/*====================================================
  FINAGECO - INSCRIPTION.CSS
  Plateforme de Gestion Financière & Établissements Scolaires
=====================================================*/

/*====================================================
  1. VARIABLES GLOBALES & RESET
=====================================================*/
:root {
    /* Couleurs principales FINAGECO */
    --primary: #0A2C70;
    --primary-dark: #071E4D;
    --primary-light: #1547B5;
    --secondary: #FF7A00;
    --secondary-dark: #F06A00;
    --secondary-light: #FF9838;
    --accent-blue: #2570FF;
    --blue-light: #5A7DFF;

    --primary-blue: #0b4c8c;
    --primary-blue-hover: #083868;
    --secondary-blue: #004bb5;
    --accent-orange: #ff6b00;
    --accent-orange-hover: #e05e00;
    --dark-bg: #0d233a;
    --light-bg: #f8fafc;
    --border-color: #9e743d;
    --transition: all 0.3s ease;
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --container-width: 1240px;

    /* Couleurs neutres & fonds */
    --white: #FFFFFF;
    --light: #F4F7FC;
    --gray: #EEF2F8;
    --gray-light: #F9FAFD;
    --border: #9e743d;
    --border-hover: #CBD5E1;
    --text: #1F2937;
    --text-dark: #0F172A;
    --text-light: #64748B;
    --text-muted: #48576b;
    --success: #22C55E;
    --success-dark: #16A34A;
    --danger: #EF4444;

    /* Ombres FINAGECO haute définition */
    --shadow-xs: 0 2px 6px rgba(10, 44, 112, 0.04);
    --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.288);
    --shadow-md: 0 10px 25px rgba(10, 44, 112, 0.08);
    --shadow-lg: 0 20px 45px rgba(10, 44, 112, 0.12);
    --shadow-xl: 0 30px 65px rgba(10, 44, 112, 0.16);
    --shadow-card: 0 12px 35px rgba(0, 0, 0, 0.05), 0 2px 8px rgba(0, 0, 0, 0.03);
    --shadow-glow: 0 0 25px rgba(255, 122, 0, 0.35);
    --shadow-blue-glow: 0 0 25px rgba(37, 112, 255, 0.3);

    /* Arrondis */
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --radius-full: 9999px;

    /* Transitions */
    --transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.2s ease;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: var(--light);
    color: var(--text);
    overflow-x: hidden;
    min-height: 100vh;
    line-height: 1.6;
    animation: pageFade 0.6s ease-out;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--secondary);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    border: none;
    outline: none;
    cursor: pointer;
    font-family: inherit;
    background: transparent;
}

input,
select,
textarea {
    font-family: inherit;
    outline: none;
}

.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}


/*====================================================
  2. PRELOADER FINAGECO
=====================================================*/
#finageco-preloader,
#schoolead-preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--white);
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.spinner-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 22px;
}

.spinner-wrapper img {
    width: 50px;
    height: auto;
    z-index: 10;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

.circle-orange,
.circle-blue {
    position: absolute;
    border-radius: 50%;
    border: 3px solid transparent;
}

.circle-orange {
    width: 100%;
    height: 100%;
    border-top-color: var(--secondary);
    border-bottom-color: var(--secondary);
    animation: spin 1.2s linear infinite;
}

.circle-blue {
    width: 72%;
    height: 72%;
    border-left-color: var(--primary);
    border-right-color: var(--primary);
    animation: spin 1.8s linear infinite reverse;
}

.preloader-text {
    font-size: 22px;
    color: var(--primary);
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}


/*====================================================
  3. HEADER PRINCIPAL / NAVBAR
=====================================================*/
.header {
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(10, 44, 112, 0.06);
    z-index: 1000;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 75px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo img {
    width: 44px;
    height: auto;
    transition: var(--transition-fast);
}

.logo:hover img {
    transform: scale(1.05);
}

.logo-text h2 {
    font-size: 19px;
    color: var(--primary);
    margin-bottom: -3px;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.logo-text span {
    font-size: 10px;
    color: var(--text-light);
    display: block;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.navbar ul {
    display: flex;
    gap: 22px;
}

.navbar a {
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 500;
    padding: 6px 0;
    position: relative;
    transition: var(--transition-fast);
}

.navbar a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--secondary);
    transition: var(--transition-fast);
    border-radius: 2px;
}

.navbar a:hover,
.navbar a.active {
    color: var(--primary);
    font-weight: 600;
}

.navbar a:hover::after,
.navbar a.active::after {
    width: 100%;
}

.sidenav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-idemo,
.btn-login,
.btn-demo {
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    padding: 9px 16px;
    transition: var(--transition);
    text-align: center;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-idemo {
    border: 1.5px solid var(--secondary);
    color: var(--secondary);
    background: transparent;
}

.btn-idemo:hover {
    background: var(--secondary);
    color: var(--white);
    box-shadow: 0 4px 12px rgba(255, 122, 0, 0.25);
}

.btn-login {
    color: var(--primary);
    border: 1.5px solid transparent;
}

.btn-login:hover {
    background: var(--gray);
    color: var(--primary-dark);
}

.btn-demo {
    background: var(--primary);
    color: var(--white);
    border: 1.5px solid var(--primary);
    box-shadow: 0 4px 15px rgba(10, 44, 112, 0.2);
}

.btn-demo:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(10, 44, 112, 0.3);
}

.btn-demo.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
}

/* Menu Mobile Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
    z-index: 1002;
}

.menu-toggle span {
    width: 26px;
    height: 3px;
    background: var(--primary);
    border-radius: 3px;
    transition: var(--transition);
}

.menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}


/*====================================================
  4. HERO SECTION (BACKGROUND IMAGES ANIMÉES & OVERLAY)
=====================================================*/
.hero.hero-inscription {
    position: relative;
    padding: 110px 0 65px;
    min-height: 340px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: var(--primary-dark);
}

.hero-bg-animated {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    opacity: 0;
    animation: heroSlideAnim 12s infinite ease-in-out;
}

.hero-bg-slide.slide-1 {
    animation-delay: 0s;
}

.hero-bg-slide.slide-2 {
    animation-delay: 6s;
}

@keyframes heroSlideAnim {
    0% {
        opacity: 0;
        transform: scale(1);
    }
    10% {
        opacity: 0.85;
    }
    45% {
        opacity: 0.85;
        transform: scale(1.06);
    }
    55% {
        opacity: 0;
        transform: scale(1.1);
    }
    100% {
        opacity: 0;
    }
}

.hero-overlay-dark {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(7, 30, 77, 0.88) 0%, rgba(10, 44, 112, 0.82) 50%, rgba(15, 23, 42, 0.92) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    width: 100%;
    max-width: 900px;
    text-align: center;
}

.badge-hero {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 122, 0, 0.2);
    color: #FFB366;
    border: 1px solid rgba(255, 122, 0, 0.4);
    padding: 7px 18px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.8px;
    margin-bottom: 18px;
    backdrop-filter: blur(6px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.badge-hero i {
    color: var(--secondary);
}

.hero-text h1 {
    font-size: 42px;
    font-weight: 800;
    color: var(--white);
    line-height: 1.25;
    margin-bottom: 14px;
    letter-spacing: -0.5px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-text h1 span {
    color: var(--secondary);
    background: linear-gradient(135deg, var(--secondary-light), var(--secondary));
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
}


.hero-text p {
    font-size: 17px;
    color: #CBD5E1;
    line-height: 1.7;
    max-width: 720px;
    margin: 0 auto;
    font-weight: 400;
}


/*====================================================
  5. DISPOSITION PRINCIPALE (MAIN LAYOUT & SIDEBAR)
=====================================================*/
.main-layout {
    max-width: 1240px;
    margin: -30px auto 60px;
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 30px;
    position: relative;
    z-index: 10;
}

/* Sidebar */
.sidebar {
    position: relative;
    background: var(--white);
    padding: 35px 30px;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    border: 1px solid var(--border);
    height: fit-content;
}

.sidebar::before {
    content: "";
    position: absolute;
    width: 240px;
    height: 240px;
    background: rgba(10, 44, 112, 0.03);
    border-radius: 50%;
    top: -100px;
    right: -100px;
    pointer-events: none;
}

.sidebar::after {
    content: "";
    position: absolute;
    width: 200px;
    height: 200px;
    background: rgba(255, 122, 0, 0.04);
    border-radius: 50%;
    bottom: -80px;
    left: -80px;
    pointer-events: none;
}

.logo-section {
    display: flex;
    flex-direction: column;
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 22px;
}

.logo-section .logo {
    width: 160px;
    margin-bottom: 12px;
}

.logo-section h2 {
    font-size: 26px;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: 0.5px;
}

.logo-section h2 span {
    color: var(--secondary);
}

.logo-section p {
    margin-top: 4px;
    color: var(--text-light);
    font-size: 14px;
    font-weight: 500;
}

/* Features List */
.features {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.feature-card {
    background: var(--gray-light);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
    border: 1px solid var(--border);
}

.feature-card:hover {
    transform: translateY(-4px);
    background: var(--white);
    border-color: #FFE2C8;
    box-shadow: var(--shadow-md), 0 0 15px rgba(255, 122, 0, 0.08);
}

.feature-icon {
    min-width: 48px;
    height: 48px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 122, 0, 0.12);
    color: var(--secondary);
    font-size: 20px;
    transition: var(--transition);
}

.feature-card:hover .feature-icon {
    background: var(--secondary);
    color: var(--white);
    transform: rotate(-8deg) scale(1.05);
    box-shadow: 0 6px 15px rgba(255, 122, 0, 0.3);
}

.feature-card h3 {
    font-size: 15px;
    color: var(--primary);
    margin-bottom: 4px;
    font-weight: 700;
}

.feature-card p {
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-light);
}

.sidebar-image {
    margin-top: 30px;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.sidebar-image img {
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    animation: floatImage 6s ease-in-out infinite;
    transition: var(--transition);
}

.sidebar-image img:hover {
    transform: scale(1.02);
}


/*====================================================
  6. MAIN CONTENT, FORM CARD & PROGRESSBAR
=====================================================*/
.main-content {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.form-card {
    width: 100%;
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: 42px 45px;
    box-shadow: var(--shadow-card);
    position: relative;
    transition: var(--transition);
    border: 1px solid var(--border);
}

.form-card:hover {
    box-shadow: var(--shadow-lg);
}

.form-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 6px;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    background: linear-gradient(90deg, var(--primary) 0%, var(--accent-blue) 50%, var(--secondary) 100%);
}

/* Header Form */
.header-form {
    text-align: center;
    margin-bottom: 40px;
}

.header-form h1 {
    font-size: 28px;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 10px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.header-form h1 span {
    color: var(--secondary);
}

.header-form p {
    font-size: 15px;
    color: var(--text-light);
    max-width: 620px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Progressbar (5 Étapes) */
.progressbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 45px;
    position: relative;
    width: 100%;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 5;
    flex: 1;
    cursor: pointer;
}

.progress-step span {
    margin-top: 10px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    transition: var(--transition-fast);
    text-align: center;
}

.circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--white);
    border: 2.5px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    color: var(--text-muted);
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.progress-step:hover .circle {
    border-color: var(--secondary);
    color: var(--secondary);
    transform: scale(1.05);
}

.progress-step.active .circle {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-color: var(--primary);
    color: var(--white);
    transform: scale(1.1);
    box-shadow: 0 8px 20px rgba(10, 44, 112, 0.28);
}

.progress-step.active span {
    color: var(--primary);
    font-weight: 700;
}

.progress-step.completed .circle {
    background: linear-gradient(135deg, var(--success), var(--success-dark));
    border-color: var(--success);
    color: var(--white);
    box-shadow: 0 6px 15px rgba(34, 197, 94, 0.25);
}

.progress-step.completed span {
    color: var(--success-dark);
    font-weight: 600;
}

.progress-line {
    flex: 1;
    height: 4px;
    background: var(--border);
    margin: 0 8px;
    border-radius: 10px;
    position: relative;
    top: -14px;
    transition: var(--transition);
}

.progress-line.active {
    background: linear-gradient(90deg, var(--primary), var(--secondary));
}

/* Titles */
.section-title {
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 15px;
}

.section-title h2 {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 6px;
}

.section-title p {
    color: var(--text-light);
    font-size: 14px;
}

.step {
    animation: fadeIn 0.4s ease-out;
}

.step:not(.active) {
    display: none;
}


/*====================================================
  7. ÉLÉMENTS DE FORMULAIRE, INPUTS & VALIDATION
=====================================================*/
form {
    width: 100%;
}

.row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
    margin-bottom: 22px;
}

.form-group {
    display: flex;
    flex-direction: column;
    position: relative;
    animation: inputFade 0.4s ease-out;
}

.full-width {
    width: 100%;
    margin-bottom: 22px;
}

.form-group label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    height: 52px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--white);
    padding: 0 16px;
    font-size: 14px;
    color: var(--text-dark);
    transition: var(--transition);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.01);
}

.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover {
    border-color: var(--border-hover);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(10, 44, 112, 0.1);
    background: var(--white);
}

.form-group textarea {
    min-height: 120px;
    padding: 14px 16px;
    resize: vertical;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-muted);
    font-size: 13px;
}

.form-group select {
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%230A2C70' viewBox='0 0 16 16'%3E%3Cpath d='M1.5 5l6.5 6 6.5-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 42px;
}

/* Password Box & Strength */
.password-box {
    position: relative;
    width: 100%;
}

.password-box input {
    padding-right: 50px;
}

.toggle-password {
    position: absolute;
    top: 50%;
    right: 16px;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 16px;
    transition: var(--transition-fast);
    padding: 4px;
}

.toggle-password:hover {
    color: var(--secondary);
}

.password-strength {
    margin-top: 12px;
    margin-bottom: 22px;
}

.strength-bar {
    width: 100%;
    height: 6px;
    border-radius: 10px;
    background: #E2E8F0;
    overflow: hidden;
}

.strength-fill {
    width: 0%;
    height: 100%;
    border-radius: 10px;
    transition: var(--transition);
    background: var(--danger);
}

.strength-fill.weak { width: 33%; background: var(--danger); }
.strength-fill.medium { width: 66%; background: var(--secondary); }
.strength-fill.strong { width: 100%; background: var(--success); }

#strength-text {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: var(--text-light);
    font-weight: 500;
}

.password-rules {
    background: var(--gray-light);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 25px;
}

.password-rules h4 {
    color: var(--primary);
    margin-bottom: 10px;
    font-size: 14px;
    font-weight: 700;
}

.password-rules ul {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.password-rules li {
    color: var(--text-light);
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.password-rules li.valid {
    color: var(--success-dark);
    font-weight: 600;
}

/* Checkbox & Confirmations */
.checkbox-group {
    margin-bottom: 25px;
}

.checkbox-group label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-light);
    cursor: pointer;
}

.checkbox-group input[type="checkbox"],
.confirmation-box input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary);
    margin-top: 3px;
    cursor: pointer;
}

.checkbox-group a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: underline;
}

.checkbox-group a:hover {
    color: var(--secondary);
}

.confirmation-box {
    margin-top: 20px;
    margin-bottom: 25px;
    padding: 18px;
    background: #F0FDF4;
    border: 1.5px solid #BBF7D0;
    border-radius: var(--radius-md);
}

.confirmation-box label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 14px;
    color: var(--text-dark);
    font-weight: 500;
    cursor: pointer;
}

/* Error / Success States */
.form-group.error input,
.form-group.error select {
    border-color: var(--danger);
    background: #FEF2F2;
}

.form-group.success input,
.form-group.success select {
    border-color: var(--success);
    background: #F0FDF4;
}

.error-message {
    margin-top: 6px;
    color: var(--danger);
    font-size: 12px;
    font-weight: 500;
}

/* Security Footer in Forms */
.form-security-footer {
    margin-top: 25px;
    padding-top: 15px;
    border-top: 1px dashed var(--border);
    text-align: center;
}

.security-text {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}

.security-text i {
    color: var(--success);
}


/*====================================================
  8. BOUTONS, BADGES & CARTES DE RÉSUMÉ
=====================================================*/
.button-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-top: 35px;
    flex-wrap: wrap;
}

.btn {
    height: 52px;
    padding: 0 28px;
    border: none;
    border-radius: var(--radius-md);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.25);
    transform: skewX(-25deg);
    transition: 0.6s ease;
}

.btn:hover::before {
    left: 130%;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    box-shadow: 0 8px 20px rgba(10, 44, 112, 0.22);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 28px rgba(10, 44, 112, 0.32);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary);
    border: 1.5px solid var(--border);
}

.btn-secondary:hover {
    background: var(--gray);
    border-color: var(--border-hover);
    color: var(--primary-dark);
}

.btn-success {
    background: linear-gradient(135deg, var(--success) 0%, var(--success-dark) 100%);
    color: var(--white);
    box-shadow: 0 8px 20px rgba(34, 197, 94, 0.25);
}

.btn-success:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 28px rgba(34, 197, 94, 0.35);
}

.summary-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 22px;
    margin-bottom: 20px;
    transition: var(--transition);
    box-shadow: var(--shadow-xs);
}

.summary-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: #CBD5E1;
}

.summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 12px;
}

.summary-header h3 {
    color: var(--primary);
    font-size: 17px;
    font-weight: 700;
}

.edit-btn {
    background: rgba(255, 122, 0, 0.1);
    color: var(--secondary);
    border: none;
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 600;
    font-size: 13px;
}

.edit-btn:hover {
    background: var(--secondary);
    color: var(--white);
}

.summary-card p {
    margin-bottom: 8px;
    color: var(--text-light);
    font-size: 14px;
    line-height: 1.6;
}

.summary-card strong {
    color: var(--text-dark);
}


/*====================================================
  9. MODALES (SUCCÈS, DÉMO MULTI-ÉTAPES & PROMO)
=====================================================*/

/* 9.1 Modal de Succès (#successModal) */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(6px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 20px;
}

.modal.show {
    display: flex;
}

.modal-content {
    width: 500px;
    max-width: 100%;
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: 40px;
    text-align: center;
    animation: zoom 0.35s ease-out;
    box-shadow: var(--shadow-xl);
}

.success-icon {
    font-size: 65px;
    color: var(--success);
    margin-bottom: 18px;
}

.modal-content h2 {
    color: var(--primary);
    margin-bottom: 12px;
    font-size: 26px;
    font-weight: 800;
}

.modal-content p {
    color: var(--text-light);
    line-height: 1.6;
    font-size: 15px;
}

.email-message {
    background: #FFF7ED;
    border-left: 4px solid var(--secondary);
    padding: 16px;
    border-radius: var(--radius-sm);
    margin: 22px 0;
    text-align: left;
    color: #9A3412;
    font-size: 14px;
}

/* 9.2 Modale Démo (#demo-modal) */
.demo-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(5px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    padding: 16px;
}

.demo-overlay.active {
    opacity: 1;
    visibility: visible;
}

.demo-modal-content {
    background: var(--white);
    width: 100%;
    max-width: 780px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 92vh;
    box-shadow: var(--shadow-xl);
}

.demo-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 24px 32px;
    position: relative;
}

.close-demo {
    position: absolute;
    top: 18px;
    right: 20px;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: var(--white);
    font-size: 20px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-demo:hover {
    background: rgba(255, 255, 255, 0.3);
}

.demo-tag {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.5px;
    display: block;
    margin-bottom: 6px;
    color: var(--secondary-light);
}

.demo-header h2 {
    font-size: 22px;
    margin-bottom: 6px;
}

.demo-header p {
    font-size: 13px;
    opacity: 0.9;
    margin-bottom: 14px;
}

.demo-badges {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.demo-badges span {
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 500;
}

.demo-body {
    padding: 28px 32px;
    overflow-y: auto;
    flex: 1;
}

.demo-choices {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
}

.choice-card {
    flex: 1;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    cursor: pointer;
    transition: var(--transition);
}

.choice-card.active {
    border-color: var(--primary);
    box-shadow: 0 4px 15px rgba(10, 44, 112, 0.1);
    background: #F8FAFC;
}

.choice-card.secondary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: var(--white);
    border-color: var(--primary);
}

.choice-icon {
    font-size: 22px;
    margin-bottom: 8px;
    color: var(--secondary);
}

.choice-card.secondary .choice-icon {
    color: var(--white);
}

.choice-card h4 {
    font-size: 15px;
    margin-bottom: 4px;
}

.choice-card p {
    font-size: 12px;
    color: var(--text-light);
    line-height: 1.4;
}

.choice-card.secondary p {
    color: rgba(255, 255, 255, 0.85);
}

.choice-card a {
    color: var(--secondary-light);
    font-size: 12px;
    font-weight: bold;
    display: inline-block;
    margin-top: 6px;
}

/* Stepper Modale Démo */
.demo-stepper {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    padding-bottom: 14px;
    margin-bottom: 24px;
}

.demo-stepper .step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    opacity: 0.5;
    transition: var(--transition-fast);
}

.demo-stepper .step.active {
    opacity: 1;
    color: var(--primary);
    font-weight: 700;
}

.step-circle {
    width: 28px;
    height: 28px;
    background: var(--gray);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    color: var(--text-light);
}

.demo-stepper .step.active .step-circle {
    background: var(--primary);
    color: var(--white);
}

.demo-form-section h3 {
    font-size: 17px;
    margin-bottom: 4px;
    color: var(--text-dark);
}

.demo-form-section p {
    font-size: 13px;
    color: var(--text-light);
    margin-bottom: 18px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.input-group.full-width {
    grid-column: 1 / -1;
}

.input-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.input-group input,
.input-group select,
.input-group textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 13px;
    transition: var(--transition-fast);
}

.input-group input:focus,
.input-group select:focus,
.input-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(10, 44, 112, 0.1);
}

.phone-group {
    display: flex;
    gap: 8px;
}

.phone-group select {
    width: 40%;
}

.phone-group input {
    width: 60%;
}

.recaptcha-mock {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid #D3D3D3;
    background: #F9F9F9;
    border-radius: 6px;
    padding: 10px 14px;
    max-width: 300px;
}

.recaptcha-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--text-dark);
}

.security-notice {
    background: #EFF6FF;
    color: var(--primary);
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    margin-top: 15px;
}

.demo-footer {
    padding: 16px 32px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--gray-light);
}

.step-indicator {
    font-size: 12px;
    color: var(--text-light);
    font-weight: 600;
}

.footer-actions-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-back {
    background: var(--white);
    border: 1px solid var(--border);
    color: var(--text-dark);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
}

.link-skip {
    color: var(--text-light);
    font-size: 12px;
    text-decoration: underline;
}

.btn-continue {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 9px 20px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 700;
}

.btn-confirm {
    background: var(--success);
    color: var(--white);
    border: none;
    padding: 9px 22px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 700;
}

/* 9.3 Modale Promo Pop-up */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    padding: 20px;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background: var(--white);
    width: 100%;
    max-width: 880px;
    border-radius: var(--radius-lg);
    display: flex;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--white);
    color: var(--text-dark);
    font-size: 22px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: var(--shadow-sm);
    z-index: 10;
}

.popup-left {
    flex: 1;
    background: #FFF7ED;
}

.popup-left img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.popup-right {
    flex: 1;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}


/*====================================================
  10. WIDGETS FLOTTANTS (WHATSAPP & CHAT RAPIDE)
=====================================================*/
.widget-btn {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: none;
    color: var(--white);
    font-size: 22px;
    cursor: pointer;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    justify-content: center;
    align-items: center;
}

.widget-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* Left Widgets */
.left-widgets {
    position: fixed;
    bottom: 25px;
    left: 25px;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.calendar-btn {
    background: var(--primary);
}

.wa-trigger {
    background: #25D366;
}

.whatsapp-container {
    position: relative;
}

.wa-info-card,
.info-card.whatsapp {
    position: absolute;
    bottom: 0;
    left: 65px;
    width: 250px;
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 16px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-10px);
    transition: var(--transition);
    border: 1px solid var(--border);
}

.wa-info-card.active,
.info-card.whatsapp.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

.wa-info-card p {
    font-size: 13px;
    color: var(--text-dark);
    margin-bottom: 12px;
    font-weight: 600;
}

.whatsapp-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #25D366;
    color: var(--white);
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 13px;
}

.whatsapp-btn:hover {
    background: #20BA5A;
}

.close-wa {
    position: absolute;
    top: 8px;
    right: 10px;
    background: none;
    border: none;
    font-size: 18px;
    color: var(--text-muted);
    cursor: pointer;
}

/* Right Widgets */
.right-widgets {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 1001;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.chat-trigger-btn {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--accent-blue);
    color: var(--white);
    border: none;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(37, 112, 255, 0.4);
    position: relative;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-trigger-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 10px 25px rgba(37, 112, 255, 0.5);
}

.chat-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: var(--danger);
    color: var(--white);
    font-size: 11px;
    font-weight: bold;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--white);
}

.chat-window {
    position: absolute;
    bottom: 72px;
    right: 0;
    width: 320px;
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-xl);
    opacity: 0;
    visibility: hidden;
    transform: translateY(15px);
    transition: var(--transition);
    overflow: hidden;
    border: 1px solid var(--border);
}

.chat-window.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.chat-header {
    background: transparent;
    padding: 10px 15px 0;
    text-align: right;
}

.close-chat {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--text-muted);
    cursor: pointer;
}

.chat-body {
    padding: 0 20px 20px;
}

.chat-message {
    background: var(--gray-light);
    border: 1px solid var(--border);
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    color: var(--text-dark);
    margin-bottom: 12px;
}

.chat-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.chat-opt {
    text-decoration: none;
    border: 1.5px solid var(--accent-blue);
    color: var(--accent-blue);
    padding: 9px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    transition: var(--transition-fast);
    background: var(--white);
    text-align: center;
}

.chat-opt:hover {
    background: var(--accent-blue);
    color: var(--white);
}

/* --------------------------------------------------------------------------
   15. PROMOTIONAL POPUP MODAL (NUMÉRO 6 : AFFICHAGE REFRESH ET OUVERTURE)
   -------------------------------------------------------------------------- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
    z-index: 100000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-overlay.active {
    display: flex;
}

.finageco-modal {
    background: var(--white);
    width: 100%;
    max-width: 850px;
    border-radius: var(--radius-lg);
    display: grid;
    grid-template-columns: 1fr 1fr;
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-lg);
    animation: modalPopIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modalPopIn {
    from {
        opacity: 0;
        transform: scale(0.85) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.1);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-dark);
    transition: var(--transition);
}

.modal-close:hover {
    background: var(--accent-orange);
    color: var(--white);
}

.promo-side {
    background: linear-gradient(135deg, #0b4c8c, #002d5a);
    color: var(--white);
    padding: 40px 30px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.special-badge {
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    width: fit-content;
}

.crown-box {
    font-size: 2rem;
    margin-top: 10px;
}

.promo-label {
    font-size: 0.75rem;
    color: var(--accent-orange);
    font-weight: 800;
    letter-spacing: 1px;
}

.promo-title {
    font-size: 1.6rem;
    line-height: 1.2;
    margin: 10px 0;
}

.promo-description {
    font-size: 0.85rem;
    opacity: 0.85;
}

.promo-side .pricing {
    background: none;
    padding: 0;
    margin: 15px 0;
    display: flex;
    align-items: center;
    gap: 15px;
}

.price-item .price {
    font-size: 1.5rem;
    font-weight: 800;
}

.price-description {
    font-size: 0.72rem;
    opacity: 0.8;
}

.price-or {
    font-size: 0.8rem;
    opacity: 0.6;
}

.saving-badge {
    background: var(--accent-orange);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    font-weight: 700;
    width: fit-content;
}

.content-side {
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
}

.brand {
    font-weight: 800;
    color: var(--primary-blue);
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.content-side h2 {
    font-size: 1.05rem;
    margin-bottom: 20px;
    line-height: 1.3;
}

.content-side .features {
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
    background: none;
}

.content-side .feature {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.content-side .feature-icon {
    color: #10b981;
    font-weight: 800;
}

.content-side .feature-title {
    font-size: 0.85rem;
    font-weight: 700;
}

.content-side .feature-description {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.countdown-box {
    background: var(--light-bg);
    padding: 12px;
    border-radius: var(--radius-sm);
    margin-bottom: 15px;
}

.countdown-title {
    font-size: 0.68rem;
    font-weight: 800;
    color: var(--accent-orange);
    margin-bottom: 6px;
}

.countdown {
    display: flex;
    gap: 8px;
    align-items: center;
}

.time-box {
    text-align: center;
    background: var(--white);
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    flex: 1;
}

.time-box div {
    font-weight: 800;
    font-size: 0.9rem;
    color: var(--primary-blue);
}

.time-box span {
    font-size: 0.55rem;
    color: var(--text-muted);
}

.offer-button {
    background: var(--accent-orange);
    color: var(--white);
    border: none;
    padding: 12px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 8px;
    transition: var(--transition);
}

.offer-button:hover {
    background: var(--accent-orange-hover);
}

.later-button {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.8rem;
    cursor: pointer;
    text-align: center;
}

.later-button:hover {
    color: var(--text-dark);
}


/*====================================================
  11. FOOTER
=====================================================*/
.footer {
    background: #0F172A;
    color: var(--white);
    padding-top: 70px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
}

.footer-about img {
    width: 160px;
    margin-bottom: 18px;
}

.footer-about p {
    color: #CBD5E1;
    line-height: 1.7;
    margin-bottom: 20px;
    font-size: 14px;
}

.footer h3 {
    margin-bottom: 22px;
    font-size: 18px;
    color: var(--white);
    position: relative;
    padding-bottom: 10px;
}

.footer h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 35px;
    height: 3px;
    background: var(--secondary);
    border-radius: 2px;
}

.footer-links ul li {
    margin-bottom: 12px;
}

.footer-links ul li a {
    color: #CBD5E1;
    font-size: 14px;
    transition: var(--transition-fast);
}

.footer-links ul li a:hover {
    color: var(--secondary);
    padding-left: 5px;
}

.footer-contact p {
    color: #CBD5E1;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    font-size: 14px;
}

.footer-contact i {
    color: var(--secondary);
    margin-right: 12px;
    font-size: 16px;
    width: 20px;
}

.social-icons {
    display: flex;
    gap: 12px;
}

.social-icons a {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--white);
    transition: var(--transition-fast);
}

.social-icons a:hover {
    background: var(--secondary);
    transform: translateY(-3px);
}

.footer-bottom {
    margin-top: 50px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
    padding: 22px 0;
    color: #94A3B8;
    font-size: 13px;
}


/*====================================================
  12. SCROLLBAR, SELECTION & ANIMATIONS
=====================================================*/
::-webkit-scrollbar {
    width: 9px;
}

::-webkit-scrollbar-track {
    background: #EEF2F7;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(var(--primary), var(--secondary));
    border-radius: 20px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary);
}

::selection {
    background: var(--secondary);
    color: var(--white);
}

@keyframes pageFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes cardFade {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes inputFade {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes floatImage {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

@keyframes zoom {
    from {
        opacity: 0;
        transform: scale(0.85);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/*====================================================
  RESPONSIVE BREAKPOINTS (ADD TO BOTTOM OF INSCRIPTION.CSS)
=====================================================*/

/*----------------------------------------------------
  1. DESKTOPS / LARGE TABLETS (<= 1200px)
-----------------------------------------------------*/
@media (max-width: 1200px) {
    .container {
        padding: 0 20px;
    }

    .main-layout {
        grid-template-columns: 320px 1fr;
        gap: 20px;
        margin: -20px auto 50px;
    }

    .sidebar {
        padding: 25px 20px;
    }

    .form-card {
        padding: 35px 30px;
    }

    .finageco-modal,
    .popup-content {
        max-width: 780px;
    }

    .footer-grid {
        grid-template-columns: 1.8fr 1fr 1fr 1.4fr;
        gap: 30px;
    }
}

/*----------------------------------------------------
  2. SMALL DESKTOPS / TABLETS PAYSAGE (<= 1080px)
-----------------------------------------------------*/
@media (max-width: 1080px) {
    .main-layout {
        grid-template-columns: 1fr;
        gap: 25px;
        margin-top: 20px;
    }

    .sidebar {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        padding: 25px;
    }

    .sidebar::before,
    .sidebar::after {
        display: none;
    }

    .logo-section {
        margin-bottom: 0;
        border-bottom: none;
        padding-bottom: 0;
    }

    .features {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        grid-column: 1 / -1;
    }

    .sidebar-image {
        display: none;
    }

    .navbar ul {
        gap: 14px;
    }

    .btn-idemo,
    .btn-login,
    .btn-demo {
        padding: 8px 12px;
        font-size: 12px;
    }

    .finageco-modal {
        grid-template-columns: 1fr;
        max-width: 580px;
        max-height: 90vh;
        overflow-y: auto;
    }

    .promo-side,
    .content-side {
        padding: 28px 22px;
    }

    .popup-content {
        flex-direction: column;
        max-width: 540px;
    }

    .popup-left {
        height: 180px;
    }

    .popup-right {
        padding: 25px;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

/*----------------------------------------------------
  3. TABLETS PORTRAIT / PHABLETS (<= 768px)
-----------------------------------------------------*/
@media (max-width: 768px) {
    .header .container {
        height: 65px;
    }

    .menu-toggle {
        display: flex;
    }

    .navbar {
        position: absolute;
        top: 65px;
        left: 0;
        width: 100%;
        background: var(--white);
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
        padding: 20px;
        clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
        transition: clip-path 0.4s ease-in-out;
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    .navbar.active {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }

    .navbar ul {
        flex-direction: column;
        gap: 10px;
        text-align: left;
    }

    .sidenav {
        flex-direction: column;
        width: 100%;
        gap: 10px;
        padding-top: 15px;
        border-top: 1px solid var(--border);
    }

    .btn-idemo,
    .btn-login,
    .btn-demo {
        width: 100%;
        justify-content: center;
        padding: 10px;
        font-size: 13px;
    }

    .hero.hero-inscription {
        padding: 90px 0 45px;
        min-height: auto;
    }

    .hero-text h1 {
        font-size: 30px;
    }

    .hero-text p {
        font-size: 15px;
    }

    .sidebar {
        display: flex;
        flex-direction: column;
        padding: 20px;
    }

    .features {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .form-card {
        padding: 25px 20px;
        border-radius: var(--radius-lg);
    }

    .header-form {
        margin-bottom: 30px;
    }

    .header-form h1 {
        font-size: 22px;
    }

    .header-form p {
        font-size: 13px;
    }

    .progressbar {
        overflow-x: auto;
        gap: 12px;
        justify-content: flex-start;
        padding-bottom: 10px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .progressbar::-webkit-scrollbar {
        display: none;
    }

    .progress-step {
        min-width: 80px;
        flex: 0 0 auto;
    }

    .progress-line {
        display: none;
    }

    .circle {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }

    .row {
        grid-template-columns: 1fr;
        gap: 16px;
        margin-bottom: 16px;
    }

    .password-rules ul {
        grid-template-columns: 1fr;
    }

    .button-group {
        flex-direction: column-reverse;
        width: 100%;
        gap: 12px;
        margin-top: 25px;
    }

    .button-group .btn {
        width: 100%;
        height: 48px;
    }

    .demo-modal-content {
        max-height: 95vh;
    }

    .demo-header {
        padding: 20px;
    }

    .demo-body {
        padding: 20px;
    }

    .demo-choices {
        flex-direction: column;
        gap: 12px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .demo-footer {
        padding: 15px 20px;
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
        text-align: center;
    }

    .footer {
        padding-top: 50px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 18px;
    }

    .operator-selector-container {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .payment-inputs-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .payment-breakdown-card {
        padding: 12px 10px;
    }

    .breakdown-total-line strong {
        font-size: 14px;
    }

    .btn-pay-now {
        width: 100%;
        justify-content: center;
        padding: 10px 12px;
        font-size: 14px;
    }

    .confirmed-receipt-box {
        padding: 12px 10px;
    }

    .receipt-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }

    .btn-activate-school {
        width: 100%;
        justify-content: center;
        height: 35px;
        font-size: 14px;
    }
}

/*----------------------------------------------------
  4. MOBILES MOYENS (<= 520px)
-----------------------------------------------------*/
@media (max-width: 520px) {
    .container {
        padding: 0 16px;
    }

    .logo img {
        width: 36px;
    }

    .logo-text h2 {
        font-size: 16px;
    }

    .badge-hero {
        font-size: 11px;
        padding: 5px 14px;
    }

    .hero-text h1 {
        font-size: 24px;
    }

    .hero-text p {
        font-size: 13px;
    }

    .form-card {
        padding: 20px 14px;
        border-radius: var(--radius-md);
    }

    .header-form h1 {
        font-size: 19px;
    }

    .section-title h2 {
        font-size: 18px;
    }

    .form-group label {
        font-size: 13px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        height: 46px;
        font-size: 13px;
    }

    .form-group textarea {
        min-height: 100px;
    }

    .summary-card {
        padding: 16px;
    }

    .summary-header h3 {
        font-size: 15px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .left-widgets {
        left: 15px;
        bottom: 15px;
    }

    .right-widgets {
        right: 15px;
        bottom: 15px;
    }

    .wa-info-card,
    .info-card.whatsapp {
        left: 0;
        bottom: 60px;
        width: calc(100vw - 30px);
    }

    .chat-window {
        right: 0;
        bottom: 65px;
        width: calc(100vw - 30px);
    }

    .modal-content {
        padding: 25px 18px;
    }

    .modal-content h2 {
        font-size: 20px;
    }

    .success-icon {
        font-size: 48px;
    }

    .recaptcha-mock {
        max-width: 100%;
    }

    .phone-group {
        flex-direction: column;
    }

    .phone-group select,
    .phone-group input {
        width: 100%;
    }
}

/*----------------------------------------------------
  5. PETITS MOBILES (<= 480px)
-----------------------------------------------------*/
@media (max-width: 480px) {
    .hero.hero-inscription {
        padding: 80px 0 35px;
    }

    .hero-text h1 {
        font-size: 22px;
        line-height: 1.3;
    }

    .badge-hero {
        font-size: 10px;
        padding: 4px 10px;
        margin-bottom: 12px;
    }

    .header-form h1 {
        font-size: 18px;
    }

    .circle {
        width: 36px;
        height: 36px;
        font-size: 13px;
    }

    .progress-step span {
        font-size: 10px;
    }

    .btn {
        height: 44px;
        font-size: 13px;
        padding: 0 18px;
    }

    .feature-card {
        padding: 12px;
        gap: 10px;
    }

    .feature-icon {
        min-width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .feature-card h3 {
        font-size: 14px;
    }

    .feature-card p {
        font-size: 12px;
    }

    .confirmation-box label,
    .checkbox-group label {
        font-size: 12px;
    }

    .password-rules {
        padding: 12px 14px;
    }

    .password-rules h4 {
        font-size: 13px;
    }

    .demo-header h2 {
        font-size: 18px;
    }

    .demo-tag {
        font-size: 10px;
    }

    .finageco-modal {
        width: 100%;
        border-radius: var(--radius-md);
    }

    .promo-title {
        font-size: 1.3rem;
    }

    .price-item .price {
        font-size: 1.2rem;
    }

    .countdown {
        gap: 4px;
    }

    .time-box {
        padding: 3px 6px;
    }

    .time-box div {
        font-size: 0.8rem;
    }

    .operator-selector-container {
        grid-template-columns: 1fr;
    }

    .payment-modal-card {
        padding: 16px 8px;
    }

    .breakdown-line {
        font-size: 11px;
    }

    .breakdown-total-line {
        font-size: 13px;
    }

    .breakdown-total-line strong {
        font-size: 13px;
    }
}

/*----------------------------------------------------
  6. TRÈS PETITS ÉCRANS (<= 360px)
-----------------------------------------------------*/
@media (max-width: 360px) {
    .container {
        padding: 0 12px;
    }

    .logo-text span {
        display: none;
    }

    .hero-text h1 {
        font-size: 20px;
    }

    .badge-hero {
        font-size: 9px;
    }

    .form-card {
        padding: 16px 10px;
    }

    .header-form h1 {
        font-size: 16px;
    }

    .header-form p {
        font-size: 12px;
    }

    .circle {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .progress-step {
        min-width: 65px;
    }

    .progress-step span {
        font-size: 9px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        height: 42px;
        font-size: 12px;
        padding: 0 12px;
    }

    .toggle-password {
        right: 10px;
        font-size: 14px;
    }

    .edit-btn {
        padding: 6px 10px;
        font-size: 11px;
    }

    .btn {
        height: 42px;
        font-size: 12px;
        padding: 0 14px;
    }

    .widget-btn,
    .chat-trigger-btn {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }

    .chat-window,
    .wa-info-card,
    .info-card.whatsapp {
        width: calc(100vw - 24px);
    }

    .footer-about img {
        width: 130px;
    }

    .footer h3 {
        font-size: 16px;
    }

    .footer-bottom {
        font-size: 11px;
    }

    .operator-selector-container {
        grid-template-columns: 1fr;
    }

    .payment-modal-card {
        padding: 10px 5px;
    }

    .breakdown-line {
        font-size: 10px;
    }

    .breakdown-total-line {
        font-size: 11px;
    }

    .breakdown-total-line strong {
        font-size: 11px;
    }

}

/* Fix Font Awesome Icons rendering */
.fa, .fas, .far, .fab, .fa-solid, .fa-regular, .fa-brands {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
}

/*==========================================================================
  13. EXTENSION OFFICIELLE DU FLUX PAIEMENT & ACTIVATION (ÉTAPES 5 & 6)
  Reproduction pixel-perfect des maquettes d'adhésion FINAGECO
==========================================================================*/

/* --- Utilitaires d'Affichage & Visibilité --- */
.step-panel-hidden,
.payment-fields-hidden,
.modal-hidden {
    display: none !important;
}

.body-no-scroll {
    overflow: hidden !important;
}

.preloader-fade-out {
    opacity: 0 !important;
    pointer-events: none !important;
}

.preloader-hidden {
    display: none !important;
}

.step-indicator-title {
    display: inline-block;
    font-size: 11px;
    font-weight: 800;
    color: var(--secondary);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 6px;
}

/* --- Jauge de Mot de Passe Adaptative --- */
.strength-fill.strength-weak {
    width: 33% !important;
    background: #ef4444 !important;
}

.strength-fill.strength-medium {
    width: 66% !important;
    background: #f59e0b !important;
}

.strength-fill.strength-strong {
    width: 100% !important;
    background: #10b981 !important;
}

/*====================================================
  ÉTAPE 5 : RÈGLEMENT & VALIDATION DU PAIEMENT
=====================================================*/

/* 1. Sélecteur de Canaux & Opérateurs Télécoms */
.operator-selector-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 25px;
}

.operator-card {
    background: var(--white);
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-md);
    padding: 20px 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
    position: relative;
    user-select: none;
}

.operator-card:hover {
    border-color: #cbd5e1;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.operator-card.active {
    border-color: var(--secondary) !important;
    background: #fffcf8 !important;
    box-shadow: 0 8px 25px rgba(255, 122, 0, 0.15) !important;
    transform: translateY(-3px);
}

.operator-card.active::after {
    content: "✓";
    position: absolute;
    top: 8px;
    right: 10px;
    font-size: 12px;
    font-weight: 800;
    color: var(--secondary);
}

.operator-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    background: rgba(10, 44, 112, 0.06);
    color: var(--primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 12px;
    transition: var(--transition-fast);
}

.operator-card.active .operator-icon {
    background: rgba(255, 122, 0, 0.12);
    color: var(--secondary);
}

.operator-card h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 4px;
}

.operator-card p {
    font-size: 12px;
    color: var(--text-light);
    margin: 0;
}

/* 2. Tableau de Décomposition Financière */
.payment-breakdown-card {
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 25px;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.breakdown-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
    color: var(--text-dark);
}

.breakdown-line strong {
    font-size: 15px;
    color: var(--text-dark);
    font-weight: 700;
}

.breakdown-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 14px 0 16px;
    border: none;
}

.breakdown-total-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 16px;
    font-weight: 800;
    color: var(--primary);
}

.breakdown-total-line strong {
    font-size: 24px;
    color: var(--secondary);
    font-weight: 800;
    letter-spacing: -0.5px;
}

.breakdown-note {
    font-size: 12px;
    font-style: italic;
    color: var(--text-muted);
    margin-top: 10px;
    display: block;
}

/* 3. Grille des Champs de Saisie du Règlement */
.payment-inputs-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.card-inputs-container {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 25px;
}

/* 4. Bouton d'Action Régler (Bouton Vert Imposant) */
.payment-action-center {
    display: flex;
    justify-content: center;
    margin: 30px 0 25px;
}

.btn-pay-now {
    background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
    color: var(--white);
    border: none;
    border-radius: var(--radius-md);
    padding: 16px 36px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 10px 25px rgba(22, 163, 74, 0.35);
}

.btn-pay-now:hover {
    background: linear-gradient(135deg, #15803d 0%, #166534 100%);
    transform: translateY(-2px);
    box-shadow: 0 14px 30px rgba(22, 163, 74, 0.45);
}

.btn-pay-now:active {
    transform: scale(0.98);
}

/* 5. Bloc Reçu de Paiement Validé & Confirmé (Boîte Verte Pointillée) */
.payment-confirmed-container {
    margin: 25px 0;
    animation: fadeIn 0.4s ease-out;
}

.confirmed-badge {
    background: #dcfce7;
    color: #15803d;
    font-size: 14px;
    font-weight: 700;
    padding: 8px 16px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.confirmed-receipt-box {
    background: #f0fdf4;
    border: 1.5px dashed #22c55e;
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.receipt-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13.5px;
    color: #1e293b;
    border-bottom: 1px dashed rgba(34, 197, 94, 0.25);
    padding-bottom: 8px;
}

.receipt-row:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.receipt-row span {
    color: #475569;
    font-weight: 500;
}

.receipt-row strong {
    font-weight: 700;
    color: #0f172a;
}

.receipt-row strong.amount-green {
    color: #15803d;
    font-size: 17px;
}

.status-sandbox {
    color: #15803d;
    background: rgba(34, 197, 94, 0.15);
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 12px;
}

.receipt-nb {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(34, 197, 94, 0.3);
    font-size: 12.5px;
    font-style: italic;
    color: #166534;
    line-height: 1.5;
}

/* État désactivé du bouton Étape 5 */
.btn-next-disabled {
    opacity: 0.45 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
    background: #94a3b8 !important;
    border-color: #94a3b8 !important;
    box-shadow: none !important;
}

/*====================================================
  ÉTAPE 6 : RÉCAPITULATIF & ACTIVATION DE L'ÉCOLE
=====================================================*/
.school-slug-highlight {
    color: #004bb5 !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    text-decoration: underline;
}

.total-summary-box {
    background: #fffcf0 !important;
    border: 1.5px solid #fde68a !important;
    border-radius: var(--radius-sm);
    padding: 12px 16px !important;
}

.total-badge-green {
    font-size: 20px !important;
    font-weight: 800 !important;
    color: #b45309 !important;
}

/* Grand Bouton d'Activation Orange Final */
.btn-activate-school {
    background: linear-gradient(135deg, var(--secondary) 0%, var(--secondary-dark) 100%) !important;
    color: var(--white) !important;
    border: none !important;
    border-radius: var(--radius-md) !important;
    height: 56px !important;
    padding: 0 38px !important;
    font-size: 16px !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 12px !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 10px 25px rgba(255, 122, 0, 0.35) !important;
}

.btn-activate-school:hover {
    background: linear-gradient(135deg, var(--secondary-dark) 0%, #c2410c 100%) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 14px 30px rgba(255, 122, 0, 0.45) !important;
}

/*====================================================
  MODALE CENTRALE DE TRAITEMENT DU PAIEMENT (POPUP)
=====================================================*/
.payment-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(6px);
    z-index: 100050;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    animation: fadeIn 0.3s ease-out;
}

.payment-modal-card {
    background: var(--white);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 480px;
    padding: 40px 32px;
    text-align: center;
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(0, 0, 0, 0.08);
    animation: modalPopIn 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.payment-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid #f1f5f9;
    border-top: 4px solid var(--secondary);
    border-right: 4px solid var(--primary);
    border-radius: 50%;
    margin: 0 auto 20px;
    animation: spin 1s linear infinite;
}

.payment-modal-card h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 10px;
}

.payment-modal-card p {
    font-size: 13.5px;
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 24px;
}

.success-check-icon {
    font-size: 65px;
    color: var(--success);
    margin-bottom: 15px;
    animation: popCheck 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#btnConfirmPaymentModal {
    min-width: 140px;
    height: 46px;
    font-size: 14px;
    font-weight: 700;
    border-radius: var(--radius-sm);
}

@keyframes popCheck {
    0% { transform: scale(0.3); opacity: 0; }
    80% { transform: scale(1.15); }
    100% { transform: scale(1); opacity: 1; }
}
/*==========================================================================
  CORRECTIF OFFICIEL DE RESPONSIVITÉ & OVERFLOW MOBILE (360px - 1080px)
  Verrouillage strict du viewport et ancrage permanent du menu hamburger
==========================================================================*/

/* 1. Verrouillage strict du viewport : zéro défilement horizontal */
html,
body {
    width: 100% !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
    position: relative !important;
}

/* 2. Annulation de l'expansion forcée de CSS Grid (min-width: 0) */
.container,
.main-layout,
.main-content,
.form-card,
.sidebar,
.hero,
.hero-content,
.progressbar,
.step,
form,
.row,
.form-group,
.summary-card,
.summary-grid-list,
.payment-breakdown-card,
.confirmed-receipt-box {
    min-width: 0 !important;
    max-width: 100% !important;
}

/* 3. Sécurisation anti-débordement des textes longs et slugs */
.school-slug-highlight,
.ref-code-highlight,
.monospace-value,
.summary-item-value,
.receipt-row strong,
.receipt-row span,
.breakdown-line strong,
.breakdown-line span {
    word-break: break-all !important;
    overflow-wrap: anywhere !important;
}

/* 4. Ancrage et visibilité du menu hamburger (<= 1080px) */
@media (max-width: 1080px) {
    .header {
        width: 100% !important;
        max-width: 100vw !important;
        left: 0 !important;
        right: 0 !important;
    }

    .header .container {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 16px !important;
    }

    /* Le hamburger reste toujours visible et ancré à droite */
    .menu-toggle {
        display: flex !important;
        flex-shrink: 0 !important;
        margin-left: auto !important;
        z-index: 1002 !important;
    }

    /* Empêche les boutons sidenav de flotter dans la barre de header sur mobile */
    .header > .container > .sidenav {
        display: none !important;
    }

    .logo {
        flex-shrink: 1 !important;
        min-width: 0 !important;
    }

    .logo-text {
        min-width: 0 !important;
    }

    /* Tiroir de navigation mobile plein écran propre */
    .navbar {
        position: fixed !important;
        top: 65px !important;
        left: 0 !important;
        width: 100% !important;
        max-width: 100vw !important;
        height: calc(100vh - 65px) !important;
        overflow-y: auto !important;
        background: #ffffff !important;
        box-shadow: 0 15px 30px rgba(0, 31, 63, 0.15) !important;
        padding: 24px 20px 40px !important;
        display: flex !important;
        flex-direction: column !important;
        gap: 18px !important;
        z-index: 1001 !important;
        transform: translateY(-120%) !important;
        transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1) !important;
        clip-path: none !important;
    }

    .navbar.active {
        transform: translateY(0) !important;
    }

    .navbar ul {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 8px !important;
    }

    .navbar ul li a {
        display: block !important;
        font-size: 15px !important;
        padding: 10px 0 !important;
        border-bottom: 1px solid #f1f5f9 !important;
    }

    /* Boutons d'action dans le tiroir mobile */
    .navbar .sidenav {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
        gap: 10px !important;
        padding-top: 15px !important;
        border-top: 2px solid #e2e8f0 !important;
    }

    .navbar .sidenav a {
        width: 100% !important;
        justify-content: center !important;
        height: 46px !important;
        font-size: 14px !important;
    }
}

/* 5. Ajustements pour écrans mobiles (<= 768px) */
@media (max-width: 768px) {
    .container {
        padding: 0 16px !important;
    }

    .hero.hero-inscription {
        width: 100% !important;
        padding: 85px 0 35px !important;
    }

    .hero-text h1 {
        font-size: 24px !important;
        line-height: 1.3 !important;
    }

    .main-layout {
        margin: 15px auto 40px !important;
        gap: 20px !important;
        width: 100% !important;
    }

    .sidebar {
        padding: 20px 16px !important;
    }

    .form-card {
        padding: 20px 14px !important;
    }

    /* Défilement horizontal fluide de la barre de progression sans casser la page */
    .progressbar {
        width: 100% !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        display: flex !important;
        justify-content: flex-start !important;
        gap: 10px !important;
        padding-bottom: 8px !important;
        -webkit-overflow-scrolling: touch !important;
    }

    .progress-step {
        flex: 0 0 72px !important;
        min-width: 72px !important;
    }

    .progress-line {
        display: none !important;
    }

    .button-group {
        flex-direction: column-reverse !important;
        gap: 12px !important;
    }

    .button-group .btn,
    .btn-activate-school {
        width: 100% !important;
    }
}

/* 6. Ajustements fins pour petits smartphones (<= 480px et <= 360px) */
@media (max-width: 480px) {
    .header .container {
        height: 60px !important;
        padding: 0 12px !important;
    }

    .logo img {
        width: 34px !important;
    }

    .logo-text h2 {
        font-size: 15px !important;
    }

    .hero-text h1 {
        font-size: 21px !important;
    }

    .btn-activate-school {
        height: auto !important;
        min-height: 50px !important;
        font-size: 14px !important;
        padding: 12px 16px !important;
        white-space: normal !important;
        line-height: 1.3 !important;
        text-align: center !important;
    }
}

@media (max-width: 360px) {
    .logo-text span {
        display: none !important;
    }

    .header .container {
        padding: 0 10px !important;
    }

    .form-card {
        padding: 16px 10px !important;
    }
}
