/* ============================================
   AUTH PAGES STYLES - BEAUTIFUL & ANIMATED
   ============================================ */

:root {
    --primary-red: #dc3545;
    --dark-red: #c82333;
    --light-red: #ffebee;
    --dark: #212529;
    --gray: #6c757d;
    --light-gray: #f8f9fa;
}

/* Auth Body */
.auth-body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, var(--primary-red) 0%, var(--dark-red) 100%);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* Floating Background Elements */
.auth-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.floating-shape {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.shape-1 {
    width: 80px;
    height: 80px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 60px;
    height: 60px;
    top: 20%;
    right: 15%;
    animation-delay: 2s;
}

.shape-3 {
    width: 100px;
    height: 100px;
    bottom: 20%;
    left: 20%;
    animation-delay: 4s;
}

.shape-4 {
    width: 40px;
    height: 40px;
    bottom: 30%;
    right: 25%;
    animation-delay: 1s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.1;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 0.2;
    }
}

/* Auth Container */
.auth-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 450px;
    padding: 2rem;
}

/* Logo Section */
.auth-logo {
    text-align: center;
    animation: slideInDown 0.8s ease-out;
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.logo-icon {
    font-size: 3rem;
    animation: pulse 2s ease-in-out infinite;
}

.logo-text {
    font-size: 1.8rem;
    line-height: 1.2;
}

/* Auth Card */
.auth-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 1.5rem;
    padding: 2.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: slideInUp 0.8s ease-out 0.2s both;
    position: relative;
    overflow: hidden;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-red), #ff6b6b, var(--primary-red));
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% {
        opacity: 0.7;
    }
    50% {
        opacity: 1;
    }
}

/* Form Elements */
.auth-form-group {
    margin-bottom: 1rem;
    animation: fadeInUp 0.6s ease-out both;
}

.auth-form-group:nth-child(1) { animation-delay: 0.4s; }
.auth-form-group:nth-child(2) { animation-delay: 0.5s; }
.auth-form-group:nth-child(3) { animation-delay: 0.6s; }
.auth-form-group:nth-child(4) { animation-delay: 0.7s; }

.auth-label {
    display: block;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
}

.auth-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 0.75rem;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: white;
    position: relative;
}

.auth-input:focus {
    outline: none;
    border-color: var(--primary-red);
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
    transform: translateY(-2px);
}

.auth-input::placeholder {
    color: #adb5bd;
}

/* Input Icons */
.input-group {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray);
    z-index: 3;
    transition: color 0.3s ease;
}

.input-group .auth-input {
    padding-left: 3rem;
}

.input-group:focus-within .input-icon {
    color: var(--primary-red);
}

/* Error Messages */
.auth-error {
    color: var(--primary-red);
    font-size: 0.875rem;
    margin-top: 0.5rem;
    animation: shake 0.5s ease-in-out;
}

/* Remember Me */
.auth-remember {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    animation: fadeInUp 0.6s ease-out 0.8s both;
}

.auth-checkbox {
    width: 16px;
    height: 16px;
    margin-right: 0.6rem;
    accent-color: var(--primary-red);
}

.auth-remember-label {
    color: var(--gray);
    font-size: 0.85rem;
    cursor: pointer;
}

/* Buttons */
.auth-button {
    width: 100%;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--primary-red), var(--dark-red));
    border: none;
    border-radius: 0.75rem;
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    animation: fadeInUp 0.6s ease-out 0.9s both;
}

.auth-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.auth-button:hover::before {
    left: 100%;
}

.auth-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(220, 53, 69, 0.3);
}

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

/* Links */
.auth-link {
    color: var(--primary-red);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    animation: fadeInUp 0.6s ease-out 1s both;
}

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

/* Footer */
.auth-footer {
    text-align: center;
    animation: fadeIn 0.8s ease-out 1.1s both;
}

/* Animations */
@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

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

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

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

/* Responsive Design */
@media (max-width: 576px) {
    .auth-container {
        padding: 1rem;
    }
    
    .auth-card {
        padding: 2rem 1.5rem;
    }
    
    .logo-icon {
        font-size: 2.5rem;
    }
    
    .logo-text {
        font-size: 1.5rem;
    }
}

/* Success/Error States */
.auth-success {
    background: rgba(40, 167, 69, 0.1);
    border-color: #28a745;
    color: #155724;
}

.auth-error-state {
    background: rgba(220, 53, 69, 0.1);
    border-color: var(--primary-red);
}

/* Loading State */
.auth-button.loading {
    pointer-events: none;
    opacity: 0.7;
}

.auth-button.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ============================================
   SPLIT LAYOUT DESIGN (NEW)
   ============================================ */

/* Wide Container for Split Layout */
.auth-container-wide {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1100px;
    padding: 1.5rem 2rem 2rem;
}

/* Logo Top (for split layout) */
.auth-logo-top {
    text-align: center;
    animation: slideInDown 0.8s ease-out;
    margin-bottom: 1.5rem;
}

.auth-logo-top .logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}

.auth-logo-top .logo-icon {
    font-size: 2.5rem;
    color: white;
    animation: pulse 2s ease-in-out infinite;
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.3));
}

.auth-logo-top .logo-text {
    font-size: 1.75rem;
    line-height: 1.2;
}

/* Split Card */
.auth-card-split {
    background: white;
    border-radius: 1.5rem;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    animation: slideInUp 0.8s ease-out 0.2s both;
    min-height: 550px;
    max-height: 85vh;
}

/* Form Section (Left Side) */
.auth-form-section {
    padding: 2rem 2.5rem;
    height: 100%;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Image Section (Right Side) */
.auth-image-section {
    height: 100%;
    min-height: 550px;
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.3) 0%, rgba(200, 35, 51, 0.4) 100%),
                url('https://images.unsplash.com/photo-1551434678-e076c223a692?w=800&h=1000&fit=crop&q=80');
    background-size: cover;
    background-position: center;
    background-blend-mode: overlay;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-image-overlay {
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem;
}

.auth-image-content {
    text-align: center;
    animation: fadeInRight 0.8s ease-out 0.4s both;
    margin-top: -1rem;
}

.auth-image-content h3 {
    position: relative;
    display: inline-block;
    color: var(--primary-red);
    font-size: 2rem;
    font-weight: 800;
    text-shadow: 0 2px 4px rgba(255, 255, 255, 0.8);
}

.auth-image-content h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 4px;
    background: var(--primary-red);
    border-radius: 2px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Stats Section */
.auth-stats {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.auth-stat-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    padding: 1rem 1.25rem;
    border-radius: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.auth-stat-item:hover {
    background: rgba(255, 255, 255, 0.85);
    transform: translateX(8px);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.auth-stat-item i {
    font-size: 2rem;
    color: var(--primary-red);
    background: rgba(255, 255, 255, 0.6);
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.auth-stat-item div {
    text-align: left;
}

.auth-stat-item strong {
    display: block;
    color: var(--primary-red);
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.auth-stat-item span {
    display: block;
    color: #2c3e50;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Enhanced Footer for Split Layout */
.auth-container-wide .auth-footer {
    text-align: center;
    animation: fadeIn 0.8s ease-out 1.1s both;
}

.auth-container-wide .auth-footer a {
    color: white;
    font-weight: 500;
    transition: all 0.3s ease;
}

.auth-container-wide .auth-footer a:hover {
    color: rgba(255, 255, 255, 0.8);
    transform: translateX(-5px);
    display: inline-block;
}

/* Back to Home Link (Top Left) */
.auth-back-link {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    z-index: 10;
    animation: fadeIn 0.8s ease-out 0.2s both;
}

.auth-back-link a {
    color: white;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.auth-back-link a:hover {
    color: rgba(255, 255, 255, 0.9);
    transform: translateX(-3px);
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    text-decoration: none;
}

/* Animations for Split Layout */
@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Responsive for Split Layout */
@media (max-width: 991px) {
    .auth-card-split {
        min-height: auto;
    }
    
    .auth-form-section {
        padding: 2.5rem 2rem;
    }
}

@media (max-width: 576px) {
    .auth-container-wide {
        padding: 1rem;
    }
    
    .auth-form-section {
        padding: 2rem 1.5rem;
    }
    
    .auth-logo-top .logo-icon {
        font-size: 2.5rem;
    }
    
    .auth-logo-top .logo-text {
        font-size: 1.5rem;
    }
}
