/* --- DEFINIZIONE ANIMAZIONI --- */

/* 1. Il lento movimento dello sfondo */
@keyframes cosmic-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 2. Il respiro dorato del box centrale */
@keyframes arcane-pulse {
    0% {
        box-shadow: 0 10px 30px rgba(0,0,0,0.5), inset 0 0 20px rgba(212, 175, 55, 0.05);
        border-color: rgba(212, 175, 55, 0.3);
    }
    50% {
        box-shadow: 0 15px 50px rgba(212, 175, 55, 0.15), inset 0 0 40px rgba(212, 175, 55, 0.1);
        border-color: rgba(212, 175, 55, 0.6);
    }
    100% {
        box-shadow: 0 10px 30px rgba(0,0,0,0.5), inset 0 0 20px rgba(212, 175, 55, 0.05);
        border-color: rgba(212, 175, 55, 0.3);
    }
}

/* 3. Aura dietro il logo */
@keyframes logo-aura-pulse {
    from { opacity: 0.5; transform: translate(-50%, -50%) scale(0.9); }
    to { opacity: 0.8; transform: translate(-50%, -50%) scale(1.1); }
}


/* --- STILI GENERALI --- */

body {
    background: #0a0a0c !important;
    /* Gradiente più complesso e grande per l'animazione */
    background-image: 
        radial-gradient(circle at top left, rgba(212, 175, 55, 0.1), transparent 50%),
        radial-gradient(circle at bottom right, rgba(80, 50, 150, 0.15), transparent 50%),
        linear-gradient(135deg, #0f0f1a 0%, #1a1a2e 50%, #050505 100%) !important;
    background-size: 300% 300% !important; /* Ingrandiamo lo sfondo per poterlo muovere */
    animation: cosmic-shift 25s ease infinite !important; /* Movimento lentissimo */
    color: #f0f0f0 !important;
    font-family: 'Georgia', serif !important;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow: hidden; /* Necessario per l'effetto 3D del JS */
}

/* Il contenitore centrale che "respira" */
.container.wrap {
    background: rgba(20, 20, 30, 0.6) !important;
    border: 1px solid rgba(212, 175, 55, 0.3) !important;
    border-radius: 20px !important;
    padding: 50px 40px !important;
    backdrop-filter: blur(15px);
    max-width: 480px !important;
    margin: auto !important; /* Centratura verticale e orizzontale */
    text-align: center;
    position: relative;
    z-index: 10;
    /* Applichiamo l'animazione del respiro */
    animation: arcane-pulse 5s ease-in-out infinite !important;
    /* Preparazione per effetto 3D JS */
    transform-style: preserve-3d;
    perspective: 1000px;
}

/* Logo con Aura */
.header .logo {
    position: relative;
    display: inline-block;
}

/* Creiamo un bagliore dietro il logo */
.header .logo::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.3) 0%, transparent 70%);
    filter: blur(20px);
    z-index: -1;
    animation: logo-aura-pulse 3s ease-in-out infinite alternate;
}

.header .logo img {
    max-width: 220px !important;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.3));
    margin-bottom: 30px;
}

/* Pulsante "Accedere" */
.button {
    background: linear-gradient(135deg, #b8860b 0%, #f1d279 50%, #b8860b 100%) !important;
    background-size: 200% auto !important;
    color: #1a1a1a !important;
    text-transform: uppercase !important;
    font-weight: 800 !important;
    letter-spacing: 3px !important;
    border: none !important;
    padding: 18px 40px !important;
    border-radius: 50px !important; /* Arrotondato */
    box-shadow: 0 10px 25px rgba(0,0,0,0.4) !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important; /* Rimbalzo elastico */
    display: inline-block;
    text-decoration: none;
}

.button:hover {
    transform: translateY(-5px) scale(1.05) !important;
    box-shadow: 0 15px 35px rgba(212, 175, 55, 0.4) !important;
    background-position: right center !important; /* Sposta il gradiente al passaggio */
    color: #000 !important;
}

/* Link secondari */
.home-options {
    margin-top: 40px !important;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    padding-top: 25px;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.home-options a {
    color: #d4af37 !important;
    text-decoration: none !important;
    font-size: 0.85em;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.7;
    transition: 0.3s;
    position: relative;
}

/* Piccola linea che appare sotto i link al passaggio */
.home-options a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -5px;
    left: 0;
    background-color: #d4af37;
    transition: width 0.3s;
}

.home-options a:hover {
    opacity: 1;
    text-shadow: 0 0 8px rgba(212, 175, 55, 0.6);
}

.home-options a:hover::after {
    width: 100%;
}

/* Footer */
footer.container {
    color: #666 !important;
    font-size: 0.75em;
    margin-top: auto;
    padding: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}