* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

/* Animated background particles */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(242, 168, 58, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(242, 168, 58, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(242, 168, 58, 0.05) 0%, transparent 50%);
    pointer-events: none;
}
/* Locate this at the top of auth.css */
body, 
.login-view-container, 
.register-view-container {
    font-family: 'Inter', sans-serif;
    /* This ensures the dark gradient covers the screen even when injected into index.html */
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%) !important;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Ccircle cx='10' cy='10' r='1.5' fill='%23f2a83a' opacity='0.3'/%3E%3Ccircle cx='30' cy='25' r='1' fill='%23f2a83a' opacity='0.2'/%3E%3Ccircle cx='70' cy='15' r='1.5' fill='%23f2a83a' opacity='0.3'/%3E%3Ccircle cx='85' cy='45' r='1' fill='%23f2a83a' opacity='0.2'/%3E%3Ccircle cx='15' cy='65' r='1' fill='%23f2a83a' opacity='0.25'/%3E%3Ccircle cx='55' cy='80' r='1.5' fill='%23f2a83a' opacity='0.2'/%3E%3Ccircle cx='90' cy='85' r='1' fill='%23f2a83a' opacity='0.3'/%3E%3C/svg%3E");
    background-repeat: repeat;
    background-size: 60px 60px;
    pointer-events: none;
    opacity: 0.5;
}

.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    position: relative;
    z-index: 1;
}

.auth-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    gap: 40px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.auth-card {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 40px;
    padding: 48px;
    max-width: 520px;
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(242, 168, 58, 0.2);
}

.auth-decoration {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.decoration-circle {
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(242, 168, 58, 0.08), rgba(242, 168, 58, 0.02));
}

.circle-1 {
    width: 250px;
    height: 250px;
    top: -125px;
    right: -125px;
}

.circle-2 {
    width: 180px;
    height: 180px;
    bottom: -90px;
    left: -90px;
}

.circle-3 {
    width: 120px;
    height: 120px;
    top: 30%;
    left: 15%;
}

.circle-4 {
    width: 80px;
    height: 80px;
    bottom: 20%;
    right: 10%;
}

.auth-header {
    text-align: center;
    margin-bottom: 32px;
    position: relative;
    z-index: 1;
}


.auth-header h1 {
    font-size: 1.8rem;
    font-weight: 800;
    color: #1f2a44;
    margin-bottom: 8px;
}

.auth-header h1 .accent {
    color: #f2a83a;
    background: linear-gradient(135deg, #f2a83a, #e5982b);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.auth-header p {
    color: #64748b;
    font-size: 0.9rem;
}

.auth-tab-container {
    display: flex;
    gap: 12px;
    background: #f1f5f9;
    padding: 6px;
    border-radius: 60px;
    margin-bottom: 32px;
    position: relative;
    z-index: 1;
}

.auth-tab-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 50px;
    background: transparent;
    font-weight: 600;
    font-size: 0.9rem;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.auth-tab-btn i {
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.auth-tab-btn.active {
    background: white;
    color: #f2a83a;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.auth-tab-btn.active i {
    color: #f2a83a;
}

.auth-tab-btn:hover:not(.active) {
    color: #f2a83a;
    background: rgba(242, 168, 58, 0.1);
}

.auth-form-container {
    display: none;
    animation: fadeInUp 0.4s ease;
}

.auth-form-container.active {
    display: block;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-form {
    position: relative;
    z-index: 1;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #1f2a44;
    margin-bottom: 8px;
}

.form-group label i {
    color: #f2a83a;
    width: 18px;
    font-size: 0.8rem;
}

.form-group input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    font-size: 0.9rem;
    transition: all 0.2s;
    background: white;
    font-family: inherit;
}

.form-group input:focus {
    outline: none;
    border-color: #f2a83a;
    box-shadow: 0 0 0 4px rgba(242, 168, 58, 0.1);
}

.form-group input.error {
    border-color: #ef4444;
}

.password-wrapper {
    position: relative;
}

.password-wrapper input {
    padding-right: 48px;
}

.password-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 1rem;
    padding: 8px;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: #f2a83a;
}

.form-row {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
}

.form-group.half {
    flex: 1;
    margin-bottom: 0;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: #64748b;
    cursor: pointer;
}

.checkbox-label input {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #f2a83a;
}

.checkbox-label a {
    color: #f2a83a;
    text-decoration: none;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

.forgot-link {
    color: #f2a83a;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s;
}

.forgot-link:hover {
    text-decoration: underline;
    color: #e5982b;
}

.auth-submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #1f2a44, #2d3a5e);
    color: white;
    border: none;
    border-radius: 60px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 8px;
    position: relative;
    overflow: hidden;
}

.auth-submit-btn::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.5s;
}

.auth-submit-btn:hover::before {
    left: 100%;
}

.auth-submit-btn:hover {
    background: linear-gradient(135deg, #f2a83a, #e5982b);
    color: #1f2a44;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(242, 168, 58, 0.4);
}

.auth-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.auth-divider {
    text-align: center;
    margin: 24px 0;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #e2e8f0, transparent);
}

.auth-divider span {
    background: rgba(255, 255, 255, 0.98);
    padding: 0 16px;
    position: relative;
    color: #94a3b8;
    font-size: 0.8rem;
}

.social-login {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
}

.social-btn {
    flex: 1;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 60px;
    background: white;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.social-btn.google {
    color: #db4437;
    border-color: #db443740;
}

.social-btn.google:hover {
    background: #db4437;
    border-color: #db4437;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(219, 68, 55, 0.3);
}

.social-btn.facebook {
    color: #4267b2;
    border-color: #4267b240;
}

.social-btn.facebook:hover {
    background: #4267b2;
    border-color: #4267b2;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 103, 178, 0.3);
}

.auth-footer-text {
    text-align: center;
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 16px;
}

.auth-footer-text a {
    color: #f2a83a;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s;
}

.auth-footer-text a:hover {
    text-decoration: underline;
    color: #e5982b;
}

.error-text {
    color: #ef4444;
    font-size: 0.75rem;
    margin-top: 6px;
    display: none;
}

.error-text.show {
    display: block;
}

.form-message {
    padding: 12px;
    border-radius: 12px;
    margin-top: 16px;
    font-size: 0.85rem;
    display: none;
}

.form-message.success {
    background: #10b98120;
    color: #10b981;
    border: 1px solid #10b98140;
    display: block;
}

.form-message.error {
    background: #ef444420;
    color: #ef4444;
    border: 1px solid #ef444440;
    display: block;
}

.forgot-password-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.forgot-password-modal.show {
    display: flex;
}

.forgot-modal-content {
    background: white;
    border-radius: 28px;
    max-width: 450px;
    width: 90%;
    overflow: hidden;
    animation: modalSlideUp 0.3s ease;
}

.forgot-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #1f2a44, #2d3a5e);
}

.forgot-modal-header h3 {
    color: white;
    font-size: 1.1rem;
    font-weight: 700;
}

.forgot-modal-header h3 i {
    color: #f2a83a;
    margin-right: 8px;
}

.forgot-modal-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    font-size: 1.3rem;
    cursor: pointer;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    transition: all 0.2s;
}

.forgot-modal-close:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.forgot-modal-body {
    padding: 24px;
}

.forgot-modal-body p {
    color: #64748b;
    margin-bottom: 20px;
    font-size: 0.9rem;
    line-height: 1.5;
}

.forgot-modal-footer {
    display: flex;
    gap: 12px;
    padding: 16px 24px 24px;
    border-top: 1px solid #e2e8f0;
}

.forgot-modal-footer .btn-secondary,
.forgot-modal-footer .btn-primary {
    flex: 1;
    padding: 12px;
    border-radius: 40px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    font-size: 0.85rem;
}

.forgot-modal-footer .btn-secondary {
    background: #f1f5f9;
    color: #64748b;
}

.forgot-modal-footer .btn-secondary:hover {
    background: #e2e8f0;
}

.forgot-modal-footer .btn-primary {
    background: linear-gradient(135deg, #f2a83a, #e5982b);
    color: #1f2a44;
}

.forgot-modal-footer .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(242, 168, 58, 0.3);
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 28px;
    padding: 28px 32px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(242, 168, 58, 0.2);
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 35px rgba(0, 0, 0, 0.15);
    border-color: rgba(242, 168, 58, 0.4);
}

.stat-icon {
    font-size: 2.8rem;
    margin-bottom: 12px;
}

.stat-number {
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, #f2a83a, #e5982b);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 4px;
}

.stat-label {
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
}

@media (max-width: 768px) {
    .auth-page {
        padding: 20px 16px;
    }
    
    .auth-card {
        padding: 32px 24px;
        max-width: 100%;
    }
    
    .auth-header h1 {
        font-size: 1.4rem;
    }
    
    .auth-tab-btn {
        padding: 10px 16px;
        font-size: 0.8rem;
    }
    
    .form-row {
        flex-direction: column;
        gap: 16px;
    }
    
    .form-group.half {
        margin-bottom: 0;
    }
    
    .social-login {
        flex-direction: column;
    }
    
    
    
    .stat-card {
        padding: 20px 24px;
        min-width: 110px;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .stat-icon {
        font-size: 2rem;
    }
}

@media (max-width: 768px) and (orientation: portrait) {
    .auth-container {
        flex-direction: column;
    }
    

}

/* ==================== SHARED HEADER ADJUSTMENTS ==================== */
/* Remove auth page's own body gradient duplication */
.auth-view-container body,
.login-view-container body,
.register-view-container body {
    background: transparent !important;
}

/* Ensure proper spacing below shared header */
.auth-page {
    padding-top: 20px;
}

@media (max-width: 768px) {
    .auth-page {
        padding-top: 10px;
    }
}

/* Keep the dark gradient when loaded in main site */
.auth-view-container {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0f172a 100%) !important;
}

/* Fix modal z-index to appear above shared header */
.forgot-password-modal {
    z-index: 20000;
}

.forgot-modal-content {
    z-index: 20001;
}
/* ==================== SHARED HEADER ADJUSTMENTS ==================== */
/* Ensure proper spacing for shared header */
body {
    padding: 0 !important;
    margin: 0 !important;
}

.auth-page {
    min-height: calc(100vh - 70px);
    padding: 40px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Mobile adjustment */
@media (max-width: 768px) {
    .auth-page {
        min-height: calc(100vh - 60px);
        padding: 20px 16px;
    }
}

/* Fix modal z-index to appear above shared header */
.forgot-password-modal {
    z-index: 20000;
}

.forgot-modal-content {
    z-index: 20001;
}
/* ==================== UI FIXES ==================== */

/* Remove icons from labels on login form */
#loginFormContainer .form-group label i {
    display: none;
}

/* Remove icons from labels on register form */
#registerFormContainer .form-group label i {
    display: none;
}

/* Social login buttons - horizontal layout on mobile */
@media (max-width: 768px) {
    .social-login {
        flex-direction: row !important;
        gap: 12px;
    }
    
    .social-login .social-btn {
        flex: 1;
        margin: 0;
    }
}

/* Ensure social buttons stay horizontal on all screen sizes */
.social-login {
    display: flex;
    flex-direction: row;
    gap: 12px;
    margin-bottom: 24px;
}

.social-login .social-btn {
    flex: 1;
    padding: 12px;
    white-space: nowrap;
}

/* Extra small devices */
@media (max-width: 480px) {
    .social-login {
        gap: 8px;
    }
    
    .social-login .social-btn {
        padding: 10px 8px;
        font-size: 0.8rem;
    }
}

/* Remove the form-row styling since we no longer have first/last name fields */
.form-row {
    display: none;
}

/* Adjust form group spacing for register form */
#registerFormContainer .form-group {
    margin-bottom: 20px;
}