/**
 * Authentication Page Styles
 * Styles for login, registration, and password reset pages
 */

/* Auth Page Layout */
.auth-page {
    background: var(--gradient-navy);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-container {
    width: 100%;
    max-width: 450px;
}

/* Auth Card */
.auth-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 40px;
    margin-bottom: 20px;
}

.auth-card.hidden {
    display: none;
}

/* Auth Header */
.auth-header {
    text-align: center;
    margin-bottom: 32px;
}

.auth-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 8px 0;
}

.auth-header p {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
}

/* Auth Form */
.auth-form {
    margin-bottom: 24px;
}

.auth-form h2 {
    font-size: 20px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 24px 0;
    text-align: center;
}

.auth-form p {
    font-size: 14px;
    color: #6b7280;
    margin: 0 0 20px 0;
    text-align: center;
}

/* Form Groups */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 6px;
}

.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="text"] {
    width: 100%;
    padding: 12px 14px;
    font-size: 14px;
    border: 1.5px solid #d1d5db;
    border-radius: 6px;
    transition: all 0.2s;
    box-sizing: border-box;
}

.form-group input:focus {
    outline: none;
    border-color: var(--sky-blue);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.form-group small {
    display: block;
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

/* Form Options (Remember Me / Forgot Password) */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    font-size: 14px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    color: #374151;
}

.checkbox-label input[type="checkbox"] {
    margin-right: 8px;
    cursor: pointer;
}

.link {
    color: var(--sky-blue);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.link:hover {
    color: var(--sky-blue-dark);
    text-decoration: underline;
}

/* Buttons */
.btn-block {
    width: 100%;
}

.btn-primary {
    background: var(--gradient-navy);
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

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

/* Messages */
.error-message,
.success-message {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
}

.error-message {
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.success-message {
    background: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

.error-message.hidden,
.success-message.hidden {
    display: none;
}

/* Loading Spinner */
.loading-spinner {
    text-align: center;
    margin-top: 20px;
}

.loading-spinner.hidden {
    display: none;
}

.spinner {
    width: 40px;
    height: 40px;
    margin: 0 auto 12px;
    border: 4px solid #e5e7eb;
    border-top-color: var(--sky-blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.loading-spinner p {
    font-size: 14px;
    color: #6b7280;
}

/* Auth Footer */
.auth-footer {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.auth-footer p {
    font-size: 14px;
    color: #6b7280;
    margin: 0;
}

/* User Display in Navigation */
#userEmail {
    font-size: 14px;
    color: #374151;
    font-weight: 500;
    margin-right: 16px;
}

#loginButton,
#logoutButton {
    display: none;
}

/* Responsive Design */
@media (max-width: 500px) {
    .auth-card {
        padding: 30px 24px;
    }

    .auth-header h1 {
        font-size: 20px;
    }

    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}
