/* ══════════════════════════════════════════════════════════════════
   Cinco mundos visuales. Cada tema redefine SOLO tokens.
   ══════════════════════════════════════════════════════════════════ */
:root {
  --fondo:#100E0C; --superficie:#17140F; --alto:#201C16;
  --texto:#F2ECE1; --suave:#CDC2AF; --tenue:#8C8375;
  --acento:#C4A44A; --acento-piso:#8A7231;
  --borde:rgba(242,236,225,0.12); --seleccion:rgba(196,164,74,0.28);
  --velo:16,14,12; --grano:0.26;
  --display:"Archivo","Helvetica Neue",Arial,sans-serif; --peso-display:600; --track:-0.035em;
  --cuerpo:"Archivo","Helvetica Neue",Arial,sans-serif;
  --realce:"EB Garamond","Times New Roman",serif; --dato:"Archivo",monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0; background: var(--fondo); color: var(--texto);
  font-family: var(--cuerpo); font-weight: 300; line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  transition: background 420ms cubic-bezier(.22,.72,.24,1), color 420ms cubic-bezier(.22,.72,.24,1);
}

::selection { background: var(--seleccion); color: var(--texto); }
:root { caret-color: var(--acento); scrollbar-color: var(--acento-piso) var(--superficie); scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--superficie); }
::-webkit-scrollbar-thumb { background: var(--acento-piso); }
:focus-visible { outline: 2px solid var(--acento); outline-offset: 3px; }

body::after {
  content: ""; position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: var(--grano);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)' opacity='0.5'/%3E%3C/svg%3E");
}

h1, h2, h3 { margin: 0; font-family: var(--display); font-weight: var(--peso-display); letter-spacing: var(--track); text-wrap: balance; }
p { margin: 0; }
a { color: inherit; }

.marco { width: 100%; max-width: 680px; margin-inline: auto; padding-inline: clamp(1.25rem,5vw,2.5rem); }

.barra { border-bottom: 1px solid var(--borde); }
.barra .marco { max-width: 1100px; height: 66px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.logotipo { display: flex; align-items: center; gap: .7rem; }
.logotipo span { font-family: var(--realce); font-size: .9375rem; letter-spacing: .2em; text-transform: uppercase; }
.socio { font-family: var(--dato); font-size: .8125rem; color: var(--tenue); }
.socio b { color: var(--acento); font-weight: 600; }

.panel { padding-block: clamp(3rem,8vh,4.5rem) clamp(5rem,12vh,7rem); display: flex; flex-direction: column; gap: 1.6rem; align-items: flex-start; }
.volver { font-size: .8125rem; color: var(--tenue); background: none; border: 0; padding: 0; cursor: pointer; display: inline-flex; align-items: center; gap: .5rem; font-family: var(--cuerpo); }
.volver:hover { color: var(--acento); }

.titular { font-size: clamp(2.1rem,6vw,3.4rem); line-height: 1.05; }
.titular em { font-family: var(--realce); font-style: italic; font-weight: 400; color: var(--acento); line-height: 1.12; padding-bottom: .06em; }

.texto { display: flex; flex-direction: column; gap: 1.5rem; width: 100%; }
.texto h3 { font-size: clamp(1.35rem,3.4vw,1.6rem); color: var(--acento); margin-top: 2rem; line-height: 1.18; }
.texto p { color: var(--suave); max-width: 68ch; font-size: 1.0625rem; }
.texto strong { color: var(--texto); font-weight: 600; }
.texto em { font-family: var(--realce); font-style: italic; color: var(--texto); }
.texto ul { margin: 0; padding-left: 1.2rem; display: flex; flex-direction: column; gap: .7rem; color: var(--suave); max-width: 68ch; font-size: 1.0625rem; }

.lema { margin: 1.25rem 0 .5rem; font-family: var(--realce); font-style: italic; font-size: clamp(1.7rem,5.4vw,2.6rem); line-height: 1.2; letter-spacing: var(--track); color: var(--texto); max-width: 20ch; }
.lema cite { display: block; font-family: var(--cuerpo); font-style: normal; font-size: .875rem; font-weight: 400; letter-spacing: 0; line-height: 1.55; color: var(--tenue); margin-top: 1.1rem; max-width: 42ch; }

.cuenta { width: 100%; border-top: 1px solid var(--borde); border-bottom: 1px solid var(--borde); padding-block: 1.4rem; display: flex; flex-direction: column; gap: .8rem; }
.cuenta__fila { display: flex; justify-content: space-between; align-items: baseline; gap: 1.5rem; font-size: .9375rem; color: var(--tenue); }
.cuenta__fila b { font-family: var(--dato); color: var(--texto); font-weight: 500; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.cuenta__total { display: flex; justify-content: space-between; align-items: baseline; gap: 1.5rem; padding-top: .9rem; margin-top: .3rem; border-top: 1px solid var(--borde); }
.cuenta__total span { font-size: .9375rem; color: var(--tenue); }
.cuenta__total b { font-family: var(--display); font-size: clamp(1.9rem,5.5vw,2.6rem); font-weight: var(--peso-display); letter-spacing: -.04em; color: var(--acento); font-variant-numeric: tabular-nums; line-height: 1; }

/* ── El puente al siguiente folio ── */
.puente { border-top: 1px solid var(--borde); margin-top: 2.5rem; padding-top: 2.25rem; width: 100%; display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }
.puente p { color: var(--tenue); font-size: .9375rem; max-width: 54ch; }
.boton {
  display: inline-flex; align-items: center; gap: .8rem;
  background: var(--texto); color: var(--fondo);
  border: 0; font-family: var(--cuerpo); cursor: pointer;
  padding: .95rem 1.6rem; font-size: .875rem; font-weight: 600;
  transition: background 320ms cubic-bezier(.22,.72,.24,1), color 320ms, transform 140ms ease;
}
.boton:hover { background: var(--acento); color: var(--fondo); }
.boton:active { transform: scale(.985); }
.boton svg { transition: transform 320ms cubic-bezier(.22,.72,.24,1); }
.boton:hover svg { transform: translateX(4px); }

/* ── El corte y el muro del club ── */
.corte { position: relative; width: 100%; }
.corte::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 220px;
  background: linear-gradient(to bottom, rgba(var(--velo),0) 0%, rgba(var(--velo),0.86) 62%, rgb(var(--velo)) 100%);
  pointer-events: none;
}
.corte--abierto::after { display: none; }
.corte__oculto { max-height: 260px; overflow: hidden; }
.corte--abierto .corte__oculto { max-height: none; overflow: visible; }

.muro { width: 100%; border: 1px solid var(--acento); padding: clamp(1.5rem,4vw,2.25rem); display: flex; flex-direction: column; gap: 1.1rem; align-items: flex-start; margin-top: -1rem; }
.muro h3 { font-size: clamp(1.5rem,4vw,2rem); color: var(--texto); margin: 0; line-height: 1.12; }
.muro > p { color: var(--suave); max-width: 56ch; }
.ventajas { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .8rem; width: 100%; }
.ventajas li { display: flex; gap: .85rem; align-items: flex-start; font-size: .9375rem; color: var(--suave); }
.ventajas svg { flex: none; margin-top: .38rem; color: var(--acento); }

.formulario { display: flex; flex-direction: column; gap: .8rem; width: 100%; max-width: 30rem; margin-top: .4rem; }
.caja { display: flex; border: 1px solid var(--borde); background: var(--fondo); }
.caja input { flex: 1; min-width: 0; background: transparent; border: 0; color: var(--texto); font-family: var(--cuerpo); font-size: 1rem; padding: .95rem 1.05rem; }
.caja input::placeholder { color: var(--tenue); }
.caja input:focus { outline: none; }
.caja:focus-within { border-color: var(--acento); }
.caja button { background: var(--texto); color: var(--fondo); border: 0; padding-inline: 1.35rem; font-family: var(--cuerpo); font-size: .8125rem; font-weight: 600; cursor: pointer; white-space: nowrap; transition: background 300ms; }
.caja button:hover { background: var(--acento); }
.letra-chica { font-size: .8125rem; color: var(--tenue); max-width: 48ch; }
.aviso { font-size: .875rem; min-height: 1.3em; color: var(--acento); }
.aviso[data-tipo="mal"] { color: #E0916F; }

.bienvenida { width: 100%; border: 1px solid var(--acento); padding: clamp(1.4rem,3.5vw,2rem); display: flex; flex-direction: column; gap: .7rem; }
.bienvenida b { color: var(--acento); font-size: .75rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.bienvenida p { color: var(--texto); max-width: 60ch; }

.tuyo { font-size: .8125rem; color: var(--acento); border: 1px solid var(--acento); padding: .85rem 1.1rem; max-width: 66ch; line-height: 1.55; }

.pie { border-top: 1px solid var(--borde); }
.pie .marco { max-width: 1100px; padding-block: 2.5rem 3rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: .8125rem; color: var(--tenue); }

/* Probador de estilos (no va en producción) */

[hidden] { display: none !important; }
.entra { animation: entra 720ms cubic-bezier(.16,1,.3,1) both; }
@keyframes entra { from { opacity: 0; transform: translateY(16px); filter: blur(6px); } to { opacity: 1; transform: none; filter: blur(0); } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; } }

/* ── Aviso flotante ─────────────────────────────────────────
   Aparece por encima de todo, cuenta una sola cosa y se va.
   No interrumpe la lectura: el contenido ya está abierto detrás. */
.flotante {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  transform: translate(-50%, 140%);
  z-index: 80;
  width: min(28rem, calc(100vw - 2rem));
  background: var(--superficie);
  border: 1px solid var(--acento);
  box-shadow: 0 24px 52px -22px rgba(6,4,2,0.9);
  padding: 1.15rem 1.3rem;
  display: flex;
  gap: .95rem;
  align-items: flex-start;
  transition: transform 620ms cubic-bezier(.16,1,.3,1), opacity 620ms cubic-bezier(.16,1,.3,1);
  opacity: 0;
}
.flotante[data-visible="si"] { transform: translate(-50%, 0); opacity: 1; }
.flotante svg { flex: none; color: var(--acento); margin-top: .2rem; }
.flotante__cuerpo { display: flex; flex-direction: column; gap: .3rem; }
.flotante__titulo { font-weight: 600; color: var(--texto); font-size: .9375rem; }
.flotante__pie { font-size: .875rem; color: var(--suave); line-height: 1.5; }
.flotante__cerrar {
  background: none; border: 0; padding: .1rem .3rem; cursor: pointer;
  color: var(--tenue); font-family: var(--cuerpo); font-size: 1.1rem; line-height: 1;
  margin-left: auto; align-self: flex-start;
}
.flotante__cerrar:hover { color: var(--texto); }

@media (prefers-reduced-motion: reduce) {
  .flotante { transition: opacity 200ms linear; }
}
