:root {
  --crema: #ebedf0;        /* gris claro frío (fondo) */
  --papel: #f7f8fa;
  --tinta: #24282c;        /* grafito frío */
  --tinta-suave: #6a717a;
  --acento: #5a6570;       /* acero / grafito */
  --acento-hondo: #3f484f; /* firma, etiqueta "Propuesta" */
  --linea: #dbdee2;
  --radio: 18px;
  --ancho: 880px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--crema);
  color: var(--tinta);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  border-top: 4px solid var(--acento);
}

/* ---------- cabecera ---------- */
.cabecera {
  max-width: var(--ancho);
  margin: 0 auto;
  padding: 56px 20px 28px;
  text-align: center;
}
.marca {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--acento);
}
.cabecera h1 {
  margin: 0;
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(2.4rem, 1.4rem + 5vw, 4.2rem);
  line-height: 1.04;
  letter-spacing: -.01em;
}
.sub {
  margin: 18px auto 0;
  max-width: 500px;
  color: var(--tinta-suave);
  font-size: 15px;
}

/* ---------- selector de propuestas ---------- */
.selector {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  gap: 8px;
  justify-content: flex-start;
  overflow-x: auto;
  padding: 12px 16px;
  background: color-mix(in srgb, var(--crema) 88%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--linea);
  scrollbar-width: none;
}
.selector::-webkit-scrollbar { display: none; }
@media (min-width: 700px) { .selector { justify-content: center; } }

.alt-btn {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px 10px 12px;
  border: 1px solid var(--linea);
  border-radius: 999px;
  background: var(--papel);
  color: var(--tinta);
  font: inherit;
  cursor: pointer;
  transition: all .25s ease;
}
.alt-btn .num {
  font-family: 'Fraunces', serif;
  font-size: 20px;
  color: var(--tinta-suave);
  transition: color .25s ease;
}
.alt-btn .nom { font-weight: 600; font-size: 14px; white-space: nowrap; }
.alt-btn .dots { display: flex; gap: 4px; }
.alt-btn .dots i {
  width: 14px; height: 14px;
  border-radius: 50%;
  border: 1px solid rgba(0,0,0,.15);
}
.alt-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(44,39,35,.10); }
.alt-btn.activo {
  background: var(--tinta);
  border-color: var(--tinta);
  color: #fff;
  box-shadow: 0 6px 18px rgba(44,39,35,.25);
}
.alt-btn.activo .num { color: #aeb8c2; }

/* ---------- bloques ---------- */
main { max-width: var(--ancho); margin: 0 auto; padding: 8px 16px 40px; }
.bloque { margin: 44px 0; }
.etiqueta {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--acento);
}
.titulo-seccion {
  margin: 0 0 6px;
  font-family: 'Fraunces', serif;
  font-weight: 600;
  font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2.1rem);
}
.ayuda { margin: 0 0 16px; color: var(--tinta-suave); font-size: 13.5px; }

/* ---------- pano ---------- */
.marco-pano {
  border-radius: var(--radio);
  overflow: hidden;
  box-shadow: 0 14px 40px rgba(44,39,35,.18);
  border: 1px solid var(--linea);
}
#pano { width: 100%; aspect-ratio: 16 / 10; background: #14100c; }
@media (max-width: 600px) { #pano { aspect-ratio: 4 / 5; } }

/* ---------- video ---------- */
#video {
  width: 100%;
  border-radius: var(--radio);
  border: 1px solid var(--linea);
  box-shadow: 0 14px 40px rgba(44,39,35,.18);
  background: #14100c;
  display: block;
}

/* ---------- galería ---------- */
.galeria {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 4px 4px 14px;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--acento) transparent;
}
.tarjeta {
  flex: 0 0 72%;
  max-width: 380px;
  scroll-snap-align: center;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  border: 1px solid var(--linea);
  background: var(--papel);
  cursor: zoom-in;
  transition: transform .25s ease, box-shadow .25s ease;
}
@media (min-width: 700px) { .tarjeta { flex-basis: 40%; } }
.tarjeta:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(44,39,35,.16); }
.tarjeta img { width: 100%; aspect-ratio: 3/4; object-fit: cover; display: block; }
.tarjeta .pie-foto {
  position: absolute;
  left: 10px; bottom: 10px;
  background: rgba(20,16,12,.62);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  padding: 5px 12px;
  border-radius: 999px;
  backdrop-filter: blur(4px);
}

/* ---------- comparador ---------- */
.comparar {
  position: relative;
  border-radius: var(--radio);
  overflow: hidden;
  aspect-ratio: 4 / 3;
  margin: 0 0 22px;
  border: 1px solid var(--linea);
  box-shadow: 0 14px 40px rgba(44,39,35,.18);
  touch-action: none;
  user-select: none;
  --pos: 50%;
}
.comparar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}
.capa-despues {
  position: absolute;
  inset: 0;
  clip-path: inset(0 0 0 var(--pos));
}
.manija {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--pos);
  width: 3px;
  background: #fff;
  transform: translateX(-1.5px);
  box-shadow: 0 0 12px rgba(0,0,0,.4);
}
.manija span {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 44px; height: 44px;
  border-radius: 50%;
  background: #fff;
  color: var(--tinta);
  display: grid;
  place-items: center;
  font-size: 18px;
  box-shadow: 0 4px 14px rgba(0,0,0,.35);
}
.etq {
  position: absolute;
  top: 12px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(20,16,12,.6);
  backdrop-filter: blur(4px);
}
.etq-a { left: 12px; }
.etq-b { right: 12px; background: var(--acento-hondo); }

/* ---------- ficha ---------- */
.materiales {
  list-style: none;
  margin: 0 0 18px;
  padding: 0;
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) { .materiales { grid-template-columns: 1fr 1fr; } }
.materiales li {
  background: var(--papel);
  border: 1px solid var(--linea);
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 14.5px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.materiales li::before {
  content: "";
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--acento);
  flex: 0 0 auto;
}
.materiales li.destacado { border-color: var(--acento); background: color-mix(in srgb, var(--acento) 8%, var(--papel)); font-weight: 600; }
.nota {
  color: var(--tinta-suave);
  font-size: 13.5px;
  border-left: 3px solid var(--linea);
  padding-left: 14px;
}

/* ---------- pie ---------- */
.pie {
  border-top: 1px solid var(--linea);
  text-align: center;
  padding: 26px 16px 34px;
  color: var(--tinta-suave);
  font-size: 13px;
}

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(15,11,8,.94);
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox[hidden] { display: none; }
.lightbox img {
  max-width: 94vw;
  max-height: 84vh;
  border-radius: 10px;
}
.lb-cerrar, .lb-prev, .lb-next {
  position: absolute;
  background: rgba(255,255,255,.12);
  border: none;
  color: #fff;
  width: 46px; height: 46px;
  border-radius: 50%;
  font-size: 26px;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background .2s ease;
}
.lb-cerrar:hover, .lb-prev:hover, .lb-next:hover { background: rgba(255,255,255,.28); }
.lb-cerrar { top: 16px; right: 16px; }
.lb-prev { left: 10px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 10px; top: 50%; transform: translateY(-50%); }
.lb-pie {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  font-size: 13px;
  background: rgba(255,255,255,.12);
  padding: 6px 16px;
  border-radius: 999px;
}

/* transición al cambiar de propuesta */
.fundido { animation: fundir .45s ease; }
@keyframes fundir { from { opacity: .25; } to { opacity: 1; } }
