/* The home page (src/site/home.ts), on top of daylight.css.
   One rhythm for the whole page: sections 72-88px apart, a heading block
   then 32px to its content, 16px between cards, 24px inside them. Grids
   are equal columns that fold 5 → 3 → 2 → 1, so rows line up. */

.h-sec { padding-top: clamp(64px, 8vw, 96px); }
.h-hero h1, .h-title, .h-title-s, .h-card h3 { text-wrap: balance; }
.h-sec:last-of-type { padding-bottom: clamp(64px, 8vw, 96px); }

.h-head { display: flex; flex-direction: column; gap: 12px; max-width: 820px; margin-bottom: 32px; }
.h-head .lead { max-width: 640px; }
.h-head-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px 32px; margin-bottom: 32px; }
.h-head-row .h-head { margin-bottom: 0; }
.h-title { font-size: clamp(34px, 4.4vw, 52px); line-height: 1.06; }
.h-title-s { font-size: clamp(26px, 3vw, 36px); line-height: 1.1; }

.h-g { display: grid; gap: 16px; }
.h-g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.h-g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.h-g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.h-g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
@media (max-width: 1040px) { .h-g5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .h-g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) { .h-g2, .h-g3 { grid-template-columns: minmax(0, 1fr); } .h-g5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .h-g4, .h-g5 { grid-template-columns: minmax(0, 1fr); } }

.h-card { border-radius: var(--r-card); padding: 24px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.h-card h3 { font-size: 21px; line-height: 1.15; }
.h-card p { font-size: 15.5px; line-height: 1.5; }
.h-big { border-radius: var(--r-tile); padding: clamp(24px, 3.4vw, 40px); }

.h-tag { display: inline-flex; align-items: center; font-size: 12px; font-weight: 700; border-radius: 999px; padding: 5px 10px; line-height: 1.2; }
.tg-blue { background: var(--accent-200); color: var(--accent-700); }
.tg-sage { background: var(--sage-200); color: var(--sage-700); }
.tg-amber { background: var(--amber-tint); color: var(--amber); }
.tg-violet { background: var(--violet-tint); color: var(--violet); }
.soon { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--amber); background: var(--amber-tint); border: 1px solid var(--amber-border); border-radius: 999px; padding: 4px 10px; line-height: 1.2; white-space: nowrap; }

/* ---------- header ---------- */
.h-nav { gap: 8px; }
@media (max-width: 900px) { .h-nav .h-nav-opt { display: none; } }

/* ---------- hero ---------- */
.h-hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(32px, 5vw, 56px); align-items: center; padding-top: clamp(12px, 3vw, 32px); }
@media (max-width: 960px) { .h-hero { grid-template-columns: minmax(0, 1fr); } }
.h-hero-text { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.h-hero h1 { font-size: clamp(44px, 5.6vw, 68px); line-height: 1.02; }

/* Three equal segments that never wrap onto a second row; the labels wrap inside them instead. */
.h-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; padding: 6px; background: var(--sunk); border-radius: 22px; width: 100%; max-width: 560px; box-sizing: border-box; }
.h-tab { min-height: 44px; padding: 6px 10px; border-radius: 16px; border: 1px solid transparent; background: transparent; font: 700 15px/1.2 var(--sans); color: var(--ink-body); cursor: pointer; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; text-align: center; gap: 4px 8px; }
.h-tab:hover { color: var(--accent-800); }
.h-tab[aria-selected="true"] { background: var(--card); color: var(--accent-800); border-color: var(--accent-border); box-shadow: inset 0 1px 0 #fff, 0 3px 0 var(--accent-ledge); }
.h-tab .soon { font-size: 10px; padding: 3px 7px; }
@media (max-width: 560px) {
  .h-tab { padding: 6px 8px; font-size: 14px; flex-direction: column; gap: 4px; }
}

.h-panel { border-radius: var(--r-card); padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.h-panel label, .h-panel .h-panel-title { font-family: var(--display); font-size: 22px; color: var(--ink); }
.h-input { width: 100%; box-sizing: border-box; min-height: 56px; padding: 0 20px; border-radius: 18px; border: 1.5px solid var(--accent-border); background: #fff; font: 18px var(--sans); color: var(--ink); }
.h-input:focus { outline: 3px solid var(--accent-bright); outline-offset: 2px; }
.h-input:disabled { background: var(--paper); color: var(--ink-muted); }
.h-legend { font-size: 12.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 8px; padding: 0; }
.h-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.h-opt { min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: 700 14.5px var(--sans); cursor: pointer; }
.h-opt[aria-pressed="true"] { background: var(--accent-700); border-color: var(--accent-700); color: #fff; }
.h-drop { border: 2px dashed var(--accent-ledge); border-radius: 18px; background: var(--accent-100); padding: 22px; display: flex; align-items: center; gap: 16px; }
.h-drop .ic { width: 36px; height: 36px; color: var(--accent-700); stroke-width: 1.8; }
.btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; transform: none; }
.h-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.h-link { font-weight: 700; }

/* the hero's picture of a personal course */
.h-mock { border-radius: var(--r-tile); overflow: hidden; padding: 0; position: relative; }
.h-mock-bar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; background: var(--mist); border-bottom: 1px solid var(--line-soft); }
.h-mock-bar .url { margin-left: 8px; background: var(--card); border-radius: 999px; padding: 3px 12px; font-size: 13px; color: var(--ink-soft); font-weight: 600; }
.h-mock-body { padding: 20px; display: flex; flex-direction: column; gap: 14px; background: var(--paper); }
.h-mock-cols { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 12px; }
@media (max-width: 1100px) and (min-width: 961px) { .h-mock-cols { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) { .h-mock-cols { grid-template-columns: minmax(0, 1fr); } }
.h-mock-box { background: var(--card); border-radius: 18px; padding: 14px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.h-mock-k { font-size: 12.5px; font-weight: 800; color: var(--ink-soft); }
.h-step { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 12px; font-size: 14.5px; }
.h-step .n { width: 24px; height: 24px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 800; }
.h-step .t { flex: 1; min-width: 0; }
.h-step .m { font-size: 12.5px; color: var(--ink-soft); flex: none; }
.h-bar { display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; }
.h-bar > div:first-child { display: flex; justify-content: space-between; gap: 8px; }
.h-bar .track { height: 7px; border-radius: 99px; background: var(--mist); }
.h-bar .fill { height: 7px; border-radius: 99px; }

/* ---------- three ways ---------- */
.h-way { flex-direction: row; align-items: flex-start; gap: 16px; text-decoration: none; color: inherit; }
.h-way .well { width: 48px; height: 48px; border-radius: 14px; flex: none; }
.h-way strong { display: block; font-family: var(--display); font-weight: 400; font-size: 21px; color: var(--ink); line-height: 1.15; }
.h-way span.d { display: block; margin-top: 4px; font-size: 15px; line-height: 1.45; color: var(--ink-soft); }

/* ---------- tools ---------- */
.h-tool { border-radius: var(--r-tile); }
.h-tool h3 { font-size: 22px; }
.h-tool .inner { background: var(--card); border-radius: 18px; padding: 16px; min-height: 132px; box-sizing: border-box; display: flex; flex-direction: column; gap: 8px; }
.h-stat b { display: block; font-family: var(--display); font-weight: 400; font-size: 26px; line-height: 1.1; }
.h-stat span { font-size: 13px; color: var(--ink-body); }

/* ---------- exam course ---------- */
.h-exam { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 16px; align-items: stretch; }
@media (max-width: 960px) { .h-exam { grid-template-columns: minmax(0, 1fr); } }
.h-nums { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 120px), 1fr)); }
.h-num { background: var(--accent-100); border-radius: 16px; padding: 12px 14px; }
.h-num b { display: block; font-family: var(--display); font-weight: 400; font-size: 26px; color: var(--accent-700); line-height: 1.1; }
.h-num span { font-size: 13.5px; color: var(--ink-body); }
.h-units { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.h-units a { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 12px; background: var(--paper); border: 1px solid var(--line); color: var(--ink); font-weight: 700; font-size: 14.5px; text-decoration: none; }
.h-units a:hover { border-color: var(--accent-border); background: var(--accent-100); color: var(--accent-800); }
.h-units a span { font-weight: 500; color: var(--ink-muted); }
.h-parts { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); }
.h-parts li { border: 1px solid var(--line-soft); border-radius: 14px; padding: 12px 14px; font-size: 14px; line-height: 1.4; color: var(--ink-soft); }
.h-parts b { display: block; color: var(--ink); font-size: 14.5px; }
.h-plan { background: var(--accent-700); color: #e6eef5; border-radius: var(--r-tile); padding: clamp(24px, 3.4vw, 36px); display: flex; flex-direction: column; gap: 16px; box-shadow: inset 0 1px 0 rgba(255,255,255,.15), 0 4px 0 var(--accent-800), 0 14px 28px rgba(46,43,37,.18); }
.h-plan h3 { color: #fff; font-size: clamp(24px, 2.6vw, 30px); line-height: 1.12; }
.h-plan ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.h-plan li { display: flex; gap: 12px; font-size: 16px; line-height: 1.45; }
.h-plan li .ic { color: var(--accent-bright); margin-top: 1px; }
.h-plan .soon { align-self: flex-start; }
.h-plan .h-date { display: flex; flex-direction: column; gap: 8px; margin-top: auto; }
.h-plan .h-date label { font-size: 14px; font-weight: 700; color: #fff; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.h-plan .h-date .box { min-height: 50px; border-radius: 14px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25); color: #abccf9; display: flex; align-items: center; padding: 0 16px; font-size: 16px; }
.h-plan .h-date .go { min-height: 50px; border-radius: 999px; background: rgba(255,255,255,.9); color: var(--accent-800); font-family: var(--display); font-size: 18px; display: grid; place-items: center; opacity: .6; cursor: not-allowed; }

/* ---------- personal courses ---------- */
.h-n { width: 40px; height: 40px; border-radius: 12px; color: #fff; display: grid; place-items: center; font-family: var(--display); font-size: 20px; }
.h-two { border-radius: var(--r-tile); padding: clamp(24px, 3.4vw, 40px); background: var(--paper); border: 1px solid var(--line-soft); box-shadow: inset 0 1px 0 #fff, 0 4px 0 var(--ledge); display: flex; flex-direction: column; gap: 24px; }
.h-two ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.h-two li { display: flex; gap: 12px; font-size: 15.5px; line-height: 1.5; }
.h-two li::before { content: ""; width: 8px; height: 8px; margin-top: 8px; flex: none; border-radius: 50%; background: var(--dot, var(--accent-bright)); }
.h-adj .ic { color: var(--accent-700); width: 26px; height: 26px; }
.h-adj h3 { font-size: 18.5px; }

/* ---------- pricing ---------- */
.h-price { border-radius: var(--r-tile); padding: 28px; display: flex; flex-direction: column; gap: 14px; }
.h-price h3 { font-size: 26px; }
.h-price .amt { font-family: var(--display); font-size: 44px; color: var(--ink); line-height: 1; }
.h-price ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; font-size: 15.5px; line-height: 1.45; }
.h-price li { display: flex; gap: 10px; }
.h-price li .ic { color: var(--sage); width: 18px; height: 18px; margin-top: 2px; }
.h-price .btn { margin-top: auto; align-self: flex-start; }

/* ---------- questions ---------- */
.h-faq details { border-radius: 20px; padding: 16px 20px; }
.h-faq summary { font-weight: 800; color: var(--ink); cursor: pointer; font-size: 17px; }
.h-faq details p { margin-top: 10px; font-size: 15.5px; }

@media (max-width: 520px) {
  .h-adj { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 4px 12px; padding: 16px 18px; }
  .h-adj p { flex-basis: 100%; }
  .h-card { padding: 20px; }
}
