@font-face { font-family: "Figtree"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("fonts/figtree-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 400 800; font-display: swap; src: url("fonts/figtree-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 400 500; font-display: swap; src: url("fonts/jetbrains-mono-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --fondo: #1B222D;
  --popup: #232C39;
  --texto: #EAF0F4;
  --suave: #AAB6C2;
  --menta: #7DE2B4;
  --menta-fuerte: #9AEBC6;
  --sobre-menta: #10231A;
  --linea: rgb(255 255 255 / .16);
  --campo: rgb(255 255 255 / .42);
  --error: #FFB4A8;
  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --suave-ease: cubic-bezier(.22, 1, .36, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; min-height: 100dvh; background: var(--fondo); color: var(--texto); font: 400 1rem/1.5 var(--sans); }
::selection { background: var(--menta); color: var(--sobre-menta); }

.inicio { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: clamp(24px, 6vw, 64px); gap: 0; }
.marca { margin: 0 0 clamp(28px, 6vh, 56px); font: 400 clamp(1.05rem, 2.4vw, 1.3rem)/1 var(--mono); letter-spacing: .01em; }
.prompt { color: var(--menta); font-weight: 500; }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.falta { visibility: hidden; }
.cursor { color: var(--menta); font-weight: 500; animation: parpadeo 1.06s steps(1, end) infinite; }
.escribiendo .cursor { animation: none; }
@keyframes parpadeo { 50% { opacity: 0; } }
h1 { margin: 0; max-width: 15ch; font: 800 clamp(2.4rem, 7.2vw, 4.2rem)/1.06 var(--sans); letter-spacing: -.02em; text-wrap: balance; }
.desc { margin: clamp(16px, 2.6vh, 24px) 0 clamp(28px, 5vh, 44px); max-width: 32ch; color: var(--suave); font-size: clamp(1.05rem, 2.6vw, 1.3rem); line-height: 1.45; text-wrap: balance; }

.enlace { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 4px 2px; background: none; border: 0; color: var(--menta); font: 600 clamp(1.05rem, 2.4vw, 1.25rem)/1.2 var(--sans); cursor: pointer; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 8px; transition: color .2s, text-underline-offset .25s var(--suave-ease); }
.enlace:hover { color: var(--menta-fuerte); text-underline-offset: 11px; }
.flecha { transition: transform .25s var(--suave-ease); }
.enlace:hover .flecha { transform: translate(2px, -2px); }
:focus-visible { outline: 3px solid var(--menta); outline-offset: 4px; border-radius: 4px; }

.popup { position: fixed; inset: 0; margin: auto; width: min(420px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 28px 28px 26px; background: var(--popup); color: var(--texto); border: 1px solid var(--linea); border-radius: 14px; box-shadow: 0 24px 60px rgb(0 0 0 / .5); overscroll-behavior: contain; }
.popup[open] { animation: entra .28s var(--suave-ease); }
.popup::backdrop { background: rgb(10 14 20 / .74); }
.popup[open]::backdrop { animation: velo .25s ease-out; }
@keyframes entra { from { opacity: 0; transform: translateY(10px) scale(.985); } }
@keyframes velo { from { opacity: 0; } }

.popup h2 { margin: 0 44px 20px 0; font: 700 1.5rem/1.2 var(--sans); letter-spacing: -.01em; }
.cerrar { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; display: grid; place-items: center; background: none; border: 0; border-radius: 10px; color: var(--texto); cursor: pointer; transition: background .15s; }
.cerrar:hover { background: rgb(255 255 255 / .09); }

.campo { margin-bottom: 18px; }
label { display: block; margin-bottom: 7px; font: 600 .95rem/1.3 var(--sans); }
select, input, textarea { width: 100%; padding: 12px 14px; background: var(--fondo); color: var(--texto); border: 1px solid var(--campo); border-radius: 10px; font: 400 1rem/1.4 var(--sans); }
textarea { resize: vertical; min-height: 5.5em; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--menta); outline-offset: 2px; border-color: transparent; }
.select { position: relative; }
.select select { appearance: none; -webkit-appearance: none; padding-right: 44px; cursor: pointer; }
.select svg { position: absolute; right: 14px; top: 50%; translate: 0 -50%; pointer-events: none; }
select:invalid { color: var(--suave); }
select option { color: var(--texto); background: var(--popup); }
[aria-invalid="true"] { border-color: var(--error); }
.error { margin: 7px 0 0; color: var(--error); font-size: .9rem; line-height: 1.35; }
.error[hidden], .listo[hidden], form[hidden] { display: none; }
.aviso { margin: 0 0 14px; padding: 10px 12px; border: 1px solid var(--error); border-radius: 10px; }

.enviar { width: 100%; min-height: 50px; padding: 12px 16px; background: var(--menta); color: var(--sobre-menta); border: 0; border-radius: 10px; font: 700 1.05rem/1.2 var(--sans); cursor: pointer; transition: background .15s, opacity .15s; }
.enviar:hover { background: var(--menta-fuerte); }
.enviar:focus-visible { outline-color: var(--texto); }
.enviar:disabled { opacity: .65; cursor: progress; }
.listo { margin: 4px 0 6px; padding: 18px 16px; background: rgb(125 226 180 / .1); border: 1px solid rgb(125 226 180 / .4); border-radius: 10px; color: var(--texto); font-weight: 600; text-wrap: balance; }

@media (max-width: 480px) {
  .popup { padding: 24px 20px 22px; }
  .popup h2 { font-size: 1.35rem; }
  .inicio { padding-bottom: 12vh; }
}
@media (max-height: 560px) { .marca { margin-bottom: 20px; } .inicio { padding-block: 24px; } }
@media (prefers-reduced-motion: reduce) {
  .popup[open], .popup[open]::backdrop { animation: none; }
  .enlace, .flecha { transition: none; }
  .cursor { animation-iteration-count: 6; }
}
