:root {
    --night: #07090f;
    --panel: #111722;
    --panel2: #18202e;
    --edge: #232f42;
    --accent: #66c0f4;
    --accent2: #a78bfa;
    --accent3: #f472b6;
}

* {
    scroll-behavior: smooth;
}

body {
    background-color: var(--night);
    color: #e6e9f0;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;
    background:
        radial-gradient(60% 50% at 15% 0%, rgba(102, 192, 244, 0.16), transparent 60%),
        radial-gradient(55% 45% at 90% 10%, rgba(167, 139, 250, 0.16), transparent 60%),
        radial-gradient(50% 60% at 60% 100%, rgba(244, 114, 182, 0.12), transparent 60%),
        linear-gradient(180deg, #090c14 0%, #07090f 100%);
}

body::after {
    content: "";
    position: fixed;
    inset: -50%;
    z-index: -1;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(ellipse 60% 50% at 50% 0%, #000 30%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 60% 50% at 50% 0%, #000 30%, transparent 75%);
}

::selection {
    background: rgba(102, 192, 244, 0.3);
    color: #fff;
}

::-webkit-scrollbar {
    width: 12px;
}
::-webkit-scrollbar-track {
    background: var(--night);
}
::-webkit-scrollbar-thumb {
    background: linear-gradient(var(--accent), var(--accent2));
    border-radius: 6px;
    border: 3px solid var(--night);
}
::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(var(--accent2), var(--accent3));
}

@keyframes flotter {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(0, -26px); }
}

@keyframes deplacerGradient {
    to { background-position: 300% center; }
}

@keyframes pulseLueur {
    0%, 100% { opacity: 0.5; transform: scale(1); }
    50% { opacity: 0.85; transform: scale(1.08); }
}

@keyframes brillance {
    100% { transform: translateX(260%) skewX(-18deg); }
}

@keyframes apparition {
    from { opacity: 0; transform: translateY(28px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes rotationLente {
    to { transform: rotate(360deg); }
}

.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.2, 0.7, 0.2, 1), transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
    will-change: opacity, transform;
}
.reveal.visible {
    opacity: 1;
    transform: none;
}

.texte-gradient {
    background: linear-gradient(90deg, #66c0f4, #a78bfa, #f472b6, #66c0f4);
    background-size: 300% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: deplacerGradient 7s linear infinite;
}

.orbe {
    position: absolute;
    border-radius: 9999px;
    filter: blur(70px);
    opacity: 0.55;
    pointer-events: none;
    animation: flotter 9s ease-in-out infinite, pulseLueur 7s ease-in-out infinite;
}

.btn-gc {
    position: relative;
    overflow: hidden;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ec4899);
    background-size: 200% auto;
    color: #fff;
    font-weight: 700;
    border: none;
    transition: background-position 0.5s ease, transform 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 10px 26px -10px rgba(124, 92, 246, 0.8);
}
.btn-gc:hover {
    background-position: right center;
    transform: translateY(-2px);
    box-shadow: 0 16px 34px -10px rgba(236, 72, 153, 0.7);
    color: #fff;
}
.btn-gc::after {
    content: "";
    position: absolute;
    top: 0;
    left: -60%;
    width: 45%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.45), transparent);
    transform: skewX(-18deg);
}
.btn-gc:hover::after {
    animation: brillance 0.8s forwards;
}

.lien-nav {
    position: relative;
}
.lien-nav::after {
    content: "";
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 6px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--accent), var(--accent2));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}
.lien-nav:hover::after {
    transform: scaleX(1);
}

.carte-jeu {
    transition: transform 0.35s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.35s ease, border-color 0.35s ease;
}
.carte-jeu:hover {
    transform: translateY(-8px);
    border-color: rgba(102, 192, 244, 0.6);
    box-shadow: 0 22px 50px -18px rgba(102, 192, 244, 0.45);
}

.jaquette {
    transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.carte-jeu:hover .jaquette {
    transform: scale(1.12);
}
.jaquette::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.16) 1px, transparent 1px);
    background-size: 13px 13px;
    opacity: 0.5;
}

.jaquette-0 { background: linear-gradient(135deg, #4f46e5, #06b6d4); }
.jaquette-1 { background: linear-gradient(135deg, #7c3aed, #db2777); }
.jaquette-2 { background: linear-gradient(135deg, #0ea5e9, #2dd4bf); }
.jaquette-3 { background: linear-gradient(135deg, #f43f5e, #8b5cf6); }
.jaquette-4 { background: linear-gradient(135deg, #2563eb, #7c3aed); }

.balayage {
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.25), transparent);
    transform: skewX(-18deg);
    pointer-events: none;
    z-index: 5;
}
.carte-jeu:hover .balayage {
    animation: brillance 0.85s forwards;
}

.verre {
    background: rgba(17, 23, 34, 0.72);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.bord-anime {
    position: relative;
}
.bord-anime::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(130deg, rgba(102, 192, 244, 0.5), transparent 40%, transparent 60%, rgba(167, 139, 250, 0.5));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.tuile-icone {
    transition: transform 0.3s ease;
}
.tuile-admin:hover .tuile-icone {
    transform: translateY(-4px) rotate(-6deg) scale(1.08);
}

.verre-hero {
    background: rgba(10, 14, 22, 0.42);
    backdrop-filter: blur(18px) saturate(125%);
    -webkit-backdrop-filter: blur(18px) saturate(125%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 30px 60px -25px rgba(0, 0, 0, 0.6);
}

.diapo-hero {
    opacity: 0;
    transform: scale(1.1);
    transition: opacity 1.5s ease-in-out, transform 7s ease-out;
    pointer-events: none;
}
.diapo-hero.actif {
    opacity: 1;
    transform: scale(1);
}

.champ {
    background: rgba(7, 9, 15, 0.6);
    border: 1px solid var(--edge);
    color: #e6e9f0;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.champ:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(102, 192, 244, 0.15);
    background: rgba(7, 9, 15, 0.85);
}
