/* Nicelingo site stylesheet: picker + course home, Poolside palette.
 * Phone-first. Lesson player keeps its own CSS. */
@font-face {
  font-family: "Bricolage Grotesque";
  font-weight: 200 800;
  font-display: swap;
  src: url("/fonts/bricolagegrotesque-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Bricolage Grotesque";
  font-weight: 200 800;
  font-display: swap;
  src: url("/fonts/bricolagegrotesque-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Figtree";
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/figtree-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Figtree";
  font-weight: 100 900;
  font-display: swap;
  src: url("/fonts/figtree-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --bg: #eef6ff;
  --card: #ffffff;
  --ink: #0e1b3d;
  --ink-soft: #2a3757;
  --muted: #4c5873;
  --line: #d3e2f5;
  --blue: #1a5feb;
  --blue-edge: #0f3fae;
  --link: #1247b8;
  --link-hover: #0c3287;
  --prem: #ff8a1f;
  --prem-edge: #c96200;
  --sun: #ffe066;
  --band-soft: #c9d8f2;
  --wash: #e4ebf3;
  --head: "Bricolage Grotesque", system-ui, sans-serif;
  --body-font: "Figtree", system-ui, sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body-font);
  font-size: 16px;
  line-height: 1.5;
}
a { color: var(--link); }
a:hover { color: var(--link-hover); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px 3rem; }
@media (min-width: 40rem) { .wrap { padding: 0 24px 3rem; } }

/* ---- header ---- */
.site-head {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 1rem 0; flex-wrap: wrap;
}
.brand { display: inline-flex; align-items: center; gap: 0.5rem; text-decoration: none; color: var(--ink); }
.brand svg { width: 40px; height: 40px; }
@media (min-width: 60rem) { .brand svg { width: 44px; height: 44px; } }
.brand b { font-family: var(--head); font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }
.head-sp { flex: 1; }

/* Pressable buttons: 4px bottom edge, press drops to 2px + shift. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 52px; padding: 0.7rem 1.4rem;
  border: none; border-radius: 16px; cursor: pointer;
  background: var(--blue); color: #fff;
  box-shadow: 0 4px 0 var(--blue-edge);
  font: inherit; font-weight: 800; font-size: 1rem; text-decoration: none;
  white-space: nowrap;
}
.btn:hover { color: #fff; filter: brightness(1.04); }
.btn:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--blue-edge); }
.btn-prem { background: var(--prem); color: var(--ink); box-shadow: 0 4px 0 var(--prem-edge); }
.btn-prem:hover { color: var(--ink); filter: brightness(1.03); }
.btn-prem:active { box-shadow: 0 2px 0 var(--prem-edge); }
.btn-outline {
  background: var(--card); color: var(--ink);
  border: 2px solid var(--ink); box-shadow: 0 4px 0 var(--ink);
}
.btn-outline:hover { color: var(--ink); }
.btn-outline:active { box-shadow: 0 2px 0 var(--ink); }
.btn-sm { min-height: 44px; padding: 0.45rem 1.1rem; }
.btn-block { width: 100%; min-height: 56px; }
@media (prefers-reduced-motion: reduce) {
  .btn:active { transform: none; }
}
.acct-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 999px;
  background: var(--card); border: 2px solid var(--ink); color: var(--ink);
  font: inherit; font-weight: 700; cursor: pointer; text-decoration: none;
}
button.linklike { background: none; border: none; padding: 0; color: var(--link); font: inherit; font-weight: 700; cursor: pointer; text-decoration: underline; }
.signin-plain { display: inline-flex; align-items: center; min-height: 44px; }

/* ---- picker hero ---- */
.hero { display: grid; gap: 1.5rem; margin: 1.5rem 0 3.5rem; }
@media (min-width: 60rem) { .hero { grid-template-columns: 1.1fr 1fr; align-items: center; } }
.eyebrow { color: var(--link); font-weight: 800; margin: 0 0 0.5rem; }
.display {
  font-family: var(--head); font-weight: 800; letter-spacing: -0.03em;
  font-size: 2.125rem; line-height: 1.08; margin: 0 0 1rem;
}
@media (min-width: 60rem) { .display { font-size: 4rem; } }
.display-sm { font-size: 2.125rem; }
@media (min-width: 60rem) { .display-sm { font-size: 2.5rem; } }
.lede { color: var(--ink-soft); font-size: 1.05rem; margin: 0 0 1rem; max-width: 34rem; }
.free-line { display: flex; gap: 0.5rem; align-items: center; font-weight: 700; margin: 0; }
.free-line svg { flex: 0 0 auto; background: var(--sun); border-radius: 999px; padding: 3px; color: var(--ink); }

.demo {
  background: var(--card); border: 2px solid var(--ink); border-radius: 24px; overflow: hidden;
  box-shadow: 0 18px 40px -24px rgba(14, 27, 61, 0.5);
}
.demo img { display: block; width: 100%; height: 220px; object-fit: cover; background: var(--wash); }
.demo-body { padding: 1.1rem 1.25rem 1.25rem; }
.demo-kicker { color: var(--muted); font-size: 0.9rem; margin: 0 0 0.15rem; }
.demo-phrase { font-family: var(--head); font-weight: 800; font-size: 1.5rem; letter-spacing: -0.01em; margin: 0 0 0.9rem; }
.demo-phrase small { display: block; font-family: var(--body-font); font-weight: 600; font-size: 0.95rem; color: var(--muted); letter-spacing: 0; }
.demo-actions { display: flex; gap: 0.6rem; flex-wrap: wrap; }

/* ---- picker language tiles (solid tile color, ink text) ---- */
.section-h { font-family: var(--head); font-weight: 800; font-size: 1.75rem; letter-spacing: -0.02em; margin: 0 0 1rem; }
.section-h-sm { font-size: 1.2rem; }
.lang-grid { display: grid; gap: 0.75rem; grid-template-columns: 1fr; margin-bottom: 3.5rem; }
@media (min-width: 36rem) { .lang-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 60rem) { .lang-grid { grid-template-columns: repeat(5, 1fr); gap: 1rem; } }
.lang-card {
  display: flex; flex-direction: column;
  background: var(--tile); color: var(--ink);
  border-radius: 20px; overflow: hidden; text-decoration: none;
  min-height: 13rem; padding: 1.25rem 1.1rem 1.1rem; position: relative;
}
.lang-card:hover { color: var(--ink); }
.lang-greet {
  display: block;
  font-family: var(--head); font-weight: 800; font-size: 1.9rem; letter-spacing: -0.02em;
}
.lang-body { display: block; margin-top: auto; padding-top: 1rem; }
.lang-own { display: block; font-weight: 800; font-size: 1.05rem; }
.lang-sub { display: block; font-weight: 600; font-size: 0.95rem; }
.lang-prog { display: block; font-weight: 800; font-size: 0.95rem; margin-top: 0.15rem; text-decoration: underline; }
.tag {
  position: absolute; top: 0.7rem; right: 0.7rem;
  background: var(--ink); color: #fff;
  font-size: 0.75rem; font-weight: 700;
  border-radius: 999px; padding: 0.2rem 0.65rem;
  white-space: nowrap;
}

/* ---- picker steps + band + footer ---- */
.steps-grid { display: grid; gap: 0.75rem; grid-template-columns: 1fr; margin-bottom: 3.5rem; }
@media (min-width: 60rem) { .steps-grid { grid-template-columns: repeat(4, 1fr); gap: 1rem; } }
.step-card { background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 1rem 1.1rem; }
@media (min-width: 60rem) { .step-card { border-radius: 18px; } }
.step-ic {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 999px;
  background: var(--tic, var(--line)); color: var(--ink); margin-bottom: 0.5rem;
}
.step-card h3 { font-family: var(--head); font-weight: 800; font-size: 1.05rem; margin: 0 0 0.2rem; }
.step-card p { color: var(--muted); font-size: 0.95rem; margin: 0; }

.band {
  display: flex; gap: 1rem; align-items: center; justify-content: space-between; flex-wrap: wrap;
  background: var(--ink); color: #fff; border-radius: 24px;
  padding: 1.25rem 1.5rem; margin-bottom: 2.5rem;
}
.band b { display: block; font-family: var(--head); font-weight: 800; font-size: 1.15rem; }
.band span { color: var(--band-soft); font-size: 0.95rem; }

.site-foot {
  display: flex; gap: 0.5rem 1.5rem; align-items: center; flex-wrap: wrap;
  color: var(--muted); font-size: 0.95rem; padding-top: 1rem;
}
.site-foot .foot-brand { color: var(--muted); }
.site-foot nav { display: flex; gap: 1.25rem; margin-left: auto; flex-wrap: wrap; }

/* ---- returning picker: keep going + list ---- */
.keep {
  background: var(--card); border: 2px solid var(--ink); border-radius: 20px;
  padding: 1.1rem 1.25rem; margin-bottom: 2rem;
}
.keep-top { display: flex; gap: 1rem; align-items: center; margin-bottom: 0.75rem; }
.keep-chip {
  flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
  min-width: 3.5rem; min-height: 3.5rem; padding: 0 0.75rem; border-radius: 14px;
  background: var(--tile); color: var(--ink);
  font-family: var(--head); font-weight: 800; font-size: 1.1rem;
}
.keep-info b { font-family: var(--head); font-weight: 800; font-size: 1.3rem; }
.keep-info span { display: block; color: var(--muted); }
.keep-bar { height: 8px; border-radius: 4px; background: var(--line); margin: 0 0 1rem; overflow: hidden; }
.keep-bar i { display: block; height: 100%; background: var(--blue); border-radius: 4px; }
.start-list { display: grid; gap: 0.75rem; grid-template-columns: 1fr; }
.start-row {
  display: flex; gap: 0.75rem; align-items: center;
  background: var(--tile); color: var(--ink);
  border-radius: 16px; padding: 0.9rem 1.1rem;
  text-decoration: none; min-height: 56px;
}
.start-row:hover { color: var(--ink); }
.start-row b { font-size: 1.05rem; font-weight: 800; }
.start-row span span { display: block; font-size: 0.95rem; font-weight: 600; }
.start-row .chev { margin-left: auto; font-size: 1.4rem; line-height: 1; font-weight: 800; }
.mini-tag {
  display: inline-block; background: var(--ink); color: #fff;
  font-size: 0.75rem; font-weight: 700; border-radius: 999px;
  padding: 0.15rem 0.6rem; margin-left: 0.5rem; vertical-align: middle;
}

/* ---- course top bar ---- */
.chip {
  display: inline-flex; align-items: center; gap: 0.3rem;
  border: 2px solid var(--ink); background: var(--card); color: var(--ink);
  border-radius: 999px; padding: 0.35rem 0.85rem; min-height: 44px;
  text-decoration: none; font-weight: 800; white-space: nowrap;
}
.chip:hover { color: var(--ink); }
.badge-premium-top {
  display: inline-flex; align-items: center; gap: 0.35rem;
  background: var(--ink); color: var(--sun); border-radius: 999px;
  padding: 0.35rem 0.85rem; min-height: 44px; font-weight: 800; white-space: nowrap;
}

/* ---- continue card ---- */
.cont {
  display: grid; grid-template-columns: 1fr;
  background: var(--card); border: 2px solid var(--ink); border-radius: 24px;
  overflow: hidden; margin: 1rem 0 0.6rem;
  box-shadow: 0 18px 40px -24px rgba(14, 27, 61, 0.5);
}
@media (min-width: 60rem) { .cont { grid-template-columns: 2fr 3fr; } }
.cont-photo { background: var(--wash); min-height: 180px; }
.cont-photo img { display: block; width: 100%; height: 100%; min-height: 180px; max-height: 260px; object-fit: cover; }
@media (min-width: 60rem) { .cont-photo img { max-height: none; } }
.cont-body { padding: 1.25rem 1.25rem 1.4rem; }
@media (min-width: 60rem) { .cont-body { padding: 1.5rem 1.75rem; } }
.cont-label { color: var(--link); font-weight: 800; font-size: 0.95rem; margin: 0 0 0.25rem; }
.cont-title {
  font-family: var(--head); font-weight: 800; letter-spacing: -0.02em;
  font-size: 1.375rem; line-height: 1.15; margin: 0 0 0.4rem;
}
@media (min-width: 60rem) { .cont-title { font-size: 2rem; } }
.cont-ctx { color: var(--muted); margin: 0 0 0.9rem; }
.pills { display: none; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
@media (min-width: 60rem) { .pills { display: flex; } }
.pill {
  border: 2px solid var(--line); border-radius: 999px;
  padding: 0.2rem 0.75rem; font-size: 0.9rem; font-weight: 700; color: var(--ink-soft);
  background: var(--card); white-space: nowrap;
}
.pill-done { background: var(--sun); border-color: var(--sun); color: var(--ink); }
.pill-next { border-color: var(--ink); color: var(--ink); }
.stepbars { display: grid; gap: 0.6rem; margin-bottom: 1.1rem; }
.stepbars.four { grid-template-columns: repeat(4, 1fr); }
.stepbars.three { grid-template-columns: repeat(3, 1fr); }
@media (min-width: 60rem) { .stepbars { display: none; } }
.stepbar i { display: block; height: 8px; border-radius: 4px; background: var(--line); }
.stepbar.done i { background: var(--blue); }
.stepbar.next i { background: var(--sun); }
.stepbar span { display: block; font-size: 0.8rem; font-weight: 800; color: var(--ink); margin-top: 0.25rem; }
.stepbar.todo span { color: var(--muted); font-weight: 600; }

.signin-line { color: var(--muted); font-size: 0.95rem; margin: 0 0 1rem; }

/* ---- level tabs ---- */
.tabs {
  position: sticky; top: 0; z-index: 1;
  display: flex; gap: 0.5rem; overflow-x: auto;
  background: var(--bg); padding: 0.6rem 0; margin-bottom: 0.5rem;
}
.tab {
  flex: 0 0 auto; display: inline-flex; gap: 0.6rem; align-items: baseline;
  background: var(--card); border: 2px solid var(--line); border-radius: 12px;
  padding: 0.55rem 1rem; min-height: 48px;
  text-decoration: none; color: var(--ink); font-weight: 800; white-space: nowrap;
}
@media (min-width: 60rem) { .tab { flex: 1 1 0; justify-content: center; } }
.tab:hover { color: var(--ink); }
.tab .cnt { font-weight: 700; color: var(--muted); font-size: 0.9rem; }
.tab[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.tab[aria-current="page"] .cnt { color: var(--sun); }
.tab-off {
  flex: 0 0 auto; display: inline-flex; gap: 0.6rem; align-items: baseline;
  border: 2px dashed var(--line); border-radius: 12px;
  padding: 0.55rem 1rem; min-height: 48px; white-space: nowrap;
  color: var(--muted); font-weight: 600; background: transparent;
}
@media (min-width: 60rem) { .tab-off { flex: 1 1 0; justify-content: center; } }

/* ---- units + lesson cards ---- */
.unit { margin: 2.5rem 0; scroll-margin-top: 5rem; }
.unit-head { display: flex; gap: 0.75rem; align-items: center; margin-bottom: 0.9rem; }
.ubadge {
  flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
  width: 2rem; height: 2rem; border-radius: 10px;
  background: var(--tile); color: var(--ink);
  font-family: var(--head); font-weight: 800; font-size: 1.1rem;
}
.unit-head h2 { font-family: var(--head); font-weight: 800; font-size: 1.25rem; letter-spacing: -0.01em; margin: 0; }
@media (min-width: 60rem) { .unit-head h2 { font-size: 1.375rem; } }
.unit-head .cnt { margin-left: auto; color: var(--muted); font-weight: 600; white-space: nowrap; }
.lgrid { display: grid; gap: 0.75rem; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 60rem) { .lgrid { grid-template-columns: repeat(4, 1fr); gap: 1rem; } }
.lcard {
  display: block; background: var(--card); border: 2px solid var(--line);
  border-radius: 16px; overflow: hidden; text-decoration: none; color: var(--ink);
}
@media (min-width: 60rem) { .lcard { border-radius: 18px; } }
.lcard:hover { color: var(--ink); }
.lcard.now { border-color: var(--ink); }
.thumb { display: block; position: relative; height: 96px; background: var(--wash); }
@media (min-width: 60rem) { .thumb { height: 132px; } }
.thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.thumb.locked { background: var(--wash); }
.thumb.locked img { filter: grayscale(1); opacity: 0.55; }
.lbadge {
  position: absolute; top: 0.55rem; left: 0.55rem;
  display: inline-flex; align-items: center; gap: 0.3rem;
  border-radius: 999px; padding: 0.2rem 0.65rem;
  font-size: 0.78rem; font-weight: 800;
}
.lbadge.free { background: var(--sun); color: var(--ink); }
.lbadge.premium { background: var(--prem); color: var(--ink); }
.lbadge.done { background: var(--ink); color: #fff; }
.lbadge.done svg { color: var(--sun); }
.lbody { display: block; padding: 0.7rem 0.85rem 0.85rem; }
.lnum { display: block; color: var(--muted); font-size: 0.85rem; font-weight: 600; }
.ltitle { display: block; font-family: var(--head); font-weight: 800; font-size: 0.875rem; line-height: 1.3; margin: 0.1rem 0 0.5rem; min-height: 2.3em; }
@media (min-width: 60rem) { .ltitle { font-size: 1rem; } }
.segs { display: flex; gap: 4px; }
.segs i { flex: 1; height: 8px; border-radius: 4px; background: var(--line); }
.segs i.on { background: var(--blue); }
.lstatus { display: block; font-size: 0.85rem; color: var(--muted); margin-top: 0.3rem; }
.lstatus strong { color: var(--ink-soft); }
