/* ==========================================================================
   Labozine — feuille de style
   Palette : fond encre profonde, accent laiton (écho d'une seule couleur
   chaude, comme le son d'une cloche qui se propage).
   ========================================================================== */

:root {
  --ink: #0e1116;
  --panel: #161b22;
  --panel-border: #262d38;
  --line: #262d38;
  --text: #edeff2;
  --text-muted: #97a1ae;
  --text-faint: #626c78;
  --brass: #c9a24b;
  --brass-bright: #ddb968;
  --brass-dim: #8c7238;
  --logo-blue: #5b9dff;
  --logo-blue-bright: #83b6ff;

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --maxw: 1120px;
  --radius: 3px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

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

a { color: inherit; }

::selection { background: var(--brass-dim); color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 3px;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 28px;
}

/* ---- Typographie ---- */

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 560;
  line-height: 1.12;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }
h3 { font-size: 1.25rem; font-weight: 560; }

p { margin: 0 0 1em; color: var(--text-muted); max-width: 62ch; }

.lede {
  font-size: 1.15rem;
  color: var(--text);
  max-width: 46ch;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--brass);
  letter-spacing: 0.02em;
}

/* ---- Nav ---- */

.site-header {
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  background: rgba(14, 17, 22, 0.88);
  backdrop-filter: blur(8px);
  z-index: 40;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 28px;
  max-width: var(--maxw);
  margin: 0 auto;
}

.logo {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  text-decoration: none;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo-mark .gear { stroke: var(--text-faint); stroke-width: 2; fill: none; transform-box: fill-box; transform-origin: 50% 50%; animation: logo-rotate 16s linear infinite; }
.logo-mark .orbit { stroke: var(--logo-blue-bright); stroke-width: 3.4; fill: none; }
.logo-mark .node-dot { fill: var(--logo-blue-bright); animation: logo-pulse 2.4s ease-in-out infinite; }
@keyframes logo-rotate { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes logo-pulse { 0%, 100% { opacity: 0.65; } 50% { opacity: 1; } }

.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--text); }
.nav-links a[aria-current="page"] { color: var(--text); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius);
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: var(--font-body);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn-brass {
  background: var(--brass);
  color: #17130a;
  font-weight: 600;
}
.btn-brass:hover { background: var(--brass-bright); }

.btn-outline {
  border-color: var(--panel-border);
  color: var(--text);
}
.btn-outline:hover { border-color: var(--brass); color: var(--brass-bright); }

.nav-cta { padding: 8px 18px; font-size: 0.9rem; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  color: var(--text);
  padding: 8px 10px;
  font-size: 1rem;
}

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: fixed;
    inset: 66px 0 auto 0;
    background: var(--ink);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 8px 28px 20px;
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li { width: 100%; border-top: 1px solid var(--line); }
  .nav-links a, .nav-links .btn { display: block; padding: 14px 0; width: 100%; }
  .nav-links .btn { margin-top: 6px; }
}

/* ---- Hero ---- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 96px 0 88px;
  border-bottom: 1px solid var(--line);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.hero-by {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 0.92rem;
  color: var(--text-faint);
  max-width: 40ch;
}
.hero-by strong { color: var(--text-muted); font-weight: 500; }

.echo-visual {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.echo-visual svg { width: 100%; height: 100%; max-width: 380px; }

.echo-ring {
  fill: none;
  stroke: var(--brass);
  stroke-width: 1;
  opacity: 0;
  transform-origin: center;
  animation: echo-pulse 3.6s ease-out infinite;
}
.echo-ring.r2 { animation-delay: 0.9s; }
.echo-ring.r3 { animation-delay: 1.8s; }
.echo-ring.r4 { animation-delay: 2.7s; }

.echo-dot { fill: var(--brass-bright); }

@keyframes echo-pulse {
  0% { transform: scale(0.15); opacity: 0.9; }
  75% { opacity: 0.12; }
  100% { transform: scale(1); opacity: 0; }
}

/* ---- Sections génériques ---- */

section { padding: 84px 0; }
.section-border-top { border-top: 1px solid var(--line); }

.section-head {
  max-width: 56ch;
  margin-bottom: 48px;
}

/* ---- Grille de cartes (services) ---- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

@media (max-width: 700px) {
  .card-grid { grid-template-columns: 1fr; }
}

.card {
  background: var(--ink);
  padding: 32px;
}

.card h3 { margin-bottom: 10px; }
.card p { margin: 0; max-width: none; }

/* ---- Étapes ---- */

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}

@media (max-width: 860px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .steps { grid-template-columns: 1fr; }
}

.step-num {
  font-family: var(--font-mono);
  color: var(--brass);
  font-size: 0.85rem;
  margin-bottom: 12px;
  display: block;
}

.step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.step p { font-size: 0.94rem; }

/* ---- CTA bande ---- */

.cta-band {
  border-top: 1px solid var(--line);
  padding: 72px 0;
}
.cta-band .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.cta-band h2 { margin: 0; }
.cta-band .lede { margin: 8px 0 0; }

/* ---- Réalisations ---- */

.projects {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.project {
  background: var(--ink);
  padding: 36px;
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 32px;
}

@media (max-width: 760px) {
  .project { grid-template-columns: 1fr; gap: 16px; }
}

.project-name { margin-bottom: 8px; }
.project-resume { color: var(--brass-bright); font-size: 0.98rem; margin-bottom: 0; }

.project-desc { margin-bottom: 16px; max-width: none; }

.stack-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-faint);
}
.stack-list li::before { content: "· "; color: var(--panel-border); }
.stack-list li:first-child::before { content: ""; }

.project-link {
  font-size: 0.92rem;
  color: var(--brass);
  text-decoration: none;
  border-bottom: 1px solid var(--brass-dim);
}
.project-link:hover { color: var(--brass-bright); border-color: var(--brass-bright); }

.empty-note {
  padding: 40px;
  color: var(--text-faint);
  font-size: 0.95rem;
}

/* ---- À propos ---- */

.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 56px;
  align-items: start;
}
@media (max-width: 820px) {
  .about-grid { grid-template-columns: 1fr; }
}

.about-figure {
  aspect-ratio: 4 / 5;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  display: flex;
  align-items: center;
  justify-content: center;
}
.about-figure svg { width: 62%; }

.about-body p { max-width: 60ch; }

.principles {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.principles li {
  padding-left: 20px;
  border-left: 2px solid var(--brass-dim);
  color: var(--text-muted);
}
.principles strong { color: var(--text); font-weight: 500; display: block; margin-bottom: 2px; }

/* ---- Contact ---- */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
}
@media (max-width: 820px) {
  .contact-grid { grid-template-columns: 1fr; }
}

.contact-info-list {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.contact-info-list dt {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-faint);
  margin-bottom: 4px;
}
.contact-info-list dd {
  margin: 0;
  font-size: 1.05rem;
}
.contact-info-list a { text-decoration: none; color: var(--text); }
.contact-info-list a:hover { color: var(--brass-bright); }

form.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 0.88rem; color: var(--text-muted); }

.field input,
.field textarea {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.98rem;
}
.field input:focus,
.field textarea:focus {
  border-color: var(--brass);
  outline: none;
}
.field textarea { resize: vertical; min-height: 130px; }

/* honeypot antispam, invisible mais accessible aux robots */
.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-status {
  font-size: 0.92rem;
  min-height: 1.4em;
}
.form-status[data-state="ok"] { color: #7fbf8f; }
.form-status[data-state="err"] { color: #d97757; }

/* ---- Footer ---- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 40px 0;
}
.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--text-faint);
  font-size: 0.88rem;
}
.site-footer a { color: var(--text-faint); text-decoration: none; }
.site-footer a:hover { color: var(--brass); }
.footer-links { display: flex; gap: 20px; list-style: none; padding: 0; margin: 0; }



/* Planche de trois poses par scène : mouvements des yeux, de la tête,
   des mains et des lèvres, sans vidéo ni script externe. */
.avatar-scene {
  position: relative;
  width: 100%;
  max-width: 360px;
  aspect-ratio: 677 / 774;
  margin-inline: auto;
  overflow: hidden;
  border: 1px solid rgba(201, 162, 75, .28);
  border-radius: 12px;
  background: #172333;
  isolation: isolate;
}
.avatar-scene .scene-frame {
  position: absolute;
  inset: 0;
  display: block;
  background-repeat: no-repeat;
  background-size: 300% 100%;
}
.scene-work .scene-frame { background-image: url("../img/avatar-travail.webp?v=10"); }
.scene-phone .scene-frame { background-image: url("../img/avatar-contact.webp?v=10"); }
.scene-presentation .scene-frame { background-image: url("../img/avatar-realisations.webp?v=10"); }
.scene-one { background-position: 0 0; }
.scene-two { background-position: 50% 0; opacity: 0; }
.scene-three { background-position: 100% 0; opacity: 0; }
.scene-work .scene-two { animation: work-blink 10s linear infinite; }
.scene-work .scene-three { animation: work-success 10s ease-in-out infinite; }
.scene-phone .scene-two { animation: phone-talk 7s ease-in-out infinite; }
.scene-phone .scene-three { animation: phone-smile 7s ease-in-out infinite; }
.scene-presentation .scene-two { animation: meeting-turn 9s ease-in-out infinite; }
.scene-presentation .scene-three { animation: meeting-return 9s ease-in-out infinite; }

@keyframes work-blink {
  0%, 27%, 31%, 100% { opacity: 0; }
  28%, 30% { opacity: 1; }
}
@keyframes work-success {
  0%, 54%, 97%, 100% { opacity: 0; }
  62%, 89% { opacity: 1; }
}
@keyframes phone-talk {
  0%, 20%, 55%, 100% { opacity: 0; }
  27%, 48% { opacity: 1; }
}
@keyframes phone-smile {
  0%, 53%, 94%, 100% { opacity: 0; }
  61%, 85% { opacity: 1; }
}
@keyframes meeting-turn {
  0%, 30%, 64%, 100% { opacity: 0; }
  38%, 57% { opacity: 1; }
}
@keyframes meeting-return {
  0%, 64%, 96%, 100% { opacity: 0; }
  72%, 88% { opacity: 1; }
}
.page-scene { max-width: 290px; margin: 24px 0 0; }
.about-figure.avatar-scene { max-width: 310px; padding: 0; }
.realisations-intro {
  display: grid;
  grid-template-columns: minmax(0, 290px) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.realisations-intro .page-scene { max-width: 290px; margin: 0; }
.realisations-intro-text { min-width: 0; }
@media (max-width: 720px) {
  .realisations-intro { grid-template-columns: 1fr; }
  .realisations-intro-text { grid-row: 1; }
  .realisations-intro .page-scene { grid-row: 2; }
}
@media (prefers-reduced-motion: reduce) {
  .avatar-scene .scene-frame { animation: none !important; }
  .scene-two, .scene-three { opacity: 0 !important; }
}

/* Bande discrète en bas de page, masquable, adaptée au mobile. */
body.has-ad-band { padding-bottom: 48px; }
.ad-band {
  position: fixed;
  z-index: 30;
  inset: auto 0 0;
  min-height: 44px;
  background: #1b2430;
  border-top: 1px solid rgba(201, 162, 75, .42);
  box-shadow: 0 -5px 18px rgba(0, 0, 0, .18);
}
.ad-band[hidden] { display: none; }
.ad-band-inner {
  max-width: var(--maxw);
  min-height: 44px;
  margin: auto;
  padding: 5px 28px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.ad-band-label {
  flex: none;
  color: var(--brass-bright);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
}
.ad-band-link {
  flex: 1;
  min-width: 0;
  color: var(--text);
  font-size: .88rem;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  text-decoration: none;
}
.ad-band-link:hover { color: var(--brass-bright); text-decoration: underline; }
.ad-band-close {
  flex: none;
  width: 28px;
  height: 28px;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}
.ad-band-close:hover { color: var(--text); }
@media (max-width: 520px) {
  .ad-band-inner { padding-inline: 14px; gap: 9px; }
  .ad-band-label { font-size: .65rem; }
  .ad-band-link { font-size: .78rem; }
}

/* V9 : passages plus vivants entre les poses existantes. */
.avatar-scene .scene-one { animation: avatar-breathe 7s ease-in-out infinite; }
.scene-work .scene-two { animation: work-blink 5s steps(1,end) infinite; }
.scene-work .scene-three { animation: work-success 11s steps(1,end) infinite; }
.scene-phone .scene-two { animation: phone-talk 3.2s steps(1,end) infinite; }
.scene-phone .scene-three { animation: phone-smile 9s steps(1,end) infinite; }
.scene-presentation .scene-two { animation: meeting-turn 7s steps(1,end) infinite; }
.scene-presentation .scene-three { animation: meeting-return 7s steps(1,end) infinite; }
@keyframes avatar-breathe { 0%, 100% { transform:scale(1); } 50% { transform:scale(1.014); } }
@keyframes phone-talk { 0%, 8%, 18%, 28%, 40%, 100% {opacity:0} 9%, 17%, 19%, 27%, 29%, 39% {opacity:1} }
@keyframes phone-smile { 0%, 65%, 96%, 100% {opacity:0} 66%, 95% {opacity:1} }
@keyframes work-blink { 0%, 47%, 51%, 100% {opacity:0} 48%, 50% {opacity:1} }
@keyframes work-success { 0%, 59%, 89%, 100% {opacity:0} 60%, 88% {opacity:1} }
@keyframes meeting-turn { 0%, 25%, 62%, 100% {opacity:0} 26%, 61% {opacity:1} }
@keyframes meeting-return { 0%, 62%, 88%, 100% {opacity:0} 63%, 87% {opacity:1} }
.nl-grid {display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:20px;margin:26px 0 60px}
.nl-card {border:1px solid var(--line);border-radius:12px;padding:24px;background:rgba(255,255,255,.035)}
.nl-card h2 {font-size:1.3rem;margin:10px 0}.nl-card time {color:var(--text-muted);font-size:.9rem}
.nl-body {max-width:760px;white-space:pre-wrap;line-height:1.8;overflow-wrap:anywhere;margin:28px 0 55px}
.video-embed {position:relative;width:100%;max-width:760px;aspect-ratio:16/9;margin:0 0 28px;border-radius:12px;overflow:hidden;border:1px solid var(--line);background:#000}
.video-embed iframe {position:absolute;inset:0;width:100%;height:100%;border:0}
.gallery {max-width:860px;margin:auto}.gallery img {display:block;max-width:100%;max-height:65vh;margin:20px auto;object-fit:contain;border-radius:8px}
.gallery-controls {display:flex;align-items:center;justify-content:center;gap:24px;margin:24px 0}.gallery button {cursor:pointer;padding:10px 18px}
.gallery-close {display:table;margin:0 0 28px auto;padding:10px 16px;border:1px solid var(--line);border-radius:8px;text-decoration:none;color:var(--text);background:#202e3d}
.gallery-close:hover,.gallery-close:focus-visible {border-color:var(--brass);color:var(--brass)}
@media(prefers-reduced-motion:reduce){.avatar-scene .scene-one {animation:none}}
