/* ============================================================
   DBT — Digital Business Tech
   Charte : Noir & Bleu Nuit (mode sombre) / Blanc & Bleu Clair (mode clair)
   Palette dérivée du logo DBT (#345EA9 / #243367)
   ============================================================ */

:root {
    /* --- Mode sombre (par défaut) : Noir & Bleu Nuit --- */
    --bg: #05070c;
    --bg-elevated: #0b1220;
    --card-bg: rgba(18, 27, 48, 0.6);
    --card-border: rgba(74, 122, 201, 0.18);
    --nav-bg: rgba(5, 7, 12, 0.85);
    --overlay-top: rgba(5, 7, 12, 0.94);
    --overlay-bottom: rgba(10, 16, 32, 0.88);

    --ink: #f3f6fc;
    --ink-muted: #93a3bf;
    --ink-faint: #5b6a87;

    --blue-deep: #1b2c56;      /* bleu nuit */
    --blue-primary: #4c86dd;   /* bleu électrique (accent principal) */
    --blue-primary-hover: #6ea0ea;
    --blue-glow: rgba(76, 134, 221, 0.35);

    --shadow: rgba(0, 0, 0, 0.55);
    --pixel-color: rgba(76, 134, 221, 0.9);

    --font-display: 'Sora', sans-serif;
    --font-body: 'Inter', sans-serif;
}

/* --- Mode clair : Blanc & Bleu Clair --- */
body.light-mode {
    --bg: #eef3fb;
    --bg-elevated: #ffffff;
    --card-bg: rgba(255, 255, 255, 0.85);
    --card-border: rgba(52, 94, 169, 0.18);
    --nav-bg: rgba(255, 255, 255, 0.85);
    --overlay-top: rgba(238, 243, 251, 0.96);
    --overlay-bottom: rgba(220, 232, 250, 0.9);

    --ink: #0e1a30;
    --ink-muted: #4b5a74;
    --ink-faint: #7c8aa3;

    --blue-deep: #dbe6f8;
    --blue-primary: #2e5aa8;
    --blue-primary-hover: #1f437f;
    --blue-glow: rgba(46, 90, 168, 0.18);

    --shadow: rgba(46, 90, 168, 0.12);
    --pixel-color: rgba(46, 90, 168, 0.55);
}

/* ============================================================
   Reset & base
   ============================================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--ink);
    background-color: var(--bg);
    background-image: linear-gradient(var(--overlay-top), var(--overlay-bottom)), url('background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    line-height: 1.65;
    transition: background-color 0.35s ease, color 0.35s ease;
}

body.light-mode {
    background-image: linear-gradient(var(--overlay-top), var(--overlay-bottom)), url('background.jpg');
}

a {
    color: inherit;
}

::selection {
    background-color: var(--blue-primary);
    color: #ffffff;
}

:focus-visible {
    outline: 2px solid var(--blue-primary);
    outline-offset: 3px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}

/* ============================================================
   Motif signature : le pixel-mark (repris du logo DBT)
   ============================================================ */
.pixel-mark {
    display: inline-grid;
    grid-template-columns: repeat(2, 6px);
    grid-template-rows: repeat(2, 6px);
    gap: 3px;
    width: 15px;
    height: 15px;
    flex-shrink: 0;
}

.pixel-mark span {
    background-color: var(--pixel-color);
    border-radius: 1px;
}

.pixel-mark span:nth-child(1) { transform: translate(0, 0); }
.pixel-mark span:nth-child(2) { transform: translate(1px, -1px); opacity: 0.7; }
.pixel-mark span:nth-child(3) { transform: translate(-1px, 1px); opacity: 0.55; }
.pixel-mark span:nth-child(4) { opacity: 0.85; }

/* Eyebrow réutilisable : pixel-mark + libellé */
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--blue-primary);
    font-weight: 600;
    font-size: 13px;
    font-family: var(--font-display);
}

/* ============================================================
   Structure réutilisable
   ============================================================ */
.section-header {
    text-align: center;
    margin-bottom: 55px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.section-header h2 {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 36px;
    letter-spacing: -0.5px;
    color: var(--ink);
}

.divider {
    width: 48px;
    height: 3px;
    background-color: var(--blue-primary);
    border-radius: 2px;
}

/* ============================================================
   Boutons
   ============================================================ */
.btn-primary {
    display: inline-block;
    background-color: var(--blue-primary);
    color: #ffffff;
    padding: 14px 32px;
    text-decoration: none;
    font-weight: 600;
    font-family: var(--font-display);
    border-radius: 10px;
    transition: all 0.25s ease;
    box-shadow: 0 8px 24px var(--blue-glow);
    border: none;
    cursor: pointer;
    font-size: 15px;
}

.btn-primary:hover {
    transform: translateY(-3px);
    background-color: var(--blue-primary-hover);
    box-shadow: 0 12px 30px var(--blue-glow);
}

.btn-secondary {
    display: inline-block;
    background-color: transparent;
    color: var(--ink);
    padding: 14px 32px;
    text-decoration: none;
    font-weight: 600;
    font-family: var(--font-display);
    border-radius: 10px;
    border: 2px solid var(--card-border);
    margin-left: 15px;
    transition: all 0.25s ease;
    font-size: 15px;
}

.btn-secondary:hover {
    border-color: var(--blue-primary);
    color: var(--blue-primary);
    transform: translateY(-3px);
}

/* ============================================================
   Navigation & Logo
   ============================================================ */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 8%;
    background-color: var(--nav-bg);
    backdrop-filter: blur(12px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--card-border);
    transition: background-color 0.35s ease, border-color 0.35s ease;
}

.logo-container {
    display: flex;
    align-items: center;
}

.nav-logo {
    height: 42px;
    width: auto;
    display: block;
    transition: transform 0.3s ease;
}

body.light-mode .nav-logo {
    filter: none;
}

.nav-links {
    display: flex;
    list-style: none;
    align-items: center;
}

.nav-links li a {
    color: var(--ink);
    text-decoration: none;
    font-weight: 600;
    margin: 0 18px;
    font-size: 15px;
    font-family: var(--font-display);
    transition: color 0.25s;
}

.nav-links li a:hover {
    color: var(--blue-primary);
}

.btn-nav {
    border: 1px solid var(--blue-primary);
    padding: 8px 22px !important;
    border-radius: 20px;
    margin-left: 15px !important;
}

.btn-nav:hover {
    background-color: var(--blue-primary);
    color: #ffffff !important;
}

/* Conteneur interrupteur + burger */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 18px;
}

/* --- Interrupteur mode sombre / clair --- */
.theme-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 54px;
    height: 30px;
    cursor: pointer;
    flex-shrink: 0;
}

.theme-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.switch-slider {
    position: absolute;
    inset: 0;
    background-color: rgba(76, 134, 221, 0.12);
    border: 2px solid var(--blue-primary);
    border-radius: 30px;
    transition: background-color 0.3s ease;
}

.switch-slider .switch-icon {
    position: absolute;
    top: 50%;
    left: 3px;
    width: 20px;
    height: 20px;
    background-color: var(--blue-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    line-height: 1;
    transform: translateY(-50%);
    transition: transform 0.3s ease, background-color 0.3s ease;
    box-shadow: 0 2px 8px var(--shadow);
}

.theme-switch input:checked ~ .switch-slider .switch-icon {
    transform: translateY(-50%) translateX(24px);
}

.theme-switch:hover .switch-slider {
    box-shadow: 0 0 12px var(--blue-glow);
}

/* ============================================================
   Hero
   ============================================================ */
.hero-section {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-tagline {
    justify-content: center;
    margin-bottom: 18px;
}

.hero-content h1 {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 58px;
    margin-bottom: 22px;
    line-height: 1.1;
    letter-spacing: -1.5px;
    color: var(--ink);
}

.hero-content p {
    font-size: 19px;
    max-width: 680px;
    margin: 0 auto 38px auto;
    color: var(--ink-muted);
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.hero-buttons .btn-secondary {
    margin-left: 0;
}

/* Halo décoratif de pixels flottants dans le hero */
.hero-section::before,
.hero-section::after {
    content: "";
    position: absolute;
    width: 340px;
    height: 340px;
    background-image:
        radial-gradient(circle, var(--pixel-color) 2px, transparent 2.5px);
    background-size: 34px 34px;
    opacity: 0.35;
    z-index: 1;
    animation: driftPixels 18s ease-in-out infinite;
}

.hero-section::before {
    top: 8%;
    left: 4%;
}

.hero-section::after {
    bottom: 6%;
    right: 4%;
    animation-delay: -9s;
}

@keyframes driftPixels {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(18px, -22px); }
}

/* ============================================================
   Section À Propos
   ============================================================ */
.about-section {
    padding: 110px 8%;
}

.about-lead {
    max-width: 850px;
    margin: 0 auto;
    font-size: 17px;
    color: var(--ink-muted);
}

.about-lead strong {
    color: var(--ink);
}

.mv-container {
    display: flex;
    gap: 40px;
    margin-top: 60px;
}

.mv-card {
    flex: 1;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 20px 40px var(--shadow);
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.mv-card:hover {
    transform: translateY(-6px);
    border-color: var(--blue-primary);
}

.card-icon {
    font-size: 32px;
    margin-bottom: 15px;
}

.mv-card h3 {
    font-family: var(--font-display);
    font-size: 21px;
    font-weight: 700;
    color: var(--blue-primary);
    margin-bottom: 15px;
}

.mv-card p {
    color: var(--ink-muted);
}

/* Valeurs */
.values-wrapper {
    margin-top: 75px;
    text-align: center;
}

.values-wrapper h3 {
    font-family: var(--font-display);
    font-size: 23px;
    font-weight: 700;
    margin-bottom: 35px;
    color: var(--ink);
}

.values-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
}

.value-item {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 14px 24px;
    border-radius: 30px;
    font-size: 14px;
    color: var(--ink-muted);
    transition: border-color 0.25s ease;
}

.value-item:hover {
    border-color: var(--blue-primary);
}

.value-item strong {
    color: var(--blue-primary);
    margin-right: 5px;
    font-family: var(--font-display);
}

/* ============================================================
   Nos Offres de Services
   ============================================================ */
.services-section {
    padding: 110px 8%;
    background: transparent;
}

.services-container {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.service-card {
    flex: 1;
    min-width: 300px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 40px 32px;
    border-radius: 16px;
    transition: all 0.3s ease;
}

.service-card:hover {
    transform: translateY(-10px);
    border-color: var(--blue-primary);
    box-shadow: 0 20px 45px var(--blue-glow);
}

.service-icon {
    font-size: 36px;
    margin-bottom: 20px;
}

.service-card h3 {
    font-family: var(--font-display);
    font-size: 21px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--ink);
    border-bottom: 1px solid var(--card-border);
    padding-bottom: 14px;
}

.service-card ul {
    list-style: none;
    text-align: left;
}

.service-card ul li {
    margin-bottom: 12px;
    color: var(--ink-muted);
    position: relative;
    padding-left: 20px;
    font-size: 15px;
}

.service-card ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 6px;
    height: 6px;
    background-color: var(--blue-primary);
    border-radius: 1px;
}

/* ============================================================
   Section Cibles & Positionnement
   ============================================================ */
.targets-section {
    padding: 110px 8%;
}

.targets-container {
    display: flex;
    gap: 60px;
    background: var(--card-bg);
    padding: 55px;
    border-radius: 22px;
    border: 1px solid var(--card-border);
}

.targets-left, .targets-right {
    flex: 1;
}

.targets-container h2 {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 30px;
    margin-bottom: 20px;
    color: var(--blue-primary);
}

.targets-container > div > p {
    color: var(--ink-muted);
}

.styled-list {
    list-style: none;
    margin-top: 20px;
}

.styled-list li {
    padding: 11px 0;
    border-bottom: 1px solid var(--card-border);
    color: var(--ink-muted);
}

.diff-box {
    margin-top: 25px;
    background: var(--bg-elevated);
    padding: 25px;
    border-radius: 14px;
    border-left: 4px solid var(--blue-primary);
}

.diff-box h4 {
    margin-bottom: 15px;
    font-family: var(--font-display);
    color: var(--ink);
}

.diff-box ul {
    list-style: none;
}

.diff-box ul li {
    margin-bottom: 8px;
    font-size: 15px;
    color: var(--ink-muted);
}

/* ============================================================
   Section Contact
   ============================================================ */
.contact-section {
    padding: 110px 8%;
}

#contact-form {
    max-width: 700px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.form-row {
    display: flex;
    gap: 18px;
}

.form-row input {
    flex: 1;
}

#contact-form input, #contact-form textarea {
    width: 100%;
    padding: 17px 18px;
    background-color: var(--bg-elevated);
    border: 1px solid var(--card-border);
    color: var(--ink);
    border-radius: 10px;
    font-family: var(--font-body);
    font-size: 15px;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

#contact-form input::placeholder,
#contact-form textarea::placeholder {
    color: var(--ink-faint);
}

#contact-form input:focus, #contact-form textarea:focus {
    outline: none;
    border-color: var(--blue-primary);
    box-shadow: 0 0 0 4px var(--blue-glow);
}

#contact-form button {
    align-self: center;
}

/* ============================================================
   Footer
   ============================================================ */
footer {
    text-align: center;
    padding: 40px;
    border-top: 1px solid var(--card-border);
    font-size: 14px;
    color: var(--ink-faint);
}

/* ============================================================
   Menu Burger Mobile
   ============================================================ */
.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 24px;
    height: 2px;
    background-color: var(--ink);
    margin: 5px;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.burger.toggle .line1 {
    transform: rotate(45deg) translate(5px, 5px);
}

.burger.toggle .line2 {
    opacity: 0;
}

.burger.toggle .line3 {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ============================================================
   Design Réponsif
   ============================================================ */
@media screen and (max-width: 900px) {
    .mv-container, .targets-container, .form-row {
        flex-direction: column;
        gap: 30px;
    }
    .hero-content h1 {
        font-size: 40px;
    }
    .btn-secondary {
        margin-left: 0;
        margin-top: 15px;
    }
}

@media screen and (max-width: 768px) {
    .nav-links {
        position: fixed;
        right: 0;
        height: 100vh;
        top: 0;
        padding-top: 90px;
        background-color: var(--overlay-top);
        backdrop-filter: blur(16px);
        flex-direction: column;
        width: 100%;
        transform: translateX(100%);
        transition: transform 0.4s ease-in;
        justify-content: flex-start;
        gap: 30px;
        z-index: 999;
    }

    .burger {
        display: block;
    }

    .nav-active {
        transform: translateX(0%);
    }

    .hero-section::before,
    .hero-section::after {
        display: none;
    }
}
