/* Matignon-Design – übernommen von cliniquematignon.ch:
   Schrift Antarctica (Condensed ExtraBold 900 / Bold 700 / SemiBold 500, Regular 400),
   Schwarz #000 / Weiß #FFF, Lime #B3EC00 (Hero, Highlights), Violett #997ADB (kleine Labels),
   Buttons: Radius 9px, Rahmen 0.8px, Condensed SemiBold; Überschriften Versalien mit Punkt. */

@font-face { font-family: "Antarctica Condensed"; font-weight: 900; font-style: normal; font-display: swap; src: url("/fonts/Antarctica-CondensedExtraBold.woff2") format("woff2"); }
@font-face { font-family: "Antarctica Condensed"; font-weight: 700; font-style: normal; font-display: swap; src: url("/fonts/Antarctica-CondensedBold.woff2") format("woff2"); }
@font-face { font-family: "Antarctica Condensed"; font-weight: 500; font-style: normal; font-display: swap; src: url("/fonts/Antarctica-CondensedSemiBold.woff2") format("woff2"); }
@font-face { font-family: "Antarctica"; font-weight: 400; font-style: normal; font-display: swap; src: url("/fonts/Antarctica-Regular.woff2") format("woff2"); }

:root {
  --black: #000000; --white: #FFFFFF; --lime: #B3EC00; --violet: #997ADB; --cyan: #00FFFF;
  --grey: #6E6E6E; --grey-line: #D9D9D9; --grey-bg: #F4F4F4; --red: #CC1818;
  --ink: var(--black); --ground: var(--white);
  --cond: "Antarctica Condensed", "Barlow Condensed", "Arial Narrow", sans-serif;
  --body: "Antarctica", "Barlow", "Helvetica Neue", Arial, sans-serif;
  --radius: 9px; --border: 0.8px solid var(--black);
  --gutter: 20px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--ground); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.4;
  padding: 0; min-height: 100vh; -webkit-font-smoothing: antialiased;
}
.page { max-width: 640px; margin-inline: auto; display: flex; flex-direction: column; min-height: 100vh; }
main { display: flex; flex-direction: column; }
section { display: flex; flex-direction: column; }
p { margin: 0; }

/* ---- Kopf wie auf der Website: Logo links, feine schwarze Linie darunter ---- */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: calc(18px + env(safe-area-inset-top, 0px)) var(--gutter) 16px; border-bottom: 1px solid var(--black);
}
.brand { display: flex; align-items: center; text-decoration: none; color: var(--black); }
.brand img { height: 21px; width: auto; display: block; }  /* Logo ist 1118×99 – bei 21px ca. 237px breit */
.wordmark { font-family: var(--cond); font-weight: 900; font-size: 30px; letter-spacing: -.01em; line-height: 1; }
.tagline { font-family: var(--body); font-size: 13px; margin-left: 8px; color: var(--black); }
.menu { display: flex; gap: 6px; align-items: center; }
.lang { display: flex; gap: 2px; }
.lang button { font: 500 14px var(--cond); background: none; border: 0.8px solid transparent; border-radius: 6px; padding: 5px 8px; cursor: pointer; color: var(--grey); }
.lang button[aria-pressed="true"] { color: var(--black); border-color: var(--black); }

/* ---- Typografie ---- */
h1 { font-family: var(--cond); font-weight: 900; font-size: clamp(38px, 10.5vw, 52px); line-height: .96; margin: 0; text-transform: uppercase; text-wrap: balance; }
h2 { font-family: var(--cond); font-weight: 900; font-size: 26px; line-height: 1; margin: 0; text-transform: uppercase; }
h3 { font-family: var(--cond); font-weight: 500; font-size: 18px; margin: 0; line-height: 1.15; }
.lead { font-size: 16px; max-width: 42ch; }
.fine { font-size: 13.5px; color: var(--grey); max-width: 60ch; }
.week { font-size: 15px; }
.center { text-align: center; margin-inline: auto; }
.eyebrow { font-family: var(--body); font-size: 14px; color: var(--violet); display: block; }

/* ---- Hero in Lime, wie die Startseite ---- */
.hero { background: var(--lime); color: var(--white); padding: 36px var(--gutter) 32px; display: flex; flex-direction: column; gap: 10px; }
.hero .week { color: var(--black); font-size: 15px; }

/* ---- Inhalt ---- */
.content { padding: 22px var(--gutter) 26px; display: flex; flex-direction: column; gap: 16px; }
.card { background: var(--white); border: var(--border); border-radius: var(--radius); padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.card.soft { border-color: var(--grey-line); }
.card.black { background: var(--black); color: var(--white); border-color: var(--black); }

/* Standort: Karte wie "Clinique / MORGES" – natives Select liegt unsichtbar darüber */
.loc-card { position: relative; border: var(--border); border-radius: var(--radius); padding: 16px 52px 16px 18px; display: flex; flex-direction: column; gap: 4px; background: var(--white); }
.loc-card .eyebrow { font-size: 14px; }
.loc-name { font: 900 30px/1 var(--cond); text-transform: uppercase; letter-spacing: .005em; }
.loc-name.placeholder { color: var(--grey); font-weight: 500; text-transform: none; font-size: 22px; }
.loc-hint { font-size: 13.5px; color: var(--grey); margin-top: 4px; }
.loc-card .chev { position: absolute; right: 22px; top: 50%; width: 11px; height: 11px; border-right: 1.6px solid var(--black); border-bottom: 1.6px solid var(--black); transform: translateY(-70%) rotate(45deg); }
.loc-card select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 16px; }
.loc-card:has(select:focus-visible) { outline: 2px solid var(--black); outline-offset: 2px; }
.loc-card:active { background: var(--grey-bg); }

/* Fortschritt: schmale Lime-Linie direkt unter dem Hero */
.progress { height: 5px; background: var(--grey-line); }
.progress i { display: block; height: 100%; width: 0; background: var(--lime); transition: width .25s ease; }

/* Fragen */
.sheet { display: flex; flex-direction: column; gap: 14px; }
.q { border: var(--border); border-radius: var(--radius); padding: 18px 18px 14px; display: flex; flex-direction: column; gap: 16px; background: var(--white); transition: box-shadow .2s ease; }
.q:has(input:checked) { box-shadow: inset 0 0 0 1px var(--black); }
.qhead { display: flex; flex-direction: column; gap: 4px; }
.qtext { font: 500 21px/1.15 var(--cond); text-wrap: balance; }

.faces { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.faces input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.faces label {
  display: flex; flex-direction: column; align-items: center; gap: 6px; min-height: 44px; padding: 6px 0 4px; border-radius: var(--radius); cursor: pointer;
  font: 500 15px var(--cond); transition: transform .2s ease, opacity .2s ease; -webkit-tap-highlight-color: transparent;
  /* vor der Auswahl blass: helle Tönung der jeweiligen Farbe, Züge in abgeschwächter Farbe */
  --c: var(--black);
  --face-fill: color-mix(in srgb, var(--c) 22%, var(--white));
  color: color-mix(in srgb, var(--c) 55%, #8A8A8A);
}
.faces label span { color: var(--grey); }
.faces svg, .face { width: 100%; max-width: 66px; height: auto; display: block; aspect-ratio: 1; }
/* Die Gesichter kommen aus <use>-Symbolen: dorthin gelangen nur vererbte Werte, deshalb Custom Properties */
.head { fill: var(--face-fill, var(--white)); stroke: currentColor; stroke-width: var(--face-sw, 1.6); transition: fill .2s ease, stroke-width .2s ease; }
.eye { fill: currentColor; }
.mouth { fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.faces label:active { transform: scale(.94); }
.faces:has(input:checked) label { opacity: .5; }
.faces input:checked + label { transform: scale(1.12); opacity: 1; --face-fill: var(--c); --face-sw: 2.2; color: var(--black); }
.faces input:checked + label span { color: var(--black); }
.faces input:focus-visible + label { outline: 2px solid var(--black); outline-offset: 2px; }
.chosen { display: flex; justify-content: space-between; font-size: 13px; color: var(--grey); min-height: 1.4em; }
.chosen.picked { justify-content: center; font: 500 15px var(--cond); color: var(--black); text-transform: uppercase; }

/* Sendeleiste: bleibt am unteren Rand sichtbar */
.submit-bar { position: sticky; bottom: 0; background: var(--white); border-top: 1px solid var(--black); padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 6px; align-items: center; }
.submit-hint { font-size: 13.5px; color: var(--grey); min-height: 1.3em; }
.btn.busy { background: var(--grey); border-color: var(--grey); }

/* ---- Buttons: wie "LET'S GLOW." / "Réserver un traitement" ---- */
.btn {
  font: 500 19px var(--cond); text-transform: uppercase; border: var(--border); border-radius: var(--radius);
  padding: 13px 20px 12px; cursor: pointer; background: var(--black); color: var(--white); width: 100%; -webkit-tap-highlight-color: transparent;
}
.btn:disabled { background: var(--white); color: var(--grey); border-color: var(--grey-line); cursor: not-allowed; }
.btn.lime { background: var(--lime); color: var(--black); border-color: var(--lime); }
.ghost { font: 500 16px var(--cond); background: var(--white); color: var(--black); border: var(--border); border-radius: var(--radius); padding: 8px 14px 7px; cursor: pointer; text-decoration: none; display: inline-block; text-align: center; }
.ghost.small { padding: 6px 11px 5px; font-size: 14px; }
.ghost:disabled { color: var(--grey-line); border-color: var(--grey-line); cursor: not-allowed; }
.ghost.danger { color: var(--red); border-color: var(--red); }
.black .ghost { background: var(--black); color: var(--white); border-color: var(--white); }
.linkish { background: none; border: 0; color: var(--black); font: 400 15px var(--body); cursor: pointer; padding: 0; text-decoration: underline; text-underline-offset: 3px; }
:is(.btn, .ghost, .linkish, input, select, .tabs button, .lang button):focus-visible { outline: 2px solid var(--black); outline-offset: 2px; }

.status { font-size: 15px; min-height: 1.5em; }
.status.ok { font-weight: 600; }
.status.err { color: var(--red); }
.black .status.err { color: #FF8A80; }

label.field { display: flex; flex-direction: column; gap: 5px; font-size: 14px; color: var(--violet); }
input[type="email"], input[type="password"], input[type="text"], input[type="number"], textarea {
  font: 400 16px var(--body); color: var(--black); background: var(--white); border: var(--border); border-radius: var(--radius); padding: 11px 13px; width: 100%;
}
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.row > * { flex: 1 1 auto; }
.row .btn, .row .ghost { width: auto; flex: 0 0 auto; }

.tabs { display: flex; gap: 0; border-bottom: 1px solid var(--black); overflow-x: auto; margin: 0 var(--gutter); }
.tabs button { font: 500 16px var(--cond); text-transform: uppercase; color: var(--grey); background: none; border: 0; padding: 14px 12px 12px; border-bottom: 2px solid transparent; margin-bottom: -1px; cursor: pointer; white-space: nowrap; }
.tabs button[aria-selected="true"] { color: var(--black); border-bottom-color: var(--black); }

/* ---- Danke / Pause: schwarzer Block wie "Trouvez votre traitement" ---- */
.done { background: var(--black); color: var(--white); padding: 40px var(--gutter) 36px; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.done .face { width: 84px; color: var(--lime); }
.done { --face-fill: transparent; --face-sw: 2; }
.done h1 { font-size: clamp(52px, 15vw, 76px); }
.done .week { color: var(--white); font-size: 16px; max-width: 40ch; }

/* ---- Auswertung ---- */
.weeknav { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.weeknav strong { font: 900 22px var(--cond); text-transform: uppercase; font-variant-numeric: tabular-nums; text-align: center; }
.result { padding: 18px 0; display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; align-items: start; border-top: 1px solid var(--grey-line); }
.avg { font: 900 38px var(--cond); line-height: 1; font-variant-numeric: tabular-nums; text-align: right; }
.avg small { display: block; font: 400 12px var(--body); color: var(--grey); margin-top: 4px; }
.dist { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; align-items: end; }
.dist div { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12.5px; color: var(--grey); font-variant-numeric: tabular-nums; }
.dist .col { height: 52px; width: 100%; display: flex; align-items: flex-end; border-bottom: 1px solid var(--black); }
.dist i { display: block; width: 100%; background: var(--lime); min-height: 2px; }
.dist b { color: var(--black); font-weight: 600; }
.empty { padding: 16px 0; color: var(--grey); }
table { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
th, td { text-align: left; padding: 9px 6px; border-bottom: 1px solid var(--grey-line); vertical-align: middle; }
th { font: 500 14px var(--cond); color: var(--grey); text-transform: uppercase; }
td.num, th.num { text-align: right; }
.table-wrap { overflow-x: auto; }
.pill { display: inline-block; padding: 3px 9px 2px; border-radius: 999px; font: 500 13px var(--cond); text-transform: uppercase; background: var(--black); color: var(--white); }
.pill.warn { background: var(--white); color: var(--black); border: var(--border); }
.legend { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13.5px; color: var(--grey); margin: 0; padding: 0; list-style: none; }
.legend li { display: flex; align-items: center; gap: 6px; }
.legend i { width: 16px; height: 3px; display: block; }
.chart { overflow-x: auto; }
.chart svg { display: block; width: 100%; min-width: 320px; height: auto; }
.chart text { fill: var(--grey); font: 400 11px var(--body); }
.chart .grid { stroke: var(--grey-line); }
:root { --l1: #000000; --l2: #B3EC00; --l3: #997ADB; }
dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; font-size: 15px; }
dt { color: var(--grey); }
dd { margin: 0; overflow-wrap: anywhere; }
.share-text { font: 400 15px var(--body); white-space: pre-wrap; background: var(--grey-bg); border-radius: var(--radius); padding: 14px; margin: 0; }

footer { padding: 0 var(--gutter) calc(30px + env(safe-area-inset-bottom, 0px)); margin-top: auto; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
