/* Direction artistique du site, reprise des cartes : cadres japonais à double filet,
   coins en pixel art, vagues seigaiha, violet du dos Geemu et sceaux. */
:root {
  --bg: #090718; --panel: #120e2b; --line: #35296b; --muted: #a9a2cf; --accent: #7c5cff; --seal: #ff4d38;
  --titre: "Segoe UI Black", "Arial Black", system-ui, sans-serif;
}

/* ---------- Fond : halo violet et vagues ---------- */
html { background: var(--bg); }
body { background: transparent; }
body::before, body::after { content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none; }
body::before { background: radial-gradient(ellipse 75% 55% at 50% 0%, #2c1d73aa, transparent 70%), radial-gradient(ellipse 50% 40% at 100% 100%, #2a1566aa, transparent 70%); }
body::after { opacity: .07; background: url('/art/vagues.svg') 0 0 / 80px 40px;
  -webkit-mask-image: linear-gradient(#000, #0003 45%, #000); mask-image: linear-gradient(#000, #0003 45%, #000); }

/* ---------- Titres, comme le lettrage GEEMU ---------- */
h1, h2, h3, .logo, .stat b { font-family: var(--titre); font-style: italic; letter-spacing: .01em; }
main h1, main > h2, main section > h3 { text-transform: uppercase; text-shadow: 0 2px 0 #3b25a8, 0 0 18px #7c5cff66; }
main > h1, main > h2 { display: flex; align-items: center; gap: 12px; }
/* petit losange de pixels et filet de chaque côté des grands titres */
main > h1::before, main > h2::before { content: ''; flex: none; width: 12px; height: 12px; background: #fff; box-shadow: 0 0 0 3px var(--accent); transform: rotate(45deg); }
main > h1::after, main > h2::after { content: ''; flex: 1; height: 6px; border-top: 2px solid var(--accent); border-bottom: 1px solid #7c5cff66; -webkit-mask-image: linear-gradient(90deg, #000, transparent); mask-image: linear-gradient(90deg, #000, transparent); }
main section > h3 { font-size: 16px; scroll-margin-top: 90px; }
main section { scroll-margin-top: 80px; }
.album-more { display: block; margin: -8px auto 36px; min-width: 260px; }

/* ---------- Barre du haut et menu ---------- */
header { background: #0c0920f2; border-bottom: 2px solid var(--accent); box-shadow: 0 1px 0 #0c0920, 0 4px 0 #7c5cff55, 0 10px 30px #0008; }
.logo { text-transform: uppercase; font-size: 21px; text-shadow: 0 2px 0 #3b25a8; }
.seal { background: var(--seal); color: #fff; font-style: normal; text-shadow: none; box-shadow: inset 0 0 0 2px #17082055, 0 0 0 1px #ffffff55, 0 0 14px #ff4d3866; }
nav a { align-items: center; border: 1px solid transparent; border-radius: 4px; font-weight: 700; }
nav a i { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; border: 1px solid #7c5cff77; background: #1b1443; color: #cfc4ff; font-style: normal; font-weight: 900; font-size: 14px; }
nav a:hover { color: var(--text); }
nav a.on { background: #7c5cff22; border-color: var(--accent); color: #fff; }
nav a.on i { background: var(--seal); border-color: #ffffff77; color: #fff; }
.wallet > span { padding: 4px 10px; background: #1b1443; border: 1px solid var(--line); border-radius: 4px; }

/* ---------- Panneaux encadrés comme les cartes ---------- */
.hero, .pack, .stat, .auth, .modal {
  border: 26px solid transparent; border-radius: 0; box-shadow: 0 14px 30px #0006;
  border-image: url('/art/cadre.svg') 32 / 26px stretch;
  background: linear-gradient(165deg, #1d1650, #100c27 70%) padding-box;
}
/* le fond remplit aussi la zone du cadre, sauf les coins rentrés */
.hero, .pack, .auth, .modal { position: relative; isolation: isolate; background: none; }
.hero::before, .pack::before, .auth::before, .modal::before { content: ''; position: absolute; inset: -19px; z-index: -1; background: url('/art/vagues.svg') 0 0 / 40px 20px, linear-gradient(165deg, #1d1650, #100c27 70%); background-blend-mode: soft-light, normal; }

.hero { padding: 12px 16px; }
.hero::before { background: url('/art/vagues.svg') 0 0 / 48px 24px, radial-gradient(circle at 85% 30%, #6f4dff, transparent 55%), linear-gradient(165deg, #24196a, #100c27 75%); background-blend-mode: soft-light, normal, normal; }
/* grand signe japonais en filigrane, comme sur l'écran d'ouverture */
.hero::after { content: 'ゲ'; position: absolute; right: 3%; top: 50%; transform: translateY(-50%); font-size: min(190px, 30vw); font-weight: 900; line-height: 1; color: transparent; -webkit-text-stroke: 1.5px #b7a6ff55; pointer-events: none; }
.hero small { color: #cfc4ff; }
.hero h1 { text-transform: uppercase; text-shadow: 0 3px 0 #3b25a8; }
.hero .btn { background: #fff; color: #1d1440; }

.stats { gap: 8px; }
.stat { border-width: 18px; border-image-width: 18px; padding: 0 2px; }
.stat b { color: #fff; }

.pack { padding: 0; transition: transform .15s, filter .15s; }
.packs { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.pack .btn { padding: 9px 6px; font-size: 12px; white-space: nowrap; }
.pack:hover { transform: translateY(-4px); filter: drop-shadow(0 0 12px #7c5cff77); }
.pack h3 { text-transform: uppercase; }
.pack-art { filter: drop-shadow(0 8px 12px #0009); }

.auth { margin-top: 6vh; padding: 14px; }
.auth h1 { text-transform: uppercase; }

/* ---------- Boutons à coins en pixels ---------- */
.btn, .open-btn {
  border-radius: 0; text-transform: uppercase; letter-spacing: .03em; font-weight: 900;
  clip-path: polygon(8px 0, calc(100% - 8px) 0, calc(100% - 8px) 4px, calc(100% - 4px) 4px, calc(100% - 4px) 8px, 100% 8px,
    100% calc(100% - 8px), calc(100% - 4px) calc(100% - 8px), calc(100% - 4px) calc(100% - 4px), calc(100% - 8px) calc(100% - 4px), calc(100% - 8px) 100%,
    8px 100%, 8px calc(100% - 4px), 4px calc(100% - 4px), 4px calc(100% - 8px), 0 calc(100% - 8px),
    0 8px, 4px 8px, 4px 4px, 8px 4px);
}
.btn { font-size: 13px; background: linear-gradient(#8f72ff, #6442e8); box-shadow: inset 0 2px 0 #ffffff40, inset 0 -3px 0 #0000004d; }
.btn.big { font-size: 15px; }
.btn.alt { background: #1b1443; box-shadow: inset 0 0 0 2px #5a45b5; }
.btn:not(:disabled):hover { filter: brightness(1.18); }
.btn:focus-visible, .open-btn:focus-visible { outline: 2px solid #fff; outline-offset: -6px; }

/* ---------- Champs, progression, tableau ---------- */
input, select { border: 2px solid var(--line); border-radius: 4px; background: #0f0b24; }
input:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
progress { -webkit-appearance: none; appearance: none; height: 10px; border: 1px solid var(--accent); background: #0f0b24; }
progress::-webkit-progress-bar { background: #0f0b24; }
progress::-webkit-progress-value { background: repeating-linear-gradient(90deg, #8f72ff 0 8px, #5b3fd1 8px 10px); }
progress::-moz-progress-bar { background: #7c5cff; }

table { border-radius: 0; background: var(--panel); border: 2px solid var(--accent); box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px #7c5cff77; }
th { background: #241a5c; text-transform: uppercase; font-size: 12px; letter-spacing: .05em; }
.ad { padding: 8px; background: #120e2bcc; border: 1px solid var(--line); }
#toast { border-radius: 4px; border: 2px solid var(--accent); box-shadow: 0 8px 24px #0008; }

@media (max-width: 900px) {
  nav { background: #0f0b24; border-top: 2px solid var(--accent); }
  nav a { gap: 2px; }
  .wallet > span { padding: 3px 7px; }
}
@media (max-width: 520px) {
  .packs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .pack { border-width: 18px; border-image-width: 18px; }
  .pack::before { inset: -13px; }
  .pack .btn { padding: 8px 2px; font-size: 11px; white-space: normal; }
}
