/* === MEDIA QUERIES RESPONSIVE MODERNES === */
@media (max-width: 1280px) {
    body { font-size: 1.08em; }
    .container, .main, .content { max-width: 98vw; }
}
@media (max-width: 900px) {
    body { font-size: 1em; }
    .container, .main, .content { max-width: 100vw; padding: 0 1rem; }
}
@media (max-width: 600px) {
    body { font-size: 0.95em; }
    .container, .main, .content { max-width: 100vw; padding: 0 0.5rem; }
    .card, .box, .panel { width: 100vw !important; margin: 0 !important; border-radius: 0 !important; }
}
/* ==============================================
   AUTHENTICATION PAGES STYLES (Connexion & Register)
   ============================================== */

/* Variables CSS Premium */
:root {
    --primary-color: #8C744E;
    --primary-dark: #5E4D34;
    --secondary-color: #B8996B;
    --accent-color: #D4A574;
    --premium-gold: #FFD700;
    --premium-gradient: linear-gradient(135deg, #8C744E 0%, #B8996B 50%, #D4A574 100%);
    --background-color: #f8f9fa;
    --card-background: #ffffff;
    --text-primary: #2c3e50;
    --text-secondary: #7f8c8d;
    --text-light: #ecf0f1;
    --border-color: #e9ecef;
    --shadow-color: rgba(140, 116, 78, 0.15);
    --shadow-premium: rgba(140, 116, 78, 0.25);
    --success-color: #27ae60;
    --error-color: #e74c3c;
    --warning-color: #f39c12;
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --transition: all 0.3s ease;
}

/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
}

/* Conteneur principal */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.auth-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 20%, rgba(140, 116, 78, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(140, 116, 78, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

/* Section Hero */
.auth-hero {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    z-index: 2;
}

.auth-hero-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 1rem;
    text-shadow: 0 2px 4px var(--shadow-color);
}

.auth-hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    font-weight: 500;
    max-width: 600px;
    margin: 0 auto;
}

/* Conteneur des cartes */
.auth-cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    width: 100%;
    position: relative;
    z-index: 2;
}

/* Carte d'authentification */
.auth-card {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: 2.5rem;
    box-shadow: 
        0 10px 30px var(--shadow-color),
        0 4px 15px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.auth-card:hover {
    transform: translateY(-5px);
    box-shadow: 
        0 15px 40px var(--shadow-color),
        0 8px 25px rgba(0, 0, 0, 0.15);
}

/* En-tête de carte */
.auth-card-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-card-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.auth-card-description {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.5;
}

/* Formulaires */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.form-input {
    padding: 1rem;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    transition: var(--transition);
    background: #fff;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(140, 116, 78, 0.1);
}

.form-input:invalid {
    border-color: var(--error-color);
}

.form-checkbox-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
}

.form-checkbox {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
}

.form-checkbox-label {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.4;
    cursor: pointer;
}

.form-checkbox-label a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.form-checkbox-label a:hover {
    text-decoration: underline;
}

/* Boutons */
.auth-button {
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}

.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.5s;
}

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

.auth-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px var(--shadow-color);
}

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

.auth-button:disabled {
    background: var(--text-secondary);
    cursor: not-allowed;
    transform: none;
}

.auth-button-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.auth-button-secondary:hover {
    background: var(--primary-color);
    color: white;
}

/* Liens d'authentification */
.auth-links {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
}

.auth-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

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

/* Messages d'alerte */
.auth-message {
    padding: 1rem;
    border-radius: var(--border-radius-sm);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    animation: slideDown 0.3s ease;
}

.auth-message.success {
    background: rgba(39, 174, 96, 0.1);
    color: var(--success-color);
    border: 1px solid rgba(39, 174, 96, 0.2);
}

.auth-message.error {
    background: rgba(231, 76, 60, 0.1);
    color: var(--error-color);
    border: 1px solid rgba(231, 76, 60, 0.2);
}

.auth-message.warning {
    background: rgba(243, 156, 18, 0.1);
    color: var(--warning-color);
    border: 1px solid rgba(243, 156, 18, 0.2);
}

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

/* Icônes d'état */
.status-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    font-size: 0.9rem;
    font-weight: bold;
}

.status-icon.secure {
    background: rgba(39, 174, 96, 0.1);
    color: var(--success-color);
}

.status-icon.loading {
    background: rgba(52, 152, 219, 0.1);
    color: #3498db;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Features list */
.auth-features {
    list-style: none;
    margin-top: 1.5rem;
}

.auth-features li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    color: var(--text-secondary);
}

.auth-features li::before {
    content: '✓';
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    font-size: 0.8rem;
    font-weight: bold;
    flex-shrink: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-container {
        padding: 1rem;
    }
    
    .auth-cards-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .auth-card {
        padding: 2rem 1.5rem;
    }
    
    .auth-hero-title {
        font-size: 2rem;
    }
    
    .auth-hero-subtitle {
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .auth-container {
        padding: 0.5rem;
    }
    
    .auth-card {
        padding: 1.5rem 1rem;
    }
    
    .auth-hero-title {
        font-size: 1.8rem;
    }
    
    .form-input {
        padding: 0.875rem;
    }
    
    .auth-button {
        padding: 0.875rem 1.5rem;
    }
}

/* Animation d'entrée */
.auth-card,
.auth-hero {
    animation: fadeInUp 0.6s ease-out forwards;
}

.auth-card:nth-child(2) {
    animation-delay: 0.2s;
}

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

/* Modales de bienvenue */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

.welcome-modal-content {
    background: white;
    padding: 3rem 2rem;
    border-radius: var(--border-radius);
    max-width: 500px;
    width: 90%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideInScale 0.4s ease;
}

.welcome-modal h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.8rem;
}

.welcome-modal p {
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

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

@keyframes slideInScale {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Responsive Grid pour les boxes en ligne */
@media (max-width: 1024px) {
    .register-grid {
        grid-template-columns: 1fr !important;
        gap: 2em !important;
    }
}

@media (max-width: 768px) {
    .register-grid {
        padding: 1em !important;
    }
}

/* ==============================================
   STYLES PREMIUM SPÉCIFIQUES (Index.html style)
   ============================================== */

/* Hero Section Premium avec particules */
.auth-hero {
    background: linear-gradient(135deg, 
        rgba(140, 116, 78, 0.1) 0%, 
        rgba(184, 153, 107, 0.05) 25%, 
        rgba(212, 165, 116, 0.1) 50%, 
        rgba(140, 116, 78, 0.05) 75%, 
        rgba(184, 153, 107, 0.1) 100%);
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

/* Particules d'arrière-plan */
.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 50%;
    opacity: 0.6;
    animation: float 4s infinite ease-in-out;
}

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

/* Icône d'authentification */
.auth-icon {
    background: var(--premium-gradient);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    box-shadow: 0 4px 16px var(--shadow-color);
}

.auth-emoji {
    font-size: 2rem;
}

/* Titres d'authentification */
.auth-title {
    font-size: 2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0 0 0.5rem 0;
    text-align: center;
}

.auth-subtitle {
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 2rem;
}

/* Cartes d'authentification améliorées */
.auth-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(140, 116, 78, 0.2);
    box-shadow: 0 8px 32px rgba(140, 116, 78, 0.1);
    border-radius: var(--border-radius);
    padding: 2.5rem;
    position: relative;
    z-index: 2;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--premium-gradient);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

/* Formulaire premium */
.premium-form {
    position: relative;
    z-index: 2;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.half-width {
    margin-bottom: 0 !important;
}

/* Formulaires améliorés */
.form-group label {
    display: block;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.form-group input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(140, 116, 78, 0.1);
}

/* Bouton d'authentification */
.btn-submit {
    width: 100%;
    background: var(--premium-gradient);
    border: none;
    color: white;
    font-weight: 600;
    font-size: 1rem;
    padding: 0.875rem 1.5rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.btn-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(140, 116, 78, 0.2);
}

/* Options et footer */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1.5rem 0;
    flex-wrap: wrap;
    gap: 1rem;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
    cursor: pointer;
}

.auth-footer {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(140, 116, 78, 0.1);
}

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

.auth-footer a:hover, .forgot-password:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Info card premium */
.premium-info {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(140, 116, 78, 0.2);
    position: relative;
    z-index: 2;
}

.premium-feature {
    padding: 1rem;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
}

.premium-feature:hover {
    background: rgba(140, 116, 78, 0.05);
    transform: translateY(-2px);
}

.premium-feature .feature-icon {
    font-size: 1.5rem;
    margin-right: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background: var(--premium-gradient);
    border-radius: 50%;
    color: white;
    text-align: center;
}

/* Footer section premium */
.premium-footer-section {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    color: var(--text-light);
    position: relative;
    z-index: 2;
}

.premium-footer-section .footer-logo-icon {
    font-size: 2rem;
    margin-right: 0.5rem;
}

/* Responsive premium */
@media (max-width: 768px) {
    .auth-title {
        font-size: 2rem;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .auth-icon-premium {
        width: 60px;
        height: 60px;
    }
    
    .auth-emoji {
        font-size: 2rem;
    }
}