/* ==========================================================================
   La Colònia Studio Gallery
   Basado en ~/.claude/skills/diseno-web-pro/references/base.css
   Estética: blanco puro, grotesca neo-grotesca pesada y comprimida, logo negro.
   ========================================================================== */

/* Archivo (SIL Open Font License, ver fonts/OFL.txt), alojada en local: sin conexiones a terceros */
@font-face {
  font-family: "Archivo"; font-style: normal; font-weight: 100 900; font-stretch: 62% 125%; font-display: swap;
  src: url("../fonts/archivo-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo"; font-style: normal; font-weight: 100 900; font-stretch: 62% 125%; font-display: swap;
  src: url("../fonts/archivo-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* Tipografía: una sola familia variable (peso 100–900, anchura 62–125 %) */
  --font-sans: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --stretch-compressed: 62%;
  --stretch-condensed: 75%;

  --text-xs: 0.75rem;   /* 12 */
  --text-sm: 0.875rem;  /* 14 */
  --text-base: 1rem;    /* 16 */
  --text-lg: 1.125rem;  /* 18 */
  --text-xl: 1.25rem;   /* 20 */
  --text-2xl: 1.5rem;   /* 24 */
  --text-3xl: 1.875rem; /* 30 */
  --text-section: clamp(2.75rem, 5vw + 1rem, 6rem);
  --text-display: clamp(3.5rem, 8vw + 1rem, 9rem);

  /* Espaciado (escala 4/8) */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Color: blanco puro, negro puro y el rojo del rótulo como detalle */
  --color-bg: #ffffff;
  --color-text: #000000;
  --color-text-muted: #555555;
  --color-text-subtle: #6b6b6b;
  --color-border: rgb(0 0 0 / 0.10);
  --color-border-strong: rgb(0 0 0 / 0.22);
  --color-accent: #942306;
  --color-danger: #b3261e;
  --color-scrim: rgb(0 0 0 / 0.22);       /* velo sobre las fotos de marca */
  --color-scrim-strong: rgb(0 0 0 / 0.42);
  --color-scrim-soft: rgb(0 0 0 / 0.08);
  --color-scrim-top: rgb(0 0 0 / 0.5);
  --color-scrim-mid: rgb(0 0 0 / 0.52);
  --color-scrim-deep: rgb(0 0 0 / 0.74);
  --color-image-fade: #0a0a0a;
  --color-on-image: #ffffff;
  --color-on-image-muted: rgb(255 255 255 / 0.9);

  --radius-none: 0;

  --ease: cubic-bezier(0.2, 0, 0, 1);
  --duration: 200ms;
  --duration-slow: 700ms;
  --slide-interval: 6s;

  --container: 1280px;
  --gutter: clamp(1rem, 4vw, 2rem);
  --header-h: 80px;

  color-scheme: light;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: var(--header-h); background: var(--color-bg); }
body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
svg { display: block; }
input, button, textarea, select { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
ul { list-style: none; }
a { color: inherit; text-decoration: none; }
address { font-style: normal; }
p { text-wrap: pretty; }

/* Titulares: peso máximo, comprimidos, interletrado cerrado */
h1, h2 {
  font-weight: 900; font-stretch: var(--stretch-condensed);
  text-transform: uppercase; line-height: 0.88; letter-spacing: -0.02em; text-wrap: balance;
}

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

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}
.skip-link {
  position: absolute; left: var(--space-4); top: -100px; z-index: 100;
  background: var(--color-text); color: var(--color-bg); padding: var(--space-2) var(--space-4);
}
.skip-link:focus { top: var(--space-4); }

/* ---------- Layout ---------- */
.container { width: min(100% - 2 * var(--gutter), var(--container)); margin-inline: auto; }
.section { padding-block: clamp(var(--space-16), 10vw, var(--space-32)); }
.section + .section { border-top: 1px solid var(--color-border); }

.eyebrow {
  font-size: var(--text-xs); font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.16em; color: var(--color-accent);
}
.section-head { display: grid; gap: var(--space-4); }
.section-title { font-size: var(--text-section); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-3);
  min-height: 48px; padding-inline: var(--space-8);
  font-size: var(--text-sm); font-weight: 800; font-stretch: var(--stretch-condensed);
  text-transform: uppercase; letter-spacing: 0.06em;
  border: 1px solid transparent; border-radius: var(--radius-none);
  transition: background-color var(--duration) var(--ease), color var(--duration) var(--ease),
              border-color var(--duration) var(--ease), transform var(--duration) var(--ease);
}
.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: var(--color-text); color: var(--color-bg); }
.btn-primary:hover { background: var(--color-accent); }
.btn-outline { border-color: var(--color-text); }
.btn-outline:hover { background: var(--color-text); color: var(--color-bg); }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.75; }

/* ---------- Cabecera ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: rgb(255 255 255 / 0.96);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--duration) var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--color-border); }
.header-inner { height: 100%; display: flex; align-items: center; gap: var(--space-8); }

.logo { display: block; flex: none; }
.logo img { height: 48px; width: auto; }

.main-nav { margin-left: auto; }
.main-nav ul { display: flex; align-items: center; gap: var(--space-8); }
.main-nav a {
  font-size: var(--text-sm); font-weight: 800; font-stretch: var(--stretch-condensed);
  text-transform: uppercase; letter-spacing: 0.06em;
  position: relative; padding-block: var(--space-2);
}
.main-nav a:not(.nav-cta)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: currentColor;
  transform: scaleX(0); transform-origin: right; transition: transform var(--duration) var(--ease);
}
.main-nav a:not(.nav-cta):hover::after { transform: scaleX(1); transform-origin: left; }
.nav-cta {
  display: inline-flex; align-items: center; min-height: 44px; padding-inline: var(--space-6);
  background: var(--color-text); color: var(--color-bg);
  transition: background-color var(--duration) var(--ease);
}
.nav-cta:hover { background: var(--color-accent); }

/* Selector de idioma: ES | CAT */
.lang-switch { display: flex; align-items: center; flex: none; margin-right: calc(-1 * var(--space-2)); }
.lang-switch button {
  min-width: 44px; min-height: 44px; padding-inline: var(--space-2);
  font-size: var(--text-xs); font-weight: 700; font-stretch: var(--stretch-condensed);
  letter-spacing: 0.12em; color: var(--color-text-subtle);
  text-decoration: underline 1px transparent; text-underline-offset: 6px;
  transition: color var(--duration) var(--ease), text-decoration-color var(--duration) var(--ease);
}
.lang-switch button:hover { color: var(--color-text); }
.lang-switch button[aria-pressed="true"] { color: var(--color-text); font-weight: 800; text-decoration-color: currentColor; cursor: default; }
.lang-sep { width: 1px; height: 12px; background: var(--color-border-strong); }
@media (max-width: 400px) { .lang-switch button { min-width: 40px; padding-inline: var(--space-1); } }

.menu-toggle { display: none; width: 44px; height: 44px; position: relative; }
.menu-toggle span {
  position: absolute; left: 10px; right: 10px; height: 2px; background: var(--color-text);
  transition: transform var(--duration) var(--ease);
}
.menu-toggle span:first-child { top: 17px; }
.menu-toggle span:last-child { top: 25px; }
.menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

@media (max-width: 860px) {
  :root { --header-h: 68px; }
  .logo img { height: 40px; }
  .header-inner { gap: var(--space-2); }
  .lang-switch { margin-left: auto; margin-right: 0; }
  .menu-toggle { display: block; margin-right: calc(-1 * var(--space-2)); }
  .main-nav {
    position: fixed; inset: var(--header-h) 0 auto 0; height: calc(100dvh - var(--header-h));
    background: var(--color-bg); padding: var(--space-12) var(--gutter);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity var(--duration) var(--ease), transform var(--duration) var(--ease), visibility var(--duration);
  }
  .main-nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .main-nav ul { flex-direction: column; align-items: flex-start; gap: var(--space-6); }
  .main-nav a:not(.nav-cta) { font-size: 3rem; font-weight: 900; line-height: 1; letter-spacing: -0.02em; }
  .nav-cta { margin-top: var(--space-6); }
}

/* ---------- Hero: carrusel ---------- */
.hero-stage {
  position: relative; overflow: hidden;
  height: clamp(440px, calc(100svh - var(--header-h) - 200px), 860px);
}
.slides { position: absolute; inset: 0; }
.slide {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 1200ms var(--ease);
}
.slide.is-active { opacity: 1; z-index: 1; }
.slide img {
  width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 50%);
  transform: scale(1.06); transform-origin: var(--pos, 50% 50%);
}
.slide.is-active img { animation: drift calc(var(--slide-interval) + 1.2s) var(--ease) forwards; }
@keyframes drift { to { transform: scale(1); } }

/* Marquesina */
.marquee {
  position: absolute; z-index: 2; left: 0; right: 0; top: 20%;
  background: rgb(255 255 255 / 0.9);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  padding-block: var(--space-3);
  overflow: hidden;
}
.marquee-track { display: flex; width: max-content; animation: marquee 34s linear infinite; }
.marquee-group { display: flex; align-items: center; flex: none; }
/* Ultraligera (Archivo 100 ≈ Helvetica Neue Ultra Light) */
.marquee span {
  font-family: "Helvetica Neue", var(--font-sans);
  font-weight: 100; font-stretch: 100%;
  font-size: clamp(2rem, 4vw + 0.5rem, 4.5rem); line-height: 1;
  letter-spacing: 0.02em; white-space: nowrap; color: var(--color-text);
}
.marquee i {
  width: 6px; height: 6px; background: var(--color-accent);
  margin-inline: var(--space-12); flex: none;
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* Barra inferior del hero */
.hero-bar {
  display: grid; gap: var(--space-8);
  padding-top: var(--space-12); padding-bottom: var(--space-8);
}
.hero-intro { display: grid; gap: var(--space-4); }
.hero-title { font-size: var(--text-display); font-stretch: 70%; line-height: 0.84; letter-spacing: -0.03em; }
.hero-title span { display: block; }
.hero-side { display: grid; gap: var(--space-6); align-content: end; }
.hero-lede { color: var(--color-text-muted); font-size: var(--text-lg); max-width: 30rem; }
.hero-actions { display: flex; }

@media (min-width: 1024px) {
  .hero-bar { grid-template-columns: 7fr 5fr; gap: var(--space-16); align-items: end; }
}
@media (max-width: 640px) {
  .hero-stage { height: 64svh; min-height: 400px; }
  .slide img { object-position: 50% 50%; transform-origin: 50% 50%; }
  .marquee { top: 18%; padding-block: var(--space-2); }
  .marquee i { margin-inline: var(--space-8); width: 4px; height: 4px; }
  .hero-actions .btn { width: 100%; }
}

/* ---------- Marcas ---------- */
.brands .section-head { margin-bottom: var(--space-12); }
.brand-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-8) var(--space-4); }
@media (min-width: 768px) { .brand-grid { grid-template-columns: repeat(4, 1fr); gap: var(--space-6); } }

.brand-card { display: grid; gap: var(--space-4); }
/* Foto de catálogo + velo + logo blanco centrado */
.brand-media { position: relative; aspect-ratio: 3 / 4; overflow: hidden; background: var(--color-bg); }
.brand-media::after {
  content: ""; position: absolute; inset: 0; background: var(--color-scrim);
  transition: background-color var(--duration-slow) var(--ease);
}
.brand-media img:not(.brand-logo) {
  width: 100%; height: 100%; object-fit: cover; object-position: var(--pos, 50% 30%);
  transition: transform var(--duration-slow) var(--ease), filter var(--duration-slow) var(--ease);
}
.brand-logo {
  position: absolute; z-index: 1; left: 50%; top: 50%;
  width: var(--logo-w, 50%); height: auto;
  transform: translate(-50%, -50%);
  opacity: 0.88; filter: drop-shadow(0 2px 12px rgb(0 0 0 / 0.25));
  transition: transform var(--duration-slow) var(--ease), opacity var(--duration-slow) var(--ease);
}
.brand-card:hover .brand-media::after, .brand-card:focus-visible .brand-media::after { background: var(--color-scrim-strong); }
.brand-card:hover .brand-media img:not(.brand-logo), .brand-card:focus-visible .brand-media img:not(.brand-logo) { transform: scale(1.04); filter: grayscale(0.35); }
.brand-card:hover .brand-logo, .brand-card:focus-visible .brand-logo { opacity: 1; transform: translate(-50%, -50%) scale(1.08); }

.brand-info { display: grid; gap: var(--space-2); }
.brand-link {
  justify-self: start; font-size: var(--text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--color-text-muted); padding-bottom: 2px; border-bottom: 1px solid var(--color-border-strong);
  transition: color var(--duration) var(--ease), border-color var(--duration) var(--ease);
}
.brand-link span { display: inline-block; transition: transform var(--duration) var(--ease); }
.brand-card:hover .brand-link { color: var(--color-text); border-color: var(--color-text); }
.brand-card:hover .brand-link span { transform: translate(2px, -2px); }
@media (max-width: 480px) {
  .brand-link { font-size: 0.6875rem; letter-spacing: 0.04em; }
}

/* ---------- Journal: foto a sangre con texto superpuesto ---------- */
.journal-feature {
  position: relative; isolation: isolate; overflow: hidden;
  height: clamp(560px, 82vh, 820px); color: var(--color-on-image);
}
.journal-bg {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover; object-position: 50% 55%;
  transition: transform var(--duration-slow) var(--ease);
}
/* Velo: muy ligero arriba (título) y más denso abajo (avance y botón) */
.journal-feature::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(to bottom, var(--color-scrim-deep) 0%, var(--color-scrim-strong) 16%, var(--color-scrim) 28%, transparent 44%),
    linear-gradient(to top, var(--color-scrim-deep) 0%, var(--color-scrim-mid) 34%, transparent 68%),
    var(--color-scrim-soft);
}
.journal-feature:hover .journal-bg { transform: scale(1.02); }
.journal-overlay {
  height: 100%; display: flex; flex-direction: column; justify-content: space-between;
  padding-block: clamp(var(--space-8), 5vw, var(--space-16));
}
.journal-overlay .section-title, .journal-feature .journal-title { color: var(--color-on-image); text-shadow: 0 1px 24px rgb(0 0 0 / 0.25); }
.journal-copy { display: grid; gap: var(--space-3); justify-items: start; max-width: 36rem; }
.journal-tag, .journal-head-label {
  font-size: var(--text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.16em; color: var(--color-text-subtle);
}
.journal-feature .journal-tag { color: var(--color-on-image-muted); }
.journal-title, .article-title {
  font-weight: 900; font-stretch: var(--stretch-condensed); text-transform: uppercase;
  line-height: 0.92; letter-spacing: -0.02em; text-wrap: balance;
}
.journal-title { font-size: clamp(2rem, 2.5vw + 1rem, 3.25rem); }
/* Avance: fino, discreto y algo translúcido */
.journal-intro {
  max-width: 30rem; font-size: var(--text-sm); font-weight: 300; line-height: 1.7;
  letter-spacing: 0.01em; color: var(--color-on-image-muted);
}
.journal-copy .btn { margin-top: var(--space-4); }
.btn-on-image { border-color: var(--color-on-image); color: var(--color-on-image); }
.btn-on-image:hover { background: var(--color-on-image); color: var(--color-text); }
.btn-on-image:focus-visible { outline-color: var(--color-on-image); }
/* Toda la foto abre el artículo (sin escala al pulsar: un transform encogería la zona clicable) */
.btn-on-image::after { content: ""; position: absolute; inset: 0; }
.btn-on-image:active { transform: none; }
.journal-copy .btn svg { transition: transform var(--duration) var(--ease); }
.journal-feature:hover .btn svg { transform: translateX(4px); }
@media (max-width: 640px) {
  /* La foto ocupa la parte superior y se funde en negro: el texto va sobre el fundido
     y no tapa el pasillo ni la silla roja del fondo */
  .journal-feature { height: auto; background: var(--color-image-fade); }
  .journal-bg { height: 66%; object-position: 47% 50%; }
  .journal-overlay { min-height: 720px; gap: var(--space-24); }
  .journal-feature::before {
    background:
      linear-gradient(to bottom, var(--color-scrim-top) 0%, transparent 16%),
      linear-gradient(to bottom, transparent 48%, var(--color-image-fade) 66%);
  }
}

/* Artículo completo: modal amplia con formato de revista */
.legal.journal-article { --article-pad: var(--space-16); width: min(100% - 2 * var(--gutter), 72rem); max-height: 92dvh; }
.article { display: grid; gap: var(--space-12); padding: var(--space-12) var(--article-pad) var(--space-16); }
.article-header { display: grid; gap: var(--space-6); max-width: 52rem; }
.article-title { font-size: clamp(2.5rem, 4vw + 1rem, 5rem); }
.article-lede { font-size: clamp(1.125rem, 0.6vw + 1rem, 1.375rem); line-height: 1.5; max-width: 46rem; }
.article-figure { display: grid; gap: var(--space-3); }
.article-figure img { width: 100%; height: auto; background: var(--color-border); }
.article-figure figcaption { font-size: var(--text-xs); color: var(--color-text-subtle); }
/* Fotos a sangre: ocupan todo el ancho de la ventana */
.article-figure-wide { margin-inline: calc(-1 * var(--article-pad)); }
.article-figure-wide img { aspect-ratio: 16 / 9; object-fit: cover; }
.article-figure-wide figcaption { padding-inline: var(--article-pad); }
.article-section { display: grid; gap: var(--space-4); }
.article-split > div { display: grid; gap: var(--space-4); align-content: start; }
.article-section h3 {
  align-self: start; padding-top: var(--space-3); border-top: 2px solid var(--color-text);
  font-size: var(--text-lg); font-weight: 800; font-stretch: var(--stretch-condensed);
  text-transform: uppercase; letter-spacing: 0.06em; line-height: 1.2;
}
.article-text { max-width: 40rem; color: var(--color-text-muted); line-height: 1.7; }
.article-text p + p { margin-top: var(--space-4); }
@media (min-width: 900px) {
  .article-section:not(.article-split) { grid-template-columns: 14rem 1fr; gap: var(--space-12); }
  .article-split { grid-template-columns: 1fr 1fr; gap: var(--space-12); align-items: start; }
}
.article-end {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-6);
  padding-top: var(--space-8); border-top: 1px solid var(--color-border);
}
.article-end p { font-size: var(--text-2xl); font-weight: 800; font-stretch: var(--stretch-condensed); text-transform: uppercase; line-height: 1.1; }
@media (max-width: 640px) {
  .legal.journal-article { --article-pad: var(--gutter); width: 100%; max-height: 100dvh; }
  .article { gap: var(--space-8); padding-block: var(--space-8) var(--space-12); }
}

/* ---------- Contacto ---------- */
.contact-grid { display: grid; gap: var(--space-16); }
.contact-copy { display: grid; gap: var(--space-6); align-content: start; justify-items: start; }
@media (min-width: 1024px) {
  .contact-grid { grid-template-columns: 5fr 6fr; gap: var(--space-24); }
  .contact-copy { position: sticky; top: calc(var(--header-h) + var(--space-8)); }
}

.contact-list { display: grid; width: 100%; margin-top: var(--space-2); border-top: 2px solid var(--color-text); }
.contact-list > div {
  display: grid; grid-template-columns: 11rem 1fr; gap: var(--space-4); align-items: baseline;
  padding-block: var(--space-4); border-bottom: 1px solid var(--color-border);
}
.contact-list dt { font-size: var(--text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: var(--color-text-subtle); }
.contact-list dd { font-size: var(--text-lg); }
.contact-list a { border-bottom: 1px solid var(--color-border-strong); transition: border-color var(--duration) var(--ease), color var(--duration) var(--ease); }
.contact-list a:hover { color: var(--color-accent); border-color: var(--color-accent); }
@media (max-width: 480px) {
  .contact-list > div { grid-template-columns: 1fr; gap: var(--space-1); }
}

/* Formulario */
.form { display: grid; gap: var(--space-6); align-content: start; }
.form-row { display: grid; gap: var(--space-6); }
@media (min-width: 640px) { .form-row { grid-template-columns: 1fr 1fr; } }

.field { display: grid; gap: var(--space-2); align-content: start; border: 0; min-width: 0; }
.field[hidden] { display: none; }
.field label, .field legend {
  font-size: var(--text-xs); font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: var(--color-text-subtle);
}
.optional { text-transform: none; letter-spacing: 0; font-weight: 400; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: var(--space-3) 0;
  background: transparent; color: var(--color-text);
  border: 0; border-bottom: 1px solid var(--color-border-strong); border-radius: 0;
  font-size: var(--text-base);
  transition: border-color var(--duration) var(--ease), box-shadow var(--duration) var(--ease);
}
.field select {
  appearance: none; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(-45deg, transparent 50%, currentColor 50%);
  background-size: 5px 5px; background-position: calc(100% - 8px) 50%, calc(100% - 3px) 50%; background-repeat: no-repeat;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input::placeholder, .field textarea::placeholder { color: var(--color-text-subtle); opacity: 1; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--color-text-muted); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--color-text); box-shadow: 0 1px 0 var(--color-text); }
.field [aria-invalid="true"] { border-color: var(--color-danger); }
.field-error { font-size: var(--text-xs); color: var(--color-danger); }
.field-error:empty { display: none; }
.field-error::before { content: "— "; }

.choices { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-2); margin-top: var(--space-2); }
.choice { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span {
  display: flex; align-items: center; justify-content: center; min-height: 48px; padding-inline: var(--space-4);
  border: 1px solid var(--color-border-strong); text-align: center;
  font-size: var(--text-sm); font-weight: 800; font-stretch: var(--stretch-condensed); text-transform: uppercase; letter-spacing: 0.04em;
  transition: background-color var(--duration) var(--ease), color var(--duration) var(--ease), border-color var(--duration) var(--ease);
}
.choice:hover span { border-color: var(--color-text); }
.choice input:checked + span { background: var(--color-text); color: var(--color-bg); border-color: var(--color-text); }
.choice input:focus-visible + span { outline: 2px solid var(--color-text); outline-offset: 3px; }
.choices-brands { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 640px) { .choices-brands { grid-template-columns: repeat(4, 1fr); } }
.choices-brands .choice span { gap: var(--space-2); padding-inline: var(--space-2); }
.choices-brands .choice span::before {
  content: ""; flex: none; width: 10px; height: 10px; border: 1px solid currentColor;
  transition: background-color var(--duration) var(--ease);
}
.choices-brands .choice input:checked + span::before { background: currentColor; }
.field-hint { font-size: var(--text-xs); color: var(--color-text-subtle); }

.form-footer { display: grid; gap: var(--space-6); margin-top: var(--space-2); }
.form-footer .btn { justify-self: start; }
.check { display: flex; gap: var(--space-3); align-items: flex-start; font-size: var(--text-sm); color: var(--color-text-muted); cursor: pointer; }
.check input { flex: none; width: 20px; height: 20px; margin-top: 1px; accent-color: var(--color-text); cursor: pointer; }
.check a { color: var(--color-text); text-decoration: underline; text-underline-offset: 3px; }
.check a:hover { color: var(--color-accent); }
.checks { display: grid; gap: var(--space-4); }
.req { color: var(--color-text); font-weight: 700; }

/* Información básica de protección de datos (1ª capa) */
.form-success { padding: var(--space-8); border: 2px solid var(--color-text); display: grid; gap: var(--space-3); color: var(--color-text-muted); }
.form-success[hidden] { display: none; }
.form-success:focus { outline: none; }
.form-success-title { font-size: var(--text-3xl); font-weight: 900; font-stretch: var(--stretch-condensed); text-transform: uppercase; line-height: 1; color: var(--color-text); }
.form-success a { color: var(--color-text); border-bottom: 1px solid var(--color-border-strong); }
.form.is-sent > :not(.form-success) { display: none; }

/* ---------- Pie ---------- */
.site-footer { border-top: 1px solid var(--color-border); padding-bottom: var(--space-8); overflow: hidden; }
/* Arcos de la nave: logo centrado, en negro */
.footer-logo {
  width: min(70%, 30rem); height: auto; margin-inline: auto;
  margin-top: clamp(var(--space-12), 6vw, var(--space-24));
}
.footer-row {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--space-4);
  margin-top: var(--space-8); padding-top: var(--space-6); border-top: 1px solid var(--color-border);
  font-size: var(--text-xs); color: var(--color-text-subtle);
}
.footer-row a[href^="tel"] { color: var(--color-text); }
.footer-legal ul { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-6); }
.footer-legal a, .footer-legal button {
  display: inline-flex; align-items: center; min-height: 44px; color: var(--color-text);
  text-decoration: underline; text-decoration-color: var(--color-border-strong); text-underline-offset: 3px;
  transition: color var(--duration) var(--ease), text-decoration-color var(--duration) var(--ease);
}
.footer-legal a:hover, .footer-legal button:hover { color: var(--color-accent); text-decoration-color: currentColor; }
.footer-legal button { font-size: inherit; }
.footer-top {
  display: inline-flex; align-items: center; gap: var(--space-2); min-height: 44px;
  font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--color-text);
}
.footer-top:hover { color: var(--color-accent); }

/* ---------- Textos legales (modales) ---------- */
.legal {
  width: min(100% - 2 * var(--gutter), 48rem); max-height: min(88dvh, 60rem);
  margin: auto; padding: 0; border: 0; border-radius: var(--radius-none);
  background: var(--color-bg); color: var(--color-text);
  box-shadow: 0 2px 4px rgb(0 0 0 / 0.04), 0 24px 64px rgb(0 0 0 / 0.18);
  overscroll-behavior: contain;
}
.legal::backdrop { background: rgb(0 0 0 / 0.5); }
.legal[open] { animation: legal-in var(--duration) var(--ease); }
@keyframes legal-in { from { opacity: 0; transform: translateY(8px); } }
.legal-head {
  position: sticky; top: 0; z-index: 1; background: var(--color-bg);
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  padding: var(--space-6) var(--space-8); border-bottom: 2px solid var(--color-text);
}
.legal-head h2 { font-size: clamp(1.75rem, 3vw + 1rem, 2.75rem); }
.legal-close {
  flex: none; width: 44px; height: 44px; display: grid; place-items: center;
  border: 1px solid var(--color-border-strong);
  transition: background-color var(--duration) var(--ease), color var(--duration) var(--ease), border-color var(--duration) var(--ease);
}
.legal-close:hover { background: var(--color-text); color: var(--color-bg); border-color: var(--color-text); }
.legal-close svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.75; }
.legal-body { padding: var(--space-6) var(--space-8) var(--space-12); font-size: var(--text-base); line-height: 1.65; color: var(--color-text); }
.legal-body > * + *, .legal-body > :where([data-lang]) > * + * { margin-top: var(--space-4); }
.legal-body > :where([data-lang]) { margin-top: 0; }
/* Solo se muestra el texto legal del idioma activo */
/* (también los bloques del artículo del Journal) */
html:not([lang="ca"]) [data-lang="ca"], html:not([lang="en"]) [data-lang="en"],
html:is([lang="ca"], [lang="en"]) [data-lang="es"] { display: none; }
.legal-body h3 {
  margin-top: var(--space-8); font-size: var(--text-lg); font-weight: 800; font-stretch: var(--stretch-condensed);
  text-transform: uppercase; letter-spacing: 0.02em; line-height: 1.2;
}
.legal-body ul { list-style: disc; padding-left: var(--space-6); display: grid; gap: var(--space-2); }
.legal-body a { text-decoration: underline; text-underline-offset: 3px; }
.legal-body a:hover { color: var(--color-accent); }
.legal-updated { font-size: var(--text-sm); color: var(--color-text-muted); }
.legal-data { display: grid; border-top: 1px solid var(--color-border-strong); }
.legal-data > div { display: grid; grid-template-columns: 10rem 1fr; gap: var(--space-4); padding-block: var(--space-3); border-bottom: 1px solid var(--color-border); }
.legal-data dt { font-weight: 700; }
.legal-table-wrap { overflow-x: auto; }
.legal-table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }
.legal-table th, .legal-table td { text-align: left; padding: var(--space-3) var(--space-4) var(--space-3) 0; border-bottom: 1px solid var(--color-border); }
.legal-table thead th { font-size: var(--text-xs); text-transform: uppercase; letter-spacing: 0.12em; color: var(--color-text-muted); border-bottom-color: var(--color-border-strong); }
@media (max-width: 640px) {
  .legal { width: 100%; max-height: 100dvh; height: 100dvh; max-width: none; }
  .legal-head { padding: var(--space-4) var(--gutter); }
  .legal-body { padding: var(--space-6) var(--gutter) var(--space-12); }
  .legal-data > div { grid-template-columns: 1fr; gap: 0; }
}
body:has(.legal[open]) { overflow: hidden; }

/* ---------- Aviso de cookies ---------- */
.cookie-banner {
  position: fixed; z-index: 60; left: var(--gutter); right: var(--gutter); bottom: var(--gutter);
  max-width: var(--container); margin-inline: auto;
  display: grid; gap: var(--space-6); align-items: center;
  padding: var(--space-6) var(--space-8);
  background: var(--color-bg); border: 2px solid var(--color-text);
  box-shadow: 0 2px 4px rgb(0 0 0 / 0.04), 0 12px 32px rgb(0 0 0 / 0.12);
  font-size: var(--text-sm); color: var(--color-text-muted);
}
.cookie-banner[hidden] { display: none; }
.cookie-banner-title { font-weight: 900; font-stretch: var(--stretch-condensed); text-transform: uppercase; font-size: var(--text-xl); color: var(--color-text); line-height: 1; margin-bottom: var(--space-2); }
.cookie-banner a { color: var(--color-text); text-decoration: underline; text-underline-offset: 3px; }
/* Aceptar y Rechazar: mismo estilo, tamaño y nivel (criterio AEPD) */
.cookie-actions { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); align-items: center; }
.cookie-actions .btn { padding-inline: var(--space-4); }
.cookie-link {
  grid-column: 1 / -1; justify-self: center; min-height: 44px;
  font-size: var(--text-sm); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; color: var(--color-text);
}
.cookie-link:hover { color: var(--color-accent); }
@media (min-width: 900px) {
  .cookie-banner { grid-template-columns: 1fr auto; gap: var(--space-12); }
  .cookie-banner .cookie-actions { grid-template-columns: auto auto auto; }
  .cookie-banner .cookie-actions .btn { min-width: 11rem; }
  .cookie-link { grid-column: auto; }
}
@media (max-width: 640px) { .cookie-banner { padding: var(--space-4); left: var(--space-2); right: var(--space-2); bottom: var(--space-2); } }

.cookie-cats { list-style: none !important; padding: 0 !important; display: grid; gap: 0 !important; border-top: 1px solid var(--color-border-strong); }
.cookie-cat { display: flex; justify-content: space-between; align-items: center; gap: var(--space-6); padding-block: var(--space-4); border-bottom: 1px solid var(--color-border); }
.cookie-cat[hidden] { display: none; }
.cookie-cat p { font-size: var(--text-sm); color: var(--color-text-muted); }
.cookie-cat .cookie-cat-name { font-size: var(--text-base); font-weight: 800; color: var(--color-text); }
.cookie-cat input[role="switch"] {
  appearance: none; flex: none; position: relative; width: 48px; height: 28px; cursor: pointer;
  border: 2px solid var(--color-text); border-radius: 999px; background: var(--color-bg);
  transition: background-color var(--duration) var(--ease);
}
.cookie-cat input[role="switch"]::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: var(--color-text); transition: transform var(--duration) var(--ease), background-color var(--duration) var(--ease);
}
.cookie-cat input[role="switch"]:checked { background: var(--color-text); }
.cookie-cat input[role="switch"]:checked::after { transform: translateX(20px); background: var(--color-bg); }
.cookie-cat input[role="switch"]:disabled { cursor: not-allowed; opacity: 0.5; }
.legal-body .cookie-actions { margin-top: var(--space-8); }
.legal-body .cookie-actions .btn-outline { grid-column: 1 / -1; }

/* ---------- Aparición al hacer scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity var(--duration-slow) var(--ease), transform var(--duration-slow) var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .marquee-track { animation: none; }
  .js .reveal { opacity: 1; transform: none; }
}
