/* ============================================================
   UnHairDePlus — Toulouse
   Palette: noir / blanc + une couleur par section
   ============================================================ */

:root {
  --bg-section-1: #0a0a0a;
  --bg-section-2: #e10600;
  --bg-section-3: #003c8a;
  --bg-section-4: #f4ff33;

  --ink: #0a0a0a;
  --paper: #f7f5f1;
  --paper-dim: #d9d5cd;

  --font-display: "Bricolage Grotesque", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --pad-x: clamp(1.25rem, 5vw, 5rem);
  --gap: clamp(1rem, 2.5vw, 2rem);
  --rule: 1px solid currentColor;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1rem, 0.55vw + 0.9rem, 1.125rem);
  line-height: 1.6;
  color: var(--paper);
  background-color: var(--bg-section-1);
  /* patterned SVG tile — dot matrix */
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 22 22'><circle cx='1.5' cy='1.5' r='1.1' fill='%23ffffff' fill-opacity='0.07'/></svg>");
  background-size: 22px 22px;
  -webkit-font-smoothing: antialiased;
  text-wrap: pretty;
  overflow-x: hidden;
}

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

a { color: inherit; }

h1, h2, h3 { font-weight: 800; line-height: 0.98; letter-spacing: -0.02em; margin: 0; }

h2 { font-size: clamp(2rem, 5.5vw, 4.25rem); }
h3 { font-size: clamp(1.15rem, 1.6vw, 1.5rem); letter-spacing: -0.01em; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

:focus-visible {
  outline: 3px solid var(--bg-section-4);
  outline-offset: 3px;
}

/* ---------- shared section scaffolding ---------- */

section { padding: clamp(3.5rem, 8vw, 7rem) var(--pad-x); position: relative; }

.sec-1 { background-color: var(--bg-section-1); color: var(--paper); }
.sec-2 { background-color: var(--bg-section-2); color: #fff; }
.sec-3 { background-color: var(--bg-section-3); color: #fff; }
.sec-4 { background-color: var(--bg-section-4); color: var(--ink); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin: 0 0 1.25rem;
  opacity: 0.85;
}

.sec-head { max-width: 62ch; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.sec-intro { margin-top: 1.25rem; max-width: 52ch; opacity: 0.92; }

/* ---------- top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 2vw, 2rem);
  flex-wrap: wrap;
  padding: 0.7rem var(--pad-x);
  background: rgba(10, 10, 10, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(247, 245, 241, 0.16);
  color: var(--paper);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  font-weight: 800;
  letter-spacing: -0.02em;
  min-height: 44px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  background: var(--bg-section-4);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 600;
}

.topnav {
  display: flex;
  gap: clamp(0.75rem, 1.6vw, 1.5rem);
  margin-left: auto;
  flex-wrap: wrap;
}

.topnav a {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.6rem 0.15rem;
  border-bottom: 2px solid transparent;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.topnav a:hover { border-bottom-color: var(--bg-section-4); }

.tel-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  background: var(--bg-section-4);
  color: var(--ink);
  padding: 0.55rem 0.9rem;
  min-height: 44px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
}

.tel-label { text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.68rem; opacity: 0.7; }
.tel-btn:hover { background: #fff; }

/* ---------- hero ---------- */

.hero { padding-top: clamp(3rem, 7vw, 6rem); }

.hero-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--gap);
  align-items: end;
}

.hero-copy { grid-column: 1 / 5; }
.hero-figure { grid-column: 4 / 7; margin: 0; }

/* stacked headline breaking the baseline */
.stacked { font-size: clamp(2.6rem, 9vw, 7rem); margin-bottom: 1.5rem; }
.stacked span { display: block; }
.stacked span:nth-child(2) { margin-left: 1.6em; }
.stacked span:nth-child(3) { margin-left: -0.35em; color: var(--bg-section-4); }

.lede { max-width: 46ch; font-size: clamp(1.02rem, 1.1vw, 1.2rem); opacity: 0.92; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.75rem 0 2.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.85rem 1.35rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  border: 2px solid currentColor;
  transition: transform 140ms ease, background-color 140ms ease, color 140ms ease;
}

.btn-solid { background: var(--bg-section-4); color: var(--ink); border-color: var(--bg-section-4); }
.btn-solid:hover { transform: translate(-2px, -2px); }
.btn-ghost { background: transparent; color: inherit; }
.btn-ghost:hover { background: currentColor; }
.btn-ghost:hover { color: var(--bg-section-1); }
.btn-sm { min-height: 44px; padding: 0.7rem 1.1rem; font-size: 0.76rem; }

.hero-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin: 0;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(247, 245, 241, 0.22);
}

.hero-facts dt {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.6;
  margin-bottom: 0.35rem;
}

.hero-facts dd { margin: 0; font-weight: 600; }

.hero-figure img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }

figcaption {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  line-height: 1.5;
  opacity: 0.75;
  margin-top: 0.7rem;
}

/* ---------- prestations : broken bento ---------- */

.bento {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--gap);
}

.card {
  padding: clamp(1.25rem, 2.2vw, 2rem);
  border: 2px solid currentColor;
  background: rgba(0, 0, 0, 0.14);
}

.card h3 { margin-bottom: 0.6rem; }

.card-note {
  font-size: 0.92rem;
  opacity: 0.9;
  margin-bottom: 1.1rem;
  max-width: 40ch;
}

/* intentional misalignment: irregular spans, one empty cell */
.card-a { grid-column: 1 / 4; }
.card-b { grid-column: 4 / 7; }
.card-c { grid-column: 2 / 5; }          /* breaks out of the left edge */
.card-d { grid-column: 5 / 7; }
.card-e { grid-column: 1 / 3; }
.card-f { grid-column: 3 / 7; }          /* leaves cell (3,1) blank on purpose */
/* the empty cell is the gap between card-e and the row above */

.price-list { list-style: none; margin: 0; padding: 0; }

.price-list li {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0.5rem 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.35);
  font-size: 0.95rem;
}

.price-list li:last-child { border-bottom: 0; }
.price-list li span:first-child { flex: 1 1 auto; }
.price-list li span:last-child {
  font-family: var(--font-mono);
  font-weight: 600;
  white-space: nowrap;
}

.note-card { background: rgba(0, 0, 0, 0.28); }
.note-card .btn { margin-top: 1.25rem; }

/* ---------- le salon ---------- */

.salon-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--gap);
  align-items: start;
}

.salon-copy { grid-column: 1 / 4; }
.salon-side { grid-column: 4 / 7; display: grid; gap: var(--gap); }

.salon-copy h2 { margin-bottom: 1.5rem; }
.salon-copy p { max-width: 54ch; }

.salon-figure { margin: 0; }
.salon-figure img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }

.team {
  border: 2px solid currentColor;
  padding: clamp(1.1rem, 2vw, 1.6rem);
}

.team h3 { margin-bottom: 0.9rem; }

.team-list { list-style: none; margin: 0; padding: 0; }

.team-list li {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.9rem;
  align-items: baseline;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  font-size: 0.94rem;
}

.team-list li:last-child { border-bottom: 0; }
.team-list strong { font-weight: 800; }
.team-list span { opacity: 0.85; }

/* ---------- galerie : drag band ---------- */

.band-wrap { position: relative; }

.band {
  display: flex;
  gap: var(--gap);
  overflow-x: auto;
  overflow-y: hidden;
  cursor: grab;
  padding-bottom: 0.75rem;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

.band::-webkit-scrollbar { display: none; }
.band.is-dragging { cursor: grabbing; scroll-behavior: auto; }
.band.is-dragging * { user-select: none; pointer-events: none; }

.band-item {
  flex: 0 0 clamp(230px, 30vw, 360px);
  margin: 0;
}

.band-item img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border: 2px solid var(--ink);
}

.band-item figcaption { color: var(--ink); opacity: 0.8; }

.band-hint {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: 1.25rem 0 0;
  opacity: 0.7;
}

/* ---------- avis ---------- */

.avis-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--gap);
}

.quote {
  margin: 0;
  padding: clamp(1.25rem, 2.2vw, 2rem);
  border: 2px solid currentColor;
  background: rgba(255, 255, 255, 0.04);
}

.quote p { font-size: 1rem; }
.quote footer {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.7;
  margin-top: 1rem;
}

.quote-a { grid-column: 1 / 4; }
.quote-b { grid-column: 4 / 7; }
.quote-c { grid-column: 2 / 5; }
.quote-d { grid-column: 5 / 7; }

/* ---------- accès ---------- */

.acces-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--gap);
  align-items: start;
}

.acces-copy { grid-column: 1 / 4; }
.acces-side { grid-column: 4 / 7; }
.acces-copy h2 { margin-bottom: 1.5rem; }
.acces-copy p { max-width: 52ch; }

.acces-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.acces .btn-ghost:hover { color: var(--bg-section-2); }

.hours {
  width: 100%;
  border-collapse: collapse;
  border: 2px solid currentColor;
  font-size: 0.95rem;
}

.hours caption {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding-bottom: 0.75rem;
  opacity: 0.85;
}

.hours th, .hours td {
  text-align: left;
  padding: 0.6rem 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.3);
  font-weight: 400;
}

.hours th { font-weight: 600; }
.hours td { font-family: var(--font-mono); font-size: 0.86rem; }
.hours tr:last-child th, .hours tr:last-child td { border-bottom: 0; }
.hours tr.closed td { opacity: 0.7; }

.hours-note { margin-top: 1rem; font-size: 0.9rem; opacity: 0.9; max-width: 46ch; }

/* ---------- footer ---------- */

.site-footer {
  background: var(--bg-section-1);
  color: var(--paper);
  padding: clamp(2.5rem, 5vw, 4rem) var(--pad-x) 2rem;
  border-top: 1px solid rgba(247, 245, 241, 0.18);
}

.footer-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--gap);
  align-items: start;
}

.footer-brand .brand-mark { margin-bottom: 0.9rem; }
.footer-name { font-weight: 800; font-size: 1.25rem; margin: 0 0 0.5rem; }
.footer-line { margin: 0 0 0.3rem; font-size: 0.92rem; opacity: 0.85; }
.footer-line a { text-decoration: none; border-bottom: 1px solid currentColor; }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}

.footer-nav a {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.footer-nav a:hover { color: var(--bg-section-4); }

.claim-banner {
  display: inline-block;
  margin-top: 2.25rem;
  padding: 0.5rem 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-decoration: none;
  color: var(--paper);
  background: rgba(247, 245, 241, 0.08);
  border: 1px solid rgba(247, 245, 241, 0.22);
}

.claim-banner:hover { background: rgba(247, 245, 241, 0.16); }

.attribution { margin: 1.25rem 0 0; font-size: 0.78rem; }
.attribution a { color: inherit; opacity: 0.65; text-decoration: none; }
.attribution a:hover { opacity: 1; text-decoration: underline; }
.muted { opacity: 0.7; }

/* ---------- motion : staggered line reveal (CSS scroll-driven) ---------- */

@keyframes riseIn {
  from { opacity: 0; translate: 0 20px; }
  to   { opacity: 1; translate: 0 0; }
}

@keyframes wipeIn {
  from { opacity: 0; clip-path: inset(0 0 100% 0); }
  to   { opacity: 1; clip-path: inset(0 0 0 0); }
}

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    section p,
    section .card,
    section .quote,
    section .band-item,
    section .hours,
    section .team,
    section figure {
      animation: riseIn linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 40%;
    }

    section h2,
    .stacked span {
      animation: wipeIn linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 35%;
    }

    .stacked span:nth-child(2) { animation-delay: 80ms; }
    .stacked span:nth-child(3) { animation-delay: 160ms; }

    .card-b, .card-d, .card-f, .quote-b, .quote-d { animation-delay: 60ms; }
    .card-c, .card-e, .quote-c { animation-delay: 120ms; }
  }
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
  .hero-copy, .hero-figure,
  .salon-copy, .salon-side,
  .acces-copy, .acces-side { grid-column: 1 / -1; }

  .hero-figure { order: -1; }

  .card-a, .card-b, .card-c, .card-d, .card-e, .card-f,
  .quote-a, .quote-b, .quote-c, .quote-d { grid-column: 1 / -1; }

  .stacked span:nth-child(2) { margin-left: 0.9em; }
  .stacked span:nth-child(3) { margin-left: 0; }
}

@media (max-width: 620px) {
  .topbar { gap: 0.5rem; }
  .topnav { order: 3; width: 100%; margin-left: 0; gap: 0.9rem; }
  .topnav a { font-size: 0.7rem; }
  .tel-btn { margin-left: auto; }
  .tel-label { display: none; }
  .band-item { flex-basis: 74vw; }
}

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