/* maziar.net : accueil public et fenêtre de connexion (design « Néon » : noir bleuté, cyan électrique du logo). */
@font-face { font-family: "Orbitron"; src: url("/porte/fonts/Orbitron-var.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "Exo 2"; src: url("/porte/fonts/Exo2-var.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --fond: #02040a; --carte: #050b14; --ligne: rgba(46, 197, 255, .22); --texte: #e4f4ff; --doux: #7d97ab;
  --neon: #2ec5ff; --halo: rgba(46, 197, 255, .45); --rouge: #ff5d6c;
}
html, body { margin: 0; height: 100%; background: var(--fond); color: var(--texte); font: 16px/1.5 "Exo 2", system-ui, "Segoe UI", sans-serif; overflow: hidden; }
canvas#fond { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
main { position: relative; z-index: 1; height: 100%; display: grid; place-items: center; text-align: center; padding: 24px; box-sizing: border-box; }
.marque { display: flex; flex-direction: column; align-items: center; gap: 22px; }
.embleme { position: relative; display: block; width: clamp(150px, 26vw, 220px); max-width: 100%; aspect-ratio: 1; }
.embleme img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 50%; mix-blend-mode: screen;
  -webkit-mask-image: radial-gradient(circle, #000 58%, transparent 71%); mask-image: radial-gradient(circle, #000 58%, transparent 71%); }
.embleme::after { content: ""; position: absolute; inset: -14px; border-radius: 50%; border: 1px solid var(--ligne);
  box-shadow: 0 0 40px var(--halo), inset 0 0 30px rgba(46, 197, 255, .15); animation: pouls 4s ease-in-out infinite; pointer-events: none; }
@keyframes pouls { 50% { box-shadow: 0 0 70px var(--halo), inset 0 0 40px rgba(46, 197, 255, .25); } }
.devise { margin: 0; font-size: 13px; letter-spacing: .3em; text-transform: uppercase; color: var(--doux); padding-left: .3em; }
.devise b { color: var(--neon); font-weight: 600; }
/* entrée discrète : le logo ouvre la connexion, comme sur samiar.net */
#porte-bouton { all: unset; display: block; cursor: default; border-radius: 50%; -webkit-tap-highlight-color: transparent; }
#porte-bouton:focus-visible { box-shadow: 0 0 0 3px var(--halo); }
@media (prefers-reduced-motion: reduce) { .embleme::after { animation: none; } }

/* ---- fenêtre de connexion ---- */
dialog.porte {
  background: var(--carte); color: var(--texte); border: 1px solid var(--ligne); border-radius: 6px;
  width: min(92vw, 390px); padding: 28px 26px 22px; margin: auto; box-sizing: border-box;
  box-shadow: 0 0 50px rgba(46, 197, 255, .18), 0 30px 90px rgba(0, 0, 0, .7);
  font: 16px/1.45 "Exo 2", system-ui, sans-serif;
}
dialog.porte::backdrop { background: rgba(0, 3, 8, .72); backdrop-filter: blur(5px); }
dialog.porte .tete { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
dialog.porte .tete img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; mix-blend-mode: screen; flex: none; }
dialog.porte h2 { margin: 0; font-family: "Orbitron", sans-serif; font-size: 17px; font-weight: 700; letter-spacing: .14em; color: #fff; }
dialog.porte p.sous { margin: 2px 0 0; color: var(--doux); font-size: 14px; }
dialog.porte label { display: block; font-size: 13px; color: #9fb6c8; margin: 12px 0 5px; letter-spacing: .03em; }
dialog.porte input {
  width: 100%; box-sizing: border-box; background: #02060c; color: #fff; border: 1px solid var(--ligne); border-radius: 4px;
  padding: 11px 12px; font: inherit; outline: none;
}
dialog.porte input:focus { border-color: var(--neon); box-shadow: 0 0 0 3px rgba(46, 197, 255, .2); }
dialog.porte input.code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; letter-spacing: .18em; font-size: 20px; text-align: center; }
dialog.porte input.code-long { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; letter-spacing: .08em; font-size: 16px; text-align: center; }
dialog.porte button.valider {
  width: 100%; margin-top: 18px; padding: 12px; border: 0; border-radius: 4px; cursor: pointer;
  font: 700 13px/1 "Orbitron", sans-serif; letter-spacing: .22em; color: #001520; background: var(--neon); box-shadow: 0 0 24px var(--halo);
}
dialog.porte button.valider:disabled { opacity: .6; cursor: progress; }
dialog.porte .aide { color: var(--doux); font-size: 13px; margin: 10px 0 0; }
dialog.porte .erreur { color: #ff8a95; font-size: 14px; min-height: 1.3em; margin: 10px 0 0; text-align: center; }
dialog.porte .liens { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; font-size: 13px; flex-wrap: wrap; }
dialog.porte .liens button { background: none; border: 0; padding: 0; color: var(--doux); cursor: pointer; font: inherit; font-size: 13px; text-decoration: underline; text-underline-offset: 3px; }
dialog.porte .liens button:hover { color: var(--neon); }
dialog.porte form[hidden] { display: none; }
