/* admcrece — pantalla de inicio (admcrece.com). Clara y sobria, como la anterior:
   tres palabras, botones de ingreso y, en lugar de la foto, el logo animado.
   Paleta "Grafito y acero" de la intranet, apenas más viva en los brillos. */

:root {
  --ink: oklch(0.2 0.012 215);
  --ink-soft: oklch(0.42 0.016 215);
  --line: oklch(0.88 0.008 215);
  --steel: oklch(0.6 0.095 208);
  --steel-deep: oklch(0.45 0.075 208);
  --sky: oklch(0.68 0.12 246);
  --mint: oklch(0.82 0.1 185);
  --g1: oklch(0.24 0.014 215);   /* barras: grafito abajo a la izquierda… */
  --g2: oklch(0.47 0.06 208);
  --g3: oklch(0.66 0.11 220);    /* …hasta acero celeste arriba a la derecha */
  --footer-h: 40px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: 'Instrument Sans', ui-sans-serif, system-ui, sans-serif;
  color: var(--ink);
  background: #fff;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: #fff; padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }
:focus-visible { outline: 2px solid var(--steel); outline-offset: 3px; border-radius: 6px; }

/* Luz muy suave que sigue al mouse. */
.l-spot {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(520px circle at var(--mx, 70%) var(--my, 45%), oklch(0.82 0.06 205 / .16), transparent 65%);
  transition: opacity .6s;
}

/* ---------- Arriba: nombre y menú ---------- */
.l-top {
  position: fixed; inset: 0 0 auto; z-index: 15;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px clamp(16px, 3vw, 32px);
}
/* Logo chico fijo + nombre, como antes: aparecen juntos. */
.l-brand {
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink);
  opacity: 0; transform: translateY(-8px); animation: fadeUp .9s var(--ease) 1.9s forwards;
}
.l-mark { height: 36px; width: auto; display: block; }
.wordmark { font-size: 1.45rem; letter-spacing: -.02em; line-height: 1; }
.wordmark .adm { font-weight: 400; color: var(--ink-soft); }
.wordmark b { font-weight: 700; }

.l-menu { position: relative; opacity: 0; animation: fadeUp .8s var(--ease) 2.2s forwards; }
.l-menu summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px 8px 16px; border-radius: 999px;
  font-size: .9rem; color: var(--ink-soft);
  background: oklch(1 0 0 / .8); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  box-shadow: inset 0 0 0 1px var(--line);
  transition: box-shadow .3s, color .3s;
}
.l-menu summary::-webkit-details-marker { display: none; }
.l-menu summary:hover, .l-menu[open] summary { color: var(--ink); box-shadow: inset 0 0 0 1px oklch(0.78 0.05 205), 0 6px 20px -10px oklch(0.6 0.095 208 / .5); }
.l-menu-cta { font-weight: 600; color: var(--ink); }
.l-menu svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .35s var(--ease); }
.l-menu[open] svg { transform: rotate(180deg); }
.l-menu-panel {
  position: absolute; right: 0; top: calc(100% + 8px); width: min(330px, calc(100vw - 32px));
  padding: 8px; border-radius: 18px; background: #fff;
  box-shadow: inset 0 0 0 1px var(--line), 0 24px 50px -20px oklch(0.2 0.02 215 / .3);
  display: grid; gap: 2px;
  animation: menuIn .3s var(--ease);
}
.l-menu-panel a { display: grid; gap: 2px; padding: 12px 14px; border-radius: 12px; text-decoration: none; transition: background-color .2s; }
.l-menu-panel a:hover { background: oklch(0.965 0.012 205); }
.l-menu-panel b { font-weight: 600; }
.l-menu-panel span { font-size: .85rem; color: var(--ink-soft); }
@keyframes menuIn { from { opacity: 0; transform: translateY(-6px); } }

/* ---------- Página: texto | logo, dentro de un contenedor centrado ---------- */
:root { --box: 1240px; --gutter: clamp(24px, 5vw, 64px); }
.l-page {
  position: relative; z-index: 1;
  min-height: 100svh; padding-bottom: var(--footer-h);
  width: min(var(--box), 100%); margin-inline: auto; padding-inline: var(--gutter);
  display: grid; grid-template-columns: 1fr 1fr;
}
.l-left { display: flex; align-items: center; padding: 72px 0 24px; position: relative; z-index: 2; }
.l-wrap { width: 100%; max-width: 520px; }

.l-slogan { margin: 0 0 8px; font-weight: 400; line-height: 1.16; }
.l-slogan .w {
  display: block; width: fit-content;
  font-size: clamp(2.5rem, 4.8vw, 3.6rem); letter-spacing: -.02em;
  opacity: 0;
}
.l-slogan strong { font-weight: 700; }
/* Entran deslizándose y enfocándose, alternando el lado, mientras el logo se acomoda. */
.l-slogan .w:nth-child(2) { margin-left: .3rem; animation: wordL 1.2s cubic-bezier(.2, .8, .2, 1) .1s forwards; }
.l-slogan .w:nth-child(3) { margin-left: 1.6rem; animation: wordR 1.2s cubic-bezier(.2, .8, .2, 1) .55s forwards; }
.l-slogan .w:nth-child(4) { margin-left: .8rem; animation: wordL 1.2s cubic-bezier(.2, .8, .2, 1) 1s forwards; }
@keyframes wordL { from { opacity: 0; transform: translate(-36px, 6px); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes wordR { from { opacity: 0; transform: translate(36px, 6px); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
/* Un único reflejo que cruza "administración" cuando termina de entrar. */
.l-slogan strong {
  background: linear-gradient(100deg, var(--ink) 0 40%, var(--steel) 48%, var(--mint) 50%, var(--steel) 52%, var(--ink) 60% 100%);
  background-size: 260% 100%; background-position: 100% 0;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shine 1.8s var(--ease) 2.2s forwards;
}
@keyframes shine { to { background-position: 0 0; } }

.l-actions {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 460px; margin-top: 30px;
  opacity: 0; transform: translateY(12px); animation: fadeUp .9s var(--ease) 1.5s forwards;
}
.l-btn {
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  padding: .9rem 1.2rem; border-radius: 12px;
  font-weight: 600; font-size: 1.02rem; text-decoration: none;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), background-color .3s;
}
.l-btn-dark { color: #fff; background: var(--ink); box-shadow: 0 10px 24px -14px oklch(0.2 0.012 215 / .8); }
.l-btn-light { color: var(--ink); background: oklch(1 0 0 / .9); box-shadow: inset 0 0 0 1px var(--line); }
.l-btn:hover { transform: translateY(-2px); }
.l-btn-dark:hover { background: oklch(0.27 0.016 215); box-shadow: 0 16px 30px -14px oklch(0.2 0.012 215 / .8); }
.l-btn-light:hover { box-shadow: inset 0 0 0 1px oklch(0.8 0.02 210), 0 12px 26px -16px oklch(0.2 0.012 215 / .35); }

.l-aux { margin-top: 12px; padding-left: 4px; font-size: .95rem; opacity: 0; animation: fadeUp .8s var(--ease) 1.75s forwards; }
.l-aux a {
  color: var(--steel-deep); text-decoration: none;
  background: linear-gradient(currentColor 0 0) 0 100% / 0 1px no-repeat;
  transition: background-size .35s var(--ease);
}
.l-aux a:hover { background-size: 100% 1px; }

/* ---------- Logo animado: parte del fondo ---------- */
/* Grande, tenue y detrás de todo: se nota que se mueve, pero no compite con el texto. */
.l-art { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
/* El logo se ubica en la mitad derecha del mismo contenedor, centrado en alto. */
.l-art { --w: min(38vw, 560px); --right: max(var(--gutter), calc((100vw - var(--box)) / 2 + var(--gutter))); }
.l-halo {
  position: absolute; right: calc(var(--right) - var(--w) * .2); top: calc(50% - var(--w) * .7); width: calc(var(--w) * 1.4); aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(closest-side, oklch(0.9 0.05 200 / .45), oklch(0.93 0.035 240 / .2) 60%, transparent);
  filter: blur(40px);
  translate: var(--hx, 0) var(--hy, 0);
  transition: translate 1.2s var(--ease);
  opacity: 0; animation: fadeIn 2.4s var(--ease) 1.6s forwards, halo 10s ease-in-out 4s infinite;
}
@keyframes halo { 50% { scale: 1.06; opacity: .75; } }
.l-logo {
  position: absolute; right: var(--right); top: calc(50% - var(--w) * .48 - var(--footer-h) / 2);
  width: var(--w); height: auto; overflow: visible;
  opacity: .13;
  transform-origin: 50% 50%;
  animation: zoomIn 3.6s cubic-bezier(.65, 0, .25, 1) .15s both;
}
/* Entrada: arranca enorme y desenfocado (sólo se ven franjas) y se achica hasta su lugar. */
@keyframes zoomIn {
  from { transform: scale(12); opacity: 0; filter: blur(14px); }
  12% { opacity: .1; }
  80% { filter: blur(0); }
}
.l-logo path {
  transform-box: fill-box; transform-origin: 50% 100%;
  animation: breathe 8s ease-in-out infinite;
  animation-delay: calc(var(--i) * .5s + 4s);
}
@keyframes breathe { 50% { transform: scaleY(.96); } }
@keyframes zoomInM {
  from { transform: scale(2.6); opacity: 0; filter: blur(8px); }
  25% { opacity: .1; }
  60% { filter: blur(0); }
}

/* ---------- Pie (igual al anterior, con el año al día) ---------- */
.l-footer {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; height: var(--footer-h);
  display: flex; align-items: center; justify-content: center;
  padding: 0 12px; background: #000; color: #fff;
  font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  opacity: 0; animation: fadeUp .8s var(--ease) 2s forwards;
}
.l-footer a { color: #9cc3ff; text-decoration: none; }
.l-footer a:hover { text-decoration: underline; }

@keyframes fadeUp { to { opacity: 1; transform: none; } }
@keyframes fadeIn { to { opacity: 1; } }

/* ---------- Celular ---------- */
@media (max-width: 992px) {
  .l-top { padding: 14px 16px; }
  .wordmark { font-size: 1.35rem; }
  .l-menu-q { display: none; }
  .l-menu summary { white-space: nowrap; }
  .l-menu summary { padding: 7px 8px 7px 14px; font-size: .85rem; }

  .l-page { grid-template-columns: 1fr; padding-inline: 20px; }
  .l-left { justify-content: center; align-items: center; min-height: calc(100svh - var(--footer-h)); padding: 76px 0 40px; }
  .l-wrap { margin: 0 auto; width: min(100%, 400px); }
  .l-slogan .w:nth-child(2) { margin-left: 0; }
  .l-slogan .w:nth-child(3) { margin-left: 1.1rem; }
  .l-slogan .w:nth-child(4) { margin-left: .5rem; }
  /* Cada elemento lleva su propio difuminado blanco para leerse sobre el logo en movimiento. */
  .l-slogan { filter: drop-shadow(0 0 10px #fff) drop-shadow(0 0 18px #fff); }
  .l-btn-dark { box-shadow: 0 10px 24px -14px oklch(0.2 0.012 215 / .8), 0 0 26px 10px oklch(1 0 0 / .9); }
  .l-btn-light { background: #fff; box-shadow: inset 0 0 0 1px var(--line), 0 0 26px 10px oklch(1 0 0 / .9); }
  .l-actions { grid-template-columns: 1fr; margin-top: 22px; }
  .l-aux { padding-left: 2px; }
  .l-aux a { text-shadow: 0 0 6px #fff, 0 0 12px #fff, 0 0 20px #fff, 0 0 28px #fff; }

  /* Logo de fondo atado abajo a la derecha, sobre el pie. */
  .l-art { --w: 118vw; }
  .l-logo {
    right: -30vw; top: auto; bottom: calc(var(--footer-h) - 4vh); opacity: .11;
    /* En el celular el zoom es más corto y arranca menos grande: el logo se ve desde el primer momento. */
    animation: zoomInM 2.4s cubic-bezier(.25, .8, .25, 1) both;
  }
  .l-halo { width: 120vw; right: -40vw; top: auto; bottom: 0; animation-delay: .3s, 3s; }
  .l-footer { font-size: .78rem; }
}
@media (max-width: 400px) {
  .l-menu-long { display: none; }
  .wordmark { font-size: 1.25rem; }
  .l-mark { height: 30px; }
}
@media (max-height: 640px) and (max-width: 992px) {
  .l-art { --w: 60vw; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .l-brand, .l-menu, .l-slogan .w, .l-actions, .l-aux, .l-footer, .l-halo { opacity: 1; transform: none; filter: none; }
  .l-slogan strong { background: none; color: var(--ink); }
}
