/* ═══════════════════════════════════════════════════════════════
   DiagImmo.fr — Light Theme Premium
   Design system : blanc, bleu, douceur, ombres subtiles
═══════════════════════════════════════════════════════════════ */

/* ─── Variables ──────────────────────────────────────────────── */
:root {
    --primary:      #0f3460;
    --primary-light:#1a5276;
    --accent:       #e94560;
    --accent-dark:  #c73652;
    --bg-body:      #f1f5fb;
    --bg-card:      #ffffff;
    --bg-section:   #f8faff;
    --border:       #e2e8f0;
    --border-hover: #c7d2e1;
    --text-primary: #1e293b;
    --text-muted:   #64748b;
    --text-light:   #94a3b8;
    --shadow-sm:    0 1px 3px rgba(15,52,96,0.06), 0 1px 2px rgba(15,52,96,0.04);
    --shadow-md:    0 4px 16px rgba(15,52,96,0.08), 0 2px 6px rgba(15,52,96,0.05);
    --shadow-lg:    0 10px 40px rgba(15,52,96,0.12), 0 4px 12px rgba(15,52,96,0.06);
    --shadow-xl:    0 20px 60px rgba(15,52,96,0.15), 0 8px 24px rgba(15,52,96,0.08);
}

/* ─── Reset & Base ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    background: var(--bg-body);
    color: var(--text-primary);
    font-family: 'Inter', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}

/* ─── Navigation ─────────────────────────────────────────────── */
.nav-glass {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border) !important;
    box-shadow: var(--shadow-sm);
}

/* ─── Hero Section ───────────────────────────────────────────── */
.hero-light {
    background: linear-gradient(135deg, #eef4ff 0%, #f0f7ff 40%, #f5efff 100%);
    position: relative;
    overflow: hidden;
}

/* ─── Card premium ───────────────────────────────────────────── */
.glass-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    border-radius: 1rem;
}

/* ─── Gradient Text ──────────────────────────────────────────── */
.gradient-text {
    background: linear-gradient(135deg, #0f3460 0%, #1d6fa4 50%, #e94560 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ─── Blobs (Hero) ───────────────────────────────────────────── */
.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.12;
    animation: blob-float 10s ease-in-out infinite;
    pointer-events: none;
}
.blob-1 {
    width: 500px; height: 500px;
    background: radial-gradient(circle, #93c5fd, transparent);
    top: -100px; right: -100px; animation-delay: 0s;
}
.blob-2 {
    width: 400px; height: 400px;
    background: radial-gradient(circle, #fca5a5, transparent);
    bottom: -50px; left: -80px; animation-delay: 3s;
}
.blob-3 {
    width: 350px; height: 350px;
    background: radial-gradient(circle, #c4b5fd, transparent);
    top: 40%; left: 40%; animation-delay: 5s;
}
@keyframes blob-float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33%       { transform: translate(20px, -20px) scale(1.05); }
    66%       { transform: translate(-15px, 10px) scale(0.97); }
}

/* ─── Grid pattern ───────────────────────────────────────────── */
.bg-grid-pattern {
    background-image:
        linear-gradient(rgba(15,52,96,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15,52,96,0.04) 1px, transparent 1px);
    background-size: 60px 60px;
}

/* ─── Animations ─────────────────────────────────────────────── */
@keyframes fade-in  { from { opacity: 0; } to { opacity: 1; } }
@keyframes slide-up { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

.animate-fade-in     { animation: fade-in  0.5s ease forwards; }
.animate-slide-up    { animation: slide-up 0.6s ease forwards; }
.animation-delay-100 { animation-delay: 0.1s; opacity: 0; }
.animation-delay-200 { animation-delay: 0.2s; opacity: 0; }
.animation-delay-300 { animation-delay: 0.3s; opacity: 0; }

/* ─── Counter ────────────────────────────────────────────────── */
.counter { transition: color 0.3s; }

/* ─── Form inputs ────────────────────────────────────────────── */
.form-input {
    background-color: #f8fafc !important;
    border: 1.5px solid var(--border) !important;
    color: var(--text-primary) !important;
    border-radius: 0.75rem;
    transition: border-color 0.2s, background-color 0.2s, box-shadow 0.2s;
}
.form-input::placeholder { color: #94a3b8; }
.form-input:focus {
    border-color: #0f3460 !important;
    background-color: #fff !important;
    box-shadow: 0 0 0 3px rgba(15, 52, 96, 0.08) !important;
    outline: none;
}
.form-input option { background: #fff; color: var(--text-primary); }

select.form-input {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 40px;
}

/* ─── Cards ──────────────────────────────────────────────────── */
.diag-card {
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.diag-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: #93c5fd;
}

.certif-card {
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.certif-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

/* ─── Stat card ──────────────────────────────────────────────── */
.stat-card {
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}
.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* ─── Dropdown ───────────────────────────────────────────────── */
.dropdown-menu {
    background: var(--bg-card);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-xl);
    transform-origin: top left;
    transition: opacity 0.15s ease, visibility 0.15s ease;
}

/* ─── FAQ ────────────────────────────────────────────────────── */
.faq-item {
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    transition: border-color 0.2s, box-shadow 0.2s;
}
.faq-item:hover { border-color: var(--border-hover); box-shadow: var(--shadow-sm); }
.faq-btn:hover  { background: #f8fafc; }
.faq-icon       { transition: transform 0.2s ease; }
.faq-btn[aria-expanded="true"] .faq-icon { transform: rotate(180deg); }
.faq-answer { animation: slide-up 0.2s ease; }

/* ─── Badge certifié ─────────────────────────────────────────── */
.badge-certified {
    background: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
}

/* ─── Prose (guides) ─────────────────────────────────────────── */
.prose-custom { color: var(--text-primary); line-height: 1.8; font-size: 1.05rem; }
.prose-custom h2 { color: var(--primary); font-size: 1.5rem; font-weight: 700; margin: 2rem 0 1rem; font-family: 'Plus Jakarta Sans', sans-serif; }
.prose-custom h3 { color: #1e293b; font-size: 1.2rem; font-weight: 600; margin: 1.5rem 0 0.75rem; }
.prose-custom p  { margin-bottom: 1.2rem; }
.prose-custom ul { margin-bottom: 1.2rem; padding-left: 1.5rem; }
.prose-custom li { margin-bottom: 0.5rem; list-style: disc; }
.prose-custom strong { color: var(--primary); }
.prose-custom a  { color: #0f3460; text-decoration: underline; }
.prose-custom table { width: 100%; border-collapse: collapse; margin-bottom: 1.5rem; border-radius: 0.75rem; overflow: hidden; border: 1px solid var(--border); }
.prose-custom th { background: #f1f5f9; color: #1e293b; padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--border); font-weight: 600; }
.prose-custom td { padding: 10px 16px; border-bottom: 1px solid #f1f5f9; }
.prose-custom tr:last-child td { border-bottom: none; }

/* ─── Scrollbar custom ───────────────────────────────────────── */
::-webkit-scrollbar       { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ─── Loading spinner ────────────────────────────────────────── */
.spinner {
    display: inline-block;
    width: 18px; height: 18px;
    border: 2px solid rgba(255,255,255,0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Breadcrumb ─────────────────────────────────────────────── */
.breadcrumb {
    background: #f8fafc;
    border-bottom: 1px solid var(--border);
    font-size: 0.8rem;
}

/* ─── Responsive tweaks ──────────────────────────────────────── */
@media (max-width: 640px) {
    .blob-1, .blob-2, .blob-3 { width: 250px; height: 250px; }
}

/* ─── Section alternée ───────────────────────────────────────── */
.section-alt { background: var(--bg-section); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

/* ─── Hero gradient CTA section ─────────────────────────────── */
.cta-gradient {
    background: linear-gradient(135deg, #0f3460 0%, #1a5276 50%, #0f3460 100%);
}

/* ─── Ville card ─────────────────────────────────────────────── */
.ville-card {
    background: var(--bg-card);
    border: 1.5px solid var(--border);
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
}
.ville-card:hover {
    border-color: #93c5fd;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}
