/* KidSprout public marketing v2 — color logo palette, mobile-first */
:root {
  --leaf: #7a986c;
  --leaf-light: #8da980;
  --book: #9c6d3e;
  --book-light: #c99a63;
  --gold: #deb169;
  --bg: #faf6ef;
  --btn: #546848;
  --btn-hover: #44553a;
  --heading: #3a3228;
  --ink: #3a3228;
  --muted: #6b6258;
  --line: #e8dfd2;
  --white: #ffffff;
  --soft: #f3ebe0;
  --shadow: 0 10px 28px rgba(58, 50, 40, 0.08);
  --radius: 18px;
  --max: 1080px;
  --header-h: 84px;
  --font: "PingFang HK", "Noto Sans TC", "Hiragino Sans CNS", "Microsoft JhengHei", system-ui, -apple-system, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 16px;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--btn); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--book); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--btn);
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 1000;
}
.skip-link:focus { left: 0.75rem; top: 0.75rem; }

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 246, 239, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--heading);
}
.brand img,
.brand-logo {
  width: auto;
  height: 64px;
  max-height: 64px;
  object-fit: contain;
  object-position: left center;
  display: block;
}
.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}
.brand-text strong {
  font-size: 1rem;
  color: var(--heading);
}
.brand-text span {
  font-size: 0.75rem;
  color: var(--leaf);
  font-weight: 600;
}

.nav-toggle {
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--white);
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  padding: 0;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--heading);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.site-nav {
  display: none;
  position: absolute;
  left: 0;
  right: 0;
  top: var(--header-h);
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  padding: 0.75rem 1rem 1.25rem;
  flex-direction: column;
  gap: 0.35rem;
  box-shadow: var(--shadow);
}
.site-nav.open { display: flex; }
.site-nav a {
  text-decoration: none;
  color: var(--ink);
  padding: 0.85rem 1rem;
  border-radius: 12px;
  font-weight: 600;
}
.site-nav a:hover,
.site-nav a:focus-visible {
  background: var(--soft);
  color: var(--heading);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 44px;
  padding: 0.7rem 1.15rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}
.btn:active { transform: scale(0.98); }
.btn-primary {
  background: var(--btn);
  color: #fff;
  box-shadow: 0 8px 18px rgba(84, 104, 72, 0.25);
}
.btn-primary:hover { background: var(--btn-hover); color: #fff; }
.btn-ghost {
  background: transparent;
  color: var(--btn);
  border-color: rgba(84, 104, 72, 0.3);
}
.btn-ghost:hover { background: var(--soft); color: var(--heading); }
.btn-light {
  background: #fff;
  color: var(--heading);
}
.btn-light:hover { background: var(--soft); color: var(--heading); }
.btn-lg { min-height: 50px; padding-inline: 1.4rem; font-size: 1.02rem; }
.btn-nav {
  margin-top: 0.35rem;
  width: 100%;
  justify-content: center;
}

/* Social icons row */
.social-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
}
.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 42px;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--heading);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
  box-shadow: 0 2px 8px rgba(58, 50, 40, 0.04);
}
.social-btn:hover {
  border-color: var(--leaf-light);
  color: var(--heading);
  background: var(--soft);
}
.social-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}
.social-btn.wa { border-color: rgba(37, 211, 102, 0.35); }
.social-btn.ig { border-color: rgba(225, 48, 108, 0.3); }
.social-btn.threads { border-color: rgba(0, 0, 0, 0.18); }
.social-btn.xhs { border-color: rgba(255, 36, 66, 0.3); }
.social-row.compact .social-btn span.label { display: none; }
.social-row.compact .social-btn {
  width: 42px;
  height: 42px;
  padding: 0;
  justify-content: center;
}

/* Hero */
.hero {
  padding: 2.25rem 0 2rem;
  background:
    radial-gradient(120% 80% at 8% 0%, rgba(141, 169, 128, 0.28), transparent 55%),
    radial-gradient(90% 70% at 100% 8%, rgba(222, 177, 105, 0.22), transparent 50%),
    var(--bg);
}
.hero-inner {
  display: grid;
  gap: 1.25rem;
  align-items: center;
}
.hero-copy { max-width: 720px; }
.eyebrow {
  display: inline-block;
  margin: 0 0 0.85rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(122, 152, 108, 0.18);
  color: var(--btn);
  font-size: 0.88rem;
  font-weight: 700;
}
.hero h1 {
  margin: 0 0 0.55rem;
  font-size: clamp(1.85rem, 6vw, 2.85rem);
  line-height: 1.22;
  letter-spacing: -0.02em;
  color: var(--heading);
}
.hero-slogan {
  margin: 0 0 0.9rem;
  font-size: clamp(1.15rem, 3.5vw, 1.45rem);
  font-weight: 800;
  color: var(--leaf);
  letter-spacing: 0.04em;
}
.hero-lead {
  margin: 0 0 1.4rem;
  color: var(--muted);
  font-size: 1.05rem;
}
.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.hero-note {
  margin: 0.85rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Trust strip */
.band { border-block: 1px solid var(--line); background: var(--white); }
.trust { padding: 1.1rem 0; }
.trust-grid {
  display: grid;
  gap: 0.85rem;
}
.trust-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  background: var(--soft);
}
.trust-item strong {
  color: var(--heading);
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}
.trust-item span {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 400;
  line-height: 1.5;
}

/* Sections */
.section { padding: 3rem 0; }
.section-soft { background: var(--white); border-block: 1px solid var(--line); }
.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 1.75rem;
}
.section-head.left { text-align: left; margin-left: 0; }
.section-head h2 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.5rem, 4vw, 2rem);
  color: var(--heading);
}
.section-head p { margin: 0; color: var(--muted); }

.card-grid {
  display: grid;
  gap: 1.1rem;
}
.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.25rem 1.4rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.card h3 {
  margin: 0;
  font-size: 1.35rem;
  color: var(--heading);
}
.card p { margin: 0; color: var(--muted); }
.card-badge {
  display: inline-flex;
  align-self: flex-start;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: rgba(222, 177, 105, 0.28);
  color: var(--book);
  font-size: 0.82rem;
  font-weight: 800;
}
.card-badge-alt {
  background: rgba(122, 152, 108, 0.2);
  color: var(--btn);
}
.card-list {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--ink);
}
.card-list li { margin-bottom: 0.35rem; }
.card-price {
  margin-top: auto !important;
  font-weight: 700;
  color: var(--btn) !important;
}
.card .btn { align-self: flex-start; margin-top: 0.25rem; }

/* About */
.about-grid {
  display: grid;
  gap: 1.5rem;
}
.about-points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.9rem;
}
.about-points li {
  background: var(--soft);
  border-radius: 14px;
  padding: 1rem 1.1rem;
  display: grid;
  gap: 0.2rem;
}
.about-points strong { color: var(--heading); }
.about-points span { color: var(--muted); }
.about-card {
  background: linear-gradient(160deg, rgba(141, 169, 128, 0.18), #fff 55%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem 1.25rem;
  box-shadow: var(--shadow);
  display: grid;
  gap: 0.85rem;
  align-content: start;
}
.about-logo { width: 140px; margin-inline: auto; }
.about-legal {
  margin: 0;
  font-weight: 700;
  color: var(--heading);
  line-height: 1.45;
  text-align: center;
}
.about-card p { margin: 0; color: var(--muted); text-align: center; }
.about-card .btn { justify-self: center; }

/* Teacher placeholder */
.teacher-card {
  background: var(--white);
  border: 1px dashed var(--book-light);
  border-radius: var(--radius);
  padding: 2rem 1.25rem;
  text-align: center;
  box-shadow: var(--shadow);
  max-width: 720px;
  margin-inline: auto;
}
.teacher-card p {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}
.teacher-card .placeholder-label {
  display: inline-block;
  margin-bottom: 0.75rem;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  background: rgba(156, 109, 62, 0.12);
  color: var(--book);
  font-weight: 800;
  font-size: 0.85rem;
}

/* Gallery placeholders */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.85rem;
}
.gallery-slot {
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  border: 1px dashed var(--leaf-light);
  background:
    linear-gradient(135deg, rgba(122, 152, 108, 0.08), rgba(222, 177, 105, 0.1));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.9rem;
  text-align: center;
  padding: 0.75rem;
}

/* Contact + map */
.contact-grid {
  display: grid;
  gap: 1rem;
}
.contact-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}
.contact-card h3 {
  margin: 0 0 0.55rem;
  color: var(--heading);
}
.contact-card p { margin: 0 0 0.75rem; color: var(--muted); }
.contact-card .phone {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--heading);
  letter-spacing: 0.02em;
}
.text-link {
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
.muted { color: var(--muted) !important; font-size: 0.92rem; }

.map-wrap {
  margin-top: 1.25rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: var(--soft);
}
.map-wrap iframe {
  display: block;
  width: 100%;
  height: 280px;
  border: 0;
}
.map-caption {
  margin: 0.75rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
  text-align: center;
}

/* CTA band */
.cta-band {
  background: linear-gradient(135deg, var(--btn), #3f4f36);
  color: #fff;
  padding: 2.75rem 0;
}
.cta-inner {
  text-align: center;
  display: grid;
  gap: 0.75rem;
  justify-items: center;
}
.cta-inner h2 {
  margin: 0;
  font-size: clamp(1.35rem, 4vw, 1.9rem);
}
.cta-inner p { margin: 0; opacity: 0.92; max-width: 36rem; }

/* Footer */
.site-footer {
  background: #2a241c;
  color: rgba(255,255,255,0.82);
  padding: 2rem 0 5.5rem;
}
.footer-inner {
  display: grid;
  gap: 1.25rem;
}
.footer-brand {
  display: grid;
  gap: 0.75rem;
}
.footer-brand img,
.footer-logo {
  width: 140px;
  max-width: min(140px, calc(55vw - 2rem));
  height: auto;
  object-fit: contain;
  object-position: center;
  display: block;
}
.footer-legal {
  margin-top: 0.15rem;
  opacity: 0.92;
  line-height: 1.45;
}
.footer-brand p,
.footer-meta p {
  margin: 0 0 0.45rem;
  font-size: 0.92rem;
}
.footer-meta a { color: #fff; }
.footer-social .social-btn {
  background: rgba(255,255,255,0.06);
  border-color: rgba(255,255,255,0.18);
  color: #fff;
}
.footer-social .social-btn:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.tiny { opacity: 0.7; font-size: 0.82rem !important; }

/* Floating WhatsApp */
.fab-wa {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 60;
  background: #25d366;
  color: #fff;
  text-decoration: none;
  font-weight: 800;
  border-radius: 999px;
  min-height: 48px;
  padding: 0.75rem 1.1rem;
  box-shadow: 0 10px 24px rgba(0,0,0,0.22);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.fab-wa svg { width: 22px; height: 22px; }
.fab-wa:hover { color: #fff; filter: brightness(1.05); }

/* ===== Desktop / tablet breakpoints ===== */
@media (min-width: 640px) {
  .hero-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .trust-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .trust-item {
    background: transparent;
    padding: 0.35rem 0.25rem;
  }
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .map-wrap iframe { height: 340px; }
}

@media (min-width: 860px) {
  .brand img,
  .brand-logo { height: 68px; max-height: 68px; width: auto; }
  .nav-toggle { display: none; }
  .site-nav {
    display: flex;
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 0.15rem;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
  }
  .site-nav a {
    padding: 0.55rem 0.7rem;
    font-size: 0.92rem;
  }
  .btn-nav {
    width: auto;
    margin-top: 0;
    margin-left: 0.35rem;
  }
  .hero {
    padding: 3.5rem 0 3rem;
  }
  .hero-inner {
    max-width: 760px;
  }
  .about-grid {
    grid-template-columns: 1.35fr 0.9fr;
    align-items: start;
    gap: 2rem;
  }
  .contact-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .footer-inner {
    grid-template-columns: 1fr 1.2fr;
    align-items: start;
    gap: 2rem;
  }
  .site-footer { padding-bottom: 2.5rem; }
  .fab-wa { right: 1.4rem; bottom: 1.4rem; }
}

@media (min-width: 1100px) {
  .hero-copy { max-width: 760px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* ===== v2.2: philosophy + courses + map placeholder ===== */
.philosophy-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem 1.6rem;
  box-shadow: var(--shadow);
  max-width: 760px;
  margin-inline: auto;
}
.philosophy-title {
  margin: 0 0 1rem;
  font-size: clamp(1.2rem, 3.5vw, 1.55rem);
  color: var(--heading);
  line-height: 1.4;
  text-align: center;
}
.philosophy-body {
  display: grid;
  gap: 0.95rem;
}
.philosophy-body p {
  margin: 0;
  color: var(--ink);
  font-size: 1.02rem;
  line-height: 1.75;
}

.course-group-title {
  margin: 2.25rem 0 0.85rem;
  font-size: clamp(1.15rem, 3vw, 1.4rem);
  color: var(--heading);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem;
}
.course-group-title span {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}
.course-group-lead {
  margin: 0 0 1rem;
  color: var(--muted);
}

.course-highlight,
.package-banner {
  display: grid;
  gap: 1.1rem;
  background: linear-gradient(160deg, rgba(141, 169, 128, 0.16), #fff 50%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
  align-items: center;
}
.course-highlight-text h3,
.package-banner h3 {
  margin: 0 0 0.55rem;
  color: var(--heading);
  font-size: 1.35rem;
}
.course-highlight-text p,
.package-banner > div > p {
  margin: 0 0 0.75rem;
  color: var(--muted);
}
.tiny-note { font-size: 0.88rem !important; }
.course-flyer-thumb {
  display: block;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  max-width: 220px;
  margin-inline: auto;
  box-shadow: 0 6px 16px rgba(58, 50, 40, 0.08);
}
.course-flyer-thumb img {
  width: 100%;
  height: auto;
}
.course-card .flyer-link {
  margin-top: 0.15rem;
  align-self: flex-start;
  font-size: 0.92rem;
}
.flyer-row {
  margin: 1rem 0 0;
  text-align: center;
}
.wong-profile {
  background: var(--soft);
  border-radius: 14px;
  padding: 0.95rem 1.1rem;
  margin-bottom: 1rem;
}
.wong-profile p { margin: 0; color: var(--ink); font-size: 0.95rem; }

.map-placeholder {
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1rem;
}
.map-placeholder-inner {
  text-align: center;
  display: grid;
  gap: 0.65rem;
  justify-items: center;
  max-width: 28rem;
}
.map-placeholder-inner p { margin: 0; color: var(--muted); }
.map-placeholder-inner .placeholder-label {
  display: inline-block;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  background: rgba(156, 109, 62, 0.12);
  color: var(--book);
  font-weight: 800;
  font-size: 0.85rem;
}

@media (min-width: 640px) {
  .course-cards {
    grid-template-columns: repeat(2, 1fr);
  }
  .course-highlight,
  .package-banner {
    grid-template-columns: 1.4fr 0.7fr;
    gap: 1.25rem;
  }
  .course-flyer-thumb { margin-inline: 0; max-width: 240px; justify-self: end; }
}

@media (min-width: 980px) {
  .course-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}


.map-image-wrap {
  padding: 0;
  background: var(--white);
}
.map-image-wrap a { display: block; text-decoration: none; }
.map-img {
  width: 100%;
  height: auto;
  display: block;
}
.map-directions {
  margin-top: 1rem;
  text-align: center;
  display: grid;
  gap: 0.45rem;
  justify-items: center;
}
.map-directions p { margin: 0; color: var(--ink); max-width: 40rem; line-height: 1.65; }
.map-directions .muted { color: var(--muted); font-size: 0.92rem; }


/* text-only course banners (no flyer thumbs) */
.course-highlight,
.package-banner {
  grid-template-columns: 1fr !important;
}
.course-highlight .btn,
.package-banner .btn {
  align-self: flex-start;
}


/* full lockup logo — keep Chinese 童增教室 visible */
@media (max-width: 420px) {
  .brand img,
  .brand-logo { height: 56px; max-height: 56px; }
  :root { --header-h: 76px; }
}

/* ===== Horizontal course cards + flyer lightbox ===== */
.course-cards {
  grid-template-columns: 1fr !important;
  gap: 1.15rem;
}
.course-card-h {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: stretch;
}
.course-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 0;
}
.course-card-body .btn { align-self: flex-start; margin-top: auto; }
.course-flyer-open {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--soft);
  border-radius: 14px;
  padding: 0.45rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  max-width: 220px;
  width: 100%;
  margin-inline: auto;
  box-shadow: 0 4px 14px rgba(58, 50, 40, 0.06);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.course-flyer-open:hover,
.course-flyer-open:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(58, 50, 40, 0.12);
  outline: 2px solid var(--leaf);
  outline-offset: 2px;
}
.course-flyer-open img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
}
.course-flyer-hint {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--btn);
}

.course-highlight.course-card-h,
.package-banner.course-card-h {
  grid-template-columns: 1fr !important;
}

@media (min-width: 720px) {
  .course-card-h {
    grid-template-columns: 1.35fr 0.65fr;
    gap: 1.25rem;
    align-items: center;
  }
  .course-flyer-open {
    margin-inline: 0;
    justify-self: end;
    max-width: 240px;
  }
  .course-highlight.course-card-h,
  .package-banner.course-card-h {
    grid-template-columns: 1.35fr 0.65fr !important;
  }
}

.flyer-lightbox[hidden] { display: none !important; }
.flyer-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 1rem;
}
.flyer-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(30, 24, 18, 0.72);
  cursor: pointer;
}
.flyer-lightbox-dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 520px);
  max-height: min(92vh, 920px);
  background: var(--bg);
  border-radius: 16px;
  padding: 0.75rem 0.75rem 1rem;
  box-shadow: 0 20px 50px rgba(0,0,0,0.35);
  display: grid;
  gap: 0.5rem;
  overflow: auto;
}
.flyer-lightbox-img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  display: block;
}
.flyer-lightbox-caption[hidden] { display: none !important; }
.flyer-lightbox-caption {
  margin: 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
}
.flyer-lightbox-close {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 999px;
  background: rgba(42, 36, 28, 0.88);
  color: #fff;
  font-size: 1.45rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.flyer-lightbox-close:hover,
.flyer-lightbox-close:focus-visible {
  background: var(--btn);
  outline: 2px solid #fff;
  outline-offset: 2px;
}
body.lightbox-open { overflow: hidden; }


/* Featured priority: 10-lesson package under trial */
.course-featured {
  border-color: rgba(122, 152, 108, 0.55);
  box-shadow: 0 12px 32px rgba(84, 104, 72, 0.14);
  background: linear-gradient(160deg, rgba(141, 169, 128, 0.22), #fff 48%);
}
.course-featured .eyebrow {
  background: rgba(84, 104, 72, 0.16);
  color: var(--btn);
}


/* Header WhatsApp CTA: beat .site-nav a ink color — white on olive */
.site-nav a.btn-primary,
.site-nav a.btn-primary:hover,
.site-nav a.btn-primary:focus-visible {
  color: #fff !important;
  background: var(--btn);
}
.site-nav a.btn-primary:hover,
.site-nav a.btn-primary:focus-visible {
  background: var(--btn-hover);
  color: #fff !important;
}

/* Wong Sir: one shared flyer + compact text cards */
.wong-sir-strip {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.1rem;
  align-items: start;
  margin-top: 0.35rem;
}
.wong-sir-flyer {
  max-width: 280px;
  width: 100%;
  margin-inline: auto;
}
.wong-sir-cards {
  display: grid;
  gap: 0.75rem;
}
.course-card-compact {
  padding: 1rem 1.05rem 1.1rem;
  gap: 0.45rem;
}
.course-card-compact h3 {
  font-size: 1.12rem;
  margin: 0;
}
.course-card-compact p {
  margin: 0;
  font-size: 0.95rem;
}
.course-card-compact .card-list {
  margin: 0.15rem 0;
  padding-left: 1.05rem;
  font-size: 0.92rem;
}
.course-card-compact .card-price {
  margin-top: 0.15rem !important;
}
.course-card-compact .btn {
  align-self: flex-start;
  min-height: 40px;
  padding: 0.55rem 1rem;
  font-size: 0.92rem;
}
@media (min-width: 860px) {
  .wong-sir-strip {
    grid-template-columns: 0.72fr 1.28fr;
    gap: 1.35rem;
    align-items: stretch;
  }
  .wong-sir-flyer {
    margin-inline: 0;
    max-width: 300px;
    height: 100%;
    justify-content: flex-start;
  }
  .wong-sir-flyer img {
    width: 100%;
  }
}


/* Gallery: uniform square thumbs, even grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}
.gallery-item {
  appearance: none;
  border: 0;
  padding: 0;
  margin: 0;
  background: var(--soft);
  border-radius: 14px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 1 / 1;
  display: block;
  box-shadow: 0 4px 14px rgba(58, 50, 40, 0.06);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.gallery-item:hover,
.gallery-item:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(58, 50, 40, 0.12);
  outline: 2px solid var(--leaf);
  outline-offset: 2px;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
@media (min-width: 720px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.9rem;
  }
}


.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}
