/* Hormona prototype – built from the 2022 hi-fi mock-ups and lo-fi sketches.
   The palette is the app's own: a warm cream page, coral for what you press,
   peach for the cycle, a deep red for the period and the blue it uses for
   progesterone. Labels are set in tracked capitals the way the original app
   sets them; everything you read is in sentence case. */
:root {
  --cream: #f7f3ee;
  --sand: #f3e6db;
  --sand-deep: #ecd6c5;
  --white: #ffffff;
  --coral: #ee5a3e;
  --coral-press: #d94a30;
  --coral-ink: #c63d24;      /* coral dark enough for small text on cream */
  --peach: #f6b495;
  --peach-soft: #fbdccb;
  --period: #d63b28;
  --blue: #4b5fd6;
  --blue-soft: #c9cff6;
  --navy: #15234a;
  --ink: #1f2133;
  --ink-2: #5d5f6e;
  --line: #e4dcd3;
  --grey-dot: #d8d3cd;

  --font: "Jost", system-ui, sans-serif;
  --tabbar-h: 68px;
  --tap: 44px;
  --pad: 22px;
  --radius: 16px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: #e9e2da;
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
a { color: inherit; text-decoration: none; }
p, h1, h2, h3, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
[hidden] { display: none !important; }
svg { display: block; }

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

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

/* One phone-wide column. On a wider screen it stands in the middle like a
   device, so the prototype is never stretched into a website. */
.app {
  position: relative;
  max-width: 430px;
  min-height: 100dvh;
  margin: 0 auto;
  background: var(--cream);
  overflow-x: hidden;
}

@media (min-width: 600px) {
  .app {
    min-height: 0;
    height: min(900px, calc(100dvh - 48px));
    margin: 24px auto;
    border-radius: 36px;
    box-shadow: 0 30px 80px rgba(60, 35, 20, 0.18);
    overflow: hidden;
  }
  #view { height: 100%; overflow-y: auto; }
}

#view {
  padding-bottom: calc(var(--tabbar-h) + 28px);
  min-height: 100dvh;
}

@media (min-width: 600px) {
  #view { min-height: 0; }
}

.label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-2);
}

/* ---------- Top bars ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: var(--tap) 1fr var(--tap);
  align-items: center;
  padding: 14px 12px;
  background: var(--sand);
}

.topbar__title {
  text-align: center;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.icon-btn {
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  border-radius: 50%;
}

.icon-btn svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Home ---------- */
.home-head {
  position: relative;
  padding: 26px var(--pad) 8px;
  text-align: center;
}

.home-head .icon-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  color: var(--coral);
}

.home-head h1 {
  font-size: 17px;
  font-weight: 400;
}

.home-head h1 strong {
  display: block;
  margin-top: 2px;
  font-size: 21px;
  font-weight: 600;
}

.disclosure {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: var(--tap);
  font-size: 14px;
  color: var(--ink-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.disclosure svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  transition: transform 0.2s ease;
}

.disclosure[aria-expanded="true"] svg { transform: rotate(180deg); }

/* Cards scroll sideways and snap, so the next one always shows its edge and
   says there is more without a dot row underneath. */
.cards {
  display: flex;
  gap: 12px;
  padding: 4px var(--pad) 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.cards::-webkit-scrollbar { display: none; }

.insight-card {
  flex: 0 0 74%;
  scroll-snap-align: start;
  scroll-margin-left: var(--pad);
  padding: 16px 18px;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 4px 18px rgba(120, 70, 40, 0.10);
  text-align: left;
}

.insight-card h3 { font-size: 17px; font-weight: 600; }
.insight-card small { display: block; margin: 2px 0 10px; font-size: 12px; color: var(--ink-2); }
.insight-card p { font-size: 14px; line-height: 1.45; color: var(--ink); }
.insight-card .card-icon { width: 30px; height: 30px; margin-bottom: 10px; }

/* ---------- Hormone chart ---------- */
.chart {
  position: relative;
  margin-top: 6px;
}

.chart svg { width: 100%; height: auto; }

.chart__labels {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.chart__labels span {
  position: absolute;
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--white);
  translate: -50% 0;
}

.chart__labels .on-light { color: var(--coral-ink); }

/* The scrubber is a native range input, so it works by keyboard and screen
   reader; only its look is replaced. The track is the cycle's own gradient. */
.scrub {
  position: relative;
  height: 26px;
  margin-top: -13px;
}

.scrub__track {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 26px;
  background: linear-gradient(90deg, #e98a73, #f3c2a6 45%, #b9b5ea 75%, #8f9be6);
}

.scrub input {
  position: relative;
  width: 100%;
  height: 26px;
  margin: 0;
  background: transparent;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.scrub input::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 2.5px solid var(--ink);
  background: var(--white);
}

.scrub input::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2.5px solid var(--ink);
  background: var(--white);
}

.phases {
  display: flex;
  justify-content: space-between;
  padding: 12px var(--pad) 0;
}

.phases span {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #9a97a3;
}

.phases span.is-current { color: var(--ink); font-weight: 600; }

.chart-caption {
  padding: 8px var(--pad) 0;
  font-size: 13px;
  color: var(--ink-2);
  min-height: 26px;
}

/* ---------- Buy test and Tomorrow ---------- */
.actions-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  align-items: center;
  padding: 16px var(--pad) 4px;
}

.actions-row p {
  grid-column: 1 / -1;
  font-size: 13px;
  color: var(--ink-2);
}

.buy-test {
  display: grid;
  place-items: center;
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: var(--peach-soft);
  color: var(--coral-ink);
  font-size: 19px;
  line-height: 1.1;
  font-weight: 500;
  text-align: center;
  box-shadow: 0 6px 16px rgba(238, 90, 62, 0.18);
  transition: transform 0.15s ease;
}

.buy-test:active { transform: scale(0.96); }

.pill-dark {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: var(--tap);
  padding: 0 18px;
  border-radius: 10px;
  background: var(--navy);
  color: var(--white);
  font-size: 16px;
}

.pill-dark svg, .next-link svg, .row-link svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Cycle ring ---------- */
.ring {
  position: relative;
  width: min(330px, 86%);
  aspect-ratio: 1;
  margin: 18px auto 8px;
}

.ring__day {
  position: absolute;
  display: grid;
  place-items: center;
  width: 9.6%;
  aspect-ratio: 1;
  translate: -50% -50%;
  border-radius: 50%;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--white);
  background: var(--peach);
}

.ring__day.is-period { background: var(--period); }
.ring__day.is-fertile { background: #f28a6c; }
.ring__day.is-past { background: var(--grey-dot); color: var(--white); }
.ring__day.is-past.is-period { background: #e0806f; }
.ring__day.is-today {
  background: var(--white);
  color: var(--ink);
  box-shadow: 0 0 0 2px var(--blue), 0 0 0 5px var(--blue-soft);
  font-weight: 600;
}

.ring__centre {
  position: absolute;
  inset: 22%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 4px;
  text-align: center;
}

.ring__centre p { font-size: 14px; color: var(--ink-2); }
.ring__centre strong { font-size: 22px; font-weight: 600; }

.ring__cal {
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  margin-top: 4px;
  border-radius: 50%;
  background: var(--white);
  color: var(--coral);
  box-shadow: 0 3px 10px rgba(120, 70, 40, 0.14);
}

.ring__cal svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

.ring-legend {
  display: flex;
  justify-content: center;
  gap: 16px;
  padding: 0 var(--pad);
  font-size: 12px;
  color: var(--ink-2);
}

.ring-legend i {
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 6px;
  border-radius: 50%;
  vertical-align: -1px;
}

/* ---------- Tomorrow ---------- */
.sheet-head {
  padding: 30px var(--pad) 6px;
  background: var(--sand);
  text-align: center;
}

.sheet-head h1 { font-size: 26px; font-weight: 600; }
.sheet-head .label { display: block; margin-bottom: 4px; }
.sheet-band { background: var(--sand); padding-top: 8px; }

/* ---------- Daily insight ---------- */
.insight-hero {
  position: relative;
  padding: 26px var(--pad) 26px;
  background:
    radial-gradient(120% 140% at 105% -10%, var(--peach) 0 38%, transparent 38.5%),
    var(--sand);
  overflow: hidden;
}

.progress {
  display: flex;
  gap: 8px;
  margin: 0 56px 30px 0;
}

.progress span {
  flex: 1;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.85);
}

.progress span.is-done { background: var(--blue); }

.insight-hero .icon-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.insight-hero h1 { margin-top: 6px; font-size: 30px; font-weight: 600; line-height: 1.1; }

.insight-body { padding: 8px var(--pad) 24px; }

.insight-section {
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}

.insight-section:last-of-type { border-bottom: 0; }
.insight-section p { margin-top: 10px; font-size: 19px; line-height: 1.5; }
.insight-section strong { font-weight: 600; }

.insight-icons { display: flex; gap: 16px; margin-top: 16px; }
.insight-icons svg { width: 36px; height: 36px; }

.next-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding: 0 var(--pad);
  background: var(--sand);
  font-size: 14px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

/* ---------- Calendar ---------- */
.month-nav {
  display: grid;
  grid-template-columns: var(--tap) 1fr var(--tap);
  align-items: center;
  padding: 18px 10px 6px;
  text-align: center;
  font-size: 18px;
}

.weekdays, .month-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  padding: 0 14px;
  text-align: center;
}

.weekdays span {
  padding: 8px 0;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: #9a97a3;
}

.month-grid { row-gap: 8px; }

.cal-day {
  position: relative;
  justify-self: center;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--peach-soft);
  color: var(--coral-ink);
  font-size: 15px;
  font-weight: 500;
}

.cal-day.is-period { background: var(--period); color: var(--white); }
.cal-day.is-fertile { background: var(--peach); color: var(--white); }
.cal-day.is-future { background: transparent; color: #a19ea8; box-shadow: inset 0 0 0 1.5px var(--grey-dot); }
.cal-day.is-future.is-period { background: transparent; color: var(--period); box-shadow: inset 0 0 0 1.5px var(--period); }
.cal-day.is-future.is-fertile { background: transparent; color: var(--coral-ink); box-shadow: inset 0 0 0 1.5px var(--peach); }
.cal-day.is-today { box-shadow: 0 0 0 2px var(--cream), 0 0 0 4px var(--blue); }
.cal-day[aria-pressed="true"] { outline: 2px solid var(--ink); outline-offset: 2px; }

.cal-day b {
  position: absolute;
  top: -5px;
  right: -5px;
  display: grid;
  place-items: center;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 9px;
  background: var(--period);
  color: var(--white);
  font-size: 10px;
  font-weight: 600;
  box-shadow: 0 0 0 2px var(--cream);
}

.cal-legend {
  display: flex;
  justify-content: center;
  gap: 18px;
  padding: 18px var(--pad);
  font-size: 13px;
  color: var(--ink-2);
  border-bottom: 1px solid var(--line);
}

.cal-legend i {
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-right: 6px;
  border-radius: 50%;
  vertical-align: -1px;
}

.day-detail { padding: 18px var(--pad); }
.day-detail h2 { font-size: 17px; font-weight: 600; margin-bottom: 8px; }

.log-line {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}

.log-line span:last-child { color: var(--ink-2); }
.empty { color: var(--ink-2); font-size: 15px; }

.fab {
  display: grid;
  place-items: center;
  gap: 2px;
  width: 72px;
  height: 72px;
  margin: 20px auto 0;
  border-radius: 18px;
  background: var(--coral);
  color: var(--white);
  font-size: 12px;
  box-shadow: 0 8px 20px rgba(238, 90, 62, 0.35);
}

.fab svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

/* ---------- Track ---------- */
.track-hero {
  position: relative;
  height: 230px;
  background:
    radial-gradient(60% 80% at 15% 100%, #f39a7e 0 40%, transparent 41%),
    radial-gradient(70% 90% at 95% 10%, var(--peach) 0 45%, transparent 46%),
    radial-gradient(40% 50% at 70% 85%, var(--blue-soft) 0 50%, transparent 51%),
    var(--sand);
}

.track-hero__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
}

.round-btn {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--white);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.10);
}

.round-btn--coral { background: var(--coral); color: var(--white); }
.round-btn svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.date-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: var(--tap);
  padding: 0 22px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  font-size: 15px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.date-pill svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.track-tabs {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 18px;
  display: flex;
  gap: 10px;
  padding: 0 16px;
  overflow-x: auto;
  scrollbar-width: none;
}

.track-tabs::-webkit-scrollbar { display: none; }

.track-tab {
  flex: 0 0 auto;
  min-height: var(--tap);
  padding: 0 22px;
  border-radius: 999px;
  background: var(--white);
  color: var(--coral-ink);
  font-size: 14px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.track-tab[aria-selected="true"] { background: var(--coral); color: var(--white); }

.track-body { padding: 10px var(--pad) 24px; background: #f6ebe2; min-height: calc(100dvh - 230px); }

.track-group { padding: 18px 0 6px; }
.track-group h2 { margin-bottom: 12px; }

.scale {
  display: flex;
  align-items: center;
  gap: 8px;
}

.scale__name { flex: 1; font-size: 18px; }
.scale small { font-size: 12px; color: var(--ink-2); }

.scale button {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: var(--white);
  box-shadow: 0 2px 6px rgba(120, 70, 40, 0.12);
}

.scale button.is-on { background: var(--period); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  min-height: 40px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--white);
  font-size: 15px;
  box-shadow: 0 1px 4px rgba(120, 70, 40, 0.10);
}

.chip[aria-pressed="true"] { background: var(--coral); color: var(--white); }

.save-btn {
  display: block;
  width: 100%;
  min-height: 56px;
  margin-top: 28px;
  border-radius: 999px;
  background: var(--coral);
  color: var(--white);
  font-size: 18px;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 18px rgba(238, 90, 62, 0.28);
}

.save-btn:active { background: var(--coral-press); }

/* ---------- Dashboard ---------- */
.seg {
  display: flex;
  gap: 6px;
  padding: 16px var(--pad) 6px;
}

.seg button {
  flex: 1;
  min-height: 38px;
  border-radius: 999px;
  background: var(--white);
  color: var(--coral-ink);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.seg button[aria-selected="true"] { background: var(--coral); color: var(--white); }

.range-nav {
  display: grid;
  grid-template-columns: var(--tap) 1fr var(--tap);
  align-items: center;
  padding: 4px 10px;
  text-align: center;
  font-size: 14px;
}

.range-nav small { display: block; color: var(--ink-2); font-size: 12px; }

.tracks-chart {
  margin: 6px var(--pad) 0;
  padding: 12px 10px 6px;
  border-radius: var(--radius);
  background: var(--white);
}

.trow {
  display: grid;
  grid-template-columns: 92px 1fr;
  align-items: center;
  gap: 8px;
  min-height: 30px;
}

.trow > span { font-size: 12px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trow svg { width: 100%; height: 20px; }

.tracks-chart .phases { padding: 6px 0 0; }
.tracks-chart .phases span { font-size: 10px; }

.panel {
  margin: 18px var(--pad) 0;
  padding: 18px;
  border-radius: var(--radius);
  background: var(--white);
}

.panel h2 { font-size: 17px; font-weight: 600; margin-bottom: 12px; }
.panel .label { margin: 14px 0 8px; display: block; }

.count-row {
  display: flex;
  justify-content: space-between;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-2);
}

.count-row b { color: var(--ink); font-weight: 600; letter-spacing: 0.06em; }
.count-row:last-child { border-bottom: 0; }

.stat-big {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stat-big div {
  padding: 14px;
  border-radius: 12px;
  background: var(--sand);
}

.stat-big strong { display: block; font-size: 26px; font-weight: 600; }
.stat-big span { font-size: 13px; color: var(--ink-2); }

/* ---------- Shop ---------- */
.shop-item {
  display: grid;
  grid-template-columns: 1fr 96px;
  gap: 8px 14px;
  padding: 28px var(--pad) 10px;
}

.shop-item h2 { font-size: 22px; font-weight: 400; }
.shop-item .price-line { display: flex; justify-content: space-between; margin-top: 10px; font-size: 18px; }
.shop-item .price-line span:first-child { color: var(--coral-ink); }
.shop-item p { grid-column: 1 / -1; font-size: 17px; line-height: 1.55; }
.shop-item svg.test-art { grid-row: 1; grid-column: 2; width: 96px; height: 120px; }

.stepper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 10px 0 20px;
}

.stepper button {
  display: grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  border-radius: 10px;
  background: var(--navy);
  color: var(--white);
  font-size: 22px;
}

.stepper button:disabled { background: #b9bccb; }

.stepper output {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--peach);
  font-size: 20px;
}

.benefits {
  margin: 4px var(--pad) 0;
  padding: 16px 18px;
  border-radius: var(--radius);
  background: var(--sand);
}

.benefits li {
  display: flex;
  gap: 10px;
  padding: 6px 0;
  font-size: 15px;
}

.benefits li::before {
  content: "";
  flex: 0 0 8px;
  height: 8px;
  margin-top: 8px;
  border-radius: 50%;
  background: var(--coral);
}

.total {
  display: flex;
  justify-content: space-between;
  padding: 20px var(--pad) 0;
  font-size: 18px;
}

.total strong { font-weight: 600; }

.pay-wrap { padding: 0 var(--pad); }

/* ---------- Community ---------- */
.community-hero {
  position: relative;
  padding: 34px var(--pad) 30px;
  background:
    radial-gradient(70% 90% at 100% 0%, var(--peach) 0 45%, transparent 46%),
    radial-gradient(40% 60% at 85% 100%, var(--blue-soft) 0 50%, transparent 51%),
    #f9d2c6;
}

.community-hero h1 { font-size: 30px; font-weight: 600; line-height: 1.15; max-width: 12ch; }

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 22px var(--pad) 10px;
}

.section-head h2 { font-size: 19px; font-weight: 500; }
.section-head a { font-size: 13px; color: var(--coral-ink); }

.articles {
  display: flex;
  gap: 12px;
  padding: 0 var(--pad) 4px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.articles::-webkit-scrollbar { display: none; }

.article {
  flex: 0 0 62%;
  scroll-snap-align: start;
  border-radius: 12px;
  background: var(--white);
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(120, 70, 40, 0.08);
}

.article .art { height: 110px; }
.article div { padding: 10px 12px 14px; }
.article small { font-size: 11px; color: var(--ink-2); }
.article h3 { margin-top: 4px; font-size: 15px; font-weight: 500; line-height: 1.3; }

.quiz {
  margin: 20px var(--pad) 0;
  padding: 18px;
  border-radius: var(--radius);
  background: var(--peach-soft);
  text-align: center;
}

.quiz p { margin: 10px 0 14px; font-size: 16px; line-height: 1.45; }

.quiz__answers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1.5px var(--coral);
  overflow: hidden;
}

.quiz__answers button {
  min-height: var(--tap);
  color: var(--coral-ink);
  font-size: 15px;
}

.quiz__answers button + button { box-shadow: -1.5px 0 0 var(--coral); }
.quiz__answers button[aria-pressed="true"] { background: var(--coral); color: var(--white); }
.quiz__result { margin-top: 12px; font-size: 14px; color: var(--ink-2); }

.discussion {
  display: grid;
  grid-template-columns: 1fr 64px;
  gap: 12px;
  margin: 0 var(--pad) 10px;
  padding: 14px;
  border-radius: 12px;
  background: var(--white);
  box-shadow: 0 2px 10px rgba(120, 70, 40, 0.06);
}

.discussion small { font-size: 11px; color: var(--ink-2); }
.discussion h3 { margin: 2px 0 4px; font-size: 16px; font-weight: 500; }
.discussion p { font-size: 13px; color: var(--ink-2); line-height: 1.4; }
.discussion .art { width: 64px; height: 64px; border-radius: 10px; }

/* ---------- Menu ---------- */
.menu-logo {
  display: grid;
  place-items: center;
  padding: 44px 0 30px;
  color: var(--coral);
}

.menu-logo svg { width: 92px; height: 92px; }

.menu-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding: 0 var(--pad);
  border-bottom: 1px solid var(--line);
  font-size: 17px;
}

.row-link svg { color: var(--ink-2); }

.ask {
  display: grid;
  justify-items: center;
  gap: 10px;
  width: calc(100% - 2 * var(--pad));
  margin: 36px var(--pad) 0;
  padding: 24px;
  border-radius: 14px;
  background: var(--navy);
  color: var(--white);
}

.ask .label { color: rgba(255, 255, 255, 0.75); }
.ask strong { font-size: 22px; font-weight: 400; }
.ask svg { width: 34px; height: 34px; }

.answers { padding: 10px var(--pad) 0; }

.qa {
  margin-top: 12px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--white);
}

.qa summary { cursor: pointer; font-weight: 500; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; color: var(--coral); font-size: 20px; line-height: 1; }
.qa[open] summary::after { content: "–"; }
.qa p { margin-top: 10px; font-size: 15px; line-height: 1.5; color: var(--ink-2); }

/* ---------- Tab bar ---------- */
.tabbar {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: end;
  width: min(430px, 100%);
  height: var(--tabbar-h);
  padding-bottom: env(safe-area-inset-bottom);
  translate: -50% 0;
  background: var(--white);
  box-shadow: 0 -1px 0 var(--line);
}

@media (min-width: 600px) {
  .tabbar {
    position: absolute;
    left: 0;
    translate: none;
    width: 100%;
  }
}

.tabbar__item {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 8px 0 10px;
  font-size: 11px;
  color: var(--coral-ink);
}

.tabbar__item svg, .tabbar__track svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tabbar__item[aria-current="page"] { color: var(--navy); font-weight: 600; }
.tabbar__item[aria-current="page"]::before {
  content: "";
  position: absolute;
  top: 0;
  width: 26px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--coral);
}

.tabbar__track {
  justify-self: center;
  display: grid;
  place-items: center;
  width: 64px;
  height: 70px;
  margin-bottom: 8px;
  border-radius: 18px;
  background: var(--coral);
  color: var(--white);
  font-size: 12px;
  box-shadow: 0 8px 18px rgba(238, 90, 62, 0.35);
}

.tabbar__track svg { stroke-width: 2.2; }

.tabbar__badge {
  position: absolute;
  top: 4px;
  left: calc(50% + 6px);
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--period);
  color: var(--white);
  font-size: 11px;
}

/* ---------- Toast and sheet ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--tabbar-h) + 16px);
  z-index: 20;
  max-width: 360px;
  padding: 12px 18px;
  border-radius: 12px;
  background: var(--navy);
  color: var(--white);
  font-size: 15px;
  translate: -50% 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, translate 0.2s ease;
}

.toast.is-on { opacity: 1; translate: -50% 0; }

@media (min-width: 600px) {
  .toast { position: absolute; }
}

.confirm {
  padding: 60px var(--pad) 0;
  text-align: center;
}

.confirm svg { width: 80px; height: 80px; margin: 0 auto 18px; color: var(--coral); }
.confirm h1 { font-size: 26px; font-weight: 600; }
.confirm p { margin: 10px auto 0; max-width: 30ch; font-size: 16px; line-height: 1.5; color: var(--ink-2); }

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