/* Authentication System Styles - ARCHTELIER INTERIORS */
/* Advanced styling for login, register, and auth-related pages */

/* Base Auth Styles */
.auth-page {
    min-height: 100vh;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #1a1a1a;
    position: relative;
    overflow-x: hidden;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #d4af37;
    color: #1a1a1a;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    font-weight: 600;
    z-index: 1000;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 6px;
}

/* Background */
.auth-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 50%, #1a1a1a 100%);
}

.background-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 30% 20%, rgba(212, 175, 55, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 80%, rgba(212, 175, 55, 0.05) 0%, transparent 50%);
}

.background-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(45deg, rgba(212, 175, 55, 0.02) 25%, transparent 25%),
        linear-gradient(-45deg, rgba(212, 175, 55, 0.02) 25%, transparent 25%),
        linear-gradient(45deg, transparent 75%, rgba(212, 175, 55, 0.02) 75%),
        linear-gradient(-45deg, transparent 75%, rgba(212, 175, 55, 0.02) 75%);
    background-size: 60px 60px;
    background-position: 0 0, 0 30px, 30px -30px, -30px 0px;
    animation: patternMove 120s linear infinite;
}

@keyframes patternMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(60px, 60px); }
}

/* Header */
.auth-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 0;
    background: rgba(26, 26, 26, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 100;
}

.auth-header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
}

.logo {
    height: 40px;
    width: auto;
}

.auth-nav {
    display: flex;
    gap: 20px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #cccccc;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #d4af37;
}

/* Main Content */
.auth-main {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 20px 60px;
}

.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    max-width: 1200px;
    width: 100%;
    align-items: start;
}

/* Auth Card */
.auth-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.auth-card-header {
    text-align: center;
    margin-bottom: 40px;
}

.auth-card-header h1 {
    font-size: 2.2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 12px;
}

.auth-card-header p {
    font-size: 1.1rem;
    color: #cccccc;
    line-height: 1.6;
}

/* Social Login */
.social-login {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
}

.social-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 14px 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.social-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s;
}

.social-btn:hover::before {
    left: 100%;
}

.social-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.social-icon {
    width: 20px;
    height: 20px;
}

.google-btn:hover {
    background: rgba(66, 133, 244, 0.1);
    border-color: #4285F4;
}

.facebook-btn:hover {
    background: rgba(24, 119, 242, 0.1);
    border-color: #1877F2;
}

/* Auth Divider */
.auth-divider {
    position: relative;
    text-align: center;
    margin: 30px 0;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.auth-divider span {
    background: rgba(26, 26, 26, 0.9);
    padding: 0 20px;
    color: #888;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Form Styles */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 600;
}

.form-label i {
    color: #d4af37;
    font-size: 1.1rem;
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-input::placeholder {
    color: #888;
}

.form-input:focus {
    outline: none;
    border-color: #d4af37;
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.form-input:valid {
    border-color: rgba(34, 197, 94, 0.5);
}

.form-input:invalid:not(:placeholder-shown) {
    border-color: rgba(239, 68, 68, 0.5);
}

/* Password Input */
.password-input-wrapper {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: #888;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.password-toggle:hover {
    color: #d4af37;
    background: rgba(255, 255, 255, 0.1);
}

/* Password Strength */
.password-strength {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.strength-bar {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.strength-fill {
    height: 100%;
    width: 0;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.strength-fill[data-strength="1"] {
    width: 25%;
    background: #ef4444;
}

.strength-fill[data-strength="2"] {
    width: 50%;
    background: #f59e0b;
}

.strength-fill[data-strength="3"] {
    width: 75%;
    background: #eab308;
}

.strength-fill[data-strength="4"] {
    width: 100%;
    background: #22c55e;
}

.strength-text {
    font-size: 0.85rem;
    color: #888;
}

/* Form Help */
.form-help {
    font-size: 0.85rem;
    color: #888;
    line-height: 1.4;
}

.form-error {
    font-size: 0.85rem;
    color: #ef4444;
    min-height: 1.2rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.form-error:empty {
    display: none;
}

.form-error::before {
    content: "⚠";
    font-size: 1rem;
}

/* Checkboxes */
.checkbox-group {
    border: none;
    padding: 0;
    margin: 0;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    line-height: 1.5;
    margin-bottom: 15px;
}

.checkbox-label.required {
    position: relative;
}

.checkbox-input {
    display: none;
}

.checkbox-custom {
    width: 20px;
    height: 20px;
    min-width: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    background: transparent;
    position: relative;
    transition: all 0.3s ease;
    margin-top: 2px;
}

.checkbox-input:checked + .checkbox-custom {
    background: #d4af37;
    border-color: #d4af37;
}

.checkbox-input:checked + .checkbox-custom::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #1a1a1a;
    font-weight: bold;
    font-size: 0.8rem;
}

.checkbox-input:focus + .checkbox-custom {
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2);
}

.checkbox-label a {
    color: #d4af37;
    text-decoration: none;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.forgot-password-link {
    color: #d4af37;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
}

.forgot-password-link:hover {
    text-decoration: underline;
}

/* Auth Button */
.auth-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 16px 24px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
}

.auth-btn.primary {
    background: linear-gradient(135deg, #d4af37, #f4d03f);
    color: #1a1a1a;
}

.auth-btn.primary:hover {
    background: linear-gradient(135deg, #f4d03f, #d4af37);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.3);
}

.auth-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-text {
    transition: opacity 0.3s ease;
}

.btn-loader {
    position: absolute;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.auth-btn.loading .btn-text {
    opacity: 0;
}

.auth-btn.loading .btn-loader {
    opacity: 1;
}

.btn-loader i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Messages */
.auth-error,
.auth-success {
    padding: 15px 20px;
    border-radius: 10px;
    margin-top: 20px;
    font-weight: 500;
    display: none;
}

.auth-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.auth-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: #86efac;
}

.auth-error.show,
.auth-success.show {
    display: block;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Card Footer */
.auth-card-footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-card-footer p {
    color: #cccccc;
    margin-bottom: 12px;
}

.auth-link {
    color: #d4af37;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.05rem;
}

.auth-link:hover {
    text-decoration: underline;
}

/* Info Panel */
.auth-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 40px 0;
}

.info-content h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 30px;
    line-height: 1.2;
}

.benefits-list {
    list-style: none;
    padding: 0;
    margin-bottom: 40px;
}

.benefits-list li {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 0;
    color: #cccccc;
    font-size: 1.05rem;
    line-height: 1.5;
}

.benefits-list i {
    color: #d4af37;
    font-size: 1.3rem;
    min-width: 24px;
}

/* Testimonial */
.testimonial {
    background: rgba(255, 255, 255, 0.05);
    border-left: 4px solid #d4af37;
    padding: 25px 30px;
    border-radius: 10px;
    margin-top: 30px;
}

.testimonial blockquote {
    font-size: 1.1rem;
    font-style: italic;
    color: #ffffff;
    margin-bottom: 15px;
    line-height: 1.6;
}

.testimonial cite {
    color: #d4af37;
    font-size: 0.95rem;
    font-weight: 600;
}

/* Stats */
.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 40px;
}

.stat-item {
    text-align: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 900;
    color: #d4af37;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.85rem;
    color: #cccccc;
    font-weight: 500;
}

/* Footer */
.auth-footer {
    background: rgba(0, 0, 0, 0.5);
    padding: 40px 0 20px;
    margin-top: 60px;
}

.auth-footer .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.footer-links a {
    color: #888;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #d4af37;
}

.footer-social {
    display: flex;
    gap: 15px;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    background: #d4af37;
    color: #1a1a1a;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: #888;
    font-size: 0.85rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .auth-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .auth-info {
        order: -1;
        text-align: center;
    }
    
    .stats {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .auth-main {
        padding: 100px 15px 40px;
    }
    
    .auth-card {
        padding: 30px 25px;
    }
    
    .auth-card-header h1 {
        font-size: 1.8rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .info-content h2 {
        font-size: 1.6rem;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .auth-card {
        padding: 25px 20px;
    }
    
    .social-login {
        gap: 12px;
    }
    
    .social-btn {
        padding: 12px 16px;
        font-size: 0.95rem;
    }
    
    .stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 15px;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .background-pattern {
        animation: none;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .auth-card {
        border: 2px solid #ffffff;
    }
    
    .form-input {
        border-width: 2px;
    }
    
    .checkbox-custom {
        border-width: 2px;
    }
}

/* Dark mode (if system preference) */
@media (prefers-color-scheme: dark) {
    /* Already optimized for dark mode */
}

/* Print styles */
@media print {
    .auth-page {
        background: white;
        color: black;
    }
    
    .auth-background,
    .background-overlay,
    .background-pattern {
        display: none;
    }
    
    .auth-card {
        background: white;
        border: 1px solid #ccc;
        box-shadow: none;
    }
}