/* Login Page - Light Mode (Default) */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--background);
    position: relative;
    overflow: hidden;
}

/* Hide particles in light mode */
.login-page::before,
.login-page::after {
    display: none;
}

/* Floating stickers - hidden in light mode */
.login-page .sticker {
    display: none;
    position: absolute;
    pointer-events: none;
    z-index: 1;
}

/* Planet - top left, gentle float */
.login-page .sticker-planet {
    width: 180px;
    top: -20px;
    left: -30px;
    animation: floatGently 8s ease-in-out infinite;
    opacity: 0.9;
}

/* Moon - bottom right */
.login-page .sticker-moon {
    width: 100px;
    bottom: 40px;
    right: 30px;
    animation: floatGently 10s ease-in-out infinite;
    animation-delay: -3s;
    opacity: 0.85;
}

/* Rocket - flying across top right */
.login-page .sticker-rocket {
    width: 90px;
    top: 15%;
    right: 8%;
    animation: rocketFly 12s ease-in-out infinite;
    opacity: 0.9;
}

/* Stars - twinkling scattered */
.login-page .sticker-star-1 {
    width: 45px;
    top: 25%;
    left: 12%;
    animation: twinkle 3s ease-in-out infinite;
}

.login-page .sticker-star-2 {
    width: 35px;
    top: 60%;
    right: 15%;
    animation: twinkle 4s ease-in-out infinite;
    animation-delay: -1s;
}

.login-page .sticker-star-3 {
    width: 28px;
    bottom: 25%;
    left: 25%;
    animation: twinkle 3.5s ease-in-out infinite;
    animation-delay: -2s;
}

/* UFO - hovering left side */
.login-page .sticker-ufo {
    width: 85px;
    top: 50%;
    left: 5%;
    animation: ufoHover 6s ease-in-out infinite;
    opacity: 0.85;
}

/* Astronaut waving - bottom left */
.login-page .sticker-astronaut {
    width: 95px;
    bottom: 8%;
    left: 8%;
    animation: astronautWave 5s ease-in-out infinite;
    opacity: 0.9;
}

/* Animations */
@keyframes floatGently {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-15px) rotate(3deg);
    }
}

@keyframes rocketFly {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(-20px, -15px) rotate(-5deg);
    }
    50% {
        transform: translate(-10px, 10px) rotate(3deg);
    }
    75% {
        transform: translate(15px, -5px) rotate(-2deg);
    }
}

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

@keyframes ufoHover {
    0%, 100% {
        transform: translateY(0) translateX(0);
    }
    25% {
        transform: translateY(-10px) translateX(8px);
    }
    50% {
        transform: translateY(5px) translateX(-5px);
    }
    75% {
        transform: translateY(-8px) translateX(-10px);
    }
}

@keyframes astronautWave {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    25% {
        transform: translateY(-5px) rotate(2deg);
    }
    75% {
        transform: translateY(-3px) rotate(-2deg);
    }
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 16px;
    padding: 48px;
    width: 100%;
    max-width: 400px;
    text-align: center;
    position: relative;
    z-index: 10;
    box-shadow: 0 0 60px rgba(237, 96, 51, 0.15), 0 0 120px rgba(93, 198, 173, 0.1),
        0 8px 32px rgba(0, 0, 0, 0.2);
}

.login-theme-toggle {
    position: absolute;
    top: 24px;
    right: 24px;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--background-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.login-theme-toggle:hover {
    border-color: var(--color-brand-primary);
    color: var(--color-brand-primary);
}

.login-theme-toggle i {
    font-size: 18px;
}

.login-theme-toggle .ph-moon {
    display: block;
}

.login-theme-toggle .ph-sun {
    display: none;
}

:root.dark .login-theme-toggle .ph-moon {
    display: none;
}

:root.dark .login-theme-toggle .ph-sun {
    display: block;
}


.login-logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-brand-primary);
    margin-bottom: 32px;
    text-shadow: 0 0 20px rgba(237, 96, 51, 0.4);
    letter-spacing: 0.5px;
}

.login-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 14px 24px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--background-secondary);
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-google:hover {
    background: var(--color-brand-teal-light);
    border-color: var(--color-brand-teal);
    box-shadow: 0 0 25px rgba(93, 198, 173, 0.4);
    text-decoration: none;
}

.btn-google i {
    font-size: 20px;
}

.login-footer {
    margin-top: 32px;
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.login-footer-logo {
    height: 24px;
    width: auto;
    opacity: 0.6;
}

.login-error {
    background-color: var(--color-danger-light);
    border: 1px solid rgba(220, 38, 38, 0.2);
    color: var(--color-danger);
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 24px;
}

.login-disabled-notice {
    background-color: var(--background);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 24px;
    text-align: center;
}

.login-disabled-notice i {
    font-size: 32px;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.login-disabled-notice p {
    margin: 0;
    font-size: 14px;
    color: var(--text-primary);
}

.login-disabled-subtext {
    margin-top: 8px !important;
    font-size: 13px !important;
    color: var(--text-secondary) !important;
}

/* =============================================================================
   DARK MODE - Activated via :root.dark class (set by theme.js)
   ============================================================================= */

:root.dark .login-page {
    background: linear-gradient(135deg, #0f1012 0%, #141518 50%, #0f1012 100%);
}

/* Show starry particles in dark mode */
:root.dark .login-page::before {
    display: block;
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(
            2.5px 2.5px at 20px 30px,
            var(--color-brand-primary) 1px,
            transparent 1px
        ),
        radial-gradient(
            2.5px 2.5px at 40px 70px,
            var(--color-brand-teal) 1px,
            transparent 1px
        ),
        radial-gradient(
            2px 2px at 50px 160px,
            var(--color-brand-blue) 1px,
            transparent 1px
        ),
        radial-gradient(
            2.5px 2.5px at 90px 40px,
            var(--color-brand-primary) 1px,
            transparent 1px
        ),
        radial-gradient(
            2px 2px at 130px 80px,
            var(--color-brand-teal) 1px,
            transparent 1px
        ),
        radial-gradient(
            2.5px 2.5px at 160px 120px,
            var(--color-brand-blue) 1px,
            transparent 1px
        );
    background-size: 200px 200px;
    animation: particleFloat 20s linear infinite;
    opacity: 0.7;
}

:root.dark .login-page::after {
    display: block;
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(
            1.5px 1.5px at 25px 45px,
            var(--color-brand-teal) 1px,
            transparent 1px
        ),
        radial-gradient(
            2px 2px at 75px 95px,
            var(--color-brand-primary) 1px,
            transparent 1px
        ),
        radial-gradient(
            1.5px 1.5px at 125px 25px,
            var(--color-brand-blue) 1px,
            transparent 1px
        ),
        radial-gradient(
            2px 2px at 175px 145px,
            var(--color-brand-teal) 1px,
            transparent 1px
        );
    background-size: 250px 200px;
    animation: particleFloat 30s linear infinite reverse;
    opacity: 0.5;
}

@keyframes particleFloat {
    0% {
        transform: translateY(0) translateX(0);
    }
    50% {
        transform: translateY(-50px) translateX(25px);
    }
    100% {
        transform: translateY(0) translateX(0);
    }
}

:root.dark .login-page .sticker {
    display: block;
    opacity: 0.75;
    filter: brightness(0.9);
}

:root.dark .login-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 40px rgba(237, 96, 51, 0.08), 0 0 80px rgba(93, 198, 173, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

:root.dark .login-logo {
    text-shadow: 0 0 30px rgba(237, 96, 51, 0.5), 0 0 60px rgba(237, 96, 51, 0.3);
}

:root.dark .login-subtitle {
    color: rgba(255, 255, 255, 0.5);
}

:root.dark .btn-google {
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.9);
}

:root.dark .btn-google:hover {
    background: rgba(93, 198, 173, 0.15);
    border-color: var(--color-brand-teal);
    box-shadow: 0 0 20px rgba(93, 198, 173, 0.2);
    color: white;
}

:root.dark .login-footer {
    color: rgba(255, 255, 255, 0.35);
}

:root.dark .login-error {
    background-color: rgba(220, 38, 38, 0.15);
    border: 1px solid rgba(220, 38, 38, 0.3);
    color: #fca5a5;
}

:root.dark .login-disabled-notice {
    background-color: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

:root.dark .login-disabled-notice i {
    color: rgba(255, 255, 255, 0.5);
}

:root.dark .login-disabled-notice p {
    color: rgba(255, 255, 255, 0.9);
}

:root.dark .login-disabled-subtext {
    color: rgba(255, 255, 255, 0.5) !important;
}
