/* ==========================================================================
   Sukoon Family - Modern Minimalist High-Converting Marketing Theme
   Colors: Deep Emerald (#0F382C), Soft Sage (#4A7C6D), Warm Cream (#FAF6EE),
           Accent Gold (#D4AF37), Rich Slate (#1A2421), Pure White (#FFFFFF)
   ========================================================================== */

:root {
  --primary-emerald: #0F382C;
  --primary-emerald-light: #185241;
  --primary-emerald-dark: #09241C;
  --sage-accent: #4A7C6D;
  --sage-subtle: #E8F0EC;
  --gold-accent: #D4AF37;
  --gold-hover: #B89528;
  --gold-subtle: #FFFDF0;
  --bg-cream: #FAF6EE;
  --bg-card: #FFFFFF;
  --text-primary: #1A2421;
  --text-secondary: #4A5853;
  --text-muted: #5A6B65;
  --border-light: #E2E8E4;
  --border-gold: rgba(212, 175, 55, 0.3);
  
  --font-heading: 'Cinzel', 'Playfair Display', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  
  --shadow-subtle: 0 4px 20px rgba(15, 56, 44, 0.04);
  --shadow-hover: 0 12px 36px rgba(15, 56, 44, 0.1);
  --shadow-gold: 0 8px 24px rgba(212, 175, 55, 0.15);
  
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
}

/* Reset & Global Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-cream);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Typography Utility */
h1, h2, .font-heading {
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--primary-emerald);
  line-height: 1.25;
}

h3, h4 {
  font-family: var(--font-body);
  font-weight: 700;
  color: var(--primary-emerald);
  line-height: 1.35;
}

p {
  color: var(--text-secondary);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

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

/* Container */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Badges & Pills */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge-emerald {
  background-color: rgba(15, 56, 44, 0.08);
  color: var(--primary-emerald);
  border: 1px solid rgba(15, 56, 44, 0.15);
}

.badge-gold {
  background-color: rgba(212, 175, 55, 0.12);
  color: #8C6D13;
  border: 1px solid var(--border-gold);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--primary-emerald);
  color: var(--bg-cream);
  box-shadow: 0 4px 14px rgba(15, 56, 44, 0.25);
}

.btn-primary:hover {
  background-color: var(--primary-emerald-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(15, 56, 44, 0.35);
}

.btn-gold {
  background-color: var(--gold-accent);
  color: var(--primary-emerald-dark);
  box-shadow: var(--shadow-gold);
}

.btn-gold:hover {
  background-color: var(--gold-hover);
  transform: translateY(-2px);
  color: var(--primary-emerald-dark);
}

.btn-outline {
  border-color: var(--primary-emerald);
  color: var(--primary-emerald);
  background: transparent;
}

.btn-outline:hover {
  background-color: var(--primary-emerald);
  color: var(--bg-cream);
}

.btn-sm {
  padding: 9px 20px;
  font-size: 0.88rem;
}

.btn-amazon {
  background-color: #FF9900;
  color: #111111;
  border: 1px solid #E68A00;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(255, 153, 0, 0.25);
}

.btn-amazon:hover {
  background-color: #E68A00;
  color: #000000;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 153, 0, 0.35);
}

/* ==========================================================================
   Multi-Line Header & Navigation Styles
   ========================================================================== */
.site-header {
  width: 100%;
  position: relative;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(9, 36, 28, 0.08);
}

/* Line 1: Top Utility Bar */
.top-utility-bar {
  background-color: var(--primary-emerald-dark, #09241c);
  color: var(--bg-cream, #FAF6EE);
  font-size: 0.82rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.utility-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.utility-left, .utility-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.utility-item {
  color: rgba(250, 246, 238, 0.9);
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

.utility-promo {
  display: inline-flex;
  align-items: center;
}

.utility-promo-text {
  white-space: nowrap;
}

.utility-link {
  text-decoration: none;
  transition: color 0.2s ease;
  white-space: nowrap;
}
.utility-link:hover {
  color: var(--gold-accent, #d4af37);
}

.utility-divider {
  color: rgba(212, 175, 55, 0.3);
}

.utility-btn {
  background: none;
  border: none;
  color: var(--bg-cream, #FAF6EE);
  font-size: 0.82rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: color 0.2s ease;
  padding: 0;
  white-space: nowrap;
}

.utility-btn:hover {
  color: var(--gold-accent, #d4af37);
}

.badge-pill {
  background: rgba(212, 175, 55, 0.2);
  color: var(--gold-accent, #d4af37);
  border: 1px solid var(--border-gold, #d4af37);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  line-height: 1.2;
}

.pill-gold {
  background: var(--gold-accent, #d4af37);
  color: var(--primary-emerald-dark, #09241c);
}

.utility-cart-total {
  font-weight: 700;
  color: var(--gold-accent, #d4af37);
}

/* Line 2: Main Header Bar */
.main-header-bar {
  background-color: var(--bg-cream, #FAF6EE);
  padding: 16px 0;
  border-bottom: 1px solid rgba(15, 56, 44, 0.08);
}

.main-header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary-emerald);
}

.logo-icon {
  width: 44px;
  height: 44px;
}

.logo-img {
  max-height: 64px;
  max-width: 280px;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.footer-brand .logo-img {
  max-height: 56px;
  max-width: 240px;
}

.logo-text-wrap {
  display: flex;
  flex-direction: column;
}

.logo-title {
  font-family: var(--font-heading, 'Cinzel', serif);
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--primary-emerald-dark, #09241c);
  line-height: 1.1;
}

.logo-tagline {
  font-size: 0.72rem;
  color: var(--gold-accent, #d4af37);
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* Header Search Form */
.header-search-form {
  display: flex;
  align-items: center;
  flex-grow: 1;
  max-width: 580px;
  background: #fff;
  border: 1px solid var(--border-gold, #d4af37);
  border-radius: 30px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(9, 36, 28, 0.05);
}

.search-category-select {
  border: none;
  background: rgba(15, 56, 44, 0.04);
  color: var(--primary-emerald-dark, #09241c);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 10px 14px;
  outline: none;
  border-right: 1px solid rgba(15, 56, 44, 0.1);
  cursor: pointer;
}

.header-search-input {
  flex-grow: 1;
  border: none;
  padding: 10px 16px;
  font-size: 0.88rem;
  outline: none;
  color: #333;
}

.header-search-btn {
  background: var(--primary-emerald-dark, #09241c);
  color: var(--gold-accent, #d4af37);
  border: none;
  padding: 10px 20px;
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.header-search-btn:hover {
  background: var(--gold-accent, #d4af37);
  color: var(--primary-emerald-dark, #09241c);
}

.main-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Line 3: Main Navigation Bar & Dropdowns */
.main-nav-bar {
  background-color: #fff;
  border-bottom: 2px solid var(--border-gold, #d4af37);
  position: sticky;
  top: 0;
  z-index: 999;
}

.nav-container {
  display: flex;
  align-items: center;
}

.main-nav-links {
  display: flex;
  list-style: none;
  gap: 4px;
  margin: 0;
  padding: 0;
}

.nav-item {
  position: relative;
}

.nav-item .nav-link {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 18px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--primary-emerald-dark, #09241c);
  text-decoration: none;
  transition: all 0.2s ease;
}

.nav-item:hover .nav-link {
  color: var(--gold-accent, #d4af37);
  background-color: rgba(15, 56, 44, 0.03);
}

/* Dropdown Menu Styles */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  width: 320px;
  background: #fff;
  border-radius: 0 0 12px 12px;
  box-shadow: 0 12px 30px rgba(9, 36, 28, 0.15);
  border: 1px solid var(--border-gold, #d4af37);
  border-top: 3px solid var(--gold-accent, #d4af37);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.25s ease;
  padding: 8px 0;
  z-index: 1001;
}

.nav-item:hover .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  text-decoration: none;
  color: #333;
  transition: background 0.2s ease;
}

.dropdown-item:hover {
  background-color: var(--bg-cream, #FAF6EE);
}

.dropdown-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--sage-subtle, #E8F0EC);
  color: var(--primary-emerald, #0F382C);
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.dropdown-item:hover .dropdown-icon {
  background: var(--gold-subtle, #FFFDF0);
  color: var(--gold-hover, #B89528);
}

.dropdown-icon svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}

.dropdown-item strong {
  display: block;
  font-size: 0.88rem;
  color: var(--primary-emerald-dark, #09241c);
  margin-bottom: 2px;
}

.dropdown-item p {
  font-size: 0.78rem;
  color: #666;
  margin: 0;
  line-height: 1.3;
}

/* ==========================================================================
   Hero Image Carousel Styles
   ========================================================================== */
.hero-carousel-section {
  position: relative;
  overflow: hidden;
  background-color: var(--primary-emerald-dark);
  color: var(--bg-cream);
}

.carousel-container {
  position: relative;
  width: 100%;
  min-height: 580px;
  display: flex;
  align-items: stretch;
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  min-height: 580px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
  display: flex;
  align-items: center;
  box-sizing: border-box;
}

.carousel-slide.active {
  opacity: 1;
  visibility: visible;
  position: relative;
  width: 100%;
  min-height: 580px;
}

.slide-bg-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 1;
  filter: brightness(0.85);
}

.slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(9, 36, 28, 0.92) 0%, rgba(9, 36, 28, 0.65) 50%, rgba(9, 36, 28, 0.2) 100%);
  z-index: 2;
}

.slide-content-wrap {
  position: relative;
  z-index: 3;
  max-width: 640px;
  padding: 60px 0;
}

.slide-badge {
  margin-bottom: 16px;
  background: rgba(212, 175, 55, 0.2);
  color: var(--gold-accent);
  border: 1px solid var(--border-gold);
}

.slide-title {
  font-size: 3.2rem;
  line-height: 1.15;
  color: var(--bg-cream);
  margin-bottom: 18px;
}

.slide-title span {
  color: var(--gold-accent);
  display: block;
}

.slide-desc {
  font-size: 1.15rem;
  color: rgba(250, 246, 238, 0.9);
  line-height: 1.65;
  margin-bottom: 28px;
}

.slide-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Carousel Controls */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(15, 56, 44, 0.65);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(212, 175, 55, 0.4);
  color: var(--bg-cream);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.carousel-btn:hover {
  background: var(--gold-accent);
  color: var(--primary-emerald-dark);
  border-color: var(--gold-accent);
}

.carousel-btn-prev {
  left: 24px;
}

.carousel-btn-next {
  right: 24px;
}

/* Carousel Indicators / Dots */
.carousel-dots {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 10px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(250, 246, 238, 0.35);
  border: 1px solid rgba(212, 175, 55, 0.5);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.dot.active {
  width: 32px;
  border-radius: 12px;
  background: var(--gold-accent);
  border-color: var(--gold-accent);
}

/* Section Common Styling */
.section {
  padding: 90px 0;
}

.section-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 50px;
}

.section-title {
  font-size: 2.3rem;
  margin: 14px 0 14px;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
}

/* High-Converting 4 Core Programs Grid */
.core-programs-section {
  background-color: var(--bg-card);
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.core-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.core-card {
  background: var(--bg-cream);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 40px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: var(--transition-normal);
  overflow: hidden;
}

.core-card.highlight {
  border-color: var(--border-gold);
  box-shadow: var(--shadow-hover);
  background: #FFFDF9;
}

.core-card:hover {
  transform: translateY(-5px);
  border-color: var(--gold-accent);
  box-shadow: var(--shadow-hover);
}

.core-badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.core-icon-box {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-emerald);
}

.core-title {
  font-size: 1.6rem;
  margin-bottom: 10px;
}

.core-desc {
  font-size: 0.98rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 24px;
  flex-grow: 1;
}

.core-benefits {
  list-style: none;
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.core-benefits li {
  font-size: 0.92rem;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-primary);
  font-weight: 500;
}

.check-svg {
  width: 18px;
  height: 18px;
  color: var(--primary-emerald);
  flex-shrink: 0;
}

/* Why Sukoon Section */
.why-section {
  background: radial-gradient(circle at 10% 10%, rgba(15, 56, 44, 0.03) 0%, transparent 60%);
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.why-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 36px 28px;
  border: 1px solid var(--border-light);
  text-align: center;
  transition: var(--transition-fast);
}

.why-card:hover {
  border-color: var(--gold-accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-subtle);
}

.why-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.why-title {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.why-desc {
  font-size: 0.92rem;
  line-height: 1.6;
}

/* Streamlined Age Tiers Section */
.age-cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.age-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 28px 20px;
  border: 1px solid var(--border-light);
  transition: var(--transition-fast);
  display: flex;
  flex-direction: column;
}

.age-card:hover {
  border-color: var(--gold-accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-subtle);
}

.age-range {
  font-size: 0.82rem;
  font-weight: 700;
  color: #8C6D13;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.age-name {
  font-size: 1.25rem;
  margin-bottom: 8px;
}

.age-focus-tag {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.age-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.88rem;
  margin-top: auto;
}

.age-bullets li {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Primary Conversion / Call Booking Section */
.conversion-section {
  background: linear-gradient(135deg, var(--primary-emerald-dark), var(--primary-emerald));
  color: var(--bg-cream);
  padding: 90px 0;
}

.conversion-box {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 50px;
  align-items: center;
}

.conversion-content h2 {
  color: var(--bg-cream);
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.conversion-content p {
  color: rgba(250, 246, 238, 0.88);
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 30px;
}

.conversion-card-form {
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border-gold);
}

.conversion-card-form h3 {
  font-size: 1.4rem;
  margin-bottom: 8px;
  text-align: center;
}

.conversion-card-form p {
  font-size: 0.88rem;
  text-align: center;
  margin-bottom: 24px;
}

/* Lead Magnet Banner */
.lead-banner {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-lg);
  padding: 50px;
  margin: 60px 0;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
  box-shadow: var(--shadow-subtle);
}

.form-inline {
  display: flex;
  gap: 12px;
  max-width: 480px;
}

label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.form-input,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="search"],
input[type="number"],
select,
textarea {
  display: block;
  width: 100%;
  padding: 12px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text-primary);
  background-color: var(--bg-card);
  outline: none;
  box-sizing: border-box;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input {
  border-radius: var(--radius-full);
}

textarea.form-input,
textarea {
  border-radius: var(--radius-sm);
  min-height: 100px;
  resize: vertical;
}

.form-input:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="tel"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
select:focus,
textarea:focus {
  border-color: var(--gold-accent);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

/* Ensure header search bar inputs keep their inline borderless styling */
.header-search-form .header-search-input {
  display: inline-block;
  width: auto;
  border: none;
  border-radius: 0;
  box-shadow: none;
  background: transparent;
  padding: 10px 16px;
}

.header-search-form .search-category-select {
  display: inline-block;
  width: auto;
  border-radius: 0;
  border: none;
  border-right: 1px solid rgba(15, 56, 44, 0.1);
  box-shadow: none;
}

/* Social Proof */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.testimonial-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 30px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.testimonial-quote {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 20px;
  font-style: italic;
}

.author-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.author-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.author-name {
  font-weight: 600;
  font-size: 0.92rem;
}

.author-role {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Footer */
.footer {
  background: var(--primary-emerald-dark);
  color: var(--bg-cream);
  padding: 70px 0 30px;
  border-top: 1px solid rgba(212, 175, 55, 0.2);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr repeat(3, 1fr);
  gap: 36px;
  margin-bottom: 45px;
}

.footer-brand p {
  color: rgba(250, 246, 238, 0.75);
  font-size: 0.88rem;
  line-height: 1.65;
  margin: 16px 0 16px;
  max-width: 320px;
}

.footer-motto {
  color: var(--gold-accent);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.footer-col h4 {
  color: var(--gold-accent);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 18px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: rgba(250, 246, 238, 0.75);
  font-size: 0.88rem;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--gold-accent);
  text-decoration: underline;
}

.footer-contact-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-contact-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(250, 246, 238, 0.8);
  font-size: 0.85rem;
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer-contact-link:hover {
  color: var(--gold-accent);
}

.footer-social-links {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}

.footer-social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(250, 246, 238, 0.08);
  color: var(--bg-cream);
  transition: all var(--transition-fast);
}

.footer-social-icon:hover {
  background: var(--gold-accent);
  color: var(--primary-emerald);
  transform: translateY(-2px);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid rgba(250, 246, 238, 0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: rgba(250, 246, 238, 0.6);
}

.footer-bottom-links {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.footer-bottom-links a {
  color: rgba(250, 246, 238, 0.7);
  transition: color var(--transition-fast);
}

.footer-bottom-links a:hover {
  color: var(--gold-accent);
}

.footer-tagline {
  color: rgba(250, 246, 238, 0.5);
  font-style: italic;
}

/* Modal Window */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(9, 36, 28, 0.75);
  backdrop-filter: blur(6px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 40px;
  max-width: 500px;
  width: 90%;
  position: relative;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.3);
  transform: translateY(20px);
  transition: transform 0.3s ease;
}

.modal-overlay.active .modal-card {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-muted);
}

/* ==========================================================================
   Book Catalog Section Styles
   ========================================================================== */
.book-catalog-section {
  background-color: var(--bg-cream-alt, #f7f5ed);
  padding: 80px 0;
  overflow: hidden;
}

.catalog-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 36px;
}

.catalog-nav-btns {
  display: flex;
  gap: 12px;
}

.catalog-scroll-btn {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--border-gold, #d4af37);
  background: var(--bg-cream, #FAF6EE);
  color: var(--primary-emerald-dark, #09241c);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.catalog-scroll-btn:hover {
  background: var(--gold-accent, #d4af37);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(212,175,55,0.3);
}

.book-catalog-track {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  padding: 10px 4px 24px 4px;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-accent, #d4af37) transparent;
}

.book-catalog-track::-webkit-scrollbar {
  height: 6px;
}
.book-catalog-track::-webkit-scrollbar-thumb {
  background: var(--gold-accent, #d4af37);
  border-radius: 4px;
}
.book-catalog-track::-webkit-scrollbar-track {
  background: rgba(0,0,0,0.05);
}

/* 4 full visible + 1 partially visible item (calc for 4.3 items view) */
.book-card {
  flex: 0 0 calc((100% - 80px) / 4.3);
  min-width: 220px;
  scroll-snap-align: start;
  background: #fff;
  border-radius: 12px;
  border: 1px solid rgba(15, 56, 44, 0.08);
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  display: flex;
  flex-direction: column;
}

.book-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(9, 36, 28, 0.12);
  border-color: var(--border-gold, #d4af37);
}

.book-cover-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #09241c;
}

.book-cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.book-card:hover .book-cover-img {
  transform: scale(1.05);
}

.book-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: rgba(9, 36, 28, 0.85);
  color: #D4AF37;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(212, 175, 55, 0.4);
}

.book-info {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.book-category {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--gold-accent, #d4af37);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.book-title {
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary-emerald-dark, #09241c);
  line-height: 1.35;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.book-author {
  font-size: 0.82rem;
  color: #666;
  margin-bottom: 12px;
}

.book-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  margin-bottom: 14px;
}

.book-rating {
  font-size: 0.85rem;
  font-weight: 700;
  color: #f39c12;
}

.rating-count {
  font-weight: 400;
  color: #888;
  font-size: 0.78rem;
}

.book-price {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-emerald-dark, #09241c);
}

.book-btn {
  width: 100%;
  text-align: center;
  padding: 8px 12px;
  font-size: 0.85rem;
}

.catalog-bottom-cta {
  text-align: center;
  margin-top: 40px;
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .slide-title {
    font-size: 2.4rem;
  }
  .carousel-btn {
    width: 40px;
    height: 40px;
  }
  .conversion-box, .lead-banner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .core-grid {
    grid-template-columns: 1fr;
  }
  .why-grid, .testimonials-grid {
    grid-template-columns: 1fr;
  }
  /* Grid items default to min-width:auto, so a 1fr track refuses to shrink
     below its content (a long word or a form input) and forces the whole page
     to overflow horizontally. min-width:0 lets the track shrink and wrap. */
  .conversion-box > *,
  .lead-banner > *,
  .conversion-content,
  .conversion-card-form,
  .why-card,
  .core-card,
  .product-summary {
    min-width: 0;
  }
  .age-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .book-card {
    flex: 0 0 calc((100% - 40px) / 2.4);
  }
}

@media (max-width: 600px) {
  .slide-title {
    font-size: 2rem;
  }
  .age-cards-grid {
    grid-template-columns: 1fr;
  }
  .form-inline {
    flex-direction: column;
  }
  .catalog-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .book-card {
    flex: 0 0 calc((100% - 20px) / 1.35);
  }
}


/* ==========================================================================
   Program landing pages
   Components used by templates/shop/program_detail.html. Each corresponds to
   one `section.type` dispatched in that template, so content stays in the DB
   and this file only owns presentation.
   ========================================================================== */

/* --- Hero ---------------------------------------------------------------- */
.program-hero {
  position: relative;
  padding: 110px 0 90px;
  background: linear-gradient(135deg, var(--primary-emerald) 0%, var(--primary-emerald-light) 100%);
  color: var(--bg-cream);
  text-align: left;
}
.program-hero .slide-content-wrap { max-width: 760px; }
.program-hero .slide-title {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4.5vw, 3.1rem);
  line-height: 1.18;
  margin-bottom: 18px;
}
.program-hero .slide-desc {
  font-size: 1.06rem;
  line-height: 1.75;
  color: rgba(250, 246, 238, 0.92);
  margin-bottom: 28px;
  max-width: 640px;
}

/* --- Process steps ------------------------------------------------------- */
.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 26px;
  max-width: 1000px;
  margin: 0 auto;
}
.process-step {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.process-step-number {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--primary-emerald);
  color: var(--gold-accent);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.process-step-title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--primary-emerald);
  margin-bottom: 6px;
}
.process-step-desc {
  color: var(--text-secondary);
  font-size: 0.94rem;
  line-height: 1.7;
}

/* --- Comparison columns -------------------------------------------------- */
.comparison-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 26px;
}
.comparison-col {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 30px 26px;
  box-shadow: var(--shadow-subtle);
}
.comparison-col.comparison-highlight {
  border: 2px solid var(--gold-accent);
  background: var(--gold-subtle);
  box-shadow: var(--shadow-gold);
}
.comparison-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  color: var(--primary-emerald);
  margin-bottom: 10px;
}

/* --- Schedule models ----------------------------------------------------- */
.schedule-card {
  flex: 1 1 260px;
  max-width: 340px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 26px 24px;
  text-align: left;
  box-shadow: var(--shadow-subtle);
}
.schedule-title {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  color: var(--primary-emerald);
  margin: 10px 0 4px;
}
.schedule-duration {
  color: var(--gold-hover);
  font-weight: 700;
  font-size: 0.92rem;
  margin: 0 0 12px;
}
.schedule-desc { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 12px; }
.schedule-list {
  list-style: none;
  padding: 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
}
.schedule-list li {
  padding: 4px 0 4px 18px;
  position: relative;
}
.schedule-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--sage-accent);
  font-weight: 700;
}

/* --- Includes / concern groups ------------------------------------------- */
.includes-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.includes-group {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 24px 22px;
}
.includes-group-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--primary-emerald);
  margin-bottom: 12px;
}
.includes-group ul { list-style: none; padding: 0; }
.includes-group li {
  position: relative;
  padding: 4px 0 4px 22px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}
.includes-group li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 14px;
  height: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234A7C6D' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
}

/* --- Stats --------------------------------------------------------------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 24px;
  text-align: center;
}
.stat {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 22px 16px;
}
.stat-value {
  display: block;
  font-family: var(--font-heading);
  font-size: 2.1rem;
  color: var(--gold-accent);
  font-weight: 700;
  line-height: 1.1;
}
.stat-label {
  display: block;
  font-size: 0.82rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-top: 6px;
}

/* --- Auth Segmented Tabs ------------------------------------------------- */
.auth-tabs {
  display: flex;
  background: var(--sage-subtle);
  padding: 4px;
  border-radius: var(--radius-full);
  margin-bottom: 24px;
  gap: 4px;
}

.auth-tab-btn {
  flex: 1;
  padding: 10px 16px;
  font-size: 0.92rem;
  font-weight: 600;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: center;
}

.auth-tab-btn:hover {
  color: var(--primary-emerald);
}

.auth-tab-btn.active {
  background: #ffffff;
  color: var(--primary-emerald);
  box-shadow: 0 2px 8px rgba(15, 56, 44, 0.08);
}

/* --- Split Screen Auth Layout & Visual Showcase -------------------------- */
.auth-split-layout {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: 36px;
  align-items: stretch;
  max-width: 1040px;
  margin: 0 auto;
}

.auth-visual-pane {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 30px 28px;
  color: var(--text-primary);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.auth-visual-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--sage-subtle);
  border: 1px solid rgba(74, 124, 109, 0.2);
  color: var(--primary-emerald);
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  width: fit-content;
}

.auth-visual-badge-dot {
  width: 6px;
  height: 6px;
  background: var(--gold-accent);
  border-radius: 50%;
}

.auth-visual-main {
  position: relative;
  z-index: 2;
  margin: 20px 0 24px;
}

.auth-visual-title {
  font-family: var(--font-heading);
  font-size: 1.55rem;
  line-height: 1.35;
  color: var(--primary-emerald);
  margin-bottom: 12px;
}

.auth-visual-title span {
  color: var(--gold-hover);
}

.auth-visual-desc {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
  margin-bottom: 20px;
}

.auth-feature-pills {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.auth-feature-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  background: #ffffff;
  border: 1px solid var(--border-light);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 0.86rem;
  color: var(--text-secondary);
  transition: border-color var(--transition-fast), background var(--transition-fast);
}

.auth-feature-pill:hover {
  border-color: var(--sage-accent);
  background: #fafcfb;
}

.auth-feature-icon {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Rotating quote ticker */
.auth-ticker-wrap {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--border-light);
  padding-top: 18px;
}

.auth-ticker-quote {
  font-style: italic;
  font-size: 0.86rem;
  color: var(--text-secondary);
  line-height: 1.55;
  margin-bottom: 6px;
  min-height: 2.8em;
  transition: opacity 0.4s ease;
}

.auth-ticker-author {
  font-size: 0.75rem;
  color: var(--sage-accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.auth-form-pane {
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
}

.auth-form-pane .core-card {
  padding: 36px 32px;
  border: 1px solid var(--border-light);
  box-shadow: 0 10px 30px rgba(15, 56, 44, 0.08);
}

@media (max-width: 900px) {
  .auth-split-layout {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .auth-visual-pane {
    padding: 28px 20px;
    order: 2;
  }
  .auth-form-pane {
    order: 1;
  }
}

/* --- Note callout -------------------------------------------------------- */
.alert-note {
  background: var(--gold-subtle);
  border-left: 4px solid var(--gold-accent);
  border-radius: var(--radius-sm);
  padding: 22px 24px;
  max-width: 860px;
  margin: 0 auto;
  color: var(--text-secondary);
  font-size: 0.93rem;
  line-height: 1.75;
}
.note-title {
  font-family: var(--font-heading);
  color: var(--primary-emerald);
  font-size: 1.05rem;
  margin-bottom: 8px;
}

/* --- Featured pricing tier ----------------------------------------------- */
.core-card-featured {
  border: 2px solid var(--gold-accent);
  box-shadow: var(--shadow-gold);
}

/* --- Tier price and dates ------------------------------------------------ */
/* A tier may show a price, a "quoted on enquiry" note, both, or neither, so each
   part is styled to stand alone without leaving a gap where one is absent. */
.tier-price {
  font-family: var(--font-heading);
  color: var(--primary-emerald);
  font-size: 1.5rem;
  line-height: 1.2;
  margin: 0 0 10px;
}
.tier-price-note {
  display: block;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 400;
  color: var(--text-muted);
  margin-top: 2px;
}
.tier-dates {
  display: flex;
  align-items: center;
  font-size: 0.86rem;
  color: var(--text-secondary);
  margin: 0 0 10px;
}

/* --- FAQ ----------------------------------------------------------------- */
.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.faq-item[open] { border-color: var(--gold-accent); box-shadow: var(--shadow-subtle); }
.faq-question {
  cursor: pointer;
  padding: 18px 22px;
  font-family: var(--font-heading);
  font-size: 1rem;
  color: var(--primary-emerald);
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}
.faq-question::-webkit-details-marker { display: none; }
.faq-question::after {
  content: "+";
  font-size: 1.3rem;
  color: var(--gold-accent);
  flex: 0 0 auto;
  transition: transform var(--transition-fast);
}
.faq-item[open] .faq-question::after { transform: rotate(45deg); }
.faq-answer {
  padding: 0 22px 20px;
  color: var(--text-secondary);
  font-size: 0.94rem;
  line-height: 1.78;
}
.faq-answer p { margin-bottom: 10px; }
.faq-answer p:last-child { margin-bottom: 0; }

/* --- Utility alert states ----------------------------------------------- */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  margin-bottom: 12px;
  border-left: 4px solid var(--sage-accent);
  background: var(--sage-subtle);
  color: var(--primary-emerald);
}
.alert-error { background: #FDECEA; border-left-color: #C0392B; color: #922B21; }
.alert-info   { background: var(--sage-subtle); border-left-color: var(--sage-accent); color: var(--primary-emerald); }
.field-error { color: #C0392B; font-size: 0.82rem; margin-top: 4px; }
.errorlist { color: #C0392B; font-size: 0.82rem; list-style: none; padding-left: 0; }

/* --- Mobile -------------------------------------------------------------- */
@media (max-width: 768px) {
  .program-hero { padding: 76px 0 64px; }
  .process-steps { grid-template-columns: 1fr; }
  .schedule-card { max-width: none; }
}


/* ==========================================================================
   CMS components
   Article cards, resource cards, author profiles, announcement bar, and prose.
   ========================================================================== */

/* --- Prose (Page / Article bodies) --------------------------------------- */
.prose { max-width: 760px; }
.prose p {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.85;
  margin-bottom: 18px;
}
.prose p:last-child { margin-bottom: 0; }

/* --- Author index -------------------------------------------------------- */
.author-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 22px;
}
.author-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 28px 22px;
  text-align: center;
  text-decoration: none;
  color: inherit;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast),
              border-color var(--transition-fast);
}
.author-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: var(--gold-accent);
}
.author-card-photo {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 14px;
  border: 2px solid var(--sage-subtle);
}
.author-card-initials {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 auto 14px;
}
.author-card-name {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  color: var(--primary-emerald);
  margin-bottom: 4px;
}
.author-card-title {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.author-card-focus { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.author-card-focus span {
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  font-size: 0.7rem;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  letter-spacing: 0.02em;
}

/* --- Author profile ------------------------------------------------------ */
.author-profile-header {
  display: flex;
  gap: 28px;
  align-items: center;
  flex-wrap: wrap;
  padding: 30px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-subtle);
}
.author-profile-photo {
  width: 116px;
  height: 116px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--sage-subtle);
  flex: 0 0 auto;
}
.author-profile-initials {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  font-family: var(--font-heading);
  font-size: 2.1rem;
  font-weight: 700;
}
.author-profile-name {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 3vw, 2rem);
  color: var(--primary-emerald);
  margin-bottom: 4px;
}
.author-profile-title { color: var(--gold-hover); font-weight: 600; font-size: 0.95rem; }
.author-profile-header .author-card-focus { justify-content: flex-start; }

/* --- Announcement bar ---------------------------------------------------- */
.announcement-bar {
  background: var(--primary-emerald);
  color: var(--bg-cream);
  font-size: 0.88rem;
  padding: 11px 0;
}
.announcement-info { background: var(--primary-emerald); color: var(--bg-cream); }
.announcement-urgent { background: var(--gold-hover); color: #2B2410; }
.announcement-closure { background: #922B21; color: #FDEDEC; }
.announcement-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.announcement-inner a {
  color: inherit;
  text-decoration: underline;
  font-weight: 600;
  margin-left: 10px;
}
.announcement-bar strong { margin-right: 8px; }
.announcement-dismiss {
  background: none;
  border: none;
  color: inherit;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 4px;
  opacity: 0.75;
}
.announcement-dismiss:hover { opacity: 1; }

/* --- Breadcrumb (CMS pages) --------------------------------------------- */
.breadcrumb {
  font-size: 0.85rem;
  color: var(--text-muted);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.breadcrumb a { color: var(--sage-accent); }
.breadcrumb a:hover { color: var(--primary-emerald); }
.breadcrumb-current { color: var(--text-secondary); }

/* --- Mobile -------------------------------------------------------------- */
@media (max-width: 640px) {
  .author-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
  .author-profile-header { padding: 22px; gap: 18px; text-align: center; justify-content: center; }
  .author-profile-header .author-card-focus { justify-content: center; }
  .announcement-inner { flex-direction: column; align-items: flex-start; gap: 6px; }
}

/* ── Contact page (spec A2) ────────────────────────────────────────────────
   Two-column layout: the form is the point of the page, so it gets the wider
   column and the direct-contact card sits beside it. Stacks on small screens,
   where the form must come first — a visitor who followed "Contact" wants to
   write, not to read an email address.
   ------------------------------------------------------------------------- */
.contact-grid { display: grid; grid-template-columns: 1.15fr 1fr; }

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr; }
}

/* The contact form uses the same controls as the consultation form, so both
   inherit the shared input styling rather than duplicating it here. */


/* ==========================================================================
   Storefront components (spec A2/A6/A7/A8)
   Product detail, cart, checkout, order, and the shared page hero. These
   templates were built after site.css and previously had no rules at all, so
   they rendered as browser defaults. Colour and spacing reuse the tokens above.
   ========================================================================== */

/* --- Accessibility helpers ----------------------------------------------- */
/* The skip link is only visible when focused; otherwise it is off-screen. */
.skip-link {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: 3000;
  background: var(--primary-emerald-dark);
  color: var(--bg-cream);
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  transition: top var(--transition-fast);
}
.skip-link:focus {
  top: 8px;
  outline: 3px solid var(--gold-accent);
  outline-offset: 2px;
}

/* Consistent keyboard focus ring across the site. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.btn:focus-visible {
  outline: 3px solid var(--gold-accent);
  outline-offset: 2px;
}

.small { font-size: 0.85rem; }
.muted { color: var(--text-muted); }

/* --- Shared page hero (bookstore-hero / hero-title) ---------------------- */
/* Used as the masthead on ~13 templates: about, category, search, all the CMS
   and listing pages. A short band, not the full-height homepage carousel. */
.bookstore-hero {
  background: linear-gradient(135deg, var(--primary-emerald-dark), var(--primary-emerald));
  color: var(--bg-cream);
  padding: 56px 0;
  border-bottom: 3px solid var(--gold-accent);
}
.bookstore-hero .container { text-align: center; }
.hero-title {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  color: var(--bg-cream);
  margin: 12px 0 10px;
}
.bookstore-hero p {
  color: rgba(250, 246, 238, 0.85);
  font-size: 1.05rem;
  max-width: 680px;
  margin: 0 auto;
}
.bookstore-hero .badge-emerald {
  background: rgba(250, 246, 238, 0.12);
  color: var(--bg-cream);
  border-color: rgba(250, 246, 238, 0.25);
}

/* The dropdown parent is a positioning context; the class is also the hook the
   mobile nav uses to decide what collapses to an accordion. */
.has-dropdown { position: relative; }

/* --- Generic content card (contact page) --------------------------------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-subtle);
}

/* --- Product detail ------------------------------------------------------ */
.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  align-items: start;
  margin-top: 28px;
}
.product-gallery {
  position: sticky;
  top: 90px;
}
.product-main-img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  background: var(--sage-subtle);
  aspect-ratio: 2 / 3;
  object-fit: cover;
}
.product-thumbs { display: flex; gap: 10px; margin-top: 12px; }
.product-thumb {
  width: 68px;
  height: 68px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 2px solid transparent;
  cursor: pointer;
}
.product-thumb.active { border-color: var(--gold-accent); }

.product-summary { min-width: 0; }
.product-meta-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
.product-category-label {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold-hover);
}
.product-meta-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 6px;
}
.product-author {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 12px;
}
.product-rating {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #f39c12;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 16px;
}
.product-rating .rating-count { color: var(--text-muted); font-weight: 500; }

.product-price-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.product-price { font-size: 2rem; font-weight: 700; color: var(--primary-emerald); }
.product-orig-price {
  font-size: 1.1rem;
  color: var(--text-muted);
  text-decoration: line-through;
}
.product-save {
  background: var(--gold-subtle);
  color: var(--gold-hover);
  border: 1px solid var(--border-gold);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
}
.product-stock-note {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin-bottom: 22px;
}

.product-buy-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 22px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  background: var(--bg-card);
}
.qty-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-secondary);
}
.qty-input { max-width: 110px; }
.product-buy-form .btn-lg { width: 100%; }

.product-assurances {
  list-style: none;
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}
.product-assurances li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.product-detail-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 40px;
  margin-top: 48px;
  align-items: start;
}
.product-description p { margin-bottom: 14px; }
.product-specs h3 { font-size: 1.2rem; margin-bottom: 14px; }
.spec-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.spec-table th,
.spec-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-light);
  vertical-align: top;
}
.spec-table th {
  color: var(--text-muted);
  font-weight: 600;
  width: 45%;
}
.spec-table td { color: var(--text-primary); }
.spec-table tr:last-child th,
.spec-table tr:last-child td { border-bottom: none; }

.suggested-products-section { text-align: left; }

/* --- Cart & order summary ------------------------------------------------ */
.cart-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 36px;
  align-items: start;
  margin-top: 26px;
}
.cart-lines { display: flex; flex-direction: column; gap: 16px; }
.cart-line {
  display: grid;
  grid-template-columns: 74px 1fr auto;
  gap: 16px;
  align-items: center;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}
.cart-line-img {
  width: 74px;
  height: 96px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--sage-subtle);
}
.cart-line-info { min-width: 0; }
.cart-line-title { font-size: 1.05rem; margin-bottom: 4px; }
.cart-line-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.cart-line-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.qty-form { display: flex; align-items: center; gap: 8px; }
.qty-form .qty-input { max-width: 76px; }
.cart-line-total {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary-emerald);
  white-space: nowrap;
}

.cart-summary {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 26px;
  box-shadow: var(--shadow-subtle);
  position: sticky;
  top: 90px;
}
.cart-summary h3 { font-size: 1.25rem; margin-bottom: 16px; }
.cart-summary .spec-table { margin-bottom: 16px; }
.cart-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 14px;
  margin-top: 6px;
  border-top: 2px solid var(--border-light);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-emerald);
  margin-bottom: 18px;
}

/* --- Buttons: large size used by cart/checkout/newsletter ---------------- */
.btn-lg { padding: 18px 34px; font-size: 1.02rem; }

/* --- Home: family-shop card variant -------------------------------------- */
.shop-catalog-section { background-color: var(--bg-cream); }
.shop-card .shop-cover-wrap { aspect-ratio: 1 / 1; }
.shop-offer-grid.shop-cover-wrap { background: var(--sage-subtle); }

/* --- Responsive ---------------------------------------------------------- */
@media (max-width: 900px) {
  .product-layout { grid-template-columns: 1fr; gap: 28px; }
  .product-gallery { position: static; }
  .product-detail-grid { grid-template-columns: 1fr; gap: 28px; }
  .cart-layout { grid-template-columns: 1fr; gap: 24px; }
  .cart-summary { position: static; }
  .product-main-img { max-width: 420px; margin: 0 auto; }
}

@media (max-width: 560px) {
  .bookstore-hero { padding: 40px 0; }
  .cart-line {
    grid-template-columns: 60px 1fr;
    grid-template-areas: "img info" "total total";
    row-gap: 10px;
  }
  .cart-line-img { width: 60px; height: 78px; grid-area: img; }
  .cart-line-info { grid-area: info; }
  .cart-line-total { grid-area: total; text-align: right; }
  .cart-line-controls { flex-direction: column; align-items: flex-start; }
}

/* ==========================================================================
   Mobile navigation
   Below 860px the horizontal nav is replaced by a toggle panel. Above it the
   original desktop row is untouched. The dropdowns on touch open on tap (the
   click handler in site.js), and on desktop via :hover and :focus-within.
   ========================================================================== */
.header-brand-wrap {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  background: var(--surface, #FAF6EE);
  border: 1px solid rgba(15, 56, 44, 0.18);
  border-radius: var(--radius-sm, 6px);
  padding: 8px 12px;
  cursor: pointer;
  font-weight: 700;
  color: var(--primary-emerald-dark, #09241c);
  transition: all 0.2s ease;
  user-select: none;
}

.nav-toggle:hover,
.nav-toggle.is-active {
  background: var(--primary-emerald, #0F382C);
  color: var(--gold-accent, #d4af37);
  border-color: var(--primary-emerald, #0F382C);
}

.nav-toggle-box {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 20px;
  height: 16px;
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle.is-active .nav-toggle-bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.nav-toggle-label {
  font-size: 0.85rem;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  font-weight: 700;
}

.desktop-search-form {
  display: flex;
}

.desktop-header-actions {
  display: flex;
}

.mobile-header-actions {
  display: none;
}

.mobile-header-cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  color: var(--primary-emerald-dark, #09241c);
  padding: 8px;
  border-radius: var(--radius-sm, 6px);
  background: rgba(15, 56, 44, 0.05);
  text-decoration: none;
}

.mobile-cart-pill {
  position: absolute;
  top: -3px;
  right: -5px;
  font-size: 0.7rem;
  padding: 1px 6px;
  font-weight: 700;
}

.mobile-nav-search-item {
  display: none;
}

.mobile-search-form {
  width: 100%;
  max-width: none;
  margin: 0;
}

.mobile-nav-cta-item {
  display: none;
}

.mobile-nav-cta-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 12px 18px;
  font-weight: 700;
  font-size: 0.95rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  text-align: center;
  box-shadow: 0 4px 14px rgba(212, 175, 55, 0.25);
  box-sizing: border-box;
}

.mobile-nav-cart-item {
  display: none;
}

.mobile-nav-cart-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 12px 16px;
  background: var(--surface, #FAF6EE);
  border: 1px solid rgba(15, 56, 44, 0.15);
  border-radius: var(--radius-sm, 6px);
  color: var(--primary-emerald-dark, #09241c);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.mobile-nav-cart-btn:hover {
  background: rgba(15, 56, 44, 0.06);
  border-color: var(--gold-accent, #d4af37);
  color: var(--primary-emerald, #0F382C);
}

.mobile-nav-cart-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mobile-nav-cart-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.mobile-nav-cart-arrow {
  color: var(--gold-accent, #d4af37);
  font-weight: 700;
  font-size: 1.05rem;
}

.mobile-nav-utility-item {
  display: none;
}

.mobile-nav-promo {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  background: rgba(212, 175, 55, 0.1);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: var(--radius-sm, 6px);
  margin-bottom: 12px;
  font-size: 0.85rem;
  color: var(--primary-emerald-dark, #09241c);
}

.mobile-nav-promo-link {
  color: var(--primary-emerald-dark, #09241c);
  text-decoration: none;
  font-weight: 500;
}

.mobile-nav-promo-link strong {
  color: var(--primary-emerald, #0F382C);
}

.mobile-nav-promo-link:hover {
  color: var(--gold-accent, #d4af37);
}

.mobile-nav-utility-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 20px;
  padding-top: 14px;
  margin-top: 10px;
  border-top: 1px solid rgba(15, 56, 44, 0.1);
  font-size: 0.88rem;
}

.mobile-nav-utility-link {
  color: var(--primary-emerald-dark);
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Keyboard accessibility for desktop dropdowns: opening on focus, not only
   hover, so a keyboard user can reach the submenu links. */
.nav-item:focus-within > .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
/* Touch / click-open state set by site.js. */
.nav-item.is-open > .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

@media (max-width: 1024px) {
  /* Remove utility bar on mobile and tablet */
  .top-utility-bar { display: none !important; }

  .nav-container { flex-wrap: wrap; padding: 0; }
  .nav-toggle { display: inline-flex; }

  .desktop-search-form { display: none !important; }
  .desktop-header-actions { display: none !important; }
  .mobile-header-actions { display: flex; align-items: center; margin-left: auto; }

  /* Mobile/tablet header bar layout */
  .main-header-container {
    flex-wrap: nowrap;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
  }
  .main-header-bar { padding: 12px 0; }
  .header-brand-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
  }
  .logo { justify-content: flex-start; }
  .logo-img { max-height: 52px; max-width: 220px; }

  .main-nav-bar {
    position: relative;
    background: transparent;
    padding: 0;
    border: none;
  }

  .main-nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
    background: var(--bg-cream, #FAF6EE);
    border-bottom: 3px solid var(--gold-accent, #d4af37);
    box-shadow: 0 16px 36px rgba(9, 36, 28, 0.22);
    padding: 16px 20px 24px;
    gap: 10px;
    z-index: 1000;
  }
  .main-nav-links.is-open { display: flex; }

  .mobile-nav-search-item {
    display: block;
    width: 100%;
    margin-bottom: 8px;
  }
  .mobile-nav-cta-item {
    display: block;
    width: 100%;
    margin-bottom: 8px;
  }
  .mobile-nav-cart-item {
    display: block;
    width: 100%;
    margin-bottom: 8px;
  }
  .mobile-nav-utility-item {
    display: block;
    width: 100%;
  }

  .main-nav-links .nav-item {
    width: 100%;
    border-top: 1px solid rgba(15, 56, 44, 0.08);
  }
  .main-nav-links .nav-item > .nav-link {
    padding: 12px 6px;
    font-size: 0.98rem;
    font-weight: 600;
    color: var(--primary-emerald-dark);
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  /* Dropdowns become inline accordions rather than floating panels. */
  .main-nav-links .nav-dropdown {
    position: static;
    width: 100%;
    opacity: 1;
    visibility: visible;
    transform: none;
    display: none;
    box-shadow: none;
    border: none;
    border-top: 1px solid rgba(15, 56, 44, 0.08);
    border-radius: 0;
    padding: 4px 0 8px 10px;
    background: rgba(15, 56, 44, 0.03);
  }
  .main-nav-links .nav-item.is-open > .nav-dropdown,
  .main-nav-links .nav-item:focus-within > .nav-dropdown { display: block; }
  .dropdown-item { padding: 10px 8px; }

  /* Utility bar adjustments on tablet */
  .utility-container {
    flex-wrap: wrap;
    gap: 8px 16px;
    justify-content: space-between;
    align-items: center;
  }
  .utility-left, .utility-right {
    flex-wrap: nowrap;
    align-items: center;
    gap: 10px;
  }
  .utility-left .utility-divider,
  .utility-right .utility-divider { display: inline-block; }

  /* Footer: 4 columns collapse to a single stack. */
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
}

@media (max-width: 680px) {
  .utility-promo { display: none; }
  .utility-left .utility-divider:first-of-type { display: none; }
}

@media (max-width: 480px) {
  .top-utility-bar { padding: 5px 0; font-size: 0.78rem; }
  .utility-container { justify-content: center; gap: 6px 12px; }
  .utility-left, .utility-right { gap: 8px; }
  .nav-toggle { padding: 8px 10px; }
  .nav-toggle-label { display: none; }
  .logo-img { max-height: 44px; max-width: 180px; }
}

/* ==========================================================================
   Responsive Refinements & Touch Optimization (Mobile & Small Viewports)
   ========================================================================== */
@media (max-width: 600px) {
  /* Search input label hiding: preserve icon, maximize text input width */
  .header-search-btn span {
    display: none;
  }
  .header-search-btn {
    padding: 10px 14px;
  }
  .search-category-select {
    padding: 8px 8px;
    font-size: 0.78rem;
    max-width: 110px;
  }
  .header-search-input {
    font-size: 0.82rem;
    padding: 8px 10px;
  }
  /* Carousel arrows on mobile: hide side arrows, rely on touch swipe & pagination dots */
  .carousel-btn-prev,
  .carousel-btn-next {
    display: none;
  }
  /* Catalog header filters full-width stacking */
  .catalog-header select {
    width: 100% !important;
  }
}

@media (max-width: 480px) {
  /* Container margin tightening on narrow devices (iPhone SE, 320px–375px) */
  .container {
    padding: 0 16px;
  }
  /* Main header actions reflow */
  .main-header-actions {
    display: flex;
    width: 100%;
    gap: 8px;
  }
  .main-header-actions .btn {
    flex: 1;
    text-align: center;
    padding: 10px 12px;
    font-size: 0.82rem;
  }
}

/* --- Product: Book Edition Selection ------------------------------------- */
.edition-selection-box {
  margin: 16px 0;
}
.edition-choice-btn {
  text-align: left;
  padding: 10px 12px;
  border-radius: var(--radius-md, 8px);
  cursor: pointer;
  transition: all 0.2s ease;
}

/* --- Visual Page Builder Content ---------------------------------------- */
.page-builder-content {
  width: 100%;
}

/* ==========================================================================
   Account Section & Left Sidebar Layout
   ========================================================================== */

.account-shell {
  display: flex;
  gap: 32px;
  align-items: flex-start;
  margin-top: 24px;
}

.account-sidebar {
  width: 270px;
  flex-shrink: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 24px 18px;
  box-shadow: var(--shadow-subtle);
  position: sticky;
  top: 90px;
}

.account-user-card {
  padding-bottom: 18px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border-light);
}

.account-user-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.account-user-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary-emerald);
  color: var(--gold-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  flex-shrink: 0;
  border: 2px solid var(--gold-accent);
}

.account-user-name {
  font-weight: 700;
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.3;
  word-break: break-word;
}

.account-user-email {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.3;
  word-break: break-all;
}

.account-user-status {
  margin-top: 8px;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: 5px;
}

.account-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.account-nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.92rem;
  font-weight: 500;
  text-decoration: none;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.account-nav-link svg {
  flex-shrink: 0;
  color: var(--text-secondary);
  transition: color var(--transition-fast), stroke var(--transition-fast);
}

.account-nav-link:hover {
  background: var(--sage-subtle);
  color: var(--primary-emerald);
}

.account-nav-link:hover svg {
  color: var(--primary-emerald);
}

.account-nav-link.active {
  background: var(--primary-emerald);
  color: #FFFFFF;
  font-weight: 600;
}

.account-nav-link.active svg {
  color: var(--gold-accent);
  stroke: var(--gold-accent);
}

.account-nav-badge {
  margin-left: auto;
  font-size: 0.72rem;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: var(--sage-subtle);
  color: var(--primary-emerald);
  font-weight: 600;
}

.account-nav-link.active .account-nav-badge {
  background: rgba(255, 255, 255, 0.2);
  color: #FFFFFF;
}

.account-nav-logout-form {
  margin: 14px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--border-light);
}

.account-nav-logout-btn {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 500;
  font-family: inherit;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.account-nav-logout-btn:hover {
  background: rgba(192, 57, 43, 0.08);
  color: #C0392B;
}

.account-nav-logout-btn:hover svg {
  color: #C0392B;
}

.account-content {
  flex: 1;
  min-width: 0;
}

@media (max-width: 900px) {
  .account-shell {
    flex-direction: column;
    gap: 20px;
  }
  .account-sidebar {
    width: 100%;
    position: static;
    padding: 16px;
  }
  .account-nav {
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px;
  }
  .account-nav-link {
    padding: 8px 14px;
    font-size: 0.86rem;
    border-radius: var(--radius-full);
    background: var(--bg-cream);
  }
  .account-nav-link.active {
    background: var(--primary-emerald);
    color: #FFFFFF;
  }
  .account-nav-logout-form {
    margin: 8px 0 0;
    padding-top: 0;
    border-top: none;
    display: inline-block;
  }
  .account-nav-logout-btn {
    width: auto;
    padding: 8px 14px;
    font-size: 0.86rem;
    border-radius: var(--radius-full);
    background: var(--bg-cream);
  }
}



