/* =========================================================
   S.I Rênes – site vitrine
   Couleurs issues du logo : cyan #03A6D9 / marine #212A37
   ========================================================= */

:root {
    --cyan: #03A6D9;
    --cyan-dark: #0287B1;
    --cyan-soft: #E6F6FC;
    --navy: #212A37;
    --navy-deep: #141B26;
    --text: #3A4555;
    --muted: #6B7686;
    --line: #E3E8EE;
    --bg: #FFFFFF;
    --bg-alt: #F5F8FB;

    --radius: 14px;
    --shadow: 0 10px 30px rgba(33, 42, 55, .08);
    --shadow-hover: 0 18px 40px rgba(33, 42, 55, .14);
    --font-title: 'Montserrat', system-ui, sans-serif;
    --font-text: 'Open Sans', system-ui, sans-serif;
    --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
    margin: 0;
    font-family: var(--font-text);
    font-size: 16px;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

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

a { color: var(--cyan-dark); }

h1, h2, h3 {
    font-family: var(--font-title);
    color: var(--navy);
    line-height: 1.2;
    margin: 0 0 .6em;
}
h1 { font-size: clamp(2rem, 4.5vw, 3.1rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 600; }
p  { margin: 0 0 1em; }

.container {
    width: 100%;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 20px;
}

.accent { color: var(--cyan); }

.eyebrow {
    font-family: var(--font-title);
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--cyan);
    margin-bottom: .8em;
}
.eyebrow-light { color: #7FD6F2; }

/* ---------- Boutons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5em;
    padding: .85em 1.6em;
    border: 2px solid var(--cyan);
    border-radius: 999px;
    background: var(--cyan);
    color: #fff;
    font-family: var(--font-title);
    font-weight: 600;
    font-size: .95rem;
    text-decoration: none;
    cursor: pointer;
    transition: background .2s, border-color .2s, color .2s, transform .2s;
}
.btn:hover { background: var(--cyan-dark); border-color: var(--cyan-dark); transform: translateY(-1px); }
.btn:focus-visible { outline: 3px solid rgba(3, 166, 217, .35); outline-offset: 2px; }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-ghost:hover { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn-small { padding: .55em 1.2em; font-size: .88rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--header-h);
    background: rgba(255, 255, 255, .96);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s, box-shadow .2s;
}
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 4px 20px rgba(33, 42, 55, .06); }

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.brand img { width: 170px; }

.main-nav { display: flex; align-items: center; gap: 30px; }
.main-nav a:not(.btn) {
    color: var(--navy);
    text-decoration: none;
    font-family: var(--font-title);
    font-weight: 500;
    font-size: .95rem;
    position: relative;
}
.main-nav a:not(.btn)::after {
    content: "";
    position: absolute;
    left: 0; right: 0; bottom: -6px;
    height: 2px;
    background: var(--cyan);
    transform: scaleX(0);
    transition: transform .2s;
}
.main-nav a:not(.btn):hover::after { transform: scaleX(1); }

.nav-toggle {
    display: none;
    width: 44px; height: 44px;
    border: 0; background: none; cursor: pointer;
    flex-direction: column; justify-content: center; align-items: center; gap: 5px;
}
.nav-toggle span { width: 24px; height: 2px; background: var(--navy); transition: transform .25s, opacity .25s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    padding: 80px 0 100px;
    background:
        radial-gradient(circle at 85% 20%, rgba(3, 166, 217, .12), transparent 45%),
        linear-gradient(180deg, #fff 0%, var(--bg-alt) 100%);
}
.hero-inner {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 60px;
    align-items: center;
}
.hero-lead { font-size: 1.12rem; color: var(--muted); max-width: 560px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }

/* Visuel « interface » : données -> S.I Rênes -> décisions */
.flow {
    display: grid;
    grid-template-columns: auto 1fr auto 1fr auto;
    align-items: center;
    padding: 36px 28px;
    background: #fff;
    border-radius: 22px;
    box-shadow: var(--shadow);
}
.flow-col { display: flex; flex-direction: column; gap: 10px; }
.chip {
    display: inline-block;
    padding: .45em 1em;
    border-radius: 999px;
    background: var(--cyan-soft);
    color: var(--cyan-dark);
    font-family: var(--font-title);
    font-size: .8rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}
.chip-dark { background: var(--navy); color: #fff; }

.flow-link {
    height: 2px;
    min-width: 24px;
    margin: 0 8px;
    background: repeating-linear-gradient(90deg, var(--cyan) 0 8px, transparent 8px 14px);
    background-size: 28px 2px;
    animation: flow 1.2s linear infinite;
}
@keyframes flow { to { background-position: 28px 0; } }

.flow-core {
    width: 108px; height: 108px;
    border-radius: 50%;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    background: var(--navy);
    box-shadow: 0 0 0 8px var(--cyan-soft), 0 0 0 9px rgba(3, 166, 217, .3);
    font-family: var(--font-title);
    font-weight: 700;
    line-height: 1.05;
}
.core-si { color: var(--cyan); font-size: 1.4rem; }
.core-name { color: #fff; font-size: .9rem; letter-spacing: .12em; }

/* ---------- Sections ---------- */
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 720px; margin: 0 auto 56px; text-align: center; }

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

/* Services */
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}
.service {
    padding: 32px 26px;
    border-top: 4px solid var(--cyan);
    transition: transform .25s, box-shadow .25s;
}
.service:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }
.service-icon {
    width: 54px; height: 54px;
    display: grid; place-items: center;
    border-radius: 12px;
    background: var(--cyan-soft);
    color: var(--cyan);
    margin-bottom: 20px;
}
.service-icon svg { width: 28px; height: 28px; }
.service-lead {
    font-size: .85rem;
    font-weight: 600;
    color: var(--cyan-dark);
    margin-top: -.4em;
}
.service p { font-size: .95rem; }

.checklist { list-style: none; padding: 0; margin: 18px 0 0; border-top: 1px solid var(--line); padding-top: 16px; }
.checklist li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 8px;
    font-size: .9rem;
    color: var(--navy);
}
.checklist li::before {
    content: "";
    position: absolute;
    left: 2px; top: .45em;
    width: 10px; height: 6px;
    border-left: 2px solid var(--cyan);
    border-bottom: 2px solid var(--cyan);
    transform: rotate(-45deg);
}

/* Bloc Business Central */
.section-dark {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-deep) 100%);
    color: #C9D2DD;
}
.section-dark h2 { color: #fff; }
.bc-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}
.bc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.bc-list li {
    padding: 22px 24px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .1);
    border-left: 4px solid var(--cyan);
}
.bc-list strong { display: block; color: #fff; font-family: var(--font-title); margin-bottom: 4px; }
.bc-list span { font-size: .95rem; }

/* Méthode */
.steps {
    list-style: none;
    margin: 0; padding: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    counter-reset: step;
    position: relative;
}
.steps::before {
    content: "";
    position: absolute;
    top: 28px; left: 12%; right: 12%;
    height: 2px;
    background: linear-gradient(90deg, var(--cyan), var(--navy));
    opacity: .25;
}
.step { position: relative; text-align: center; padding: 0 10px; }
.step-num {
    position: relative;
    display: inline-grid; place-items: center;
    width: 56px; height: 56px;
    margin-bottom: 18px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--cyan);
    color: var(--cyan);
    font-family: var(--font-title);
    font-weight: 700;
}
.step:last-child .step-num { background: var(--cyan); color: #fff; }
.step p { font-size: .95rem; color: var(--muted); }

/* Atouts */
.values-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    max-width: 960px;
    margin: 0 auto;
}
.value {
    padding: 28px 30px 20px 30px;
    background: #fff;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    position: relative;
}
.value::before {
    content: "";
    position: absolute;
    top: 28px; left: 0;
    width: 4px; height: 24px;
    border-radius: 0 4px 4px 0;
    background: var(--cyan);
}
.value p { color: var(--muted); }

/* Contact */
.contact-inner {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 60px;
    align-items: start;
}
.contact-list { list-style: none; padding: 0; margin: 30px 0 0; }
.contact-list li { padding: 14px 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; }
.contact-label { font-size: .78rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.contact-list a { font-weight: 600; text-decoration: none; }

.contact-form { padding: 34px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: .88rem; font-weight: 600; color: var(--navy); margin-bottom: 6px; }
.field input,
.field select,
.field textarea {
    width: 100%;
    padding: .75em .9em;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--bg-alt);
    font: inherit;
    color: var(--navy);
    transition: border-color .2s, box-shadow .2s, background .2s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--cyan);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(3, 166, 217, .15);
}
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: .85rem; color: var(--muted); margin-bottom: 22px; cursor: pointer; }
.consent input { margin-top: .3em; accent-color: var(--cyan); }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.alert { padding: 14px 18px; border-radius: 10px; margin-bottom: 22px; font-size: .93rem; }
.alert-success { background: #E7F7EE; color: #1D6B40; border: 1px solid #BFE7CF; }
.alert-error { background: #FDECEC; color: #9B2C2C; border: 1px solid #F5C6C6; }

/* Footer */
.site-footer { padding: 48px 0 36px; border-top: 1px solid var(--line); text-align: center; }
.footer-inner { display: flex; flex-direction: column; align-items: center; }
.footer-logo { width: 150px; margin-bottom: 8px; }
.footer-baseline { color: var(--muted); font-style: italic; }
.footer-copy { font-size: .85rem; color: var(--muted); margin: 0; }
.footer-copy a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.footer-copy a:hover { color: var(--cyan-dark); }
.footer-sep { margin: 0 .5em; }

/* Page mentions légales */
.legal { padding-top: 64px; }
.legal-inner { max-width: 820px; }
.legal h1 { margin-bottom: .3em; }
.legal-updated { color: var(--muted); font-size: .9rem; }
.legal section { padding-top: 36px; margin-top: 36px; border-top: 1px solid var(--line); }
.legal h2 { font-size: 1.35rem; }
.legal-toc { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.legal-toc a {
    padding: .4em 1em;
    border-radius: 999px;
    background: var(--cyan-soft);
    color: var(--cyan-dark);
    font-family: var(--font-title);
    font-size: .85rem;
    font-weight: 600;
    text-decoration: none;
}
.legal-toc a:hover { background: var(--cyan); color: #fff; }
.legal-list {
    display: grid;
    grid-template-columns: minmax(180px, 260px) 1fr;
    margin: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}
.legal-list dt, .legal-list dd { margin: 0; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.legal-list dt { background: var(--bg-alt); font-weight: 600; color: var(--navy); font-size: .92rem; }
.legal-list dd { color: var(--text); }
.legal-list dt:last-of-type, .legal-list dd:last-of-type { border-bottom: 0; }
.todo { color: #B54708; background: #FEF3E2; padding: .1em .4em; border-radius: 4px; font-size: .9em; }
.consent a { color: var(--cyan-dark); }

@media (max-width: 600px) {
    .legal-list { grid-template-columns: 1fr; }
    .legal-list dt { border-bottom: 0; padding-bottom: 6px; }
    .legal-list dd { padding-top: 8px; }
}

/* Animations d'apparition */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none; transition: none; }
    .flow-link { animation: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .hero-inner { grid-template-columns: 1fr; gap: 50px; }
    .hero-visual { max-width: 520px; }
}

@media (max-width: 860px) {
    .nav-toggle { display: flex; }
    .main-nav {
        position: absolute;
        top: var(--header-h); left: 0; right: 0;
        flex-direction: column;
        gap: 0;
        padding: 10px 20px 24px;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: 0 12px 24px rgba(33, 42, 55, .08);
        display: none;
    }
    .main-nav.is-open { display: flex; }
    .main-nav a:not(.btn) { width: 100%; padding: 14px 0; border-bottom: 1px solid var(--line); }
    .main-nav a:not(.btn)::after { display: none; }
    .main-nav .btn { margin-top: 18px; }

    .bc-inner, .contact-inner { grid-template-columns: 1fr; gap: 40px; }
    .steps { grid-template-columns: repeat(2, 1fr); row-gap: 40px; }
    .steps::before { display: none; }
    .section { padding: 72px 0; }
}

@media (max-width: 600px) {
    :root { --header-h: 66px; }
    .brand img { width: 140px; }
    .hero { padding: 50px 0 70px; }
    .services-grid, .values-grid, .steps, .form-row { grid-template-columns: 1fr; }
    .form-row { gap: 0; }
    .contact-form { padding: 24px 20px; }
    .flow { padding: 24px 14px; }
    .flow-core { width: 84px; height: 84px; }
    .core-si { font-size: 1.1rem; }
    .core-name { font-size: .72rem; }
    .chip { font-size: .7rem; padding: .4em .7em; }
    .flow-link { min-width: 12px; margin: 0 4px; }
}
