/* Violon Riviera — feuille de style */

@font-face { font-family: "Poppins"; font-weight: 600; font-display: swap; src: url("../fonts/poppins-600.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 700; font-display: swap; src: url("../fonts/poppins-700.woff2") format("woff2"); }
@font-face { font-family: "Roboto"; font-weight: 400; font-display: swap; src: url("../fonts/roboto-400.woff2") format("woff2"); }
@font-face { font-family: "Roboto"; font-weight: 700; font-display: swap; src: url("../fonts/roboto-700.woff2") format("woff2"); }

:root {
  --dark: #0c131f;
  /* Fond « bleu nuit » : même teinte, jeux de clarté */
  --night:
    radial-gradient(ellipse 70% 60% at 12% 8%, rgba(46, 70, 112, .55) 0%, transparent 60%),
    radial-gradient(ellipse 60% 55% at 92% 85%, rgba(36, 56, 92, .5) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 60% 40%, rgba(22, 34, 56, .6) 0%, transparent 70%),
    linear-gradient(160deg, #101a2b 0%, #0c131f 45%, #070c15 100%);
  --shade1: #284069;
  --shade2: #456db2;
  --main: #8ba5d2;
  --light: #eef2f9;
  --white: #ffffff;
  --text: #1d2533;
  --muted: #5a6475;
  --radius: 14px;
  --max: 1140px;
  --head: "Poppins", system-ui, sans-serif;
  --copy: "Roboto", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--night); background-color: var(--dark); background-attachment: fixed; }
body {
  margin: 0;
  font-family: var(--copy);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--shade2); }
a:hover { color: var(--shade1); }
h1, h2, h3 { font-family: var(--head); font-weight: 600; line-height: 1.2; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.25rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--white); padding: 8px 12px; }

/* ---------- En-tête ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #e6eaf1;
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; min-height: 72px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--head); font-weight: 700; font-size: 1.2rem; color: var(--dark); text-decoration: none; }
.brand img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.brand:hover { color: var(--shade1); }

.nav ul { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; }
.nav a {
  display: block; padding: 8px 14px; border-radius: 999px;
  font-family: var(--head); font-weight: 600; font-size: .95rem;
  color: var(--dark); text-decoration: none;
}
.nav a:hover { background: var(--light); }
.nav a[aria-current="page"] { background: var(--dark); color: var(--white); }

/* Sélecteur de langue */
.brand { margin-right: auto; white-space: nowrap; }
@media (max-width: 420px) {
  .brand { font-size: 1.02rem; gap: 8px; }
  .lang-switch a { padding: 5px 8px; }
}
.lang-switch { order: 2; display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--light); }
.lang-switch a {
  display: block; padding: 5px 10px; border-radius: 999px; text-decoration: none;
  font-family: var(--head); font-weight: 600; font-size: .78rem; letter-spacing: .04em; color: var(--muted);
}
.lang-switch a:hover { color: var(--dark); }
.lang-switch a[aria-current="true"] { background: var(--white); color: var(--dark); box-shadow: 0 1px 4px rgba(12, 19, 31, .12); }
.nav-toggle { order: 3; }

.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; color: var(--dark); }
.nav-toggle svg { width: 28px; height: 28px; }

@media (max-width: 880px) {
  .nav-toggle { display: block; }
  .nav { position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid #e6eaf1; display: none; }
  .nav.open { display: block; }
  .nav ul { flex-direction: column; padding: 8px 16px 16px; }
  .nav a { padding: 12px 14px; }
}

/* ---------- Boutons ---------- */
.btn {
  display: inline-block; padding: 13px 28px; border-radius: 999px;
  font-family: var(--head); font-weight: 600; font-size: 1rem;
  background: var(--main); color: var(--dark); text-decoration: none; border: 0; cursor: pointer;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--white); color: var(--dark); transform: translateY(-1px); }
.btn-dark { background: var(--dark); color: var(--white); }
.btn-dark:hover { background: var(--shade1); color: var(--white); }

/* ---------- Sections ---------- */
.section { padding: clamp(56px, 9vw, 110px) 0; }
.section-dark { background: var(--night); background-color: var(--dark); background-attachment: fixed; color: var(--white); }
.section-dark a:not(.btn) { color: var(--main); }
.section-light { background: var(--light); }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.split.reverse .split-media { order: 2; }
.split-wide-media { grid-template-columns: 1fr 1.35fr; } /* image ~15 % plus grande */
.split-media img { width: 100%; border-radius: var(--radius); aspect-ratio: 4 / 3; object-fit: cover; }
.split-media.contain img { object-fit: contain; aspect-ratio: auto; }
.lead { font-family: var(--head); font-weight: 600; font-size: clamp(1.1rem, 2.2vw, 1.4rem); line-height: 1.45; color: var(--main); }

@media (max-width: 800px) {
  .split { grid-template-columns: 1fr; }
  .split.reverse .split-media { order: 0; }
}

/* Sur écrans tactiles, background-attachment: fixed est mal géré */
@media (hover: none) {
  html, .section-dark, .site-footer, .page-hero { background-attachment: scroll; }
}

/* ---------- Bandeau page ---------- */
.page-hero { position: relative; min-height: 380px; display: flex; align-items: flex-end; color: var(--white); background: var(--night); background-color: var(--dark); background-attachment: fixed; overflow: hidden; }
.page-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 15%; opacity: .55; }
.page-hero .container { position: relative; padding-top: 120px; padding-bottom: 48px; }
.page-hero h1 { margin: 0; }

/* ---------- Section avec image de fond ---------- */
.bg-hero { position: relative; overflow: hidden; min-height: min(78vh, 680px); display: flex; align-items: center; }
.bg-hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% center; }
.bg-hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(12, 19, 31, .92) 0%, rgba(12, 19, 31, .7) 45%, rgba(12, 19, 31, .3) 100%);
}
.bg-hero .container { position: relative; z-index: 1; }
.bg-hero-text { max-width: 560px; }
@media (max-width: 800px) {
  .bg-hero::after { background: rgba(12, 19, 31, .7); }
}

/* ---------- Cartes ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.card { background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: 0 6px 24px rgba(12, 19, 31, .08); }
.card img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.card-body { padding: 22px 24px 26px; }
.card-body h3 { color: var(--shade1); }
.card-body p { margin: 0; color: var(--muted); }
@media (max-width: 880px) { .cards { grid-template-columns: 1fr; max-width: 480px; margin: 0 auto; } }

/* ---------- Témoignages ---------- */
.testimonials { text-align: center; background: var(--white); }
.slider {
  display: grid; grid-template-columns: auto minmax(0, 700px) auto;
  justify-content: space-between; align-items: center; row-gap: clamp(40px, 7vw, 110px);
  max-width: 1320px; margin: 0 auto;
}
.slider-box { display: grid; border: 4px solid #333; padding: clamp(40px, 7vw, 90px) clamp(24px, 6vw, 80px); }
.slide { grid-area: 1 / 1; margin: 0; align-self: center; opacity: 0; visibility: hidden; transition: opacity .5s ease, visibility .5s; }
.slide.active { opacity: 1; visibility: visible; }
.slide figcaption { font-family: var(--head); font-weight: 600; font-size: clamp(1.25rem, 2.4vw, 1.6rem); color: #333; margin-bottom: 18px; }
.slide blockquote { margin: 0; font-size: 1.1rem; line-height: 1.65; color: #333; }
.slider-arrow {
  display: grid; place-items: center; width: 48px; height: 48px; padding: 0;
  border: 0; background: none; color: #333; cursor: pointer; border-radius: 50%;
}
.slider-arrow svg { width: 30px; height: 30px; }
.slider-arrow:hover { background: var(--light); }
.slider-dots { grid-column: 1 / -1; display: flex; justify-content: center; gap: 8px; }
.slider-dots button { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%; background: #d4d4d4; cursor: pointer; }
.slider-dots button[aria-current="true"] { background: #333; }
@media (max-width: 600px) {
  .slider { grid-template-columns: auto minmax(0, 1fr) auto; column-gap: 4px; }
  .slider-arrow { width: 36px; height: 36px; }
}

/* Page Cours de violon */
.section-divider { border-top: 1px solid rgba(255, 255, 255, .08); }
.section-head { text-align: center; max-width: 640px; margin: 0 auto clamp(36px, 5vw, 56px); }
.section-head h2 { margin: 0; }
.eyebrow {
  margin: 0 0 10px; font-family: var(--head); font-weight: 600; font-size: .85rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--main);
}
.courses { display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; align-items: start; }
.course {
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--radius); padding: clamp(26px, 4vw, 40px);
}
.course h3 { font-size: 1.4rem; color: var(--main); margin-bottom: 20px; }
.course p { margin: 0; color: rgba(255, 255, 255, .85); }
.durations { margin: 0; }
.durations div {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 14px 0; border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.durations div:last-child { border-bottom: 0; padding-bottom: 0; }
.durations div:first-child { padding-top: 0; }
.durations dt { color: rgba(255, 255, 255, .9); }
.durations dd { margin: 0; font-family: var(--head); font-weight: 600; color: var(--main); white-space: nowrap; }
.price { text-align: center; }
.price p { margin: 0 0 8px; color: rgba(255, 255, 255, .85); }
.price-amount {
  font-family: var(--head); font-weight: 700; line-height: 1.1;
  font-size: clamp(2.6rem, 7vw, 4rem); color: var(--white) !important; margin-bottom: 14px !important;
}
.price-amount span { font-size: .45em; font-weight: 600; color: var(--main); }
.price-note {
  display: inline-block; margin-top: 16px !important; padding: 8px 18px; border-radius: 999px;
  background: rgba(139, 165, 210, .15); color: var(--main) !important; font-size: .95rem;
}
.cta { text-align: center; }
.cta p { color: rgba(255, 255, 255, .85); }
@media (max-width: 880px) { .courses { grid-template-columns: 1fr; } }

/* ---------- Formulaire ---------- */
.form { display: grid; gap: 18px; max-width: 640px; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form label { display: block; font-family: var(--head); font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.form input, .form textarea {
  width: 100%; padding: 12px 14px; font: inherit; color: var(--text);
  border: 1px solid #cdd5e3; border-radius: 10px; background: var(--white);
}
.form input:focus, .form textarea:focus { outline: 2px solid var(--main); border-color: var(--shade2); }
.form textarea { min-height: 160px; resize: vertical; }
.form .consent { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; color: var(--muted); }
.form .consent input { width: auto; margin-top: 4px; }
.form .hp { position: absolute; left: -9999px; }
.section-dark .form input:not([type=checkbox]), .section-dark .form textarea {
  background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .18); color: var(--white);
}
.section-dark .form input:focus, .section-dark .form textarea:focus { border-color: var(--main); background: rgba(255, 255, 255, .09); }
.section-dark .form .consent { color: rgba(255, 255, 255, .7); }
.section-dark .form input[type=checkbox] { accent-color: var(--main); }
.captcha:empty { display: none; }
.form-status { padding: 14px 16px; border-radius: 10px; display: none; }
.form-status.ok { display: block; background: #e6f4ea; color: #1e5b2e; }
.form-status.err { display: block; background: #fdecea; color: #8a1f17; }
@media (max-width: 600px) { .form .row { grid-template-columns: 1fr; } }

/* ---------- Textes légaux ---------- */
.prose { max-width: 760px; }
.prose h2 { font-size: 1.35rem; margin-top: 1.8em; color: var(--shade1); }

/* ---------- Page About Me ---------- */
.facts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.facts li {
  padding: 26px 22px; border-radius: var(--radius); text-align: center;
  background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1);
  font-family: var(--head); font-weight: 600; line-height: 1.4;
}
@media (max-width: 880px) { .facts { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .facts { grid-template-columns: 1fr; } }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--night); background-color: var(--dark); background-attachment: fixed; color: rgba(255,255,255,.75); padding: 40px 0; font-size: .92rem; border-top: 1px solid rgba(255, 255, 255, .08); }
.site-footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.site-footer a { color: rgba(255,255,255,.85); text-decoration: none; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer ul { list-style: none; display: flex; flex-wrap: wrap; gap: 20px; margin: 0; padding: 0; }

/* ---------- Effets au défilement ---------- */
/* La classe .js est posée dans le <head> : sans JavaScript (ou si main.js ne se charge pas
   en 3 s), elle est retirée et tout reste visible. */
.js .split > *,
.js .bg-hero-text,
.js .card,
.js .course,
.js .facts li,
.js .section-head,
.js .price,
.js .cta .container,
.js .slider-box,
.js .prose,
.js .form,
.js .section .container > .lead,
.js .page-hero h1 {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .8s ease, transform .8s cubic-bezier(.2, .7, .2, 1);
  transition-delay: var(--delay, 0s);
}
.js .is-visible { opacity: 1 !important; transform: none !important; }

/* Parallaxe */
.page-hero img { transform: scale(1.12); will-change: transform; }
.split-media img { will-change: transform; }

/* En-tête compact */
.site-header { transition: box-shadow .3s ease; }
.site-header .container { transition: min-height .3s ease; }
.brand img { transition: width .3s ease, height .3s ease; }
.site-header.scrolled { box-shadow: 0 4px 20px rgba(12, 19, 31, .08); }
.site-header.scrolled .container { min-height: 56px; }
.site-header.scrolled .brand img { width: 30px; height: 30px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .split > *, .js .bg-hero-text, .js .card, .js .course, .js .facts li, .js .section-head, .js .price, .js .cta .container, .js .slider-box,
  .js .prose, .js .form, .js .section .container > .lead, .js .page-hero h1 {
    opacity: 1; transform: none; transition: none;
  }
  .page-hero img, .split-media img, .bg-hero-img { transform: none !important; }
  .slide { transition: none; }
}

/* ---------- Popup de réservation ---------- */
html.has-dialog { overflow: hidden; }
.booking-dialog {
  width: min(60vw, 860px); max-width: calc(100vw - 24px); max-height: min(88vh, 820px);
  padding: 0; border: 0; border-radius: 22px; background: var(--white); color: var(--text);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .45); overflow: auto; overscroll-behavior: contain;
}
.booking-dialog::backdrop { background: rgba(12, 19, 31, .6); backdrop-filter: blur(6px); }
.booking-dialog[open] { animation: dialog-in .5s cubic-bezier(.16, 1, .3, 1); }
.booking-dialog[open]::backdrop { animation: backdrop-in .4s ease; }
.booking-dialog.is-closing { animation: dialog-out .28s ease forwards; }
.booking-dialog.is-closing::backdrop { animation: backdrop-out .28s ease forwards; }
@keyframes dialog-in { from { opacity: 0; transform: translateY(40px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes dialog-out { to { opacity: 0; transform: translateY(24px) scale(.97); } }
@keyframes backdrop-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes backdrop-out { to { opacity: 0; } }
@media (max-width: 900px) { .booking-dialog { width: min(92vw, 640px); } }

.booking { position: relative; padding: clamp(24px, 4vw, 44px); }
.booking a:not(.btn) { color: var(--shade2); }
.booking-close {
  position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; display: grid; place-items: center;
  border: 0; border-radius: 50%; background: transparent; color: var(--muted); cursor: pointer;
}
.booking-close:hover { background: var(--light); color: var(--dark); }
.booking-close svg { width: 22px; height: 22px; }
.booking-title { font-size: clamp(1.4rem, 2.6vw, 1.8rem); color: var(--dark); margin: 0 48px 18px 0; }

.booking-progress { margin-bottom: 26px; }
.booking-progress-bar { height: 5px; border-radius: 999px; background: var(--light); overflow: hidden; }
.booking-progress-bar span { display: block; height: 100%; width: 0; background: var(--shade2); border-radius: inherit; transition: width .4s ease; }
.booking-progress-label { margin: 8px 0 0; font-family: var(--head); font-weight: 600; font-size: .8rem; color: var(--muted); }

.step { border: 0; padding: 0; margin: 0 0 22px; min-width: 0; }
.step:not(.is-active) { display: none; }
.step.is-active { animation: step-in .35s ease; }
@keyframes step-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
.step legend { font-family: var(--head); font-weight: 600; font-size: 1.15rem; color: var(--dark); padding: 0; margin-bottom: 16px; }

.group-label { font-family: var(--head); font-weight: 600; font-size: .9rem; margin: 18px 0 10px; color: var(--dark); }
[data-when] > .group-label:first-child { margin-top: 0; }
.optional { font-weight: 400; color: var(--muted); }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.tile {
  position: relative; display: flex; flex-direction: column; gap: 4px; cursor: pointer;
  padding: 18px; border: 2px solid #dfe5ef; border-radius: 14px; background: var(--white);
  transition: border-color .2s, background .2s, transform .15s;
}
.tile:hover { border-color: var(--main); transform: translateY(-2px); }
.tile input, .chip input { position: absolute; opacity: 0; pointer-events: none; }
.tile-title { font-family: var(--head); font-weight: 600; color: var(--dark); line-height: 1.3; }
.tile-sub { font-size: .88rem; color: var(--muted); line-height: 1.4; }
.tile:has(input:checked) { border-color: var(--shade2); background: var(--light); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { cursor: pointer; }
.chip span {
  display: inline-block; padding: 8px 16px; border-radius: 999px; border: 2px solid #dfe5ef;
  font-family: var(--head); font-weight: 600; font-size: .88rem; transition: all .2s;
}
.chip:hover span { border-color: var(--main); }
.chip input:checked + span { background: var(--shade2); border-color: var(--shade2); color: var(--white); }
.tile:has(input:focus-visible), .chip:has(input:focus-visible) span { outline: 2px solid var(--shade2); outline-offset: 2px; }

.field { margin-top: 14px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row .field { margin-top: 0; }
.booking .field label { display: block; font-family: var(--head); font-weight: 600; font-size: .85rem; margin-bottom: 6px; }
.booking input[type=text], .booking input[type=email], .booking input[type=tel], .booking textarea {
  width: 100%; padding: 11px 14px; font: inherit; color: var(--text);
  border: 2px solid #dfe5ef; border-radius: 10px; background: var(--white);
}
.booking input:focus, .booking textarea:focus { outline: none; border-color: var(--shade2); }
.booking .consent { display: flex; gap: 10px; align-items: flex-start; margin-top: 16px; font-size: .88rem; color: var(--muted); cursor: pointer; }
.booking .consent input { margin-top: 4px; }
.booking .hp { position: absolute; left: -9999px; }
@media (max-width: 600px) { .field-row { grid-template-columns: 1fr; } .field-row .field + .field { margin-top: 14px; } }

.booking-error { color: #b3261e; font-weight: 700; font-size: .92rem; min-height: 1.4em; margin: 0 0 6px; }
.booking-nav { display: flex; align-items: center; gap: 12px; }
.booking-nav [data-next], .booking-nav [data-submit] { margin-left: auto; }
.btn-ghost { background: transparent; color: var(--muted); padding-left: 8px; padding-right: 8px; }
.btn-ghost:hover { background: transparent; color: var(--dark); transform: none; }
.booking .btn:not(.btn-ghost) { background: var(--shade2); color: var(--white); }
.booking .btn:not(.btn-ghost):hover { background: var(--shade1); }
.booking [hidden] { display: none !important; }
.booking-done { text-align: center; padding: 24px 0 8px; }
.booking-done h2 { color: var(--dark); }

@media (prefers-reduced-motion: reduce) {
  .booking-dialog[open], .booking-dialog[open]::backdrop, .step.is-active { animation: none; }
}
