/* Authentication Pages Styles */

.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
}

/* Branding Panel */
.auth-branding {
    background: linear-gradient(135deg, rgba(255, 77, 109, 0.1) 0%, rgba(0, 0, 0, 0.95) 100%),
                url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="20" height="20" patternUnits="userSpaceOnUse"><path d="M 20 0 L 0 0 0 20" fill="none" stroke="rgba(255,77,109,0.1)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)" /></svg>');
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.auth-branding::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255, 77, 109, 0.15) 0%, transparent 70%);
    animation: glow 8s ease-in-out infinite;
}

@keyframes glow {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-20px, -20px) scale(1.1); }
}

.branding-content {
    position: relative;
    z-index: 1;
    max-width: 500px;
}

.brand-logo {
    margin-bottom: 2rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.branding-content h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #FFFFFF, var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.branding-content > p {
    font-size: 1.1rem;
    color: var(--dark-text-secondary);
    margin-bottom: 3rem;
    line-height: 1.7;
}

.feature-highlights {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.highlight-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 77, 109, 0.2);
    border-radius: var(--radius-md);
    transition: all var(--transition-normal);
}

.highlight-item:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 77, 109, 0.4);
    transform: translateX(10px);
}

.highlight-icon {
    font-size: 2rem;
    min-width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 77, 109, 0.1);
    border-radius: var(--radius-md);
}

.highlight-item h3 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
    color: var(--dark-text-primary);
}

.highlight-item p {
    font-size: 0.9rem;
    color: var(--dark-text-secondary);
    margin: 0;
}

/* Form Panel */
.auth-form-panel {
    background: var(--dark-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
}

.auth-form-container {
    width: 100%;
    max-width: 450px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--dark-text-secondary);
    text-decoration: none;
    margin-bottom: 2rem;
    transition: color var(--transition-fast);
}

.back-link:hover {
    color: var(--primary-color);
}

.form-header {
    margin-bottom: 2rem;
}

.form-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: var(--dark-text-primary);
}

.form-header p {
    color: var(--dark-text-secondary);
    font-size: 0.95rem;
}

.auth-form {
    margin-bottom: 2rem;
}

.password-input {
    position: relative;
}

.password-input .form-control {
    padding-right: 45px;
}

.toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--dark-text-hint);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color var(--transition-fast);
}

.toggle-password:hover {
    color: var(--primary-color);
}

.password-strength {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    font-weight: 500;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--dark-text-secondary);
    font-size: 0.9rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.link-primary {
    color: var(--primary-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.link-primary:hover {
    color: var(--primary-light);
    text-decoration: underline;
}

.btn-full {
    width: 100%;
}

.btn-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: inline-block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.divider {
    position: relative;
    text-align: center;
    margin: 2rem 0;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--dark-surface-variant);
}

.divider span {
    position: relative;
    display: inline-block;
    padding: 0 1rem;
    background: var(--dark-bg);
    color: var(--dark-text-hint);
    font-size: 0.85rem;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    background: var(--dark-surface);
    color: var(--dark-text-primary);
    border: 2px solid var(--dark-surface-variant);
}

.social-btn:hover {
    border-color: var(--primary-color);
    background: var(--dark-surface-variant);
}

.form-footer {
    text-align: center;
    margin-top: 2rem;
}

.form-footer p {
    color: var(--dark-text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* Light Mode Adjustments */
body.light-mode .auth-branding {
    background: linear-gradient(135deg, rgba(255, 77, 109, 0.05) 0%, rgba(255, 255, 255, 0.95) 100%);
}

body.light-mode .branding-content h1 {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

body.light-mode .branding-content > p {
    color: var(--light-text-secondary);
}

body.light-mode .highlight-item {
    background: rgba(255, 77, 109, 0.05);
    border-color: rgba(255, 77, 109, 0.2);
}

body.light-mode .highlight-item:hover {
    background: rgba(255, 77, 109, 0.1);
}

body.light-mode .highlight-item h3 {
    color: var(--light-text-primary);
}

body.light-mode .highlight-item p {
    color: var(--light-text-secondary);
}

body.light-mode .highlight-icon {
    background: rgba(255, 77, 109, 0.1);
}

body.light-mode .auth-form-panel {
    background: var(--light-bg);
}

body.light-mode .back-link {
    color: var(--light-text-secondary);
}

body.light-mode .back-link:hover {
    color: var(--primary-color);
}

body.light-mode .form-header h2 {
    color: var(--light-text-primary);
}

body.light-mode .form-header p {
    color: var(--light-text-secondary);
}

body.light-mode .toggle-password {
    color: var(--light-text-hint);
}

body.light-mode .toggle-password:hover {
    color: var(--primary-color);
}

body.light-mode .checkbox-label {
    color: var(--light-text-secondary);
}

body.light-mode .divider::before {
    background: var(--light-surface-variant);
}

body.light-mode .divider span {
    background: var(--light-bg);
    color: var(--light-text-hint);
}

body.light-mode .social-btn {
    background: var(--light-surface);
    color: var(--light-text-primary);
    border-color: var(--light-surface-variant);
}

body.light-mode .social-btn:hover {
    border-color: var(--primary-color);
    background: var(--light-surface-variant);
}

body.light-mode .form-footer p {
    color: var(--light-text-secondary);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .auth-container {
        grid-template-columns: 1fr;
    }
    
    .auth-branding {
        display: none;
    }
    
    .auth-form-panel {
        padding: 2rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .auth-form-panel {
        padding: 2rem 1rem;
    }
    
    .auth-form-container {
        max-width: 100%;
    }
    
    .form-header h2 {
        font-size: 1.75rem;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}

/* Animation for form elements */
.auth-form .form-group {
    animation: slideIn 0.5s ease forwards;
    opacity: 0;
}

.auth-form .form-group:nth-child(1) { animation-delay: 0.1s; }
.auth-form .form-group:nth-child(2) { animation-delay: 0.2s; }
.auth-form .form-group:nth-child(3) { animation-delay: 0.3s; }
.auth-form .form-group:nth-child(4) { animation-delay: 0.4s; }

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
