/* JudeMind auth pages */
:root {
    --primary: #ff7200;
    --primary-dark: #e65a00;
    --surface: #12121A;
    --surface-2: #1A1B26;
    --border: rgba(255, 114, 0, 0.25);
    --text: #FFFFFF;
    --text-muted: #9CA3AF;
    --error: #EF4444;
    --success: #10B981; /* Added success color */
    --radius: 14px;
}

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

body.auth-page {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(180deg, rgba(10,10,15,0.95) 0%, rgba(17,24,39,0.92) 100%),
        radial-gradient(ellipse 80% 50% at 50% 0%, rgba(255, 114, 0, 0.12) 0%, transparent 50%);
    min-height: 100vh;
    color: var(--text);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

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

.auth-card {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: 0 24px 48px rgba(0,0,0,0.3);
    animation: fadeIn 0.3s ease; /* Added fade-in animation */
}

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

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

.auth-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text);
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 20px;
    transition: opacity 0.2s; /* Added hover effect */
}

.auth-logo:hover {
    opacity: 0.9;
}

.auth-logo img {
    width: 44px;
    height: 44px;
    object-fit: contain;
}

.auth-header h1 {
    font-size: 1.5rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.auth-header p {
    color: var(--text-muted);
    font-size: 0.9375rem;
    line-height: 1.5;
}

.auth-form {
    width: 100%;
}

.auth-form label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--text);
}

.auth-form input {
    width: 100%;
    padding: 12px 14px;
    margin-bottom: 16px;
    font-size: 1rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: rgba(255,255,255,0.05);
    color: var(--text);
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.auth-form input::placeholder {
    color: var(--text-muted);
    opacity: 0.7;
}

.auth-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 114, 0, 0.2);
    background: rgba(255,255,255,0.08);
}

.auth-form input:hover:not(:focus) {
    background: rgba(255,255,255,0.08);
}

/* Password hint styling */
.password-hint {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: -12px;
    margin-bottom: 16px;
    line-height: 1.4;
}

/* Message styling */
.auth-message {
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9375rem;
    line-height: 1.5;
    animation: slideIn 0.2s ease;
}

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

.auth-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #FCA5A5;
}

.auth-success {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #A7F3D0;
}

/* Button styling */
.auth-submit {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    background: linear-gradient(135deg, var(--primary), #1e90ff);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 8px;
    transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
    position: relative;
    overflow: hidden;
}

.auth-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 114, 0, 0.4);
}

.auth-submit:active {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(255, 114, 0, 0.3);
}

.auth-submit:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 114, 0, 0.3);
}

.auth-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Footer styling */
.auth-footer {
    text-align: center;
    margin-top: 24px;
    font-size: 0.9375rem;
    color: var(--text-muted);
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.auth-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.auth-footer a:hover {
    color: #ff8c33;
    text-decoration: underline;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    body.auth-page {
        padding: 16px;
    }
    
    .auth-card {
        padding: 24px;
    }
    
    .auth-header h1 {
        font-size: 1.375rem;
    }
    
    .auth-logo img {
        width: 40px;
        height: 40px;
    }
}

/* Loading state for buttons */
.auth-submit.loading {
    color: transparent;
    background-image: linear-gradient(135deg, var(--primary), #1e90ff);
    position: relative;
    pointer-events: none;
}

.auth-submit.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

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

/* Input validation states */
.auth-form input.error {
    border-color: var(--error);
    background: rgba(239, 68, 68, 0.05);
}

.auth-form input.error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

.auth-form input.success {
    border-color: var(--success);
}

/* Remember me checkbox styling (for login page) */
.remember-me {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.remember-me input[type="checkbox"] {
    width: auto;
    margin-right: 8px;
    margin-bottom: 0;
    accent-color: var(--primary);
}

.remember-me label {
    margin-bottom: 0;
    font-size: 0.875rem;
    cursor: pointer;
}