/* Pocket World — interface de l'appli (thème nuit néon, mobile d'abord) */
:root {
  --night: #050a16; --navy: #0c1730; --panel: #0f1d38; --panel2: #13244a;
  --ink: #eaf6f3; --mute: #93abbb; --mint: #5ff0c4; --cyan: #3fd2f2; --sakura: #ff8fbd; --gold: #ffd36b; --red: #ff5c7a;
  --line: rgba(95, 240, 196, 0.22); --line-soft: rgba(147, 171, 187, 0.16);
  --t-AERO: #5ff0c4; --t-MECA: #a9bccd; --t-NEURO: #c39bff; --t-ORBITE: #7f8dff; --t-FORGE: #ff9a5c; --t-ONDE: #f2e05a; --t-N: #dfe8f0;
  --r-F: #6f7d8c; --r-E: #8fb3a0; --r-D: #5fc98f; --r-C: #3fd2f2; --r-B: #c39bff; --r-A: #ff9a5c; --r-S: #ffd36b;
  --f-display: "Barlow Condensed", "Arial Narrow", "Roboto Condensed", sans-serif;
  --f-body: "Zen Kaku Gothic New", "Hiragino Sans", "Noto Sans JP", system-ui, sans-serif;
  --tabs-h: 64px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; background: var(--night); color: var(--ink); font-family: var(--f-body); font-size: 15px; line-height: 1.5; -webkit-tap-highlight-color: transparent; }
body { min-height: 100dvh; background: radial-gradient(900px 500px at 85% -10%, rgba(63, 210, 242, 0.12), transparent 60%), radial-gradient(700px 500px at -10% 40%, rgba(255, 143, 189, 0.07), transparent 60%), var(--night); overflow-x: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
button:disabled { cursor: default; opacity: 0.45; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 800; letter-spacing: 0.02em; line-height: 1.05; margin: 0; }
.cta { border: 0; border-radius: 14px; padding: 12px 20px; font-family: var(--f-display); font-weight: 800; font-size: 18px; letter-spacing: 0.06em; text-transform: uppercase; color: #04131a; background: linear-gradient(135deg, var(--mint), var(--cyan)); box-shadow: 0 0 22px rgba(63, 210, 242, 0.35); }
.cta.big { font-size: 22px; padding: 16px 30px; }
.cta.gold { background: linear-gradient(135deg, #fff3c4, var(--gold)); box-shadow: 0 0 22px rgba(255, 211, 107, 0.4); }
.ghost { border: 1px solid var(--line); border-radius: 12px; padding: 9px 14px; background: rgba(15, 29, 56, 0.7); font-size: 14px; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-soft); border-radius: 999px; padding: 4px 11px; font-size: 13px; background: rgba(15, 29, 56, 0.6); white-space: nowrap; }
.chip[aria-pressed="true"] { border-color: var(--mint); color: var(--mint); background: rgba(95, 240, 196, 0.1); }
.muted { color: var(--mute); }
.tdot { width: 16px; height: 16px; }

/* ---------- Barre du haut ---------- */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 25; background: #050a16; }
.bar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; display: flex; align-items: center; gap: 10px; padding-block: 10px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); background: linear-gradient(180deg, rgba(5, 10, 22, 0.96), rgba(5, 10, 22, 0.82)); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line-soft); }
.bar .appicon { width: 42px; height: 42px; flex: none; border-radius: 11px; filter: drop-shadow(0 0 8px rgba(63, 210, 242, 0.45)); }
.bar .par .emb { width: 30px; height: 30px; flex: none; filter: drop-shadow(0 0 8px rgba(95, 240, 196, 0.35)); }
.bar .par .emb svg { width: 100%; height: 100%; display: block; }
.bar .ttl b { display: block; font-family: var(--f-display); font-weight: 800; font-size: 20px; letter-spacing: 0.08em; text-transform: uppercase; line-height: 1; }
.bar .ttl small { display: block; color: var(--mute); font-size: 11.5px; letter-spacing: 0.06em; margin-top: 2px; }
.bar .sp { flex: 1; }
.bar .snd { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-soft); background: rgba(15, 29, 56, 0.6); display: grid; place-items: center; }
.bar .snd svg { width: 18px; height: 18px; }
.bar .par { display: flex; align-items: center; gap: 6px; color: var(--mute); font-size: 11.5px; border: 0; background: none; padding: 0; }
@media (max-width: 520px) { .bar .par > span:last-child { display: none; } }

/* ---------- Onglets du bas ---------- */
.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(5, 1fr); padding: 6px max(8px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left)); background: linear-gradient(0deg, rgba(5, 10, 22, 0.98), rgba(5, 10, 22, 0.88)); border-top: 1px solid var(--line-soft); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.tabs button { display: flex; flex-direction: column; align-items: center; gap: 2px; border: 0; background: none; padding: 6px 2px; border-radius: 12px; color: var(--mute); font-family: var(--f-display); font-weight: 700; font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; }
.tabs button svg { width: 24px; height: 24px; }
.tabs button[aria-current="page"] { color: var(--mint); background: rgba(95, 240, 196, 0.08); }
.tabs button[aria-current="page"] svg { filter: drop-shadow(0 0 6px rgba(95, 240, 196, 0.7)); }
.tabs .dot { position: absolute; margin: -2px 0 0 22px; width: 8px; height: 8px; border-radius: 50%; background: var(--sakura); box-shadow: 0 0 8px var(--sakura); }
.tabs button { position: relative; }

main#view { padding-block: 16px calc(var(--tabs-h) + 28px + env(safe-area-inset-bottom, 0px)); padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); max-width: 1100px; margin: 0 auto; }
.vh { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.vh h1 { font-size: 30px; }
.vh p { margin: 4px 0 0; color: var(--mute); font-size: 14px; }

/* ---------- Boosters ---------- */
.packs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 720px) { .packs { grid-template-columns: 1fr; } }
.pack-tile { position: relative; border: 0; padding: 0; border-radius: 22px; overflow: hidden; aspect-ratio: 3 / 4; text-align: left; background: #0b1530; box-shadow: 0 16px 34px rgba(0, 0, 0, 0.5); isolation: isolate; }
@media (max-width: 720px) { .pack-tile { aspect-ratio: 16 / 9; } }
.pack-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; z-index: -2; transition: transform 0.6s; }
.pack-tile:hover img { transform: scale(1.04); }
.pack-tile::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(5, 10, 22, 0.05) 30%, rgba(5, 10, 22, 0.92) 85%), linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, 0.18) 48%, transparent 60%); background-size: 100% 100%, 300% 100%; animation: foil 5s linear infinite; }
@keyframes foil { from { background-position: 0 0, 120% 0; } to { background-position: 0 0, -80% 0; } }
.pack-tile::after { content: ""; position: absolute; inset: 0; border-radius: inherit; border: 2px solid var(--pc, var(--cyan)); box-shadow: inset 0 0 24px color-mix(in srgb, var(--pc, var(--cyan)) 50%, transparent); pointer-events: none; }
.pack-tile .pk { position: absolute; left: 16px; right: 16px; bottom: 14px; }
.pack-tile .pk small { display: block; font-family: var(--f-display); letter-spacing: 0.2em; color: var(--pc); font-size: 12px; }
.pack-tile .pk b { display: block; font-family: var(--f-display); font-size: 28px; line-height: 1; text-transform: uppercase; letter-spacing: 0.03em; }
.pack-tile .pk span { display: block; color: var(--mute); font-size: 13px; margin-top: 4px; }
.pack-tile .seal { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border-radius: 50%; background: rgba(5, 10, 22, 0.75); border: 2px solid var(--pc); display: grid; place-items: center; color: var(--pc); }
.pack-tile .seal svg { width: 26px; height: 26px; }
.daily { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.daily .tickets { display: flex; gap: 6px; }
.daily .tickets i { width: 26px; height: 34px; border-radius: 6px; border: 2px solid var(--mint); background: linear-gradient(160deg, rgba(95, 240, 196, 0.35), rgba(63, 210, 242, 0.15)); box-shadow: 0 0 10px rgba(95, 240, 196, 0.4); }
.daily .tickets i.used { border-color: var(--line-soft); background: none; box-shadow: none; }

/* Ouverture */
.opening { position: fixed; inset: 0; z-index: 60; background: radial-gradient(circle at 50% 40%, #142850, #03060e 75%); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: max(16px, env(safe-area-inset-top)) 14px max(16px, env(safe-area-inset-bottom)); overflow-y: auto; }
.opening .head { text-align: center; }
.opening .head small { color: var(--mute); letter-spacing: 0.18em; font-family: var(--f-display); }
.opening .head b { display: block; font-family: var(--f-display); font-size: 26px; text-transform: uppercase; }
.sealed { width: min(62vw, 260px); aspect-ratio: 3 / 4.4; border-radius: 18px; position: relative; overflow: hidden; border: 2px solid var(--pc); box-shadow: 0 0 40px color-mix(in srgb, var(--pc) 45%, transparent); animation: wobble 1.2s ease-in-out infinite; background: #0b1530; }
.sealed img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; }
.sealed::after { content: "Touchez pour ouvrir"; position: absolute; left: 0; right: 0; bottom: 0; padding: 14px; text-align: center; font-family: var(--f-display); font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; background: linear-gradient(0deg, rgba(5, 10, 22, 0.95), transparent); }
.sealed.tear { animation: tear 0.55s ease-in forwards; }
@keyframes wobble { 0%, 100% { transform: rotate(-1.5deg); } 50% { transform: rotate(1.5deg) scale(1.02); } }
@keyframes tear { 0% { transform: scale(1); } 40% { transform: scale(1.08) rotate(2deg); filter: brightness(1.6); } 100% { transform: scale(0.2) translateY(-60vh); opacity: 0; } }
.fan { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; width: min(100%, 860px); }
@media (max-width: 640px) { .fan { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; } .fan > :nth-child(10) { grid-column: 2; } }
.flip { perspective: 900px; border: 0; padding: 0; background: none; position: relative; animation: deal 0.45s backwards; }
@keyframes deal { from { transform: translateY(40vh) rotate(8deg); opacity: 0; } }
.flip .in { position: relative; transition: transform 0.55s cubic-bezier(.3, .7, .3, 1); transform-style: preserve-3d; }
.flip.done .in { transform: rotateY(180deg); }
.flip .face { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.flip .face.front { position: absolute; inset: 0; transform: rotateY(180deg); }
.flip .newtag { position: absolute; top: -8px; right: -6px; z-index: 3; background: var(--sakura); color: #2a0718; font-family: var(--f-display); font-weight: 800; font-size: 12px; letter-spacing: 0.08em; padding: 2px 8px; border-radius: 999px; box-shadow: 0 0 10px var(--sakura); opacity: 0; transition: opacity 0.3s 0.4s; }
.flip.done .newtag { opacity: 1; }
.flip.hot .pc-back { box-shadow: 0 0 0 2px var(--gold), 0 0 26px rgba(255, 211, 107, 0.7); }
.flip.hot.top .pc-back { animation: sssPulse 1.1s ease-in-out infinite; }
@keyframes sssPulse { 50% { box-shadow: 0 0 0 3px #fff3c4, 0 0 44px rgba(255, 143, 189, 0.85); } }
.opening .acts { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }

/* Éclat SSS */
.sss-burst { position: absolute; inset: -60%; z-index: 5; pointer-events: none; border-radius: 50%; background: repeating-conic-gradient(from 0deg, rgba(255, 211, 107, 0.9) 0 4deg, transparent 4deg 14deg, rgba(255, 143, 189, 0.85) 14deg 18deg, transparent 18deg 28deg, rgba(63, 210, 242, 0.85) 28deg 32deg, transparent 32deg 42deg); -webkit-mask: radial-gradient(circle, #000 18%, transparent 62%); mask: radial-gradient(circle, #000 18%, transparent 62%); animation: burst 1.5s ease-out forwards; mix-blend-mode: screen; }
@keyframes burst { 0% { transform: scale(0.2) rotate(0); opacity: 0; } 15% { opacity: 1; } 100% { transform: scale(1.5) rotate(70deg); opacity: 0; } }

/* ---------- Dos de carte (cerisier + racines) ---------- */
.pc-back { position: relative; width: 100%; aspect-ratio: 63 / 88; border-radius: 5.2% / 3.7%; overflow: hidden; background: #050c1e; box-shadow: 0 10px 28px rgba(0, 0, 0, 0.45); }
.pc-back > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pc-back svg.back-ov { position: absolute; inset: 0; width: 100%; height: 100%; }
.back-ov .frame { animation: neon 4s ease-in-out infinite; }
@keyframes neon { 50% { opacity: 0.82; } 52% { opacity: 1; } 54% { opacity: 0.9; } }
.back-ov .root.grow path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: rootGrow 2.4s 0.3s ease-out forwards; }
.back-ov .embl.grow { opacity: 0; animation: emblIn 0.8s 2.3s ease-out forwards; }
@keyframes rootGrow { to { stroke-dashoffset: 0; } }
@keyframes emblIn { from { opacity: 0; transform: var(--t) scale(0.2); } to { opacity: 1; } }

/* ---------- Carte certifiée ---------- */
.pc.certified { box-shadow: 0 0 0 2px #ffd36b, 0 0 26px rgba(255, 211, 107, 0.6), 0 10px 28px rgba(0, 0, 0, 0.5); }
.cert { position: absolute; right: 4%; top: 31%; z-index: 4; display: flex; align-items: center; gap: 1.4cqw; padding: 1cqw 2.4cqw 1cqw 1cqw; border-radius: 999px; background: linear-gradient(135deg, #fff3c4, #ffd36b 55%, #c8902a); color: #1a1204; font-family: var(--f-display); font-weight: 800; font-size: 3.4cqw; letter-spacing: 0.06em; box-shadow: 0 0 2.4cqw rgba(255, 211, 107, 0.8); transform: rotate(-6deg); }
.cert svg { width: 7cqw; height: 7cqw; color: #8a5a10; }

/* ---------- Collection ---------- */
.seg { display: inline-flex; border: 1px solid var(--line-soft); border-radius: 14px; padding: 3px; gap: 3px; background: rgba(15, 29, 56, 0.6); flex-wrap: wrap; }
.seg button { border: 0; background: none; border-radius: 11px; padding: 7px 12px; font-family: var(--f-display); font-weight: 700; letter-spacing: 0.04em; font-size: 15px; color: var(--mute); }
.seg button[aria-pressed="true"] { background: var(--panel2); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.progress { display: grid; gap: 6px; margin: 12px 0; }
.progress .bar2 { height: 10px; border-radius: 999px; background: rgba(147, 171, 187, 0.14); overflow: hidden; }
.progress .bar2 i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--mint), var(--cyan)); box-shadow: 0 0 12px rgba(95, 240, 196, 0.6); }
.progress .row { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; flex-wrap: wrap; }
.filters { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
@media (max-width: 520px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; } }
.cell { position: relative; border: 0; padding: 0; background: none; text-align: left; }
.cell .cnt { position: absolute; z-index: 5; right: -4px; bottom: -6px; min-width: 26px; height: 26px; padding: 0 7px; border-radius: 999px; background: var(--panel2); border: 1px solid var(--line); font-family: var(--f-display); font-weight: 800; font-size: 14px; display: grid; place-items: center; }
.cell .nw { position: absolute; z-index: 5; left: -4px; top: -6px; background: var(--sakura); color: #2a0718; font-family: var(--f-display); font-weight: 800; font-size: 11px; letter-spacing: 0.08em; padding: 1px 7px; border-radius: 999px; }
.miss { width: 100%; aspect-ratio: 63 / 88; border-radius: 5.2% / 3.7%; border: 1.5px dashed rgba(147, 171, 187, 0.3); background: repeating-linear-gradient(135deg, rgba(147, 171, 187, 0.05) 0 8px, transparent 8px 16px), #081127; display: grid; place-items: center; align-content: center; gap: 4px; color: var(--mute); font-family: var(--f-display); container-type: inline-size; }
.miss b { font-size: 16cqw; color: rgba(147, 171, 187, 0.5); line-height: 1; }
.miss span { font-size: 8cqw; letter-spacing: 0.08em; }
.miss.hs { border: 1.5px solid rgba(255, 211, 107, 0.45); background: radial-gradient(circle at 50% 40%, rgba(255, 211, 107, 0.16), transparent 60%), #0a0c1c; color: var(--gold); }
.miss.hs b { color: var(--gold); text-shadow: 0 0 18px rgba(255, 211, 107, 0.8); font-size: 30cqw; }
.hs-title { margin: 26px 0 10px; display: flex; align-items: baseline; gap: 10px; }
.hs-title h2 { font-size: 22px; background: linear-gradient(90deg, #fff3c4, var(--gold), var(--sakura)); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Fenêtres ---------- */
.modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; background: rgba(3, 7, 15, 0.84); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); padding: max(14px, env(safe-area-inset-top)) 14px max(14px, env(safe-area-inset-bottom)); overflow-y: auto; animation: fadeIn 0.18s; }
@keyframes fadeIn { from { opacity: 0; } }
.sheet { position: relative; width: min(100%, 720px); background: linear-gradient(180deg, #102047, #0a1430); border: 1px solid var(--line); border-radius: 22px; padding: 18px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); }
.sheet h2 { font-size: 24px; margin-bottom: 4px; padding-right: 44px; }
.sheet .x { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line-soft); background: var(--panel); font-size: 20px; line-height: 1; }
.sheet.card-view { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 640px) { .sheet.card-view { grid-template-columns: 1fr; justify-items: center; } .sheet.card-view .pc { width: min(300px, 78vw); } }
.card-view .info { display: grid; gap: 10px; min-width: 0; width: 100%; }
.card-view .flav { font-style: italic; color: #cfe2e6; margin: 0; }
.card-view .copies { display: flex; flex-wrap: wrap; gap: 6px; }
.choose-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin-top: 12px; max-height: 64vh; overflow-y: auto; padding: 4px; }
.choose-list.txt { grid-template-columns: 1fr; }
.choose-list > button { border: 1px solid var(--line-soft); background: var(--panel); border-radius: 14px; padding: 6px; text-align: left; }
.choose-list > button:hover { border-color: var(--mint); }
.choose-list > button .lbl { display: block; font-size: 12.5px; margin-top: 4px; text-align: center; line-height: 1.2; }
.toast { position: fixed; left: 50%; top: calc(70px + env(safe-area-inset-top)); transform: translateX(-50%); z-index: 90; background: rgba(15, 29, 56, 0.96); border: 1px solid var(--line); border-radius: 14px; padding: 10px 16px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); font-size: 14px; max-width: min(92vw, 520px); text-align: center; animation: toastIn 0.25s; }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, -10px); } }

/* ---------- Decks ---------- */
.decks { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.deck-tile { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: center; text-align: left; border: 1px solid var(--line-soft); background: var(--panel); border-radius: 16px; padding: 10px; }
.deck-tile .cv { width: 64px; aspect-ratio: 63 / 88; border-radius: 8px; overflow: hidden; background: #0a1430; }
.deck-tile .cv img { width: 100%; height: 100%; object-fit: cover; }
.deck-tile b { font-family: var(--f-display); font-size: 19px; display: block; line-height: 1.1; }
.deck-tile .meta { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 4px; font-size: 12.5px; color: var(--mute); }
.deck-tile.bad { border-color: rgba(255, 92, 122, 0.5); }
.sec-title { font-family: var(--f-display); font-size: 20px; letter-spacing: 0.04em; margin: 22px 0 10px; color: var(--mute); text-transform: uppercase; }
.editor { position: fixed; inset: 0; z-index: 65; background: var(--night); display: grid; grid-template-rows: auto auto 1fr; padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left)); gap: 10px; }
.editor .top { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.editor .top input { flex: 1; min-width: 140px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 9px 12px; color: var(--ink); font: inherit; font-family: var(--f-display); font-size: 19px; }
.editor .stat { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 13.5px; }
.editor .stat .n { font-family: var(--f-display); font-weight: 800; font-size: 22px; }
.editor .stat .err { color: var(--red); }
.editor .cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: 12px; min-height: 0; }
@media (max-width: 720px) { .editor .cols { grid-template-columns: 1fr; grid-template-rows: minmax(120px, 34%) 1fr; } }
.editor .pane { min-height: 0; overflow-y: auto; border: 1px solid var(--line-soft); border-radius: 16px; padding: 8px; background: rgba(15, 29, 56, 0.4); }
.editor .pane h3 { font-size: 15px; color: var(--mute); letter-spacing: 0.06em; text-transform: uppercase; margin: 2px 4px 8px; }
.dl { display: grid; gap: 6px; }
.dl button { display: grid; grid-template-columns: 34px 1fr auto; gap: 8px; align-items: center; border: 1px solid var(--line-soft); background: var(--panel); border-radius: 10px; padding: 4px 8px 4px 4px; text-align: left; font-size: 13.5px; }
.dl button img { width: 34px; height: 34px; object-fit: cover; border-radius: 7px; }
.dl button .x2 { font-family: var(--f-display); font-weight: 800; color: var(--mint); }
.pool { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; }
.pool button { position: relative; border: 0; padding: 0; background: none; }
.pool button .left { position: absolute; right: 4px; bottom: 4px; z-index: 3; background: rgba(5, 10, 22, 0.85); border-radius: 999px; padding: 0 7px; font-family: var(--f-display); font-weight: 800; font-size: 13px; }
.pool button.off { opacity: 0.35; }

/* Vignette */
.mini { position: relative; width: 100%; aspect-ratio: 63 / 88; border-radius: 9px; overflow: hidden; background: #0a1430; border: 2px solid color-mix(in srgb, var(--tc, var(--t-N)) 70%, transparent); container-type: inline-size; }
.mini.t-AERO { --tc: var(--t-AERO); } .mini.t-MECA { --tc: var(--t-MECA); } .mini.t-NEURO { --tc: var(--t-NEURO); } .mini.t-ORBITE { --tc: var(--t-ORBITE); } .mini.t-FORGE { --tc: var(--t-FORGE); } .mini.t-ONDE { --tc: var(--t-ONDE); }
.mini.k-op { --tc: #d8e2ee; } .mini.k-mod { --tc: var(--cyan); }
.mini.r-S, .mini.r-SS { border-color: var(--gold); } .mini.r-SSS, .mini.r-EX { border-color: transparent; background: conic-gradient(from var(--ang, 0deg), #ffd36b, #ff8fbd, #c39bff, #3fd2f2, #ffd36b) border-box; }
.mini img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 22%; }
.mini::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(5, 10, 22, 0.92) 82%); }
.mini .mn { position: absolute; z-index: 2; left: 5cqw; right: 5cqw; bottom: 5cqw; font-family: var(--f-display); font-weight: 700; font-size: 11.5cqw; line-height: 1.02; text-shadow: 0 1px 3px #000; }
.mini .mh { position: absolute; z-index: 2; right: 4cqw; top: 3cqw; font-family: var(--f-display); font-weight: 800; font-size: 12cqw; text-shadow: 0 1px 4px #000; }
.mini .mk { position: absolute; z-index: 2; right: 4cqw; top: 4cqw; font-family: var(--f-display); font-weight: 800; font-size: 9cqw; padding: 0 3cqw; border-radius: 4cqw; background: rgba(5, 10, 22, 0.8); letter-spacing: 0.06em; }
.mini > .tdot { position: absolute; z-index: 2; left: 4cqw; top: 4cqw; width: 14cqw; height: 14cqw; }
.mini .badge.mr { position: absolute; z-index: 2; left: 4cqw; top: 21cqw; width: 14cqw; height: 14cqw; font-size: 8.5cqw; border-radius: 4cqw; }
.mini.k-op .badge.mr, .mini.k-mod .badge.mr { top: 4cqw; }

/* ---------- Combat ---------- */
.foes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 640px) { .foes { grid-template-columns: 1fr; } }
.foe { border: 1px solid var(--line-soft); border-radius: 18px; padding: 14px; background: var(--panel); text-align: left; display: grid; gap: 4px; }
.foe[aria-pressed="true"] { border-color: var(--mint); box-shadow: 0 0 0 1px var(--mint), 0 0 24px rgba(95, 240, 196, 0.25); }
.foe b { font-family: var(--f-display); font-size: 22px; }
.foe small { color: var(--mute); }
.foe .lv { font-family: var(--f-display); letter-spacing: 0.16em; font-size: 12px; text-transform: uppercase; }
.lv.facile { color: var(--mint); } .lv.moyen { color: var(--gold); } .lv.difficile { color: var(--red); }
.board { position: fixed; inset: 0; z-index: 55; background: radial-gradient(ellipse at 50% 50%, rgba(30, 60, 110, 0.5), transparent 70%), linear-gradient(180deg, #070d1f, #050914 50%, #070d1f); display: grid; grid-template-rows: auto minmax(0, 1fr) auto minmax(0, 1fr) auto; padding: max(8px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-right)) max(8px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left)); gap: 6px; max-width: 760px; margin: 0 auto; }
.pl-bar { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.pl-bar b { font-family: var(--f-display); font-size: 17px; letter-spacing: 0.04em; }
.pl-bar .sp { flex: 1; }
.hearts { display: flex; gap: 3px; }
.hearts i { width: 18px; height: 18px; background: rgba(147, 171, 187, 0.25); -webkit-mask: var(--heart) center / contain no-repeat; mask: var(--heart) center / contain no-repeat; }
.hearts i.on { background: var(--sakura); filter: drop-shadow(0 0 6px var(--sakura)); }
:root { --heart: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-8-5.3-8-11a4.6 4.6 0 0 1 8-3 4.6 4.6 0 0 1 8 3c0 5.7-8 11-8 11z'/%3E%3C/svg%3E"); }
.side { display: grid; grid-template-rows: 92px minmax(0, 1fr); gap: 10px; min-height: 0; }
.side.me { grid-template-rows: minmax(0, 1fr) 92px; }
.benches { display: grid; grid-template-columns: repeat(3, 66px); justify-content: center; gap: 10px; height: 92px; }
.benches .unit { width: 66px; height: 92px; }
.act-slot { display: flex; justify-content: center; align-items: center; min-height: 0; height: 100%; }
.unit { position: relative; border: 0; padding: 0; background: none; width: 100%; }
.act-slot .unit { height: 100%; max-height: 200px; width: auto; aspect-ratio: 63 / 88; }
.unit .mini { box-shadow: 0 8px 20px rgba(0, 0, 0, 0.45); }
.unit.sel .mini { outline: 3px solid var(--mint); outline-offset: 2px; animation: selPulse 1s infinite; }
@keyframes selPulse { 50% { outline-color: rgba(95, 240, 196, 0.3); } }
.unit .hpb { position: absolute; left: 6%; right: 6%; bottom: -7px; height: 8px; border-radius: 999px; background: rgba(5, 10, 22, 0.9); border: 1px solid var(--line-soft); overflow: hidden; z-index: 3; }
.unit .hpb i { display: block; height: 100%; background: linear-gradient(90deg, var(--mint), var(--cyan)); transition: width 0.4s; }
.unit .hpb i.low { background: linear-gradient(90deg, var(--red), var(--gold)); }
.unit .hpn { position: absolute; z-index: 4; left: 50%; bottom: 3px; transform: translateX(-50%); font-family: var(--f-display); font-weight: 800; font-size: 13px; background: rgba(5, 10, 22, 0.88); padding: 0 6px; border-radius: 6px; white-space: nowrap; }
.unit .fx { position: absolute; z-index: 4; top: 26%; right: -6px; display: flex; flex-direction: column; gap: 2px; }
.unit .fx .tdot { width: 15px; height: 15px; }
.unit .st { position: absolute; z-index: 4; top: -8px; left: 50%; transform: translateX(-50%); display: flex; gap: 2px; }
.unit .st span { font-size: 10px; font-family: var(--f-display); font-weight: 800; letter-spacing: 0.04em; padding: 0 5px; border-radius: 999px; }
.st .burn { background: var(--t-FORGE); color: #2a0e00; } .st .conf { background: var(--t-NEURO); color: #1b0a33; } .st .block { background: var(--t-MECA); color: #0b1631; }
.unit .md { position: absolute; z-index: 4; left: -6px; top: 40%; width: 20px; height: 20px; border-radius: 6px; background: var(--cyan); color: #04131a; font-family: var(--f-display); font-weight: 800; font-size: 12px; display: grid; place-items: center; }
.unit.empty { aspect-ratio: 63 / 88; border: 1.5px dashed rgba(147, 171, 187, 0.25); border-radius: 9px; }
.unit.hit { animation: hitShake 0.4s; }
@keyframes hitShake { 20% { transform: translateX(-6px) rotate(-2deg); } 40% { transform: translateX(6px) rotate(2deg); } 60% { transform: translateX(-4px); } 80% { transform: translateX(3px); } }
.unit.ko { animation: ko 0.7s forwards; }
@keyframes ko { to { transform: scale(0.6) rotate(-14deg); opacity: 0; filter: grayscale(1); } }
.unit.lunge-up { animation: lungeUp 0.35s; } .unit.lunge-down { animation: lungeDown 0.35s; }
@keyframes lungeUp { 50% { transform: translateY(-28px) scale(1.06); } } @keyframes lungeDown { 50% { transform: translateY(28px) scale(1.06); } }
.float { position: absolute; z-index: 9; left: 50%; top: 30%; transform: translateX(-50%); font-family: var(--f-display); font-weight: 800; font-size: 28px; color: #fff; text-shadow: 0 0 10px var(--red), 0 2px 0 #000; pointer-events: none; animation: floatUp 1s forwards; }
.float.heal { text-shadow: 0 0 10px var(--mint), 0 2px 0 #000; }
@keyframes floatUp { to { transform: translate(-50%, -50px); opacity: 0; } }
.mid { display: flex; align-items: center; gap: 8px; justify-content: center; flex-wrap: wrap; padding: 2px 0; }
.mid .turn { font-family: var(--f-display); font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; font-size: 14px; padding: 4px 12px; border-radius: 999px; background: var(--panel2); border: 1px solid var(--line); }
.mid .turn.me { color: var(--mint); } .mid .turn.them { color: var(--sakura); }
.fluxtok { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 999px; padding: 4px 10px 4px 4px; background: var(--panel); font-size: 13px; }
.fluxtok .tdot { width: 26px; height: 26px; box-shadow: 0 0 12px var(--dc); animation: fluxGlow 1.4s infinite; }
@keyframes fluxGlow { 50% { box-shadow: 0 0 2px var(--dc); } }
.fluxtok[aria-pressed="true"] { border-color: var(--mint); background: rgba(95, 240, 196, 0.15); }
.lastlog { width: 100%; text-align: center; font-size: 12.5px; color: var(--mute); min-height: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hand { display: flex; }
.hand button { flex: none; width: 72px; border: 0; padding: 0; background: none; scroll-snap-align: start; transition: transform 0.15s; }
.hand button.can .mini { box-shadow: 0 0 0 2px var(--mint), 0 0 14px rgba(95, 240, 196, 0.5); }
.hand button:active { transform: translateY(-6px); }
.hand .empty { color: var(--mute); font-size: 13px; padding: 30px 10px; }
.backs { display: flex; }
.backs i { width: 14px; height: 20px; border-radius: 3px; margin-left: -6px; background: url("../art/dos-pocket.webp") center / cover; border: 1px solid rgba(143, 244, 255, 0.6); }
.backs i:first-child { margin-left: 0; }
.logbox { max-height: 50vh; overflow-y: auto; font-size: 13.5px; display: grid; gap: 3px; margin-top: 10px; }
.logbox div:nth-child(odd) { color: #cfe2e6; }
.atk-list { display: grid; gap: 8px; margin-top: 10px; }
.atk-btn { display: grid; grid-template-columns: auto 1fr auto; gap: 4px 10px; align-items: center; text-align: left; border: 1px solid var(--line); background: var(--panel); border-radius: 14px; padding: 10px 12px; }
.atk-btn b { font-family: var(--f-display); font-size: 19px; }
.atk-btn .d { font-family: var(--f-display); font-weight: 800; font-size: 24px; }
.atk-btn p { grid-column: 1 / -1; margin: 0; font-size: 13px; color: var(--mute); }
.atk-btn .cost { display: flex; gap: 3px; }
.atk-btn .cost .tdot { width: 20px; height: 20px; }
.opt-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; align-items: center; }
.switch { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; }
.switch input { width: 20px; height: 20px; accent-color: var(--gold); }
.coin { position: fixed; z-index: 95; left: 50%; top: 42%; width: 74px; height: 74px; margin: -37px; border-radius: 50%; display: grid; place-items: center; font-family: var(--f-display); font-weight: 800; font-size: 13px; color: #1a1204; background: radial-gradient(circle at 35% 30%, #fff3c4, #ffd36b 55%, #b07a1a); box-shadow: 0 0 30px rgba(255, 211, 107, 0.7); animation: coin 0.9s; pointer-events: none; }
@keyframes coin { 0% { transform: rotateY(0) scale(0.4); } 70% { transform: rotateY(1080deg) scale(1.1); } 100% { transform: rotateY(1080deg) scale(1); } }
.endcard { text-align: center; display: grid; gap: 12px; justify-items: center; }
.endcard h2 { font-size: 46px; padding: 0; }
.endcard.win h2 { background: linear-gradient(90deg, #fff3c4, var(--gold), var(--sakura)); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Bible ---------- */
.bible h2 { font-size: 26px; margin: 26px 0 8px; }
.bible p { margin: 0 0 12px; max-width: 70ch; color: #d6e6ea; }
.bible .lead { font-size: 16.5px; color: var(--ink); }
.montage { position: relative; display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 6px; height: clamp(220px, 46vw, 360px); border-radius: 20px; overflow: hidden; margin: 14px 0 18px; box-shadow: 0 18px 40px rgba(0, 0, 0, 0.5); }
.montage > div { position: relative; overflow: hidden; }
.montage > div:first-child { grid-row: span 2; }
.montage img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 25%; animation: kb 18s ease-in-out infinite alternate; }
.montage > div:nth-child(2) img { animation-delay: -6s; } .montage > div:nth-child(3) img { animation-delay: -11s; }
@keyframes kb { from { transform: scale(1.02); } to { transform: scale(1.14) translate(-2%, 1%); } }
.montage figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 14px 10px; background: linear-gradient(0deg, rgba(5, 10, 22, 0.92), transparent); font-family: var(--f-display); font-size: 17px; letter-spacing: 0.04em; z-index: 2; }
.montage.wide { grid-template-columns: repeat(4, 1fr); grid-template-rows: 1fr; height: clamp(160px, 30vw, 260px); }
.montage.wide > div:first-child { grid-row: auto; }
.fiches { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.fiche { border: 1px solid var(--line-soft); border-radius: 18px; background: var(--panel); overflow: hidden; display: grid; }
.fiche .ph { display: flex; height: 120px; }
.fiche .ph img { flex: 1; min-width: 0; object-fit: cover; object-position: 50% 22%; }
.fiche .bd { padding: 12px 14px 14px; display: grid; gap: 6px; }
.fiche h3 { font-size: 20px; }
.fiche .names { font-size: 12.5px; color: var(--mute); }
.fiche dl { margin: 0; display: grid; gap: 6px; font-size: 13.5px; }
.fiche dt { font-family: var(--f-display); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; font-size: 12px; color: var(--mint); }
.fiche dd { margin: 0; color: #d6e6ea; }
.fiche.locked { opacity: 0.85; }
.fiche.locked .ph { background: repeating-linear-gradient(135deg, rgba(147, 171, 187, 0.06) 0 8px, transparent 8px 16px); }

/* ---------- Coffre secret ---------- */
.vault .sec { border-top: 1px solid var(--line-soft); margin-top: 16px; padding-top: 14px; display: grid; gap: 10px; }
.vault h3 { font-size: 19px; }
.vault input[type=text], .vault select { background: #081127; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; color: var(--ink); font: inherit; width: 100%; }
.vault .code-in { font-family: var(--f-display); font-size: 22px; letter-spacing: 0.12em; text-transform: uppercase; }
.vault .code-out { font-family: var(--f-display); font-weight: 800; font-size: clamp(22px, 6vw, 30px); letter-spacing: 0.1em; color: var(--gold); text-align: center; padding: 12px; border-radius: 14px; border: 1px dashed var(--gold); background: rgba(255, 211, 107, 0.06); user-select: all; }
.vault .row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.vault .made { display: grid; gap: 6px; font-size: 13px; max-height: 220px; overflow-y: auto; }
.vault .made div { display: flex; justify-content: space-between; gap: 8px; border: 1px solid var(--line-soft); border-radius: 10px; padding: 6px 10px; }
.vault .made code { font-family: var(--f-display); letter-spacing: 0.06em; color: var(--gold); }
.vault .pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); gap: 6px; max-height: 300px; overflow-y: auto; padding: 2px; }
.vault .pick button { border: 2px solid transparent; padding: 0; background: none; border-radius: 11px; }
.vault .pick button[aria-pressed="true"] { border-color: var(--gold); }

/* ---------- Intro et 7S ---------- */
.intro, .seven { position: fixed; inset: 0; z-index: 200; background: #030812; color: var(--ink); touch-action: manipulation; }
.intro canvas, .seven canvas { position: absolute; inset: 0; }
.intro-gate { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: 18px; text-align: center; padding: 20px; }
.intro-gate .ig-logo { width: min(56vw, 240px); aspect-ratio: 63 / 88; border-radius: 16px; background: url("../art/dos-pocket.webp") center / cover; box-shadow: 0 0 40px rgba(63, 210, 242, 0.35), 0 0 80px rgba(255, 143, 189, 0.2); animation: breathe 3s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.03); box-shadow: 0 0 60px rgba(63, 210, 242, 0.5), 0 0 100px rgba(255, 143, 189, 0.3); } }
.intro-gate small { color: var(--mute); }
.intro-title { position: absolute; left: 0; right: 0; bottom: 14%; text-align: center; opacity: 0; display: grid; gap: 2px; pointer-events: none; }
.intro-title .jp { font-family: var(--f-body); letter-spacing: 0.5em; color: var(--sakura); font-size: clamp(12px, 3.4vw, 16px); }
.intro-title .nur { font-family: var(--f-display); font-weight: 700; letter-spacing: 0.4em; font-size: clamp(16px, 5vw, 26px); color: #dfe9f7; }
.intro-title .pw { font-family: var(--f-display); font-weight: 800; letter-spacing: 0.04em; font-size: clamp(36px, 11vw, 84px); line-height: 0.95; color: rgba(127, 246, 255, 0.25); transition: color 0.05s, text-shadow 0.05s; }
.intro-title.on .pw { color: #effdff; text-shadow: 0 0 8px #3fd2f2, 0 0 22px #3fd2f2, 0 0 46px rgba(255, 143, 189, 0.8); }
.skip { position: absolute; right: max(16px, env(safe-area-inset-right)); bottom: max(18px, env(safe-area-inset-bottom)); z-index: 3; border: 1px solid rgba(255, 255, 255, 0.4); background: rgba(5, 10, 22, 0.6); border-radius: 999px; padding: 10px 18px; font-family: var(--f-display); font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.halo { position: relative; }
.halo::before { content: ""; position: absolute; inset: -14%; z-index: -1; border-radius: 50%; background: conic-gradient(from var(--ang, 0deg), rgba(255, 211, 107, 0), rgba(255, 211, 107, 0.75), rgba(255, 243, 196, 0.2), rgba(255, 143, 189, 0.6), rgba(255, 211, 107, 0)); filter: blur(14px); animation: spin 5s linear infinite; }
@media (prefers-reduced-motion: reduce) { .pack-tile::before, .sealed, .montage img, .back-ov .frame, .halo::before { animation: none; } }

.unit .mini .mh { display: none; }
.unit .hpn { left: auto; right: 3px; bottom: auto; top: 3px; transform: none; font-size: 12px; }

/* Numéro des hors-série : au-delà du total de la série, en gras or (SSS) ou or irisé (7S) */
.hsno { font-weight: 800; background: linear-gradient(90deg, #fff3c4, #ffd36b, #e0a43a); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 0 0.6cqw rgba(255, 211, 107, 0.8)); }
.hsno.EX { background: linear-gradient(90deg, #fff3c4, #ffd36b, #ff8fbd, #c39bff, #3fd2f2, #ffd36b); background-size: 300% 100%; -webkit-background-clip: text; background-clip: text; animation: hsShine 3s linear infinite; filter: drop-shadow(0 0 0.8cqw rgba(255, 211, 107, 0.9)); }
@keyframes hsShine { to { background-position: -300% 0; } }
.chip .hsno { filter: drop-shadow(0 0 4px rgba(255, 211, 107, 0.8)); }
@media (prefers-reduced-motion: reduce) { .hsno.EX { animation: none; } }

/* ---------- Boîtes en bois (kiri-bako) ---------- */
.opening .head .muted { display: block; margin-top: 4px; font-size: 14px; letter-spacing: 0.04em; }
.shelf { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; width: 100%; max-width: 1100px; padding: 30px 24vw 26px; scrollbar-width: none; }
.shelf::-webkit-scrollbar { display: none; }
.pick-box { flex: none; width: min(46vw, 220px); border: 0; padding: 0; background: none; scroll-snap-align: center; transition: transform 0.25s, filter 0.25s; animation: boxIn 0.5s backwards; }
.pick-box:nth-child(2) { animation-delay: 40ms; } .pick-box:nth-child(3) { animation-delay: 80ms; } .pick-box:nth-child(4) { animation-delay: 120ms; } .pick-box:nth-child(5) { animation-delay: 160ms; }
.pick-box:nth-child(6) { animation-delay: 200ms; } .pick-box:nth-child(7) { animation-delay: 240ms; } .pick-box:nth-child(8) { animation-delay: 280ms; } .pick-box:nth-child(9) { animation-delay: 320ms; } .pick-box:nth-child(10) { animation-delay: 360ms; }
@keyframes boxIn { from { transform: translateY(40px); opacity: 0; } }
.pick-box:hover, .pick-box:focus-visible, .pick-box.hop { transform: translateY(-14px) scale(1.04); filter: drop-shadow(0 0 18px color-mix(in srgb, var(--pc) 70%, transparent)); }
.kbox { position: relative; width: 100%; aspect-ratio: 640 / 358; transform: rotate(var(--rot, 0deg)); filter: drop-shadow(0 14px 18px rgba(0, 0, 0, 0.55)); }
.kbox img { position: absolute; left: 0; width: 100%; height: auto; pointer-events: none; user-select: none; }
.kbox .lid { top: 0; z-index: 2; transition: transform 0.9s cubic-bezier(.2, .8, .2, 1), opacity 0.9s; }
.kbox .base { bottom: 0; z-index: 1; }
.kbox .band { position: absolute; z-index: 3; left: 44%; width: 12%; top: 17%; bottom: 7%; background: repeating-linear-gradient(90deg, rgba(160, 140, 110, 0.10) 0 1px, transparent 1px 3px), repeating-linear-gradient(0deg, rgba(160, 140, 110, 0.08) 0 1px, transparent 1px 5px), linear-gradient(90deg, #efe6d4, #fffaf0 40%, #f4ead8); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(120, 100, 70, 0.2); transform-origin: 50% 0; transition: transform 0.6s cubic-bezier(.5, 0, .7, .4), opacity 0.6s; }
.kbox .band i { position: absolute; left: 0; right: 0; top: 18%; height: 3px; background: color-mix(in srgb, var(--pc) 70%, #222); opacity: 0.6; }
.kbox .hanko { position: absolute; z-index: 4; left: 50%; top: 48%; width: 22%; aspect-ratio: 1; transform: translate(-50%, -50%) rotate(-8deg); border-radius: 50%; background: radial-gradient(circle at 40% 35%, #e0303e, #b3101f 70%); color: #fff6ee; display: grid; place-items: center; box-shadow: 0 0 0 3px rgba(179, 16, 31, 0.35), 0 2px 6px rgba(0, 0, 0, 0.4); -webkit-mask: radial-gradient(circle, #000 64%, transparent 66%), repeating-conic-gradient(#000 0 7deg, transparent 7deg 9deg); mask: radial-gradient(circle, #000 64%, transparent 66%), repeating-conic-gradient(#000 0 7deg, transparent 7deg 9deg); transition: transform 0.6s cubic-bezier(.5, 0, .7, .4), opacity 0.6s; }
.kbox .hanko svg { width: 62%; height: 62%; }
.kbox .glowline { position: absolute; z-index: 2; left: 4%; right: 4%; top: 48.6%; height: 3px; border-radius: 3px; background: var(--lc, #fff); box-shadow: 0 0 10px 3px var(--lc, #fff), 0 0 30px 8px var(--lc, #fff); opacity: 0; }
.kbox.arrive { animation: arrive 0.6s cubic-bezier(.2, .9, .3, 1.2); }
@keyframes arrive { from { transform: scale(0.6) translateY(60px); opacity: 0; } }
.kbox.unsealed .band { transform: translate(30%, -40%) rotate(24deg) scaleY(0.3); opacity: 0; }
.kbox.unsealed .hanko { transform: translate(60%, -260%) rotate(220deg) scale(0.6); opacity: 0; }
.kbox.leak .glowline { animation: leak 0.18s steps(2) infinite; opacity: 1; }
@keyframes leak { 50% { opacity: 0.55; } }
.kbox.open .lid { transform: translateY(-150%) rotate(-10deg); opacity: 0; }
.kbox.open .glowline { opacity: 0; transition: opacity 0.4s; }
.box-stage { position: relative; width: min(82vw, 420px); margin: 30px auto; cursor: pointer; --lc: #bfe9ff; }
.box-stage .kbox { --rot: 0deg; }
.box-stage .beam, .box-stage .rays { position: absolute; left: 50%; pointer-events: none; opacity: 0; }
.box-stage .beam { z-index: 0; bottom: 50%; width: 96%; height: 260%; transform: translateX(-50%); background: linear-gradient(0deg, var(--lc), color-mix(in srgb, var(--lc) 40%, transparent) 40%, transparent); -webkit-mask: linear-gradient(90deg, transparent, #000 25%, #000 75%, transparent); mask: linear-gradient(90deg, transparent, #000 25%, #000 75%, transparent); filter: blur(6px); }
.box-stage .rays { z-index: -1; top: 50%; width: 260%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: repeating-conic-gradient(color-mix(in srgb, var(--lc) 70%, transparent) 0 5deg, transparent 5deg 18deg); -webkit-mask: radial-gradient(circle, #000 10%, transparent 65%); mask: radial-gradient(circle, #000 10%, transparent 65%); }
.box-stage.lit .beam { animation: beam 1.1s ease-out forwards; }
.box-stage.lit .rays { animation: rays 1.1s ease-out forwards; }
@keyframes beam { 0% { opacity: 0; transform: translateX(-50%) scaleY(0.2); transform-origin: 50% 100%; } 30% { opacity: 1; } 100% { opacity: 0.9; transform: translateX(-50%) scaleY(1); } }
@keyframes rays { 0% { opacity: 0; transform: translate(-50%, -50%) rotate(0) scale(0.4); } 30% { opacity: 1; } 100% { opacity: 0.8; transform: translate(-50%, -50%) rotate(40deg) scale(1); } }
.box-stage.rainbow .beam { background: linear-gradient(0deg, #ffd36b, #ff8fbd 30%, #c39bff 55%, #3fd2f2 75%, transparent); }
.box-stage.rainbow .rays { background: repeating-conic-gradient(#ffd36b 0 5deg, transparent 5deg 12deg, #ff8fbd 12deg 17deg, transparent 17deg 24deg, #3fd2f2 24deg 29deg, transparent 29deg 36deg); }
.box-stage.rainbow .kbox .glowline { background: linear-gradient(90deg, #ffd36b, #ff8fbd, #c39bff, #3fd2f2, #5ff0c4); box-shadow: 0 0 14px 4px #ff8fbd, 0 0 34px 10px #ffd36b; }
.box-stage.exl .beam { background: linear-gradient(0deg, #fff3c4, #ffd36b 25%, #ff8fbd 55%, transparent); }
.box-stage.exl .rays { background: repeating-conic-gradient(#ffd36b 0 4deg, #120c02 4deg 10deg); }
.box-stage.shake .kbox { animation: shakeS 0.12s linear infinite; }
.box-stage.lv5.shake .kbox, .box-stage.lv6.shake .kbox { animation: shakeM 0.1s linear infinite; }
.box-stage.lv7.shake .kbox, .box-stage.lv8.shake .kbox, .box-stage.lv9.shake .kbox { animation: shakeL 0.08s linear infinite; }
@keyframes shakeS { 25% { transform: translate(-1px, 1px) rotate(-0.4deg); } 75% { transform: translate(1px, -1px) rotate(0.4deg); } }
@keyframes shakeM { 25% { transform: translate(-3px, 2px) rotate(-1deg); } 75% { transform: translate(3px, -2px) rotate(1deg); } }
@keyframes shakeL { 25% { transform: translate(-6px, 3px) rotate(-2deg); } 75% { transform: translate(6px, -3px) rotate(2deg); } }

/* ---------- Le paquet, carte par carte ---------- */
.stack-zone { display: grid; justify-items: center; gap: 14px; width: 100%; }
.stack { position: relative; width: min(76vw, 330px); aspect-ratio: 63 / 88; }
.stack::before, .stack::after { content: ""; position: absolute; inset: 0; border-radius: 5.2% / 3.7%; background: url("../art/dos-pocket.webp") center / cover; box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5); }
.stack::before { transform: translate(10px, 10px) rotate(3deg); opacity: 0.55; }
.stack::after { transform: translate(5px, 5px) rotate(1.5deg); opacity: 0.8; }
.rv-card { position: absolute; inset: 0; z-index: 2; touch-action: none; cursor: grab; transition: transform 0.26s ease-in, opacity 0.26s; animation: rvIn 0.35s cubic-bezier(.2, .9, .3, 1.1); perspective: 1200px; }
.rv-card .rv-in { position: relative; z-index: 1; transform-style: preserve-3d; }
@keyframes rvIn { from { transform: translateY(24px) scale(0.92); opacity: 0.4; } }
.rv-card.spin .rv-in { animation: rvSpin 0.9s cubic-bezier(.2, .7, .2, 1); }
.rv-card.spin2 .rv-in { animation: rvSpin2 1.4s cubic-bezier(.2, .7, .2, 1); }
@keyframes rvSpin { from { transform: rotateY(-360deg) scale(0.7); } }
@keyframes rvSpin2 { 0% { transform: rotateY(-720deg) scale(0.5); filter: brightness(2.2); } 70% { filter: brightness(1.3); } }
.rv-card.away-l { transform: translateX(-130vw) rotate(-26deg) !important; opacity: 0; }
.rv-card.away-r { transform: translateX(130vw) rotate(26deg) !important; opacity: 0; }
.rv-card .aura { position: absolute; inset: -14%; z-index: 0; border-radius: 50%; opacity: 0; pointer-events: none; filter: blur(16px); }
.rv-card.rk-A .aura { opacity: 0.7; background: radial-gradient(circle, rgba(255, 154, 92, 0.75), transparent 65%); }
.rv-card.rk-S .aura { opacity: 1; background: conic-gradient(from var(--ang, 0deg), rgba(255, 211, 107, 0), rgba(255, 211, 107, 0.95), rgba(255, 243, 196, 0.3), rgba(255, 211, 107, 0.95), rgba(255, 211, 107, 0)); animation: spin 4s linear infinite; }
.rv-card.rk-SS .aura { opacity: 1; background: conic-gradient(from var(--ang, 0deg), rgba(238, 244, 255, 0), rgba(238, 244, 255, 0.95), rgba(195, 155, 255, 0.5), rgba(238, 244, 255, 0.95), rgba(238, 244, 255, 0)); animation: spin 3s linear infinite; }
.rv-card.rk-SSS .aura { opacity: 1; background: conic-gradient(from var(--ang, 0deg), #ffd36b, #ff8fbd, #c39bff, #3fd2f2, #5ff0c4, #ffd36b); animation: spin 2.4s linear infinite; }
.rv-card.rk-EX .aura { opacity: 1; inset: -20%; background: conic-gradient(from var(--ang, 0deg), rgba(18, 12, 2, 0), #ffd36b, #fff3c4, #ff8fbd, #ffd36b, rgba(18, 12, 2, 0)); animation: spin 2s linear infinite; }
.spark { position: absolute; z-index: 3; left: 50%; top: 50%; width: 7px; height: 7px; margin: -3px; border-radius: 50%; background: var(--c); box-shadow: 0 0 10px 2px var(--c); animation: spark 1.2s ease-out forwards; pointer-events: none; }
@keyframes spark { from { transform: translate(0, 0) scale(1.4); opacity: 1; } to { transform: translate(var(--x), var(--y)) scale(0.2); opacity: 0; } }
.stack-info { display: flex; gap: 12px; align-items: center; color: var(--mute); font-family: var(--f-display); letter-spacing: 0.06em; }
.newtag { position: absolute; top: -8px; right: -6px; z-index: 6; background: var(--sakura); color: #2a0718; font-family: var(--f-display); font-weight: 800; font-size: 12px; letter-spacing: 0.08em; padding: 2px 8px; border-radius: 999px; box-shadow: 0 0 10px var(--sakura); }
.sum-card { position: relative; border: 0; padding: 0; background: none; animation: deal 0.4s backwards; }
@media (prefers-reduced-motion: reduce) { .rv-card.spin .rv-in, .rv-card.spin2 .rv-in, .rv-card .aura, .box-stage.shake .kbox { animation: none; } }

/* ---------- Cartes non possédées : noir et blanc, floues, pixelisées ---------- */
.unowned { filter: grayscale(1) brightness(0.6) contrast(0.9) blur(1.5px); image-rendering: pixelated; }

/* ---------- Intro : la planète en plein écran ---------- */
.intro-bg { position: absolute; inset: 0; overflow: hidden; }
.intro-bg img { position: absolute; inset: 0; width: 100%; height: 100%; }
.intro-bg .blur { object-fit: cover; filter: blur(26px) brightness(0.55) saturate(1.2); transform: scale(1.1); }
.intro-bg .sharp { object-fit: cover; object-position: 50% 40%; }
@media (min-aspect-ratio: 3/4) { .intro-bg .sharp { object-fit: contain; } }
.intro:not(.play) .intro-bg { opacity: 0.55; }
.intro.play .intro-bg { opacity: 0; transform: scale(1.14); }
.intro-gate { background: radial-gradient(circle at 50% 70%, rgba(3, 8, 18, 0.2), rgba(3, 8, 18, 0.75)); align-content: end; padding-bottom: max(18vh, env(safe-area-inset-bottom)); }
.intro canvas { z-index: 1; }
.intro-title { z-index: 2; bottom: 9%; }

/* ---------- Plateau : hauteurs fixes, rien ne bouge d'un tour à l'autre ---------- */
.board { grid-template-rows: 36px minmax(0, 1fr) 78px minmax(0, 1fr) 36px 112px; }
.board > div:last-child { display: contents; }
.pl-bar { height: 36px; flex-wrap: nowrap; white-space: nowrap; overflow: hidden; min-width: 0; }
.pl-bar .muted { font-size: 12px; }
@media (max-width: 480px) { .pl-bar .backs { display: none; } .pl-bar .lv { display: none; } }
.mid { height: 78px; overflow: hidden; align-content: center; flex-wrap: wrap; row-gap: 4px; }
.mid .lastlog { font-size: 11.5px; min-height: 0; }
.mid .chip { font-size: 12px; padding: 3px 9px; }
.mid .lastlog { flex-basis: 100%; }
.act-slot .unit { height: 100%; max-height: 210px; }
/* Main en éventail : toutes les cartes restent visibles */
.hand { --n: 1; height: 112px; overflow: visible; padding: 6px 8px 0; justify-content: center; gap: 0; }
.hand button { width: 74px; margin-left: calc(-1 * max(0px, (74px * var(--n) - 100%) / max(1, var(--n) - 1))); position: relative; transition: transform 0.15s, margin 0.2s; }
.hand button:first-child { margin-left: 0; }
.hand button:hover, .hand button:focus-visible { transform: translateY(-10px); z-index: 5; }
.hand button.drawn { animation: drawn 0.6s cubic-bezier(.2, .9, .3, 1.2); z-index: 4; }
.hand button.drawn .mini { box-shadow: 0 0 0 2px var(--gold), 0 0 18px rgba(255, 211, 107, 0.8); }
.hand button.drawn::after { content: "PIOCHÉE"; position: absolute; left: 50%; top: -9px; transform: translateX(-50%); background: var(--gold); color: #1a1204; font-family: var(--f-display); font-weight: 800; font-size: 10px; letter-spacing: 0.08em; padding: 0 6px; border-radius: 999px; }
@keyframes drawn { from { transform: translate(120px, -80px) rotate(14deg) scale(0.6); opacity: 0; } }

/* Texte censuré au marqueur noir */
.redact { color: transparent; background: #05070c; border-radius: 3px 6px 4px 7px / 6px 3px 7px 4px; box-shadow: 0 0 0 1px #05070c, 1px 1px 0 2px rgba(5, 7, 12, 0.85); -webkit-box-decoration-break: clone; box-decoration-break: clone; padding: 0 2px; user-select: none; letter-spacing: -0.02em; line-height: 1.7; }
h3 .redact { line-height: 1.2; }

.pack-tile .gift { position: absolute; top: 14px; left: 14px; padding: 3px 10px; border-radius: 999px; background: linear-gradient(135deg, #fff3c4, var(--gold)); color: #1a1204; font-family: var(--f-display); font-weight: 800; letter-spacing: 0.06em; font-size: 13px; box-shadow: 0 0 14px rgba(255, 211, 107, 0.6); }

/* ---------- Nuriim's dollars, quêtes, choix d'ouverture ---------- */
.wallet { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px 5px 6px; border-radius: 999px; border: 1px solid rgba(255, 211, 107, 0.5); background: linear-gradient(135deg, rgba(255, 211, 107, 0.16), rgba(15, 29, 56, 0.7)); font-family: var(--f-display); }
.wallet b { font-size: 20px; font-weight: 800; color: #fff3c4; font-variant-numeric: tabular-nums; }
.wallet small { color: var(--gold); letter-spacing: 0.08em; font-weight: 700; }
.coin-i { width: 24px; height: 24px; flex: none; filter: drop-shadow(0 0 5px rgba(255, 211, 107, 0.6)); }
button .coin-i { width: 18px; height: 18px; vertical-align: -4px; }
.topline { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: start; margin-bottom: 16px; }
@media (max-width: 720px) { .topline { grid-template-columns: 1fr; } }
.quests { border: 1px solid var(--line-soft); border-radius: 16px; background: rgba(15, 29, 56, 0.6); padding: 10px 12px; display: grid; gap: 8px; }
.quests .qh { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.quests .qh b { font-family: var(--f-display); font-size: 17px; letter-spacing: 0.04em; }
.quest { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; }
.quest b { display: block; font-size: 14px; font-weight: 600; }
.quest .qbar { display: block; height: 7px; border-radius: 999px; background: rgba(147, 171, 187, 0.16); margin: 4px 0 2px; overflow: hidden; }
.quest .qbar i { display: block; height: 100%; background: linear-gradient(90deg, var(--mint), var(--gold)); border-radius: inherit; }
.quest small { color: var(--mute); font-size: 12px; }
.quest button { padding: 7px 12px; font-size: 15px; white-space: nowrap; }
.quest.ok { opacity: 0.6; }
.qdone { font-family: var(--f-display); color: var(--mint); letter-spacing: 0.06em; font-size: 14px; }
.pack-opts { display: grid; gap: 8px; margin-top: 8px; }
.popt { display: flex; justify-content: space-between; align-items: center; gap: 10px; text-align: left; border: 1px solid var(--line); background: var(--panel); border-radius: 14px; padding: 12px 14px; }
.popt b { font-family: var(--f-display); font-size: 18px; letter-spacing: 0.02em; }
.popt small { color: var(--mute); font-size: 13px; white-space: nowrap; }
.popt.ten { border-color: rgba(255, 211, 107, 0.6); background: linear-gradient(135deg, rgba(255, 211, 107, 0.12), var(--panel)); }
.popt.ten small { color: var(--gold); }
.popt:not(:disabled):hover { border-color: var(--mint); }
.multi { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px 10px; width: min(100%, 900px); padding: 30px 6px; cursor: pointer; }
@media (max-width: 640px) { .multi { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 14px; padding-top: 40px; } }
.multi .box-stage { width: 100%; margin: 0; }
.multi .box-stage .rays { width: 200%; }
.fan.hundred { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); max-height: 66vh; overflow-y: auto; padding: 10px 4px; }
.sum-card.hot .pc { box-shadow: 0 0 0 2px var(--gold), 0 0 18px rgba(255, 211, 107, 0.6); }

.pack-count { display: flex; gap: 10px; align-items: baseline; font-family: var(--f-display); letter-spacing: 0.06em; }
.pack-count b { font-size: 20px; color: var(--gold); }
.pack-count span { color: var(--mute); font-size: 14px; }

/* ---------- Version, boutique, Points Pocket ---------- */
.intro-ver { position: absolute; left: 0; right: 0; bottom: max(14px, env(safe-area-inset-bottom, 0px)); z-index: 3; text-align: center; font-family: var(--f-display); letter-spacing: 0.12em; font-size: 13px; color: rgba(223, 233, 247, 0.75); text-transform: uppercase; pointer-events: none; }
.tabs { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 480px) { .tabs button { font-size: 10.5px; letter-spacing: 0.02em; } .tabs button svg { width: 22px; height: 22px; } }
.wallet.pts { border-color: rgba(255, 143, 189, 0.5); background: linear-gradient(135deg, rgba(255, 143, 189, 0.16), rgba(15, 29, 56, 0.7)); }
.wallet.pts small { color: var(--sakura); }
.pts-i { width: 22px; height: 22px; flex: none; filter: drop-shadow(0 0 5px rgba(255, 143, 189, 0.6)); }
.shop-item { display: grid; gap: 6px; }
.buy { display: flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid rgba(255, 143, 189, 0.5); background: linear-gradient(135deg, rgba(255, 143, 189, 0.18), var(--panel)); border-radius: 12px; padding: 7px 8px; font-family: var(--f-display); }
.buy b { font-size: 17px; font-variant-numeric: tabular-nums; }
.buy .pts-i { width: 18px; height: 18px; }
.buy.off { opacity: 0.45; }
.shop-item.mystery .miss { aspect-ratio: 63 / 88; }

.announce { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; padding: 12px 14px; border-radius: 16px; border: 1px solid rgba(255, 211, 107, 0.55); background: linear-gradient(120deg, rgba(255, 211, 107, 0.16), rgba(255, 143, 189, 0.12), rgba(63, 210, 242, 0.12)); box-shadow: 0 0 24px rgba(255, 211, 107, 0.18); }
.announce .an-k { flex: none; font-family: var(--f-display); font-weight: 800; letter-spacing: 0.14em; font-size: 12px; padding: 4px 9px; border-radius: 999px; background: var(--gold); color: #1a1204; }
.announce b { display: block; font-family: var(--f-display); font-size: 20px; line-height: 1.1; }
.announce span { color: #d6e6ea; font-size: 13.5px; }
.vault input[type=datetime-local] { background: #081127; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; color: var(--ink); font: inherit; width: 100%; }

/* Boutique : cartes non possédées en petit seulement ; noir et blanc tant qu’on ne peut pas les payer */
.shop-item.bw .pc { filter: grayscale(1) brightness(0.75); }
.shop-item .locked-cell { cursor: default; }

/* ---------- Cueillette ---------- */
.pick { margin: 6px 0 22px; }
.pick-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.pick-head h2 { font-size: 24px; }
.pick-head p { margin: 4px 0 0; font-size: 13.5px; }
.pick-row { display: flex; gap: 12px; overflow-x: auto; padding: 14px 4px 12px; scroll-snap-type: x proximity; scrollbar-width: thin; }
.pick-tile { flex: none; width: 150px; scroll-snap-align: start; display: grid; justify-items: center; gap: 2px; text-align: center; border: 1px solid var(--line-soft); background: linear-gradient(180deg, rgba(19, 36, 74, 0.9), rgba(10, 20, 48, 0.9)); border-radius: 18px; padding: 12px 10px 10px; position: relative; }
.pick-tile:hover { border-color: var(--mint); }
.pick-tile b { font-family: var(--f-display); font-size: 18px; line-height: 1.1; margin-top: 4px; }
.pick-tile small { color: var(--mute); font-size: 11.5px; line-height: 1.2; min-height: 28px; }
.pick-tile .pt-s { display: inline-flex; align-items: center; gap: 4px; font-family: var(--f-display); font-size: 12px; letter-spacing: 0.06em; }
.pick-tile .pt-s svg { width: 14px; height: 14px; }
.pick-tile .pt-best { width: 64px; margin-top: 4px; }
.pick-tile.done { opacity: 0.5; }
.pick-tile .pt-done { position: absolute; top: 8px; right: 8px; font-family: var(--f-display); font-size: 11px; letter-spacing: 0.08em; color: var(--mint); }
.av { position: relative; width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center; isolation: isolate; animation: avBob 3.4s ease-in-out infinite; }
.av::before { content: ""; position: absolute; inset: -4px; border-radius: 50%; z-index: -1; background: conic-gradient(from var(--ang, 0deg), var(--g), transparent 40%, var(--g) 70%, transparent); animation: spin 4s linear infinite; filter: blur(1px); }
.av img, .av b { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; border: 2px solid #081228; }
.av b { display: grid; place-items: center; font-family: var(--f-display); font-size: 34px; background: radial-gradient(circle at 35% 30%, #2a4a8a, #0b1530); color: #eaf6f3; }
.av img { animation: avBreath 3.4s ease-in-out infinite; }
.av .crown { position: absolute; top: -6px; right: -4px; font-style: normal; color: var(--gold); text-shadow: 0 0 8px var(--gold); font-size: 18px; }
.av.big { width: 96px; height: 96px; margin: 0 auto 6px; }
@keyframes avBob { 50% { transform: translateY(-4px); } }
@keyframes avBreath { 50% { transform: scale(1.03); filter: brightness(1.06); } }
.pick-stage .head .av { margin-bottom: 8px; }
.halves { display: grid; gap: 14px; width: min(100%, 760px); }
.half { border: 1px solid var(--line); background: rgba(15, 29, 56, 0.75); border-radius: 18px; padding: 10px; display: grid; gap: 8px; text-align: left; }
.half:hover { border-color: var(--mint); box-shadow: 0 0 20px rgba(95, 240, 196, 0.2); }
.half .hl { font-family: var(--f-display); font-size: 18px; letter-spacing: 0.06em; }
.half .hc { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.pick-table { position: relative; width: min(100%, 640px); height: min(44vw, 260px); margin: 10px auto; }
.pk-card { position: absolute; top: 0; left: calc(var(--x) * 20% + 1%); width: 18%; border: 0; padding: 0; background: none; perspective: 900px; transition: left 0.25s ease-in-out, transform 0.3s; }
.pk-card .in { position: relative; transition: transform 0.5s cubic-bezier(.3, .7, .3, 1); transform-style: preserve-3d; }
.pk-card .face { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.pk-card .face.front { position: absolute; inset: 0; transform: rotateY(180deg); }
.pk-card .in { transform: rotateY(180deg); }
.pk-card.down .in { transform: rotateY(0deg); }
.pk-card.down:hover { transform: translateY(-8px); }
.pk-card.won { transform: translateY(-14px) scale(1.12); z-index: 3; }
.pk-card.won .pc { box-shadow: 0 0 0 2px var(--gold), 0 0 26px rgba(255, 211, 107, 0.8); }
@media (prefers-reduced-motion: reduce) { .av, .av img, .av::before { animation: none; } }

/* ---------- Intro : sous-titres japonais / français, les cinq sens, « par Nuriim's World » ---------- */
.intro-sub { position: absolute; left: 0; right: 0; bottom: 30%; z-index: 2; display: grid; justify-items: center; gap: 6px; text-align: center; padding: 0 16px; pointer-events: none; opacity: 0; }
.intro-sub.in { animation: subIn 0.5s ease-out forwards; }
@keyframes subIn { from { opacity: 0; transform: translateY(8px); filter: blur(4px); } to { opacity: 1; transform: none; filter: none; } }
.intro-sub .jp { white-space: pre-line; line-height: 1.25; font-family: var(--f-body); font-weight: 700; font-size: clamp(20px, 6vw, 36px); letter-spacing: 0.08em; color: #ffffff; text-shadow: 0 0 10px rgba(63, 210, 242, 0.9), 0 0 26px rgba(255, 143, 189, 0.6), 0 2px 4px rgba(0, 0, 0, 0.8); }
.intro-sub .fr { font-size: clamp(13px, 3.6vw, 17px); color: #dfeef3; letter-spacing: 0.04em; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9); background: rgba(3, 8, 18, 0.45); padding: 2px 10px; border-radius: 6px; }
.senses { display: flex; gap: 8px; margin-bottom: 6px; opacity: 0; transition: opacity 0.4s; }
.senses.on { opacity: 1; }
.senses span { display: grid; justify-items: center; gap: 1px; padding: 6px 8px; border-radius: 10px; border: 1px solid rgba(143, 244, 255, 0.25); background: rgba(3, 8, 18, 0.55); color: rgba(223, 238, 243, 0.35); transition: all 0.35s; }
.senses span b { font-family: var(--f-body); font-size: clamp(14px, 4vw, 20px); }
.senses span small { font-size: 10.5px; letter-spacing: 0.06em; }
.senses span.lit { color: #ffffff; border-color: #8ff4ff; box-shadow: 0 0 14px rgba(63, 210, 242, 0.7), inset 0 0 10px rgba(63, 210, 242, 0.35); }
.intro-title { opacity: 0; transition: opacity 0.8s; bottom: 12%; }
.intro-title.show { opacity: 1; }
.intro-title.show .pw { color: #effdff; text-shadow: 0 0 8px #3fd2f2, 0 0 22px #3fd2f2, 0 0 46px rgba(255, 143, 189, 0.8); animation: neonOn 1.2s steps(1) 1; }
@keyframes neonOn { 0% { opacity: 0.2; } 12% { opacity: 1; } 18% { opacity: 0.3; } 26% { opacity: 1; } }
.intro-title .jp { display: none; }
.intro-by { position: absolute; left: 0; right: 0; bottom: calc(max(14px, env(safe-area-inset-bottom, 0px)) + 22px); z-index: 3; display: flex; align-items: center; justify-content: center; gap: 8px; pointer-events: none; color: rgba(223, 233, 247, 0.85); font-family: var(--f-display); letter-spacing: 0.1em; font-size: 13px; text-transform: uppercase; }
.intro-by .wlogo { width: 46px; height: 42px; background: var(--world) center / contain no-repeat; filter: drop-shadow(0 0 8px rgba(143, 244, 255, 0.45)); }
.intro-ver { font-size: 11px; letter-spacing: 0.14em; }

/* Carrousel de l'ouverture : la carte suivante arrive par la droite, la précédente par la gauche */
.rv-card.from-r { animation: rvFromR 0.32s cubic-bezier(.2, .9, .3, 1); }
.rv-card.from-l { animation: rvFromL 0.32s cubic-bezier(.2, .9, .3, 1); }
@keyframes rvFromR { from { transform: translateX(70vw) rotate(10deg); opacity: 0.3; } }
@keyframes rvFromL { from { transform: translateX(-70vw) rotate(-10deg); opacity: 0.3; } }
.stack-info .cnt2::after { content: " · glisse vers la gauche"; color: var(--mute); font-size: 12px; letter-spacing: 0.02em; }
.rv-card img, .pk-card img, .flip img { -webkit-user-drag: none; user-select: none; pointer-events: none; }

/* ---------- Fluidité (2.2) : rotations en transform (et non plus en propriété --ang), moins de repeints ---------- */
@keyframes spinT { to { transform: rotate(360deg); } }
.halo::before { animation: spinT 5s linear infinite; will-change: transform; }
.av::before { animation: spinT 4s linear infinite; will-change: transform; filter: none; }
@keyframes avBreath { 50% { transform: scale(1.03); } }
.rv-card.rk-S .aura { animation: spinT 4s linear infinite; }
.rv-card.rk-SS .aura { animation: spinT 3s linear infinite; }
.rv-card.rk-SSS .aura { animation: spinT 2.4s linear infinite; }
.rv-card.rk-EX .aura { animation: spinT 2s linear infinite; }
.rv-card .aura { will-change: transform; }
.pack-tile::before { animation: none; background: linear-gradient(180deg, rgba(5, 10, 22, 0.05) 30%, rgba(5, 10, 22, 0.92) 85%); }
.pack-tile .foil { position: absolute; inset: 0; z-index: -1; pointer-events: none; background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, 0.18) 48%, transparent 60%); transform: translateX(-100%); animation: foilT 5s linear infinite; will-change: transform; }
@keyframes foilT { to { transform: translateX(100%); } }
.flip.hot.top .pc-back { animation: none; box-shadow: 0 0 0 3px #fff3c4, 0 0 44px rgba(255, 143, 189, 0.85); }
.fluxtok .tdot { animation: none; }
/* grilles longues : les cartes hors de l'écran ne sont ni mises en page ni peintes */
/* 2.5 : content-visibility retiré des grilles (il ralentissait le défilement : chaque carte qui entre à l'écran était remise en page) */
.fan.hundred > .sum-card { content-visibility: auto; contain-intrinsic-size: auto 200px; }
@media (prefers-reduced-motion: reduce) { .pack-tile .foil { animation: none; } }

/* ---------- Combat (2.2) : attaques, dégâts, K.O. et cartes du bot bien visibles ---------- */
.board .fxl { position: fixed; inset: 0; z-index: 70; pointer-events: none; }
.fxl > * { position: fixed; transform: translate(-50%, -50%); }
.dmgnum { font-family: var(--f-display); font-weight: 800; font-size: 34px; line-height: 1; color: #fff; -webkit-text-stroke: 1.5px #3a0710; paint-order: stroke; text-shadow: 0 0 14px rgba(255, 92, 120, 0.9), 0 3px 0 #000; display: grid; justify-items: center; animation: dmgUp 1.3s cubic-bezier(.2, .9, .3, 1) forwards; }
.dmgnum.big { font-size: 46px; color: #fff3c4; text-shadow: 0 0 18px rgba(255, 211, 107, 0.95), 0 3px 0 #000; }
.dmgnum.weak { color: #ffd36b; }
.dmgnum.heal { color: #c9ffe9; -webkit-text-stroke: 1.5px #06382b; text-shadow: 0 0 14px rgba(95, 240, 196, 0.9), 0 3px 0 #000; }
.dmgnum small { font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; -webkit-text-stroke: 0; color: #1a1204; background: var(--gold); border-radius: 999px; padding: 1px 7px; margin-top: 3px; text-shadow: none; }
@keyframes dmgUp { 0% { transform: translate(-50%, -30%) scale(0.4); opacity: 0; } 14% { transform: translate(-50%, -60%) scale(1.25); opacity: 1; } 28% { transform: translate(-50%, -62%) scale(1); } 75% { opacity: 1; } 100% { transform: translate(-50%, -150%) scale(1); opacity: 0; } }
.impact { width: 120px; height: 120px; border-radius: 50%; background: radial-gradient(circle, rgba(255, 255, 255, 0.95) 0 12%, rgba(255, 211, 107, 0.8) 20%, rgba(255, 92, 120, 0.4) 42%, transparent 66%); animation: impact 0.5s ease-out forwards; }
.impact.big { width: 190px; height: 190px; }
@keyframes impact { from { transform: translate(-50%, -50%) scale(0.2); opacity: 1; } to { transform: translate(-50%, -50%) scale(1.3); opacity: 0; } }
.kostamp { font-family: var(--f-display); font-weight: 800; font-size: 54px; line-height: 0.9; letter-spacing: 0.04em; color: #ff5c78; -webkit-text-stroke: 2px #2a0410; paint-order: stroke; text-shadow: 0 0 22px rgba(255, 92, 120, 0.9), 0 4px 0 #000; display: grid; justify-items: center; gap: 6px; animation: koStamp 1.5s cubic-bezier(.2, .9, .3, 1.2) forwards; white-space: nowrap; }
.kostamp small { font-size: 14px; letter-spacing: 0.06em; -webkit-text-stroke: 0; color: #1a1204; background: var(--gold); border-radius: 999px; padding: 3px 10px; text-shadow: none; }
@keyframes koStamp { 0% { transform: translate(-50%, -50%) scale(2.6) rotate(-14deg); opacity: 0; } 18% { transform: translate(-50%, -50%) scale(0.95) rotate(-10deg); opacity: 1; } 26% { transform: translate(-50%, -50%) scale(1.05) rotate(-10deg); } 80% { opacity: 1; } 100% { transform: translate(-50%, -50%) scale(1) rotate(-10deg); opacity: 0; } }
.unit.ko { animation: koFall 1.1s ease-in forwards; }
@keyframes koFall { 0%, 35% { transform: none; opacity: 1; } 100% { transform: translateY(18px) scale(0.7) rotate(-12deg); opacity: 0; } }
.unit.ko .mini { filter: grayscale(1) brightness(0.7); transition: filter 0.3s; }
@keyframes lungeUp { 45% { transform: translateY(-46px) scale(1.12); } }
@keyframes lungeDown { 45% { transform: translateY(46px) scale(1.12); } }
.unit.lunge-up, .unit.lunge-down { z-index: 6; animation-duration: 0.5s; }
.board.quake .side { animation: quake 0.35s; }
@keyframes quake { 20% { transform: translate(-5px, 2px); } 40% { transform: translate(5px, -2px); } 60% { transform: translate(-3px, 1px); } 80% { transform: translate(2px, 0); } }
.hearts i.gain { animation: heartGain 0.9s cubic-bezier(.2, .9, .3, 1.4); }
@keyframes heartGain { 0% { transform: scale(0.2); } 50% { transform: scale(1.9); } 100% { transform: scale(1); } }
.botplay { position: fixed; left: 50%; top: 38%; z-index: 66; transform: translate(-50%, -50%); display: grid; justify-items: center; gap: 8px; pointer-events: none; animation: bpIn 0.35s cubic-bezier(.2, .9, .3, 1.2); transition: opacity 0.3s, transform 0.3s; }
.botplay .bp-card { width: 104px; filter: drop-shadow(0 12px 26px rgba(0, 0, 0, 0.7)) drop-shadow(0 0 16px rgba(255, 143, 189, 0.45)); }
.botplay span { font-family: var(--f-display); font-weight: 700; font-size: 14px; letter-spacing: 0.04em; color: #fff; background: rgba(5, 10, 22, 0.85); border: 1px solid rgba(255, 143, 189, 0.5); border-radius: 999px; padding: 4px 12px; white-space: nowrap; max-width: 86vw; overflow: hidden; text-overflow: ellipsis; }
.botplay.out { opacity: 0; transform: translate(-50%, -90%) scale(0.85); }
@keyframes bpIn { from { transform: translate(-50%, -30%) scale(0.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .board.quake .side, .dmgnum, .kostamp, .botplay { animation-duration: 0.01s; } }
.pack-tile .more { position: absolute; top: 12px; left: 12px; z-index: 2; font-family: var(--f-display); font-weight: 700; font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; background: rgba(5, 10, 22, 0.72); border: 1px solid rgba(255, 255, 255, 0.28); color: #eaf6f3; }
.side.me { position: relative; }
.qatks { position: absolute; right: 2px; top: 50%; transform: translateY(-62%); z-index: 5; display: grid; gap: 6px; width: min(118px, 29vw); }
.qatk { display: grid; grid-template-columns: auto 1fr; align-items: center; column-gap: 5px; text-align: left; padding: 6px 8px; border-radius: 12px; border: 1px solid rgba(95, 240, 196, 0.6); background: linear-gradient(180deg, rgba(20, 52, 70, 0.95), rgba(8, 22, 40, 0.95)); color: #eaf6f3; box-shadow: 0 0 14px rgba(95, 240, 196, 0.25); animation: fadeIn 0.25s; }
.qatk .cost { display: flex; gap: 2px; grid-row: span 2; }
.qatk .cost .tdot { width: 14px; height: 14px; }
.qatk b { font-family: var(--f-display); font-size: 13px; line-height: 1.05; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qatk em { font-style: normal; font-family: var(--f-display); font-weight: 800; font-size: 15px; color: var(--gold); line-height: 1; }
.qatk:active { transform: scale(0.96); }

/* ---------- 2.3 : profil, mode éditeur, cartes Œuvre, feuilleter la collection ---------- */
.bar .me { display: flex; align-items: center; gap: 0; padding: 0; border: 0; background: none; position: relative; }
.bar .me-av { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-family: var(--f-display); font-weight: 800; font-size: 19px; color: #eaf6f3; background: radial-gradient(circle at 35% 30%, #2a4a8a, #0b1530); border: 2px solid var(--gold); box-shadow: 0 0 12px rgba(255, 211, 107, 0.35); }
.bar .me-lv { position: absolute; right: -6px; bottom: -4px; min-width: 20px; height: 18px; padding: 0 4px; border-radius: 999px; background: var(--gold); color: #1a1204; font-family: var(--f-display); font-weight: 800; font-size: 11px; display: grid; place-items: center; }
.bar .me[aria-current="page"] .me-av { border-color: var(--mint); box-shadow: 0 0 14px rgba(95, 240, 196, 0.6); }
.edchip { font-family: var(--f-display); font-weight: 700; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: #1a1204; background: linear-gradient(90deg, #ffd36b, #ff9fc8); border-radius: 999px; padding: 3px 9px; white-space: nowrap; max-width: 34vw; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 480px) { .bar .par span:last-child { display: none; } .edchip { max-width: 22vw; } }
.ed-note { margin: 0 0 14px; padding: 10px 14px; border-radius: 14px; border: 1px solid rgba(255, 159, 200, 0.5); background: rgba(255, 143, 189, 0.1); font-size: 13.5px; }

/* Tirage Œuvre du jour */
.oe-daily { position: relative; display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; margin: 16px 0; padding: 14px 16px; border-radius: 20px; overflow: hidden; isolation: isolate;
  background: radial-gradient(120% 140% at 0% 0%, rgba(255, 143, 189, 0.22), transparent 55%), radial-gradient(120% 140% at 100% 100%, rgba(255, 211, 107, 0.18), transparent 55%), #0b1430; border: 1px solid rgba(255, 211, 107, 0.45); box-shadow: 0 0 0 1px rgba(255, 246, 216, 0.08) inset, 0 12px 30px rgba(0, 0, 0, 0.35); }
.oe-fan { position: relative; width: 108px; height: 96px; }
.oe-fan img { position: absolute; top: 4px; width: 60px; aspect-ratio: 63 / 88; object-fit: cover; object-position: 50% 10%; border-radius: 7px; border: 2px solid #f4d98e; box-shadow: 0 6px 14px rgba(0, 0, 0, 0.5); }
.oe-fan img:nth-child(1) { left: 0; transform: rotate(-12deg); } .oe-fan img:nth-child(2) { left: 24px; z-index: 2; top: -2px; } .oe-fan img:nth-child(3) { left: 48px; transform: rotate(12deg); }
.oe-daily.ready .oe-fan img:nth-child(2) { animation: oeBob 3s ease-in-out infinite; }
@keyframes oeBob { 50% { transform: translateY(-5px); } }
.oe-d-txt { display: grid; gap: 3px; min-width: 0; }
.oe-d-txt small { font-family: var(--f-display); font-weight: 700; font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; color: #ffc2de; }
.oe-d-txt b { font-family: var(--f-display); font-size: 22px; line-height: 1; }
.oe-d-txt span { font-size: 13.5px; color: var(--mute); }
.oe-d-txt .oe-rates { font-family: var(--f-display); letter-spacing: 0.04em; color: var(--gold); font-size: 13px; }
@media (max-width: 640px) { .oe-daily { grid-template-columns: auto 1fr; } .oe-daily > .cta { grid-column: 1 / -1; } .oe-fan { width: 92px; height: 86px; } .oe-fan img { width: 52px; } .oe-fan img:nth-child(2) { left: 20px; } .oe-fan img:nth-child(3) { left: 40px; } }
.popt.oe-opt { border-color: color-mix(in srgb, var(--pc) 55%, transparent); }

/* Révélation d'une Œuvre */
.oe-reveal { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; align-content: center; gap: 18px; padding: 20px; overflow: hidden;
  background: radial-gradient(60% 50% at 50% 42%, rgba(255, 211, 107, 0.16), transparent 70%), radial-gradient(80% 60% at 50% 100%, rgba(255, 143, 189, 0.16), transparent 70%), #04070f; animation: fadeIn 0.4s; }
.oe-reveal.bye { opacity: 0; transition: opacity 0.3s; }
.oe-rays { position: absolute; left: 50%; top: 42%; width: 160vmax; height: 160vmax; margin: -80vmax 0 0 -80vmax; opacity: 0; pointer-events: none;
  background: repeating-conic-gradient(from 0deg, rgba(255, 228, 160, 0.16) 0 5deg, transparent 5deg 15deg); -webkit-mask: radial-gradient(circle, #000 0%, transparent 55%); mask: radial-gradient(circle, #000 0%, transparent 55%); transition: opacity 1s 0.4s; will-change: transform; animation: spinT 40s linear infinite; }
.oe-reveal.open .oe-rays { opacity: 1; }
.oe-reveal.os3 .oe-rays { background: repeating-conic-gradient(from 0deg, rgba(255, 228, 160, 0.22) 0 5deg, transparent 5deg 12deg, rgba(255, 159, 200, 0.18) 12deg 16deg, transparent 16deg 24deg); }
.oe-petals { position: absolute; inset: 0; pointer-events: none; }
.oe-petals i { position: absolute; top: -6vh; left: var(--x); width: 13px; height: 9px; border-radius: 80% 0 80% 0; background: linear-gradient(135deg, #ffe3ef, #ff9fc8); box-shadow: 0 0 6px rgba(255, 159, 200, 0.6); opacity: 0.9; transform: rotate(var(--r)) scale(var(--s)); animation: petalFall var(--t) linear var(--d) infinite; will-change: transform; }
@keyframes petalFall { to { transform: translate(-14vw, 112vh) rotate(calc(var(--r) + 560deg)) scale(var(--s)); } }
.oe-stage { position: relative; z-index: 2; perspective: 1200px; }
.oe-frame { position: relative; width: min(72vw, 320px, 46vh); padding: 14px; border-radius: 18px; background: linear-gradient(150deg, #fff6d8, #c99c46 30%, #6e4d14 50%, #f4d98e 70%, #fff6d8); box-shadow: 0 0 0 2px #2a1a04, 0 0 0 5px #e7c372, 0 30px 70px rgba(0, 0, 0, 0.7), 0 0 80px rgba(255, 211, 107, 0.35); transform: scale(0.86) translateY(16px); opacity: 0; animation: oeFrameIn 0.8s 0.15s cubic-bezier(.2, .9, .3, 1.1) forwards; }
.oe-reveal.os3 .oe-frame { box-shadow: 0 0 0 2px #2a1a04, 0 0 0 5px #e7c372, 0 30px 70px rgba(0, 0, 0, 0.7), 0 0 90px rgba(255, 211, 107, 0.55), 0 0 160px rgba(255, 143, 189, 0.35); }
@keyframes oeFrameIn { to { transform: none; opacity: 1; } }
.oe-card { position: relative; border-radius: 10px; overflow: hidden; }
.oe-curtain { position: absolute; top: 14px; bottom: 14px; width: calc(50% - 14px); z-index: 3; transition: transform 1.25s cubic-bezier(.65, 0, .25, 1); will-change: transform;
  background: repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.18) 0 7px, rgba(255, 255, 255, 0.06) 7px 14px), linear-gradient(180deg, #9b1730, #6a0d1f 60%, #4a0815); box-shadow: inset 0 0 22px rgba(0, 0, 0, 0.55); }
.oe-curtain.l { left: 14px; border-radius: 10px 0 0 10px; border-right: 3px solid #e7c372; transform-origin: 0 50%; }
.oe-curtain.r { right: 14px; border-radius: 0 10px 10px 0; border-left: 3px solid #e7c372; transform-origin: 100% 50%; }
.oe-curtain::after { content: "花"; position: absolute; top: 46%; font-family: "Zen Kaku Gothic New", serif; font-size: 34px; color: #f4d98e; text-shadow: 0 0 10px rgba(255, 211, 107, 0.7); }
.oe-curtain.l::after { right: 8px; } .oe-curtain.r::after { content: "見"; left: 8px; }
.oe-reveal:not(.open) .oe-curtain.l { animation: curtainBreath 2s ease-in-out infinite; }
@keyframes curtainBreath { 50% { transform: scaleX(0.985); } }
.oe-reveal.open .oe-curtain.l { transform: translateX(-108%) scaleX(0.3); }
.oe-reveal.open .oe-curtain.r { transform: translateX(108%) scaleX(0.3); }
.oe-reveal.open .oe-curtain { opacity: 0; transition: transform 1.25s cubic-bezier(.65, 0, .25, 1), opacity 0.6s 0.9s; }
.oe-flash { position: absolute; inset: 0; z-index: 4; border-radius: 18px; background: radial-gradient(circle, #fffaf0, rgba(255, 236, 170, 0.6) 40%, transparent 70%); opacity: 0; pointer-events: none; }
.oe-reveal.open .oe-flash { animation: oeFlash 1.1s 0.25s ease-out; }
@keyframes oeFlash { 20% { opacity: 1; } 100% { opacity: 0; } }
.oe-cap { position: relative; z-index: 2; display: grid; justify-items: center; gap: 5px; text-align: center; opacity: 0; transform: translateY(14px); transition: opacity 0.5s 0.9s, transform 0.5s 0.9s; }
.oe-reveal.open .oe-cap { opacity: 1; transform: none; }
.oe-cap small { font-family: var(--f-display); font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: #ffc2de; font-size: 12px; }
.oe-cap b { font-family: var(--f-display); font-size: 28px; line-height: 1; background: linear-gradient(90deg, #fff3c4, #ffd36b, #ffb3d1); -webkit-background-clip: text; background-clip: text; color: transparent; }
.oe-st { display: flex; gap: 6px; height: 34px; }
.oe-st i { font-style: normal; font-size: 30px; color: #ffd36b; text-shadow: 0 0 14px rgba(255, 211, 107, 0.95); opacity: 0; transform: scale(2.6) rotate(-30deg); }
.oe-reveal.open .oe-st i { animation: starPop 0.45s cubic-bezier(.2, .9, .3, 1.4) forwards; animation-delay: calc(1.45s + var(--i) * 0.35s); }
@keyframes starPop { to { opacity: 1; transform: none; } }
.oe-info { font-size: 13.5px; color: var(--mute); } .oe-info em { font-style: normal; font-weight: 800; color: var(--sakura); letter-spacing: 0.08em; }
.oe-hint { position: absolute; bottom: max(22px, env(safe-area-inset-bottom)); left: 0; right: 0; text-align: center; margin: 0; color: var(--mute); font-family: var(--f-display); letter-spacing: 0.14em; text-transform: uppercase; font-size: 12px; transition: opacity 0.3s; }
.oe-reveal.open .oe-hint { opacity: 0; }
@media (prefers-reduced-motion: reduce) { .oe-petals, .oe-rays { display: none; } .oe-curtain { transition-duration: 0.2s; } }

/* Œuvres manquantes, cartes recherchées */
.oe-miss { position: relative; width: 100%; aspect-ratio: 63 / 88; border-radius: 5.2% / 3.7%; overflow: hidden; border: 1.5px solid rgba(244, 217, 142, 0.35); background: #0a0f1e; container-type: inline-size; }
.oe-miss img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(0.9) brightness(0.62); image-rendering: pixelated; }
.oe-miss span { position: absolute; left: 0; right: 0; bottom: 0; padding: 6cqw 4cqw 4cqw; text-align: center; font-family: var(--f-display); font-weight: 700; font-size: 8cqw; letter-spacing: 0.06em; color: #f4d98e; background: linear-gradient(180deg, transparent, rgba(5, 10, 22, 0.92)); }
.want-dot { position: absolute; top: 4cqw; right: 4cqw; font-style: normal; color: var(--sakura); font-size: 10cqw; text-shadow: 0 0 8px rgba(255, 143, 189, 0.9); }
.miss.wanted { border-color: rgba(255, 143, 189, 0.7); color: var(--sakura); }
.miss.wanted b { color: rgba(255, 143, 189, 0.75); }
.oe-title .oe-cnt { font-family: var(--f-display); font-size: 18px; color: #f4d98e; } .oe-title .oe-cnt b { font-size: 22px; }
.want-ph { width: 100%; aspect-ratio: 63 / 88; border-radius: 5.2% / 3.7%; overflow: hidden; }
.want-ph img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) brightness(0.62); image-rendering: pixelated; }

/* Fiche d'une carte : feuilleter d'un glissé */
.cv-carousel .cv-wrap { display: contents; }
.cv-carousel .cv-card { touch-action: pan-y; }
.cv-carousel .cv-wrap.in-r > .cv-card { animation: cvInR 0.32s cubic-bezier(.2, .8, .3, 1); }
.cv-carousel .cv-wrap.in-l > .cv-card { animation: cvInL 0.32s cubic-bezier(.2, .8, .3, 1); }
@keyframes cvInR { from { transform: translateX(46%) rotate(4deg); opacity: 0; } }
@keyframes cvInL { from { transform: translateX(-46%) rotate(-4deg); opacity: 0; } }
.cv-nav { position: fixed; top: 50%; z-index: 3; width: 44px; height: 64px; margin-top: -32px; border-radius: 14px; border: 1px solid var(--line); background: rgba(8, 16, 34, 0.75); color: var(--ink); font-size: 30px; line-height: 1; display: grid; place-items: center; }
.cv-nav.prev { left: max(8px, env(safe-area-inset-left)); } .cv-nav.next { right: max(8px, env(safe-area-inset-right)); }
@media (max-width: 640px) { .cv-nav { width: 34px; height: 52px; font-size: 24px; top: auto; bottom: max(14px, env(safe-area-inset-bottom)); margin: 0; } }
.cv-pos { grid-column: 1 / -1; text-align: center; font-size: 12.5px; }

/* Profil */
.profile h2 { margin: 24px 0 10px; display: flex; align-items: baseline; gap: 10px; }
.profile h2 small { font-size: 14px; font-family: var(--f-body); font-weight: 500; }
.pf-head { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; padding: 16px; border-radius: 20px; background: radial-gradient(120% 140% at 0% 0%, rgba(63, 210, 242, 0.16), transparent 60%), rgba(15, 29, 56, 0.75); border: 1px solid var(--line); }
@media (max-width: 560px) { .pf-head { grid-template-columns: auto 1fr; } .pf-head > .ghost { grid-column: 1 / -1; } }
.pf-av { position: relative; width: 78px; height: 78px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 35% 30%, #2a4a8a, #0b1530); border: 3px solid var(--gold); box-shadow: 0 0 22px rgba(255, 211, 107, 0.35); }
.pf-av span { font-family: var(--f-display); font-weight: 800; font-size: 38px; }
.pf-lv { position: absolute; right: -6px; bottom: -4px; font-style: normal; min-width: 30px; height: 26px; padding: 0 6px; border-radius: 999px; background: var(--gold); color: #1a1204; font-family: var(--f-display); font-weight: 800; font-size: 16px; display: grid; place-items: center; box-shadow: 0 0 0 3px #0b1530; }
.pf-id { display: grid; gap: 5px; min-width: 0; }
.pf-id small { font-family: var(--f-display); letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); font-weight: 700; font-size: 12px; }
.pf-id b { font-family: var(--f-display); font-size: 28px; line-height: 1; }
.pf-id .muted { font-size: 12.5px; }
.pf-xp { height: 10px; border-radius: 999px; background: rgba(5, 10, 22, 0.9); border: 1px solid var(--line-soft); overflow: hidden; }
.pf-xp i { display: block; height: 100%; background: linear-gradient(90deg, var(--mint), var(--cyan), var(--gold)); }
.pf-stats { margin-top: 12px; display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
@media (max-width: 720px) { .pf-stats { grid-template-columns: repeat(3, 1fr); } }
.pf-stats div { padding: 10px 6px; border-radius: 14px; background: rgba(15, 29, 56, 0.6); border: 1px solid var(--line-soft); text-align: center; }
.pf-stats b { display: block; font-family: var(--f-display); font-size: 24px; line-height: 1; } .pf-stats b small { font-size: 14px; color: var(--mute); }
.pf-stats span { font-size: 11.5px; color: var(--mute); }
.pf-favs, .pf-wants { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
@media (max-width: 520px) { .pf-favs, .pf-wants { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.pf-cups { display: flex; flex-wrap: wrap; gap: 8px; }
.pf-cups span { display: grid; grid-template-columns: auto auto; align-items: center; column-gap: 6px; padding: 6px 12px 6px 8px; border-radius: 999px; background: rgba(15, 29, 56, 0.6); border: 1px solid var(--line-soft); }
.pf-cups .cup { width: 24px; height: 24px; grid-row: span 2; } .pf-cups b { font-family: var(--f-display); font-size: 17px; line-height: 1; } .pf-cups small { font-size: 11px; color: var(--mute); line-height: 1; }
.pf-tro { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 8px; }
.tro { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 16px; background: rgba(15, 29, 56, 0.55); border: 1px solid var(--line-soft); }
.tro > div { display: grid; gap: 3px; min-width: 0; } .tro b { font-family: var(--f-display); font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .tro .muted { font-size: 12px; } .tro small { font-size: 11.5px; color: var(--mute); }
.tro.got { border-color: color-mix(in srgb, var(--tc2, var(--gold)) 45%, transparent); }
.tro.obsidienne { background: radial-gradient(120% 140% at 0% 0%, rgba(180, 140, 255, 0.22), transparent 60%), rgba(20, 12, 36, 0.8); border-color: rgba(180, 140, 255, 0.6); }
.tro.diamant { background: radial-gradient(120% 140% at 0% 0%, rgba(143, 233, 255, 0.2), transparent 60%), rgba(15, 29, 56, 0.6); }
.cup { width: 22px; height: 22px; vertical-align: -5px; } .cup.big { width: 40px; height: 40px; }
.cup.none { opacity: 0.45; }
.cup.diamant, .cup.obsidienne { filter: drop-shadow(0 0 6px var(--cc)); }
.cup.obsidienne path:first-child { fill: #241433; stroke: #b48cff; }
.toast .cup { margin-right: 4px; }
.tro .qbar { display: block; height: 6px; border-radius: 999px; background: rgba(5, 10, 22, 0.9); overflow: hidden; margin-top: 2px; }
.tro .qbar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--mint), var(--gold)); }
@media (max-width: 560px) { .pf-tro { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; } .tro { grid-template-columns: 1fr; gap: 4px; padding: 8px 10px; } .tro .cup.big { width: 28px; height: 28px; } .tro b { font-size: 14px; white-space: normal; line-height: 1.1; } .ed-l { display: none; } .bar .ttl small { display: none; } .edchip { max-width: none; } }
/* Collection : les cartes manquantes montrent leur illustration en noir et blanc, floutée et pixelisée */
.miss.px { position: relative; overflow: hidden; border-style: solid; border-color: rgba(147, 171, 187, 0.22); }
.miss.px img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.9; }
.miss.px img:not([src]) { visibility: hidden; }
.miss.px::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5, 10, 22, 0.15), rgba(5, 10, 22, 0.75)); }
.miss.px b, .miss.px span { position: relative; z-index: 1; text-shadow: 0 2px 8px #000; }
.miss.px b { color: rgba(220, 232, 245, 0.85); }
.miss.px img.unowned, .oe-miss img.unowned { filter: grayscale(1) brightness(1.15) contrast(1.05) blur(0.6px); }
.miss.px::after { background: linear-gradient(180deg, rgba(5, 10, 22, 0.05) 40%, rgba(5, 10, 22, 0.7)); }
/* Bible : galerie des Œuvres */
.oe-gal { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin-bottom: 8px; }
@media (max-width: 640px) { .oe-gal { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; } }
.oe-g { position: relative; display: block; padding: 0; border: 1.5px solid rgba(244, 217, 142, 0.6); border-radius: 12px; overflow: hidden; aspect-ratio: 3 / 4; background: #0a0f1e; text-align: left; box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4); }
.oe-g img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 10%; }
.oe-g span { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 8px 7px; display: grid; gap: 1px; background: linear-gradient(180deg, transparent, rgba(5, 10, 22, 0.9)); }
.oe-g b { font-family: var(--f-display); font-size: 13px; line-height: 1.1; } .oe-g i { font-style: normal; color: var(--gold); font-size: 12px; letter-spacing: 1px; }
.oe-g.locked { border-color: rgba(147, 171, 187, 0.25); } .oe-g.locked img { filter: grayscale(1) brightness(1.1) blur(0.6px); }
/* plateau de combat sur grand écran : le décor couvre tout l'écran, pas seulement la colonne de jeu */
.board { box-shadow: 0 0 0 100vmax #050914; }
.edchip { flex: none; }

/* 2.5 — cartes non possédées : le noir et blanc est cuit dans la petite image, plus de filtre CSS coûteux pendant le défilement */
img.unowned.pxd { filter: brightness(0.55); image-rendering: auto; }
.miss.px img.unowned.pxd, .oe-miss img.unowned.pxd { filter: none; }
.oe-miss img:not([src]) { visibility: hidden; }
.miss.px::after { background: radial-gradient(ellipse 70% 32% at 50% 47%, rgba(5, 10, 22, 0.5), transparent), linear-gradient(180deg, rgba(5, 10, 22, 0.05) 40%, rgba(5, 10, 22, 0.7)); }
.miss.px span { color: rgba(226, 236, 248, 0.82); }
/* 2.5 — le cadre néon du dos de carte (flous SVG) ne change plus qu'aux instants du grésillement : plus de rendu continu */
.back-ov .frame { animation: neonStep 4s steps(1, end) infinite; }
@keyframes neonStep { 0% { opacity: 1; } 50% { opacity: 0.8; } 51.5% { opacity: 1; } 53% { opacity: 0.88; } 55% { opacity: 1; } 100% { opacity: 1; } }
/* 2.5 — fenêtres : fond simplement assombri ; le flou d'arrière-plan coûtait cher quand quelque chose bouge derrière (≈ 21 → 60 i/s sur grand écran) */
.modal { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(3, 7, 15, 0.88); }
/* 2.6 — page Boosters : les boosters d'abord, puis l'Œuvre du jour, les quêtes, la Cueillette */
.bdaily { margin: 0 0 12px; }
.bdaily + .packs { margin-bottom: 4px; }
.quests { margin: 16px 0; }
.pack-tile .more { top: auto; left: auto; right: 12px; bottom: 12px; }   /* ne cache plus le badge « 10 offerts » */
.pool > p.muted { grid-column: 1 / -1; }   /* message « collection vide » sur toute la largeur */
/* récap d'ouverture : « NOUVELLE » en bas de la carte, le nom et l'INT restent lisibles */
.sum-card .newtag { top: auto; bottom: -8px; right: 50%; transform: translateX(50%); font-size: 10.5px; padding: 1px 8px; white-space: nowrap; }
/* 2.6 — passage de niveau */
.lvup { position: fixed; left: 50%; top: calc(76px + env(safe-area-inset-top, 0px)); z-index: 95; transform: translateX(-50%); min-width: 220px; padding: 12px 24px 13px; border-radius: 18px; text-align: center; pointer-events: none;
  background: linear-gradient(135deg, #22305c, #0d1730 70%); border: 1px solid rgba(255, 211, 107, 0.65); box-shadow: 0 0 0 1px rgba(255, 243, 196, 0.15) inset, 0 10px 40px rgba(0, 0, 0, 0.55), 0 0 34px rgba(255, 211, 107, 0.3);
  animation: lvIn 0.55s cubic-bezier(0.2, 1.5, 0.4, 1) both, lvOut 0.45s 2.8s ease-in forwards; }
.lvup small { display: block; font-family: var(--f-display); font-weight: 700; letter-spacing: 0.24em; font-size: 11px; color: var(--gold); }
.lvup b { display: block; font-family: var(--f-display); font-weight: 800; font-size: 32px; line-height: 1.05; color: #fff8e1; text-shadow: 0 0 18px rgba(255, 211, 107, 0.6); }
.lvup span { font-size: 13px; color: #c9d6e6; } .lvup em { font-style: normal; color: var(--gold); font-weight: 700; }
@keyframes lvIn { from { opacity: 0; transform: translateX(-50%) scale(0.6); } }
@keyframes lvOut { to { opacity: 0; transform: translateX(-50%) translateY(-12px); } }
.bar .me.pulse .me-lv { animation: lvPulse 0.7s ease-out 3; }
@keyframes lvPulse { 40% { transform: scale(1.55); box-shadow: 0 0 14px var(--gold); } }
@media (prefers-reduced-motion: reduce) { .lvup { animation-duration: 0.01s, 0.01s; } .bar .me.pulse .me-lv { animation: none; } }
/* 2.6 — profil public dans la Cueillette */
.av .av-lv { position: absolute; right: -4px; bottom: -2px; z-index: 2; min-width: 22px; height: 20px; padding: 0 5px; border-radius: 999px; background: var(--gold); color: #1a1204; font: 800 12px/20px var(--f-display); font-style: normal; text-align: center; box-shadow: 0 0 0 2px #0b1430; }
.pick-stage .head .pk-prof { padding: 6px 12px; font-size: 13px; }
.po-head { display: flex; align-items: center; gap: 14px; margin-bottom: 6px; }
.po-head .av { animation: none; }
.po-h { font-size: 17px; margin: 14px 0 8px; }
.po-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; }
.po-c.unown .mini { filter: grayscale(1) brightness(0.75); }
.endcard .end-st { margin: 8px 0 0; font-size: 13.5px; color: #c9d6e6; } .endcard .end-st b { color: var(--gold); }
.sheet .x { z-index: 6; }   /* au-dessus d'une illustration filtrée (le filtre crée un contexte d'empilement) */
/* 3.0 — nouveautés */
.news small { font-family: var(--f-display); letter-spacing: 0.22em; font-size: 11px; color: var(--cyan); }
.news h2 { margin: 2px 0 10px; }
.news .news-gift { margin: 0 0 12px; padding: 10px 12px; border-radius: 12px; background: linear-gradient(135deg, rgba(255, 211, 107, 0.16), rgba(255, 143, 189, 0.1)); border: 1px solid rgba(255, 211, 107, 0.4); }
.news ul { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
.news li { display: grid; gap: 2px; padding-left: 14px; border-left: 2px solid rgba(95, 240, 196, 0.5); }
.news li b { font-family: var(--f-display); font-size: 17px; }
.news li span { font-size: 14px; color: #c9d6e6; line-height: 1.4; }
/* 2.9 — tickets des boosters gratuits du jour : petits boosters scellés plutôt que des cases vides */
.daily .tickets i { position: relative; display: grid; place-items: center; overflow: hidden; }
.daily .tickets i::before { content: ""; position: absolute; left: 0; right: 0; top: 7px; height: 3px; background: rgba(255, 255, 255, 0.35); }
.daily .tickets i::after { content: "✦"; font-style: normal; font-size: 13px; line-height: 1; color: #eafff8; text-shadow: 0 0 8px rgba(95, 240, 196, 0.9); }
.daily .tickets i.used::before { background: rgba(147, 171, 187, 0.18); }
.daily .tickets i.used::after { content: "✓"; color: rgba(147, 171, 187, 0.55); text-shadow: none; font-size: 12px; }
img[data-px]:not([src]) { visibility: hidden; }   /* pas de texte « alt » ni d'icône cassée avant la pixelisation */
.hs-title { flex-wrap: wrap; row-gap: 2px; } .hs-title h2 { white-space: nowrap; }   /* « Hors-série » ne se coupe plus au trait d'union */
.intro-bg { will-change: transform, opacity; }   /* le fond flouté de l'intro est animé par le compositeur, sans être redessiné */
@media (max-width: 480px) { .intro-sub .jp { font-size: 5.3vw; letter-spacing: 0.04em; } }   /* « ヌリームズ・ポケット・ワールド » tient sur une ligne */

/* Série annoncée (3.1) : tuile floutée, compte à rebours ; quatre séries côte à côte sur grand écran */
.packs { grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); }
@media (max-width: 980px) { .packs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) { .packs { grid-template-columns: 1fr; } }
.pack-tile.soon { cursor: default; }
.pack-tile.soon img { filter: blur(9px) saturate(0.7) brightness(0.5); transform: scale(1.14); }
.pack-tile.soon:hover img { transform: scale(1.14); }
.pack-tile.soon::before { animation: none; background: linear-gradient(180deg, rgba(5, 10, 22, 0.15) 20%, rgba(5, 10, 22, 0.9) 80%); }
.pack-tile.soon::after { border-style: dashed; }
.pack-tile .soon-tag { position: absolute; top: 12px; left: 12px; padding: 4px 11px; border-radius: 999px; background: rgba(5, 10, 22, 0.78); border: 1px solid var(--pc); color: var(--pc); font-family: var(--f-display); font-weight: 800; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; }
.pack-tile .pk .cd { display: block; margin-top: 8px; color: #fff; font-family: var(--f-display); font-weight: 700; font-size: 22px; letter-spacing: 0.04em; font-variant-numeric: tabular-nums; text-shadow: 0 0 14px color-mix(in srgb, var(--pc) 70%, transparent); }
@media (max-width: 720px) { .pack-tile .pk .cd { font-size: 19px; margin-top: 4px; } }
.pack-tile .pk .cd { white-space: nowrap; }
@media (min-width: 981px) { .pack-tile .pk .cd { font-size: 18px; } }

/* 3.2 : avatars (planche app/avatars.webp) */
.bar .me-av.pic, .pf-av.pic { background-color: #0b1530; background-repeat: no-repeat; }
.pf-av { padding: 0; color: inherit; cursor: pointer; font: inherit; }
.pf-av:focus-visible { outline: 3px solid var(--mint); outline-offset: 3px; }
.pf-btns { display: flex; flex-direction: column; gap: 8px; }
@media (max-width: 720px) { .pf-btns { flex-direction: row; flex-wrap: wrap; } }
.av b.pic { background-color: #0b1530; background-repeat: no-repeat; }
.av-pick { display: grid; gap: 14px; margin-top: 10px; }
.av-row small { display: block; font-family: var(--f-display); font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; font-size: 12px; color: var(--pc, var(--mute)); margin-bottom: 6px; }
.av-row > div { display: flex; flex-wrap: wrap; gap: 12px; }
.av-opt { display: grid; justify-items: center; gap: 5px; width: 86px; padding: 0; border: 0; background: none; color: inherit; cursor: pointer; font: inherit; }
.av-opt i { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-family: var(--f-display); font-weight: 800; font-size: 32px; color: #eaf6f3; background: radial-gradient(circle at 35% 30%, #2a4a8a, #0b1530); background-repeat: no-repeat; border: 2px solid rgba(255, 255, 255, 0.16); transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s; }
.av-opt span { font-size: 12.5px; line-height: 1.2; text-align: center; color: var(--mute); }
.av-opt:hover i { transform: translateY(-2px); border-color: rgba(255, 255, 255, 0.4); }
.av-opt[aria-pressed="true"] i { border: 3px solid var(--gold); box-shadow: 0 0 16px rgba(255, 211, 107, 0.55); }
.av-opt[aria-pressed="true"] span { color: var(--gold); font-weight: 700; }
.av-opt:focus-visible i { outline: 3px solid var(--mint); outline-offset: 2px; }
.av-soon { font-size: 13px; margin: 0; }
@media (max-width: 560px) { .pf-head > .pf-btns { grid-column: 1 / -1; } }

/* ---------- 3.3 : halos et ouverture des cartes spéciales sans flou animé ni filtre (clignotements sur téléphone) ---------- */
.halo::before { filter: none; inset: -10%; background: radial-gradient(closest-side, rgba(255, 211, 107, 0.6), rgba(255, 143, 189, 0.3) 55%, rgba(255, 211, 107, 0) 100%); animation: haloPulse 3.2s ease-in-out infinite; will-change: transform, opacity; }
@keyframes haloPulse { 0%, 100% { transform: scale(0.96); opacity: 0.75; } 50% { transform: scale(1.05); opacity: 1; } }
.rv-card .rv-in { transform-style: flat; backface-visibility: visible; }
.rv-card .aura { filter: none; will-change: transform, opacity; }
.rv-card.rk-A .aura { animation: none; }
.rv-card.rk-S .aura { background: radial-gradient(closest-side, rgba(255, 211, 107, 0.85), rgba(255, 211, 107, 0.25) 60%, rgba(255, 211, 107, 0)); animation: auraPulse 2.8s ease-in-out infinite; }
.rv-card.rk-SS .aura { background: radial-gradient(closest-side, rgba(238, 244, 255, 0.9), rgba(195, 155, 255, 0.4) 60%, rgba(195, 155, 255, 0)); animation: auraPulse 2.4s ease-in-out infinite; }
.rv-card.rk-SSS .aura { background: radial-gradient(closest-side, rgba(255, 211, 107, 0.9), rgba(255, 143, 189, 0.55) 45%, rgba(63, 210, 242, 0.3) 72%, rgba(63, 210, 242, 0)); animation: auraPulse 2s ease-in-out infinite; }
.rv-card.rk-EX .aura { background: radial-gradient(closest-side, rgba(255, 243, 196, 0.95), rgba(255, 211, 107, 0.65) 45%, rgba(255, 143, 189, 0.32) 72%, rgba(255, 143, 189, 0)); animation: auraPulse 1.8s ease-in-out infinite; }
@keyframes auraPulse { 0%, 100% { transform: scale(0.97); opacity: 0.8; } 50% { transform: scale(1.06); opacity: 1; } }
/* le grand tour des cartes SS et plus : éclair blanc par-dessus (opacité) au lieu d'un filtre de luminosité sur toute la carte */
@keyframes rvSpin2 { 0% { transform: rotateY(-720deg) scale(0.5); } }
.rv-card.spin2::after { content: ""; position: absolute; inset: -4%; z-index: 3; pointer-events: none; border-radius: 8%; background: radial-gradient(closest-side, rgba(255, 255, 255, 0.95), rgba(255, 243, 196, 0.55) 60%, rgba(255, 243, 196, 0)); opacity: 0; animation: rvFlash 1.4s ease-out; }
@keyframes rvFlash { 0% { opacity: 0.85; } 55% { opacity: 0.3; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .halo::before, .rv-card .aura, .rv-card.spin2::after { animation: none; } }

/* 3.4 : code du coffre */
.pin-box { text-align: center; }
.pin-in { width: 9.5ch; margin: 0 auto; display: block; padding: 10px 14px; border-radius: 14px; border: 2px solid var(--line); background: rgba(6, 12, 24, 0.7); color: var(--ink); font-family: var(--f-display); font-weight: 800; font-size: 34px; letter-spacing: 0.5em; text-indent: 0.5em; text-align: center; }
.pin-in:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(255, 211, 107, 0.25); }
.pin-in.shake { animation: shakeM 0.32s 2; border-color: var(--red); }
.pin-msg { min-height: 1.3em; margin: 10px 0 0; }

/* 3.5 : écran après une ouverture qui efface (fond nuit, cartes qui s'éteignent une à une) */
.eclipse { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; overflow-y: auto; padding: 24px 16px; background: radial-gradient(70% 55% at 50% 30%, rgba(80, 60, 140, 0.35), transparent 70%), rgba(2, 4, 12, 0.96); animation: eclIn 0.6s ease-out; }
.eclipse.out { opacity: 0; transition: opacity 0.3s; }
@keyframes eclIn { from { opacity: 0; } }
.ecl-in { width: min(560px, 100%); display: grid; justify-items: center; gap: 18px; text-align: center; }
.ecl-card { width: min(260px, 62vw); position: relative; }
.ecl-gone { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; max-width: 520px; }
.ecl-c { width: 52px; opacity: 1; animation: eclGone 1.3s ease-in forwards; animation-delay: calc(0.9s + var(--i) * 0.11s); }
@keyframes eclGone { 0% { opacity: 1; transform: none; filter: none; } 45% { opacity: 0.9; filter: grayscale(1) brightness(1.5); } 100% { opacity: 0; transform: translateY(-26px) scale(0.8); filter: grayscale(1) brightness(2); } }
.ecl-txt { opacity: 0; transform: translateY(8px); transition: opacity 0.6s, transform 0.6s; }
.eclipse.done .ecl-txt { opacity: 1; transform: none; }
.ecl-txt b { display: block; font-family: var(--f-display); font-weight: 800; font-size: 30px; color: #eef0ff; text-shadow: 0 0 18px rgba(195, 175, 255, 0.7); }
.ecl-txt .flav { font-style: italic; color: #cfd6f5; margin: 6px 0 10px; }
.ecl-txt p { margin: 0 0 8px; }
@media (prefers-reduced-motion: reduce) { .ecl-c { animation: none; opacity: 0.25; } }
.pion { text-align: center; }
.ecl-txt .opt-row { justify-content: center; }

/* 3.6 : nouvelle version prête (appli Android) */
.upd-bar { position: fixed; left: 50%; bottom: calc(86px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 80; display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 16px; border-radius: 999px; background: rgba(10, 20, 42, 0.96); border: 1px solid var(--mint); box-shadow: 0 8px 26px rgba(0, 0, 0, 0.5); white-space: nowrap; max-width: calc(100vw - 24px); }
.upd-bar span { font-weight: 600; overflow: hidden; text-overflow: ellipsis; }
.upd-bar .cta { padding: 8px 14px; }
.upd-bar .x { position: static; }
