/* =========================================================
   Cernunnos — Landing page
   Réplique du mockup cernunnos_landing_mockup_v2.jpg
   ========================================================= */

:root {
    --black: #060606;
    --ink: #0d0d0f;
    --paper: #f2f0ec;
    --purple: #7c1cff;
    --purple-deep: #5b2ea6;
    --text-dark-muted: #6b6b70;
    --text-light-muted: #b9b4c4;
    --radius-lg: 22px;
    --radius-md: 16px;
    --font-title: 'Archivo', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    background: var(--black);
    color: #fff;
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 32px;
}

/* ============ Typo commune ============ */
h1, h2 {
    font-family: var(--font-title);
    font-stretch: 118%;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.045em;
    line-height: 1.15;
    text-align: center;
}

h1 { font-size: clamp(34px, 4.6vw, 58px); }
h2 { font-size: clamp(26px, 3.4vw, 42px); }

.kicker {
    text-align: center;
    font-size: 19px;
    margin-top: 18px;
}

.prose {
    text-align: center;
    margin: 26px auto 0;
    max-width: 640px;
    font-size: 17px;
    line-height: 1.75;
}

.prose p + p { margin-top: 10px; }

/* ============ Boutons ============ */
.btn {
    display: inline-block;
    font-family: var(--font-body);
    font-weight: 500;
    font-size: 15px;
    text-decoration: none;
    padding: 13px 28px;
    border-radius: 999px;
    border: 1px solid transparent;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.btn:hover { transform: translateY(-1px); opacity: 0.92; }

.btn-primary { background: var(--purple); color: #fff; }
.btn-dark { background: #111; color: #fff; padding: 11px 24px; font-size: 14px; }
.btn-outline {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.45);
    padding: 11px 24px;
}

/* ============ Header ============ */
.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 26px 32px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #fff;
}

.brand-mark { width: 42px; height: 42px; border-radius: 50%; }

.brand-name {
    font-family: var(--font-title);
    font-weight: 700;
    font-size: 24px;
    letter-spacing: 0.01em;
    line-height: 1;
    display: flex;
    flex-direction: column;
}

.brand-name small {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 11px;
    color: var(--text-light-muted);
    margin-top: 2px;
}

/* ============ Switcher de langue ============ */
.header-actions {
    display: flex;
    align-items: center;
    gap: 22px;
}

.lang-switch {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
}

.lang-switch a {
    color: var(--text-light-muted);
    text-decoration: none;
    transition: color 0.15s ease;
}

.lang-switch a:hover { color: #fff; }

.lang-switch a.active {
    color: var(--purple);
    cursor: default;
}

.lang-switch span { color: rgba(255, 255, 255, 0.3); }

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

/* Image en fond plein écran */
.hero-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 62%;
}

/* Voile de lisibilité autour du texte */
.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    background: radial-gradient(ellipse 70% 55% at 50% 42%, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.35) 55%, rgba(0, 0, 0, 0) 100%);
    pointer-events: none;
}

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

/* Effet de révélation du fond */
@keyframes heroReveal {
    from { opacity: 0; transform: scale(1.08); }
    to { opacity: 1; transform: scale(1); }
}

.js .hero-bg[data-animate="heroReveal"] {
    opacity: 0;
}

.js .hero-bg.animate__animated {
    animation: heroReveal 1.6s ease-out forwards;
}

.hero h1 {
    text-shadow: 0 4px 40px rgba(0, 0, 0, 0.8);
}

.hero .kicker { color: var(--text-light-muted); text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8); }

.hero .lead {
    max-width: 560px;
    margin: 26px auto 0;
    color: var(--text-light-muted);
    font-size: 17px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8);
}

.hero .btn { margin-top: 36px; box-shadow: 0 8px 40px rgba(124, 28, 255, 0.45); }

/* ============ Sections génériques ============ */
.section { padding: 130px 0; }

.section-light {
    background: var(--paper);
    color: var(--ink);
}

.section-light .kicker { color: var(--text-dark-muted); }
.section-light .prose { color: var(--text-dark-muted); }
.section-light .prose strong { color: var(--ink); font-weight: 600; }

.section-dark { background: var(--black); }
.section-dark .kicker { color: var(--text-light-muted); }
.section-dark .prose { color: var(--text-light-muted); }
.section-dark .prose strong { color: #fff; font-weight: 600; }

/* ============ Visuels larges ============ */
.wide-visual {
    margin: 60px auto 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.wide-visual img { width: 100%; }

#standard .prose { margin-top: 56px; }

/* ============ Assemblez (visuel en background) ============ */
.section-assemble {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.assemble-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.assemble-orb {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.assemble-columns {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

/* Voile de lisibilité derrière le texte */
.section-assemble::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    background: radial-gradient(ellipse 65% 50% at 50% 45%, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.35) 55%, rgba(0, 0, 0, 0) 100%);
    pointer-events: none;
}

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

.assemble-content h2 { text-shadow: 0 4px 40px rgba(0, 0, 0, 0.8); }
.assemble-content .prose { text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8); }

.js .assemble-bg[data-animate="heroReveal"] {
    opacity: 0;
}

.js .assemble-bg.animate__animated {
    animation: heroReveal 1.6s ease-out forwards;
}

/* ============ Cartes modules ============ */
.card-grid { display: grid; gap: 28px; margin-top: 64px; }

.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-6 { grid-template-columns: repeat(6, 1fr); }

.grid-6 .span-3 { grid-column: span 3; }
.grid-6 .span-2 { grid-column: span 2; }

.module-card {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--card-color);
    display: flex;
    flex-direction: column;
}

.module-card-media { height: 230px; background: #000; }
.module-card-media.media-short { height: 170px; }

.module-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.module-card-media dotlottie-player {
    width: 100%;
    height: 100%;
}

/* Animation Lottie superposée à l'image statique (repli si le player ne charge pas) */
.module-card-media { position: relative; }

.module-card-media .lottie-slot { display: none; }

.module-card-media .media-desktop {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.module-card-body {
    padding: 30px 30px 34px;
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1;
}

.module-card-body h3 {
    font-family: var(--font-title);
    font-stretch: 115%;
    font-weight: 700;
    font-size: 20px;
    letter-spacing: 0.06em;
}

.module-card-body p { font-size: 15px; opacity: 0.92; }

.module-card-body ul {
    list-style: none;
    font-size: 15px;
}

.module-card-body ul li {
    padding: 7px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.25);
}

.module-card-body ul li:last-child { border-bottom: none; }

.module-card-body .btn { align-self: flex-start; margin-top: auto; }

/* ============ Tuiles métiers ============ */
.tile-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    margin-top: 64px;
}

.metier-tile {
    border-radius: var(--radius-md);
    background-size: cover;
    background-position: center;
    padding: 30px 28px 34px;
    min-height: 380px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.metier-icon { width: 52px; height: 52px; }

.metier-tile h3 {
    font-family: var(--font-title);
    font-stretch: 112%;
    font-weight: 700;
    font-size: 17px;
    letter-spacing: 0.05em;
    margin-top: 6px;
}

.metier-tile p { font-size: 14px; opacity: 0.9; }

.metier-tile .metier-modules { font-weight: 600; opacity: 1; }

.metier-tile .btn { align-self: flex-start; margin-top: auto; }

.tile-light-text { color: #fff; }
.tile-dark-text { color: #131313; }
.tile-dark-text .btn-dark { background: #111; color: #fff; }

/* ============ Comparaison ============ */
.compare-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    max-width: 900px;
    margin: 60px auto 0;
}

.compare-panel {
    border-radius: var(--radius-md);
    padding: 32px 34px;
}

.compare-panel h3 {
    font-family: var(--font-title);
    font-stretch: 112%;
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 18px;
}

.compare-panel ul { list-style: none; }

.compare-panel li {
    padding: 10px 0;
    font-size: 15px;
}

.panel-legacy { background: #dcdcda; color: #555; }
.panel-legacy li { border-bottom: 1px solid #c3c3bf; }
.panel-legacy li:last-child { border-bottom: none; }

.panel-cernunnos { background: var(--purple); color: #fff; }
.panel-cernunnos li { border-bottom: 1px solid rgba(255, 255, 255, 0.35); }
.panel-cernunnos li:last-child { border-bottom: none; }

/* ============ Dashboard ============ */
.dashboard-visual {
    max-width: 1050px;
    margin: 64px auto 0;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 40px 120px rgba(124, 28, 255, 0.28);
}

.dashboard-visual img { width: 100%; }

/* ============ CTA ============ */
#cta .btn { margin-top: 40px; }
#cta { text-align: center; }

/* ============ Footer ============ */
.site-footer { padding: 40px 0 0; }

.footer-card {
    background: #151223;
    border-radius: 26px;
    text-align: center;
    padding: 90px 32px 80px;
}

.footer-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 999px;
    padding: 8px 18px;
    font-size: 12px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #fff;
}

.footer-badge i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--purple);
}

.footer-card h2 { margin-top: 34px; }

.footer-mail {
    display: inline-block;
    margin-top: 34px;
    color: #fff;
    font-size: 20px;
    text-decoration: none;
}

.footer-mail:hover { text-decoration: underline; }

.footer-nav {
    display: flex;
    justify-content: center;
    gap: 44px;
    padding: 42px 0 38px;
}

.footer-nav a {
    color: #eee;
    text-decoration: none;
    font-size: 15px;
}

.footer-nav a:hover { color: var(--purple); }

/* ============ Animations au scroll ============ */
/* État initial uniquement si JS est actif (évite de masquer le contenu sans JS) */
.js [data-animate] {
    opacity: 0;
}

.js [data-animate].animate__animated {
    opacity: 1;
}

/* Respect des préférences d'accessibilité */
@media (prefers-reduced-motion: reduce) {
    .js [data-animate] {
        opacity: 1;
        animation: none !important;
    }
}

/* ============ Responsive ============ */

/* --- Grands laptops / petits écrans --- */
@media (max-width: 1200px) {
    .container { padding: 0 28px; }
    .site-header { padding: 22px 28px; }
}

/* --- Tablette paysage / petit laptop --- */
@media (max-width: 1024px) {
    .section { padding: 100px 0; }

    .hero { min-height: 80vh; padding: 100px 0 80px; }

    .card-grid,
    .tile-grid { gap: 22px; margin-top: 48px; }

    .grid-3 { grid-template-columns: 1fr 1fr; }
    .grid-3 .module-card:last-child { grid-column: 1 / -1; max-width: 480px; margin: 0 auto; width: 100%; }

    .grid-6 { grid-template-columns: 1fr 1fr; }
    .grid-6 .span-3 { grid-column: span 1; }
    .grid-6 .span-2 { grid-column: span 1; }
    .grid-6 .module-card:last-child { grid-column: 1 / -1; max-width: 480px; margin: 0 auto; width: 100%; }

    .tile-grid { grid-template-columns: 1fr 1fr; }

    .module-card-media { height: 200px; }
    .module-card-media.media-short { height: 150px; }

    .compare-grid { margin-top: 44px; }

    .dashboard-visual { margin-top: 48px; box-shadow: 0 24px 70px rgba(124, 28, 255, 0.25); }

    .footer-card { padding: 64px 28px 56px; }
}

/* --- Tablette portrait --- */
@media (max-width: 768px) {
    h1 { font-size: clamp(30px, 7vw, 42px); }
    h2 { font-size: clamp(22px, 5.4vw, 32px); }

    .kicker { font-size: 17px; margin-top: 14px; }
    .prose { font-size: 16px; margin-top: 20px; }

    .compare-grid { grid-template-columns: 1fr; max-width: 520px; }

    .wide-visual { margin-top: 40px; }
    #standard .prose { margin-top: 40px; }

    .footer-nav { gap: 28px; padding: 34px 0 30px; }
}

/* --- Mobile --- */
@media (max-width: 640px) {
    .section { padding: 72px 0; }
    .container { padding: 0 20px; }

    .site-header { padding: 16px 20px; }
    .brand { min-width: 0; }
    .brand-mark { width: 32px; height: 32px; flex-shrink: 0; }
    .brand-name { font-size: 17px; white-space: nowrap; }
    .header-actions { gap: 12px; flex-shrink: 0; }
    .lang-switch { gap: 6px; font-size: 12px; }
    .btn-outline { padding: 9px 14px; font-size: 12px; white-space: nowrap; }

    .hero { min-height: 78vh; padding: 90px 0 70px; }
    .hero-bg img { object-position: center 55%; }
    .hero .lead { font-size: 15px; }
    .hero .btn { margin-top: 28px; }

    .grid-3,
    .grid-6,
    .tile-grid { grid-template-columns: 1fr; }
    .grid-3 .module-card:last-child,
    .grid-6 .module-card:last-child { max-width: none; }

    .module-card-media { height: 190px; }
    .module-card-body { padding: 24px 22px 28px; }

    .metier-tile { min-height: 0; padding: 26px 22px 30px; }

    .compare-panel { padding: 24px 22px; }

    .footer-card { padding: 52px 20px 44px; border-radius: 20px; }
    .footer-mail { font-size: 17px; }

    .footer-nav { flex-wrap: wrap; gap: 18px 26px; }
    .footer-nav a { font-size: 14px; }
}

/* --- Très petits écrans --- */
@media (max-width: 380px) {
    h1 { font-size: 27px; }
    .brand-name { font-size: 17px; }
    .btn-outline { padding: 8px 14px; font-size: 12px; }
}
