/* missed studio · página de próxima salida
   Fuentes alojadas en /fonts (licencia SIL OFL). Si aún no están, se usa la pila del sistema. */
@font-face { font-family: "Outfit"; src: url("/fonts/outfit-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Outfit"; src: url("/fonts/outfit-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Lora"; src: url("/fonts/lora-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("/fonts/ibm-plex-mono-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --crema: #F3EDDE;
  --crema-oscura: #E9E1CD;
  --oliva: #747C5A;          /* logo y elementos grandes */
  --oliva-texto: #5E6548;    /* texto: contraste 5,2:1 sobre crema */
  --oliva-panel: #3F4430;    /* fondo del panel de salidas */
  --ambar: #E3B04B;          /* luz de "próximamente" */
  --linea: rgba(94, 101, 72, 0.25);
  --f-marca: "Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --f-lema: "Lora", "Iowan Old Style", Georgia, serif;
  --f-panel: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

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

html { background: var(--crema); color: var(--oliva-texto); font-family: var(--f-marca);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }

body { min-height: 100svh; }

::selection { background: var(--oliva-texto); color: var(--crema); }

a { color: inherit; text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--oliva-texto); outline-offset: 3px; }

.grano { position: fixed; inset: 0; pointer-events: none; opacity: .03; z-index: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E"); }

.pagina { position: relative; z-index: 1; max-width: 1080px; margin: 0 auto; min-height: 100svh;
  display: flex; flex-direction: column; gap: clamp(2rem, 6vh, 4rem);
  padding: max(1.25rem, env(safe-area-inset-top)) max(1.25rem, env(safe-area-inset-right))
           max(1.25rem, env(safe-area-inset-bottom)) max(1.25rem, env(safe-area-inset-left)); }

/* Cabecera tipo estación */
.cabecera { display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding-bottom: .9rem; border-bottom: 1px solid var(--linea);
  font-size: .75rem; font-weight: 500; letter-spacing: .2em; text-transform: uppercase; }
.marca-pequena { display: inline-flex; line-height: 0; }
.marca-pequena img { width: 24px; height: auto; }
.reloj { font-family: var(--f-panel); letter-spacing: .08em; font-variant-numeric: tabular-nums; }

main { flex: 1; display: flex; flex-direction: column; gap: clamp(2.5rem, 7vh, 4.5rem); }

/* Portada */
.portada { text-align: center; padding-top: clamp(1rem, 5vh, 3rem); }
.antetitulo { font-size: .75rem; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; margin-bottom: 1.25rem; }
/* Logo principal (imagen; el texto alternativo "missed studio" queda para buscadores y lectores de pantalla) */
.wordmark { line-height: 0; }
.wordmark img { display: inline-block; width: min(100%, 30rem); height: auto; }
.lema { margin-top: 1.5rem; font-family: var(--f-lema); font-style: italic;
  font-size: clamp(1.1rem, 2.6vw, 1.35rem); line-height: 1.45; }

/* Panel de salidas */
.panel { background: var(--oliva-panel); color: var(--crema); border-radius: 6px;
  padding: clamp(1rem, 3vw, 1.75rem); font-family: var(--f-panel); font-weight: 500;
  box-shadow: inset 0 0 0 1px rgba(243,237,222,.06); }
.panel-cabecera, .fila { display: grid; grid-template-columns: 1fr 5.5rem 4rem 11rem; gap: 1rem; align-items: center; }
.panel-cabecera { font-size: .7rem; letter-spacing: .18em; text-transform: uppercase; opacity: .6;
  padding-bottom: .75rem; border-bottom: 1px solid rgba(243,237,222,.15); }
.fila { padding: 1rem 0; border-bottom: 1px dashed rgba(243,237,222,.15); font-size: clamp(.85rem, 2.2vw, 1.05rem); letter-spacing: .06em; }
.celda { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.estado { display: flex; align-items: center; gap: .55rem; color: var(--ambar); }
.estado.apagado { color: rgba(243,237,222,.55); }
.punto { width: .5rem; height: .5rem; border-radius: 50%; background: var(--ambar); flex: none; }
.panel-aviso { margin-top: 1rem; font-size: .78rem; letter-spacing: .04em; opacity: .7; line-height: 1.6; }

@media (prefers-reduced-motion: no-preference) {
  .punto { animation: parpadeo 1.6s ease-in-out infinite; }
}
@keyframes parpadeo { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }

/* Formulario */
.avisame { max-width: 560px; margin: 0 auto; width: 100%; text-align: center; }
.avisame h2 { font-size: clamp(1.3rem, 3vw, 1.6rem); font-weight: 500; letter-spacing: -0.01em; }
.avisame-texto { margin-top: .5rem; font-size: .95rem; }
.formulario { margin-top: 1.5rem; text-align: left; }
.campo-fila { display: flex; gap: .5rem; }
.campo-fila input { flex: 1; min-width: 0; font: inherit; font-size: 1rem; color: var(--oliva-texto);
  background: var(--crema-oscura); border: 1px solid var(--linea); border-radius: 4px; padding: .85rem 1rem; }
.campo-fila input::placeholder { color: rgba(94,101,72,.65); }
.campo-fila button { font: inherit; font-size: .95rem; font-weight: 500; letter-spacing: .04em; cursor: pointer;
  color: var(--crema); background: var(--oliva-texto); border: 0; border-radius: 4px; padding: .85rem 1.4rem; }
.campo-fila button:hover { background: var(--oliva-panel); }
.campo-fila button:disabled { opacity: .6; cursor: wait; }
.consentimiento { display: flex; gap: .6rem; align-items: flex-start; margin-top: 1rem; font-size: .82rem; line-height: 1.5; cursor: pointer; }
.consentimiento input { margin-top: .2rem; accent-color: var(--oliva-texto); width: 1rem; height: 1rem; flex: none; }
.mensaje { margin-top: 1rem; min-height: 1.4em; font-size: .9rem; text-align: center; }
.mensaje.error { color: #8A3B2A; }
.trampa { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.avisame-pronto { display: inline-flex; align-items: center; gap: .55rem; margin-top: 1.5rem;
  padding: .8rem 1.2rem; border: 1px dashed var(--linea); border-radius: 4px;
  font-family: var(--f-panel); font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; }
.avisame-pronto::before { content: ""; width: .45rem; height: .45rem; border-radius: 50%; background: var(--ambar); flex: none; }

[hidden] { display: none !important; }

/* Pie */
.pie { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem 1.75rem; padding-top: 1rem;
  border-top: 1px solid var(--linea); font-size: .75rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }
.apagado-pie { opacity: .55; }

/* Páginas de texto (aviso legal y privacidad) */
.cabecera a { text-decoration: none; }
.texto { max-width: 680px; margin: 0 auto; width: 100%; line-height: 1.65; font-size: 1rem; }
.texto h1 { font-size: clamp(1.8rem, 5vw, 2.4rem); font-weight: 500; letter-spacing: -0.02em; color: var(--oliva); line-height: 1.15; }
.texto .actualizado { margin-top: .5rem; font-family: var(--f-panel); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; opacity: .75; }
.texto h2 { margin-top: 2.25rem; font-size: 1.15rem; font-weight: 500; letter-spacing: -0.005em; }
.texto p, .texto ul, .texto dl { margin-top: .75rem; }
.texto ul { padding-left: 1.2rem; }
.texto li + li { margin-top: .35rem; }
.texto dl { display: grid; grid-template-columns: max-content 1fr; gap: .4rem 1.25rem; }
.texto dt { font-weight: 500; }
.pendiente { font-family: var(--f-panel); font-size: .85em; letter-spacing: .06em; text-transform: uppercase;
  color: var(--oliva-texto); background: var(--crema-oscura); border-radius: 3px; padding: .05em .45em; }
.volver { display: inline-block; margin-top: 2.5rem; font-size: .8rem; font-weight: 500; letter-spacing: .14em; text-transform: uppercase; }

/* 404: andén equivocado */
.perdido { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 1.25rem; }
.perdido .codigo { font-family: var(--f-panel); font-size: clamp(3.5rem, 14vw, 6rem); color: var(--oliva); letter-spacing: .04em; line-height: 1; }
.perdido p { font-family: var(--f-lema); font-style: italic; font-size: clamp(1.1rem, 2.6vw, 1.3rem); }

@media (max-width: 640px) {
  .texto dl { grid-template-columns: 1fr; gap: .1rem; }
  .texto dd { margin-bottom: .6rem; }
}

/* Móvil: el panel pierde la columna de andén y se compacta */
@media (max-width: 640px) {
  .panel-cabecera, .fila { grid-template-columns: 1fr auto; gap: .75rem; }
  .col-anden, .hora, .panel-cabecera span:nth-child(2) { display: none; }
  .fila { font-size: .9rem; }
  .estacion { display: none; }
  .campo-fila { flex-direction: column; }
}
