/* ==========================================================================
   Construcciones López Álvarez S.L. — hoja de estilos
   HTML + CSS estático, sin dependencias externas.
   ========================================================================== */

@font-face {
  font-family: "Archivo";
  src: url("../fonts/archivo.woff2") format("woff2-variations"), url("../fonts/archivo.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Colores de marca (tomados del logotipo) */
  --green: #36672f;        /* verde del rótulo */
  --green-deep: #1d361a;   /* pie de página */
  --copper: #a05f1a;       /* tejado del símbolo */
  --copper-soft: #c9893f;  /* cobre sobre fondo oscuro */
  --ink: #1a2a1c;
  --muted: #56645a;
  --stone: #eef1ec;        /* paspartú de las fotos y bandas */
  --line: #d3dbd1;
  --white: #ffffff;

  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --wrap: 76rem;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --header-h: 4.5rem;
  --radius: 2px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-stretch: 100%;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--green); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--copper); outline-offset: 3px; }

h1, h2, h3 { font-family: var(--sans); font-weight: 700; font-stretch: 88%; letter-spacing: -0.02em; line-height: 1.08; margin: 0; }
p { margin: 0 0 1em; }

.wrap { width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto; }

.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--ink); color: var(--white); padding: 0.6rem 1rem; text-decoration: none;
}
.skip:focus { top: 1rem; }

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

/* --------------------------------------------------------------------------
   Línea de tejado (motivo tomado del símbolo de la marca)
   -------------------------------------------------------------------------- */
.roof { display: block; width: 4.5rem; height: auto; color: var(--copper); overflow: visible; }
.roof path { fill: none; stroke: currentColor; stroke-width: 3; stroke-linejoin: miter; stroke-linecap: square; }

/* --------------------------------------------------------------------------
   Cabecera
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(1.2) blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
  min-height: var(--header-h);
}
.brand { display: block; flex: 0 1 auto; min-width: 0; }
.brand img { height: 2rem; width: auto; max-width: 100%; }

.nav-toggle {
  display: none;
  font: 600 0.9375rem/1 var(--sans);
  color: var(--ink); background: none; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 0.6rem 0.8rem; cursor: pointer; align-items: center; gap: 0.5rem;
}
.nav-toggle-bars { width: 1rem; height: 0.7rem; position: relative; border-top: 2px solid currentColor; border-bottom: 2px solid currentColor; }
.nav-toggle-bars::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 2px solid currentColor; transform: translateY(-50%); }

.site-nav { display: flex; align-items: center; gap: 2rem; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.5rem; }
.site-nav a {
  display: block; padding: 0.4rem 0; color: var(--ink); text-decoration: none;
  font-size: 0.9375rem; font-weight: 500; border-bottom: 2px solid transparent;
}
.site-nav a:hover { border-bottom-color: var(--line); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--copper); }

.lang { display: flex; align-items: center; gap: 0.25rem; font-size: 0.875rem; font-weight: 600; }
.lang a, .lang span { padding: 0.3rem 0.45rem; text-decoration: none; border-radius: var(--radius); }
.lang span { background: var(--green); color: var(--white); }
.lang a { color: var(--muted); }
.lang a:hover { color: var(--ink); background: var(--stone); }

@media (max-width: 68rem) {
  .nav-toggle { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--white); border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; gap: 0;
    padding: 0.5rem var(--gutter) 1.25rem;
    box-shadow: 0 12px 24px -16px rgba(26, 42, 28, 0.35);
  }
  .site-nav.is-open { display: flex; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav li + li { border-top: 1px solid var(--line); }
  .site-nav a { padding: 0.85rem 0; font-size: 1.0625rem; border-bottom: 0; }
  .site-nav a[aria-current="page"] { color: var(--green); box-shadow: inset 3px 0 0 var(--copper); padding-left: 0.75rem; }
  .lang { margin-top: 1rem; }
}
@media (max-width: 30rem) {
  .brand img { height: 1.25rem; }
  .nav-toggle-label { display: none; }
}

/* --------------------------------------------------------------------------
   Botones
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 3rem; padding: 0.75rem 1.4rem;
  font: 600 0.9375rem/1.2 var(--sans); text-decoration: none;
  border: 1.5px solid var(--green); border-radius: var(--radius);
  background: var(--green); color: var(--white);
  transition: background-color 0.15s, color 0.15s;
}
.btn:hover { background: var(--green-deep); border-color: var(--green-deep); color: var(--white); }
.btn--line { background: transparent; color: var(--green); }
.btn--line:hover { background: var(--green); color: var(--white); border-color: var(--green); }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* --------------------------------------------------------------------------
   Portada: foto a todo el ancho con los valores de la empresa
   -------------------------------------------------------------------------- */
.btn--light { background: var(--white); border-color: var(--white); color: var(--green-deep); }
.btn--light:hover { background: var(--stone); border-color: var(--stone); color: var(--green-deep); }
.btn--ghost { background: transparent; border-color: rgba(255, 255, 255, 0.75); color: var(--white); }
.btn--ghost:hover { background: rgba(255, 255, 255, 0.14); border-color: var(--white); color: var(--white); }

.hero {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; align-items: flex-end;
  min-height: clamp(36rem, calc(100svh - var(--header-h)), 62rem);
  background: var(--green-deep); color: var(--white);
}
.hero-media { position: absolute; inset: 0; z-index: -2; margin: 0; }
.hero-media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transform: scale(1.07);
  transition: opacity 1.4s ease, transform 0s linear 1.4s;
}
.hero-media img.is-active { opacity: 1; transform: scale(1); transition: opacity 1.4s ease, transform 8s cubic-bezier(.2, .6, .3, 1); }
.hero-shade {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    linear-gradient(to top, rgba(13, 24, 14, 0.92) 0%, rgba(13, 24, 14, 0.62) 30%, rgba(13, 24, 14, 0.12) 62%, rgba(13, 24, 14, 0) 75%),
    linear-gradient(to right, rgba(13, 24, 14, 0.5) 0%, rgba(13, 24, 14, 0) 60%);
}
.hero-content { padding-block: 7rem clamp(1.5rem, 3vw, 2.25rem); }
.hero .roof { width: clamp(4rem, 7vw, 6rem); color: var(--copper-soft); margin-bottom: 0.25rem; }
.hero .roof path { stroke-width: 2.5; }

/* Misma letra que los títulos de página (p. ej. «La empresa») */
.hero-word {
  font-family: var(--sans); font-weight: 700; font-stretch: 88%; letter-spacing: -0.02em; line-height: 1;
  font-size: clamp(2.75rem, 9.5vw, 7.5rem);
  margin: 0 0 clamp(1.5rem, 3vw, 2.25rem); min-height: 1em;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.25);
}
.hero-word span { display: inline-block; }
.hero-word span.is-entering { animation: word-in 0.8s cubic-bezier(.2, .7, .2, 1) both; }
@keyframes word-in { from { opacity: 0; transform: translateY(0.25em); } to { opacity: 1; transform: none; } }

.hero-bar {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1.25rem 3rem; align-items: end;
  margin-top: clamp(2.5rem, 7vh, 5rem);
}
.values { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0 clamp(1rem, 2.5vw, 2rem); }
.values button {
  position: relative; width: 100%; text-align: left; cursor: pointer;
  font: 500 0.9375rem/1.3 var(--sans); color: rgba(255, 255, 255, 0.62);
  background: none; border: 0; padding: 1rem 0 0.25rem;
  transition: color 0.3s;
}
.values button::before, .values button::after { content: ""; position: absolute; left: 0; top: 0; height: 2px; }
.values button::before { right: 0; background: rgba(255, 255, 255, 0.28); }
.values button::after { width: 0; background: var(--copper-soft); }
.values button:hover, .values button[aria-current="true"] { color: var(--white); }
.values button[aria-current="true"]::after { width: 100%; }
.hero.is-playing .values button[aria-current="true"]::after { animation: progreso 6s linear both; }
@keyframes progreso { from { width: 0; } to { width: 100%; } }

.hero-foot { display: flex; align-items: flex-end; gap: 1.25rem; }
.hero-caption { display: none; margin: 0; max-width: 21rem; text-align: right; font-size: 0.8125rem; line-height: 1.45; color: rgba(255, 255, 255, 0.8); }
.hero-caption.is-active { display: block; }
.hero-caption strong { display: block; color: var(--copper-soft); font-size: 0.875rem; font-weight: 700; }
.hero-pause {
  flex: none; width: 2.5rem; height: 2.5rem; display: grid; place-items: center; cursor: pointer;
  background: transparent; color: var(--white); border: 1px solid rgba(255, 255, 255, 0.5); border-radius: 50%;
}
.hero-pause:hover { border-color: var(--white); background: rgba(255, 255, 255, 0.12); }
.hero-pause svg { width: 0.8rem; height: 0.8rem; }
.hero-pause .i-play { display: none; }
.hero-pause[aria-pressed="true"] .i-play { display: block; }
.hero-pause[aria-pressed="true"] .i-pause { display: none; }

/* Dibujo del tejado: único movimiento de entrada de la página */
.js .hero .roof path { stroke-dasharray: 120; stroke-dashoffset: 120; animation: roof-draw 1.2s 0.2s cubic-bezier(.6, 0, .2, 1) forwards; }
@keyframes roof-draw { to { stroke-dashoffset: 0; } }

@media (max-width: 52rem) {
  .hero { min-height: min(calc(100svh - var(--header-h)), 48rem); }
  .hero-content { padding-top: 5rem; }
  .hero-bar { grid-template-columns: 1fr; }
  .values { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 0.5rem; }
  .hero-foot { justify-content: space-between; }
  .hero-caption { text-align: left; }
}

/* --------------------------------------------------------------------------
   Secciones
   -------------------------------------------------------------------------- */
.section { padding-block: clamp(3rem, 7vw, 6rem); }
.section--stone { background: var(--stone); }
.section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: clamp(1.75rem, 3vw, 2.75rem); }
.section-head h2 { font-size: clamp(2rem, 4vw, 3rem); }

.intro { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.intro-text p {
  font-size: clamp(1.15rem, 1.7vw, 1.3125rem); line-height: 1.65;
  max-width: 34em; margin-bottom: 1.5rem;
}
@media (max-width: 52rem) { .intro { grid-template-columns: 1fr; } }

/* Ficha: datos de la empresa con el formato de una ficha técnica de obra */
.ficha { margin: 0; border-top: 2px solid var(--ink); }
.ficha div { display: grid; grid-template-columns: 11rem 1fr; gap: 1rem; padding: 0.9rem 0; border-bottom: 1px solid var(--line); }
.ficha dt { font-size: 0.875rem; color: var(--muted); padding-top: 0.15rem; }
.ficha dd { margin: 0; font-weight: 500; }
.ficha dd strong { font-size: 1.25rem; font-weight: 700; line-height: 1.25; }
@media (max-width: 30rem) { .ficha div { grid-template-columns: 1fr; gap: 0.15rem; } }

/* --------------------------------------------------------------------------
   Cabecera de páginas interiores
   -------------------------------------------------------------------------- */
.page-head { padding-block: clamp(2.5rem, 6vw, 5rem) clamp(1.5rem, 3vw, 2.5rem); }
.page-head .roof { margin-bottom: 0.5rem; }
.page-head h1 { font-size: clamp(2.6rem, 7vw, 5rem); letter-spacing: -0.01em; }
.page-head .lead { margin: 1rem 0 0; font-size: 1.125rem; color: var(--muted); max-width: 46ch; }
.page-body { padding-bottom: clamp(3.5rem, 8vw, 7rem); }

/* --------------------------------------------------------------------------
   Obras (construcciones y promociones)
   Las fotos se muestran completas sobre un paspartú, sin recortar el edificio.
   -------------------------------------------------------------------------- */
.obras { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(2rem, 4vw, 3.5rem) clamp(1.25rem, 2.5vw, 2.25rem); }
@media (max-width: 60rem) { .obras { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 36rem) { .obras { grid-template-columns: 1fr; } }

.obra-foto {
  display: block; aspect-ratio: 4 / 3; background: var(--stone); padding: 5%;
  cursor: zoom-in; position: relative;
}
.obra-foto img { width: 100%; height: 100%; object-fit: contain; }
.obra-foto:hover img { filter: brightness(1.04); }
.obra-foto::after {
  content: ""; position: absolute; right: 0.6rem; bottom: 0.6rem; width: 1.75rem; height: 1.75rem;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231a2a1c' stroke-width='2'%3E%3Cpath d='M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7'/%3E%3C/svg%3E") center / 0.85rem no-repeat;
  border-radius: 50%; opacity: 0; transition: opacity 0.2s;
}
.obra-foto:hover::after, .obra-foto:focus-visible::after { opacity: 1; }

.obra-años { font-size: 1.125rem; font-weight: 700; color: var(--copper); margin: 1rem 0 0.25rem; font-variant-numeric: lining-nums; }
.obra h2, .obra h3 { font-family: var(--sans); font-size: 1.0625rem; font-weight: 600; line-height: 1.35; margin: 0 0 0.3rem; }
.obra-lugar { font-size: 0.9375rem; color: var(--muted); margin: 0; }

/* --------------------------------------------------------------------------
   Empresa
   -------------------------------------------------------------------------- */
.empresa { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(2rem, 6vw, 5rem); align-items: start; }
.empresa-text p { max-width: 62ch; }
.empresa-destacado {
  font-size: clamp(1.3rem, 2.4vw, 1.6rem); line-height: 1.35; font-weight: 700; font-stretch: 88%;
  border-top: 2px solid var(--ink); padding-top: 1.25rem; margin-top: 2.25rem; max-width: 24ch;
}
.empresa-aside { display: grid; gap: 2rem; position: sticky; top: calc(var(--header-h) + 1.5rem); }
.empresa-aside figure { margin: 0; }
.empresa-aside figcaption { font-size: 0.8125rem; color: var(--muted); margin-top: 0.5rem; }
@media (max-width: 52rem) { .empresa { grid-template-columns: 1fr; } .empresa-aside { position: static; } }

/* --------------------------------------------------------------------------
   Enlaces de interés
   -------------------------------------------------------------------------- */
.enlaces { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.25rem, 3vw, 2.5rem); }
@media (max-width: 40rem) { .enlaces { grid-template-columns: 1fr; } }
.enlace { display: grid; grid-template-rows: auto 1fr; height: 100%; text-decoration: none; color: var(--ink); border-top: 2px solid var(--ink); }
.enlace-logo { display: flex; align-items: center; justify-content: center; height: clamp(10rem, 22vw, 15rem); background: var(--stone); padding: 1.5rem 2rem; margin-top: 1.25rem; min-width: 0; }
.enlace-logo img { max-height: 100%; max-width: 100%; width: auto; height: auto; object-fit: contain; mix-blend-mode: multiply; }
.enlace-text { padding-top: 1rem; }
.enlace-text strong { display: block; font-size: 1.375rem; font-weight: 700; line-height: 1.2; }
.enlace-text span { display: block; color: var(--muted); font-size: 0.9375rem; margin-top: 0.35rem; }
.enlace-text em { display: inline-block; font-style: normal; color: var(--green); font-weight: 600; margin-top: 0.75rem; text-decoration: underline; text-underline-offset: 0.2em; }
.enlace:hover .enlace-text em { color: var(--ink); }

/* --------------------------------------------------------------------------
   Contacto
   -------------------------------------------------------------------------- */
.contacto { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 56rem) { .contacto { grid-template-columns: 1fr; } }
.contacto .ficha div { grid-template-columns: 6.5rem 1fr; }
.contacto .ficha dd a { font-weight: 600; }
.mapa { aspect-ratio: 4 / 3; background: var(--stone); }
.mapa iframe { width: 100%; height: 100%; border: 0; display: block; }
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.5rem 0.85rem; min-height: 2.75rem;
  border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); text-decoration: none; font-size: 0.9375rem; font-weight: 500;
}

/* Banda de contacto (portada) */
.cta { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 2rem 4rem; align-items: end; }
.cta h2 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 0.75rem; }
.cta p { color: var(--muted); max-width: 40ch; margin: 0; }
.cta-datos { display: grid; gap: 0.75rem; }
.cta-datos .tel { font-size: clamp(2rem, 4.5vw, 3rem); font-weight: 700; font-stretch: 88%; color: var(--ink); text-decoration: none; line-height: 1.1; font-variant-numeric: lining-nums; }
.cta-datos .tel:hover { color: var(--green); }
@media (max-width: 52rem) { .cta { grid-template-columns: 1fr; } }

/* Mapa web */
.mapa-web { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.5rem; }
.mapa-web h2 { font-size: 1.5rem; margin-bottom: 0.75rem; }
.mapa-web ul { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.mapa-web li { border-bottom: 1px solid var(--line); }
.mapa-web a { display: block; padding: 0.75rem 0; text-decoration: none; color: var(--ink); font-weight: 500; }
.mapa-web a:hover { color: var(--green); }
@media (max-width: 40rem) { .mapa-web { grid-template-columns: 1fr; } }

/* --------------------------------------------------------------------------
   Pie
   -------------------------------------------------------------------------- */
.site-footer { background: var(--green-deep); color: #dfe7dc; font-size: 0.9375rem; padding-top: clamp(3rem, 6vw, 4.5rem); }
.site-footer a { color: var(--white); }
.site-footer a:hover { color: var(--copper-soft); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2.5rem; padding-bottom: 3rem; }
.footer-name { font-size: 1.25rem; line-height: 1.25; color: var(--white); margin: 0 0 1rem; font-weight: 700; }
.site-footer h2 { font-family: var(--sans); font-size: 0.875rem; font-weight: 600; color: var(--copper-soft); margin: 0 0 0.75rem; }
.site-footer address { font-style: normal; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.35rem; }
.site-footer .footer-nav a { text-decoration: none; }
.site-footer .footer-nav a:hover { text-decoration: underline; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, 0.15); padding-block: 1.25rem; display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; justify-content: space-between; font-size: 0.8125rem; color: #b9c6b5; }
.footer-bottom button { font: inherit; color: var(--white); background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 0.2em; cursor: pointer; }
@media (max-width: 60rem) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 36rem) { .footer-grid { grid-template-columns: 1fr; } }

/* --------------------------------------------------------------------------
   Visor de fotos
   -------------------------------------------------------------------------- */
.visor {
  width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0;
  background: rgba(14, 22, 15, 0.96); color: var(--white);
}
.visor::backdrop { background: rgba(14, 22, 15, 0.9); }
.visor[open] { display: grid; grid-template-rows: 1fr auto; }
.visor-stage { position: relative; display: grid; place-items: center; padding: 3.5rem 4.5rem 1rem; min-height: 0; }
.visor-stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.visor-caption { padding: 0.75rem 4.5rem 1.5rem; text-align: center; }
.visor-caption .obra-años { color: var(--copper-soft); margin: 0; font-size: 1.125rem; }
.visor-caption p { margin: 0.15rem 0 0; color: #dfe7dc; }
.visor button {
  position: absolute; display: grid; place-items: center; width: 3rem; height: 3rem;
  background: rgba(255, 255, 255, 0.1); color: var(--white); border: 0; border-radius: 50%; cursor: pointer;
}
.visor button:hover { background: rgba(255, 255, 255, 0.22); }
.visor button svg { width: 1.25rem; height: 1.25rem; fill: none; stroke: currentColor; stroke-width: 2; }
.visor-close { top: 0.75rem; right: 0.75rem; }
.visor-prev { left: 0.75rem; top: 50%; transform: translateY(-50%); }
.visor-next { right: 0.75rem; top: 50%; transform: translateY(-50%); }
@media (max-width: 40rem) {
  .visor-stage { padding: 3.75rem 0.5rem 0.5rem; }
  .visor-caption { padding-inline: 1rem; padding-bottom: 5rem; }
  .visor-prev, .visor-next { top: auto; bottom: 1rem; transform: none; }
}

/* --------------------------------------------------------------------------
   Aviso de cookies
   -------------------------------------------------------------------------- */
.cookies {
  position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 60;
  max-width: 34rem; margin-left: auto;
  background: var(--white); color: var(--ink); border: 1px solid var(--line); border-top: 3px solid var(--green);
  box-shadow: 0 18px 40px -18px rgba(26, 42, 28, 0.45);
  padding: 1.25rem 1.25rem 1.1rem; font-size: 0.9375rem;
}
.cookies[hidden] { display: none; }
.cookies p { margin: 0 0 1rem; }
.cookies .btn { min-height: 2.6rem; padding: 0.5rem 1.1rem; }

/* --------------------------------------------------------------------------
   Páginas legales
   -------------------------------------------------------------------------- */
.legal > * { max-width: 46rem; }
.legal h2 { font-size: clamp(1.4rem, 2.6vw, 1.75rem); margin: 2.5rem 0 0.9rem; }
.legal p, .legal li { max-width: 68ch; }
.legal ul { padding-left: 1.25rem; margin: 0 0 1em; }
.legal li { margin-bottom: 0.4rem; }
.legal .ficha { margin: 0.5rem 0 1rem; }
.legal .ficha div { grid-template-columns: 10rem 1fr; }
.legal code { font-size: 0.9em; background: var(--stone); padding: 0.1em 0.35em; border-radius: var(--radius); }
.legal-nota { font-size: 0.9375rem; color: var(--muted); border-left: 3px solid var(--copper); padding-left: 0.9rem; }
.legal-fecha { margin-top: 3rem; font-size: 0.875rem; color: var(--muted); }
.tabla { overflow-x: auto; margin: 0.5rem 0 1.25rem; }
.tabla table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
.tabla--ancha table { min-width: 32rem; }
.tabla th { text-align: left; font-weight: 600; border-bottom: 2px solid var(--ink); padding: 0.6rem 0.75rem 0.6rem 0; }
.tabla td { border-bottom: 1px solid var(--line); padding: 0.7rem 0.75rem 0.7rem 0; vertical-align: top; }
@media (max-width: 30rem) { .legal .ficha div { grid-template-columns: 1fr; } }

/* Pie: enlaces legales */
.footer-legal { display: flex; flex-wrap: wrap; gap: 0.4rem 1.25rem; }
.footer-legal a { color: var(--white); }

/* Mapa con carga bajo demanda */
.mapa-aviso { text-align: center; padding: 2rem; max-width: 26rem; }
.mapa-aviso p { color: var(--muted); }
.mapa-aviso .btn-row { justify-content: center; }
.cookies a { color: var(--green); font-weight: 600; }

/* 404 */
.notfound { min-height: 50vh; }
.notfound .btn-row { margin-top: 2rem; }

@media print {
  .site-header, .cookies, .hero-pause, .mapa { display: none !important; }
  body { font-size: 11pt; }
}
