@media screen {
:root {--grad:linear-gradient(105deg,#ffe39a,#ff9d95 48%,#f36ab3);--accent:#fc87c7;}
body {background:radial-gradient(ellipse at 0 0,#19324f,transparent 60%),radial-gradient(ellipse at 100% 30%,#3a1742,transparent 70%),#0b0e1c;}
body::before {background:radial-gradient(circle at 85% 15%,#ff4d9720,transparent 40%),radial-gradient(circle at 0% 65%,#00d9d015,transparent 45%);}
.app {max-width:640px;}
[data-screen='home'] {gap:0;}
[data-screen='home'] .top {position:relative;isolation:isolate;min-height:420px;padding:12px 0 24px;margin:-24px -20px 0;overflow:hidden;text-align:left;display:flex;flex-direction:column;justify-content:flex-end;}
[data-screen='home'] .top::before {content:'';position:absolute;inset:0;z-index:-2;background-image:url('art/loading-scene.webp');background-position:64% 46%;background-size:cover;animation:city-reveal 1.5s ease-out both;}
[data-screen='home'] .top::after {content:'';position:absolute;inset:0;z-index:-1;background:linear-gradient(180deg,#080b2140 0%,#080b2100 38%,#0b0e1c70 65%,#0b0e1c 100%),linear-gradient(90deg,#0b0e1c44,transparent 80%);}
[data-screen='home'] .brand:first-child {position:absolute;left:22px;top:25px;margin:0;}
.brand .mark {width:38px;height:38px;border-radius:11px;background:linear-gradient(140deg,#ffdb8d,#ff78ad);box-shadow:0 0 25px #ff8bba33;animation:none;}
.brand .mark svg {width:23px;height:23px;}
[data-screen='home'] .brand:last-child {position:absolute;top:34px;right:22px;margin:0;}
[data-screen='home'] .brand .by {color:#f4d7e7;font-size:.62rem;text-shadow:0 2px 9px #000;}
[data-screen='home'] h1 {font-family:Impact,'Arial Narrow','Bricolage Grotesque',sans-serif;text-transform:uppercase;font-size:clamp(37px,10.5vw,52px);font-weight:800;line-height:.98;letter-spacing:-.035em;color:#fff6e8;margin:220px 22px 0;max-width:10ch;text-shadow:3px 4px 0 #151020,0 5px 20px #0008;transform:rotate(-3deg);transform-origin:left bottom;}
[data-screen='home'] h1::after {display:none;}
[data-screen='home'] .sub {margin:17px 23px 0;max-width:32ch;font-size:.77rem;color:#e2d2e8;line-height:1.5;}
[data-screen='home'] .grow {position:relative;gap:12px;}
#btn-start {color:#271b2f;background:linear-gradient(105deg,#ffe4a6,#ffb2ac 65%,#ff91c2);border:1px solid #ffe1bb;box-shadow:0 6px 0 #744859,0 16px 35px #ff92bf28;min-height:69px;border-radius:13px;margin-bottom:10px;font-size:.92rem;font-weight:800;letter-spacing:.02em;padding:19px 45px 19px 19px;}
#btn-start::before {right:23px;}
[data-screen='home'] .btn-secondary {min-height:91px;gap:8px;border-radius:13px;font-size:.8rem;padding:13px;background:linear-gradient(145deg,#25213c,#14182b);box-shadow:0 4px 0 #080b18;border-color:#d7adc82b;}
[data-screen='home'] .btn-secondary::before {height:25px;width:25px;font-size:18px;border-radius:8px;}
#btn-history {color:#9de6ed;}#btn-atelier {color:#f1b7f4;}#btn-circ {color:#9ff0d4;}#btn-free {color:#ffcc91;}
[data-screen='home'] .btn-secondary::after {opacity:.4;}
#btn-reset-all {font-size:.72rem;min-height:44px;margin:3px 0 0;}
[data-screen='home'] .legal {padding-top:15px;font-size:.65rem;line-height:1.6;}
.draw:not(:disabled) {color:#281a2c;background:var(--grad);box-shadow:0 4px 0 #71465e,0 10px 25px #ff7cad24;font-weight:800;}
.draw.ghost {color:#f8dce9;background:transparent;}
.draw:active,#btn-start:active {transform:translateY(3px);box-shadow:0 1px 0 #71465e;}
.top h1 {font-family:'Bricolage Grotesque',Inter,sans-serif;color:#fff4ed;}
.back {background:#f8a6cb0c;border-color:#f8a6cb35;color:#f6d0e5;}
.card {border-color:#e7a4db26;background:linear-gradient(145deg,#21213b,#141b30);}
.stage,.stage.compact {border-radius:18px;border-color:#f6a9d65c;background:linear-gradient(145deg,#15203ff0,#341d44eb),url('art/loading-scene.webp') center/cover;box-shadow:0 10px 30px #0003,inset 0 1px #fff2;min-height:285px;}
.stage:has(.number) {background:linear-gradient(180deg,#12192d75,#1a102bdc),url('art/loading-scene.webp') 60% center/cover;}
.stage::after {border-top-color:#ffb7bf;border-bottom-color:#65f1e6;filter:drop-shadow(0 0 7px #fb85c6);}
.stage .number {font-family:Impact,'Arial Narrow',sans-serif;font-weight:800;font-size:clamp(110px,32vw,170px);background:linear-gradient(180deg,#fff7ce,#ffc3ce 55%,#e779d0);-webkit-background-clip:text;background-clip:text;filter:drop-shadow(3px 5px 0 #17132b);}
.stage .label {font-weight:700;color:#ffc1e0;letter-spacing:.2em;}
.stage .hint {color:#ecd9f1;}
.stage .number[data-state='spinning'] {filter:blur(.6px) drop-shadow(0 0 18px #ff95c9);}
.stage:has([data-state='spinning']) {border-color:#ffd5aa;}
.stage.cap-revealed {animation:mission-impact .65s ease-out;}
.stage.compact .qdraw {color:#ffca9f;text-shadow:none;}
.stage:has(.qbig) {background:linear-gradient(145deg,#28233e,#17243a);}
.stage:has(.qbig)::before {opacity:.3;}
.progress li.current {background:linear-gradient(90deg,#ffd59a,#fc87c7);box-shadow:0 0 10px #ff8cbc44;}
.score-line strong {color:#ffd4a4;text-shadow:none;}
.mode.is-active {background:#f9a7cb1a;border-color:#fdb7d78c;color:#ffe4ef;box-shadow:0 0 15px #ff7eb51a;}
.cap-audio {position:absolute;right:20px;top:77px;z-index:3;min-height:44px;padding:8px 13px;border:1px solid #ffe1ec55;border-radius:30px;background:#11152dd9;color:#f6e0ee;font:600 11px Inter,system-ui,sans-serif;backdrop-filter:blur(8px);}
.cap-audio[aria-pressed='true'] {background:#ffccbb;color:#2b2030;border-color:#ffedcf;}
.cap-mission-overlay {position:fixed;inset:0;z-index:90;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;pointer-events:none;background:#0b0e1cf0;opacity:0;visibility:hidden;overflow:hidden;}
.cap-mission-overlay::before {content:'';position:absolute;width:140%;height:110px;background:linear-gradient(90deg,#9df3ed,#ffc69e,#ff8bbd);transform:rotate(-9deg);opacity:.09;}
.cap-mission-overlay span {font:600 10px Inter,system-ui,sans-serif;letter-spacing:.3em;color:#c6afc7;}
.cap-mission-overlay strong {font:800 clamp(25px,8vw,52px)/1.1 Impact,'Arial Narrow',sans-serif;max-width:90%;text-align:center;text-transform:uppercase;color:#ffcfa9;letter-spacing:.02em;transform:rotate(-4deg);text-shadow:2px 4px 0 #3a223e;}
.cap-mission-overlay.is-playing {visibility:visible;animation:mission-wipe 1.15s ease-in-out forwards;}
.cap-mission-overlay.is-playing strong {animation:mission-title 1.15s ease-out both;}
.chrono .time {font-family:Impact,'Arial Narrow',sans-serif;color:#ffcfac;text-shadow:3px 4px #281e37;}
@keyframes city-reveal {from {transform:scale(1.07);filter:saturate(.7);}to {transform:scale(1);filter:saturate(1);}}
@keyframes mission-wipe {0% {opacity:0;transform:translateX(-12%);}18%,70% {opacity:1;transform:translateX(0);}100% {opacity:0;transform:translateX(12%);visibility:hidden;}}
@keyframes mission-title {0% {translate:-35px 0;opacity:0;}30%,70% {translate:0 0;opacity:1;}100% {translate:25px 0;opacity:0;}}
@keyframes mission-impact {0% {transform:scale(.97);box-shadow:0 0 0 0 #ffcbad99;}45% {transform:scale(1.015);}100% {transform:scale(1);box-shadow:0 0 0 20px #ffcbad00;}}
@media (min-width:700px) {
 .app {max-width:980px;padding:32px;}
 [data-screen='home'] {display:grid;grid-template-columns:1.2fr 1fr;gap:28px;align-content:center;}
 [data-screen='home'][hidden] {display:none;}
 [data-screen='home'] .top {min-height:600px;margin:0 -5px 0 -20px;border-radius:20px;padding-bottom:35px;align-self:stretch;}
 [data-screen='home'] .top::before {background-position:66% center;}
 [data-screen='home'] h1 {font-size:52px;margin-top:300px;}
 [data-screen='home'] .grow {align-self:center;}
 [data-screen='home'] .brand:last-child {position:absolute;top:34px;right:20px;margin:0;}
 [data-screen='home'] .legal {grid-column:1/-1;padding-top:0;}
 .cap-audio {right:20px;top:77px;}
}
@media (max-width:360px) {[data-screen='home'] .top {margin-left:-14px;margin-right:-14px;min-height:400px;}[data-screen='home'] h1 {font-size:36px;}}
@media(prefers-reduced-motion:reduce) {*,*::before,*::after {animation:none!important;transition:none!important;}.cap-mission-overlay.is-playing {display:none;}}
}
@media screen {
[data-screen='home'] .top::before {animation:city-reveal 1.5s ease-out both,city-breathe 14s 1.5s ease-in-out infinite alternate;}
@keyframes city-breathe {from {transform:scale(1) translateX(0);}to {transform:scale(1.04) translateX(-1%);}}
@media(prefers-reduced-motion:reduce) {[data-screen='home'] .top::before {animation:none;}}
}

/* Signature et monogramme : seuls ajustements après validation du thème. */
@media screen {
[data-screen='home'] .brand .mark {width:49px;height:49px;background:none;border:none;border-radius:0;box-shadow:none;transform:rotate(-7deg);animation:none;}
[data-screen='home'] .brand .mark .cap-monogram {display:block;width:49px;height:49px;transform:none;filter:drop-shadow(0 4px 8px #00000055);}
[data-screen='home'] .brand .by {display:block;letter-spacing:0;text-transform:none;line-height:1;}
[data-screen='home'] .cap-wordmark {display:block;width:158px;height:44px;overflow:visible;transform:rotate(-3deg);filter:drop-shadow(0 3px 7px #00000066);}
}
