/* Prasadhana : charte B v2, contrastes corrigés (proposition § 6). Mobile d'abord. */

@font-face {
    font-family: "Morpheus";
    src: url("../fonts/morpheus.woff") format("woff");
    font-display: swap;
}

@font-face {
    font-family: "Astonpoliz";
    src: url("../fonts/Astonpoliz.ttf") format("truetype");
    font-display: swap;
}

:root {
    --teal: #105b66;
    --teal-dark: #0a3c43;
    --teal-soft: #e3eff0;
    --saffron: #e6b783;
    --saffron-dark: #c98d58;
    --saffron-soft: #f7eee4;
    --saffron-ink: #714a29;
    --cta-orange: #e98024;
    --cta-orange-dark: #d3731f;
    --cream: #faf6f0;
    --ink: #1e2a38;
    --ink-soft: #4a5563;
    --white: #ffffff;
    --line: rgba(16, 91, 102, 0.16);
    --error: #a3271d;
    --success: #1d6b3a;

    --font-heading: "Morpheus", Georgia, serif;
    --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;

    --radius-card: 16px;
    --radius-btn: 10px;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    --container: 1160px;
    --gutter: 16px;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }

body {
    margin: 0;
    background-color: #066269;
    background-image:
        url("../img/overlay-patatas.png"),
        linear-gradient(rgba(250, 246, 240, 0.18), rgba(250, 246, 240, 0.18)),
        url("../img/sunburst-background.svg");
    background-size: auto, auto, cover;
    background-position: center, center, top center;
    background-repeat: repeat, no-repeat, no-repeat;
    background-attachment: scroll, scroll, fixed;
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.65;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--teal); text-underline-offset: 0.18em; }
a:hover { color: var(--teal-dark); }
:focus-visible { outline: 3px solid var(--saffron); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3 {
    font-family: var(--font-heading);
    font-weight: normal;
    line-height: 1.15;
    color: var(--teal);
    margin: 0 0 0.6em;
    overflow-wrap: break-word;
    hyphens: auto;
}
h1, h2 { font-family: "Astonpoliz", var(--font-body); font-weight: 700; }
h1 { font-size: clamp(2rem, 6vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.3rem); margin-top: 0.4em; }
h3, .h3 { font-size: clamp(1.25rem, 2.6vw, 1.5rem); }
.h3 { font-family: var(--font-heading); font-weight: normal; color: var(--teal); }
p, ul, ol, dl { margin: 0 0 1em; }
em { font-style: italic; }
code { background: var(--teal-soft); padding: 0.1em 0.35em; border-radius: 4px; font-size: 0.9em; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 780px; }
.center { text-align: center; }
.muted { color: var(--ink-soft); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; z-index: 100; border-radius: 6px; }
.skip-link:focus { left: 8px; color: #fff; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------------------------------------------------------------- boutons */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 0.4em;
    min-height: 48px; padding: 0.7em 1.3em;
    border: 2px solid transparent; border-radius: var(--radius-btn);
    font: 600 1rem/1.2 var(--font-body); text-decoration: none; cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s, background-color 0.15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--cta-orange); color: var(--ink); }
.btn-primary:hover { background: var(--cta-orange-dark); color: var(--ink); box-shadow: 0 4px 12px rgba(233, 128, 36, 0.35); }
.btn-secondary { background: var(--teal); color: var(--white); }
.btn-secondary:hover { background: var(--teal-dark); color: var(--white); }
.btn-ghost { background: transparent; border-color: var(--teal); color: var(--teal); }
.btn-ghost-light { background: transparent; border-color: rgba(255, 255, 255, 0.85); color: var(--white); }
.btn-ghost-light:hover { background: rgba(255, 255, 255, 0.12); color: var(--white); }
.btn-sm { min-height: 44px; padding: 0.5em 1em; font-size: 0.95rem; }
.btn-block { width: 100%; }
.link-button { background: none; border: 0; padding: 0; font: inherit; color: var(--teal); text-decoration: underline; cursor: pointer; min-height: 44px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.4em; }
.more { font-weight: 600; text-decoration: none; }
.more:hover { text-decoration: underline; }

.badge {
    display: inline-block; padding: 0.15em 0.75em; border-radius: 999px;
    background: var(--teal-soft); color: var(--teal-dark);
    font-size: 0.82rem; font-weight: 600; margin: 0 0 0.6em;
}
.badge-saffron { background: var(--saffron-soft); color: var(--saffron-ink); }

/* ---------------------------------------------------------------- en-tête */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(250, 246, 240, 0.92);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--teal); }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-name { font-family: var(--font-heading); font-size: 1.55rem; }
.brand-sub { font-size: 0.8rem; color: var(--ink-soft); letter-spacing: 0.03em; }

.nav-toggle {
    display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 12px;
    background: none; border: 2px solid var(--line); border-radius: var(--radius-btn);
    font: 600 0.95rem var(--font-body); color: var(--teal); cursor: pointer;
}
.nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    display: block; width: 20px; height: 2px; background: currentColor; position: relative; content: "";
}
.nav-toggle-bars::before { position: absolute; top: -6px; }
.nav-toggle-bars::after { position: absolute; top: 6px; }

.main-nav { display: none; }
.main-nav.is-open {
    display: block; position: absolute; left: 0; right: 0; top: 100%;
    background: var(--cream); border-bottom: 1px solid var(--line);
    max-height: calc(100vh - 68px); overflow-y: auto; padding: 8px var(--gutter) 20px;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.08);
}
.nav-list { list-style: none; margin: 0; padding: 0; }
.nav-item { position: relative; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; }
.nav-link { flex: 1; display: block; padding: 12px 0; font-weight: 600; text-decoration: none; color: var(--ink); min-height: 44px; }
.nav-link[aria-current="page"] { color: var(--teal); }
.sub-toggle {
    width: 44px; height: 44px; background: none; border: 0; cursor: pointer; color: var(--teal);
}
.sub-toggle::before { content: ""; display: inline-block; width: 9px; height: 9px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); margin-top: -4px; }
.sub-toggle[aria-expanded="true"]::before { transform: rotate(-135deg); margin-top: 4px; }
.sub-menu { display: none; list-style: none; margin: 0 0 8px; padding: 0 0 0 14px; width: 100%; }
.sub-toggle[aria-expanded="true"] + .sub-menu { display: block; }
.sub-menu a { display: block; padding: 8px 0; text-decoration: none; color: var(--ink); min-height: 40px; }
.sub-menu a:hover { color: var(--teal); }
.nav-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding-top: 16px; }
.nav-espace { font-weight: 600; text-decoration: none; padding: 10px 0; }

@media (min-width: 1080px) {
    .nav-toggle { display: none; }
    .main-nav, .main-nav.is-open {
        display: flex; align-items: center; gap: 24px; position: static; padding: 0;
        background: none; border: 0; box-shadow: none; max-height: none; overflow: visible;
    }
    .nav-list { display: flex; gap: 4px; }
    .nav-item { border: 0; flex-wrap: nowrap; }
    .nav-link { padding: 10px 4px 10px 10px; font-weight: 500; }
    .nav-link[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--saffron); }
    .sub-toggle { width: 26px; height: 40px; }
    .sub-menu {
        position: absolute; top: 100%; left: 0; min-width: 230px; padding: 8px 0;
        background: var(--white); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
    }
    .sub-menu a { padding: 8px 16px; }
    .nav-item:hover > .sub-menu { display: block; }
    .nav-actions { padding: 0; flex-wrap: nowrap; }
}

/* ---------------------------------------------------------------- sections */
.section { padding: 56px 0; }
.section-tight { padding: 36px 0; }
.section-cream { background: #f3ece2; }
.section-teal { background: var(--teal); color: var(--white); }
.section-teal h2 { color: var(--white); }
.section-teal a:not(.btn) { color: var(--white); }
.section-sun {
    background:
        radial-gradient(circle at 50% 0%, rgba(230, 183, 131, 0.16), transparent 60%),
        var(--cream);
}
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px; }
@media (min-width: 768px) { .section { padding: 80px 0; } .section-tight { padding: 48px 0; } }

/* Panneaux séparés pour laisser apparaître le fond fixe sur toutes les pages */
#contenu {
    display: grid;
    gap: clamp(24px, 4vw, 48px);
    padding: 24px 0 48px;
}
#contenu > .hero,
#contenu > .section,
#contenu > .page-head,
#contenu > .page-toc {
    width: min(calc(100% - 32px), 1120px);
    max-width: 1120px;
    margin-inline: auto;
    border-radius: var(--radius-card);
    overflow: hidden;
    box-shadow: 0 8px 22px rgba(10, 60, 67, 0.2);
    --container: 960px;
}
#contenu > .section:not(.section-teal) { background-color: var(--cream); }
#contenu > .page-toc { background: var(--cream); padding: 12px 24px; }

/* Hero : fond historique et logo en filigrane */
.hero {
    position: relative; overflow: hidden; color: var(--white);
    background: linear-gradient(160deg, rgba(16, 91, 102, 0.72) 0%, rgba(10, 60, 67, 0.8) 100%);
}
.hero::before {
    content: ""; position: absolute; inset: 0;
    background: url("../img/overlay-patatas.png") center / auto repeat;
    opacity: 0.22; pointer-events: none;
}
.hero::after {
    content: ""; position: absolute; inset: 0;
    background: url("../img/logo-big.png") center / min(34vw, 230px) auto no-repeat;
    opacity: 0.22; mix-blend-mode: screen; pointer-events: none;
}
.hero-inner { position: relative; z-index: 1; display: grid; gap: 32px; padding-top: 48px; padding-bottom: 56px; }
.hero h1 { color: var(--white); }
.hero .eyebrow { color: #f4d9b8; }
.hero .lead { color: rgba(255, 255, 255, 0.92); }
.hero-address { display: flex; gap: 8px; align-items: flex-start; margin-top: 1.4em; font-size: 0.95rem; color: rgba(255, 255, 255, 0.9); }
.hero-address svg { flex: none; margin-top: 3px; color: var(--saffron); }
.hero-img { border-radius: var(--radius-card); box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25); aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.hero-hours { margin-top: 20px; color: rgba(255, 255, 255, 0.92); }
.hero-hours h2 { margin-bottom: 10px; color: var(--white); font-size: 1.1rem; }
.hero-hours ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; margin: 0 0 10px; padding: 0; list-style: none; }
.hero-hours li { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.9rem; }
.hero-hours li span { font-weight: 700; color: #f4d9b8; }
.hero-hours > a { color: #f4d9b8; font-weight: 700; }
@media (min-width: 960px) { .hero-inner { grid-template-columns: 1.1fr 1fr; align-items: center; padding-top: 72px; padding-bottom: 80px; } }

.eyebrow { font-weight: 700; font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--saffron-ink); margin-bottom: 0.6em; }
.lead { font-size: 1.15rem; max-width: 40em; }

.page-head { padding: 28px 0 32px; background: linear-gradient(180deg, var(--saffron-soft), var(--cream)); border-bottom: 1px solid var(--line); }
.page-head h1 { margin-bottom: 0.3em; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.88rem; color: var(--ink-soft); margin-bottom: 18px; }
.crumbs a { color: var(--ink-soft); }
.page-toc { display: flex; flex-wrap: wrap; gap: 8px 18px; padding-top: 18px; padding-bottom: 4px; font-size: 0.95rem; }
.page-toc a { font-weight: 600; text-decoration: none; }

/* Mises en page */
.split { display: grid; gap: 32px; }
.split-media { display: grid; gap: 20px; align-content: start; }
.split-plain { display: grid; gap: 24px; margin-top: 32px; }
.rounded { border-radius: var(--radius-card); }
@media (min-width: 960px) {
    .split { grid-template-columns: 1.25fr 1fr; align-items: start; gap: 56px; }
    .split-plain { grid-template-columns: 1fr 1fr; }
}
.grid-2 { display: grid; gap: 0 16px; }
@media (min-width: 600px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

/* Cartes */
.cards-3 { display: grid; gap: 12px; }
@media (min-width: 760px) { .cards-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .cards-3 { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.card-img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.card-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.card-body p:not(.badge) { flex: 1; }
.card-link { font-weight: 600; text-decoration: none; }
.card-link:hover { text-decoration: underline; }

.pillars { list-style: none; padding: 0; margin: 32px 0 0; display: grid; gap: 20px; counter-reset: pilier; }
@media (min-width: 700px) { .pillars { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .pillars { grid-template-columns: repeat(4, 1fr); } }
.pillar { background: var(--white); border-radius: var(--radius-card); padding: 24px; border-top: 4px solid var(--saffron); box-shadow: var(--shadow); counter-increment: pilier; }
.pillar::before { content: counter(pilier); display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--teal); color: var(--white); font-weight: 700; margin-bottom: 12px; }
.pillar h3 span { font-family: var(--font-body); font-size: 0.9rem; color: var(--ink-soft); display: block; margin-top: 4px; }

.quote { margin: 0 0 1.2em; padding: 6px 0 6px 20px; border-left: 4px solid var(--saffron); font-size: 1.12rem; color: var(--teal-dark); }
.quote p { margin: 0; }

.steps { padding-left: 1.3em; }
.steps li { margin-bottom: 0.7em; }
.steps-compact li { margin-bottom: 0.5em; }
.checklist { list-style: none; padding: 0; }
.checklist li { position: relative; padding-left: 28px; margin-bottom: 0.6em; }
.checklist li::before { content: ""; position: absolute; left: 4px; top: 0.45em; width: 12px; height: 7px; border-left: 2px solid var(--teal); border-bottom: 2px solid var(--teal); transform: rotate(-45deg); }
.timeline { list-style: none; padding: 0; border-left: 2px solid var(--line); margin-left: 6px; }
.timeline li { position: relative; padding: 0 0 14px 22px; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 0.55em; width: 12px; height: 12px; border-radius: 50%; background: var(--saffron); }
.link-list { padding-left: 1.2em; }
.link-list li { margin-bottom: 0.4em; }
.modules { padding-left: 0; list-style: none; }
.modules li { padding: 12px 16px; background: var(--white); border-radius: 12px; border: 1px solid var(--line); margin-bottom: 10px; }

.facts { display: grid; gap: 10px; margin: 1.2em 0; }
.facts > div { display: grid; grid-template-columns: 130px 1fr; gap: 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.facts dt { font-weight: 700; color: var(--teal); }
.facts dd { margin: 0; }
.infobox { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 22px; box-shadow: var(--shadow); }
.note { font-size: 0.97rem; color: var(--ink-soft); }
.empty { padding: 18px; border: 1px dashed var(--line); border-radius: 12px; background: var(--white); }
.prose h2 { margin-top: 1.4em; }

/* Planning */
.week { display: grid; gap: 12px; margin: 24px 0 8px; }
@media (min-width: 640px) { .week { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); } }
.day { background: var(--white); border-radius: 12px; border: 1px solid var(--line); padding: 14px 16px; }
.day-name { font-weight: 700; color: var(--teal); margin-bottom: 6px; }
.day-slot { display: flex; flex-direction: column; margin: 0 0 8px; }
.day-time { font-weight: 600; }
.day-title { font-size: 0.92rem; color: var(--ink-soft); }

/* Tarifs */
.price-intro { display: grid; gap: 24px; margin-bottom: 28px; }
@media (min-width: 860px) { .price-intro { grid-template-columns: 360px 1fr; align-items: start; } }
.price-essai { background: var(--white); border: 2px solid var(--saffron); border-radius: var(--radius-card); padding: 24px; }
.price-big { font-family: var(--font-heading); font-size: 2.6rem; color: var(--teal); line-height: 1; margin-bottom: 0.4em; }
.price-big span { font-family: var(--font-body); font-size: 1rem; color: var(--ink); }
.price-grid { display: grid; gap: 18px; }
@media (min-width: 700px) { .price-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .price-grid { grid-template-columns: repeat(3, 1fr); } }
.price-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 22px; }
.price-card h3 { margin-bottom: 0.3em; }
.price-note { font-size: 0.92rem; color: var(--saffron-ink); font-weight: 600; margin-bottom: 0.4em; }
.price-rythme { color: var(--ink-soft); font-size: 0.95rem; }
.price-list { margin: 0 0 0.8em; }
.price-list > div { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--line); }
.price-list dt { flex: 1; }
.price-list dd { margin: 0; font-weight: 700; white-space: nowrap; }
.price-option { font-size: 0.93rem; }
.price-perks { font-size: 0.93rem; padding-left: 1.1em; color: var(--ink-soft); }

/* Événements */
.event-list { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 16px; }
@media (min-width: 700px) { .event-list { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); } }
.event-card { background: var(--white); border: 1px solid var(--line); border-left: 4px solid var(--saffron); border-radius: 12px; padding: 18px; display: flex; flex-direction: column; }
.event-card p { margin-bottom: 0.4em; }
.event-date { font-weight: 700; color: var(--teal); }
.event-meta { font-size: 0.93rem; color: var(--ink-soft); flex: 1; }
.event-card .btn { align-self: flex-start; margin-top: 8px; }

/* Articles */
.article-links { display: grid; gap: 8px; padding: 0; list-style: none; }
.article-links li { margin: 0; }
.article-links a {
    display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
    padding: 12px 16px; background: var(--white); border: 1px solid var(--line);
    border-radius: 10px; text-decoration: none; font-weight: 600;
}
.article-links a:hover { border-color: var(--teal); background: var(--teal-soft); }
.article-links time { flex: none; color: var(--ink-soft); font-size: 0.88rem; font-weight: 400; }
@media (max-width: 480px) {
    .article-links a { align-items: flex-start; flex-direction: column; gap: 2px; }
}
.article-meta { color: var(--ink-soft); font-size: 0.92rem; }
.article-summary, .article-background { padding: 16px 20px; background: var(--saffron-soft); border-left: 4px solid var(--saffron); }
.article-content { overflow-wrap: anywhere; }
.article-content img { height: auto; max-width: 100%; margin: 20px auto; border-radius: 10px; }
.article-content figure { margin: 24px 0; }
.article-content blockquote { margin: 20px 0; padding-left: 18px; border-left: 3px solid var(--teal); color: var(--ink-soft); }
.article-tags { margin-top: 32px; color: var(--ink-soft); font-size: 0.92rem; }

/* FAQ */
.faq { margin: 16px 0 32px; }
.faq-item { background: var(--white); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; }
.faq-item summary { cursor: pointer; padding: 14px 48px 14px 18px; font-weight: 600; list-style: none; position: relative; min-height: 44px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; position: absolute; right: 18px; top: 10px; font-size: 1.5rem; color: var(--teal); }
.faq-item[open] summary::after { content: "–"; }
.faq-answer { padding: 0 18px 8px; }

/* Appel final */
.cta-final { text-align: center; background:
    repeating-conic-gradient(from 0deg at 50% 120%, rgba(230, 183, 131, 0.08) 0deg 4deg, transparent 4deg 12deg),
    var(--teal); }
.cta-final .cta-row { justify-content: center; }
.cta-address { margin-top: 1.2em; font-size: 0.95rem; opacity: 0.9; }

/* ---------------------------------------------------------------- formulaires */
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; }
.optional { font-weight: 400; color: var(--ink-soft); font-size: 0.9em; }
input[type="text"], input[type="email"], input[type="tel"], input[type="password"], textarea {
    width: 100%; min-height: 48px; padding: 10px 12px;
    border: 1.5px solid #9aa7b0; border-radius: 10px; background: var(--white);
    font: inherit; color: var(--ink);
}
textarea { min-height: 96px; resize: vertical; }
input:focus, textarea:focus { border-color: var(--teal); outline: 3px solid rgba(16, 91, 102, 0.25); outline-offset: 0; }
.has-error input, .has-error textarea { border-color: var(--error); }
.field-error { color: var(--error); font-weight: 600; font-size: 0.93rem; margin: 6px 0 0; }
.hint { font-size: 0.88rem; color: var(--ink-soft); margin: 6px 0 0; }
.alert { padding: 12px 16px; border-radius: 10px; background: var(--teal-soft); border-left: 4px solid var(--teal); }
.alert-error { background: #fbeae8; border-color: var(--error); color: #6e1a13; }
.alert-success { background: #e6f3ea; border-color: var(--success); color: #134a28; }
.inline-form { display: grid; gap: 12px; max-width: 480px; margin-bottom: 20px; }

/* Réservation */
.booking-layout { display: grid; gap: 32px; }
@media (min-width: 960px) { .booking-layout { grid-template-columns: 1.6fr 1fr; align-items: start; } }
.booking-main { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 20px; box-shadow: var(--shadow); }
.booking-aside { padding: 4px; }
.resa-types { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.segment {
    display: inline-flex; align-items: center; min-height: 40px; padding: 6px 14px; border-radius: 999px;
    border: 1.5px solid var(--line); text-decoration: none; color: var(--ink); font-size: 0.93rem; font-weight: 600; background: var(--white);
}
.segment.is-active { background: var(--teal); border-color: var(--teal); color: var(--white); }
.resa-step { border: 0; padding: 0; margin: 0 0 18px; }
.resa-step legend { font-weight: 700; font-size: 1.05rem; margin-bottom: 12px; display: flex; align-items: center; gap: 10px; }
.step-num { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--saffron); color: var(--ink); font-size: 0.9rem; }
.slots { display: grid; gap: 8px; max-height: 340px; overflow-y: auto; padding: 2px; }
.slot {
    display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center;
    padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; background: var(--white);
}
.slot:hover { border-color: var(--teal); }
.slot:has(input:checked) { border-color: var(--teal); background: var(--teal-soft); }
.slot input { width: 20px; height: 20px; accent-color: var(--teal); margin: 0; }
.slot-body { display: flex; flex-direction: column; }
.slot-date { font-weight: 700; }
.slot-title { font-size: 0.9rem; color: var(--ink-soft); }
.slot-meta { display: flex; flex-direction: column; align-items: flex-end; font-size: 0.88rem; text-align: right; }
.slot-bookings { color: var(--ink-soft); font-size: 0.8rem; }
.slot-places.is-low { color: var(--saffron-ink); font-weight: 700; }
.slot-price { font-weight: 700; }
.slot-online { display: inline-grid; place-items: center; min-width: 1.45em; min-height: 1.45em; border-radius: 50%; background: #c62828; color: #fff; font-weight: 800; line-height: 1; padding: 2px; }
.slot.is-full { opacity: 0.55; cursor: not-allowed; }
.resa-info { font-size: 0.9rem; color: var(--ink-soft); }
.resa-ok { text-align: center; padding: 8px 0; }
.resa-ok:focus { outline: none; }
.resa-ok-icon { width: 56px; height: 56px; margin: 0 auto 12px; display: grid; place-items: center; border-radius: 50%; background: var(--success); color: #fff; font-size: 1.8rem; }
.resa-ok-title { font-family: var(--font-heading); font-size: 1.9rem; color: var(--teal); margin-bottom: 0.3em; }
.resa-ok .checklist { text-align: left; max-width: 460px; margin: 16px auto; }
.resa-list { list-style: none; padding: 0; }
.resa-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.loading { color: var(--ink-soft); }

/* Modale */
.resa-dialog {
    width: min(720px, calc(100vw - 16px)); max-height: calc(100vh - 16px); padding: 0;
    border: 0; border-radius: var(--radius-card); box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
    background: var(--white); color: var(--ink);
}
.resa-dialog::backdrop { background: rgba(10, 60, 67, 0.55); }
.dialog-head { position: sticky; top: 0; z-index: 1; display: flex; justify-content: space-between; align-items: center; padding: 12px 16px 12px 20px; background: var(--white); border-bottom: 1px solid var(--line); }
.dialog-title { font-family: var(--font-heading); font-size: 1.5rem; color: var(--teal); margin: 0; }
.dialog-close { width: 44px; height: 44px; border: 0; background: none; font-size: 1.8rem; line-height: 1; color: var(--ink); cursor: pointer; border-radius: 50%; }
.dialog-close:hover { background: var(--teal-soft); }
.dialog-body { padding: 18px 20px 22px; }
.dialog-body .slots { max-height: 260px; }
body.dialog-open { overflow: hidden; }

/* Consentement */
.consent {
    position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 60; max-width: 640px; margin: 0 auto;
    background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    padding: 16px 18px; font-size: 0.95rem;
}
.consent-actions { display: flex; gap: 10px; justify-content: flex-end; }

/* Pied de page */
.site-footer { background: var(--teal-dark); color: rgba(255, 255, 255, 0.92); padding: 48px 0 24px; font-size: 0.97rem; }
.site-footer a { color: var(--white); }
.site-footer .link-button { color: var(--white); min-height: 0; }
.footer-grid { display: grid; gap: 28px; }
@media (min-width: 700px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .footer-grid { grid-template-columns: 1.3fr 1fr 1fr 0.8fr; } }
.footer-brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-heading); font-size: 1.6rem; color: var(--white); }
.footer-title { font-weight: 700; color: #f4d9b8; margin-bottom: 0.6em; }
.site-footer address { font-style: normal; }
.footer-hours, .footer-links { list-style: none; padding: 0; }
.footer-hours li span { display: inline-block; min-width: 86px; font-weight: 600; }
.footer-links li { margin-bottom: 0.35em; }
.footer-legal { border-top: 1px solid rgba(255, 255, 255, 0.2); margin-top: 28px; padding-top: 18px; font-size: 0.88rem; }
.footer-legal p { margin-bottom: 0.4em; }

/* Administration */
.admin-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0 28px; padding: 10px; background: var(--white); border: 1px solid var(--line); border-radius: 12px; }
.admin-nav a { display: block; padding: 8px 12px; border-radius: 8px; text-decoration: none; font-weight: 600; background: var(--cream); }
.admin-nav a:hover { background: var(--teal-soft); }
.admin-nav a[aria-current="page"] { color: var(--white); background: var(--teal); }
.admin-week-nav { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin: 16px 0; }
.admin-management-dialog .dialog-body { max-height: calc(100vh - 90px); overflow-y: auto; }
.admin-slot { background: var(--white); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; padding: 0 16px; }
.admin-slot summary { padding: 12px 0; cursor: pointer; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.admin-slot .badge { margin: 0; }
.admin-card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; }
.admin-slot-card { min-width: 0; padding: 16px; margin: 0; box-shadow: var(--shadow); }
.admin-slot-heading { padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.admin-slot-heading h3 { display: inline-block; margin: 0 0 0 8px; }
.admin-slot-heading .admin-slot-title { display: block; margin: 8px 0; font-family: "Astonpoliz", var(--font-body); font-weight: 400; }
.admin-slot-heading p { margin: 6px 0; }
.admin-slot-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.admin-group-mail { margin: 10px 0 0; }
.admin-group-mail summary { font-weight: 600; }
.admin-group-mail .admin-card { margin-bottom: 0; }
.admin-table { width: 100%; border-collapse: collapse; margin-bottom: 14px; font-size: 0.93rem; }
.admin-table th, .admin-table td { text-align: left; padding: 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-section { margin: 28px 0; }
.admin-section > h2 { margin-bottom: 12px; }
.admin-toolbar, .admin-inline { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; }
.admin-toolbar { justify-content: space-between; align-items: center; }
.admin-toolbar p { margin: 0; }
.admin-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 12px; }
.admin-card { display: grid; gap: 10px; padding: 16px; margin: 10px 0; background: var(--white); border: 1px solid var(--line); border-radius: 12px; }
.admin-card label { display: grid; gap: 4px; font-weight: 600; }
.admin-card input, .admin-card select, .admin-card textarea, .admin-inline input { min-width: 0; max-width: 100%; padding: 8px; border: 1px solid var(--line); border-radius: 6px; font: inherit; }
.admin-card .check { display: flex; align-items: center; gap: 8px; }
.admin-card .check input { width: auto; }
.admin-event-form { max-width: 760px; }
.cms-settings-form { max-width: 1100px; }
.cms-settings-group { padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.cms-settings-group summary { cursor: pointer; font-weight: 700; }
.cms-settings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px; padding-top: 12px; }
.cms-setting-field { min-width: 0; }
.cms-setting-field textarea { width: 100%; resize: vertical; }
.cms-page-picker { margin: 16px 0; }
.cms-page-picker select { min-width: min(100%, 280px); padding: 8px; border: 1px solid var(--line); border-radius: 6px; font: inherit; }
.cms-meta-form { max-width: 980px; }
.cms-meta-form h3 { margin: 0; }
.cms-meta-actions { display: flex; justify-content: flex-start; }
.cms-editor-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; align-items: start; }
.cms-editor-layout > * { min-width: 0; }
.cms-preview { display: block; width: 100%; height: 620px; background: var(--white); border: 1px solid var(--line); border-radius: 12px; }
.cms-text-form { max-height: 680px; overflow: auto; }
.cms-text-field { padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.cms-text-field textarea { width: 100%; resize: vertical; }
.cms-reset-form { margin-top: 10px; }
@media (min-width: 1100px) { .cms-editor-layout { grid-template-columns: minmax(0, 1fr) minmax(360px, 0.8fr); } }
.event-defaults-editor { margin: 16px 0 24px; }
.event-defaults-editor > summary span { margin-left: 8px; color: var(--muted); font-weight: 400; }
.event-default-fields { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 14px; border: 1px solid var(--line); border-radius: 8px; }
.event-default-fields legend { padding: 0 6px; font-weight: 700; }
.event-default-fields label { display: grid; gap: 5px; }
.event-default-fields textarea { width: 100%; resize: vertical; }
@media (min-width: 800px) { .event-default-fields { grid-template-columns: minmax(0, 1fr) minmax(220px, 0.35fr); align-items: start; } }
.admin-color-field { display: flex; align-items: center; gap: 10px; font-weight: 400; }
.admin-color-field input[type="color"] { width: 56px; min-width: 56px; height: 40px; padding: 3px; cursor: pointer; }
.event-color-indicator { display: inline-block; width: 18px; height: 18px; border: 1px solid var(--line); border-radius: 50%; vertical-align: middle; }
.admin-closures { padding-left: 20px; }
.admin-closures li { margin: 8px 0; }
.admin-closures form { display: inline; }
.admin-list { min-width: 0; }
.admin-slot { min-width: 0; }
.table-scroll { overflow-x: auto; }
.admin-login { align-items: end; }
@media (max-width: 600px) { .admin-login { display: grid; } }

/* ---------------------------------------------------------------- espace perso */
.page-head-compact { padding: 22px 0 20px; }
.espace-layout { display: grid; gap: 24px; grid-template-columns: minmax(0, 1fr); }
.espace-layout > * { min-width: 0; } /* sans cela, le menu horizontal élargit la page sur mobile */
@media (min-width: 960px) { .espace-layout { grid-template-columns: 240px minmax(0, 1fr); align-items: start; } }
.espace-main { min-width: 0; }
.espace-main > h2, .espace-main .h3 { margin-top: 1.4em; }
.espace-nav { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 10px; }
.espace-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.espace-nav a { display: block; padding: 8px 12px; border-radius: 10px; text-decoration: none; color: var(--ink); font-weight: 500; background: var(--cream); }
@media (min-width: 960px) { .espace-nav a { background: none; padding: 10px 12px; } }
.espace-nav a:hover { background: var(--teal-soft); }
.espace-nav a[aria-current="page"] { background: var(--teal); color: var(--white); }
.espace-nav a.admin-access { background: var(--cta-orange); color: var(--ink); font-weight: 700; }
.espace-nav a.admin-access:hover { background: var(--cta-orange-dark); }
.espace-nav form { padding: 6px 12px 0; }
@media (min-width: 960px) {
    .espace-nav { position: sticky; top: 88px; }
    .espace-nav ul { flex-direction: column; overflow: visible; }
}
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
.auth-card, .stack-form.infobox, .infobox + .infobox { margin-top: 0; }
.infobox { margin-bottom: 20px; }
.auth-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 22px; box-shadow: var(--shadow); }
.auth-links { margin-top: 14px; font-size: 0.95rem; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 8px 0; font-weight: 400; cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--teal); flex: none; }
.stack-form .field { max-width: 640px; }
select { width: 100%; min-height: 48px; padding: 10px 12px; border: 1.5px solid #9aa7b0; border-radius: 10px; background: var(--white); font: inherit; color: var(--ink); }
.alert { margin-bottom: 16px; }
.alert-info { background: var(--saffron-soft); border-color: var(--saffron); color: var(--ink); }
.badge-success { background: #e6f3ea; color: #134a28; }
.badge-warning { background: #fdf0d5; color: #6b4300; }
.badge-online { background: #e8e6f8; color: #3a2f8a; }
.star { color: var(--saffron-dark); }
.event-card.is-featured { box-shadow: var(--shadow); }
.event-desc { font-size: 0.93rem; }
.resa-who { margin-bottom: 12px; }
.btn-danger { background: var(--error); color: var(--white); }
.btn-danger:hover { background: #7f1d16; color: var(--white); }
.danger-zone { border-color: rgba(163, 39, 29, 0.35); }

.dash-grid { display: grid; gap: 16px; margin-bottom: 8px; }
@media (min-width: 700px) { .dash-grid { grid-template-columns: repeat(3, 1fr); } }
.dash-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 18px; box-shadow: var(--shadow); }
.dash-card p { margin-bottom: 0.5em; }
.dash-next { border-top: 4px solid var(--saffron); }
.dash-label { font-size: 0.82rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--saffron-ink); }
.dash-big { font-family: var(--font-heading); font-size: 1.45rem; color: var(--teal); line-height: 1.2; }

.resa-rows { list-style: none; padding: 0; margin: 0 0 16px; }
.resa-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px; background: var(--white); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 8px; }
.resa-row p { margin: 0; }
.resa-row-date { font-weight: 700; }
.resa-row-title { color: var(--ink-soft); font-size: 0.95rem; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.resa-row .badge { margin: 0; }

.week-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.week-nav .btn { flex: none; }
.week-title { margin: 0; font-weight: 700; color: var(--teal); text-align: center; flex: 1; min-width: 0; }
.calendar { display: grid; gap: 10px; }
.cal-day { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 12px; display: grid; gap: 8px; min-width: 0; }
@media (min-width: 700px) { .cal-day { grid-template-columns: 150px minmax(0, 1fr); align-items: start; } }
.cal-day.is-today { border-color: var(--saffron); box-shadow: 0 0 0 2px rgba(230, 183, 131, 0.25); }
.cal-day-title { font-family: var(--font-body); font-size: 0.98rem; font-weight: 700; color: var(--teal); margin: 6px 0 0; }
.cal-slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; min-width: 0; }
.cal-empty { margin: 6px 0 0; }
.cal-slot { border-radius: 10px; background: var(--teal-soft); padding: 10px; font-size: 0.92rem; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cal-slot p { margin: 0; }
.cal-slot.is-event { background: var(--saffron-soft); }
.cal-slot.is-booked { outline: 2px solid var(--success); outline-offset: -2px; }
.cal-slot.is-past { opacity: 0.55; }
.cal-time { font-weight: 700; }
.cal-title { overflow-wrap: anywhere; }
.cal-slot .btn { width: 100%; margin-top: auto; }
.cal-slot .badge { margin: 0; }
.cal-slot form { margin: 0; }

.table-recurrentes { width: 100%; border-collapse: collapse; margin-bottom: 18px; background: var(--white); border-radius: 12px; overflow: hidden; }
.table-recurrentes th, .table-recurrentes td { padding: 10px; border-bottom: 1px solid var(--line); text-align: center; }
.table-recurrentes th[scope="row"] { text-align: left; font-weight: 600; }
.table-recurrentes thead th { background: var(--teal); color: var(--white); font-weight: 600; }
.radio-cell { display: inline-grid; place-items: center; min-width: 44px; min-height: 44px; cursor: pointer; }
.radio-cell input { width: 20px; height: 20px; accent-color: var(--teal); }
.choice-grid { display: grid; gap: 10px; }
@media (min-width: 700px) { .choice-grid { grid-template-columns: repeat(2, 1fr); } }
.choice { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--white); cursor: pointer; font-weight: 400; }
.choice:has(input:checked) { border-color: var(--teal); background: var(--teal-soft); }
.choice input { margin-top: 4px; accent-color: var(--teal); }
.resa-ok-icon.is-pending { background: var(--saffron); color: var(--ink); }

/* bouton grisé : créneau complet */
.btn-disabled, .btn-disabled:hover { background: #e3e6e8; color: #5b6570; border-color: transparent; cursor: not-allowed; transform: none; box-shadow: none; }
.slot-full { font-weight: 700; color: #5b6570; }
.resa-row { flex-wrap: wrap; }
.resa-row > div { flex: 1 1 220px; min-width: 0; }
.resa-row form { display: inline-flex; }
@media (max-width: 520px) {
    .table-recurrentes th, .table-recurrentes td { padding: 8px 4px; font-size: 0.9rem; }
    .radio-cell { min-width: 40px; }
    .dash-big { font-size: 1.25rem; }
}
