/* ==========================================================================
   EdCatalyst — Irritating Batch Scripts Page Styles
   Matches the site's standard Tools-page pattern: full navbar/footer,
   terracotta/gold/peacock palette, gradient hero, card system.
   (Layers on top of ../../styles/main.css for shared variables.)
   ========================================================================== */

body {
  font-family: 'Poppins', sans-serif;
  background: var(--ec-bg);
}

/* ---------------- Hero ---------------- */
.batch-hero {
  position: relative;
  overflow: hidden;
}

.batch-hero-title {
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1.15;
  margin: 1rem 0 1rem;
}

.batch-hero-sub {
  font-size: 1.05rem;
  color: var(--ec-ink-soft);
  max-width: 620px;
  margin: 0 auto;
}

.batch-author-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 2px solid #f0e2d3;
  border-radius: 30px;
  padding: 0.5rem 1.3rem;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ec-terracotta);
}

/* ---------------- Generic card ---------------- */
.batch-card {
  background: var(--ec-card-bg);
  border-radius: 20px;
  padding: 2rem;
  box-shadow: var(--ec-shadow-soft);
  border: 1px solid rgba(168, 60, 12, 0.06);
}

.batch-card-title {
  color: var(--ec-terracotta);
  font-weight: 800;
  font-size: 1.3rem;
  margin-bottom: 1rem;
}

.batch-card-title i {
  margin-right: 8px;
}

.batch-mission-text {
  color: var(--ec-ink-soft);
  font-size: 1rem;
  line-height: 1.7;
}

.batch-mission-text strong {
  color: var(--ec-terracotta);
}

/* ---------------- File badges ---------------- */
.batch-file-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1rem;
}

.batch-file-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #fffaf2;
  border: 1.5px solid #f0e2d3;
  padding: 0.5rem 1.1rem;
  border-radius: 30px;
  font-family: 'Courier New', monospace;
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--ec-ink);
}

.batch-file-badge i {
  color: var(--ec-terracotta);
}

.batch-bonus-note {
  background: rgba(216, 144, 12, 0.1);
  border: 1px solid rgba(216, 144, 12, 0.3);
  border-radius: 30px;
  padding: 0.7rem 1.4rem;
  color: var(--ec-ink);
  font-size: 0.92rem;
  display: inline-block;
}

.batch-bonus-note i {
  color: var(--ec-gold);
  margin-right: 6px;
}

/* ---------------- Tags / instruction note ---------------- */
.batch-tag-badge {
  background: var(--ec-gradient-1);
  color: #fff;
  font-weight: 700;
  font-size: 0.78rem;
  padding: 0.35rem 1rem;
  border-radius: 20px;
  white-space: nowrap;
}

.batch-tag-badge.batch-tag-warn {
  background: linear-gradient(135deg, #b91c1c, var(--ec-terracotta));
}

.batch-instruction-note {
  background: #fffaf2;
  border: 1.5px dashed #f0e2d3;
  border-radius: 14px;
  padding: 1rem 1.3rem;
  color: var(--ec-ink-soft);
  font-size: 0.92rem;
  line-height: 1.7;
}

.batch-instruction-note i {
  color: var(--ec-peacock-green);
  margin-right: 6px;
}

/* ---------------- Script grid ---------------- */
.batch-script-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.2rem;
}

.batch-script-entry {
  background: #fffaf2;
  border: 1.5px solid #f0e2d3;
  border-radius: 16px;
  padding: 1.3rem 1.4rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.batch-script-entry:hover {
  transform: translateY(-4px);
  box-shadow: var(--ec-shadow-soft);
  border-color: var(--ec-terracotta);
}

.batch-script-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  margin-bottom: 0.5rem;
}

.batch-script-title {
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--ec-ink);
}

.batch-emoji {
  margin-right: 4px;
}

.batch-script-desc {
  color: var(--ec-ink-soft);
  font-size: 0.85rem;
  margin-bottom: 0.8rem;
}

/* ---------------- Code blocks ---------------- */
.batch-code {
  background: #1a1310;
  border-radius: 10px;
  padding: 1rem 1.1rem;
  margin: 0;
  overflow-x: auto;
  border: 1px solid #2b1f17;
}

.batch-code code {
  color: #9fe89f;
  font-family: 'Courier New', monospace;
  font-size: 0.82rem;
  line-height: 1.6;
  white-space: pre;
}

/* ---------------- Copy / toggle buttons ---------------- */
.batch-copy-btn,
.batch-toggle-btn {
  background: var(--ec-gradient-1);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 0.4rem 0.9rem;
  font-weight: 700;
  font-size: 0.78rem;
  white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  flex-shrink: 0;
}

.batch-copy-btn:hover,
.batch-toggle-btn:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--ec-shadow-soft);
}

.batch-copy-btn.copied {
  background: var(--ec-gradient-4);
}

.batch-copy-btn i,
.batch-toggle-btn i {
  margin-right: 4px;
}

.batch-toggle-btn {
  background: #fff;
  color: var(--ec-terracotta);
  border: 2px solid #f0e2d3;
}

.batch-toggle-btn:hover {
  border-color: var(--ec-terracotta);
}

.batch-toggle-btn .fa-chevron-down {
  transition: transform 0.25s ease;
}

.batch-toggle-btn[aria-expanded="true"] .fa-chevron-down {
  transform: rotate(180deg);
}

/* ---------------- Project blocks ---------------- */
.batch-project-block {
  background: var(--ec-card-bg);
  border-radius: 20px;
  padding: 1.8rem 2rem;
  box-shadow: var(--ec-shadow-soft);
  border: 1px solid rgba(168, 60, 12, 0.06);
}

.batch-project-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 0.5rem;
}

.batch-project-title {
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--ec-ink);
}

.batch-project-title i {
  color: var(--ec-terracotta);
  margin-right: 8px;
}

.batch-collapsible {
  display: none;
  margin-top: 1rem;
}

.batch-collapsible.expanded {
  display: block;
  animation: batchFadeIn 0.3s ease;
}

@keyframes batchFadeIn {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------------- Responsive ---------------- */
@media (max-width: 768px) {
  .batch-hero-title {
    font-size: 1.9rem;
  }
  .batch-card,
  .batch-project-block {
    padding: 1.4rem;
  }
  .batch-script-grid {
    grid-template-columns: 1fr;
  }
  .batch-code {
    font-size: 0.75rem;
  }
}
