/* 55 Aniversario FADU — identidad tomada de la invitación oficial */
:root {
  --guinda: #8C3B32;
  --verde: #00483A;
  --verde-hondo: #00352b;
  --ocre: #D5A10F;
  --oro: #e2b44e;
  --gris: #5f5b58;
  --tinta: #2b2826;
  --perla: #f5f6f7;
  --perla-2: #eceef1;
  --perla-3: #dfe2e6;
  --blanco: #ffffff;

  --serif: "Source Serif 4", "Source Serif Pro", Georgia, "Times New Roman", serif;
  --medida: 38rem;
  --ancho: 72rem;
  --margen: clamp(1.25rem, 5vw, 3rem);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5rem; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--tinta);
  background: var(--perla);
  font-optical-sizing: auto;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--verde); text-underline-offset: .2em; text-decoration-thickness: 1px; }
a:hover { color: var(--guinda); }
:focus-visible { outline: 2px solid var(--ocre); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { font-weight: 400; line-height: 1.15; margin: 0; text-wrap: balance; }
p { margin: 0 0 1.1em; }

.solo-lectores {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.saltar {
  position: absolute; left: 1rem; top: -4rem; z-index: 10;
  background: var(--verde); color: var(--blanco); padding: .5rem 1rem;
}
.saltar:focus { top: 1rem; color: var(--blanco); }

/* ── Arcos dorados (firma visual de la invitación) ─────────────────────── */
.arcos {
  position: absolute; left: 0; right: 0; bottom: 0;
  width: 100%; height: min(34vh, 22rem);
  pointer-events: none;
}
.arcos .trazo {
  stroke-dasharray: 2200; stroke-dashoffset: 2200;
  animation: trazar 2.6s cubic-bezier(.6, .05, .2, 1) .3s forwards;
}
.arcos .trazo--2 { animation-delay: .7s; }
@keyframes trazar { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) {
  .arcos .trazo { animation: none; stroke-dashoffset: 0; }
}

/* ── Cuenta regresiva ──────────────────────────────────────────────────── */
.pagina-cuenta {
  min-height: 100vh; min-height: 100svh;
  position: relative; overflow-x: hidden;
  background:
    radial-gradient(ellipse 70% 55% at 62% 28%, var(--blanco) 0%, rgba(255,255,255,0) 70%),
    linear-gradient(180deg, var(--perla) 0%, var(--perla-2) 100%);
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.cuenta {
  position: relative; z-index: 1;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column;
  padding: clamp(1.5rem, 4vw, 3rem) var(--margen) clamp(9rem, 22vh, 14rem);
  max-width: var(--ancho); margin: 0 auto;
}
.cuenta__logos { display: flex; justify-content: space-between; align-items: center; gap: 2rem; }
.cuenta__logos img:first-child { width: clamp(9rem, 28vw, 17rem); }
.cuenta__logos img:last-child { width: clamp(6rem, 17vw, 10rem); }

.cuenta__centro { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding-top: clamp(2rem, 6vh, 4rem); }
.cuenta__intro { font-size: clamp(1.15rem, 2.4vw, 1.6rem); font-weight: 600; margin-bottom: 1.25rem; }
.cuenta__marca img { width: clamp(11rem, 30vw, 16rem); }

.reloj {
  display: grid; grid-template-columns: repeat(4, auto);
  gap: 0 clamp(1rem, 4vw, 3.25rem);
  margin: clamp(2rem, 6vh, 3.5rem) 0 clamp(1.5rem, 4vh, 2.5rem);
}
.reloj__u { display: flex; flex-direction: column; align-items: center; position: relative; }
.reloj__u + .reloj__u::before {
  content: ""; position: absolute; left: calc(clamp(1rem, 4vw, 3.25rem) / -2); top: 18%; bottom: 38%;
  width: 1px; background: linear-gradient(var(--oro), transparent);
}
.reloj__n {
  font-size: clamp(2.8rem, 10.5vw, 6.75rem);
  font-weight: 300; line-height: 1; letter-spacing: -.01em;
  font-variant-numeric: tabular-nums lining-nums;
  font-variation-settings: "opsz" 60;
  color: var(--tinta);
}
.reloj__u:first-child .reloj__n { color: var(--guinda); }
.reloj.sin-dias { grid-template-columns: repeat(3, auto); }
.reloj.sin-dias .reloj__n { font-size: clamp(3.6rem, 15vw, 7.5rem); }
.reloj.sin-dias .reloj__u:first-child { display: none; }
.reloj.sin-dias .reloj__u:nth-child(2)::before { display: none; }
.reloj.sin-dias .reloj__u:nth-child(2) .reloj__n { color: var(--guinda); }
.reloj__l { margin-top: .6rem; font-size: clamp(.85rem, 1.6vw, 1rem); color: var(--gris); font-style: italic; }

.cuenta__fecha { font-size: clamp(1rem, 2vw, 1.25rem); line-height: 1.6; margin-bottom: .75rem; }
.cuenta__fecha strong { font-weight: 600; }
.cuenta__nota { font-size: .95rem; color: var(--gris); margin: 0; }
.es-hora .reloj__n { color: var(--verde); transition: color .6s; }

/* ── Sitio ─────────────────────────────────────────────────────────────── */
.barra {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
  padding: .6rem var(--margen);
  padding-top: calc(.6rem + env(safe-area-inset-top, 0px));
  background: rgba(245, 246, 247, .86);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--perla-3);
}
.barra__marca { display: flex; align-items: center; gap: 1rem; text-decoration: none; flex: none; }
.barra__marca img { height: 2.6rem; width: auto; }
.barra__marca .barra__uat { height: 2.25rem; }
.barra__divisor { width: 1px; align-self: stretch; margin: .2rem 0; background: var(--perla-3); }
.barra__nav { display: flex; gap: clamp(.9rem, 2.2vw, 1.8rem); }
.barra__nav a { color: var(--tinta); text-decoration: none; font-size: 1rem; white-space: nowrap; padding: .35rem 0; border-bottom: 1px solid transparent; }
.barra__nav a:hover { color: var(--guinda); border-bottom-color: var(--oro); }
.barra__boton { display: none; }

@media (max-width: 60rem) {
  .barra { padding-top: calc(.55rem + env(safe-area-inset-top, 0px)); padding-bottom: .55rem; }
  .barra__marca { gap: .75rem; }
  .barra__marca img { height: 2.15rem; }
  .barra__marca .barra__uat { height: 1.8rem; }

  .barra__boton {
    display: grid; place-content: center; gap: 5px;
    width: 2.75rem; height: 2.75rem; margin-right: -.5rem;
    background: none; border: 0; padding: 0; cursor: pointer; color: var(--tinta);
  }
  .barra__boton span {
    display: block; width: 1.5rem; height: 2px; border-radius: 1px; background: currentColor;
    transition: transform .25s, opacity .2s;
  }
  .abierta .barra__boton span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .abierta .barra__boton span:nth-child(2) { opacity: 0; }
  .abierta .barra__boton span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  /* Sin JavaScript el menú queda visible como fila desplazable. */
  .barra__nav { overflow-x: auto; scrollbar-width: none; }
  .barra__nav::-webkit-scrollbar { display: none; }
  .js .barra__nav {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0; overflow: visible;
    background: var(--perla); border-bottom: 1px solid var(--perla-3);
    box-shadow: 0 18px 30px -18px rgba(43, 40, 38, .35);
    padding: .25rem 0 calc(.75rem + env(safe-area-inset-bottom, 0px));
    opacity: 0; visibility: hidden; transform: translateY(-.5rem);
    transition: opacity .2s, transform .2s, visibility 0s .2s;
  }
  .js .abierta .barra__nav { opacity: 1; visibility: visible; transform: none; transition: opacity .2s, transform .2s, visibility 0s; }
  .js .barra__nav a {
    font-size: 1.25rem; padding: .85rem var(--margen);
    border-bottom: 1px solid var(--perla-2);
  }
  .js .barra__nav a:last-child { border-bottom: 0; }
  .js .barra__nav a:hover { border-bottom-color: var(--perla-2); background: var(--blanco); }
}
@media (max-width: 60rem) and (prefers-reduced-motion: reduce) {
  .barra__boton span, .js .barra__nav, .js .abierta .barra__nav { transition: none; }
}
@media (max-width: 26rem) {
  .barra__marca { gap: .6rem; }
  .barra__marca .barra__uat { height: 1.55rem; }
  .barra__marca img { height: 1.9rem; }
}

.portada {
  position: relative; overflow: hidden;
  min-height: calc(100svh - 4.5rem);
  display: grid; place-items: center;
  padding: clamp(3rem, 8vh, 6rem) var(--margen) clamp(10rem, 26vh, 16rem);
  text-align: center;
  background:
    radial-gradient(ellipse 70% 60% at 60% 25%, var(--blanco) 0%, rgba(255,255,255,0) 70%),
    linear-gradient(180deg, var(--perla) 0%, var(--perla-2) 100%);
}
.portada__cuerpo { position: relative; z-index: 1; max-width: 46rem; }
.portada__marca { width: clamp(12rem, 34vw, 19rem); margin: 0 auto clamp(2rem, 5vh, 3rem); }
.portada__titulo { font-size: clamp(2rem, 5vw, 3.6rem); font-weight: 400; letter-spacing: -.012em; font-variation-settings: "opsz" 60; }
.portada__fechas { margin: 1.5rem 0 0; color: var(--gris); font-style: italic; font-size: 1.15rem; }

.seccion { padding: clamp(4rem, 10vw, 7rem) var(--margen); }
.seccion--perla { background: var(--perla-2); }
.seccion--verde { background: var(--verde); color: var(--perla); }
.seccion--verde a { color: var(--oro); }
.columna { max-width: var(--medida); margin: 0 auto clamp(2.5rem, 6vw, 4rem); }
.columna > p:last-child { margin-bottom: 0; }
.columna--media { max-width: 50rem; }
.columna--ancha { max-width: var(--ancho); }
.columna--media > p, .columna--ancha > p { max-width: var(--medida); }
.seccion h2 {
  font-size: clamp(2.2rem, 5vw, 3.25rem); letter-spacing: -.01em;
  font-variation-settings: "opsz" 60;
  margin-bottom: 1.5rem; padding-bottom: 1.1rem;
  background: no-repeat left bottom / 5.5rem 10px
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 88 10'%3E%3Cpath d='M1 2 C 25 10 60 10 87 4' fill='none' stroke='%23e2b44e' stroke-width='1.6'/%3E%3C/svg%3E");
}
.entrada { font-size: clamp(1.25rem, 2.3vw, 1.45rem); line-height: 1.55; }
.aviso {
  display: flex; gap: .75rem; align-items: baseline;
  font-style: italic; color: var(--gris);
}
.aviso::before {
  content: ""; flex: none; width: .55rem; height: .55rem; border-radius: 50%;
  background: var(--ocre); transform: translateY(-.1rem);
}

/* Línea del tiempo */
.linea { list-style: none; margin: 0 auto; padding: 0; max-width: 50rem; }
@media (min-width: 64rem) {
  .linea { max-width: var(--medida); }
  .linea__hito { margin-left: -9.5rem; }
}
.linea__hito {
  display: grid; grid-template-columns: 6.5rem 1fr; gap: 0 2rem;
  position: relative; padding-bottom: 2rem;
}
.linea__hito::before {
  content: ""; position: absolute; left: 7.5rem; top: .9rem; bottom: -.9rem;
  width: 1px; background: var(--oro);
}
.linea__hito:last-child::before { display: none; }
.linea__hito::after {
  content: ""; position: absolute; left: calc(7.5rem - 4px); top: .7rem;
  width: 9px; height: 9px; border-radius: 50%; background: var(--perla); border: 1.5px solid var(--ocre);
}
.linea__anio {
  font-size: 1.9rem; line-height: 1.15; color: var(--guinda);
  font-variant-numeric: lining-nums; text-align: right;
  font-variation-settings: "opsz" 48;
}
.linea__texto { margin: .35rem 0 0 1rem; max-width: var(--medida); }
.linea__hito:last-child .linea__anio { color: var(--verde); font-weight: 600; }
@media (max-width: 34rem) {
  .linea__hito { grid-template-columns: 1fr; padding-left: 1.75rem; }
  .linea__hito::before { left: .25rem; }
  .linea__hito::after { left: calc(.25rem - 4px); }
  .linea__anio { text-align: left; font-size: 1.6rem; }
  .linea__texto { margin-left: 0; }
}

/* Directores */
.directores {
  list-style: none; padding: 0; margin: 0 auto; max-width: 50rem;
  columns: 2 22rem; column-gap: 3rem;
}
.directores li {
  break-inside: avoid;
  display: grid; grid-template-columns: 2rem 1fr; gap: 0 .75rem;
  padding: .85rem 0; border-top: 1px solid var(--perla-3);
}
.directores__num { grid-row: span 2; color: var(--ocre); font-variant-numeric: tabular-nums; }
.directores__nombre { line-height: 1.35; }
.directores__periodo { color: var(--gris); font-style: italic; font-size: .95rem; }

/* Medios */
.marco { position: relative; width: 100%; background: rgba(0,0,0,.08); }
.marco iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.marco--16x9 { aspect-ratio: 16 / 9; }
.marco--9x16 { aspect-ratio: 9 / 16; }

.videos { max-width: var(--ancho); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 2rem; }
.video { margin: 0; }
.video--principal { grid-column: 1 / -1; }
.video figcaption { margin-top: .75rem; font-style: italic; opacity: .85; }

.reels { max-width: var(--ancho); margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 18rem)); justify-content: center; gap: 1.5rem; }
.reel { margin: 0; }
.reels .marco { border-radius: 6px; overflow: hidden; }
.reel figcaption { margin-top: .6rem; font-size: .95rem; text-align: center; }
.reel__tarjeta {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.25rem;
  background: radial-gradient(ellipse at 50% 30%, #0a5c4b, var(--verde) 55%, var(--verde-hondo));
  color: var(--perla); text-decoration: none;
}
.reel__tarjeta:hover { color: var(--blanco); }
.reel__play {
  width: 4.5rem; height: 4.5rem; border-radius: 50%; border: 1.5px solid var(--oro);
  display: grid; place-items: center; transition: transform .2s, background-color .2s;
}
.reel__play::after {
  content: ""; margin-left: .3rem;
  border-style: solid; border-width: .7rem 0 .7rem 1.15rem;
  border-color: transparent transparent transparent var(--oro);
}
.reel__tarjeta:hover .reel__play { transform: scale(1.06); background-color: rgba(226, 180, 78, .12); }
.reel__texto { font-size: 1.05rem; }
@media (prefers-reduced-motion: reduce) { .reel__play { transition: none; } }

.podcast { max-width: 50rem; margin: 0 auto; display: grid; gap: 1rem; }
.podcast iframe { width: 100%; border: 0; border-radius: 12px; }

.pendiente {
  max-width: var(--medida); margin: 0 auto; padding: 1.5rem 0 0;
  border-top: 1px solid var(--oro); font-style: italic; color: var(--gris);
}
.seccion--verde .pendiente { color: var(--perla-3); }

/* Identidad */
.ficha {
  max-width: var(--ancho); margin: 0 auto;
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
  padding: clamp(2.5rem, 6vw, 4.5rem) 0;
  border-top: 1px solid var(--perla-3);
}
.ficha:last-child { padding-bottom: 0; }
.ficha__lamina {
  position: sticky; top: 6rem;
  aspect-ratio: 1 / 1; display: grid; place-items: center; padding: clamp(2rem, 6vw, 4rem);
  background: radial-gradient(ellipse at 50% 35%, var(--blanco), var(--perla-2));
  border: 1px solid var(--perla-3);
}
.ficha__lamina img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; padding: clamp(2rem, 6vw, 4rem) clamp(1.5rem, 4vw, 2.75rem);
}
.ficha__vacio { color: var(--gris); font-style: italic; }
.ficha__texto { max-width: var(--medida); }
.ficha__texto h3 { font-size: clamp(1.8rem, 3.4vw, 2.4rem); font-variation-settings: "opsz" 48; }
.ficha__dato { margin: .35rem 0 1.5rem; color: var(--gris); font-style: italic; font-size: 1rem; }
.ficha__frase {
  font-size: clamp(1.35rem, 2.6vw, 1.7rem); line-height: 1.35; font-style: italic; font-weight: 400;
  color: var(--verde); margin-bottom: 1.5rem; text-wrap: balance;
}

.colores { list-style: none; padding: 0; margin: 1.75rem 0; display: grid; gap: .9rem; }
.colores li { display: grid; grid-template-columns: 2.75rem 1fr; column-gap: 1rem; align-items: baseline; }
.colores__muestra { grid-row: span 3; width: 2.75rem; height: 2.75rem; align-self: start; margin-top: .3rem; }
.colores__nombre { font-weight: 600; line-height: 1.3; }
.colores__ref { font-size: .9rem; color: var(--gris); font-variant-numeric: tabular-nums; }
.colores__valor { font-size: .98rem; }

.ficha__mas { margin: 1.75rem 0 1.25rem; border-top: 1px solid var(--oro); }
.ficha__mas summary {
  cursor: pointer; list-style: none; padding: 1rem 0; color: var(--verde);
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
}
.ficha__mas summary::-webkit-details-marker { display: none; }
.ficha__mas summary::after {
  content: ""; width: .6rem; height: .6rem; flex: none;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-3px); transition: transform .25s;
}
.ficha__mas[open] summary::after { transform: rotate(-135deg) translateY(-3px); }
.ficha__mas summary:hover { color: var(--guinda); }
@media (prefers-reduced-motion: reduce) { .ficha__mas summary::after { transition: none; } }

.ficha__secciones { margin: .5rem 0 0; padding: 0; list-style: none; counter-reset: sec; }
.ficha__secciones li { counter-increment: sec; position: relative; padding-left: 2.25rem; margin-bottom: 1.5rem; }
.ficha__secciones li::before {
  content: counter(sec); position: absolute; left: 0; top: .05rem;
  color: var(--ocre); font-size: 1.15rem; font-variant-numeric: lining-nums;
}
.ficha__secciones h4 { margin: 0 0 .4rem; font-size: 1.12rem; font-weight: 600; line-height: 1.35; }
.ficha__secciones p { margin: 0; font-size: 1.02rem; }
.ficha__credito { font-size: .92rem; color: var(--gris); margin: 0; }

@media (max-width: 52rem) {
  .ficha { grid-template-columns: 1fr; }
  .ficha__lamina { position: relative; top: auto; aspect-ratio: 4 / 3; max-width: 30rem; }
}

/* Pie */
.pie { padding: 4rem var(--margen) calc(3rem + env(safe-area-inset-bottom, 0px)); background: var(--perla-3); text-align: center; font-size: 1rem; color: var(--gris); }
.pie__logos { display: flex; justify-content: center; align-items: center; gap: 2.5rem; flex-wrap: wrap; margin-bottom: 2rem; }
.pie__logos img:first-child { width: 12rem; }
.pie__logos img:last-child { width: 7.5rem; }
.pie__visitas {
  display: inline-flex; align-items: center; gap: .5rem;
  margin: 1.25rem 0 0; font-size: .85rem; font-style: italic;
  font-variant-numeric: tabular-nums lining-nums; opacity: .8;
}
.pie__visitas::before { content: ""; width: .35rem; height: .35rem; border-radius: 50%; background: var(--ocre); }
@media (max-width: 40rem) { .arcos { height: 20vh; } }
