/* Les thèmes complets de l'espace d'un serveur : polices, fonds, formes des cartes et des boutons, ornements.
   Chargé après espace.css ; le thème vient de data-style sur <body>. La formule VIP ajoute par-dessus
   une palette tirée de l'icône du serveur (variables --accent… posées sur <body>). */
body.espace { --titres:'Plus Jakarta Sans', system-ui, sans-serif; --texte-police:'Plus Jakarta Sans', system-ui, sans-serif; font-family:var(--texte-police); }
body.espace h1, body.espace h2, body.espace h3, .espace .e-marque, .espace .surtitre, .espace .e-tuile strong, .espace .e-chiffre strong, .espace .lp-infos h2 { font-family:var(--titres); }

/* ----- Médiéval : cuir sombre, or, parchemin, enluminures ----- */
body.espace[data-style=medieval] { --titres:'Cinzel', 'Cormorant Garamond', serif; --texte-police:'Cormorant Garamond', Georgia, serif; --texte:#f1e6cf; --texte-2:#d8c8a6; --texte-3:#a8987a;
  --trait:#d9b27333; --trait-2:#d9b27366; --rayon:6px; font-size:18px;
  background:radial-gradient(ellipse at 50% -10%, #3a2b17 0%, transparent 55%), radial-gradient(ellipse at 50% 120%, #1f160c 0%, transparent 60%),
    repeating-linear-gradient(45deg, #ffffff03 0 2px, transparent 2px 6px), #120e09; }
.espace[data-style=medieval] .carte, .espace[data-style=medieval] .lp-scene { background:linear-gradient(180deg, #2a2117, #1d1710); border:1px solid #d9b27355;
  box-shadow:inset 0 0 0 4px #120e09, inset 0 0 0 5px #d9b27333, 0 18px 40px -24px #000; }
.espace[data-style=medieval] h1 { letter-spacing:.04em; font-weight:700; text-shadow:0 2px 0 #000, 0 0 24px #d9b27333; }
.espace[data-style=medieval] .surtitre { letter-spacing:.22em; } .espace[data-style=medieval] .surtitre::before, .espace[data-style=medieval] .surtitre::after { content:' ❧ '; color:var(--accent-2); }
.espace[data-style=medieval] .d-bouton { border-radius:4px; background:linear-gradient(180deg, #e9c98a, #b8894a 55%, #8f6a37); color:#1d1408; border:1px solid #5c4322;
  box-shadow:inset 0 1px 0 #fff6, 0 6px 16px -8px #000; font-family:var(--titres); letter-spacing:.06em; text-transform:uppercase; font-size:14px; }
.espace[data-style=medieval] .e-entete { background:linear-gradient(180deg, #1d160ef0, #150f0ae6); border-bottom:1px solid #d9b27355; box-shadow:0 1px 0 #000, 0 2px 0 #d9b27322; }
.espace[data-style=medieval] .e-nav a { font-family:var(--titres); letter-spacing:.06em; font-size:14px; }
.espace[data-style=medieval] .e-tuile-icone { border-radius:50%; background:radial-gradient(circle, #d9b27340, #d9b27310); border:1px solid #d9b27366; }
.espace[data-style=medieval] .e-icone.grande { border-radius:50%; box-shadow:0 0 0 3px #120e09, 0 0 0 5px #d9b273, 0 24px 50px -20px #000; }
.espace[data-style=medieval] .e-heros { border-bottom:1px solid #d9b27333; } .espace[data-style=medieval] .e-heros h1::after { content:''; display:block; width:120px; height:2px; margin-top:14px; background:linear-gradient(90deg, var(--accent), transparent); }
.espace[data-style=medieval] .e-puce, .espace[data-style=medieval] .lp-puce, .espace[data-style=medieval] .onglet { border-radius:3px; }
.espace[data-style=medieval] .lp-rond { border-radius:50%; border-color:#d9b27366; } .espace[data-style=medieval] .lp-pochette { border-radius:4px; box-shadow:0 0 0 4px #120e09, 0 0 0 6px #d9b27399, 0 30px 60px -30px #000; }

/* ----- Futuriste : verre sombre, grille, angles coupés, lumière cyan ----- */
body.espace[data-style=futuriste] { --titres:'Orbitron', 'Exo 2', sans-serif; --texte-police:'Exo 2', system-ui, sans-serif; --texte:#e6f4ff; --texte-2:#a9c4dd; --texte-3:#7390ab; --trait:#4fd1ff22; --trait-2:#4fd1ff55; --rayon:2px;
  background:linear-gradient(#4fd1ff0a 1px, transparent 1px) 0 0 / 40px 40px, linear-gradient(90deg, #4fd1ff0a 1px, transparent 1px) 0 0 / 40px 40px,
    radial-gradient(ellipse at 80% -20%, #1b3f6e 0%, transparent 55%), #070b14; }
.espace[data-style=futuriste] .carte, .espace[data-style=futuriste] .lp-scene { background:linear-gradient(160deg, #0f1a2ccc, #0a1220e6); border:1px solid #4fd1ff44; backdrop-filter:blur(6px);
  clip-path:polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 18px 100%, 0 calc(100% - 18px)); }
.espace[data-style=futuriste] h1, .espace[data-style=futuriste] h2 { text-transform:uppercase; letter-spacing:.08em; } .espace[data-style=futuriste] h1 { text-shadow:0 0 18px #4fd1ff66; }
.espace[data-style=futuriste] .d-bouton { border-radius:0; clip-path:polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%); background:linear-gradient(90deg, #4fd1ff, #2a8cff); color:#03101c;
  text-transform:uppercase; letter-spacing:.1em; font-family:var(--titres); font-size:13px; box-shadow:0 0 18px #4fd1ff66; }
.espace[data-style=futuriste] .e-tuile-icone, .espace[data-style=futuriste] .lp-rond { border-radius:2px; } .espace[data-style=futuriste] .e-icone.grande { border-radius:4px; box-shadow:0 0 0 1px #4fd1ff, 0 0 26px #4fd1ff55; }
.espace[data-style=futuriste] .e-nav a { text-transform:uppercase; letter-spacing:.12em; font-size:12px; font-family:var(--titres); }
.espace[data-style=futuriste] .surtitre { font-family:var(--titres); letter-spacing:.3em; } .espace[data-style=futuriste] .surtitre::before { content:'// '; }

/* ----- Minimaliste : clair, net, beaucoup d'air ----- */
body.espace[data-style=minimaliste] { --titres:'Inter', system-ui, sans-serif; --texte-police:'Inter', system-ui, sans-serif; --fond:#f6f6f4; --surface:#ffffff; --carte:#ffffff; --carte-2:#f0f0ed;
  --texte:#16171a; --texte-2:#4a4d55; --texte-3:#7b7f88; --trait:#16171a14; --trait-2:#16171a26; --accent:#16171a; --accent-2:#3a3c42; --halo:#16171a0d; --encre:#ffffff; --rayon:14px; background:#f6f6f4; }
.espace[data-style=minimaliste] .carte, .espace[data-style=minimaliste] .lp-scene { box-shadow:0 1px 2px #0000000a, 0 8px 24px -16px #00000026; }
.espace[data-style=minimaliste] .d-bouton { background:#16171a; color:#fff; box-shadow:none; border-radius:999px; } .espace[data-style=minimaliste] .d-bouton.secondaire { background:#fff; color:#16171a; border:1px solid #16171a26; }
.espace[data-style=minimaliste] .e-entete { background:#f6f6f4e6; } .espace[data-style=minimaliste] h1 { letter-spacing:-.04em; font-weight:800; }
.espace[data-style=minimaliste] .lp-barre { background:#16171a14; } .espace[data-style=minimaliste] .lp-rond.grand { color:#fff; }
.espace[data-style=minimaliste] .lp-scene::before { opacity:.18; filter:blur(50px) saturate(1.2); }
.espace[data-style=minimaliste] .champ { background:#fff; color:#16171a; } .espace[data-style=minimaliste] .alerte { color:#a3271c; }

/* ----- Nature : mousse, bois, formes douces ----- */
body.espace[data-style=nature] { --titres:'Fraunces', Georgia, serif; --texte-police:'Nunito', system-ui, sans-serif; --texte:#eef5e9; --texte-2:#bcd1b6; --texte-3:#8da688; --trait:#86cf8a22; --trait-2:#86cf8a55; --rayon:26px;
  background:radial-gradient(ellipse at 15% 0%, #2c4a2d 0%, transparent 50%), radial-gradient(ellipse at 90% 100%, #3a2f1c 0%, transparent 55%), #0c130d; }
.espace[data-style=nature] .carte, .espace[data-style=nature] .lp-scene { background:linear-gradient(170deg, #1a2a1d, #121c14); border:1px solid #86cf8a33; }
.espace[data-style=nature] .d-bouton { border-radius:999px; background:linear-gradient(180deg, #9ad99c, #5aa95f); color:#08140a; }
.espace[data-style=nature] .e-tuile-icone, .espace[data-style=nature] .e-icone.grande { border-radius:40% 60% 55% 45% / 50% 45% 55% 50%; }
.espace[data-style=nature] h1 { font-weight:800; letter-spacing:-.02em; } .espace[data-style=nature] .surtitre::before { content:'🌿 '; }

/* ----- Néon : nuit, lueurs magenta et cyan ----- */
body.espace[data-style=neon] { --titres:'Audiowide', system-ui, sans-serif; --texte-police:'Rajdhani', system-ui, sans-serif; --texte:#fff0fc; --texte-2:#e0b8dc; --texte-3:#a986a6; --trait:#ff5ddc2a; --trait-2:#ff5ddc66; --rayon:14px; font-size:17px;
  background:radial-gradient(ellipse at 20% -10%, #5a1460 0%, transparent 50%), radial-gradient(ellipse at 100% 100%, #0d3a5c 0%, transparent 55%), #08040d; }
.espace[data-style=neon] .carte, .espace[data-style=neon] .lp-scene { background:#140a1dcc; border:1px solid #ff5ddc55; box-shadow:0 0 0 1px #ff5ddc22, 0 0 30px -10px #ff5ddc88, inset 0 0 30px -18px #4fd1ff; }
.espace[data-style=neon] h1 { color:#fff; text-shadow:0 0 6px #fff, 0 0 18px #ff5ddc, 0 0 38px #ff5ddc; letter-spacing:.02em; }
.espace[data-style=neon] .surtitre { color:#4fd1ff; text-shadow:0 0 10px #4fd1ff; }
.espace[data-style=neon] .d-bouton { background:transparent; color:#fff; border:2px solid #ff5ddc; box-shadow:0 0 12px #ff5ddc, inset 0 0 12px #ff5ddc66; text-shadow:0 0 8px #ff5ddc; font-family:var(--titres); }
.espace[data-style=neon] .e-tuile:hover { box-shadow:0 0 24px -4px #ff5ddc; } .espace[data-style=neon] .e-icone.grande { box-shadow:0 0 0 2px #ff5ddc, 0 0 30px #ff5ddc; }

/* ----- Rétro pixel : bords en escalier, police de borne d'arcade ----- */
body.espace[data-style=pixel] { --titres:'Press Start 2P', monospace; --texte-police:'VT323', monospace; --texte:#fff8e6; --texte-2:#e2d3a8; --texte-3:#b3a47c; --trait:#ffcc4d33; --trait-2:#ffcc4d77; --rayon:0px; font-size:21px; line-height:1.35;
  background:repeating-linear-gradient(0deg, #00000022 0 2px, transparent 2px 4px), #14111d; image-rendering:pixelated; }
.espace[data-style=pixel] .carte, .espace[data-style=pixel] .lp-scene { background:#1e1a2a; border:0; border-radius:0;
  box-shadow:0 -4px 0 0 #ffcc4d, 0 4px 0 0 #ffcc4d, -4px 0 0 0 #ffcc4d, 4px 0 0 0 #ffcc4d, 8px 8px 0 0 #000; margin:4px; }
.espace[data-style=pixel] h1 { font-size:clamp(22px, 4vw, 40px); line-height:1.4; } .espace[data-style=pixel] h2 { font-size:15px; line-height:1.5; }
.espace[data-style=pixel] .e-tuile strong, .espace[data-style=pixel] .e-chiffre strong { font-size:13px; line-height:1.6; } .espace[data-style=pixel] .e-nav a { font-size:18px; }
.espace[data-style=pixel] .d-bouton { border-radius:0; background:#ffcc4d; color:#1c1404; box-shadow:4px 4px 0 #000; font-family:var(--titres); font-size:11px; }
.espace[data-style=pixel] .d-bouton:active { transform:translate(2px, 2px); box-shadow:2px 2px 0 #000; }
.espace[data-style=pixel] .e-tuile-icone, .espace[data-style=pixel] .e-icone, .espace[data-style=pixel] .lp-rond, .espace[data-style=pixel] .lp-pochette, .espace[data-style=pixel] .lp-mini, .espace[data-style=pixel] .e-puce, .espace[data-style=pixel] .lp-puce, .espace[data-style=pixel] .onglet { border-radius:0 !important; }

/* ----- Personnalisation (VIP) : la devise écrite pour le serveur ----- */
.e-devise { font-family:var(--titres); color:var(--accent); font-size:clamp(15px, 1.8vw, 19px); margin:-6px 0 14px; letter-spacing:.02em; }
@media (prefers-reduced-motion: reduce) { .espace[data-style=pixel] .d-bouton:active { transform:none; } }
