body {
    min-height: 100vh;
    min-height: -webkit-fill-available;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 90px 16px 40px;
    box-sizing: border-box;
}

.auth-container {
    position: relative;
    z-index: 1;
    max-width: 450px;
    width: 100%;
    margin: 0;
    padding: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    animation: fadeInUp 0.5s ease-out;
    -webkit-transform: translate3d(0, 0, 0);
}

.auth-header {
    text-align: center;
    margin-bottom: 35px;
}

.spark-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
}

.spark-icon {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 15px rgba(0, 87, 183, 0.5));
}

.auth-title {
    font-size: 2rem;
    font-weight: 900;
    letter-spacing: 4px;
    background: linear-gradient(135deg, #0057B7 0%, #FFD700 50%, #0057B7 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shine 3s linear infinite;
    margin-bottom: 10px;
}

.auth-subtitle {
    font-size: 1rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 1px;
}

.auth-form {
    margin-bottom: 30px;
}

.auth-type-toggle {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}

.auth-type-btn {
    flex: 1;
    padding: 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    pointer-events: auto;
    position: relative;
    z-index: 10;
    min-height: 48px;
}

.auth-type-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.auth-type-btn.active {
    background: linear-gradient(135deg, #0057B7 0%, #FFD700 100%);
    border-color: transparent;
    color: #ffffff;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    letter-spacing: 1px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #ffffff;
    font-family: 'Montserrat', sans-serif;
    font-size: 16px;
    transition: all 0.3s ease;
    min-height: 48px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #0057B7;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 20px rgba(0, 87, 183, 0.2);
}

.auth-submit {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #0057B7 0%, #FFD700 100%);
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    min-height: 52px;
}

.auth-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 87, 183, 0.3);
}

.auth-submit:active {
    transform: translateY(0);
}

.auth-error {
    margin-top: 20px;
    padding: 12px;
    background: rgba(255, 0, 0, 0.1);
    border: 1px solid rgba(255, 0, 0, 0.3);
    border-radius: 10px;
    color: #ff6b6b;
    font-size: 0.85rem;
    font-weight: 600;
    text-align: center;
    display: none;
}

.auth-footer {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-footer p {
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
}

.auth-link {
    color: #FFD700;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.auth-link:hover {
    color: #0057B7;
    text-decoration: underline;
}

@media (max-width: 768px) {
    .auth-container {
        margin: 70px 16px;
        padding: 30px 24px;
    }

    .auth-title {
        font-size: 1.6rem;
        letter-spacing: 3px;
    }

    .auth-subtitle {
        font-size: 0.9rem;
    }

    .spark-logo {
        width: 65px;
        height: 65px;
    }

    .auth-submit:hover {
        transform: none;
    }
}

@media (max-width: 480px) {
    .auth-container {
        padding: 24px 16px;
        border-radius: 16px;
    }

    .auth-header {
        margin-bottom: 28px;
    }

    .auth-title {
        font-size: 1.3rem;
        letter-spacing: 2px;
    }

    .auth-subtitle {
        font-size: 0.82rem;
    }

    .spark-logo {
        width: 50px;
        height: 50px;
        margin-bottom: 16px;
    }

    .auth-type-btn {
        padding: 12px;
        font-size: 0.88rem;
        min-height: 44px;
    }

    .form-group label {
        font-size: 0.82rem;
        margin-bottom: 6px;
    }

    .form-group input {
        padding: 12px 14px;
        font-size: 16px;
    }

    .auth-submit {
        padding: 14px;
        font-size: 0.95rem;
        min-height: 48px;
    }

    .auth-footer p {
        font-size: 0.82rem;
    }
}

@media (hover: none) and (pointer: coarse) {
    .auth-submit:hover {
        transform: none;
    }
}

.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 16px;
}

.modal-box {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 20px;
    padding: 40px 32px;
    text-align: center;
    max-width: 380px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.modal-icon-svg {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(0, 87, 183, 0.3), rgba(255, 215, 0, 0.15));
    border: 1px solid rgba(255, 215, 0, 0.3);
    color: #FFD700;
}

.modal-box h2 {
    color: #fff;
    font-size: 1.4rem;
    margin: 0 0 12px;
}

.modal-box p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    margin: 0 0 20px;
}

.modal-btn {
    display: inline-block;
    background: linear-gradient(135deg, #0057B7, #004499);
    color: #FFD700;
    font-size: 1.1rem;
    font-weight: 700;
    padding: 14px 32px;
    border-radius: 12px;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.modal-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 20px rgba(0, 87, 183, 0.5);
}

.modal-close {
    display: block;
    margin: 20px auto 0;
    background: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.6);
    padding: 10px 24px;
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.modal-close:hover {
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
}
