/* ============================================================
   help.git.nluagrm.org — Guía visual de acceso a la plataforma Git
   Núcleo Linux UAGRM
   ============================================================ */

/* 1. Variables y temas -------------------------------------- */
:root {
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

  --bg: #f4f7f5;
  --surface: #ffffff;
  --surface-2: #ecf1ee;
  --surface-3: #e3e9e5;
  --text: #16211c;
  --text-muted: #526158;
  --text-soft: #6c7a72;
  --border: #d8e1db;
  --border-strong: #b8c8be;

  --accent: #0a7f57;
  --accent-strong: #086b4c;
  --accent-soft: #d9f2e8;
  --accent-contrast: #ffffff;

  --ok: #1a9c4f;
  --ok-strong: #157a3f;
  --ok-soft: #dcf5e6;
  --ok-border: #b3e2c8;

  --warn: #b26a0a;
  --warn-strong: #8a5206;
  --warn-soft: #fdf0da;
  --warn-border: #f0d4a6;

  --telegram: #1479a8;

  --shadow-md: 0 10px 30px rgba(24, 42, 34, 0.1);
  --shadow-lg: 0 24px 60px rgba(24, 42, 34, 0.14);

  --radius-sm: .5rem;
  --radius-md: .75rem;
  --radius-lg: 1.1rem;

  --header-h: 68px;
  --progress-h: 56px;

  --text-base: clamp(1rem, 1.5vw, 1.1rem);
}

[data-theme="dark"] {
  --bg: #0c1210;
  --surface: #121a16;
  --surface-2: #18221d;
  --surface-3: #202c26;
  --text: #e5ede8;
  --text-muted: #9db0a6;
  --text-soft: #7c8f85;
  --border: #25322b;
  --border-strong: #3a4c42;

  --accent: #34d399;
  --accent-strong: #5eead4;
  --accent-soft: #0f2b22;
  --accent-contrast: #06231a;

  --ok: #34d399;
  --ok-strong: #6ee7a7;
  --ok-soft: #0d2b1c;
  --ok-border: #1f5538;

  --warn: #fbbf24;
  --warn-strong: #fcd34d;
  --warn-soft: #2a2009;
  --warn-border: #57400f;

  --telegram: #1479a8;

  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.5);
}

/* 2. Reset y base ------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
ul, ol { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; line-height: 1.2; font-weight: 700; }
a { color: var(--accent); }

::selection { background: var(--accent-soft); color: var(--text); }

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* 3. Utilidades --------------------------------------------- */
.container {
  width: 100%;
  max-width: 1180px;
  margin-inline: auto;
  padding-inline: clamp(1rem, 4vw, 2rem);
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px; left: 1rem;
  z-index: 100;
  padding: .6rem 1rem;
  background: var(--accent);
  color: var(--accent-contrast);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  font-weight: 600;
  text-decoration: none;
  transition: top .2s ease;
}
.skip-link:focus { top: 0; }

.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.icon {
  width: 1.1em;
  height: 1.1em;
  flex: none;
}

/* 4. Tipografía de sección ---------------------------------- */
.section-kicker {
  font-family: var(--font-mono);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
}

/* 5. Header -------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  transition: box-shadow .25s ease, background .3s ease;
}
.site-header.is-scrolled {
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 8px 24px rgba(24, 42, 34, 0.06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
  padding-block: .5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  text-decoration: none;
  color: var(--text);
  min-width: 0;
}
.brand-mark {
  width: 38px;
  height: 38px;
  flex: none;
  filter: drop-shadow(0 4px 10px rgba(13, 158, 111, 0.35));
}
.brand-text {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 0;
}
.brand-title { font-weight: 800; font-size: 1rem; letter-spacing: .01em; }
.brand-subtitle {
  font-family: var(--font-mono);
  font-size: .72rem;
  color: var(--text-muted);
  letter-spacing: .06em;
}

/* Selector de tema */
.theme-switch {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  flex: none;
}
.theme-option {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .42rem .7rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: .82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.theme-option:hover { color: var(--text); }
.theme-option.is-active {
  background: var(--surface);
  color: var(--accent);
  box-shadow: 0 2px 8px rgba(24, 42, 34, 0.1);
}

/* 6. Barra de progreso --------------------------------------- */
.guide-progress {
  position: sticky;
  top: var(--header-h);
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.progress-track {
  position: relative;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding-block: .7rem;
}
.progress-item {
  position: relative;
  flex: 1;
  display: flex;
  justify-content: center;
}
.progress-item::before {
  content: "";
  position: absolute;
  top: 17px;
  left: -50%;
  width: 100%;
  height: 3px;
  background: var(--border);
  transition: background .3s ease;
}
.progress-item:first-child::before { display: none; }
.progress-item.is-done::before { background: var(--accent); }

.progress-dot {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--border-strong);
  font-family: var(--font-mono);
  font-size: .72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-decoration: none;
  transition: background .3s ease, border-color .3s ease, color .3s ease, transform .3s ease;
}
.progress-item a { display: block; line-height: 0; }
.progress-dot:hover { border-color: var(--accent); color: var(--accent); }
.progress-item.is-active .progress-dot {
  border-color: var(--accent);
  color: var(--accent);
  transform: scale(1.15);
  box-shadow: 0 0 0 4px var(--accent-soft);
}
.progress-item.is-done .progress-dot {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-contrast);
}

.progress-bar {
  display: none;
  height: 3px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 1.1rem;
}
.progress-fill {
  display: block;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-strong));
  transition: width .35s ease;
}

/* 7. Hero ---------------------------------------------------- */
.hero {
  position: relative;
  text-align: center;
  padding-block: clamp(3rem, 8vw, 6.5rem);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(color-mix(in srgb, var(--accent) 7%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--accent) 7%, transparent) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 75% 70% at 50% 0%, #000 55%, transparent 100%);
  mask-image: radial-gradient(ellipse 75% 70% at 50% 0%, #000 55%, transparent 100%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(420px 260px at 18% 12%, var(--accent-soft), transparent 70%),
    radial-gradient(460px 300px at 84% 20%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 70%);
  pointer-events: none;
}
.hero-inner { position: relative; z-index: 1; }

.hero-eyebrow {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  justify-content: center;
  margin-bottom: 1.2rem;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .35rem .85rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-family: var(--font-mono);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .05em;
  border: 1px solid var(--accent-soft);
}
.chip-soft {
  background: var(--surface);
  color: var(--text-muted);
  border-color: var(--border);
}

.hero-title {
  font-size: clamp(2rem, 6vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.hero-subtitle {
  margin-top: .6rem;
  font-size: clamp(1.05rem, 2.5vw, 1.35rem);
  font-weight: 600;
  color: var(--accent);
}
.hero-desc {
  max-width: 640px;
  margin: 1rem auto 0;
  color: var(--text-muted);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .8rem;
  justify-content: center;
  margin-top: 1.8rem;
}

.hero-deco {
  position: absolute;
  width: 34px;
  height: 34px;
  color: color-mix(in srgb, var(--accent) 45%, transparent);
  animation: floaty 7s ease-in-out infinite;
  pointer-events: none;
}
.hero-deco--1 { top: 22%; left: 10%; animation-delay: 0s; }
.hero-deco--2 { top: 30%; right: 12%; animation-delay: -2.3s; }
.hero-deco--3 { top: 64%; left: 18%; width: 26px; height: 26px; animation-delay: -4.6s; }

/* 8. Botones ------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .72rem 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background .2s ease, color .2s ease, border-color .2s ease,
              box-shadow .2s ease, transform .15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--accent); color: var(--accent-contrast); }
.btn-primary:hover {
  background: var(--accent-strong);
  box-shadow: 0 10px 26px color-mix(in srgb, var(--accent) 40%, transparent);
}

.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.btn-telegram { background: var(--telegram); color: #fff; }
.btn-telegram:hover {
  background: color-mix(in srgb, var(--telegram) 88%, #000);
  box-shadow: 0 10px 26px color-mix(in srgb, var(--telegram) 45%, transparent);
}

/* 9. Pasos (layout) ------------------------------------------ */
.steps { padding-block: clamp(2rem, 5vw, 4rem) clamp(3rem, 7vw, 5.5rem); }

.step {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  grid-template-areas:
    "num   visual"
    "title visual"
    "body  visual";
  column-gap: clamp(1.5rem, 4vw, 3.5rem);
  row-gap: .8rem;
  align-items: center;
  padding-block: clamp(2.2rem, 6vw, 4.5rem);
  border-bottom: 1px solid var(--border);
  min-width: 0;
}
.step:last-child { border-bottom: 0; }

.step:nth-child(even) {
  grid-template-areas:
    "visual num"
    "visual title"
    "visual body";
}

.step.step--wide {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas:
    "num   title"
    "visual visual"
    "body  body";
}

.step-number {
  grid-area: num;
  align-self: end;
  font-family: var(--font-mono);
  font-size: clamp(2.6rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: .02em;
  color: var(--accent);
  opacity: .9;
}

.step-title {
  grid-area: title;
  align-self: start;
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  letter-spacing: -0.01em;
}

.step-visual {
  grid-area: visual;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-body {
  grid-area: body;
  display: flex;
  flex-direction: column;
  gap: .9rem;
  align-items: flex-start;
  min-width: 0;
}

.step-text { color: var(--text-muted); }

.step-note {
  display: inline-flex;
  align-items: flex-start;
  gap: .5rem;
  padding: .6rem .85rem;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--border));
  color: var(--accent-strong);
  font-size: .92rem;
  font-weight: 600;
}
.step-note .icon { margin-top: .15em; }

.step-note--warn {
  background: var(--warn-soft);
  border-color: var(--warn-border);
  color: var(--warn-strong);
}

/* 10. Mockups (ventanas / formularios) ----------------------- */
.mock {
  width: 100%;
  max-width: 480px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.mock-bar {
  display: flex;
  align-items: center;
  gap: .45rem;
  padding: .65rem .9rem;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}
.mock-dot { width: .55rem; height: .55rem; border-radius: 50%; flex: none; }
.mock-dot:nth-child(1) { background: #f87f6d; }
.mock-dot:nth-child(2) { background: #f6c05c; }
.mock-dot:nth-child(3) { background: #6ccb8f; }
.mock-url {
  margin-left: auto;
  max-width: 70%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: .15rem .7rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: .7rem;
}

.mock-body { padding: 1.3rem; }
.mock-head { display: flex; align-items: center; gap: .6rem; margin-bottom: 1.1rem; flex-wrap: wrap; }
.mock-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px; height: 30px;
  border-radius: .6rem;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: var(--accent-contrast);
  font-size: 1rem;
}
.mock-h { font-size: 1.05rem; font-weight: 700; }
.mock-h--small { font-size: .85rem; color: var(--text-muted); font-weight: 600; margin-bottom: .7rem; }

.field { margin-bottom: .75rem; }
.field-label { display: block; font-size: .76rem; font-weight: 600; color: var(--text-muted); margin-bottom: .3rem; }
.mock-input {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .55rem .7rem;
  border-radius: var(--radius-sm);
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: .86rem;
  font-family: var(--font-sans);
  overflow: hidden;
}
.mock-input .icon { color: var(--text-soft); width: .95em; height: .95em; }
.mock-input span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.btn-mock {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  width: 100%;
  margin-top: .9rem;
  padding: .62rem;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 700;
  text-align: center;
}
.btn-mock-accent { background: var(--accent); color: var(--accent-contrast); }
.btn-mock-ghost { background: var(--surface-2); color: var(--text-muted); border: 1px solid var(--border); }

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .3rem .7rem;
  border-radius: 999px;
  font-size: .76rem;
  font-weight: 700;
  white-space: nowrap;
}
.badge-accent { background: var(--accent-soft); color: var(--accent-strong); border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--border)); }
.badge-ok { background: var(--ok-soft); color: var(--ok-strong); border: 1px solid var(--ok-border); }
.badge-warn { background: var(--warn-soft); color: var(--warn-strong); border: 1px solid var(--warn-border); }

/* 11. Paso 2 — revisión de cuenta ---------------------------- */
.review-card {
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-2);
  flex-wrap: wrap;
}
.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem; height: 2.5rem;
  flex: none;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: var(--accent-contrast);
  font-size: .78rem;
  font-weight: 800;
  font-family: var(--font-mono);
}
.avatar--admin { background: linear-gradient(135deg, #4b6bfb, #7a5bfd); }

.review-info { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.review-user { font-weight: 700; font-size: .9rem; }
.review-mail { font-size: .76rem; color: var(--text-muted); font-family: var(--font-mono); }

.review-actions { display: flex; gap: .6rem; margin-top: .8rem; }
.review-actions .btn-mock { width: auto; flex: 1; margin-top: 0; padding: .5rem .7rem; font-size: .84rem; }

.review-admin {
  display: flex;
  align-items: center;
  gap: .7rem;
  margin-top: .9rem;
  padding: .7rem .8rem;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  background: var(--surface);
}
.review-admin-text { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.review-admin-name { font-weight: 700; font-size: .86rem; }
.review-admin-role { font-size: .74rem; color: var(--text-muted); }

.pulse-dot {
  position: relative;
  width: .5rem; height: .5rem;
  border-radius: 50%;
  background: var(--warn);
  flex: none;
}
.pulse-dot::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid var(--warn);
  animation: pulse 2s ease-out infinite;
}

/* 12. Paso 4 — flujo 2FA ------------------------------------- */
.flow {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  justify-content: center;
  gap: 1.1rem;
  width: 100%;
}
.flow-node { min-width: 0; }
.flow-node.mock { max-width: 380px; }

.flow-arrow {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .35rem;
  color: var(--text-muted);
  font-size: .78rem;
  font-weight: 700;
  text-align: center;
  flex: none;
}
.icon-arrow { width: 26px; height: 26px; }

.flow-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: 1.1rem 1.4rem;
  border-radius: var(--radius-md);
  background: var(--ok-soft);
  border: 2px solid var(--ok-border);
  color: var(--ok-strong);
  font-weight: 800;
  text-align: center;
  font-size: .95rem;
  line-height: 1.25;
}
.icon-check-big { width: 2rem; height: 2rem; }

.setting-row {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .7rem .8rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  margin-bottom: .9rem;
}
.setting-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px; height: 30px;
  flex: none;
  border-radius: .5rem;
  background: var(--accent-soft);
  color: var(--accent);
}
.setting-label { font-size: .82rem; font-weight: 700; flex: 1; }

.toggle {
  position: relative;
  width: 40px; height: 22px;
  flex: none;
  border-radius: 999px;
  background: var(--border-strong);
  transition: background .25s ease;
}
.toggle-knob {
  position: absolute;
  top: 3px; left: 3px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #fff;
  transition: transform .25s ease;
}
.toggle.is-on { background: var(--ok); }
.toggle.is-on .toggle-knob { transform: translateX(18px); }

.qr-card {
  display: flex;
  justify-content: center;
  padding: .7rem;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  width: max-content;
  margin-inline: auto;
}
.qr-svg { width: 5.4rem; height: 5.4rem; shape-rendering: crispEdges; }
.qr-hint {
  margin-top: .55rem;
  text-align: center;
  font-size: .74rem;
  color: var(--text-muted);
}

/* 13. Teléfono y Aegis --------------------------------------- */
.phone {
  width: min(100%, var(--phone-w, 240px));
  margin-inline: auto;
  padding: 8px;
  background: var(--border-strong);
  border-radius: 2.2rem;
  box-shadow: var(--shadow-lg);
  border: 3px solid var(--surface-3);
}
.phone-screen {
  background: var(--surface);
  border-radius: 1.7rem;
  padding: 1rem .85rem .95rem;
  border: 1px solid var(--border);
  overflow: hidden;
}
.phone-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .68rem;
  font-weight: 700;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-bottom: .55rem;
}
.phone-signal {
  width: 34px; height: 8px;
  border-radius: 2px;
  background:
    radial-gradient(circle 3px at 3px 50%, var(--text-muted) 95%, transparent) 0 0 / 8px 8px,
    radial-gradient(circle 3px at 11px 50%, var(--text-muted) 95%, transparent) 0 0 / 8px 8px,
    radial-gradient(circle 3px at 19px 50%, var(--text-muted) 95%, transparent) 0 0 / 8px 8px,
    radial-gradient(circle 3px at 27px 50%, var(--border) 95%, transparent) 0 0 / 8px 8px;
}

.aegis-head {
  display: flex;
  align-items: center;
  gap: .45rem;
  font-size: .82rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: .6rem;
}
.aegis-head .icon { color: var(--accent); }
.aegis-count {
  margin-left: auto;
  padding: .05rem .45rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: .7rem;
  font-weight: 800;
}

.aegis-account {
  display: flex;
  flex-direction: column;
  gap: .15rem;
  padding: .65rem .75rem;
  margin-bottom: .55rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-2);
}
.aegis-account-active {
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}
.aegis-issuer { font-size: .74rem; font-weight: 800; }
.aegis-user { font-size: .68rem; color: var(--text-muted); font-family: var(--font-mono); }
.aegis-code {
  font-family: var(--font-mono);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: .22em;
  color: var(--text);
  margin-top: .1rem;
}
.aegis-code-muted { color: var(--text-soft); font-size: 1.15rem; letter-spacing: .4em; }
.aegis-timer-row {
  display: flex;
  align-items: center;
  gap: .45rem;
  margin-top: .25rem;
  font-size: .68rem;
  font-weight: 600;
  color: var(--text-muted);
}
.aegis-timer { width: 26px; height: 26px; }
.timer-track { fill: none; stroke: var(--border-strong); stroke-width: 3; }
.timer-fill {
  fill: none;
  stroke: var(--accent);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 94.2;
  stroke-dashoffset: 0;
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
  animation: timer-count 30s linear infinite;
}
.timer-label {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 700;
  fill: var(--text-muted);
}

/* 14. Paso 6 — cuenta protegida ------------------------------ */
.protected-scene {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}
.shield {
  width: clamp(5.5rem, 12vw, 8.5rem);
  height: clamp(5.5rem, 12vw, 8.5rem);
  filter: drop-shadow(0 14px 30px color-mix(in srgb, var(--accent) 45%, transparent));
}
.shield-body { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 1.4; }
.shield-inner { fill: none; stroke: var(--ok); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.shield-lock { fill: var(--accent); }

.protected-card {
  width: 100%;
  max-width: 460px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 1.1rem 1.2rem;
}
.protected-row { display: flex; align-items: center; gap: .7rem; }
.protected-user { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.protected-name { font-weight: 800; font-size: .92rem; }
.protected-role { font-size: .74rem; color: var(--text-muted); }
.protected-msg {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-top: .9rem;
  padding: .65rem .8rem;
  border-radius: var(--radius-sm);
  background: var(--ok-soft);
  border: 1px solid var(--ok-border);
  color: var(--ok-strong);
  font-weight: 700;
  font-size: .92rem;
}

/* 15. Ayuda -------------------------------------------------- */
.help {
  border-top: 1px solid var(--border);
  background: var(--surface-2);
  padding-block: clamp(3rem, 7vw, 5.5rem);
}
.help-head { text-align: center; max-width: 720px; margin-inline: auto; }
.help-title { font-size: clamp(1.7rem, 4vw, 2.4rem); margin-top: .4rem; }
.help-intro { margin-top: .9rem; color: var(--text-muted); }

.help-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem;
  max-width: 860px;
  margin: 2.2rem auto 0;
}
.help-card {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  padding: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}
.help-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  border-radius: var(--radius-md);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 1.4rem;
  margin-bottom: .2rem;
}
.help-card-title { font-size: 1.05rem; }
.help-card-text { color: var(--text-muted); font-size: .94rem; }

.help-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  max-width: 640px;
  margin: 1.6rem auto 0;
  text-align: center;
  font-size: .92rem;
  color: var(--text-muted);
  font-weight: 600;
}

.help-cta { display: flex; justify-content: center; margin-top: 1.4rem; }

/* 16. Footer -------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg);
  padding-block: 2.2rem;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .5rem;
  text-align: center;
}
.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.2;
}
.footer-brand .brand-subtitle {
  font-family: var(--font-mono);
  font-size: .74rem;
  color: var(--text-muted);
  letter-spacing: .08em;
  text-transform: uppercase;
}
.footer-meta { color: var(--text-muted); font-size: .86rem; max-width: 480px; }
.footer-link { font-size: .86rem; font-weight: 700; text-decoration: none; }
.footer-link:hover { text-decoration: underline; }
.footer-copy { color: var(--text-soft); font-size: .8rem; }

/* 17. Animaciones --------------------------------------------- */
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}
@keyframes pulse {
  0% { transform: scale(.8); opacity: .9; }
  70% { transform: scale(1.9); opacity: 0; }
  100% { opacity: 0; }
}
@keyframes timer-count {
  to { stroke-dashoffset: 94.2; }
}
@keyframes shield-glow {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}
.shield-anim { animation: shield-glow 4s ease-in-out infinite; transform-origin: center; }

/* 18. Revelado por scroll -------------------------------------- */
.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .6s ease, transform .6s ease;
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* 19. Responsive ----------------------------------------------- */
@media (max-width: 960px) {
  .step,
  .step:nth-child(even),
  .step--wide {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "num"
      "title"
      "visual"
      "body";
  }
  .step-number { align-self: start; }
  .step-visual { padding-block: 1rem; }
  .flow { flex-direction: column; align-items: center; }
  .icon-arrow { transform: rotate(90deg); }
}

@media (max-width: 760px) {
  .progress-track { display: none; }
  .progress-bar { display: block; }

  .brand-mark { width: 34px; height: 34px; }
  .brand-subtitle { display: none; }
  .theme-option { padding: .45rem .55rem; }
  .theme-option span { display: none; }

  .help-grid { grid-template-columns: minmax(0, 1fr); }
  .mock { max-width: 100%; }
  .step-note { font-size: .86rem; }
}

@media (max-width: 380px) {
  .theme-option { padding: .4rem .48rem; }
  .hero-deco { display: none; }
  .badge { font-size: .7rem; }
}

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