/* ==========================================================================
   BELÉN ESTILISTES — main.css
   Paleta pròpia: crema / tinta / terracota. Tipografia: Fraunces + Inter.
   Mobile-first. Breakpoints: 480 / 768 / 1024 / 1280.
   ========================================================================== */

/* ---------- Fonts self-hosted (variables, subset llatí) ---------- */
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 300 500;
  font-display: swap;
  src: url('../assets/fonts/fraunces-normal-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 300 500;
  font-display: swap;
  src: url('../assets/fonts/fraunces-italic-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('../assets/fonts/inter-normal-latin.woff2') format('woff2');
}

/* ---------- Custom properties ---------- */
:root {
  /* Paleta */
  --crema:        #f7f4ef;
  --crema-fosc:   #ede8df;
  --tinta:        #1a1a1a;
  --tinta-suau:   #3d3a36;
  --terracota:    #c25a3c;
  --terracota-fosc: #a04830;  /* text petit sobre fons clar (contrast AA) */
  --terracota-clar: #d97a5c;  /* text petit sobre fons fosc (contrast AA) */
  --blanc:        #fffdf9;
  --linia:        rgba(26, 26, 26, 0.12);
  --linia-clara:  rgba(255, 253, 249, 0.18);

  /* Tipografia */
  --font-display: 'Fraunces', Georgia, serif;
  --font-cos:     'Inter', system-ui, sans-serif;

  /* Escala fluida */
  --text-hero:   clamp(2.75rem, 9vw, 7rem);
  --text-h2:     clamp(2.25rem, 6vw, 4.5rem);
  --text-h3:     clamp(1.5rem, 3.5vw, 2.5rem);
  --text-mani:   clamp(1.625rem, 4vw, 3.25rem);
  --text-num:    clamp(2.75rem, 7vw, 5.5rem);
  --text-body:   clamp(1rem, 1.2vw, 1.125rem);
  --text-label:  clamp(0.6875rem, 0.9vw, 0.78rem);

  /* Espais fluids */
  --espai-seccio: clamp(6rem, 16vh, 11rem);
  --espai-bloc:   clamp(2.5rem, 6vh, 5rem);
  --espai-marge:  clamp(1.25rem, 5vw, 5rem);

  /* Moviment */
  --ease-suau: cubic-bezier(0.25, 1, 0.5, 1);
}

/* ---------- Reset breu ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: auto; } /* Lenis se n'encarrega */

html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }

body {
  background: var(--crema);
  color: var(--tinta);
  font-family: var(--font-cos);
  font-size: var(--text-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
em { font-style: italic; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  clip-path: inset(50%); overflow: hidden; white-space: nowrap;
}

/* Etiquetes uppercase (estil editorial) */
.split-label,
[class*="__eyebrow"] {
  font-family: var(--font-cos);
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* ---------- Preloader ---------- */
.preloader {
  position: fixed; inset: 0; z-index: 100;
  display: grid; place-items: center;
  background: var(--tinta);
}
.preloader__word {
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 4rem);
  font-weight: 300;
  font-style: italic;
  color: var(--crema);
  opacity: 0;
}

/* ---------- Header ---------- */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem;
  padding: clamp(0.75rem, 2vw, 1.25rem) var(--espai-marge);
  color: var(--tinta); /* el hero és clar: el header sempre va en tinta */
  transition: color 0.45s var(--ease-suau), background 0.45s var(--ease-suau),
              box-shadow 0.45s var(--ease-suau);
}
.header.scrolled {
  color: var(--tinta);
  background: color-mix(in srgb, var(--crema) 88%, transparent);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--linia);
}
.header__brand {
  display: flex; align-items: center; gap: 0.6rem;
  text-decoration: none;
}
.header__brand img { width: clamp(30px, 4vw, 40px); height: auto; }
.header__name {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  font-weight: 500;
  letter-spacing: -0.01em;
}
.header__name em { font-weight: 300; font-size: 0.82em; }
.header__nav { display: none; gap: clamp(1.25rem, 3vw, 2.5rem); }
.header__nav a {
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  opacity: 0.85;
  transition: opacity 0.3s;
}
.header__nav a:hover { opacity: 1; }
.header__cta {
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-decoration: none;
  border: 1px solid currentColor;
  border-radius: 99px;
  padding: 0.55em 1.3em;
  transition: background 0.35s var(--ease-suau), color 0.35s var(--ease-suau),
              border-color 0.35s var(--ease-suau);
}
.header__cta:hover { background: var(--terracota); border-color: var(--terracota); color: var(--blanc); }

@media (min-width: 768px) {
  .header__nav { display: flex; }
}

/* ---------- Botons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-cos);
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--blanc);
  background: var(--terracota-fosc);
  border: 1px solid var(--terracota-fosc);
  border-radius: 99px;
  padding: 1em 2.2em;
  transition: background 0.35s var(--ease-suau), transform 0.35s var(--ease-suau);
}
.btn:hover { background: var(--terracota); border-color: var(--terracota); transform: translateY(-2px); }
.btn--ghost {
  background: transparent;
  color: inherit;
  border-color: currentColor;
}
.btn--ghost:hover { background: var(--tinta); border-color: var(--tinta); color: var(--crema); }
.btn--light:hover { background: var(--blanc); border-color: var(--blanc); color: var(--tinta); }

/* ==========================================================================
   01 · HERO
   ========================================================================== */
/* El vídeo de tisores és clar (marbre, llum càlida): text en tinta, no en blanc */
.hero {
  position: relative;
  color: var(--tinta);
  background: var(--crema);
}
.hero__pin {
  position: relative;
  height: 100svh;
  min-height: 560px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.hero__media { position: absolute; inset: 0; }
.hero__base img,
.hero__fade img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
}
/* Fallback crossfade (mòbil/connexió lenta): el JS scrubeja l'opacitat */
.hero__fade { opacity: 0; }
/* Seqüència de frames (només desktop): el JS hi dibuixa per sobre de la capa base */
.hero__canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  display: none;
}
@media (min-width: 769px) {
  .hero__canvas { display: block; }
}
.hero__static { display: none; } /* només visible amb prefers-reduced-motion */
.hero__static img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
}
/* Veladura clara: reforça la lectura del claim sense apagar la llum del clip */
.hero__veil {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(247, 244, 239, 0.82) 0%, rgba(247, 244, 239, 0.25) 38%, rgba(247, 244, 239, 0) 60%);
}
.hero__content {
  position: relative; z-index: 2;
  padding: 0 var(--espai-marge) clamp(5.5rem, 14vh, 9rem);
  max-width: 1200px;
}
.hero__label {
  color: var(--tinta-suau);
  margin-bottom: clamp(1rem, 2.5vh, 1.75rem);
}
.hero__claim {
  font-family: var(--font-display);
  font-size: var(--text-hero);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.03em;
}
.hero__claim em { color: var(--terracota-fosc); font-weight: 400; }
.hero__scroll {
  position: absolute; right: var(--espai-marge); bottom: clamp(2rem, 6vh, 3.5rem);
  z-index: 2;
  display: flex; flex-direction: column; align-items: center; gap: 0.8rem;
}
.hero__scroll-text {
  font-size: var(--text-label);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
  opacity: 0.7;
}
.hero__scroll-line {
  width: 1px; height: clamp(3rem, 8vh, 5rem);
  background: linear-gradient(to bottom, transparent, var(--tinta));
  transform-origin: top;
  animation: scroll-pulse 2.2s var(--ease-suau) infinite;
}
@keyframes scroll-pulse {
  0%   { transform: scaleY(0); opacity: 0; }
  35%  { transform: scaleY(1); opacity: 0.9; }
  100% { transform: scaleY(1) translateY(20%); opacity: 0; }
}

/* Barra de càrrega dels frames: línia fina centrada a baix */
.hero__loader {
  position: absolute; left: 50%; bottom: clamp(1.5rem, 4vh, 2.5rem);
  z-index: 3;
  width: min(160px, 30vw); height: 2px;
  transform: translateX(-50%);
  background: rgba(26, 26, 26, 0.15);
  border-radius: 2px;
  overflow: hidden;
  opacity: 0;
}
.hero__loader-bar {
  display: block;
  width: 100%; height: 100%;
  background: var(--terracota);
  transform: scaleX(0);
  transform-origin: left;
}

/* Progrés del pin: línia vertical discreta que es dibuixa amb el scroll */
.hero__progress {
  position: absolute; right: var(--espai-marge); top: 50%;
  z-index: 3;
  width: 2px; height: clamp(8rem, 26vh, 14rem);
  transform: translateY(-50%);
  opacity: 0;
  overflow: visible;
}
/* Sense non-scaling-stroke: trencaria el dasharray de DrawSVG amb el viewBox estirat */
.hero__progress line {
  fill: none;
  stroke-width: 2;
}
.hero__progress-track { stroke: rgba(26, 26, 26, 0.18); }
.hero__progress-line { stroke: var(--terracota-fosc); }

/* ==========================================================================
   02 · MANIFEST
   ========================================================================== */
.manifest {
  padding: var(--espai-seccio) var(--espai-marge);
  max-width: 68rem;
  margin-inline: auto;
}
.manifest__eyebrow { color: var(--terracota-fosc); margin-bottom: var(--espai-bloc); }
.manifest__text {
  font-family: var(--font-display);
  font-size: var(--text-mani);
  font-weight: 300;
  line-height: 1.28;
  letter-spacing: -0.015em;
  color: var(--tinta);
}
.manifest__text em { color: var(--terracota); }
/* Les paraules es revelen amb scrub — estat inicial apagat el posa el JS */

/* ==========================================================================
   03 · COMPTADORS
   ========================================================================== */
.stats {
  border-block: 1px solid var(--linia);
  background: var(--crema-fosc);
}
.stats__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  max-width: 1280px;
  margin-inline: auto;
}
.stat {
  padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1.25rem, 3vw, 3rem);
  display: flex; flex-direction: column; gap: 0.6rem;
  border-right: 1px solid var(--linia);
}
.stat:nth-child(2n) { border-right: none; }
.stat:nth-child(-n+2) { border-bottom: 1px solid var(--linia); }
.stat__num {
  font-family: var(--font-display);
  font-size: var(--text-num);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--tinta);
}
.stat__label {
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--tinta-suau);
}

@media (min-width: 768px) {
  .stats__grid { grid-template-columns: repeat(4, 1fr); }
  .stat:nth-child(-n+2) { border-bottom: none; }
  .stat:nth-child(2n) { border-right: 1px solid var(--linia); }
  .stat:last-child { border-right: none; }
}

/* Odòmetre: columnes de dígits rodants */
.odo { display: inline-flex; overflow: hidden; font-variant-numeric: tabular-nums; }
.odo__static { display: inline-block; }
.odo__digit {
  display: inline-flex; flex-direction: column;
  height: 1em; line-height: 1;
  overflow: hidden;
}
.odo__digit span { display: block; height: 1em; line-height: 1; text-align: center; }

/* ==========================================================================
   04 · SERVEIS (pinned)
   ========================================================================== */
.serveis { background: var(--tinta); color: var(--crema); }
.serveis__pin {
  min-height: 100svh;
  display: flex; flex-direction: column;
  padding: clamp(5rem, 10vh, 7rem) var(--espai-marge) clamp(2.5rem, 6vh, 4rem);
  gap: var(--espai-bloc);
}
.serveis__eyebrow { color: var(--terracota-clar); margin-bottom: 0.75rem; }
.serveis__title, .galeria__title, .contacte__title, .aura__title {
  font-family: var(--font-display);
  font-size: var(--text-h2);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.025em;
}
.serveis__body {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--espai-bloc);
  flex: 1;
  align-items: center;
}
.serveis__list { list-style: none; display: flex; flex-direction: column; }
.serveis__item {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: clamp(1rem, 2.5vw, 2rem);
  align-items: baseline;
  padding: clamp(0.7rem, 1.6vh, 1.1rem) 0;
  border-bottom: 1px solid var(--linia-clara);
}
.serveis__item .serveis__name {
  opacity: 0.55;
  transition: opacity 0.5s var(--ease-suau);
}
.serveis__item.is-active .serveis__name { opacity: 1; }
.serveis__num {
  font-family: var(--font-cos);
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--terracota-clar);
}
.serveis__name {
  font-family: var(--font-display);
  font-size: var(--text-h3);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.serveis__desc {
  grid-column: 2;
  font-size: clamp(0.875rem, 1.1vw, 1rem);
  color: color-mix(in srgb, var(--crema) 65%, transparent);
  max-width: 42ch;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.6s var(--ease-suau), opacity 0.6s var(--ease-suau),
              margin-top 0.6s var(--ease-suau);
}
.serveis__item.is-active .serveis__desc {
  max-height: 6em;
  opacity: 1;
  margin-top: 0.45em;
}
.serveis__visual {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 6px;
  overflow: hidden;
  display: none;
}
.serveis__img {
  position: absolute; inset: 0;
  clip-path: inset(100% 0 0 0); /* tapat: el JS el revela */
}
.serveis__img.is-active { clip-path: inset(0 0 0 0); }
.serveis__img img {
  width: 100%; height: 100%;
  object-fit: cover;
}

@media (min-width: 1024px) {
  .serveis__body { grid-template-columns: 1.1fr 1fr; }
  .serveis__visual { display: block; }
}

/* ==========================================================================
   05 · AURA
   ========================================================================== */
.aura {
  position: relative;
  background: #0d0b09;
  color: var(--crema);
}

/* --- Transició scroll-sync (encrespat → sedós) --- */
.aura__trans { position: relative; }
.aura__trans-pin {
  position: relative;
  height: 100svh;
  min-height: 540px;
  overflow: hidden;
}
/* Capes del frame scrub: base (frame inicial), fade (mòbil), canvas (desktop) */
.aura__base, .aura__fade, .aura__static { position: absolute; inset: 0; }
.aura__base img, .aura__fade img, .aura__static img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
}
.aura__fade { opacity: 0; z-index: 2; } /* el JS scrubeja l'opacitat al mòbil */
.aura__static { display: none; } /* només amb prefers-reduced-motion */
.aura__canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  z-index: 2;
  display: none;
}
@media (min-width: 769px) {
  .aura__canvas { display: block; }
}
.aura__trans-veil {
  position: absolute; inset: 0; z-index: 4;
  background: linear-gradient(to top, rgba(13, 11, 9, 0.66) 0%, rgba(13, 11, 9, 0.08) 42%, rgba(13, 11, 9, 0.35) 100%);
  pointer-events: none;
}
.aura__trans-text {
  position: absolute; inset: auto 0 0 0; z-index: 5;
  padding: 0 var(--espai-marge) clamp(3.5rem, 10vh, 6rem);
  text-align: center;
}
.aura__tag {
  position: absolute; bottom: clamp(1.1rem, 3vh, 2rem); z-index: 5;
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--crema) 80%, transparent);
}
.aura__tag--inici { left: var(--espai-marge); }
.aura__tag--final { right: var(--espai-marge); opacity: 0.25; }

.aura__intro {
  max-width: 64rem; margin-inline: auto; text-align: center;
  padding: var(--espai-seccio) var(--espai-marge) 0;
}
.aura__cos { padding: 0 var(--espai-marge) var(--espai-seccio); }
.aura__eyebrow { color: var(--terracota-clar); margin-bottom: 1.25rem; }
.aura__title em { color: var(--terracota); font-weight: 400; }
.aura__lead {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 1.75rem);
  font-weight: 300;
  line-height: 1.45;
  color: color-mix(in srgb, var(--crema) 88%, transparent);
  max-width: 52rem;
  margin-inline: auto;
}
.aura__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--linia-clara);
  border-block: 1px solid var(--linia-clara);
  max-width: 1100px;
  margin: var(--espai-bloc) auto;
}
.aura__stat {
  background: #0d0b09;
  padding: clamp(1.75rem, 4vw, 3rem) 1rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  text-align: center;
}
.aura__num {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 5vw, 4rem);
  font-weight: 300;
  line-height: 1;
  display: inline-flex; align-items: baseline;
}
.aura__dash { color: var(--terracota); margin: 0 0.08em; }
.aura__label {
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--crema) 60%, transparent);
}
@media (min-width: 768px) {
  .aura__stats { grid-template-columns: repeat(4, 1fr); }
}

.aura__cta-row {
  display: flex; flex-direction: column; align-items: center; gap: 1rem;
  text-align: center;
  margin-top: var(--espai-bloc);
}

/* ==========================================================================
   06 · MARQUES
   ========================================================================== */
.marques {
  padding: var(--espai-seccio) var(--espai-marge);
  text-align: center;
  max-width: 70rem;
  margin-inline: auto;
}
.marques__eyebrow { color: var(--terracota-fosc); margin-bottom: var(--espai-bloc); }
.marques__wall {
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: center;
  gap: clamp(2.5rem, 8vw, 6rem);
  margin-bottom: var(--espai-bloc);
}
.marques__logo img {
  height: clamp(2.6rem, 5vw, 3.6rem);
  width: auto;
  opacity: 0.85;
  filter: grayscale(1);
  transition: opacity 0.4s, filter 0.4s;
}
.marques__logo:hover img { opacity: 1; filter: grayscale(0); }
.marques__claim {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.6vw, 1.9rem);
  font-weight: 300;
  line-height: 1.4;
  max-width: 38ch;
  margin-inline: auto;
}
.marques__claim em { color: var(--terracota-fosc); }

/* ==========================================================================
   07 · GALERIA (scroll horitzontal scrubbed)
   ========================================================================== */
.galeria { background: var(--crema-fosc); border-block: 1px solid var(--linia); }
.galeria__pin {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  gap: var(--espai-bloc);
  padding: clamp(5rem, 10vh, 7rem) 0;
  overflow: hidden;
}
.galeria__head { padding-inline: var(--espai-marge); }
.galeria__eyebrow { color: var(--terracota-fosc); margin-bottom: 0.75rem; }
.galeria__track {
  display: flex;
  gap: clamp(1rem, 2.5vw, 2rem);
  padding-inline: var(--espai-marge);
  width: max-content;
}
.galeria__card {
  width: clamp(260px, 38vw, 560px);
  flex-shrink: 0;
}
.galeria__card img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 6px;
}
.galeria__card--tall img { aspect-ratio: 3 / 4; }
.galeria__card figcaption {
  margin-top: 0.8rem;
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--tinta-suau);
}

/* Mòbil: swipe natiu en lloc de pin scrubbed */
@media (max-width: 768px) {
  .galeria__pin { min-height: auto; }
  .galeria__track {
    width: auto;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }
  .galeria__card { scroll-snap-align: start; width: 78vw; }
}

/* ==========================================================================
   08 · TREBALLS (fotos reals: grid amb hover / carrusel amb dots al mòbil)
   ========================================================================== */
.treballs {
  padding: var(--espai-seccio) var(--espai-marge);
  max-width: 90rem;
  margin-inline: auto;
}
.treballs__eyebrow { color: var(--terracota-fosc); margin-bottom: 0.75rem; }
.treballs__title {
  font-family: var(--font-display);
  font-size: var(--text-h2);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin-bottom: var(--espai-bloc);
}
.treballs__title em { color: var(--terracota-fosc); font-weight: 400; }

.treballs__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(0.75rem, 1.8vw, 1.5rem);
}
.treballs__item {
  position: relative;
  overflow: hidden;
  border-radius: 6px;
  aspect-ratio: 3 / 4;
}
.treballs__item img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 30%;
  transition: transform 0.8s var(--ease-suau);
}
.treballs__item figcaption {
  position: absolute; inset: auto 0 0 0;
  padding: 2.2rem 1.1rem 0.9rem;
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--blanc);
  background: linear-gradient(to top, rgba(15, 12, 10, 0.65), transparent);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.5s var(--ease-suau), transform 0.5s var(--ease-suau);
}
.treballs__item:hover img { transform: scale(1.045); }
.treballs__item:hover figcaption { opacity: 1; transform: translateY(0); }

/* Peça final: enllaç a Instagram amb la mateixa proporció que les fotos */
.treballs__more {
  display: flex; flex-direction: column;
  align-items: flex-start; justify-content: space-between;
  aspect-ratio: 3 / 4;
  padding: clamp(1.25rem, 2.5vw, 2rem);
  border: 1px solid var(--linia);
  border-radius: 6px;
  background: var(--crema-fosc);
  text-decoration: none;
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1.8vw, 1.5rem);
  font-weight: 300;
  line-height: 1.35;
  color: var(--tinta);
  transition: background 0.5s var(--ease-suau), border-color 0.5s var(--ease-suau);
}
.treballs__more strong { font-weight: 500; color: var(--terracota-fosc); }
.treballs__more-fletxa {
  font-size: 1.6em;
  color: var(--terracota-fosc);
  transition: transform 0.5s var(--ease-suau);
}
.treballs__more:hover { background: var(--blanc); border-color: var(--terracota); }
.treballs__more:hover .treballs__more-fletxa { transform: translateX(8px); }

/* Dots del carrusel (només mòbil) */
.treballs__dots {
  display: none;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.25rem;
}
.treballs__dots span {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--linia);
  transition: background 0.3s, transform 0.3s;
}
.treballs__dots span.actiu {
  background: var(--terracota-fosc);
  transform: scale(1.3);
}

@media (min-width: 1024px) {
  .treballs__grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .treballs__grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin-inline: calc(-1 * var(--espai-marge));
    padding-inline: var(--espai-marge);
  }
  .treballs__grid::-webkit-scrollbar { display: none; }
  .treballs__item, .treballs__more {
    flex: 0 0 76vw;
    scroll-snap-align: center;
  }
  /* Al mòbil el nom del servei és sempre visible (no hi ha hover) */
  .treballs__item figcaption { opacity: 1; transform: none; }
  .treballs__dots { display: flex; }
}

/* ==========================================================================
   09 · RESSENYES
   ========================================================================== */
.ressenyes {
  padding: var(--espai-seccio) var(--espai-marge);
  max-width: 80rem;
  margin-inline: auto;
}
.ressenyes__head {
  display: flex; flex-wrap: wrap;
  align-items: baseline; justify-content: space-between;
  gap: 1rem;
  margin-bottom: var(--espai-bloc);
}
.ressenyes__eyebrow { color: var(--terracota-fosc); }
.ressenyes__rating {
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  display: flex; align-items: baseline; gap: 0.6rem;
}
.ressenyes__rating strong { font-size: 1.6em; font-weight: 400; }
.ressenyes__stars { color: var(--terracota); letter-spacing: 0.1em; }
.ressenyes__count { font-family: var(--font-cos); font-size: 0.8rem; color: var(--tinta-suau); }
.ressenyes__carousel {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(85%, 30rem);
  gap: clamp(1rem, 2.5vw, 2rem);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 1rem;
  scrollbar-width: thin;
  scrollbar-color: var(--terracota) transparent;
}
.ressenya {
  scroll-snap-align: start;
  background: var(--blanc);
  border: 1px solid var(--linia);
  border-radius: 6px;
  padding: clamp(1.75rem, 4vw, 2.75rem);
  display: flex; flex-direction: column; gap: 1.25rem;
}
.ressenya p {
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  font-weight: 300;
  line-height: 1.5;
}
.ressenya cite {
  font-style: normal;
  font-size: var(--text-label);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terracota-fosc);
}
.ressenyes__link {
  display: inline-block;
  margin-top: var(--espai-bloc);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--tinta);
  text-decoration-color: var(--terracota);
  text-underline-offset: 4px;
}
.ressenyes__link:hover { color: var(--terracota); }

@media (min-width: 1024px) {
  .ressenyes__carousel { grid-auto-columns: 1fr; grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); overflow: visible; }
}

/* ==========================================================================
   09 · CONTACTE
   ========================================================================== */
.contacte {
  background: var(--tinta);
  color: var(--crema);
  padding: var(--espai-seccio) var(--espai-marge);
}
.contacte__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--espai-bloc);
  max-width: 1280px;
  margin-inline: auto;
}
.contacte__eyebrow { color: var(--terracota-clar); margin-bottom: 0.75rem; }
.contacte__title { margin-bottom: var(--espai-bloc); }
.contacte__title em { color: var(--terracota); font-weight: 400; }
.contacte__address {
  font-style: normal;
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  font-weight: 300;
  line-height: 1.5;
  margin-bottom: var(--espai-bloc);
}
.contacte__actions {
  display: flex; flex-wrap: wrap; gap: 0.8rem;
  margin-bottom: var(--espai-bloc);
}
.contacte__horari { border-collapse: collapse; width: 100%; max-width: 28rem; }
.contacte__horari th, .contacte__horari td {
  text-align: left;
  padding: 0.85em 0;
  border-bottom: 1px solid var(--linia-clara);
  font-size: 0.95rem;
}
.contacte__horari th { font-weight: 500; }
.contacte__horari td { text-align: right; color: color-mix(in srgb, var(--crema) 70%, transparent); }
.contacte__mapa iframe {
  width: 100%; height: 100%;
  min-height: clamp(320px, 50vh, 480px);
  border-radius: 6px;
  filter: grayscale(0.85) contrast(1.05);
}
@media (min-width: 1024px) {
  .contacte__grid { grid-template-columns: 1fr 1fr; align-items: stretch; }
}

/* ==========================================================================
   10 · FOOTER
   ========================================================================== */
.footer {
  background: var(--tinta);
  color: var(--crema);
  border-top: 1px solid var(--linia-clara);
  padding: var(--espai-bloc) var(--espai-marge) clamp(1.5rem, 4vh, 2.5rem);
}
.footer__top {
  display: flex; flex-direction: column; align-items: center; gap: 1.25rem;
  text-align: center;
  padding-bottom: var(--espai-bloc);
}
.footer__logo { width: clamp(90px, 11vw, 130px); height: auto; }
.footer__claim {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-weight: 300;
  font-style: italic;
}
.footer__meta {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem;
  border-top: 1px solid var(--linia-clara);
  padding-top: 1.5rem;
  font-size: 0.8rem;
  color: color-mix(in srgb, var(--crema) 55%, transparent);
}
.footer__meta a { color: inherit; text-underline-offset: 3px; }
.footer__meta a:hover { color: var(--terracota); }
/* Crèdit de l'estudi: discret però visible (terracota clar = AA sobre fons fosc) */
.footer__vexyon {
  color: var(--terracota-clar);
  font-weight: 500;
  text-decoration-color: color-mix(in srgb, var(--terracota-clar) 45%, transparent);
  transition: color 0.3s, text-decoration-color 0.3s;
}
.footer__meta a.footer__vexyon:hover {
  color: var(--terracota-clar);
  text-decoration-color: var(--terracota-clar);
}

/* ==========================================================================
   Accessibilitat
   ========================================================================== */
/* Focus visible amb teclat */
:focus-visible {
  outline: 2px solid var(--terracota);
  outline-offset: 3px;
  border-radius: 2px;
}
.btn:focus-visible, .header__cta:focus-visible { border-radius: 99px; }

::selection { background: var(--terracota); color: var(--blanc); }

/* Reduced motion: estats finals estàtics, sense transicions */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  /* Hero: frame final estàtic en lloc del scrub */
  .hero__canvas, .hero__fade, .hero__loader, .hero__progress { display: none !important; }
  .hero__static { display: block; }
  /* AURA: mostra directament el resultat (capa final), sense wipe */
  .aura__canvas, .aura__fade, .aura__tag { display: none !important; }
  .aura__static { display: block; }
}
