:root {
  --maroon: #7B1E1E;
  --maroon-light: #9A2E2E;
  --maroon-dark: #5C1414;
  --gold: #C9A227;
  --gold-light: #E0C158;
  --gold-dark: #A6821B;
  --ink: #2B2B2B;
  --ink-light: #5A5A5A;
  --cream: #FBF9F4;
  --white: #FFFFFF;
  --shadow-soft: 0 10px 40px -12px rgba(43,43,43,0.15);
  --shadow-card: 0 4px 24px -4px rgba(123,30,30,0.12);
  --shadow-gold: 0 8px 30px -6px rgba(201,162,39,0.35);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', 'Noto Sans Tamil', system-ui, sans-serif;
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, h4 { font-family: 'Playfair Display', 'Noto Sans Tamil', Georgia, serif; }

.tamil-text { font-family: 'Noto Sans Tamil', sans-serif; }

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

a { color: inherit; text-decoration: none; }

button { font-family: inherit; cursor: pointer; border: none; background: none; }

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (min-width: 768px) {
  .container { padding: 0 3rem; }
}

@media (min-width: 1280px) {
  .container { padding: 0 4rem; }
}

/* Scroll progress bar */
#scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 4px;
  width: 0%;
  background: linear-gradient(90deg, var(--maroon), var(--gold), var(--maroon));
  z-index: 60;
  transition: width 0.1s ease-out;
}

/* Navbar */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  height: 5rem;
  display: flex;
  align-items: center;
  transition: transform 0.35s ease-in-out, background-color 0.3s, box-shadow 0.3s;
  background: transparent;
}

#navbar.scrolled {
  background: rgba(251, 249, 244, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-soft);
}

#navbar.hidden { transform: translateY(-100%); }

.nav-inner {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: 'Playfair Display', 'Noto Sans Tamil', serif;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--maroon);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}
.logo svg { flex-shrink: 0; }
@media (max-width: 480px) {
  .logo { font-size: 0.95rem; }
}
.logo svg { color: var(--gold); }

.nav-links {
  display: none;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

@media (min-width: 1024px) {
  .nav-links { display: flex; }
}

.nav-links a {
  position: relative;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-light);
  padding: 0.5rem 0;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--maroon); }

.nav-links a.active { color: var(--maroon); }

.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: var(--gold);
}

.nav-toggle {
  display: block;
  color: var(--maroon);
}
@media (min-width: 1024px) { .nav-toggle { display: none; } }

.mobile-menu {
  display: none;
  background: rgba(251, 249, 244, 0.97);
  backdrop-filter: blur(10px);
  border-top: 1px solid rgba(123,30,30,0.1);
  flex-direction: column;
  padding: 1rem 1.5rem;
  gap: 1rem;
}
.mobile-menu.open { display: flex; }
.mobile-menu a { font-weight: 500; padding: 0.25rem 0; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 1.75rem;
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s ease;
}

.btn-primary {
  background: var(--maroon);
  color: var(--cream);
  box-shadow: var(--shadow-card);
}
.btn-primary:hover { background: var(--maroon-dark); box-shadow: var(--shadow-gold); }

.btn-outline {
  border: 2px solid var(--gold);
  color: var(--maroon);
}
.btn-outline:hover { background: var(--gold); color: var(--cream); }

/* Reveal animation */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }
.reveal-delay-4 { transition-delay: 0.32s; }
.reveal-delay-5 { transition-delay: 0.4s; }

/* Section heading */
.section-heading-wrap { text-align: center; margin-bottom: 4rem; position: relative; padding-bottom: 1rem; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold-dark);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
}
.section-heading {
  font-size: 2rem;
  color: var(--maroon);
  font-weight: 600;
}
@media (min-width: 768px) { .section-heading { font-size: 3rem; } }
.section-subheading {
  color: var(--ink-light);
  max-width: 640px;
  margin: 1rem auto 0;
}
.section-heading-wrap::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -14px;
  transform: translateX(-50%);
  width: 64px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

/* HERO */
#home {
  position: relative;
  min-height: auto;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-top: 5rem;
  padding-bottom: 2rem;
}
@media (min-width: 768px) {
  #home {
    min-height: 80vh;
    padding-bottom: 3rem;
  }
}
@media (max-width: 767px) {
  #home {
    align-items: flex-start;
    padding-top: 5.5rem;
    padding-bottom: 2rem;
  }
}
.hero-bg-texture {
  position: absolute;
  inset: 0;
  background-image: url('../textures/palm-leaf.svg');
  background-repeat: repeat;
  opacity: 0.06;
  pointer-events: none;
}
.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  align-items: center;
  width: 100%;
}
.hero-heading { order: 1; }
.hero-portrait-wrap { order: 2; }
.hero-cta { order: 3; }
@media (max-width: 767px) {
  .hero-heading { text-align: center; }
}

@media (min-width: 768px) {
  .hero-grid {
    padding-top: 4rem;
    padding-bottom: 4rem;
    row-gap: 0.75rem;
    column-gap: 3rem;
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "heading portrait"
      "cta portrait";
  }
  .hero-heading { grid-area: heading; order: initial; align-self: end; }
  .hero-portrait-wrap { grid-area: portrait; order: initial; }
  .hero-cta { grid-area: cta; order: initial; align-self: start; }
}
@media (min-width: 1024px) {
  .hero-grid { column-gap: 5rem; }
}
.hero-title {
  font-size: clamp(1.35rem, 6.2vw, 2.1rem);
  color: var(--maroon);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 0;
}
.hero-title-honorific {
  font-size: 0.62em;
  font-weight: 600;
}
@media (min-width: 768px) {
  .hero-title {
    font-size: clamp(1.8rem, 3.4vw, 3.2rem);
    white-space: nowrap;
    margin-bottom: 0;
  }
}
.hero-heading { margin-bottom: 0; }
.hero-tagline {
  color: var(--ink-light);
  font-size: 1.15rem;
  max-width: 32rem;
  margin-bottom: 2.5rem;
}
.hero-buttons { display: flex; flex-wrap: wrap; gap: 1rem; }

.hero-portrait-wrap {
  position: relative;
  display: flex;
  justify-content: center;
}
.hero-portrait-glow {
  position: absolute;
  inset: -0.75rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201,162,39,0.2), transparent 70%);
  filter: blur(16px);
}
@media (min-width: 768px) {
  .hero-portrait-glow {
    inset: -1.5rem;
    filter: blur(24px);
  }
}
.hero-portrait {
  position: relative;
  width: 11.5rem;
  height: 14rem;
  border-radius: 2rem;
  overflow: hidden;
  border: 4px solid var(--white);
  box-shadow: var(--shadow-soft);
  background: linear-gradient(135deg, rgba(123,30,30,0.08), rgba(201,162,39,0.12));
}
@media (min-width: 768px) {
  .hero-portrait {
    width: 18rem;
    height: 22rem;
    border-radius: 2.5rem;
  }
}
.hero-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.hero-portrait img.is-loaded { opacity: 1; }
.hero-badge {
  position: absolute;
  bottom: -0.65rem;
  right: -0.65rem;
  background: var(--gold);
  color: var(--white);
  border-radius: 0.75rem;
  padding: 0.4rem 0.7rem;
  font-family: 'Playfair Display', 'Noto Sans Tamil', serif;
  font-size: 0.65rem;
  white-space: nowrap;
  box-shadow: var(--shadow-gold);
}
@media (min-width: 768px) {
  .hero-badge {
    bottom: -1rem;
    right: -1rem;
    border-radius: 1rem;
    padding: 0.75rem 1.25rem;
    font-size: 0.9rem;
  }
}

/* Sections generic */
section { padding: 6rem 0; }
.bg-white { background: var(--white); }
.bg-cream { background: var(--cream); }
.bg-maroon { background: var(--maroon); color: var(--cream); position: relative; overflow: hidden; }

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 6rem;
}
@media (min-width: 768px) { .about-grid { grid-template-columns: 1fr 1fr; } }
.about-card {
  background: var(--cream);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: var(--shadow-soft);
  transition: box-shadow 0.3s;
}
.about-card:hover { box-shadow: var(--shadow-card); }
.about-card-head { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1rem; }
.about-icon {
  padding: 0.6rem;
  border-radius: 0.75rem;
  background: rgba(123,30,30,0.1);
  color: var(--maroon);
  display: flex;
}
.about-card h3 { color: var(--maroon); font-size: 1.25rem; font-weight: 600; }
.about-card p { color: var(--ink-light); }

.timeline-title { text-align: center; margin-bottom: 3rem; }
.timeline-title h3 { color: var(--maroon); font-size: 1.75rem; font-weight: 600; }

.timeline {
  position: relative;
  max-width: 48rem;
  margin: 0 auto;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 1rem;
  top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, var(--gold), rgba(123,30,30,0.3), var(--gold));
}
@media (min-width: 768px) {
  .timeline::before { left: 50%; transform: translateX(-50%); }
}
.timeline-items { display: flex; flex-direction: column; gap: 2.5rem; }
.timeline-item {
  position: relative;
  padding-left: 3rem;
}
@media (min-width: 768px) {
  .timeline-item { width: 50%; padding-left: 0; }
  .timeline-item.left { padding-right: 3rem; text-align: right; margin-right: 50%; }
  .timeline-item.right { padding-left: 3rem; margin-left: 50%; }
}
.timeline-dot {
  position: absolute;
  left: 0.6rem;
  top: 0.25rem;
  width: 1rem; height: 1rem;
  border-radius: 50%;
  background: var(--gold);
  border: 4px solid var(--white);
  box-shadow: var(--shadow-gold);
}
@media (min-width: 768px) {
  .timeline-item.left .timeline-dot { left: auto; right: -0.5rem; }
  .timeline-item.right .timeline-dot { left: -0.5rem; }
}
.timeline-card {
  background: var(--cream);
  border-radius: 0.75rem;
  padding: 1.25rem;
  box-shadow: var(--shadow-soft);
  display: inline-block;
  text-align: left;
}
.timeline-year { color: var(--gold-dark); font-family: 'Playfair Display', serif; font-weight: 700; }
.timeline-card h4 { color: var(--maroon); margin-top: 0.25rem; font-weight: 600; }
.timeline-card p { font-size: 0.9rem; color: var(--ink-light); margin-top: 0.25rem; }

/* Achievements */
.achievements-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
@media (min-width: 640px) { .achievements-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .achievements-grid { grid-template-columns: 1fr 1fr 1fr; } }
.achievement-card {
  background: var(--white);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: var(--shadow-soft);
  border: 1px solid transparent;
  transition: box-shadow 0.3s, border-color 0.3s, transform 0.3s;
}
.achievement-card:hover { box-shadow: var(--shadow-card); border-color: rgba(201,162,39,0.3); transform: translateY(-6px); }
.achievement-icon {
  width: 3.5rem; height: 3.5rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--maroon), var(--maroon-light));
  color: var(--gold);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-card);
}
.achievement-card .year { color: var(--gold-dark); font-family: 'Playfair Display', serif; font-weight: 700; font-size: 0.9rem; }
.achievement-card h3 { color: var(--maroon); font-size: 1.25rem; font-weight: 600; margin: 0.25rem 0 0.5rem; }
.achievement-card .org { font-size: 0.9rem; color: var(--ink-light); font-weight: 500; margin-bottom: 0.75rem; }
.achievement-card .desc { font-size: 0.9rem; color: var(--ink-light); }

/* Carousels (Books, Videos) */
.carousel-controls { display: none; justify-content: flex-end; gap: 0.75rem; margin-bottom: 1.5rem; }
@media (min-width: 768px) { .carousel-controls { display: flex; } }
.carousel-btn {
  padding: 0.75rem;
  border-radius: 50%;
  background: var(--cream);
  color: var(--maroon);
  box-shadow: var(--shadow-soft);
  transition: background 0.2s, color 0.2s;
  display: flex;
}
.carousel-btn:hover { background: var(--maroon); color: var(--cream); }
.bg-cream .carousel-btn, #videos .carousel-btn { background: var(--white); }

.carousel-track {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 1rem;
  scrollbar-width: none;
}
.carousel-track::-webkit-scrollbar { display: none; }

/* Book card */
.book-card {
  flex-shrink: 0;
  width: 16rem;
  scroll-snap-align: start;
  background: var(--cream);
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  text-align: left;
  transition: box-shadow 0.3s, transform 0.3s;
}
.book-card:hover { box-shadow: var(--shadow-card); transform: translateY(-10px); }
.book-cover { position: relative; width: 100%; height: 20rem; overflow: hidden; background: rgba(123,30,30,0.05); }
.book-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.book-card:hover .book-cover img { transform: scale(1.05); }
.book-info { padding: 1.25rem; }
.book-info h3 { color: var(--maroon); font-size: 1.1rem; font-weight: 600; margin-bottom: 0.25rem; }
.book-meta { font-size: 0.75rem; color: var(--gold-dark); font-weight: 600; margin-bottom: 0.5rem; }
.book-desc { font-size: 0.9rem; color: var(--ink-light); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Video card */
.video-card {
  flex-shrink: 0;
  width: 20rem;
  scroll-snap-align: start;
  background: var(--white);
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  text-align: left;
  transition: box-shadow 0.3s, transform 0.3s;
}
.video-card:hover { box-shadow: var(--shadow-card); transform: translateY(-8px); }
.video-thumb { position: relative; width: 100%; height: 11rem; overflow: hidden; background: rgba(0,0,0,0.05); }
.video-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.video-card:hover .video-thumb img { transform: scale(1.05); }
.video-play-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.2);
  display: flex; align-items: center; justify-content: center;
  color: var(--white);
  opacity: 0.85;
  transition: opacity 0.3s;
}
.video-card:hover .video-play-overlay { opacity: 1; }
.video-duration-badge {
  position: absolute; bottom: 0.5rem; right: 0.5rem;
  background: rgba(0,0,0,0.7); color: var(--white);
  font-size: 0.7rem; padding: 0.15rem 0.5rem; border-radius: 0.25rem;
}
.video-info { padding: 1.25rem; }
.video-info h3 { color: var(--maroon); font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.video-meta { display: flex; gap: 0.75rem; font-size: 0.75rem; color: var(--ink-light); }
.video-meta span { display: flex; align-items: center; gap: 0.25rem; }

/* Gallery masonry */
.gallery-grid {
  column-count: 2;
  column-gap: 1rem;
}
@media (min-width: 640px) { .gallery-grid { column-count: 3; } }
@media (min-width: 1024px) { .gallery-grid { column-count: 4; } }
.gallery-item {
  break-inside: avoid;
  margin-bottom: 1rem;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  position: relative;
  cursor: pointer;
  display: block;
  width: 100%;
}
.gallery-item img { width: 100%; height: auto; transition: transform 0.5s; }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item::after {
  content: "";
  position: absolute; inset: 0;
  background: rgba(123,30,30,0);
  transition: background 0.3s;
}
.gallery-item:hover::after { background: rgba(123,30,30,0.2); }

/* Quotes */
#quotes .section-heading, #quotes .eyebrow { color: var(--cream); }
#quotes .eyebrow { color: var(--gold-light); }
.quotes-bg-texture {
  position: absolute; inset: 0;
  background-image: url('../textures/palm-leaf.svg');
  background-repeat: repeat;
  opacity: 0.05;
  pointer-events: none;
}
.quote-wrap {
  position: relative;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.quote-icon { position: absolute; top: -1.5rem; left: 50%; transform: translateX(-50%); color: rgba(201,162,39,0.3); }
.quote-slide { opacity: 0; transition: opacity 0.6s ease; position: absolute; padding: 0 1rem; }
.quote-slide.active { opacity: 1; position: relative; }
.quote-tamil { font-family: 'Noto Sans Tamil', sans-serif; font-size: 1.5rem; font-weight: 600; margin-bottom: 1.25rem; }
@media (min-width: 768px) { .quote-tamil { font-size: 1.85rem; } }
.quote-translation { color: rgba(251,249,244,0.8); font-style: italic; font-size: 1.05rem; margin-bottom: 0.75rem; }
.quote-source { color: var(--gold); font-size: 0.85rem; font-weight: 600; }
.quote-controls { display: flex; align-items: center; justify-content: center; gap: 1.5rem; margin-top: 2.5rem; }
.quote-dots { display: flex; gap: 0.5rem; }
.quote-dot { width: 0.6rem; height: 0.6rem; border-radius: 50%; background: rgba(251,249,244,0.3); transition: background 0.2s; }
.quote-dot.active { background: var(--gold); }
.quote-nav-btn { padding: 0.75rem; border-radius: 50%; background: rgba(251,249,244,0.1); color: var(--cream); transition: background 0.2s, color 0.2s; }
.quote-nav-btn:hover { background: var(--gold); color: var(--maroon); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 2.5rem; }
@media (min-width: 1024px) { .contact-grid { grid-template-columns: 1fr 1fr; } }
.contact-card { background: var(--white); border-radius: 1rem; padding: 2rem; box-shadow: var(--shadow-soft); display: flex; flex-direction: column; gap: 1.5rem; }
.contact-row { display: flex; align-items: center; gap: 1rem; }
.contact-row-icon { padding: 0.75rem; border-radius: 0.75rem; background: rgba(123,30,30,0.1); color: var(--maroon); flex-shrink: 0; display: flex; }
.contact-row .label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink-light); }
.contact-row .value { font-weight: 500; }
.contact-socials { display: flex; gap: 0.75rem; padding-top: 0.5rem; }
.social-btn { padding: 0.75rem; border-radius: 50%; background: var(--maroon); color: var(--cream); transition: background 0.2s; display: flex; }
.social-btn:hover { background: var(--gold); }
.map-wrap { border-radius: 1rem; overflow: hidden; box-shadow: var(--shadow-soft); height: 16rem; }
.map-wrap iframe { width: 100%; height: 100%; border: 0; }

.contact-form { background: var(--white); border-radius: 1rem; padding: 2rem; box-shadow: var(--shadow-soft); display: flex; flex-direction: column; gap: 1.25rem; }
.form-group label { display: block; font-size: 0.9rem; font-weight: 500; margin-bottom: 0.4rem; }
.form-group input, .form-group textarea {
  width: 100%;
  border: 1px solid rgba(43,43,43,0.1);
  border-radius: 0.75rem;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 0.95rem;
  transition: box-shadow 0.2s, border-color 0.2s;
}
.form-group input:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,162,39,0.25);
}
.form-group textarea { resize: none; }
.form-submit {
  width: 100%;
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  background: var(--maroon); color: var(--cream);
  padding: 0.9rem 1.5rem; border-radius: 999px; font-weight: 500;
  box-shadow: var(--shadow-card);
  transition: background 0.2s;
}
.form-submit:hover { background: var(--maroon-dark); }
.form-success { text-align: center; font-size: 0.9rem; color: #15803d; }

/* Footer */
footer { background: var(--maroon); color: var(--cream); }
.footer-inner {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 1.5rem;
  padding-top: 3.5rem;
  padding-bottom: 3.5rem;
}
.footer-inner h3 { font-size: 1.5rem; }
.footer-inner .tagline { color: rgba(251,249,244,0.7); max-width: 36rem; font-size: 0.9rem; }
.footer-socials { display: flex; gap: 1.25rem; }
.footer-socials a { padding: 0.6rem; border-radius: 50%; background: rgba(251,249,244,0.1); transition: background 0.2s, color 0.2s; display: flex; }
.footer-socials a:hover { background: var(--gold); color: var(--maroon); }
.footer-divider { width: 100%; height: 1px; background: rgba(251,249,244,0.15); }
.footer-bottom { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; font-size: 0.75rem; color: rgba(251,249,244,0.6); }
@media (min-width: 640px) { .footer-bottom { flex-direction: row; } }
.footer-bottom .heart { display: inline-flex; align-items: center; gap: 0.25rem; }
.footer-bottom svg { fill: var(--gold); color: var(--gold); }

/* Modal */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100;
  display: none;
  align-items: center; justify-content: center;
  padding: 1rem;
}
.modal-overlay.open { display: flex; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(43,43,43,0.7); backdrop-filter: blur(4px); }
.modal-box {
  position: relative;
  background: var(--cream);
  border-radius: 1rem;
  box-shadow: 0 25px 60px rgba(0,0,0,0.3);
  max-width: 48rem; width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalIn 0.3s ease-out;
}
@keyframes modalIn { from { opacity: 0; transform: scale(0.94) translateY(20px); } to { opacity: 1; transform: scale(1) translateY(0); } }
.modal-close {
  position: absolute; top: 1rem; right: 1rem; z-index: 10;
  background: rgba(255,255,255,0.9);
  color: var(--maroon);
  border-radius: 50%;
  padding: 0.5rem;
  box-shadow: var(--shadow-soft);
  display: flex;
}
.modal-close:hover { background: var(--white); }

.book-modal-grid { display: grid; grid-template-columns: 1fr; }
@media (min-width: 768px) { .book-modal-grid { grid-template-columns: 1fr 1fr; } }
.book-modal-cover { position: relative; min-height: 280px; background: rgba(123,30,30,0.05); }
.book-modal-cover img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.book-modal-body { padding: 2rem; }
.book-modal-body .meta { font-size: 0.75rem; color: var(--gold-dark); font-weight: 600; margin-bottom: 0.5rem; }
.book-modal-body h3 { font-size: 1.5rem; color: var(--maroon); font-weight: 700; margin-bottom: 1rem; }
.book-modal-body .synopsis { color: var(--ink-light); margin-bottom: 1.25rem; }
.book-modal-body .awards-title { font-size: 0.9rem; font-weight: 600; color: var(--maroon); margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.5rem; }
.book-modal-body ul { list-style: disc; padding-left: 1.25rem; color: var(--ink-light); font-size: 0.9rem; margin-bottom: 1.25rem; }
.book-modal-body .isbn { font-size: 0.75rem; color: var(--ink-light); margin-bottom: 1.25rem; }

.video-modal-body { padding: 1rem; }
.video-embed-wrap { position: relative; width: 100%; aspect-ratio: 16/9; border-radius: 0.75rem; overflow: hidden; }
.video-embed-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-modal-title { font-size: 1.25rem; color: var(--maroon); font-weight: 600; margin-top: 1rem; padding: 0 0.5rem; }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(0,0,0,0.9);
  display: none;
  align-items: center; justify-content: center;
  padding: 1rem;
}
.lightbox.open { display: flex; }
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  color: rgba(255,255,255,0.8);
  transition: color 0.2s;
}
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { color: var(--white); }
.lightbox-close { top: 1.5rem; right: 1.5rem; }
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }
@media (min-width: 768px) { .lightbox-prev { left: 2rem; } .lightbox-next { right: 2rem; } }
.lightbox-content { max-width: 56rem; max-height: 85vh; width: 100%; text-align: center; }
.lightbox-content img { max-height: 85vh; width: auto; max-width: 100%; margin: 0 auto; border-radius: 0.5rem; object-fit: contain; }
.lightbox-caption { color: rgba(255,255,255,0.7); font-size: 0.9rem; margin-top: 1rem; }

/* Scrollbar */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--cream); }
::-webkit-scrollbar-thumb { background: rgba(123,30,30,0.4); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: rgba(123,30,30,0.6); }

::selection { background: rgba(201,162,39,0.3); color: var(--maroon); }
