* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg-dark: #0a0a0a;
    --bg-darker: #050505;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --accent-primary: #0ea5e9;
    --accent-secondary: #06b6d4;
    --accent-tertiary: #22c55e;
    --border-color: #1a1a1a;
}

html, body {
    height: 100%;
    background: var(--bg-dark);
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    overflow-x: hidden;
}

/* Animated Background */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(14, 165, 233, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(6, 182, 212, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.background-animation::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        repeating-linear-gradient(
            0deg,
            rgba(14, 165, 233, 0.03) 0px,
            rgba(14, 165, 233, 0.03) 1px,
            transparent 1px,
            transparent 80px
        );
    animation: gridScroll 20s linear infinite;
}

@keyframes gridScroll {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(80px);
    }
}

.container {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

/* Header */
.header {
    position: absolute;
    top: 40px;
    left: 40px;
    animation: slideInLeft 0.8s ease-out;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo {
    width: 48px;
    height: 48px;
    filter: drop-shadow(0 0 8px rgba(14, 165, 233, 0.3));
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-8px);
    }
}

.brand-name {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 1px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Hero Section */
.hero {
    text-align: center;
    margin-bottom: 60px;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
}

.hero-title {
    font-size: 56px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1px;
    line-height: 1.2;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 50%, var(--text-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 20px;
    font-weight: 500;
    color: var(--accent-primary);
    margin-bottom: 12px;
    letter-spacing: 0.5px;
}

.hero-description {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 8px;
}

/* Authentication Box */
.auth-container {
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.auth-box {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.8) 0%, rgba(15, 23, 42, 0.5) 100%);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 40px;
    max-width: 400px;
    width: 100%;
    backdrop-filter: blur(10px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.auth-box:hover {
    border-color: rgba(14, 165, 233, 0.3);
    box-shadow: 0 20px 80px rgba(14, 165, 233, 0.1);
}

.auth-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 24px;
    text-align: center;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    position: relative;
}

.input-field {
    width: 100%;
    padding: 14px 16px;
    background: rgba(10, 10, 10, 0.8);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.input-field:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 20px rgba(14, 165, 233, 0.2);
    background: rgba(10, 10, 10, 0.95);
}

.input-field::placeholder {
    color: var(--text-secondary);
}

.btn-login {
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-secondary) 100%);
    border: none;
    border-radius: 8px;
    color: var(--bg-dark);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 8px 24px rgba(14, 165, 233, 0.3);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(14, 165, 233, 0.4);
}

.btn-login:active {
    transform: translateY(0);
}

.error-msg {
    color: #ef4444;
    font-size: 12px;
    margin-top: 12px;
    text-align: center;
    display: none;
}

.error-msg.show {
    display: block;
    animation: shake 0.4s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Footer */
.footer {
    position: absolute;
    bottom: 40px;
    text-align: center;
    font-size: 12px;
    color: var(--text-secondary);
    animation: fadeIn 0.8s ease-out 0.6s both;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.footer p {
    margin: 4px 0;
}

.footer-sub {
    color: var(--text-secondary);
    opacity: 0.6;
}

/* Responsive */
@media (max-width: 768px) {
    .header {
        top: 20px;
        left: 20px;
    }

    .hero-title {
        font-size: 36px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .hero-description {
        font-size: 13px;
    }

    .auth-box {
        padding: 32px 24px;
    }

    .footer {
        bottom: 20px;
        left: 20px;
        right: 20px;
    }

    .logo {
        width: 40px;
        height: 40px;
    }

    .brand-name {
        font-size: 20px;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-primary);
}
