/* KISSKOO · espace de jeu. Reprend la direction artistique validée (Bodoni Moda + Jost, bordeaux, laiton),
   calme au quotidien, spectaculaire seulement aux moments narratifs (boîte qui arrive, révélation, fin). */
:root {
  color-scheme: dark;
  --ink: #0d0507; --deep: #160609; --wine: #3a0d14; --wine2: #24070c;
  --paper: #efe4d2; --mute: rgba(239,228,210,.68); --faint: rgba(239,228,210,.42);
  --brass: #c9a45c; --amber: #ffcf8a; --line: rgba(201,164,92,.24); --ok: #9fd3a8; --err: #ffb4a8;
  --serif: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --sans: "Jost", "Futura", "Avenir Next", system-ui, sans-serif;
  --ease: cubic-bezier(.22,.61,.36,1);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { background: #080304; -webkit-text-size-adjust: 100%; }
body { min-height: 100svh; color: var(--paper); font: 400 16px/1.5 var(--sans); -webkit-font-smoothing: antialiased;
  background: radial-gradient(120% 60% at 50% -10%, rgba(58,13,20,.55), transparent 70%), #080304; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }
img { max-width: 100%; display: block; }
[hidden] { display: none !important; }

/* ---------- cadre ---------- */
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: max(10px, env(safe-area-inset-top)) 18px 10px; background: rgba(8,3,4,.86); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.brand { font-family: var(--serif); font-style: italic; font-size: 23px; text-decoration: none; }
.top nav { display: flex; align-items: center; gap: 4px; }
.top nav a { position: relative; display: inline-flex; align-items: center; min-height: 40px; padding: 0 10px; font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--mute); text-decoration: none; }
.top nav a:hover, .top nav a[aria-current="page"] { color: var(--paper); }
.top nav .badge { position: absolute; top: 2px; right: -8px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--brass); color: #1b0b05; font-size: 10px; letter-spacing: 0; display: grid; place-items: center; }
.recette { padding: 6px 16px; text-align: center; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: #dfe8ff; background: rgba(143,180,255,.12); border-bottom: 1px solid rgba(143,180,255,.25); }
main { width: 100%; max-width: 520px; margin: 0 auto; padding: 22px 18px calc(48px + env(safe-area-inset-bottom)); }
main.large { max-width: 980px; }
.foot { max-width: 520px; margin: 0 auto; padding: 0 18px 40px; font-size: 12px; color: var(--faint); text-align: center; }
.foot a { color: var(--faint); }

/* ---------- typographie ---------- */
.k { font-size: 10.5px; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; color: var(--brass); }
.h { font-family: var(--serif); font-style: italic; font-weight: 400; font-size: 34px; line-height: 1.08; margin: 8px 0 12px; text-wrap: balance; }
.h.s { font-size: 26px; }
.h.xs { font-size: 21px; margin: 4px 0 6px; }
.p { color: var(--mute); }
.p b, .p strong { color: var(--paper); font-weight: 500; }
.p + .p { margin-top: 8px; }
.small { font-size: 13.5px; }
.center { text-align: center; }
.enter > * { animation: rise .7s var(--ease) both; }
.enter > :nth-child(2) { animation-delay: .06s; } .enter > :nth-child(3) { animation-delay: .12s; } .enter > :nth-child(4) { animation-delay: .18s; } .enter > :nth-child(n+5) { animation-delay: .24s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@keyframes fade { from { opacity: 0; } }

/* ---------- boutons et formulaires ---------- */
.cta { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 52px; margin-top: 16px; padding: 0 18px; border-radius: 26px;
  background: var(--brass); color: #1b0b05; font-weight: 500; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; text-decoration: none; text-align: center; transition: background .3s, transform .2s; }
.cta:hover { background: var(--amber); }
.cta:active { transform: scale(.98); }
.cta.ghost { background: transparent; color: var(--paper); border: 1px solid var(--line); }
.cta.ghost:hover { border-color: var(--brass); }
.cta.danger { background: transparent; color: var(--err); border: 1px solid rgba(255,180,168,.4); }
.cta[disabled] { opacity: .4; cursor: not-allowed; }
.lnk { display: block; width: 100%; margin-top: 12px; padding: 10px; font-size: 14px; color: var(--mute); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgba(239,228,210,.25); text-align: center; }
.lnk:hover { color: var(--paper); }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; min-width: 0; }
form.inline { display: inline; }
label.f { display: block; margin-top: 16px; font-size: 14px; color: var(--paper); }
label.f small, .hint { display: block; font-size: 12.5px; color: var(--faint); margin-top: 2px; }
.field, textarea, select { display: block; width: 100%; margin-top: 8px; min-height: 48px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: rgba(0,0,0,.28); color: var(--paper); font-size: 16px; }
textarea { min-height: 90px; resize: vertical; line-height: 1.45; }
.field:focus, textarea:focus, select:focus { border-color: var(--brass); outline: none; }
input[type=date], input[type=time] { color-scheme: dark; }
.code { font-size: 26px; letter-spacing: .4em; text-align: center; font-variant-numeric: tabular-nums; }
.check { display: flex; gap: 12px; align-items: flex-start; margin-top: 14px; font-size: 14.5px; color: var(--mute); }
.check input { width: 22px; height: 22px; accent-color: var(--brass); flex: none; margin-top: 1px; }
.msg { margin-top: 14px; padding: 12px 14px; border-radius: 14px; font-size: 14.5px; }
.msg.err { color: var(--err); background: rgba(255,180,168,.08); border: 1px solid rgba(255,180,168,.3); }
.msg.ok { color: var(--paper); background: rgba(201,164,92,.1); border: 1px solid var(--line); }
.flash { animation: rise .5s var(--ease) both; }

/* ---------- cartes ---------- */
.card { margin-top: 16px; padding: 18px; border: 1px solid var(--line); border-radius: 20px; background: linear-gradient(170deg, rgba(58,13,20,.55), rgba(22,6,9,.6)); }
.card.soft { background: rgba(239,228,210,.035); }
.card.gold { border-color: rgba(201,164,92,.6); box-shadow: inset 0 0 0 1px rgba(201,164,92,.15); }
.card .t { font-family: var(--serif); font-style: italic; font-size: 22px; line-height: 1.2; }
dl.facts div { display: grid; grid-template-columns: 104px 1fr; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
dl.facts div:first-child { border-top: 0; }
dl.facts dt { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--brass); padding-top: 4px; }
.poster { display: flex; gap: 14px; align-items: center; }
.poster img { width: 70px; height: 104px; object-fit: cover; border-radius: 9px; flex: none; border: 1px solid rgba(239,228,210,.14); }
.poster .t { font-size: 24px; }
.who { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 16px; border: 1px solid var(--line); font-size: 13px; color: var(--mute); }
.who b { color: var(--paper); font-weight: 500; }

/* ---------- l'état du duo, en un coup d'œil ---------- */
.now { margin-top: 6px; display: grid; gap: 8px; }
.now .line { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--mute); padding: 9px 0; border-top: 1px solid var(--line); }
.now .line:first-child { border-top: 0; }
.now .line b { color: var(--paper); font-weight: 500; text-align: right; }

/* ---------- choix d'histoire ---------- */
.scpick { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 14px; }
.scpick a { position: relative; aspect-ratio: 2 / 3; border-radius: 16px; overflow: hidden; border: 1px solid var(--line); display: flex; align-items: flex-end; padding: 12px; text-decoration: none; background: #1a070b center / cover; }
.scpick a::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 40%, rgba(8,3,4,.92)); }
.scpick a span { position: relative; z-index: 1; font-family: var(--serif); font-style: italic; font-size: 20px; line-height: 1.1; }
.scpick a small { position: relative; z-index: 1; display: block; font-family: var(--sans); font-style: normal; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--brass); margin-top: 6px; }
.scpick a:hover { border-color: var(--brass); }
.opt { display: block; width: 100%; text-align: left; margin-top: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 18px; text-decoration: none; background: rgba(239,228,210,.03); }
.opt b { display: block; font-family: var(--serif); font-style: italic; font-weight: 400; font-size: 22px; }
.opt span { display: block; font-size: 14px; color: var(--mute); margin-top: 3px; }
.opt:hover, .opt[aria-pressed="true"] { border-color: var(--brass); background: rgba(201,164,92,.1); }
.radios { display: grid; gap: 8px; margin-top: 10px; }
.radios label { position: relative; display: block; padding: 13px 14px 13px 46px; border: 1px solid var(--line); border-radius: 16px; cursor: pointer; font-size: 15px; }
.radios label small { display: block; color: var(--mute); font-size: 13px; }
.radios input { position: absolute; left: 15px; top: 15px; width: 20px; height: 20px; accent-color: var(--brass); }
.radios label:has(input:checked) { border-color: var(--brass); background: rgba(201,164,92,.1); }
.sec { margin-top: 26px; }
.recap { margin-top: 18px; padding: 16px; border-radius: 18px; background: rgba(239,228,210,.05); font-size: 14.5px; }
.recap p + p { margin-top: 6px; }

/* ---------- préparation ---------- */
.grp { margin-top: 22px; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; color: var(--faint); }
.step { margin-top: 8px; border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; }
.step form { display: flex; gap: 12px; align-items: flex-start; }
.step .tick { width: 26px; height: 26px; flex: none; border-radius: 50%; border: 1.5px solid var(--faint); display: grid; place-items: center; font-size: 13px; margin-top: 1px; }
.step.done .tick { background: var(--brass); border-color: var(--brass); color: #1b0b05; }
.step .st { font-size: 15.5px; text-align: left; flex: 1; }
.step.done .st { color: var(--mute); }
.step .sd { margin: 8px 0 0 38px; font-size: 14px; color: var(--mute); }
.step .x { margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: rgba(239,228,210,.05); font-size: 13.5px; }
.step .tag { margin-left: auto; font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); padding-top: 4px; }
details { margin-top: 10px; }
details summary { cursor: pointer; color: var(--brass); font-size: 14px; list-style: none; padding: 6px 0; }
details summary::-webkit-details-marker { display: none; }
details[open] summary { margin-bottom: 4px; }
.reveal { margin-top: 18px; padding: 30px 20px; border-radius: 22px; text-align: center; background: radial-gradient(120% 90% at 50% 0%, rgba(255,207,138,.18), transparent 60%), #1a070b; border: 1px solid rgba(255,207,138,.4); }
.reveal p:not(.k) { font-family: var(--serif); font-style: italic; font-size: 25px; line-height: 1.3; white-space: pre-line; }
.reveal.on { animation: unveil 1.4s var(--ease) both; }
@keyframes unveil { from { opacity: 0; transform: scale(.96); filter: blur(6px); } }
.actions { margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.actions .row .cta { margin-top: 10px; }
.mini { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 16px; margin-top: 12px; }
.mini button, .mini a { padding: 8px 4px; font-size: 13.5px; color: var(--mute); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: rgba(239,228,210,.25); }

/* ---------- la boîte ---------- */
.boxhero { position: relative; margin: 0 -18px; height: 170px; overflow: hidden; display: grid; place-items: center; }
.boxhero::before { content: ""; position: absolute; inset: 0; background: var(--box-img) 50% 55% / cover; opacity: .3; filter: saturate(.8); }
.boxhero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(#080304, transparent 30%, transparent 70%, #080304); }
.boxhero .where { position: absolute; z-index: 2; bottom: 10px; left: 0; right: 0; text-align: center; font-size: 10.5px; letter-spacing: .3em; text-transform: uppercase; color: var(--brass); }
.bx { position: relative; z-index: 1; width: 96px; height: 62px; }
.bx i { position: absolute; display: block; }
.bx .b { left: 0; right: 0; bottom: 0; height: 66%; border-radius: 5px; background: linear-gradient(#701827, #3b0b13); box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 14px 26px rgba(0,0,0,.55); }
.bx .l { left: -4%; right: -4%; top: 10%; height: 30%; border-radius: 5px; background: linear-gradient(#912637, #4d1019); box-shadow: 0 3px 0 rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.18); }
.bx .c { left: 50%; top: 31%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; box-shadow: inset 5px -1px 0 0 #e8c374; }
.bx .g { left: -40%; right: -40%; top: 20%; height: 120%; border-radius: 50%; background: radial-gradient(closest-side, rgba(255,190,110,.45), transparent); z-index: -1; animation: breathe 3.4s ease-in-out infinite; }
@keyframes breathe { 50% { opacity: .45; transform: scale(.9); } }
.bx.away { opacity: .35; filter: grayscale(.5); }
.bx.away .g { display: none; }

/* ---------- moments (plein écran) ---------- */
.moment { position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 40px 26px;
  background: radial-gradient(90% 60% at 50% 40%, #2b0a10, #070203 70%); animation: fade .6s both; }
.moment .bx { transform: scale(1.6); margin: 30px 0 50px; }
.moment.arrive .bx { animation: drop 1.6s var(--ease) .2s both; }
@keyframes drop { 0% { transform: translateY(-260px) scale(1.2) rotate(-12deg); opacity: 0; } 60% { transform: translateY(10px) scale(1.65) rotate(2deg); opacity: 1; } 100% { transform: scale(1.6); } }
.moment .h { font-size: 36px; }
.moment > *:not(.bx) { animation: rise .9s var(--ease) both; }
.moment > :nth-child(2) { animation-delay: .9s; } .moment > :nth-child(3) { animation-delay: 1.1s; } .moment > :nth-child(4) { animation-delay: 1.3s; } .moment > :nth-child(n+5) { animation-delay: 1.5s; }
.moment .cta, .moment .lnk { max-width: 320px; }
.moment[hidden] { display: none; }
.moment.fin .bx { animation: none; }

/* ---------- listes ---------- */
.list { margin-top: 12px; }
.list > * { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0; border-top: 1px solid var(--line); text-decoration: none; }
.list > *:first-child { border-top: 0; }
.list .t { font-family: var(--serif); font-style: italic; font-size: 20px; }
.list small { color: var(--mute); font-size: 13px; }
.film { display: flex; gap: 12px; overflow-x: auto; margin-top: 12px; padding-bottom: 6px; scrollbar-width: none; }
.film figure { flex: none; width: 92px; }
.film img { width: 92px; height: 138px; object-fit: cover; border-radius: 10px; border: 1px solid rgba(239,228,210,.14); }
.film img.non { filter: grayscale(.8) brightness(.7); }
.film figcaption { font-size: 11.5px; line-height: 1.3; color: var(--mute); margin-top: 6px; }
.notif { padding: 14px 0; border-top: 1px solid var(--line); font-size: 14.5px; }
.notif:first-child { border-top: 0; }
.notif time { display: block; font-size: 12px; color: var(--faint); margin-top: 2px; }
.notif.new { color: var(--paper); }
.notif.new::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--brass); margin-right: 8px; vertical-align: 2px; }
.duopick { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.duopick a { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; padding: 6px 12px; border-radius: 14px; border: 1px solid var(--line); text-decoration: none; color: var(--mute); }
.duopick a[aria-current="page"] { color: #1b0b05; background: var(--brass); border-color: var(--brass); }

dialog.dlg { margin: auto; width: calc(100% - 32px); max-width: 440px; padding: 22px; border-radius: 22px; border: 1px solid var(--line); background: #1b070c; color: var(--paper); }
dialog.dlg::backdrop { background: rgba(5,2,3,.75); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}
@media (min-width: 700px) { main { padding-top: 36px; } .h { font-size: 40px; } }
