/* ═══════════════════════════════════════════════════════════
   FirefighterStory.com — styles.css
   Color Scheme: Deep Red (#8B0000) + Black + White + Gold
   Mobile-first, fast-loading, text-forward
   ═══════════════════════════════════════════════════════════ */

/* ─── RESET & BASE ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --red:        #8B0000;
  --red-light:  #b30000;
  --red-dark:   #5c0000;
  --gold:       #c9a84c;
  --gold-light: #e6c97a;
  --black:      #111111;
  --dark:       #1a1a1a;
  --gray-dark:  #333333;
  --gray:       #666666;
  --gray-light: #cccccc;
  --off-white:  #f5f5f0;
  --white:      #ffffff;

  --font-head:  'Georgia', 'Times New Roman', serif;
  --font-body:  'Helvetica Neue', Arial, sans-serif;
  --font-mono:  'Courier New', monospace;

  --shadow-sm:  0 1px 4px rgba(0,0,0,0.15);
  --shadow-md:  0 4px 16px rgba(0,0,0,0.20);
  --shadow-lg:  0 8px 32px rgba(0,0,0,0.25);

  --radius:     6px;
  --radius-lg:  12px;
  --transition: 0.2s ease;
  --max-width:  1100px;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--off-white);
  color: var(--black);
  line-height: 1.7;
  font-size: 16px;
  padding-bottom: 60px; /* space above footer */
}

a { color: var(--red); text-decoration: none; }
a:hover { color: var(--red-light); text-decoration: underline; }

img { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  line-height: 1.25;
  color: var(--dark);
}

p { margin-bottom: 1rem; }

ul, ol { padding-left: 1.5rem; margin-bottom: 1rem; }

/* ─── LAYOUT ────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
}

.section { padding: 3rem 0; }
.section-alt { background: var(--white); }

.two-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .two-col { grid-template-columns: 1fr 1fr; }
  .three-col { grid-template-columns: 1fr 1fr 1fr; }
}

.three-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .three-col { grid-template-columns: repeat(3, 1fr); }
}

/* ─── NAVIGATION ────────────────────────────────────────── */
.site-nav {
  background: var(--dark);
  border-bottom: 3px solid var(--red);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-md);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  max-width: var(--max-width);
  margin: 0 auto;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.nav-logo {
  font-family: var(--font-head);
  font-size: 1.4rem;
  font-weight: bold;
  color: var(--white) !important;
  text-decoration: none !important;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-logo .flame { color: var(--gold); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.nav-link {
  color: var(--gray-light) !important;
  font-size: 0.95rem;
  transition: color var(--transition);
  text-decoration: none !important;
}

.nav-link:hover, .nav-link.active { color: var(--gold) !important; }

.nav-admin { color: var(--gold) !important; }

#nav-auth {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav-user { color: var(--gray-light); font-size: 0.9rem; }

/* ─── BUTTONS ───────────────────────────────────────────── */
.btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius);
  font-weight: bold;
  font-size: 1rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition);
  text-decoration: none !important;
  text-align: center;
}

.btn-primary {
  background: var(--red);
  color: var(--white) !important;
  border-color: var(--red);
}
.btn-primary:hover {
  background: var(--red-light);
  border-color: var(--red-light);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-gold {
  background: var(--gold);
  color: var(--dark) !important;
  border-color: var(--gold);
}
.btn-gold:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--red) !important;
  border-color: var(--red);
}
.btn-outline:hover {
  background: var(--red);
  color: var(--white) !important;
}

.btn-dark {
  background: var(--dark);
  color: var(--white) !important;
  border-color: var(--dark);
}
.btn-dark:hover { background: var(--black); }

.btn-sm {
  display: inline-block;
  padding: 0.4rem 0.9rem;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: bold;
  cursor: pointer;
  border: 2px solid var(--red);
  background: var(--red);
  color: var(--white) !important;
  text-decoration: none !important;
  transition: all var(--transition);
}
.btn-sm:hover { background: var(--red-light); border-color: var(--red-light); }

.btn-success { background: #2e7d32; color: var(--white) !important; border-color: #2e7d32; }
.btn-success:hover { background: #1b5e20; }

.btn-danger { background: var(--red-dark); color: var(--white) !important; border-color: var(--red-dark); }
.btn-danger:hover { background: var(--red); }

.btn-warn { background: #e65100; color: var(--white) !important; border-color: #e65100; }
.btn-warn:hover { background: #bf360c; }

/* ─── HERO ──────────────────────────────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--dark) 0%, var(--red-dark) 60%, var(--dark) 100%);
  color: var(--white);
  padding: 5rem 1rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 40px,
    rgba(255,255,255,0.02) 40px,
    rgba(255,255,255,0.02) 80px
  );
}

.hero-content { position: relative; z-index: 1; }

.hero h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  color: var(--white);
  margin-bottom: 1rem;
  text-shadow: 2px 2px 8px rgba(0,0,0,0.5);
}

.hero-flame { color: var(--gold); }

.hero p {
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: var(--gray-light);
  max-width: 600px;
  margin: 0 auto 2rem;
}

.hero-btns {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ─── SECTION HEADERS ───────────────────────────────────── */
.section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.section-header h2 {
  font-size: 2rem;
  position: relative;
  display: inline-block;
}

.section-header h2::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--gold);
  margin: 0.5rem auto 0;
}

.section-header p {
  color: var(--gray);
  font-size: 1.05rem;
  margin-top: 0.5rem;
}

/* ─── BADGES ────────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 0.25rem 0.7rem;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: bold;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ─── STORY CARDS ───────────────────────────────────────── */
.story-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(0,0,0,0.06);
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}

.story-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.story-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.story-date { color: var(--gray); font-size: 0.85rem; }

.story-card-title {
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.story-card-title a {
  color: var(--dark);
  text-decoration: none;
}
.story-card-title a:hover { color: var(--red); }

.story-card-teaser {
  color: var(--gray-dark);
  font-size: 0.95rem;
  flex: 1;
}

.story-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--gray-light);
}

.story-author { color: var(--gray); font-size: 0.85rem; }

.read-more-link {
  color: var(--red);
  font-weight: bold;
  font-size: 0.9rem;
}

/* ─── CATEGORIES BAR ────────────────────────────────────── */
.categories-bar {
  background: var(--dark);
  padding: 1rem;
}

.categories-inner {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.cat-pill {
  padding: 0.4rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: bold;
  cursor: pointer;
  border: 2px solid transparent;
  color: var(--white);
  transition: all var(--transition);
  text-decoration: none !important;
  background: var(--gray-dark);
}
.cat-pill:hover, .cat-pill.active {
  border-color: var(--gold);
  color: var(--gold) !important;
}

/* ─── FORMS ─────────────────────────────────────────────── */
.form-group {
  margin-bottom: 1.25rem;
}

label {
  display: block;
  font-weight: bold;
  margin-bottom: 0.4rem;
  color: var(--dark);
  font-size: 0.95rem;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="file"],
select,
textarea {
  width: 100%;
  padding: 0.65rem 0.9rem;
  border: 2px solid var(--gray-light);
  border-radius: var(--radius);
  font-size: 1rem;
  font-family: var(--font-body);
  background: var(--white);
  color: var(--dark);
  transition: border-color var(--transition);
  -webkit-appearance: none;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(139,0,0,0.1);
}

textarea { resize: vertical; min-height: 200px; line-height: 1.7; }

.form-hint { font-size: 0.82rem; color: var(--gray); margin-top: 0.25rem; }

.form-error { color: var(--red); font-size: 0.85rem; margin-top: 0.25rem; display: none; }
.form-error.visible { display: block; }

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.checkbox-group input[type="checkbox"] {
  width: auto;
  margin-top: 0.2rem;
  accent-color: var(--red);
}

/* Toggle */
.toggle-group {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.toggle-btn {
  padding: 0.4rem 1.2rem;
  border: 2px solid var(--gray-light);
  border-radius: 20px;
  cursor: pointer;
  font-size: 0.9rem;
  background: var(--white);
  color: var(--gray);
  transition: all var(--transition);
}

.toggle-btn.active {
  background: var(--red);
  color: var(--white);
  border-color: var(--red);
}

/* ─── SEARCH BAR ────────────────────────────────────────── */
.search-bar {
  display: flex;
  gap: 0.5rem;
  max-width: 500px;
}

.search-bar input {
  flex: 1;
}

/* ─── STORY DETAIL ──────────────────────────────────────── */
.story-detail {
  max-width: 780px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

.story-detail-header {
  margin-bottom: 2rem;
}

.story-detail-header h1 {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  margin: 0.75rem 0;
  line-height: 1.3;
}

.story-detail-meta {
  color: var(--gray);
  font-size: 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.5rem;
}

.story-body {
  font-size: 1.1rem;
  line-height: 1.9;
  color: var(--gray-dark);
}

.story-body p {
  white-space: pre-line;
}

.share-bar {
  background: var(--off-white);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  margin: 2rem 0;
}

.share-bar h4 {
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.share-btns {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.share-btn {
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: bold;
  cursor: pointer;
  border: none;
  color: var(--white);
  text-decoration: none !important;
  transition: opacity var(--transition);
}
.share-btn:hover { opacity: 0.85; }
.share-fb  { background: #1877f2; }
.share-tw  { background: #000; }
.share-ig  { background: linear-gradient(45deg,#f09433,#e6683c,#dc2743,#cc2366,#bc1888); }
.share-copy{ background: var(--gray-dark); }

/* ─── SUBSCRIPTION CARDS ────────────────────────────────── */
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  max-width: 700px;
  margin: 0 auto;
}

@media (min-width: 600px) {
  .pricing-grid { grid-template-columns: 1fr 1fr; }
}

.pricing-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  border: 2px solid transparent;
  text-align: center;
  position: relative;
}

.pricing-card.featured {
  border-color: var(--gold);
  box-shadow: var(--shadow-md);
}

.pricing-card.featured::before {
  content: 'BEST VALUE';
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: var(--dark);
  font-size: 0.75rem;
  font-weight: bold;
  padding: 0.2rem 0.75rem;
  border-radius: 20px;
  letter-spacing: 0.05em;
}

.pricing-price {
  font-size: 2.5rem;
  font-family: var(--font-head);
  color: var(--red);
  font-weight: bold;
}

.pricing-period { font-size: 0.9rem; color: var(--gray); }

.pricing-features {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
  text-align: left;
}

.pricing-features li {
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--off-white);
  font-size: 0.95rem;
}

.pricing-features li::before { content: '✓ '; color: var(--red); font-weight: bold; }

/* ─── ADMIN PANEL ───────────────────────────────────────── */
.admin-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: calc(100vh - 60px);
}

@media (max-width: 768px) {
  .admin-layout { grid-template-columns: 1fr; }
}

.admin-sidebar {
  background: var(--dark);
  padding: 1.5rem 0;
  min-height: 100%;
}

.admin-sidebar h3 {
  color: var(--gold);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0.5rem 1.25rem;
  margin-bottom: 0.25rem;
}

.admin-nav-link {
  display: block;
  padding: 0.65rem 1.25rem;
  color: var(--gray-light) !important;
  text-decoration: none !important;
  font-size: 0.95rem;
  transition: background var(--transition), color var(--transition);
  cursor: pointer;
}

.admin-nav-link:hover, .admin-nav-link.active {
  background: rgba(139,0,0,0.3);
  color: var(--white) !important;
}

.admin-content {
  padding: 2rem;
  overflow-x: auto;
}

.admin-section { display: none; }
.admin-section.active { display: block; }

.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--red);
}

.stat-num {
  font-size: 2rem;
  font-weight: bold;
  color: var(--red);
  font-family: var(--font-head);
}

.stat-label { font-size: 0.85rem; color: var(--gray); }

/* ─── STORY TABLE ───────────────────────────────────────── */
.story-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  font-size: 0.9rem;
}

.story-table th {
  background: var(--dark);
  color: var(--white);
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.story-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--off-white);
  vertical-align: top;
}

.story-table tr:last-child td { border-bottom: none; }
.story-table tr:hover td { background: var(--off-white); }

.story-table .actions {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

/* ─── MODAL ─────────────────────────────────────────────── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-overlay.open { display: flex; }

.modal {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  max-width: 700px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--gray);
  line-height: 1;
}
.modal-close:hover { color: var(--dark); }

/* ─── EMAIL CAPTURE ─────────────────────────────────────── */
.email-capture {
  background: linear-gradient(135deg, var(--dark), var(--red-dark));
  color: var(--white);
  padding: 3rem 1rem;
  text-align: center;
}

.email-capture h2 { color: var(--white); margin-bottom: 0.5rem; }
.email-capture p { color: var(--gray-light); margin-bottom: 1.5rem; }

.email-form {
  display: flex;
  gap: 0.5rem;
  max-width: 460px;
  margin: 0 auto;
  flex-wrap: wrap;
}

.email-form input {
  flex: 1;
  min-width: 200px;
  border: 2px solid rgba(255,255,255,0.3);
  background: rgba(255,255,255,0.1);
  color: var(--white);
}

.email-form input::placeholder { color: rgba(255,255,255,0.5); }
.email-form input:focus { border-color: var(--gold); }

/* ─── FOOTER ────────────────────────────────────────────── */
.site-footer {
  background: var(--dark);
  color: var(--gray-light);
  padding: 2.5rem 1rem 1rem;
  border-top: 3px solid var(--red);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 600px) {
  .footer-inner { grid-template-columns: 2fr 1fr 1fr; }
}

.footer-brand h3 {
  color: var(--white);
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.footer-brand p { font-size: 0.9rem; max-width: 300px; }

.footer-links h4 {
  color: var(--gold);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.footer-links ul { list-style: none; padding: 0; }
.footer-links li { margin-bottom: 0.4rem; }
.footer-links a { color: var(--gray-light); font-size: 0.9rem; }
.footer-links a:hover { color: var(--gold); }

.footer-bottom {
  max-width: var(--max-width);
  margin: 2rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--gray);
}

.footer-social {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.1);
  border-radius: 50%;
  color: var(--gray-light) !important;
  transition: background var(--transition);
}

.footer-social a:hover { background: var(--red); }
.footer-social svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ─── SOCIAL SIDEBAR ─────────────────────────────────────── */
.social-sidebar {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: var(--white) !important;
  transition: width var(--transition), opacity var(--transition);
  text-decoration: none !important;
  opacity: 0.85;
}
.social-icon:hover { width: 44px; opacity: 1; }

.social-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.social-icon.facebook  { background: #1877f2; }
.social-icon.instagram { background: #e1306c; }
.social-icon.tiktok    { background: #010101; }
.social-icon.twitter   { background: #14171a; }

@media (max-width: 600px) { .social-sidebar { display: none; } }

/* ─── LOGIN / AUTH ──────────────────────────────────────── */
.auth-box {
  max-width: 440px;
  margin: 3rem auto;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
}

.auth-tabs {
  display: flex;
  border-bottom: 2px solid var(--off-white);
  margin-bottom: 1.5rem;
}

.auth-tab {
  padding: 0.65rem 1.25rem;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 1rem;
  color: var(--gray);
  font-weight: bold;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition);
}

.auth-tab.active {
  color: var(--red);
  border-bottom-color: var(--red);
}

.auth-panel { display: none; }
.auth-panel.active { display: block; }

/* ─── ALERTS ─────────────────────────────────────────────── */
.alert {
  padding: 0.9rem 1.25rem;
  border-radius: var(--radius);
  margin-bottom: 1rem;
  font-size: 0.95rem;
  display: none;
}
.alert.visible { display: block; }
.alert-success { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.alert-error   { background: #ffebee; color: #c62828; border: 1px solid #ef9a9a; }
.alert-info    { background: #e3f2fd; color: #1565c0; border: 1px solid #90caf9; }

/* ─── PAGINATION ─────────────────────────────────────────── */
.pagination {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.page-btn {
  padding: 0.5rem 0.9rem;
  border: 2px solid var(--gray-light);
  border-radius: var(--radius);
  cursor: pointer;
  background: var(--white);
  font-size: 0.9rem;
  transition: all var(--transition);
}

.page-btn:hover, .page-btn.active {
  background: var(--red);
  border-color: var(--red);
  color: var(--white);
}

/* ─── CAPTCHA ────────────────────────────────────────────── */
.captcha-box {
  background: var(--off-white);
  border: 2px dashed var(--gray-light);
  border-radius: var(--radius);
  padding: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.captcha-question {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: bold;
  color: var(--dark);
  background: var(--white);
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.captcha-box input {
  width: 80px;
}

/* ─── THANK YOU / SUCCESS SCREEN ────────────────────────── */
.success-screen {
  text-align: center;
  padding: 3rem 1rem;
  display: none;
}
.success-screen.visible { display: block; }
.success-icon { font-size: 4rem; margin-bottom: 1rem; }
.success-screen h2 { color: var(--red); margin-bottom: 0.75rem; }

/* ─── BOOK BUILDER ───────────────────────────────────────── */
.book-selection {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.book-story-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--white);
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
  transition: border-color var(--transition);
  cursor: pointer;
}

.book-story-row:hover { border-color: var(--gold); }
.book-story-row.selected { border-color: var(--red); background: #fff5f5; }
.book-story-row input[type="checkbox"] { accent-color: var(--red); }

/* ─── MISC ───────────────────────────────────────────────── */
.divider {
  border: none;
  border-top: 2px solid var(--off-white);
  margin: 2rem 0;
}

.gold-bar {
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  margin: 2rem 0;
}

.tag { color: var(--gray); font-style: italic; font-size: 0.9rem; }

.loading {
  text-align: center;
  color: var(--gray);
  padding: 2rem;
  font-style: italic;
}

.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--gray);
}

.empty-state h3 { margin-bottom: 0.5rem; }

/* ─── RESPONSIVE TWEAKS ─────────────────────────────────── */
@media (max-width: 768px) {
  .admin-layout { grid-template-columns: 1fr; }
  .admin-sidebar { min-height: auto; display: flex; flex-wrap: wrap; align-items: center; padding: 0.5rem; }
  .admin-sidebar h3 { display: none; }
  .admin-nav-link { padding: 0.5rem 0.75rem; font-size: 0.85rem; }
  .admin-content { padding: 1rem; }
  .story-table { font-size: 0.82rem; }
  .story-table .actions { flex-direction: column; }
}

@media (max-width: 480px) {
  .hero { padding: 3rem 1rem; }
  .nav-links { gap: 0.5rem; }
}
