/* Study Chinese — homepage-specific layout. Depends on site.css + ui.css. */

/* HERO */
.hero { position: relative; overflow: clip; padding: clamp(40px, 6vw, 84px) 0 clamp(30px, 5vw, 70px); }
.hero-glow { position: absolute; inset: -14% -10% auto -10%; height: 90%; pointer-events: none; z-index: -1;
  background: radial-gradient(54% 62% at 26% 0%, rgba(24, 178, 87, .16), transparent 70%),
              radial-gradient(42% 52% at 86% 14%, rgba(244, 183, 64, .13), transparent 72%),
              radial-gradient(40% 46% at 62% 40%, rgba(14, 159, 110, .08), transparent 72%); }
.hero-grid { display: grid; grid-template-columns: 1.02fr .98fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero-pill { display: inline-flex; align-items: center; gap: 11px; background: var(--card); border: 1px solid var(--border); box-shadow: var(--shadow-sm); border-radius: var(--r-pill); padding: 7px 18px 7px 8px; font-weight: 700; font-size: .88rem; color: var(--ink2); margin-bottom: 24px; }
.hero-copy h1 { font-size: clamp(2.5rem, 5.4vw, 4.4rem); font-weight: 800; margin-bottom: 20px; max-width: 15ch; }
.hero-copy h1 em { font-style: normal; color: var(--jade-deep); position: relative; }
.hero-copy h1 em::after { content: ""; position: absolute; left: -.04em; right: -.04em; bottom: .05em; height: .32em; background: var(--gold); border-radius: 6px; z-index: -1; opacity: .5; }
.hero-sub { font-size: clamp(1.05rem, 1.6vw, 1.24rem); color: var(--ink2); max-width: 52ch; margin-bottom: 30px; }

/* hero stage: phone + portal cards + Bao */
.hero-stage { position: relative; display: grid; place-items: center; min-height: 480px; }
.hero-hanzi { position: absolute; top: -6%; right: 0; font-family: var(--f-hanzi); font-weight: 700; font-size: clamp(9rem, 16vw, 15rem); color: var(--jade); opacity: .07; line-height: 1; pointer-events: none; }
.hero-phone { width: clamp(220px, 24vw, 280px); z-index: 1; }
/* Cards peek over the phone's edges (~20% overlap), not across it: narrower, and pushed
   outward by a viewport-scaled offset that stays clear of the copy column on the left. */
.hero-mc { position: absolute; width: min(244px, 74vw); z-index: 2; }
.hero-mc .mc-title { white-space: nowrap; }
.hero-mc-sched { top: 5%; left: calc(-1 * clamp(20px, 4vw, 58px)); }
.hero-mc-hw { bottom: 41%; right: calc(-1 * clamp(24px, 4.2vw, 60px)); }
.hero-mc-prog { bottom: -4%; left: calc(-1 * clamp(12px, 3vw, 44px)); width: 200px; }
/* Narrower stage below ~1100px: the cards can't move further out without touching the headline, so they slim down instead. */
@media (max-width: 1100px) { .hero-mc { width: min(200px, 74vw); } .hero-mc-sched { left: calc(-1 * clamp(12px, 3vw, 36px)); } .hero-mc-prog { left: calc(-1 * clamp(8px, 2.5vw, 30px)); width: 180px; } .hero-mc-hw { right: calc(-1 * clamp(16px, 3.5vw, 44px)); } .mockcard.hero-mc { padding: 12px 13px; } }
.hero-prog-note { color: var(--muted); font-size: .78rem; display: block; margin-top: 8px; }
.hero-bao { position: absolute; bottom: -3%; right: 6%; width: clamp(96px, 12vw, 150px); z-index: 3; pointer-events: auto; }
.hero-bao img { width: 100%; height: auto; filter: drop-shadow(0 18px 30px rgba(9, 52, 30, .26)); animation: bao-bob 5.5s var(--ease-in-out) infinite alternate; }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-stage { min-height: 0; margin-top: 8px; padding-bottom: 40px; }
  .hero-mc-sched { left: -2%; top: 0; }
  .hero-mc-hw { right: -2%; }
}
@media (max-width: 480px) {
  .hero-mc-prog { display: none; }
  .hero-bao { right: 0; }
}

/* JadeClass grid tweaks */
.prog-grid { align-items: stretch; }
.prog-more { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; margin-top: 28px; font-weight: 600; color: var(--muted); font-size: .93rem; }
.prog-more .badge { transition: transform .2s var(--ease-out), box-shadow .2s var(--ease-out); }
.prog-more .badge:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.prog-more .link-arrow { margin-left: 6px; }

/* student split: two overlapping phones */
.home-shots { position: relative; display: grid; place-items: center; padding: 10px 0 26px; }
.home-shots .phone { z-index: 1; }
.home-shots .phone-back { position: absolute; z-index: 0; transform: translateX(52%) rotate(5deg) scale(.9); opacity: .9; }
@media (max-width: 480px) { .home-shots .phone-back { display: none; } }

/* dark section extras */
.cta-row-center { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: clamp(26px, 4vw, 40px); }
.dark-note { text-align: center; color: var(--on-dark2); font-size: .87rem; margin-top: 16px; }
.section-dark .dash { max-width: 900px; margin-inline: auto; color: var(--ink); }

/* school tiles — padding-right reserves room for the stair offsets so nothing overflows */
.school-tiles { display: grid; gap: 14px; padding-right: 44px; }
.school-tiles .card:nth-child(2) { transform: translateX(22px); }
.school-tiles .card:nth-child(3) { transform: translateX(44px); }
@media (max-width: 700px) { .school-tiles { padding-right: 0; } .school-tiles .card { transform: none !important; } }

/* HSK readiness: a calm evidence → finding → plan story. */
.hsk-story-section { overflow: clip; }
.hsk-story { display: grid; grid-template-columns: minmax(260px,.78fr) minmax(360px,1.22fr); gap: clamp(24px,6vw,76px); align-items: center; max-width: 1040px; margin: clamp(34px,5vw,62px) auto 0; }
.hsk-story-steps { list-style: none; display: grid; gap: 7px; margin: 0; padding: 0; }
.hsk-story-steps li { border: 1px solid transparent; border-radius: 14px; color: var(--muted); opacity: .58; transition: opacity .24s var(--ease-out), background .24s, border-color .24s, transform .24s var(--ease-out); }
.hsk-story-steps li button { width:100%; min-height:44px; display:grid; grid-template-columns:34px minmax(0,1fr); gap:1px 12px; align-items:center; padding:13px 15px; border:0; border-radius:inherit; background:transparent; color:inherit; font:inherit; text-align:left; cursor:pointer; }
.hsk-story-steps li button:focus-visible,.teacher-flow li button:focus-visible { outline:3px solid var(--gold); outline-offset:3px; }
.hsk-story-steps li button > span { grid-row: 1 / span 2; font-size: .7rem; font-weight: 800; letter-spacing: .08em; color: var(--jade-deep); }
.hsk-story-steps li b { font-size: .94rem; color: var(--ink); }
.hsk-story-steps li small { font-size: .78rem; }
.hsk-story-steps li.is-active { opacity: 1; transform: translateX(6px); background: var(--card); border-color: var(--border-mint); box-shadow: var(--shadow-sm); }
.hsk-demo { position: relative; overflow: hidden; border: 1px solid var(--border-mint); border-radius: var(--r-xl); background: linear-gradient(155deg,#fff,var(--mint)); box-shadow: var(--shadow-lg); padding: clamp(22px,4vw,38px); }
.hsk-demo::after { content: "级"; position: absolute; right: -12px; bottom: -48px; font-family: var(--f-hanzi); font-size: 10rem; color: var(--jade); opacity: .045; pointer-events: none; }
.hsk-demo-head { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-bottom: 18px; border-bottom: 1px solid var(--border); font-size: .78rem; color: var(--muted); }
.hsk-demo-head b { color: var(--ink); font-size: .94rem; }.hsk-demo-head i { color: var(--jade-deep); font-style: normal; padding: 0 5px; }
.hsk-score { position: relative; z-index: 1; display: grid; grid-template-columns: 104px minmax(0,1fr); gap: 20px; align-items: center; margin: 24px 0; }
.hsk-score-ring { width: 100px; aspect-ratio: 1; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--jade) 0 54%,rgba(18,125,72,.1) 54% 100%); position: relative; }
.hsk-score-ring::after { content: ""; position: absolute; inset: 9px; border-radius: inherit; background: var(--card); }
.hsk-score-ring b { position: relative; z-index: 1; font-size: 1.35rem; }
.hsk-score div { display: grid; gap: 5px; }.hsk-score small { color: var(--muted); }.hsk-score strong { font-size: 1.22rem; }.hsk-score p { color: var(--ink2); font-size: .88rem; }
.hsk-skill-list { position: relative; z-index: 1; display: grid; gap: 11px; }
.hsk-skill-list > div { display: grid; grid-template-columns: 84px minmax(80px,1fr) 38px; gap: 10px; align-items: center; font-size: .78rem; }
.hsk-skill-list i { height: 7px; border-radius: 99px; overflow: hidden; background: rgba(18,125,72,.1); }.hsk-skill-list i b { display: block; width: 100%; height: 100%; border-radius: inherit; background: var(--jade); transform: scaleX(var(--hsk-value)); transform-origin: left; }
.hsk-skill-list .is-weak i b { background: var(--coral); }.hsk-skill-list strong { text-align: right; }
.hsk-plan { position: relative; z-index: 1; margin-top: 20px; border: 1px solid rgba(18,125,72,.18); border-radius: 14px; background: rgba(255,255,255,.72); padding: 13px 15px; display: grid; gap: 3px; }
.hsk-plan span { color: var(--jade-deep); font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; }.hsk-plan b { font-size: .86rem; }

.teacher-flow { list-style: none; max-width: 900px; margin: 22px auto 0; padding: 0; display: grid; grid-template-columns: repeat(6,1fr); gap: 7px; }
.teacher-flow li { min-width: 0; border: 1px solid rgba(255,255,255,.14); border-radius: 12px; color: rgba(255,255,255,.56); text-align: center; transition: color .24s, background .24s, border-color .24s, transform .24s var(--ease-out); }
.teacher-flow li button { width:100%; min-height:64px; padding:10px 8px; border:0; border-radius:inherit; background:transparent; color:inherit; font:inherit; cursor:pointer; }
.teacher-flow li span { display: grid; place-items: center; width: 24px; height: 24px; margin: 0 auto 7px; border-radius: 50%; background: rgba(255,255,255,.08); font-size: .68rem; font-weight: 800; }
.teacher-flow li b { display: block; font-size: .68rem; line-height: 1.25; }
.teacher-flow li.is-active { color: #fff; background: rgba(54,196,123,.14); border-color: rgba(110,239,171,.42); transform: translateY(-3px); }
.teacher-flow li.is-active span { background: var(--gold); color: #4d3500; }

@media (max-width: 820px) {
  .hsk-story { grid-template-columns: 1fr; }.hsk-story-steps { grid-template-columns: repeat(6,minmax(210px,1fr)); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }.hsk-story-steps li { scroll-snap-align: start; opacity: 1; }.hsk-story-steps li.is-active { transform: none; }
  .teacher-flow { grid-template-columns: repeat(3,1fr); }
}
@media (max-width: 520px) { .hsk-score { grid-template-columns: 82px 1fr; }.hsk-score-ring { width: 80px; }.teacher-flow { grid-template-columns: repeat(2,1fr); } }

/* final conversion */
.final-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(30px, 5vw, 70px); align-items: center; background: linear-gradient(160deg, var(--mint) 0%, var(--paper) 60%); border: 1px solid var(--border-mint); border-radius: var(--r-xl); padding: clamp(26px, 4.5vw, 60px); }
@media (max-width: 900px) { .final-grid { grid-template-columns: 1fr; } }
.final-copy h2 { font-size: clamp(1.9rem, 4vw, 2.9rem); font-weight: 800; margin-bottom: 14px; }
.final-copy > p { color: var(--ink2); margin-bottom: 20px; max-width: 46ch; }
.final-copy .checks { margin-bottom: 20px; }
.final-bao { display: block; width: clamp(84px, 9vw, 120px); margin-bottom: 14px; }
.final-bao img { width: 100%; filter: drop-shadow(0 14px 24px rgba(9, 52, 30, .22)); }
.final-form { background: var(--card); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); padding: clamp(22px, 3.5vw, 36px); }
.final-form h3 { font-size: 1.4rem; font-weight: 800; margin-bottom: 18px; }
.full-btn { width: 100%; margin-top: 18px; }
.lead-success { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.lead-success h3 { margin-bottom: 0; }
.lead-success p { color: var(--ink2); font-size: .96rem; max-width: 40ch; }

/* mobile trim: the homepage app rail shows a taste; the full set lives on /app */
@media (max-width: 560px) {
  #aplikasi .shots-rail figure:nth-child(n+5) { display: none; }
}
