/* Samouraï 83 Toulon — H comme Local. Vanilla, sans dépendance. */

@font-face { font-family: "Barlow Condensed"; src: url("fonts/barlow-condensed-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Barlow Condensed"; src: url("fonts/barlow-condensed-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("fonts/barlow-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("fonts/barlow-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --sumi: #1C1A1B;      /* encre */
  --kinu: #F5F5F1;      /* blanc du keikogi */
  --paper: #FFFFFF;
  --hi: #C8102E;        /* rouge hinomaru du logo */
  --hi-ink: #A50D25;
  --tatami: #2E6650;    /* vert tatami */
  --hai: #5F5B57;       /* cendre */
  --line: #DAD8D2;
  --kin: #9A7425;       /* or des médailles */
  --bg: var(--kinu);
  --fg: var(--sumi);
  --muted: var(--hai);
  --card: var(--paper);

  --f-disp: "Barlow Condensed", "Arial Narrow", sans-serif;
  --f-text: "Barlow", system-ui, sans-serif;
  --s-1: .875rem; --s0: 1.0625rem; --s1: 1.25rem; --s2: 1.6rem; --s3: 2.4rem; --s4: clamp(3.4rem, 9vw, 7.5rem);
  --gap: clamp(1rem, 3vw, 2rem);
  --sec: clamp(3.5rem, 8vw, 6.5rem);
  --wrap: 72rem;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #161415; --fg: #EDEBE6; --muted: #AAA49E; --card: #211E1F; --line: #3A3637;
    --hi: #E0303F; --hi-ink: #F2525E; --tatami: #6FB08F; --kin: #D2A94C; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --bg: #161415; --fg: #EDEBE6; --muted: #AAA49E; --card: #211E1F; --line: #3A3637;
    --hi: #E0303F; --hi-ink: #F2525E; --tatami: #6FB08F; --kin: #D2A94C; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body { margin: 0; background: var(--bg); color: var(--fg); font: 400 var(--s0)/1.6 var(--f-text); padding-bottom: 4.25rem; }
@media (min-width: 861px) { body { padding-bottom: 0; } }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--hi); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--f-disp); font-weight: 800; line-height: .95; margin: 0 0 .5em; letter-spacing: -.01em; }
h2 { font-size: var(--s3); }
h3 { font-size: var(--s2); font-weight: 600; }
p { margin: 0 0 1em; max-width: 64ch; }
sup { font-size: .6em; line-height: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 700px) { .wrap { padding: 0 clamp(16px, 4vw, 40px); } }
.small { font-size: var(--s-1); color: var(--muted); }
.skip { position: absolute; left: -999px; top: 0; background: var(--hi); color: #fff; padding: .6rem 1rem; z-index: 99; }
.skip:focus { left: 8px; top: 8px; }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .7rem 1.3rem; font: 600 var(--s1)/1 var(--f-disp); letter-spacing: .02em; text-decoration: none; border-radius: 2px; border: 2px solid transparent; cursor: pointer; }
.btn--red { background: var(--hi); color: #fff; }
.btn--red:hover { background: var(--hi-ink); }
.btn--line { border-color: currentColor; background: transparent; color: var(--fg); }
.btn--line:hover { background: var(--fg); color: var(--bg); }

/* En-tête */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top__in { max-width: var(--wrap); margin: 0 auto; padding: .5rem 16px; display: flex; align-items: center; gap: 1.5rem; }
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; font: 800 1.15rem/1 var(--f-disp); }
.brand img { width: 40px; height: auto; }
.nav { display: none; gap: 1.4rem; margin-left: auto; font: 600 var(--s1)/1 var(--f-disp); }
.nav a { text-decoration: none; padding: .5rem 0; border-bottom: 2px solid transparent; }
.nav a:hover { border-color: var(--hi); }
.top__call { margin-left: auto; min-height: 44px; padding: .5rem .9rem; font-size: 1.05rem; }
@media (min-width: 861px) { .nav { display: flex; } .top__call { margin-left: 0; } }

/* Hero : le disque rouge du logo, la photo en noir et blanc */
.hero { max-width: var(--wrap); margin: 0 auto; padding: clamp(2rem, 6vw, 4.5rem) 16px var(--sec); display: grid; gap: var(--gap); align-items: center; }
@media (min-width: 861px) { .hero { grid-template-columns: 1.15fr .85fr; padding-left: clamp(16px, 4vw, 40px); padding-right: clamp(16px, 4vw, 40px); } }
.hero__title { font-size: var(--s4); text-transform: uppercase; line-height: .86; margin-bottom: .35em; }
.hero__title span { display: block; color: var(--hi); }
.hero__sub { font: 600 var(--s2)/1.15 var(--f-disp); margin-bottom: .9rem; }
.hero__lead { color: var(--muted); }
.hero__facts { list-style: none; padding: 0; margin: 1.2rem 0 1.6rem; display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; font-weight: 600; }
.hero__facts li { display: flex; align-items: center; gap: .5rem; }
.hero__facts li::before { content: ""; width: .6rem; height: .6rem; border-radius: 50%; background: var(--hi); }
.hero__cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: .5rem; }
.next { margin-top: 1.25rem; font-weight: 600; min-height: 1.6em; }
.next strong { color: var(--tatami); }

.hero__visual { position: relative; margin: 0; max-width: 30rem; justify-self: center; width: 100%; }
.hinomaru { position: absolute; width: 88%; aspect-ratio: 1; border-radius: 50%; background: var(--hi); left: 40%; top: 36%; transform: translate(-50%, -50%); }
.hero__visual picture { position: relative; display: block; width: 64%; margin: 18% 0 0 auto; box-shadow: -14px 14px 0 var(--sumi); }
.hero__visual img { filter: grayscale(1) contrast(1.08); aspect-ratio: 2 / 3; object-fit: cover; }
.hero__visual figcaption { position: relative; font-size: var(--s-1); color: var(--muted); text-align: right; margin-top: 1.2rem; }
@media (prefers-reduced-motion: no-preference) {
  .hinomaru { animation: rise 1.1s cubic-bezier(.2,.7,.2,1) both; }
  @keyframes rise { from { transform: translate(-50%, -30%) scale(.85); opacity: 0; } to { transform: translate(-50%, -50%) scale(1); opacity: 1; } }
}

/* Sélecteur de cours */
.finder { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: var(--sec) 0; }
.intro { color: var(--muted); }
.finder__grid { display: grid; gap: var(--gap); margin: 2rem 0; }
@media (min-width: 861px) { .finder__grid { grid-template-columns: 22rem 1fr; } }
.pick fieldset { border: 0; padding: 0; margin: 0 0 1.4rem; }
.pick legend { font: 600 var(--s1)/1 var(--f-disp); margin-bottom: .7rem; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chips label { position: relative; }
.chips input { position: absolute; opacity: 0; inset: 0; }
.chips span { display: inline-flex; align-items: center; gap: .55rem; min-height: 44px; padding: .55rem 1rem; border: 2px solid var(--line); border-radius: 999px; font-weight: 600; cursor: pointer; background: var(--bg); }
.chips input:checked + span { border-color: var(--fg); background: var(--fg); color: var(--bg); }
.chips input:focus-visible + span { outline: 3px solid var(--hi); outline-offset: 2px; }
.obi { display: inline-block; width: 1.6rem; height: .5rem; border-radius: 1px; border: 1px solid #8f8a84; }
.obi--white { background: #fff; }
.obi--color { background: linear-gradient(90deg, #F2C230 0 20%, #E8822A 20% 40%, #3E8E4F 40% 60%, #2F5DA8 60% 80%, #7A4A2A 80%); }

.result { min-height: 10rem; }
.result h3 { margin-bottom: .2rem; }
.course { border-left: 4px solid var(--hi); padding: .2rem 0 .2rem 1rem; margin: 0 0 1.25rem; }
.course--extra { border-left-color: var(--tatami); }
.course p { margin: 0; }
.course .where { color: var(--muted); font-size: var(--s-1); }
.course ul { list-style: none; padding: 0; margin: .3rem 0; display: flex; flex-wrap: wrap; gap: .3rem .9rem; font-weight: 600; }
.result .note { font-size: var(--s-1); color: var(--muted); }
.result h4 { font: 600 var(--s1)/1.1 var(--f-disp); margin: 1.6rem 0 .8rem; color: var(--tatami); }

/* Planning hebdo */
.week { display: none; }
@media (min-width: 861px) {
  .week { display: grid; grid-template-columns: 3.2rem repeat(6, 1fr); gap: 0 6px; position: relative; margin-bottom: 1rem; }
  .plain { display: none; }
}

/* Agenda mobile : mêmes couleurs que la grille */
.agenda { display: none; }
@media (max-width: 860px) {
  .has-agenda .agenda { display: block; margin: 1.5rem 0 1rem; }
  .has-agenda .plain { display: none; }
}
@media (min-width: 600px) and (max-width: 860px) {
  .agenda__days { display: grid; grid-template-columns: 1fr 1fr; column-gap: var(--gap); }
}
.agenda__key { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem; font-size: var(--s-1); color: var(--muted); margin: 0 0 1rem; }
.agenda__key span { display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap; }
.agenda__key .k { display: inline-block; width: .9rem; height: .9rem; border-radius: 2px; border: 1px solid var(--line); }
.k--on { background: var(--tatami); border-color: var(--fg) !important; box-shadow: inset 0 0 0 1px var(--fg); }
.k--extra { background: var(--tatami); border-color: var(--tatami) !important; }
.k--off { background: var(--bg); opacity: .55; }
.agenda__day { padding: .6rem 0 .8rem; border-top: 2px solid var(--fg); }
.agenda__day h4 { font: 600 var(--s1)/1 var(--f-disp); margin: 0 0 .6rem; }
.agenda__day h4 span { font: 600 .72rem/1 var(--f-text); text-transform: uppercase; letter-spacing: .04em; color: var(--hi); margin-left: .4rem; }
.agenda__day ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.slot.slot--row { position: static; display: grid; grid-template-columns: 6.6rem 1fr; gap: .6rem; align-items: baseline; padding: .55rem .7rem; font-size: .88rem; line-height: 1.25; width: auto; }
.slot--row b { font-weight: 600; font-variant-numeric: tabular-nums; }
.slot--row small { display: block; font-size: .75rem; opacity: .85; }
.week__head { font: 600 var(--s1)/1 var(--f-disp); padding: .6rem 0; text-align: center; border-bottom: 2px solid var(--fg); }
.week__hours { position: relative; }
.week__hours span { position: absolute; right: .4rem; font-size: .75rem; color: var(--muted); transform: translateY(-50%); }
.week__col { position: relative; background: repeating-linear-gradient(to bottom, transparent 0 calc(var(--h) - 1px), var(--line) calc(var(--h) - 1px) var(--h)); }
.slot { position: absolute; left: 2px; right: 2px; padding: .2rem .35rem; border-radius: 2px; font-size: .74rem; line-height: 1.15; overflow: hidden; background: var(--bg); border: 1px solid var(--line); color: var(--muted); transition: opacity .2s; }
.slot b { display: block; font-weight: 600; }
.slot.is-on { background: var(--tatami); border-color: var(--fg); box-shadow: inset 0 0 0 1px var(--fg); color: #fff; z-index: 2; }
.slot.is-on b::after { content: " \2605"; }
.slot.is-extra { background: var(--tatami); border-color: var(--tatami); color: #fff; z-index: 1; }
.slot.is-off { opacity: .55; }
.slot--narrow { right: 50%; }
.slot--narrow2 { left: 50%; }

.plain__list { margin: 1rem 0; }
.plain__list div { padding: .7rem 0; border-bottom: 1px solid var(--line); }
.plain__list dt { font-weight: 600; }
.plain__list dd { margin: 0; color: var(--muted); }

.pics { display: grid; gap: var(--gap); margin-top: 2.5rem; }
@media (min-width: 700px) { .pics { grid-template-columns: repeat(3, 1fr); } }
.pics figure { margin: 0; }
.pics img { aspect-ratio: 4 / 3; object-fit: cover; width: 100%; }
figcaption { font-size: var(--s-1); color: var(--muted); margin-top: .5rem; }

/* Sections en deux colonnes */
.club, .prof, .acces { padding: var(--sec) 0; }
.split { display: grid; gap: calc(var(--gap) * 1.5); align-items: start; }
@media (min-width: 861px) { .split { grid-template-columns: 1fr 1fr; align-items: center; } .split--rev > :first-child { order: 0; } }
.club__pic, .prof__pic, .prof__inset { margin: 0; }
.club__pic img { aspect-ratio: 3 / 2; object-fit: cover; }
.prof { background: var(--sumi); color: #EDEBE6; }
.prof .btn--line { color: #EDEBE6; }
.prof__pic { max-width: 26rem; justify-self: center; position: relative; }
.prof__pic img { filter: grayscale(1) contrast(1.05); }
.prof__pic::after { content: ""; position: absolute; width: 5rem; height: 5rem; border-radius: 50%; background: var(--hi); right: -1rem; top: -1rem; z-index: -0; mix-blend-mode: normal; }
.prof__pic picture { position: relative; z-index: 1; display: block; }
.titles { list-style: none; padding: 0; margin: 0 0 1.4rem; font: 600 var(--s1)/1.25 var(--f-disp); }
.titles li { padding: .55rem 0; border-bottom: 1px solid #3A3637; }
.prof__inset { margin-top: 1.4rem; max-width: 28rem; }
.prof__inset img { aspect-ratio: 3 / 2; object-fit: cover; }

/* Palmarès */
.palm { padding: var(--sec) 0; background: var(--card); border-top: 1px solid var(--line); }
.palm__pic { margin: 0 0 2rem; }
.palm__pic img { width: 100%; aspect-ratio: 2.1 / 1; object-fit: cover; }
.timeline { list-style: none; padding: 0; margin: 0 0 2.5rem; display: grid; gap: 0; }
@media (min-width: 861px) { .timeline { grid-template-columns: 1fr 1fr; column-gap: var(--gap); } }
.timeline li { display: grid; grid-template-columns: 4.2rem 1fr; gap: 1rem; padding: .9rem 0; border-top: 1px solid var(--line); align-items: baseline; }
.timeline .y { font: 800 var(--s2)/1 var(--f-disp); color: var(--kin); }
.timeline p { margin: 0; }
.video { margin: 0 0 2rem; }
.video__btn { width: 100%; display: flex; align-items: center; gap: 1.2rem; padding: 1.2rem; background: var(--sumi); color: #EDEBE6; border: 0; border-radius: 2px; text-align: left; font: inherit; cursor: pointer; min-height: 7rem; }
.video__play { flex: none; width: 4rem; height: 4rem; border-radius: 50%; background: var(--hi); position: relative; }
.video__play::after { content: ""; position: absolute; left: 1.6rem; top: 1.25rem; border-style: solid; border-width: .75rem 0 .75rem 1.2rem; border-color: transparent transparent transparent #fff; }
.video__btn:hover .video__play { background: var(--hi-ink); }
.video iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; display: block; }
.rating { font: 600 var(--s1)/1.2 var(--f-disp); }
.rating strong { color: var(--kin); font-size: var(--s2); }

/* Accès + formulaire */
address { font-style: normal; font-size: var(--s1); margin-bottom: 1rem; line-height: 1.4; }
.form { background: var(--card); border: 1px solid var(--line); padding: clamp(1.2rem, 3vw, 2rem); display: grid; gap: .9rem; }
.form label { display: grid; gap: .3rem; font-weight: 600; }
.form input, .form textarea { font: inherit; padding: .7rem .8rem; border: 1px solid #8f8a84; border-radius: 2px; background: var(--bg); color: var(--fg); min-height: 44px; width: 100%; }
.form .consent { display: flex; gap: .6rem; align-items: flex-start; font-weight: 400; font-size: var(--s-1); }
.form .consent input { width: 1.2rem; min-height: 1.2rem; margin-top: .2rem; flex: none; }
.form .btn { justify-self: start; }
.form__msg { margin: 0; font-weight: 600; }
.hp { position: absolute; left: -9999px; }

/* Pied de page */
.foot { background: var(--sumi); color: #D8D4CE; padding: 3rem 0 2rem; font-size: var(--s-1); }
.foot a { color: #fff; }
.foot__in { display: grid; gap: 1.5rem; }
.foot__id { display: flex; gap: 1rem; align-items: center; }
.foot__id p { margin: 0; }
.foot details { border-top: 1px solid #3A3637; padding-top: .8rem; }
.foot summary { cursor: pointer; font-weight: 600; min-height: 44px; display: flex; align-items: center; }
.credit { color: #9C968F; margin: 0; }
.credit a { color: #C9C4BE; }

/* Barre d'actions mobile */
.mbar { position: fixed; z-index: 30; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(3, 1fr); background: var(--sumi); border-top: 3px solid var(--hi); }
.mbar a { color: #fff; text-decoration: none; text-align: center; padding: .95rem .3rem; font: 600 1.05rem/1 var(--f-disp); min-height: 52px; }
.mbar a:first-child { background: var(--hi); }
@media (min-width: 861px) { .mbar { display: none; } }
