/* Icewall landing · "ICE" sobrio: tinta oscura + acento hielo. Mobile-first. */

:root {
  --bg: #070b10;
  --bg-2: #0b1219;
  --surface: #0e1720;
  --surface-2: #121e29;
  --line: #1c2a38;
  --line-strong: #2a3d50;
  --text: #e8eff5;
  --muted: #9aabbb;
  --ice: #7fe3f0;
  --ice-strong: #43cfe0;
  --ice-ink: #03181c;          /* texto sobre botón hielo */
  --ice-glow: rgba(127, 227, 240, .16);
  --danger: #ff8f8f;
  --ok: #8cf0b8;
  --grid: rgba(127, 227, 240, .07);
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, .7);

  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "IBM Plex Sans", "Segoe UI", sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, monospace;

  --r: 10px;
  --r-lg: 16px;
  --gutter: 16px;
  --maxw: 1120px;
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f3f6f8;
    --bg-2: #e9eff3;
    --surface: #ffffff;
    --surface-2: #f6f9fb;
    --line: #d5dfe6;
    --line-strong: #b5c4cf;
    --text: #0a141d;
    --muted: #46576a;
    --ice: #006b78;
    --ice-strong: #00525c;
    --ice-ink: #ffffff;
    --ice-glow: rgba(0, 107, 120, .1);
    --danger: #b3261e;
    --ok: #146c43;
    --grid: rgba(0, 82, 92, .07);
    --shadow: 0 24px 50px -28px rgba(10, 30, 45, .35);
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #f3f6f8; --bg-2: #e9eff3; --surface: #ffffff; --surface-2: #f6f9fb;
  --line: #d5dfe6; --line-strong: #b5c4cf; --text: #0a141d; --muted: #46576a;
  --ice: #006b78; --ice-strong: #00525c; --ice-ink: #ffffff; --ice-glow: rgba(0, 107, 120, .1);
  --danger: #b3261e; --ok: #146c43; --grid: rgba(0, 82, 92, .07);
  --shadow: 0 24px 50px -28px rgba(10, 30, 45, .35);
  color-scheme: light;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.6 var(--f-body);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--ice); text-underline-offset: 3px; }
a:hover { color: var(--ice-strong); }
h1, h2, h3 { margin: 0; font-family: var(--f-display); font-stretch: 112%; line-height: 1.1; letter-spacing: -.01em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--ice); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--ice); color: var(--ice-ink); }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.wrap--narrow { max-width: 780px; }

.skip {
  position: absolute; left: var(--gutter); top: -60px; z-index: 100;
  background: var(--ice); color: var(--ice-ink); padding: 10px 14px; border-radius: var(--r);
  font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; }

/* ---------- topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-family: var(--f-display); font-weight: 800; font-stretch: 125%; letter-spacing: .04em; text-transform: uppercase; font-size: .95rem; }
.brand:hover { color: var(--text); }
.brand__mark { width: 22px; height: 22px; fill: var(--ice); }
.topbar__nav { display: none; list-style: none; gap: 28px; }
.topbar__nav a { color: var(--muted); text-decoration: none; font-size: .92rem; }
.topbar__nav a:hover { color: var(--text); }
@media (min-width: 760px) { .topbar__nav { display: flex; } }

/* ---------- buttons ---------- */
.btn {
  --h: 52px;
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: var(--h); padding: 0 22px; border-radius: var(--r);
  font: 600 1rem/1 var(--f-body); text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: background .2s, color .2s, border-color .2s, transform .15s, box-shadow .2s;
}
.btn:active { transform: translateY(1px); }
.btn--sm { --h: 38px; padding: 0 14px; font-size: .88rem; }
.btn--primary { background: var(--ice); color: var(--ice-ink); box-shadow: 0 0 0 0 var(--ice-glow); }
.btn--primary:hover { background: var(--ice-strong); color: var(--ice-ink); box-shadow: 0 0 0 6px var(--ice-glow); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn--ghost:hover { color: var(--text); border-color: var(--ice); background: var(--ice-glow); }
.btn[disabled], .btn[aria-busy="true"] { cursor: progress; opacity: .85; }
.spinner { display: none; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
.btn[aria-busy="true"] .spinner { display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- hero ---------- */
.hero { position: relative; padding: 56px 0 64px; overflow: hidden; isolation: isolate; border-bottom: 1px solid var(--line); }
.hero__grid {
  position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 70% at 70% 20%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 70% 20%, #000 20%, transparent 75%);
}
.hero__grid::after {
  /* línea de barrido: el "muro" escaneando */
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 120px;
  background: linear-gradient(180deg, transparent, var(--ice-glow), transparent);
  animation: sweep 7s cubic-bezier(.5, 0, .5, 1) infinite;
}
@keyframes sweep { 0% { transform: translateY(-140px); } 100% { transform: translateY(820px); } }

.eyebrow { display: inline-flex; align-items: center; gap: 10px; font: 500 .78rem/1.3 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 20px; }
.pulse { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--ice); box-shadow: 0 0 0 0 var(--ice); animation: pulse 2.4s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 var(--ice-glow); } 70% { box-shadow: 0 0 0 10px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

.hero__title { font-size: clamp(2.1rem, 8.4vw, 4.4rem); font-weight: 800; font-stretch: 112%; max-width: 16ch; letter-spacing: -.02em; }
.hero__title .ice { display: block; color: var(--ice); font-weight: 700; font-size: .62em; margin-top: .35em; max-width: 26ch; letter-spacing: -.01em; }
.hero__sub { margin-top: 20px; font-size: clamp(1.05rem, 2.6vw, 1.2rem); color: var(--muted); max-width: 52ch; }

.reveal { opacity: 0; transform: translateY(14px); animation: rise .7s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- forms ---------- */
.diag {
  margin-top: 32px; max-width: 780px; padding: 16px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  border: 1px solid var(--line-strong); border-radius: var(--r-lg);
  box-shadow: var(--shadow);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.diag__fields { display: grid; gap: 12px; }
@media (min-width: 760px) { .diag__fields { grid-template-columns: 1.1fr 1fr auto; align-items: end; } }
.field { display: grid; gap: 6px; min-width: 0; }
.field label { font: 500 .78rem/1.2 var(--f-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.field input {
  width: 100%; min-height: 52px; padding: 0 14px; border-radius: var(--r);
  background: var(--bg); color: var(--text); border: 1px solid var(--line-strong);
  font: 400 1rem/1.2 var(--f-body);
  transition: border-color .2s, box-shadow .2s;
}
.field input::placeholder { color: color-mix(in srgb, var(--muted) 75%, transparent); }
.field input:focus { outline: none; border-color: var(--ice); box-shadow: 0 0 0 4px var(--ice-glow); }
.field input[aria-invalid="true"] { border-color: var(--danger); }
.field__err { color: var(--danger); font-size: .86rem; }
.diag__submit { width: 100%; }
@media (min-width: 760px) { .diag__submit { width: auto; } }
.diag__note { margin-top: 12px; font: 400 .82rem/1.4 var(--f-mono); color: var(--muted); }
.diag__status { margin-top: 8px; font-weight: 500; min-height: 0; }
.diag__status:empty { display: none; }
.diag__status[data-kind="ok"] { color: var(--ok); }
.diag__status[data-kind="error"] { color: var(--danger); }
.diag.is-done .diag__fields, .diag.is-done .diag__note, .diag.is-done .turnstile-slot { display: none; }
.diag.is-done .diag__status { margin: 0; font-size: 1.1rem; display: flex; gap: 10px; align-items: center; }
.diag.is-done .diag__status::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--ok); }
.turnstile-slot:empty { display: none; }
.turnstile-slot { margin-top: 12px; }
.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.hero__trust { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 24px; }
.hero__trust li { display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; color: var(--muted); }
.hero__trust li::before { content: ""; width: 14px; height: 14px; flex: none; background: var(--ice); mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 12l5 5L20 6' fill='none' stroke='%23000' stroke-width='3'/%3E%3C/svg%3E") center/contain no-repeat; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 12l5 5L20 6' fill='none' stroke='%23000' stroke-width='3'/%3E%3C/svg%3E") center/contain no-repeat; }

/* ---------- sections ---------- */
.section { padding: 72px 0; }
.section--alt { background: var(--bg-2); border-block: 1px solid var(--line); }
.kicker { font: 500 .78rem/1 var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--ice); margin-bottom: 14px; }
.section__title { font-size: clamp(1.6rem, 5vw, 2.6rem); font-weight: 700; max-width: 24ch; }
.section__lead { margin-top: 14px; color: var(--muted); font-size: 1.08rem; max-width: 60ch; }

/* stats */
.stats { list-style: none; display: grid; gap: 1px; margin-top: 40px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(3, 1fr); } }
.stat { background: var(--surface); padding: 28px 22px; position: relative; }
.stat::before { content: ""; position: absolute; left: 0; top: 0; width: 36px; height: 2px; background: var(--ice); }
.stat__num { font: 800 clamp(2.6rem, 9vw, 3.6rem)/1 var(--f-display); font-stretch: 125%; color: var(--text); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat__txt { margin-top: 14px; color: var(--muted); }
.ref { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; margin-left: 6px; padding: 0 4px; border: 1px solid var(--line-strong); border-radius: 6px; font: 500 .72rem/1 var(--f-mono); text-decoration: none; vertical-align: 2px; }
.ref:hover { border-color: var(--ice); }
.sources { margin-top: 20px; padding-left: 1.4em; font-size: .84rem; color: var(--muted); display: grid; gap: 6px; }
.sources li { overflow-wrap: anywhere; }
.sources li:target { color: var(--text); }

/* steps */
.steps { list-style: none; display: grid; gap: 16px; margin-top: 40px; counter-reset: s; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 0; } }
.step { position: relative; padding: 26px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
@media (min-width: 760px) {
  .step { border-radius: 0; border-right-width: 0; }
  .step:first-child { border-radius: var(--r-lg) 0 0 var(--r-lg); }
  .step:last-child { border-radius: 0 var(--r-lg) var(--r-lg) 0; border-right-width: 1px; }
  .step:not(:last-child)::after {
    content: ""; position: absolute; right: -9px; top: 34px; z-index: 1; width: 16px; height: 16px;
    background: var(--bg-2); border: 1px solid var(--line-strong); border-left: 0; border-bottom: 0; transform: rotate(45deg);
  }
}
.step__n { font: 500 .8rem/1 var(--f-mono); color: var(--ice); letter-spacing: .08em; }
.step__title { margin: 14px 0 10px; font-size: 1.45rem; font-weight: 700; }
.step p { color: var(--muted); }

/* compat */
.compat { display: grid; gap: 32px; }
@media (min-width: 900px) { .compat { grid-template-columns: 1fr 1.2fr; align-items: center; } }
.chips { list-style: none; display: grid; gap: 12px; }
.chip { display: grid; gap: 4px; padding: 18px 20px; border: 1px solid var(--line); border-left: 3px solid var(--ice); border-radius: var(--r); background: var(--surface); }
.chip strong { font-family: var(--f-display); font-stretch: 112%; font-size: 1.12rem; }
.chip span { color: var(--muted); font-size: .95rem; }

/* plans */
.plans { display: grid; gap: 16px; margin-top: 40px; }
@media (min-width: 900px) { .plans { grid-template-columns: repeat(3, 1fr); align-items: stretch; } }
.plan { position: relative; display: flex; flex-direction: column; padding: 28px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); transition: border-color .25s, transform .25s; }
.plan:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.plan--featured { border-color: var(--ice); box-shadow: 0 0 0 1px var(--ice), 0 30px 70px -40px var(--ice); }
.plan--featured:hover { border-color: var(--ice); }
.plan__badge { position: absolute; top: -12px; left: 22px; padding: 4px 10px; border-radius: 999px; background: var(--ice); color: var(--ice-ink); font: 500 .72rem/1.2 var(--f-mono); letter-spacing: .06em; text-transform: uppercase; }
.plan__name { font-size: 1.6rem; font-weight: 800; font-stretch: 125%; }
.plan__tag { margin-top: 4px; color: var(--ice); font: 500 .82rem/1.3 var(--f-mono); letter-spacing: .04em; }
.plan__price { margin: 22px 0; font: 800 2.8rem/1 var(--f-display); font-stretch: 112%; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.plan__cur { font: 500 .9rem/1 var(--f-mono); color: var(--muted); vertical-align: .9em; letter-spacing: .04em; }
.plan__per { font: 400 1rem/1 var(--f-body); color: var(--muted); letter-spacing: 0; }
.plan__list { list-style: none; display: grid; gap: 10px; margin-bottom: 28px; flex: 1; }
.plan__list li { position: relative; padding-left: 22px; color: var(--muted); font-size: .96rem; }
.plan__list li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 8px; height: 8px; border: 1.5px solid var(--ice); transform: rotate(45deg); }
.plan__cta { width: 100%; }
.plans__note { margin-top: 20px; text-align: center; font: 400 .84rem/1.4 var(--f-mono); color: var(--muted); }

/* faq */
.faq { margin-top: 32px; border-top: 1px solid var(--line); }
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 4px; font: 600 1.08rem/1.35 var(--f-body);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: ""; flex: none; width: 12px; height: 12px; border-right: 2px solid var(--ice); border-bottom: 2px solid var(--ice);
  transform: rotate(45deg) translate(-3px, -3px); transition: transform .25s;
}
.faq__item[open] summary::after { transform: rotate(-135deg) translate(-3px, -3px); }
.faq__item summary:hover { color: var(--ice); }
.faq__body { padding: 0 4px 22px; color: var(--muted); max-width: 66ch; }

/* cta */
.section--cta { border-top: 1px solid var(--line); background: radial-gradient(ellipse 60% 80% at 50% 120%, var(--ice-glow), transparent 70%), var(--bg); }
.cta { display: grid; gap: 28px; justify-items: start; }
@media (min-width: 760px) { .cta { justify-items: center; text-align: center; } .cta .section__title { max-width: 22ch; } }

/* footer */
.footer { padding: 48px 0 40px; border-top: 1px solid var(--line); background: var(--bg-2); }
.footer__inner { display: grid; gap: 22px; }
@media (min-width: 900px) { .footer__inner { grid-template-columns: 1.1fr 1.4fr auto; align-items: start; } .footer__copy { grid-column: 1 / -1; } }
.footer__who { margin-top: 10px; color: var(--muted); font-size: .92rem; max-width: 40ch; }
.footer__legal { color: var(--muted); font-size: .92rem; max-width: 52ch; }
.footer__links { list-style: none; display: flex; flex-wrap: wrap; gap: 10px 20px; font-size: .92rem; }
.footer__links a { color: var(--text); overflow-wrap: anywhere; }
.footer__copy { font: 400 .8rem/1 var(--f-mono); color: var(--muted); }

/* ---------- modal ---------- */
.modal { position: fixed; inset: 0; z-index: 50; display: grid; place-items: end center; padding: var(--gutter); }
.modal[hidden] { display: none; }
@media (min-width: 600px) { .modal { place-items: center; } }
.modal__backdrop { position: absolute; inset: 0; background: rgba(2, 6, 10, .72); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: fade .2s ease-out; }
.modal__panel {
  position: relative; width: 100%; max-width: 460px; padding: 30px 22px 24px;
  background: var(--surface); border: 1px solid var(--line-strong); border-top: 2px solid var(--ice); border-radius: var(--r-lg);
  box-shadow: var(--shadow); animation: pop .28s cubic-bezier(.2, .8, .2, 1);
}
.modal__x { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; display: grid; place-items: center; background: none; border: 0; border-radius: var(--r); color: var(--muted); cursor: pointer; }
.modal__x:hover { color: var(--text); background: var(--ice-glow); }
.modal__x svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2; fill: none; }
.modal__title { font-size: 1.6rem; font-weight: 800; padding-right: 32px; }
.modal__desc { margin-top: 8px; color: var(--muted); }
.modal__form { display: grid; gap: 14px; margin-top: 22px; }
.modal__form.is-done .field, .modal__form.is-done .btn { display: none; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.98); } }
body.has-modal { overflow: hidden; }

/* ---------- motion prefs ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .hero__grid::after { display: none; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- páginas legales ---------- */
.legal { display: grid; gap: 14px; }
.legal h1 { font-size: clamp(1.8rem, 5vw, 2.6rem); font-weight: 800; }
.legal h2 { margin-top: 22px; font-size: 1.2rem; font-weight: 700; }
.legal p, .legal li { color: var(--muted); max-width: 66ch; }
.legal strong { color: var(--text); }
.legal ul { padding-left: 1.3em; display: grid; gap: 8px; }
