/* ============================================================
   HSE VOICE — Pages d'authentification
   ============================================================ */

:root {
    --primary: #1e40af;
    --primary-hover: #1e3a8a;
    --primary-light: #3b82f6;
    --primary-subtle: #eff6ff;

    --bg: #f8fafc;
    --card: #ffffff;
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
    --hover: #f1f5f9;

    --text: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --text-light: #94a3b8;

    --success: #059669;
    --success-bg: #ecfdf5;
    --danger: #dc2626;
    --danger-bg: #fef2f2;

    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow: 0 1px 3px rgba(15, 23, 42, 0.08), 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 4px 6px rgba(15, 23, 42, 0.06), 0 2px 4px rgba(15, 23, 42, 0.04);
    --shadow-lg: 0 20px 25px rgba(15, 23, 42, 0.08), 0 10px 10px rgba(15, 23, 42, 0.04);

    --radius-sm: 6px;
    --radius: 8px;
    --radius-md: 10px;
    --radius-lg: 12px;

    --transition: all 0.15s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%);
    color: var(--text);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* ============================================================
   CONTENEUR
   ============================================================ */

.auth-container {
    width: 100%;
    max-width: 440px;
}

.auth-card {
    background: var(--card);
    border-radius: var(--radius-lg);
    padding: 40px 32px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
}

/* ============================================================
   WORDMARK LOGO
   ============================================================ */

.auth-header {
    text-align: center;
    margin-bottom: 28px;
}

.auth-logo {
    display: inline-block;
    font-family: 'Inter', -apple-system, sans-serif;
    font-size: 26px;
    font-weight: 900;
    font-style: italic;
    letter-spacing: -1.8px;
    text-decoration: none;
    margin-bottom: 10px;
    line-height: 1;
}

.auth-logo .hse {
    color: var(--text);
}

.auth-logo .voice {
    color: var(--primary);
}

.tagline {
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 400;
}

/* ============================================================
   SÉLECTEUR DE LANGUE
   ============================================================ */

.lang-selector {
    display: flex;
    gap: 6px;
    margin-bottom: 24px;
    justify-content: center;
}

.lang-btn {
    flex: 1;
    padding: 8px 6px;
    background: var(--card);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: var(--transition);
    font-family: inherit;
}

.lang-btn:hover {
    background: var(--hover);
    color: var(--text);
    border-color: var(--border-strong);
}

.lang-btn.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    font-weight: 600;
}

/* ============================================================
   ONGLETS
   ============================================================ */

.auth-tabs {
    display: flex;
    background: var(--bg);
    border-radius: var(--radius);
    padding: 4px;
    margin-bottom: 24px;
    border: 1px solid var(--border);
}

.auth-tab {
    flex: 1;
    padding: 10px;
    background: transparent;
    color: var(--text-muted);
    border: none;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}

.auth-tab:hover {
    color: var(--text);
}

.auth-tab.active {
    background: var(--card);
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

/* ============================================================
   FORMULAIRES
   ============================================================ */

.auth-form { display: none; }
.auth-form.active { display: block; }

.field { margin-bottom: 16px; }

.field label {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 6px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.field input {
    width: 100%;
    padding: 11px 14px;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: var(--transition);
}

.field input::placeholder {
    color: var(--text-light);
}

.field input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

/* ============================================================
   BOUTON PRINCIPAL
   ============================================================ */

.btn-primary {
    width: 100%;
    padding: 12px;
    background: var(--primary);
    color: #fff;
    border: none;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 8px;
    transition: var(--transition);
    font-family: inherit;
    letter-spacing: 0.2px;
}

.btn-primary:hover {
    background: var(--primary-hover);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ============================================================
   MESSAGES
   ============================================================ */

.error-msg {
    margin-top: 14px;
    color: var(--danger);
    font-size: 13px;
    text-align: center;
    min-height: 20px;
    font-weight: 500;
    line-height: 1.5;
}

.error-msg.success {
    color: var(--success);
}

/* ============================================================
   FOOTER
   ============================================================ */

.auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    font-size: 13px;
}

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

.auth-footer a:hover {
    color: var(--primary);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 500px) {
    .auth-card {
        padding: 32px 24px;
    }
    .auth-logo {
        font-size: 22px;
    }
}