/* Victor Garcia — Sport & Outdoor
   Mise en page : écran partagé façon road book. Panneau vert sapin fixe à gauche (nom, chapitres, portfolio, contact),
   chapitres photo à droite sur fond sable. Thème clair chaleureux unique : sable, brun, orange coucher de soleil,
   vert sapin et bleu lac. Sur téléphone : barre fine en haut + menu dépliant, la photo d'accueil apparaît tout de suite. */
@font-face { font-family: "Fraunces Variable"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("fonts/fraunces-latin-soft-normal.woff2") format("woff2"); }
@font-face { font-family: "Fraunces Variable"; font-style: italic; font-weight: 100 900; font-display: swap; src: url("fonts/fraunces-latin-soft-italic.woff2") format("woff2"); }
@font-face { font-family: "Figtree Variable"; font-style: normal; font-weight: 300 900; font-display: swap; src: url("fonts/figtree-latin-wght-normal.woff2") format("woff2"); }

:root {
  --sand: #F3EADC;
  --paper: #FAF5EC;
  --ink: #2B2219;
  --muted: #6C5E50;
  --rule: #E2D5C2;
  --sunset: #C8592B;
  --sunset-deep: #A8471F; /* version plus foncée pour les textes et boutons (contraste suffisant) */
  --apricot: #F2A65A;
  --pine: #2E4B3F;
  --pine-deep: #233B31;
  --lake: #2F6681;
  --display: "Fraunces Variable", "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Figtree Variable", "Figtree", "Segoe UI", system-ui, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body { overflow-x: clip; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { background: var(--sand); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.65; }
a { color: inherit; }
img { max-width: 100%; }
h1, h2, h3 { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 600; line-height: 1.02; margin: 0; text-wrap: balance; letter-spacing: -.01em; }
p { margin: 0; }
.label { font-family: var(--body); font-size: .74rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--lake); outline-offset: 3px; }

.layout { display: grid; grid-template-columns: minmax(300px, 35%) minmax(0, 1fr); min-height: 100vh; }

/* Left panel: pine green */
.panel { position: sticky; top: 0; height: 100vh; height: 100dvh; background: var(--pine); color: var(--sand); display: flex; flex-direction: column; justify-content: space-between; gap: 22px; padding: max(30px, env(safe-area-inset-top, 0px)) 36px 26px max(36px, env(safe-area-inset-left, 0px)); overflow-y: auto; }
.name { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 700; font-size: clamp(3rem, 5.4vw, 5.4rem); line-height: .9; letter-spacing: -.02em; }
.name a { text-decoration: none; }
.name em { display: block; font-style: italic; font-weight: 500; color: var(--apricot); }
.panel .label { color: rgba(243,234,220,.7); margin-top: 14px; }
.panel .sig { font-family: var(--display); font-variation-settings: "SOFT" 100; font-style: italic; font-weight: 400; font-size: 1.45rem; line-height: 1.25; color: var(--sand); margin-top: 26px; padding-left: 14px; border-left: 2px solid var(--apricot); }
.panel .base { margin-top: 14px; font-size: .85rem; color: rgba(243,234,220,.82); }
.toc { list-style: none; margin: 0; padding: 0; border-top: 1px solid rgba(243,234,220,.18); }
.toc li { border-bottom: 1px solid rgba(243,234,220,.18); }
.toc a { display: flex; gap: 14px; align-items: baseline; padding: 8px 0; text-decoration: none; font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 500; font-size: 1.32rem; transition: color .2s, padding-left .25s; }
.toc a span { font-family: var(--body); font-size: .72rem; font-weight: 600; color: rgba(243,234,220,.78); }
.toc a:hover, .toc a.on { color: var(--apricot); padding-left: 6px; }
.toc .sep a { font-family: var(--body); font-size: .8rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; padding: 7px 0; }
.panel-foot { display: flex; flex-direction: column; gap: 12px; }
.panel-foot .label { margin: 0; text-transform: none; letter-spacing: .02em; font-weight: 500; font-size: .85rem; }
.btn { display: inline-flex; justify-content: center; text-decoration: none; font-family: var(--body); font-weight: 700; font-size: 1rem; letter-spacing: .04em; padding: 13px 20px; background: var(--apricot); color: var(--pine-deep); border: 2px solid var(--apricot); border-radius: 999px; transition: background .2s, color .2s; }
.btn:hover { background: transparent; color: var(--apricot); }

/* Portfolio link in panel */
.pf-link { display: flex; justify-content: space-between; align-items: center; gap: 10px; text-decoration: none; border: 1.5px solid var(--apricot); color: var(--apricot); border-radius: 999px; padding: 10px 18px; font-weight: 700; font-size: .95rem; transition: background .2s, color .2s; }
.pf-link:hover, .pf-link.on { background: var(--apricot); color: var(--pine-deep); }
.pf-link small { font-weight: 600; font-size: .75rem; }

/* Portfolio view */
.pf-head { padding-top: 48px; padding-bottom: 16px; border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; gap: 10px; }
.pf-head h1, .pf-head h2 { font-size: clamp(2.6rem, 5vw, 4.4rem); }
.pf-head p { color: var(--muted); max-width: 60ch; }
.back { align-self: flex-start; font-weight: 600; font-size: .9rem; color: var(--lake); text-decoration: none; }
.back:hover { text-decoration: underline; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; padding: 18px 0 20px; }
.filters button { font-family: var(--body); font-weight: 600; font-size: .88rem; padding: 7px 15px; border-radius: 999px; border: 1px solid var(--rule); background: var(--paper); color: var(--ink); cursor: pointer; }
.filters button[aria-pressed="true"] { background: var(--pine); border-color: var(--pine); color: var(--sand); }
.masonry { column-count: 3; column-gap: 12px; }
.masonry .shot { break-inside: avoid; margin-bottom: 12px; }
@media (max-width: 1200px) { .masonry { column-count: 2; } }
@media (max-width: 480px) { .masonry { column-count: 1; } }

/* Right column */
.content { min-width: 0; padding: 0 max(30px, env(safe-area-inset-right, 0px)) 0 30px; }
.cover { margin: 0 calc(-1 * max(30px, env(safe-area-inset-right, 0px))) 0 -30px; position: relative; }
.cover img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; object-position: 60% 55%; }
.cover .over { position: absolute; left: 30px; right: 30px; bottom: 0; padding: 70px 0 26px; display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; color: #FFF8EE; text-shadow: 0 1px 2px rgba(0,0,0,.55), 0 2px 18px rgba(0,0,0,.45); }
.cover h1 { font-size: clamp(2.1rem, 4vw, 3.7rem); max-width: 15ch; }
.cover h1 em { font-style: italic; font-weight: 500; color: var(--apricot); }
.cover .label { color: #FFF8EE; }
.cover .label span { white-space: nowrap; }

.chapter { padding-top: 70px; scroll-margin-top: 10px; }
.ch-head { margin-bottom: 22px; padding-bottom: 14px; border-bottom: 1px solid var(--rule); }
.ch-head h2 { font-size: clamp(2.4rem, 4.6vw, 4rem); }
.shot { margin: 0 0 14px; overflow: hidden; background: var(--rule); border-radius: 4px; }
.shot .open { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.shot img { display: block; width: 100%; height: auto; transition: transform .7s ease; }
.shot:hover img { transform: scale(1.025); }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.pair .shot { margin: 0; }
.pair.single { grid-template-columns: minmax(0, 1fr); width: calc(50% - 7px); margin-left: auto; margin-right: auto; }
@media (max-width: 560px) { .pair { grid-template-columns: 1fr; } .pair.single { width: auto; } }

/* Services */
.block { padding-top: 96px; scroll-margin-top: 10px; }
.block > header { margin-bottom: 24px; padding-bottom: 14px; border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; gap: 8px; }
.block h2 { font-size: clamp(2.4rem, 4.6vw, 4rem); }
.block > header p { color: var(--muted); max-width: 62ch; }
.offers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.offer { background: var(--paper); padding: 24px; display: flex; flex-direction: column; gap: 10px; border-radius: 6px; border: 1px solid var(--rule); }
.offer h3 { font-size: 1.6rem; }
.offer p { color: var(--muted); font-size: .97rem; }
.offer.other { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: space-between; gap: 18px 28px; flex-wrap: wrap; background: transparent; border: 1px dashed var(--muted); }
.offer.other > div { flex: 1 1 360px; display: flex; flex-direction: column; gap: 10px; }
.other-link { flex: none; font-weight: 700; color: var(--pine); text-decoration: none; border: 1.5px solid var(--pine); border-radius: 999px; padding: 10px 18px; transition: background .2s, color .2s; }
.other-link:hover, .other-link:focus-visible { background: var(--pine); color: var(--sand); }
@media (max-width: 700px) { .offers { grid-template-columns: 1fr; } }
.road { list-style: none; margin: 34px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); position: relative; }
.road::before { content: ""; position: absolute; left: 0; right: 0; top: 7px; border-top: 2px dashed var(--rule); }
.road li { position: relative; padding: 28px 14px 0 0; display: flex; flex-direction: column; gap: 4px; }
.road li::before { content: ""; position: absolute; top: 0; left: 0; width: 16px; height: 16px; border-radius: 50%; background: var(--sand); border: 3px solid var(--lake); }
.road li:last-child::before { border-color: var(--sunset); background: var(--sunset); }
.road b { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 600; font-size: 1.3rem; }
.road p { color: var(--muted); font-size: .93rem; }
.road .label { color: var(--lake); }
@media (max-width: 700px) { .road { grid-template-columns: 1fr 1fr; row-gap: 22px; } .road::before { display: none; } }

/* About */
.about-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(24px, 4vw, 48px); align-items: center; }
.about-grid figure { margin: 0; border-radius: 6px; overflow: hidden; }
.about-grid figure img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 60%; }
.about-text { display: flex; flex-direction: column; gap: 14px; }
.about-text p { color: var(--muted); max-width: 60ch; }
.about-text .big { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 500; font-size: clamp(1.6rem, 2.8vw, 2.3rem); line-height: 1.15; color: var(--ink); }
.about-text .big em { font-style: italic; color: var(--sunset); }
.zones { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 0; padding: 0; list-style: none; }
.zones li { font-size: .8rem; font-weight: 600; border-radius: 999px; background: rgba(47,102,129,.1); color: var(--lake); padding: 5px 12px; }
@media (max-width: 760px) { .about-grid { grid-template-columns: 1fr; } .about-grid figure img { aspect-ratio: 4 / 4.4; } }

/* Contact */
.contact-card { background: var(--lake); color: var(--sand); padding: clamp(28px, 5vw, 50px); display: flex; flex-direction: column; gap: 16px; border-radius: 8px; }
.contact-card .label { color: var(--sand); }
.mail { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 600; font-size: clamp(1.45rem, 3.6vw, 3.4rem); line-height: 1.1; overflow-wrap: anywhere; }
.contact-row { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; }
.copy { font-family: var(--body); font-size: .85rem; font-weight: 700; background: var(--apricot); color: var(--pine-deep); border: 0; padding: 10px 18px; border-radius: 999px; cursor: pointer; }
.copy:hover { background: var(--sand); }
.contact-row a { font-weight: 600; }

/* Contact form */
.cform { margin-top: 14px; background: var(--paper); border: 1px solid var(--rule); border-radius: 8px; padding: clamp(22px, 4vw, 36px); display: flex; flex-direction: column; gap: 14px; }
.cform h3 { font-size: 1.6rem; }
.cform label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: .9rem; color: var(--ink); min-width: 0; }
.cform .opt { font-weight: 400; color: var(--muted); }
.cform input[type="text"], .cform input[type="email"], .cform select, .cform textarea { font: inherit; font-weight: 400; font-size: 1rem; color: var(--ink); background: #FFFDF9; border: 1px solid var(--rule); border-radius: 6px; padding: 10px 12px; width: 100%; }
.cform textarea { resize: vertical; min-height: 120px; }
.cform input:focus, .cform select:focus, .cform textarea:focus { outline: 2px solid var(--lake); outline-offset: 1px; border-color: var(--lake); }
.cform .row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 640px) { .cform .row2 { grid-template-columns: 1fr; } }
.cform .consent { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 4px 10px; font-size: .9rem; color: var(--muted); }
.cform .consent input { margin-top: 5px; width: 18px; height: 18px; accent-color: var(--pine); flex: none; }
.cform .consent > span { flex: 1 1 0; min-width: 0; }
.cform .consent label { display: inline; font-weight: 400; font-size: inherit; color: var(--muted); }
.cform .consent a { color: var(--lake); font-weight: 600; white-space: nowrap; }
.cform .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.send-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.send { font-family: var(--body); font-weight: 700; font-size: 1rem; background: var(--sunset-deep); color: #FFF8EE; border: 0; border-radius: 999px; padding: 12px 24px; cursor: pointer; }
.send:hover { background: var(--pine); }
.send:disabled { opacity: .6; cursor: default; }
.status { font-size: .93rem; color: var(--muted); }
.status.ok { color: var(--pine); font-weight: 600; }
.status.err { color: var(--sunset-deep); font-weight: 600; }

footer { margin-top: 70px; padding: 22px 0 max(32px, env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--rule); color: var(--muted); font-size: .86rem; display: flex; flex-direction: column; gap: 12px; }
footer .r { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
footer a { color: var(--ink); }

/* Ordinateurs portables à écran bas : panneau plus compact pour qu'il tienne sans défiler */
@media (min-width: 901px) and (max-height: 960px) {
  .panel { padding-top: 24px; padding-bottom: 20px; gap: 14px; }
  .name { font-size: clamp(2.6rem, 4.4vw, 3.9rem); }
  .panel .label { margin-top: 10px; }
  .panel .sig { margin-top: 16px; font-size: 1.2rem; }
  .panel .base { margin-top: 8px; font-size: .8rem; }
  .toc a { padding: 5px 0; font-size: 1.15rem; }
  .toc .sep a { padding: 5px 0; }
  .panel-foot { gap: 9px; }
  .btn { padding: 10px 18px; }
  .pf-link { padding: 8px 16px; }
}

@media (min-width: 901px) and (max-height: 760px) {
  .name { font-size: clamp(2.4rem, 4vw, 3.4rem); }
  .panel .sig { font-size: 1.1rem; margin-top: 12px; }
  .toc a { padding: 3px 0; font-size: 1.02rem; }
  .panel { gap: 10px; padding-top: 18px; padding-bottom: 16px; }
}

/* Barre mobile (cachée sur ordinateur) */
.topbar { display: none; }

.panel-close { display: none; position: absolute; top: max(14px, env(safe-area-inset-top, 0px)); right: max(16px, env(safe-area-inset-right, 0px)); width: 42px; height: 42px; place-items: center; border-radius: 50%; border: 1.5px solid rgba(243,234,220,.5); background: transparent; color: var(--sand); font-size: 1.2rem; cursor: pointer; }
/* Téléphone et tablette : barre fine + menu dépliant, la photo d'accueil apparaît tout de suite */
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
  .topbar { display: flex; position: sticky; top: 0; z-index: 30; align-items: center; justify-content: space-between; gap: 12px; background: var(--pine); color: var(--sand); padding: max(10px, env(safe-area-inset-top, 0px)) max(18px, env(safe-area-inset-right, 0px)) 10px max(18px, env(safe-area-inset-left, 0px)); }
  .topbar .tb-name { font-family: var(--display); font-variation-settings: "SOFT" 100; font-weight: 700; font-size: 1.35rem; text-decoration: none; white-space: nowrap; }
  .topbar .tb-name em { font-style: italic; font-weight: 500; color: var(--apricot); }
  .menu-btn { font-family: var(--body); font-weight: 700; font-size: .9rem; background: transparent; color: var(--sand); border: 1.5px solid rgba(243,234,220,.5); border-radius: 999px; padding: 7px 16px; cursor: pointer; }
  .panel { position: fixed; inset: 0; z-index: 40; height: auto; transform: translateX(-100%); transition: transform .3s ease; visibility: hidden; padding: max(70px, calc(env(safe-area-inset-top, 0px) + 60px)) max(22px, env(safe-area-inset-right, 0px)) max(26px, env(safe-area-inset-bottom, 0px)) max(22px, env(safe-area-inset-left, 0px)); }
  .panel.open { transform: none; visibility: visible; }
  .panel-close { display: grid; }
  .panel .sig, .panel .base { display: none; } /* dans le menu mobile, la navigation passe en premier */
  .content { padding: 0 max(18px, env(safe-area-inset-right, 0px)) 0 max(18px, env(safe-area-inset-left, 0px)); }
  .cover { margin: 0 calc(-1 * max(18px, env(safe-area-inset-right, 0px))) 0 calc(-1 * max(18px, env(safe-area-inset-left, 0px))); }
  .cover img { aspect-ratio: 4 / 3.6; object-position: 70% 65%; }
  .cover .over { left: max(18px, env(safe-area-inset-left, 0px)); right: max(18px, env(safe-area-inset-right, 0px)); }
  .chapter { scroll-margin-top: 64px; }
  .block { scroll-margin-top: 64px; }
}
@media (prefers-reduced-motion: reduce) { .panel { transition: none; } }

/* Mentions légales et confidentialité */
.legal { display: flex; flex-direction: column; gap: 10px; padding-top: 28px; max-width: 70ch; }
.legal h2 { margin: 26px 0 2px; font-size: clamp(1.5rem, 2.6vw, 2rem); scroll-margin-top: 70px; }
.legal h2:first-child { margin-top: 0; }
.legal p { margin: 0; color: var(--muted); }
.legal a { color: var(--lake); }
.nf-legal { font-size: .9rem; }
.mail a { text-decoration: none; }
.mail a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; }

/* Lightbox */
dialog.lb { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
dialog.lb::backdrop { background: rgba(28,22,16,.94); }
.lb-wrap { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 56px max(16px, env(safe-area-inset-right, 0px)) 24px max(16px, env(safe-area-inset-left, 0px)); }
.lb-wrap img { max-width: 100%; max-height: calc(100vh - 120px); object-fit: contain; border-radius: 3px; }
.lb-count { font-size: .8rem; font-weight: 600; letter-spacing: .1em; color: rgba(243,234,220,.75); }
.lb-btn { position: absolute; background: rgba(46,75,63,.9); color: var(--sand); border: 0; width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; font-size: 1.4rem; cursor: pointer; }
.lb-btn:hover { background: var(--sunset); }
.lb-close { top: max(12px, env(safe-area-inset-top, 0px)); right: max(12px, env(safe-area-inset-right, 0px)); }
.lb-prev { left: max(12px, env(safe-area-inset-left, 0px)); top: 50%; transform: translateY(-50%); }
.lb-next { right: max(12px, env(safe-area-inset-right, 0px)); top: 50%; transform: translateY(-50%); }

/* Page ouverte en arrière-plan bloquée pendant que la visionneuse ou le menu est ouvert */
body.locked { overflow: hidden; }
