/* ==========================================================================
   EnglishTeacher.lk — Home page styles
   Brand tokens derived from the original logo:
   blue #1E78AE · navy #1C2350 · pale blue #C9DEEC · white
   ========================================================================== */

:root {
  /* Brand palette */
  --blue: #1E78AE;
  --blue-600: #16618F;
  --blue-700: #10507A;
  --blue-100: #DCEEF8;
  --sky: #C9DEEC;
  --sky-soft: #EAF4FA;
  --navy: #1C2350;
  --navy-700: #2A3474;

  /* Neutrals (blue-tinted to stay in family) */
  --ink: #1C2350;
  --muted: #57608A;
  --line: #E2EDF5;
  --surface: #FFFFFF;
  --surface-2: #F5FAFD;

  /* Typography */
  --font-display: "Poppins", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-body: "Nunito Sans", "Segoe UI", system-ui, -apple-system, sans-serif;

  /* Shape & elevation */
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(28, 35, 80, 0.06), 0 2px 8px rgba(28, 35, 80, 0.06);
  --shadow-md: 0 4px 12px rgba(28, 35, 80, 0.08), 0 12px 32px rgba(28, 35, 80, 0.10);
  --shadow-lg: 0 8px 20px rgba(28, 35, 80, 0.10), 0 24px 56px rgba(28, 35, 80, 0.14);

  --ring: rgba(30, 120, 174, 0.35);
  --container: 1160px;
  --header-h: 72px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
}

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

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--navy);
  line-height: 1.18;
  margin: 0 0 0.5em;
  letter-spacing: -0.015em;
}

p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: var(--blue-600); text-decoration: none; }
a:hover { text-decoration: underline; }

svg {
  width: 1.25em;
  height: 1.25em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.22em;
  flex: none;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(18px, 4vw, 32px);
}

.section { padding-block: clamp(64px, 9vw, 104px); }
.section-tint {
  background:
    radial-gradient(circle at 100% 0%, rgba(201, 222, 236, 0.45), transparent 42%),
    var(--surface-2);
}

.section-head {
  max-width: 640px;
  margin: 0 auto clamp(36px, 5vw, 56px);
  text-align: center;
}

.kicker {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--blue-600);
  margin: 0 0 10px;
}

.section-head h2 { font-size: clamp(1.65rem, 3.4vw, 2.4rem); }

.section-sub { color: var(--muted); font-size: 1.075rem; margin: 0; }
.section-sub.left { text-align: left; }

.center-cta { text-align: center; margin-top: 28px; }

.sample-note {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  margin: 22px 0 0;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1;
  padding: 12px 22px;
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease,
    transform 0.15s ease, box-shadow 0.2s ease;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--blue-600);
  color: #fff;
  box-shadow: 0 6px 16px rgba(22, 97, 143, 0.28);
}
.btn-primary:hover { background: var(--blue-700); color: #fff; }

.btn-outline {
  background: transparent;
  color: var(--blue-600);
  border-color: var(--blue);
}
.btn-outline:hover { background: var(--sky-soft); color: var(--blue-700); }

.btn-ghost { color: var(--navy); padding-inline: 14px; }
.btn-ghost:hover { background: var(--sky-soft); color: var(--blue-700); }

.btn-light {
  background: #fff;
  color: var(--navy);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
}
.btn-light:hover { background: var(--sky-soft); color: var(--blue-700); }

.btn-outline-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
}
.btn-outline-light:hover { border-color: #fff; background: rgba(255, 255, 255, 0.12); color: #fff; }

.btn-lg { padding: 15px 30px; font-size: 1rem; }
.btn-block { width: 100%; }

:focus-visible {
  outline: 3px solid var(--ring);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -64px;
  z-index: 200;
  background: var(--navy);
  color: #fff;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}
.site-header.is-scrolled {
  border-bottom-color: var(--line);
  box-shadow: 0 4px 18px rgba(28, 35, 80, 0.07);
}

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

.brand img { width: 46px; height: 46px; }

.nav-list {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.6vw, 14px);
}
.nav-list a {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 0.92rem;
  color: var(--ink);
  padding: 9px 12px;
  border-radius: var(--radius-pill);
  transition: background-color 0.15s ease, color 0.15s ease;
}
.nav-list a:hover {
  background: var(--sky-soft);
  color: var(--blue-700);
  text-decoration: none;
}

.site-nav { display: flex; align-items: center; gap: clamp(10px, 2vw, 26px); }
.nav-actions { display: flex; align-items: center; gap: 10px; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: var(--sky-soft);
  border: 0;
  border-radius: var(--radius-sm);
  cursor: pointer;
}
.nav-toggle .bar {
  display: block;
  width: 100%;
  height: 2.4px;
  border-radius: 2px;
  background: var(--navy);
  transition: transform 0.25s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] .bar:nth-child(1) { transform: translateY(7.4px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .bar:nth-child(3) { transform: translateY(-7.4px) rotate(-45deg); }

@media (max-width: 920px) {
  .nav-toggle { display: flex; }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    padding: 10px clamp(18px, 4vw, 32px) 22px;
    gap: 6px;
    display: none;
  }
  .site-header.nav-open .site-nav { display: flex; }

  .nav-list { flex-direction: column; align-items: stretch; gap: 2px; }
  .nav-list a { display: block; padding: 12px 14px; border-radius: var(--radius-sm); }

  .nav-actions {
    flex-direction: column;
    align-items: stretch;
    margin-top: 10px;
    padding-top: 14px;
    border-top: 1px solid var(--line);
  }
  .nav-actions .btn { width: 100%; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(52% 60% at 88% -6%, rgba(30, 120, 174, 0.10), transparent 70%),
    radial-gradient(40% 50% at -4% 12%, rgba(201, 222, 236, 0.55), transparent 70%),
    linear-gradient(180deg, #FDFEFE 0%, var(--surface-2) 100%);
  padding-block: clamp(52px, 8vw, 96px) 0;
}
/* Halftone dots — homage to the logo texture */
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 -20px 0;
  height: 200px;
  background-image: radial-gradient(rgba(30, 120, 174, 0.28) 1.6px, transparent 1.7px);
  background-size: 20px 20px;
  -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,.8), transparent);
  mask-image: linear-gradient(to top, rgba(0,0,0,.8), transparent);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(40px, 6vw, 72px);
  align-items: center;
}

.eyebrow-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blue-700);
  background: #fff;
  border: 1px solid var(--sky);
  padding: 7px 15px;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
  margin: 0 0 20px;
}
.eyebrow-chip svg { width: 1.05em; height: 1.05em; color: var(--blue); }

.hero h1 {
  font-size: clamp(2.1rem, 5.2vw, 3.4rem);
  font-weight: 800;
  margin-bottom: 18px;
}

.grad-text {
  background: linear-gradient(92deg, var(--blue) 10%, var(--blue-600) 55%, var(--navy) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  color: var(--muted);
  font-size: clamp(1.05rem, 1.6vw, 1.2rem);
  max-width: 54ch;
  margin-bottom: 30px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 24px;
}

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
}
.hero-trust li { display: flex; align-items: center; gap: 7px; }
.hero-trust svg {
  width: 1.15em;
  height: 1.15em;
  color: var(--blue);
  stroke-width: 2.6;
  background: var(--blue-100);
  border-radius: 50%;
  padding: 2px;
}

/* Hero visual composition */
.hero-visual {
  position: relative;
  min-height: 380px;
  display: grid;
  place-items: center;
}

.vcard {
  position: absolute;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.vcard-room { width: min(340px, 88vw); padding: 18px; z-index: 2; }

.vcard-room-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
}
.live-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #E2504C;
  box-shadow: 0 0 0 0 rgba(226, 80, 76, 0.5);
  animation: pulse 1.8s infinite;
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 9px rgba(226, 80, 76, 0); }
  100% { box-shadow: 0 0 0 0 rgba(226, 80, 76, 0); }
}
.room-name { font-family: var(--font-display); font-weight: 700; font-size: 0.98rem; color: var(--navy); }
.room-tag {
  margin-left: auto;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--blue-700);
  background: var(--sky-soft);
  border-radius: var(--radius-pill);
  padding: 3px 10px;
}

.avatar-row { display: flex; margin-bottom: 14px; }
.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: var(--a, var(--blue));
  color: #fff;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  border: 2.5px solid #fff;
  margin-left: -10px;
  box-shadow: var(--shadow-sm);
}
.avatar:first-child { margin-left: 0; }
.avatar-more { background: var(--sky); color: var(--navy); }

.speaking-row { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 14px; }
.speaker-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--navy);
  background: var(--surface-2);
  border: 1px solid var(--line);
  padding: 5px 12px;
  border-radius: var(--radius-pill);
}
.speaker-chip svg { width: 1em; height: 1em; color: var(--blue); }
.speaker-chip.is-muted { color: var(--muted); }
.speaker-chip.is-muted svg { color: #B6C3D5; }

.vcard-room-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
}
.waveform { display: inline-flex; align-items: flex-end; gap: 3px; height: 20px; }
.waveform i {
  width: 3.5px;
  border-radius: 2px;
  background: var(--blue);
  animation: wave 1.1s ease-in-out infinite;
}
.waveform i:nth-child(1) { height: 40%; animation-delay: 0s; }
.waveform i:nth-child(2) { height: 75%; animation-delay: 0.12s; }
.waveform i:nth-child(3) { height: 100%; animation-delay: 0.24s; }
.waveform i:nth-child(4) { height: 60%; animation-delay: 0.36s; }
.waveform i:nth-child(5) { height: 90%; animation-delay: 0.48s; }
.waveform i:nth-child(6) { height: 50%; animation-delay: 0.6s; }
.waveform i:nth-child(7) { height: 80%; animation-delay: 0.72s; }
@keyframes wave { 50% { transform: scaleY(0.35); } }

.room-count { font-size: 0.8rem; font-weight: 600; color: var(--muted); }

.vcard-ai {
  width: min(270px, 78vw);
  padding: 16px 18px;
  right: clamp(-8px, -1vw, 8px);
  bottom: 6px;
  z-index: 3;
}
.vcard-ai-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.ai-glyph {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--blue), var(--navy));
  color: #fff;
}
.ai-glyph svg { width: 17px; height: 17px; }
.ai-name { font-family: var(--font-display); font-weight: 700; font-size: 0.9rem; color: var(--navy); }
.ai-mode {
  margin-left: auto;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--blue-700);
  background: var(--blue-100);
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}
.ai-bubble {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 4px 14px 14px 14px;
  padding: 9px 13px;
  font-size: 0.88rem;
  color: var(--ink);
  margin: 0 0 9px;
}
.typing { display: inline-flex; gap: 4px; padding: 2px 4px; }
.typing i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--blue);
  opacity: 0.4;
  animation: blink 1.2s infinite;
}
.typing i:nth-child(2) { animation-delay: 0.2s; }
.typing i:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 50% { opacity: 1; } }

.float-chip {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--navy);
  padding: 8px 15px;
  z-index: 4;
  animation: floaty 5s ease-in-out infinite;
}
.float-streak { top: 8px; left: clamp(-4px, 0vw, 12px); }
.float-verified { color: var(--blue-700); animation-delay: 2.2s; right: clamp(6px, 2vw, 30px); }
.float-verified svg { width: 1.1em; height: 1.1em; color: var(--blue); }
@keyframes floaty { 50% { transform: translateY(-8px); } }

@media (min-width: 980px) {
  .hero-grid { grid-template-columns: 1.08fr 0.92fr; }
  .hero-visual { min-height: 430px; }
  .vcard-room { position: relative; width: min(360px, 100%); left: -6px; top: 6px; }
  .vcard-ai { position: absolute; right: -4px; bottom: -18px; }
}

/* ---------- Stats band ---------- */
.stats-band {
  position: relative;
  z-index: 2;
  margin-top: clamp(48px, 7vw, 84px);
  background: linear-gradient(120deg, var(--navy) 0%, var(--navy-700) 58%, var(--blue-600) 130%);
}
.stats-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.14) 1.4px, transparent 1.5px);
  background-size: 22px 22px;
  -webkit-mask-image: linear-gradient(115deg, rgba(0,0,0,.7), transparent 55%);
  mask-image: linear-gradient(115deg, rgba(0,0,0,.7), transparent 55%);
}

.stats-grid {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px 20px;
  padding-block: clamp(30px, 4vw, 44px);
}
.stat { display: flex; align-items: center; gap: 14px; }
.stat-icon {
  width: 46px;
  height: 46px;
  flex: none;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: var(--sky);
}
.stat-icon svg { width: 22px; height: 22px; }
.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.98rem;
  color: #fff;
  line-height: 1.3;
}
.stat span:not(.stat-icon) {
  display: block;
  font-size: 0.85rem;
  color: var(--sky);
}

@media (min-width: 880px) {
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Features ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
@media (min-width: 660px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .feature-grid { grid-template-columns: repeat(3, 1fr); } }

.feature-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px 24px 22px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}
.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--sky);
}
.feature-card h3 { font-size: 1.08rem; margin-bottom: 8px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.feature-card p { color: var(--muted); font-size: 0.96rem; margin: 0; }

.feature-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}
.feature-icon svg { width: 25px; height: 25px; }
.icon-blue { background: var(--blue-100); color: var(--blue-600); }
.icon-navy { background: #E9EBF7; color: var(--navy); }

.mini-tag {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--blue-700);
  background: var(--sky-soft);
  border: 1px solid var(--sky);
  border-radius: var(--radius-pill);
  padding: 2px 9px;
}

/* ---------- Steps ---------- */
.steps {
  counter-reset: step;
  display: grid;
  gap: 18px;
}
@media (min-width: 880px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 26px; } }

.step {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px 24px;
  box-shadow: var(--shadow-sm);
}
.step-num {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--blue-600));
  box-shadow: 0 6px 14px rgba(22, 97, 143, 0.3);
  margin-bottom: 16px;
}
.step h3 { font-size: 1.06rem; }
.step p { color: var(--muted); font-size: 0.96rem; margin: 0; }

/* ---------- Teachers ---------- */
.teacher-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
}
@media (min-width: 700px) { .teacher-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1020px) { .teacher-grid { grid-template-columns: repeat(3, 1fr); } }

.teacher-card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}
.teacher-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }

.teacher-top { display: flex; align-items: center; gap: 14px; margin-bottom: 13px; }
.avatar-lg { width: 58px; height: 58px; font-size: 1.05rem; margin: 0; flex: none; }

.teacher-top h3 {
  font-size: 1.05rem;
  margin: 0 0 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.verified { width: 19px; height: 19px; color: var(--blue); stroke-width: 2; }
.teacher-spec { margin: 0; font-size: 0.86rem; font-weight: 700; color: var(--blue-600); }

.teacher-bio { color: var(--muted); font-size: 0.94rem; flex: 1; }

.teacher-tags { display: flex; flex-wrap: wrap; gap: 7px; margin: 12px 0 16px; }
.teacher-tags span {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--navy);
  background: var(--sky-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 3px 11px;
}

.teacher-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 13px;
  margin-bottom: 15px;
  border-top: 1px dashed var(--line);
}
.price { font-size: 0.92rem; color: var(--muted); }
.price strong {
  font-family: var(--font-display);
  font-size: 1.12rem;
  color: var(--navy);
}
.rating {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 800;
  font-size: 0.92rem;
  color: var(--navy);
}
.rating svg { width: 15px; height: 15px; fill: #F5A623; stroke: none; }
.rating em { font-style: normal; font-weight: 600; color: var(--muted); font-size: 0.82rem; }

/* ---------- Safety ---------- */
.safety-grid { display: grid; gap: 36px; }
@media (min-width: 940px) {
  .safety-grid { grid-template-columns: 0.9fr 1.1fr; align-items: center; gap: 64px; }
}
.safety-copy .btn { margin-top: 10px; }

.safety-list { display: grid; gap: 14px; }
.safety-list li {
  display: flex;
  gap: 15px;
  align-items: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  box-shadow: var(--shadow-sm);
}
.safety-icon {
  width: 42px;
  height: 42px;
  flex: none;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--blue-100);
  color: var(--blue-600);
}
.safety-icon svg { width: 21px; height: 21px; }
.safety-list strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.97rem;
  color: var(--navy);
}
.safety-list li span:not(.safety-icon) {
  display: block;
  color: var(--muted);
  font-size: 0.92rem;
}

/* ---------- CTA band ---------- */
.cta-band {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(60% 90% at 85% 10%, rgba(30, 120, 174, 0.55), transparent 60%),
    linear-gradient(130deg, var(--navy) 20%, var(--navy-700) 100%);
  padding-block: clamp(64px, 9vw, 100px);
}
.cta-band::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.12) 1.4px, transparent 1.5px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(70% 100% at 80% 0%, rgba(0,0,0,.6), transparent 70%);
  mask-image: radial-gradient(70% 100% at 80% 0%, rgba(0,0,0,.6), transparent 70%);
}

.cta-inner { position: relative; text-align: center; max-width: 680px; }
.cta-inner h2 { color: #fff; font-size: clamp(1.7rem, 3.6vw, 2.5rem); }
.cta-inner p { color: var(--sky); font-size: 1.1rem; margin-bottom: 30px; }
.cta-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy);
  color: #B9C1E4;
  padding-top: clamp(52px, 7vw, 76px);
}

.footer-grid {
  display: grid;
  gap: 38px;
  padding-bottom: 46px;
}
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }

.footer-brand p { font-size: 0.95rem; margin: 16px 0 0; max-width: 30ch; }
.footer-logo {
  display: inline-grid;
  place-items: center;
  width: 68px;
  height: 68px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

.footer-col h3 {
  color: #fff;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 16px;
}
.footer-col ul { display: grid; gap: 10px; }
.footer-col a {
  color: #B9C1E4;
  font-size: 0.95rem;
  transition: color 0.15s ease;
}
.footer-col a:hover { color: #fff; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-block: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.footer-bottom p { margin: 0; font-size: 0.88rem; }

.socials { display: flex; gap: 10px; }
.socials a {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #DDE3FA;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.socials a:hover { background: var(--blue); color: #fff; transform: translateY(-2px); }
.socials svg { width: 18px; height: 18px; }

/* ---------- Community feed preview ---------- */
.feed-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  align-items: start;
}
@media (min-width: 1000px) {
  .feed-layout { grid-template-columns: minmax(0, 1fr) 330px; gap: 26px; }
}

.feed-column { display: grid; gap: 18px; }

.post-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px 22px 16px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.22s ease, border-color 0.22s ease;
}
.post-card:hover { box-shadow: var(--shadow-md); border-color: var(--sky); }

.post-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 13px;
}
.post-head .avatar { flex: none; }
.post-who { flex: 1; min-width: 0; }
.post-who h3 {
  font-size: 0.98rem;
  margin: 0 0 2px;
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
}
.post-meta { margin: 0; font-size: 0.82rem; color: var(--muted); }

.level-chip, .role-chip, .ai-chip {
  font-family: var(--font-body);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  padding: 2.5px 9px;
}
.level-chip { color: #1B6E3D; background: #E2F5E9; }
.role-chip { color: var(--blue-700); background: var(--blue-100); }
.ai-chip {
  color: var(--navy);
  background: #E9EBF7;
  border: 1px dashed #B9C0E8;
}

.avatar-ai {
  background: linear-gradient(135deg, var(--navy), var(--blue-600));
  width: 42px;
  height: 42px;
}
.avatar-ai svg { width: 20px; height: 20px; color: #fff; }

.btn-follow {
  flex: none;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue-600);
  background: transparent;
  border: 1.5px solid var(--blue);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  cursor: pointer;
  transition: background-color 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}
.btn-follow:hover { background: var(--sky-soft); }
.btn-follow[aria-pressed="true"] {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}

.post-text {
  font-size: 0.99rem;
  color: var(--ink);
  margin: 0 0 12px;
}

.post-tags { display: flex; flex-wrap: wrap; gap: 7px; margin: 0 0 14px; }
.post-tags span {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--blue-700);
  background: var(--sky-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  padding: 3px 11px;
}

.post-actions {
  display: flex;
  gap: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}
.pa {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-body);
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-radius: var(--radius-pill);
  padding: 7px 13px;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.pa svg { width: 1.05em; height: 1.05em; }
.pa:hover { background: var(--sky-soft); color: var(--blue-700); }
.pa.like[aria-pressed="true"] { color: #D64550; }
.pa.like[aria-pressed="true"] svg { fill: #D64550; stroke: #D64550; }

/* Fake audio player for challenge entries */
.audio-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin: 0 0 14px;
}
.play-btn {
  width: 44px;
  height: 44px;
  flex: none;
  display: grid;
  place-items: center;
  background: var(--blue-600);
  color: #fff;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  transition: background-color 0.18s ease, transform 0.15s ease;
}
.play-btn:hover { background: var(--blue-700); }
.play-btn:active { transform: scale(0.94); }
.play-btn svg { width: 19px; height: 19px; fill: currentColor; stroke: none; margin-left: 2px; }
.play-btn[aria-pressed="true"] { background: var(--navy); }

.audio-info { flex: 1; min-width: 0; }
.audio-title {
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 6px;
}
.audio-dur { font-size: 0.8rem; font-weight: 700; color: var(--muted); }

.waveform.static { height: 16px; gap: 2.5px; }
.waveform.static i { animation: none; background: var(--blue); opacity: 0.55; }
.waveform.static i:nth-child(1) { height: 30%; }
.waveform.static i:nth-child(2) { height: 55%; }
.waveform.static i:nth-child(3) { height: 85%; }
.waveform.static i:nth-child(4) { height: 45%; }
.waveform.static i:nth-child(5) { height: 100%; }
.waveform.static i:nth-child(6) { height: 60%; }
.waveform.static i:nth-child(7) { height: 90%; }
.waveform.static i:nth-child(8) { height: 35%; }
.waveform.static i:nth-child(9) { height: 75%; }
.waveform.static i:nth-child(10) { height: 50%; }

/* Side panels */
.feed-side { display: grid; gap: 18px; }

.side-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}
.side-card h3 {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.95rem;
  margin-bottom: 15px;
}
.side-card h3 svg { width: 1.1em; height: 1.1em; color: var(--blue-600); }

.room-list { display: grid; gap: 12px; }
.room-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.room-info { display: flex; align-items: center; gap: 10px; min-width: 0; }
.room-info .live-dot { flex: none; }
.room-info strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.88rem;
  color: var(--navy);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.room-info span:not(.live-dot) { display: block; font-size: 0.78rem; color: var(--muted); }
.btn-join {
  flex: none;
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue-600);
  border: 1.5px solid var(--blue);
  border-radius: var(--radius-pill);
  padding: 5px 14px;
  transition: background-color 0.18s ease, color 0.18s ease;
}
.btn-join:hover { background: var(--blue-600); color: #fff; text-decoration: none; }

.trend-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.trend-cloud span {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--navy);
  background: var(--sky-soft);
  border: 1px solid var(--sky);
  border-radius: var(--radius-pill);
  padding: 6px 13px;
  transition: background-color 0.18s ease, color 0.18s ease;
  cursor: default;
}
.trend-cloud span:hover { background: var(--blue-600); color: #fff; }

.leader-list { display: grid; gap: 13px; counter-reset: rank; }
.leader-list li {
  display: flex;
  align-items: center;
  gap: 11px;
}
.leader-list .avatar { width: 38px; height: 38px; font-size: 0.74rem; margin: 0; flex: none; }
.leader-list li > div { flex: 1; min-width: 0; }
.leader-list strong {
  display: block;
  font-family: var(--font-display);
  font-size: 0.88rem;
  color: var(--navy);
}
.leader-list li > div > span { display: block; font-size: 0.78rem; color: var(--muted); }
.leader-list em {
  font-style: normal;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--blue-700);
  background: var(--blue-100);
  border-radius: var(--radius-pill);
  padding: 3px 10px;
}

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
  .reveal { opacity: 1; transform: none; }
}
