Laboratorio de Wireshark sin conexión: capturas sintéticas de un pentest, filtros validados al instante, retos guiados y un megalodón 3D en WebGL2.
JavaScript blue-teamcybersecurityewptjavascriptlearning-labnetwork-securityoffline-firstpacket-analysispcappentestingsocspanishtcp-ipwireshark
/* Megalodon · estilos. Sistema Rosetta/WhiteFox de Yoandy Ramírez Delgado: oscuro por defecto, claro con data-theme='light'.
Neutros + un acento azul + verde de recompensa + rojo de error. Sombras suaves, sin bordes ni barras laterales. Contraste de texto ≥ 7:1. */
:root {
--font-sans: ui-sans-serif, system-ui, -apple-system, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
--font-mono: ui-monospace, 'SF Mono', 'Cascadia Mono', Menlo, Consolas, 'Liberation Mono', monospace;
--r-chip: 6px; --r-ctl: 10px; --r-card: 16px; --r-dlg: 20px;
--ease-out: cubic-bezier(0.23, 1, 0.32, 1);
--ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
--spring: cubic-bezier(0.34, 1.56, 0.64, 1);
--top-h: 60px;
color-scheme: dark;
--ground: #0b0d11; --surface: #12151b; --surface-2: #1a1e26; --surface-3: #232831;
--ink: #eef2f6; --ink-2: #c9d0d8; --ink-3: #b2bbc6; --ink-4: #5d6672;
--accent: #6cb2ff; --accent-ink: #04152b; --accent-soft: rgb(108 178 255 / 0.15);
--ok: #57dc98; --ok-ink: #032614; --ok-soft: rgb(87 220 152 / 0.13);
--bad: #ff8f86; --bad-ink: #2b0503; --bad-soft: rgb(255 143 134 / 0.14);
--glass: rgb(18 21 27 / 0.78); --glass-thick: rgb(18 21 27 / 0.96);
--sh-panel: 0 1px 2px rgb(0 0 0 / 0.45), 0 12px 32px rgb(0 0 0 / 0.28);
--sh-overlay: 0 2px 8px rgb(0 0 0 / 0.5), 0 30px 80px rgb(0 0 0 / 0.55);
--sh-top: 0 1px 0 rgb(255 255 255 / 0.04), 0 10px 30px -18px rgb(0 0 0 / 0.8);
--sh-raise: 0 1px 2px rgb(0 0 0 / 0.5), 0 2px 8px rgb(0 0 0 / 0.25);
--cli: #ffb4ad; --cli-bg: rgb(255 143 134 / 0.1); --srv: #a9d1ff; --srv-bg: rgb(108 178 255 / 0.1);
/* reglas de color de paquetes (texto ≥ 7:1 sobre cada fondo) */
--pk-tcp: #241f3d; --pk-http: #17321f; --pk-udp: #13293d; --pk-arp: #352a17; --pk-synfin: #2d3138; --pk-smb: #33321a; --pk-icmp: #3a1f3a;
--pk-rst: #5e1015; --pk-rst-ink: #ffe0b8; --pk-bad: #000000; --pk-bad-ink: #ff8f86;
}
[data-theme='light'] {
color-scheme: light;
--ground: #f3f5f8; --surface: #ffffff; --surface-2: #eef1f5; --surface-3: #e1e6ed;
--ink: #0b1016; --ink-2: #252e39; --ink-3: #3a434e; --ink-4: #a3acb7;
--accent: #143f94; --accent-ink: #ffffff; --accent-soft: rgb(20 63 148 / 0.1);
--ok: #07583a; --ok-ink: #ffffff; --ok-soft: rgb(7 88 58 / 0.1);
--bad: #a8221b; --bad-ink: #ffffff; --bad-soft: rgb(168 34 27 / 0.09);
--glass: rgb(255 255 255 / 0.82); --glass-thick: rgb(255 255 255 / 0.97);
--sh-panel: 0 1px 3px rgb(15 23 42 / 0.05), 0 10px 25px -5px rgb(15 23 42 / 0.07);
--sh-overlay: 0 4px 14px rgb(15 23 42 / 0.08), 0 25px 50px -10px rgb(15 23 42 / 0.18);
--sh-top: 0 1px 0 rgb(15 23 42 / 0.04), 0 10px 30px -18px rgb(15 23 42 / 0.25);
--sh-raise: 0 1px 2px rgb(15 23 42 / 0.08), 0 2px 6px rgb(15 23 42 / 0.06);
--cli: #8c1a14; --cli-bg: #fcecea; --srv: #123d86; --srv-bg: #e9f0fc;
--pk-tcp: #e7e6ff; --pk-http: #e4ffc7; --pk-udp: #daeeff; --pk-arp: #faf0d7; --pk-synfin: #d9d9d9; --pk-smb: #feffd0; --pk-icmp: #fce0ff;
--pk-rst: #a40000; --pk-rst-ink: #fffc9c; --pk-bad: #12272e; --pk-bad-ink: #ff9d9d;
}
html.theming, html.theming *, html.theming *::before, html.theming *::after { transition: background-color 0.3s var(--ease-out), color 0.3s var(--ease-out), fill 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out) !important; }
/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--top-h) + 16px); background: var(--ground); }
body { margin: 0; min-height: 100dvh; background: var(--ground); color: var(--ink); font: 15px/1.55 var(--font-sans); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
h1, h2, h3, p, dl, dd, ol, ul, figure { margin: 0; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.015em; text-wrap: balance; }
p { text-wrap: pretty; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
code, kbd, .mono { font-family: var(--font-mono); font-size: 0.9em; }
code { overflow-wrap: anywhere; }
.num, .n { font-variant-numeric: tabular-nums; }
kbd { display: inline-flex; align-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: var(--r-chip); background: var(--surface-3); color: var(--ink-2); font-size: 11.5px; font-weight: 600; box-shadow: inset 0 -1px 0 rgb(0 0 0 / 0.18); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
::selection { background: var(--accent); color: var(--accent-ink); }
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: fixed; left: 12px; top: -60px; z-index: 100; padding: 10px 14px; border-radius: var(--r-ctl); background: var(--accent); color: var(--accent-ink); font-weight: 600; text-decoration: none; transition: top 0.2s var(--ease-out); }
.skip:focus { top: 12px; }
.noscript { padding: 40px; text-align: center; }
.i { width: 18px; height: 18px; flex: none; }
.i.sm { width: 15px; height: 15px; }
.muted { color: var(--ink-3); }
.sm { font-size: 13px; }
.okt { color: var(--ok); font-weight: 600; }
.badt { color: var(--bad); font-weight: 600; }
.center { text-align: center; }
.grow { flex: 1; }
.hide { display: none !important; }
.row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.stack-sm { display: grid; gap: 8px; }
.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
.wrap-wide { width: min(1600px, 100% - 32px); margin-inline: auto; }
.page { padding-block: 36px 24px; }
.card { background: var(--surface); border-radius: var(--r-card); box-shadow: var(--sh-panel); padding: 20px; }
.eyebrow { font-size: 12px; font-weight: 650; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.lead { font-size: 18px; color: var(--ink-2); max-width: 56ch; }
.note { display: flex; gap: 8px; align-items: center; padding: 10px 12px; border-radius: var(--r-ctl); background: var(--accent-soft); color: var(--ink-2); }
#main { outline: none; }
#main.enter > * { animation: enter 0.24s var(--ease-out) both; }
@keyframes enter { from { opacity: 0; transform: translateY(6px); } }
/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 38px; padding: 0 16px; border: 0; border-radius: var(--r-ctl); background: var(--surface-2); color: var(--ink); font-weight: 600; font-size: 14px; text-decoration: none; white-space: nowrap; transition: transform 0.16s var(--ease-out), background-color 0.16s var(--ease-out), box-shadow 0.16s var(--ease-out); -webkit-tap-highlight-color: transparent; }
.btn:active:not(:disabled) { transform: scale(0.97); }
.btn.primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--sh-raise); }
.btn.ghost { background: transparent; color: var(--ink-2); }
.btn.danger { background: var(--bad); color: var(--bad-ink); }
.btn.lg { height: 48px; padding: 0 22px; font-size: 15.5px; border-radius: 12px; }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; gap: 6px; }
.btn:disabled { opacity: 0.5; }
.ibtn { display: inline-grid; place-items: center; width: 38px; height: 38px; padding: 0; border: 0; border-radius: var(--r-ctl); background: transparent; color: var(--ink-2); text-decoration: none; transition: transform 0.16s var(--ease-out), background-color 0.16s var(--ease-out), color 0.16s; }
.ibtn.sm { width: 30px; height: 30px; border-radius: 8px; }
.ibtn:active:not(:disabled) { transform: scale(0.94); }
.ibtn:disabled { opacity: 0.4; }
.ibtn.done { color: var(--ok); }
@media (hover: hover) and (pointer: fine) {
.btn:hover:not(:disabled) { background: var(--surface-3); }
.btn.primary:hover:not(:disabled) { background: color-mix(in srgb, var(--accent) 88%, var(--ink)); }
.btn.ghost:hover:not(:disabled) { background: var(--surface-2); color: var(--ink); }
.btn.danger:hover:not(:disabled) { background: color-mix(in srgb, var(--bad) 88%, var(--ink)); }
.ibtn:hover:not(:disabled) { background: var(--surface-2); color: var(--ink); }
}
.pill { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 99px; background: var(--surface-2); color: var(--ink-2); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.meter { flex: 1; height: 6px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--accent); transition: width 0.5s var(--ease-out), background-color 0.3s; }
.meter.full i { background: var(--ok); }
/* ---------- Barra superior ---------- */
.top { position: sticky; top: 0; z-index: 30; background: var(--glass); -webkit-backdrop-filter: saturate(180%) blur(16px); backdrop-filter: saturate(180%) blur(16px); box-shadow: var(--sh-top); }
.top-in { display: flex; align-items: center; gap: 16px; height: var(--top-h); padding: 0 max(16px, env(safe-area-inset-left)); width: min(1600px, 100%); margin-inline: auto; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; letter-spacing: -0.02em; font-size: 17px; }
.logo { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: var(--accent); color: var(--accent-ink); }
.logo .i { width: 19px; height: 19px; }
.nav { display: flex; gap: 2px; }
.nav a, .mnav a, .mnav button { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: var(--r-ctl); color: var(--ink-2); font-size: 14px; font-weight: 550; text-decoration: none; transition: background-color 0.16s var(--ease-out), color 0.16s; }
.nav a[aria-current='page'], .mnav a[aria-current='page'] { background: var(--surface-2); color: var(--ink); }
.nav a[aria-current='page'] .i, .mnav a[aria-current='page'] .i { color: var(--accent); }
@media (hover: hover) and (pointer: fine) { .nav a:hover, .mnav a:hover, .mnav button:hover { background: var(--surface-2); color: var(--ink); } }
.top-acts { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.search-btn { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 8px 0 12px; border: 0; border-radius: var(--r-ctl); background: var(--surface-2); color: var(--ink-3); font-size: 13.5px; min-width: 200px; transition: background-color 0.16s, transform 0.16s var(--ease-out); }
.search-btn kbd { margin-left: auto; }
.search-btn:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) { .search-btn:hover { background: var(--surface-3); color: var(--ink-2); } }
.xp-chip { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 11px; margin: 0 4px; border-radius: 99px; background: var(--ok-soft); color: var(--ok); font-weight: 700; font-size: 13.5px; text-decoration: none; }
.xp-chip .xp-u { font-weight: 600; font-size: 12px; }
.xp-chip.bump { animation: bump 0.45s var(--spring); }
@keyframes bump { 40% { transform: scale(1.14); } }
.theme-btn { position: relative; }
.theme-btn .sun, .theme-btn .moon { position: absolute; display: grid; transition: transform 0.3s var(--ease-out), opacity 0.2s; }
.theme-btn .moon { opacity: 0; transform: rotate(-60deg) scale(0.85); }
[data-theme='light'] .theme-btn .sun { opacity: 0; transform: rotate(60deg) scale(0.85); }
[data-theme='light'] .theme-btn .moon { opacity: 1; transform: none; }
.mnav { display: grid; gap: 2px; padding: 8px 12px 14px; }
.mnav[hidden] { display: none; }
.mnav button { border: 0; background: transparent; text-align: left; }
.only-narrow { display: none !important; }
@media (max-width: 1023px) { .only-narrow { display: inline-flex !important; } }
@media (max-width: 1199px) { .search-btn { min-width: 0; width: 38px; padding: 0; justify-content: center; } .search-btn .sb-t, .search-btn kbd { display: none; } }
@media (max-width: 999px) { .nav { display: none; } }
@media (min-width: 1000px) { [data-menu] { display: none !important; } .mnav { display: none !important; } }
@media (max-width: 999px) { [data-menu] { display: inline-grid !important; } }
@media (max-width: 640px) { .search-btn .sb-t, .search-btn kbd { display: none; } .search-btn { width: 38px; padding: 0; justify-content: center; background: transparent; color: var(--ink-2); } .hide-narrow { display: none !important; } .brand-t { display: none; } .top-in { gap: 8px; } }
/* ---------- Hero ---------- */
/* Hero: banda de portada siempre oscura (también en modo claro), imagen a sangre y texto sobre la zona vacía de la izquierda */
.hero {
--hero-bg: rgb(4 14 37);
color-scheme: dark; --ground: var(--hero-bg); --ink: #f2f5f9; --ink-2: #d3dae3; --accent: #7cbcff; --accent-ink: #03122a; --surface-2: rgb(255 255 255 / 0.1);
position: relative; isolation: isolate; min-height: clamp(460px, 70vh, 720px); display: flex; align-items: center; overflow: hidden;
background: var(--hero-bg); color: var(--ink);
}
.hero-art { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.hero-art picture, .hero-img { display: block; width: 100%; height: 100%; }
.hero-img { object-fit: cover; object-position: 62% 50%; transform-origin: 74% 46%; animation: hero-drift 36s var(--ease-in-out) infinite alternate; will-change: transform; }
@keyframes hero-drift { from { transform: scale(1.001); } to { transform: scale(1.06) translate3d(-0.8%, -0.6%, 0); } }
.hero::before { content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
background: linear-gradient(90deg, var(--hero-bg) 0%, color-mix(in srgb, var(--hero-bg) 92%, transparent) 34%, color-mix(in srgb, var(--hero-bg) 55%, transparent) 50%, transparent 68%),
linear-gradient(0deg, color-mix(in srgb, var(--hero-bg) 70%, transparent) 0%, transparent 22%); }
.hero-copy { width: min(1160px, 100% - 40px); margin: 0 auto; padding: 56px 0; display: grid; gap: 16px; justify-items: start; }
.hero-copy > * { max-width: min(580px, 46vw); }
@media (min-width: 761px) and (max-width: 1199px) { .hero::before { background: linear-gradient(90deg, var(--hero-bg) 0%, color-mix(in srgb, var(--hero-bg) 92%, transparent) 46%, color-mix(in srgb, var(--hero-bg) 50%, transparent) 60%, transparent 76%); } .hero-copy > * { max-width: 48vw; } }
.hero-copy h1 { font-size: clamp(48px, 7.4vw, 96px); font-weight: 760; letter-spacing: -0.045em; line-height: 0.95; text-wrap: balance; }
.hero-copy .lead { max-width: 46ch; text-wrap: pretty; }
.hero-copy .cta { margin-top: 8px; gap: 10px; }
@media (hover: hover) and (pointer: fine) { .hero .btn.ghost:hover:not(:disabled) { background: rgb(255 255 255 / 0.1); color: var(--ink); } }
@media (prefers-reduced-motion: reduce) { .hero-img { animation: none; transform: none; } }
@media (max-width: 760px) {
.hero { display: block; min-height: 0; }
.hero-art { position: relative; height: clamp(240px, 62vw, 420px); }
.hero-img { object-position: 84% 50%; transform-origin: 80% 50%; }
.hero::before { inset: 0 0 auto 0; height: clamp(240px, 62vw, 420px); background: linear-gradient(0deg, var(--hero-bg) 0%, color-mix(in srgb, var(--hero-bg) 60%, transparent) 22%, transparent 48%); }
.hero-copy { padding: 0 0 36px; margin-top: -28px; position: relative; }
.hero-copy > * { max-width: none; }
.hero-copy .cta .btn { flex: 1 1 100%; }
}
@media (forced-colors: active) { .hero::before { display: none; } }
/* ---------- Inicio ---------- */
.stats3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 32px; }
.stat { display: flex; gap: 14px; align-items: center; }
.stat > div { flex: 1; display: grid; gap: 4px; }
.stat-ic { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--surface-2); color: var(--ink-2); flex: none; }
.stat-ic.ok { background: var(--ok-soft); color: var(--ok); }
.stat-v { font-size: 24px; font-weight: 720; letter-spacing: -0.02em; line-height: 1.1; }
.stat-l { font-size: 13px; color: var(--ink-3); }
.stat .meter { margin-top: 6px; }
.sec-h { display: grid; gap: 8px; margin: 80px 0 24px; }
.sec-h h1 { font-size: clamp(30px, 4vw, 40px); font-weight: 730; letter-spacing: -0.03em; }
.sec-h h2 { font-size: 26px; font-weight: 700; }
.sec-h.sub { margin-top: 48px; }
.sec-h.sub h2, .sec-h.sub h3 { font-size: 19px; font-weight: 680; }
.page .sec-h:first-child { margin-top: 8px; }
.mgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.mcard { display: grid; gap: 6px; align-content: start; color: inherit; text-decoration: none; transition: transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out); }
.mcard h3 { font-size: 18px; font-weight: 680; }
.mcard .row.between { margin-bottom: 10px; }
.mcard:active { transform: scale(0.985); }
@media (hover: hover) and (pointer: fine) { .mcard:hover { transform: translateY(-2px); box-shadow: var(--sh-overlay); } }
.mic { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.mic.lg { width: 52px; height: 52px; border-radius: 14px; }
.mic.lg .i { width: 24px; height: 24px; }
.mfoot { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.how { margin-top: 80px; }
.how h2 { font-size: 26px; font-weight: 700; margin-bottom: 24px; }
.steps3 { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.steps3 li { display: grid; gap: 8px; align-content: start; }
.steps3 h3 { font-size: 17px; }
.steps3 p { color: var(--ink-2); }
.stepn { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 99px; background: var(--accent); color: var(--accent-ink); font-weight: 700; font-size: 14px; }
.foot { display: grid; gap: 4px; padding: 48px 0 40px; color: var(--ink-3); font-size: 13px; }
@media (max-width: 760px) { .stats3, .steps3 { grid-template-columns: 1fr; } .stats3 { margin-top: 24px; gap: 12px; } .sec-h { margin-top: 56px; } .how { margin-top: 56px; } }
/* ---------- Módulo ---------- */
.mod { padding-bottom: 24px; }
.mod-h { display: grid; gap: 14px; padding: 22px 0 18px; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); text-decoration: none; font-weight: 550; justify-self: start; }
.mod-title { display: flex; gap: 16px; align-items: center; }
.mod-title h1 { font-size: clamp(26px, 3.4vw, 36px); font-weight: 740; letter-spacing: -0.03em; }
.mod-prog { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; max-width: 720px; }
.mod-prog .meter { min-width: 140px; }
.mod-grid { display: grid; grid-template-columns: minmax(360px, 460px) minmax(0, 1fr); gap: 20px; align-items: start; }
.mod-side { display: grid; gap: 16px; min-width: 0; }
.mod-side > .seg { position: sticky; top: calc(var(--top-h) + 10px); z-index: 5; justify-self: start; box-shadow: var(--sh-raise); }
.pan { display: grid; gap: 16px; outline: none; }
.pan[hidden] { display: none; }
.mod-ws { position: sticky; top: calc(var(--top-h) + 12px); height: calc(100dvh - var(--top-h) - 24px); min-height: 520px; }
.intro { font-size: 16px; color: var(--ink-2); }
.lcard { display: grid; gap: 12px; }
.lcard h2 { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 680; }
.lcard p { color: var(--ink-2); }
.lcard strong { color: var(--ink); }
.lcard code, .tq code, .hint code, .task-fb code { padding: 1px 6px; border-radius: var(--r-chip); background: var(--surface-2); color: var(--ink); }
.ln { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font-size: 13px; font-weight: 700; flex: none; }
.tries { display: grid; gap: 6px; margin-top: 4px; }
.tries-h { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 650; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3); }
.try { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; align-items: baseline; text-align: left; padding: 9px 12px; border: 0; border-radius: var(--r-ctl); background: var(--surface-2); transition: transform 0.16s var(--ease-out), background-color 0.16s; }
.try code { color: var(--accent); font-weight: 600; padding: 0; background: none; }
.try span { color: var(--ink-3); font-size: 13px; }
.try:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) { .try:hover { background: var(--surface-3); } }
@media (max-width: 1023px) {
.mod-grid { grid-template-columns: 1fr; }
.mod-ws { display: none; position: static; height: calc(100dvh - var(--top-h) - 84px); min-height: 460px; }
.mod[data-tab='ws'] .mod-ws { display: block; }
.mod-side > .seg { top: calc(var(--top-h) + 8px); }
}
/* Retos */
.task { display: grid; gap: 12px; transition: background-color 0.3s var(--ease-out); }
.task[data-state='done'] { background: color-mix(in srgb, var(--ok) 8%, var(--surface)); }
.task-h { display: flex; align-items: center; gap: 10px; }
.tnum { position: relative; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 99px; background: var(--surface-3); font-size: 13px; font-weight: 700; flex: none; }
.tn-ok { position: absolute; inset: 0; display: grid; place-items: center; border-radius: inherit; background: var(--ok); color: var(--ok-ink); opacity: 0; transform: scale(0.4); }
.task[data-state='done'] .tn-ok { opacity: 1; transform: none; }
.task.just .tn-ok { animation: pop 0.5s var(--spring); }
@keyframes pop { from { opacity: 0; transform: scale(0.4); } }
.ttype { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 650; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3); }
.txp { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; color: var(--ink-3); }
.task[data-state='done'] .txp { color: var(--ok); }
.tq { font-size: 15.5px; }
.task-act { display: grid; gap: 10px; justify-items: start; }
.task[data-state='done'] .task-act > .btn, .task[data-state='done'] .ans .btn { display: none; }
.ans { display: flex; gap: 8px; width: 100%; }
.tinput { flex: 1; min-width: 0; height: 38px; padding: 0 12px; border: 0; border-radius: var(--r-ctl); background: var(--surface-2); box-shadow: inset 0 0 0 1px transparent; transition: box-shadow 0.16s, background-color 0.16s; }
.tinput:focus { outline: none; box-shadow: inset 0 0 0 2px var(--accent); background: var(--surface); }
.tinput:disabled { opacity: 0.7; }
.opts { display: grid; gap: 6px; width: 100%; }
.opt { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 10px 12px; border: 0; border-radius: var(--r-ctl); background: var(--surface-2); transition: transform 0.16s var(--ease-out), background-color 0.16s, color 0.16s; }
.opt:active:not(:disabled) { transform: scale(0.985); }
.ob { width: 16px; height: 16px; border-radius: 99px; box-shadow: inset 0 0 0 2px var(--ink-3); flex: none; transition: box-shadow 0.2s var(--ease-out); }
.opt.right { background: var(--ok-soft); color: var(--ok); font-weight: 600; opacity: 1; }
.opt.right .ob { box-shadow: inset 0 0 0 5px var(--ok); }
.opt.wrong { background: var(--bad-soft); color: var(--ink-3); text-decoration: line-through; text-decoration-color: var(--bad); }
.opt.wrong .ob { box-shadow: inset 0 0 0 2px var(--bad); }
.opt:disabled:not(.right):not(.wrong) { opacity: 0.6; }
@media (hover: hover) and (pointer: fine) { .opt:hover:not(:disabled) { background: var(--surface-3); } }
.task-fb:empty { display: none; }
.task-fb { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-ctl); font-size: 14px; animation: fade 0.2s var(--ease-out); }
.task-fb .i { margin-top: 2px; }
.task-fb.ok { background: var(--ok-soft); color: var(--ok); font-weight: 550; }
.task-fb.ok strong { color: inherit; }
.task-fb.bad { background: var(--bad-soft); color: var(--bad); }
@keyframes fade { from { opacity: 0; transform: translateY(-3px); } }
.task.nope { animation: nope 0.32s var(--ease-out); }
@keyframes nope { 20% { transform: translateX(-4px); } 50% { transform: translateX(4px); } 80% { transform: translateX(-2px); } }
.task-hints { display: grid; gap: 6px; }
.task-hints:empty { display: none; }
.hint { display: flex; gap: 8px; align-items: flex-start; padding: 9px 12px; border-radius: var(--r-ctl); background: var(--surface-2); color: var(--ink-2); font-size: 14px; }
.hint .i { margin-top: 3px; color: var(--accent); }
.hint.new { animation: fade 0.24s var(--ease-out); }
.task-foot { display: flex; justify-content: flex-end; margin-top: -4px; }
.task-foot .btn[hidden] { display: none; }
.mod-end { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; background: color-mix(in srgb, var(--ok) 10%, var(--surface)); }
.mod-end > .i { width: 36px; height: 36px; color: var(--ok); }
.mod-end > div { flex: 1; min-width: 180px; }
.mod-end h2 { font-size: 18px; color: var(--ok); }
/* Diagrama de escalera */
.ladder { display: grid; gap: 8px; padding: 12px; border-radius: 14px; background: var(--surface-2); }
.ladder svg { width: 100%; height: auto; display: block; overflow: visible; }
.ladder .lh { font: 650 13px var(--font-sans); fill: var(--ink); }
.ladder .lh2 { font: 11px var(--font-mono); fill: var(--ink-3); }
.ladder .life { stroke: var(--ink-4); stroke-width: 1.5; stroke-dasharray: 3 4; }
.ladder .ph rect { fill: var(--surface-3); }
.ladder .ph text { font: 650 11px var(--font-sans); fill: var(--ink-2); letter-spacing: 0.02em; }
.ladder .ar { stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; }
.ladder .hd { fill: var(--ink-2); }
.ladder .sl { font: 650 12px var(--font-sans); fill: var(--ink); }
.ladder .sn { font: 10.5px var(--font-mono); fill: var(--ink-3); }
.ladder .step { cursor: pointer; outline: none; }
.ladder .step.app .ar { stroke: var(--ok); } .ladder .step.app .hd { fill: var(--ok); }
.ladder .step.rst .ar { stroke: var(--bad); } .ladder .step.rst .hd { fill: var(--bad); }
.ladder .step.on .ar, .ladder .step:focus-visible .ar { stroke: var(--accent); stroke-width: 2.4; }
.ladder .step.on .hd, .ladder .step:focus-visible .hd { fill: var(--accent); }
.ladder .step.on .sl, .ladder .step:focus-visible .sl { fill: var(--accent); }
@media (hover: hover) and (pointer: fine) { .ladder .step:hover .sl { fill: var(--accent); } .ladder .step:hover .ar { stroke: var(--accent); } .ladder .step:hover .hd { fill: var(--accent); } }
.ladder.play .step { animation: stepIn 0.32s var(--ease-out) both; animation-delay: var(--d); }
.ladder.play .step .ar { stroke-dasharray: 1; animation: draw 0.36s var(--ease-out) both; animation-delay: var(--d); }
@keyframes stepIn { from { opacity: 0; } }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
/* ---------- Segmentos, interruptores, selects ---------- */
.seg { display: inline-flex; gap: 2px; padding: 4px; border-radius: 12px; background: var(--surface-2); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg button { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border: 0; border-radius: 9px; background: transparent; color: var(--ink-3); font-size: 13.5px; font-weight: 600; white-space: nowrap; transition: background-color 0.18s var(--ease-out), color 0.18s, box-shadow 0.18s; }
.seg button[aria-selected='true'], .seg button[aria-checked='true'] { background: var(--surface); color: var(--ink); box-shadow: var(--sh-raise); }
[data-theme='dark'] .seg button[aria-selected='true'], [data-theme='dark'] .seg button[aria-checked='true'] { background: var(--surface-3); }
.seg button .num { font-size: 12px; color: var(--ink-3); }
.seg.sm button { height: 30px; font-size: 13px; }
.switch { position: relative; width: 46px; height: 28px; padding: 0; border: 0; border-radius: 99px; background: var(--surface-3); flex: none; transition: background-color 0.2s var(--ease-out); }
.switch i { position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 99px; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / 0.3); transition: transform 0.24s var(--spring); }
.switch[aria-checked='true'] { background: var(--accent); }
.switch[aria-checked='true'] i { transform: translateX(18px); }
.sel { height: 36px; padding: 0 10px; border: 0; border-radius: var(--r-ctl); background: var(--surface-2); color: var(--ink); max-width: 100%; }
select { accent-color: var(--accent); min-height: 32px; padding: 4px 8px; border: 0; border-radius: 8px; background: var(--surface-2); color: var(--ink); box-shadow: var(--sh-raise); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border: 0; border-radius: 99px; background: var(--surface-2); color: var(--ink-2); font-size: 13px; font-weight: 600; transition: background-color 0.16s, color 0.16s; }
.chip .num { color: var(--ink-3); font-weight: 500; }
.chip.on { background: var(--accent); color: var(--accent-ink); }
.chip.on .num { color: inherit; opacity: 0.85; }
/* ---------- Espacio de trabajo (Wireshark) ---------- */
.ws { position: relative; display: flex; flex-direction: column; height: 100%; background: var(--surface); border-radius: var(--r-card); box-shadow: var(--sh-panel); overflow: hidden; }
.ws-bar { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 10px 6px; align-items: center; }
.fbar { position: relative; flex: 1 1 380px; display: flex; align-items: center; gap: 4px; height: 40px; padding: 0 4px 0 10px; border-radius: var(--r-ctl); background: var(--surface-2); transition: background-color 0.2s var(--ease-out), box-shadow 0.2s var(--ease-out); }
.fbar:focus-within { box-shadow: 0 0 0 2px var(--accent); }
.fbar[data-state='ok'] { background: color-mix(in srgb, var(--ok) 16%, var(--surface-2)); }
.fbar[data-state='bad'] { background: color-mix(in srgb, var(--bad) 16%, var(--surface-2)); }
.fbar[data-state='ok']:focus-within { box-shadow: 0 0 0 2px var(--ok); }
.fbar[data-state='bad']:focus-within { box-shadow: 0 0 0 2px var(--bad); }
.fbar.shake { animation: nope 0.3s var(--ease-out); }
.fbar-ic { display: grid; color: var(--ink-3); }
.fbar[data-state='ok'] .fbar-ic { color: var(--ok); }
.fbar[data-state='bad'] .fbar-ic { color: var(--bad); }
.finput { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; font-size: 13.5px; outline: none; }
.finput::placeholder { color: var(--ink-3); font-family: var(--font-sans); }
.fbar [data-clear] { opacity: 0.75; }
.fbar[data-state='empty'] [data-clear] { visibility: hidden; }
.ac { position: absolute; z-index: 20; top: calc(100% + 6px); left: 0; right: 0; max-height: 300px; overflow: auto; margin: 0; padding: 6px; list-style: none; border-radius: 12px; background: var(--glass-thick); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: var(--sh-overlay); animation: acIn 0.16s var(--ease-out); transform-origin: top center; }
@keyframes acIn { from { opacity: 0; transform: scale(0.98) translateY(-4px); } }
.ac li { display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 12px; align-items: baseline; padding: 7px 10px; border-radius: 8px; cursor: pointer; }
.ac li code { color: var(--accent); font-weight: 600; white-space: nowrap; }
.ac li span { color: var(--ink-3); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ac li[aria-selected='true'] { background: var(--accent-soft); }
@media (hover: hover) and (pointer: fine) { .ac li:hover { background: var(--surface-2); } }
.ws-tools { display: flex; gap: 4px; flex-wrap: wrap; }
.tbtn { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 10px; border: 0; border-radius: var(--r-ctl); background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 600; white-space: nowrap; transition: background-color 0.16s, color 0.16s, transform 0.16s var(--ease-out); }
.tbtn:active { transform: scale(0.96); }
.tbtn[aria-pressed='true'] { color: var(--accent); }
@media (hover: hover) and (pointer: fine) { .tbtn:hover { background: var(--surface-2); color: var(--ink); } }
.fmsg { display: flex; gap: 6px; align-items: center; min-height: 0; margin: 0 12px; font-size: 13px; }
.fmsg:empty { display: none; }
.fmsg.bad { color: var(--bad); padding: 2px 0 6px; }
.ws-panes { flex: 1; min-height: 0; display: grid; grid-template-rows: minmax(140px, 1.3fr) minmax(110px, 1fr) minmax(90px, 0.7fr); gap: 6px; padding: 0 8px; }
.pane { position: relative; min-height: 0; border-radius: 12px; background: var(--ground); overflow: hidden; }
[data-theme='light'] .pane { background: var(--surface-2); }
.pane.plist { display: flex; flex-direction: column; outline: none; overflow: auto; overscroll-behavior: contain; }
.plist:focus-visible { box-shadow: inset 0 0 0 2px var(--accent); }
.prow { display: grid; grid-template-columns: 52px 86px minmax(96px, 1fr) minmax(96px, 1fr) 76px 54px minmax(180px, 3fr); align-items: center; gap: 8px; height: 28px; padding: 0 10px; font: 12.5px/1 var(--font-mono); font-variant-numeric: tabular-nums; }
.prow > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.prow .c-no, .prow .c-l { text-align: right; }
.phead { flex: none; position: sticky; top: 0; z-index: 2; height: 30px; font: 600 12px var(--font-sans); color: var(--ink-3); background: var(--surface-3); }
.pbody { position: relative; flex: 1 0 auto; }
.pspacer { width: 1px; }
.pbody .prow { position: absolute; top: 0; left: 0; right: 0; cursor: default; color: var(--ink); }
.pempty { position: absolute; inset: 0; display: grid; place-items: center; color: var(--ink-3); font-size: 14px; }
.pempty[hidden] { display: none; }
.c-tcp { background: var(--pk-tcp); } .c-http { background: var(--pk-http); } .c-udp { background: var(--pk-udp); } .c-arp { background: var(--pk-arp); }
.c-synfin { background: var(--pk-synfin); } .c-smb { background: var(--pk-smb); } .c-icmp { background: var(--pk-icmp); }
.pbody .c-rst { background: var(--pk-rst); color: var(--pk-rst-ink); } .pbody .c-bad { background: var(--pk-bad); color: var(--pk-bad-ink); }
.nocolor .pbody .prow { background: transparent; color: var(--ink); }
.nocolor .pbody .prow:nth-child(odd) { background: color-mix(in srgb, var(--surface-3) 45%, transparent); }
.pbody .prow[aria-selected='true'] { background: var(--accent); color: var(--accent-ink); }
@media (hover: hover) and (pointer: fine) { .pbody .prow:hover:not([aria-selected='true']) { box-shadow: inset 0 0 0 100px rgb(127 127 127 / 0.12); } }
.ptree { overflow: auto; }
.pane-empty { position: absolute; inset: 0; display: grid; place-items: center; padding: 12px; color: var(--ink-3); font-size: 14px; text-align: center; }
.pane-empty[hidden] { display: none; }
.tree, .tree ul { list-style: none; margin: 0; padding: 0; }
.tree { padding: 6px; outline: none; min-height: 100%; }
.tree ul { padding-left: 18px; }
.tree ul[hidden] { display: none; }
.tn { display: flex; align-items: center; gap: 2px; min-height: 26px; padding: 2px 4px 2px 2px; border-radius: 7px; font: 12.5px/1.35 var(--font-mono); cursor: default; }
.tw { display: grid; place-items: center; width: 20px; height: 20px; flex: none; color: var(--ink-3); border-radius: 5px; }
.tw .i { transition: transform 0.18s var(--ease-out); }
[aria-expanded='true'] > .tn .tw .i { transform: rotate(90deg); }
.tl { flex: 1; min-width: 0; overflow-wrap: anywhere; }
li[aria-level='1'] > .tn .tl { font-weight: 650; font-family: var(--font-sans); font-size: 13px; }
.tf { display: grid; place-items: center; width: 26px; height: 24px; padding: 0; border: 0; border-radius: 6px; background: transparent; color: var(--ink-3); opacity: 0; transition: opacity 0.12s, background-color 0.12s; }
[aria-selected='true'] > .tn { background: var(--accent-soft); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 45%, transparent); }
[aria-selected='true'] > .tn .tf, .tf:focus-visible { opacity: 1; color: var(--accent); }
.tree:focus-visible [aria-selected='true'] > .tn { box-shadow: inset 0 0 0 2px var(--accent); }
@media (hover: hover) and (pointer: fine) { .tn:hover { background: rgb(127 127 127 / 0.1); } .tn:hover .tf { opacity: 1; } .tf:hover { background: var(--accent-soft); color: var(--accent); } }
@media (hover: none) { .tf { opacity: 0.8; } }
.phex { overflow: auto; outline: none; }
.phex:focus-visible, .tbl-wrap:focus-visible { box-shadow: inset 0 0 0 2px var(--accent); outline: none; }
.hex { padding: 8px 10px; font-size: 12.5px; line-height: 1.55; }
.hl-row { display: flex; gap: 14px; white-space: pre; }
.hl-row .off { color: var(--ink-3); }
.hx span, .as span { cursor: pointer; border-radius: 3px; }
.hx span { padding: 0 2px; }
.hx .gap { padding: 0 3px; cursor: default; }
.hx .pad { cursor: default; }
.as { color: var(--ink-2); }
.hex .on2 { background: var(--accent-soft); }
.hex .on { background: var(--accent); color: var(--accent-ink); }
.ws-status { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 7px 14px 9px; font-size: 12.5px; color: var(--ink-3); }
.ws-status strong { color: var(--ink); font-weight: 650; }
.ws-status .dot { width: 3px; height: 3px; border-radius: 9px; background: var(--ink-4); }
.legend { display: flex; gap: 10px; flex-wrap: wrap; }
.lg { display: inline-flex; align-items: center; gap: 5px; }
.lg i { width: 10px; height: 10px; border-radius: 3px; box-shadow: inset 0 0 0 1px rgb(127 127 127 / 0.35); }
.lg.c-rst, .lg.c-bad, .lg[class*='c-'] { background: none; color: inherit; }
.lg.c-tcp i { background: var(--pk-tcp); } .lg.c-http i { background: var(--pk-http); } .lg.c-udp i { background: var(--pk-udp); } .lg.c-arp i { background: var(--pk-arp); } .lg.c-synfin i { background: var(--pk-synfin); }
.lg.c-smb i { background: var(--pk-smb); } .lg.c-icmp i { background: var(--pk-icmp); } .lg.c-rst i { background: var(--pk-rst); } .lg.c-bad i { background: var(--pk-bad); }
.drop { position: absolute; inset: 0; z-index: 25; display: grid; place-content: center; justify-items: center; gap: 10px; background: color-mix(in srgb, var(--accent) 18%, var(--glass-thick)); color: var(--accent); font-weight: 650; font-size: 16px; border-radius: inherit; }
.drop[hidden] { display: none; }
.drop .i { width: 32px; height: 32px; }
@media (max-width: 1280px) { .prow { grid-template-columns: 44px 76px minmax(90px, 1fr) minmax(90px, 1fr) 64px 46px minmax(160px, 2.6fr); gap: 6px; } }
@media (max-width: 760px) {
.tbtn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.tbtn { width: 38px; padding: 0; justify-content: center; }
.ws-tools { width: 100%; justify-content: space-between; }
.prow { grid-template-columns: 34px minmax(78px, 1fr) minmax(78px, 1fr) 56px minmax(150px, 2fr); gap: 6px; padding: 0 6px; font-size: 12px; }
.prow .c-t, .prow .c-l { display: none; }
.fbar [data-apply] span { display: none; }
.legend { display: none; }
}
/* ---------- Laboratorio ---------- */
.lab { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; padding: 18px 0 20px; }
.lab-h .row { min-width: 0; max-width: 100%; }
.lab-h .row .sel { min-width: 0; flex: 1 1 auto; text-overflow: ellipsis; }
.lab-h { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; flex-wrap: wrap; }
.lab-h h1 { font-size: 28px; font-weight: 730; letter-spacing: -0.03em; }
.lab-ws { height: calc(100dvh - var(--top-h) - 120px); min-height: 520px; }
/* ---------- Chuleta y glosario ---------- */
.cgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 500px), 1fr)); gap: 16px; }
.cs h2 { font-size: 18px; font-weight: 680; margin-bottom: 10px; }
.cs ul { list-style: none; padding: 0; display: grid; gap: 2px; }
.cs li { display: flex; gap: 10px; align-items: center; padding: 8px 8px 8px 10px; border-radius: var(--r-ctl); transition: background-color 0.16s; }
.cs li:nth-child(odd) { background: var(--surface-2); }
.cs-f { flex: 1; min-width: 0; display: grid; gap: 2px; }
.cs-f code { color: var(--accent); font-weight: 600; }
.cs-f p { font-size: 13.5px; color: var(--ink-2); }
.cs-a { display: flex; gap: 2px; }
.cs.fields { margin-top: 16px; }
.gsearch { display: flex; align-items: center; gap: 10px; max-width: 520px; padding-left: 12px; border-radius: 12px; background: var(--surface); box-shadow: var(--sh-panel); color: var(--ink-3); margin-bottom: 8px; }
.gsearch .tinput { background: transparent; height: 46px; padding-left: 0; }
.gsearch .tinput:focus { box-shadow: none; }
.gsearch:focus-within { box-shadow: 0 0 0 2px var(--accent), var(--sh-panel); }
.gl { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 12px; margin-top: 12px; }
.gi { display: grid; gap: 6px; align-content: start; padding: 16px 18px; }
.gi[hidden] { display: none; }
.gi dt { font-weight: 700; }
.gi dd { color: var(--ink-2); font-size: 14.5px; }
.gi.flash { animation: flash 1.4s var(--ease-out); }
@keyframes flash { 0%, 30% { box-shadow: 0 0 0 2px var(--accent), var(--sh-panel); } }
/* ---------- Tablas ---------- */
.tbl-wrap { overflow: auto; border-radius: 12px; max-height: 58vh; }
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; }
.tbl th { position: sticky; top: 0; z-index: 1; text-align: left; padding: 9px 10px; background: var(--surface-3); color: var(--ink-2); font-weight: 650; font-size: 12.5px; white-space: nowrap; }
.tbl td { padding: 7px 10px; vertical-align: middle; }
.tbl tbody tr:nth-child(even) td { background: var(--surface-2); }
.tbl .n { text-align: right; font-variant-numeric: tabular-nums; }
.tbl.keys th { position: static; background: none; width: 40%; }
.tbl.keys td, .tbl.keys th { padding: 8px 6px; }
.bar-col { width: 28%; }
.bar { display: block; height: 8px; min-width: 2px; border-radius: 99px; background: var(--accent); }
/* ---------- Diálogos ---------- */
.dlg { width: min(600px, calc(100% - 24px)); max-width: none; max-height: none; padding: 0; border: 0; background: transparent; color: var(--ink); overflow: visible; }
.dlg.wide { width: min(1000px, calc(100% - 24px)); }
.dlg.narrow { width: min(460px, calc(100% - 24px)); }
.dlg::backdrop { background: rgb(4 8 14 / 0.5); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.dlg[open] .dlg-in { animation: dlgIn 0.22s var(--ease-out); }
.dlg[open]::backdrop { animation: fadeIn 0.2s var(--ease-out); }
.dlg.closing .dlg-in { animation: dlgOut 0.15s ease-in forwards; }
.dlg.closing::backdrop { animation: fadeOut 0.15s ease-in forwards; }
@keyframes dlgIn { from { opacity: 0; transform: scale(0.96) translateY(6px); } }
@keyframes dlgOut { to { opacity: 0; transform: scale(0.97); } }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes fadeOut { to { opacity: 0; } }
.dlg-in { display: flex; flex-direction: column; max-height: min(86dvh, 900px); border-radius: var(--r-dlg); background: var(--surface); box-shadow: var(--sh-overlay); overflow: hidden; }
.dlg-h { display: flex; align-items: center; gap: 12px; padding: 16px 14px 10px 22px; }
.dlg-h h2 { flex: 1; display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 680; }
.dlg-h h2 .i { color: var(--accent); }
.dlg-b { padding: 4px 22px 20px; overflow: auto; display: grid; gap: 14px; align-content: start; }
.dlg-f { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px 16px; background: var(--surface-2); flex-wrap: wrap; }
.lead-sm { color: var(--ink-2); }
.choice { display: flex; gap: 12px; align-items: center; width: 100%; padding: 12px 14px; border: 0; border-radius: 12px; background: var(--surface-2); text-align: left; transition: background-color 0.16s, transform 0.16s var(--ease-out); }
.choice span { display: grid; gap: 2px; }
.choice small { color: var(--ink-3); font-size: 13px; }
.choice .i { color: var(--accent); }
.choice:active:not(:disabled) { transform: scale(0.985); }
.choice:disabled { opacity: 0.5; }
@media (hover: hover) and (pointer: fine) { .choice:hover:not(:disabled) { background: var(--surface-3); } }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; flex-wrap: wrap; }
.set-row + .set-row { box-shadow: 0 -1px 0 var(--surface-2); }
.set-row > div:first-child { flex: 1; min-width: 200px; display: grid; gap: 2px; }
.set-row > div:first-child > p:first-child { font-weight: 600; }
.danger-zone { margin-top: 6px; padding: 14px; border-radius: 12px; background: var(--bad-soft); }
.help { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.help section { display: grid; gap: 6px; align-content: start; padding: 14px; border-radius: 12px; background: var(--surface-2); }
.help h3 { display: flex; gap: 8px; align-items: center; font-size: 15px; }
.help h3 .i { color: var(--accent); }
.help p { color: var(--ink-2); font-size: 14px; }
.celebrate .dlg-b { justify-items: center; padding-top: 10px; }
.badge-big { display: grid; place-items: center; width: 92px; height: 92px; border-radius: 28px; background: var(--ok-soft); color: var(--ok); animation: badge 0.7s var(--spring) both; }
.badge-big .i { width: 46px; height: 46px; }
@keyframes badge { from { opacity: 0; transform: scale(0.5) rotate(-12deg); } }
.badge-name { font-size: 22px; font-weight: 750; color: var(--ok); letter-spacing: -0.02em; }
/* Follow Stream */
.fs-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.fs-ends { display: flex; gap: 8px; flex-wrap: wrap; }
.who { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 99px; font-size: 13px; font-weight: 600; }
.who.cli { background: var(--cli-bg); color: var(--cli); }
.who.srv { background: var(--srv-bg); color: var(--srv); }
.who code { font-weight: 500; }
.fs-body { max-height: 56vh; overflow: auto; padding: 10px; border-radius: 12px; background: var(--ground); display: grid; gap: 4px; font-size: 12.5px; }
[data-theme='light'] .fs-body { background: var(--surface-2); }
.fs-body pre { margin: 0; padding: 8px 10px; border-radius: 8px; white-space: pre-wrap; word-break: break-word; font: inherit; line-height: 1.5; }
.fs-body pre.cli { background: var(--cli-bg); color: var(--cli); }
.fs-body pre.srv { background: var(--srv-bg); color: var(--srv); }
/* Estadísticas */
.st-p { display: grid; gap: 12px; outline: none; }
.io { width: 100%; height: auto; }
.io .gl { stroke: var(--surface-3); stroke-width: 1; }
.io .ax { font: 11px var(--font-mono); fill: var(--ink-3); }
.io .b-all { fill: var(--ink-4); opacity: 0.55; }
[data-theme='light'] .io .b-all { opacity: 0.8; }
.io .b-hit { fill: var(--accent); }
.lgd { display: inline-flex; align-items: center; gap: 6px; }
.lgd i { width: 12px; height: 12px; border-radius: 3px; }
.lgd.all i { background: var(--ink-4); }
.lgd.hit i { background: var(--accent); }
/* Búsqueda */
/* ---------- Avisos ---------- */
.toasts { position: fixed; z-index: 60; left: 50%; bottom: max(20px, env(safe-area-inset-bottom)); transform: translateX(-50%); display: grid; gap: 8px; justify-items: center; pointer-events: none; width: min(520px, calc(100% - 24px)); }
.toast { display: flex; align-items: center; gap: 10px; padding: 11px 16px; border-radius: 14px; background: var(--glass-thick); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: var(--sh-overlay); font-size: 14px; color: var(--ink); opacity: 0; transform: translateY(10px) scale(0.98); transition: opacity 0.2s var(--ease-out), transform 0.24s var(--ease-out); }
.toast.in { opacity: 1; transform: none; }
.toast.out { opacity: 0; transform: translateY(4px); transition-duration: 0.15s; }
.toast .i { color: var(--accent); }
.toast.ok { color: var(--ok); font-weight: 600; } .toast.ok .i { color: var(--ok); }
.toast.err { color: var(--bad); } .toast.err .i { color: var(--bad); }
.toast code { font-size: 12.5px; color: var(--ink); }
/* ---------- Movimiento reducido: solo fundidos ---------- */
@media (prefers-reduced-motion: reduce) {
*, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
.btn, .ibtn, .tbtn, .try, .opt, .choice, .mcard, .switch i, .toast, .tw .i { transition-property: opacity, background-color, color !important; }
.btn:active, .ibtn:active, .tbtn:active, .try:active, .opt:active, .choice:active, .mcard:active { transform: none !important; }
.toast { transform: none !important; }
}
@media (forced-colors: active) { .fbar, .card, .btn, .tinput, .pane { border: 1px solid CanvasText; } .pbody .prow[aria-selected='true'] { forced-color-adjust: none; background: Highlight; color: HighlightText; } }
/* ---------- Herramientas de análisis (src/app/40-dialogs.js) ---------- */
.tfmt { display: inline-flex; align-items: center; gap: 6px; }
.tfmt select { height: 26px; padding: 0 6px; border: 0; border-radius: 6px; background: var(--surface-2); color: var(--ink-2); font: inherit; }
.ex-sum { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 14px; }
.ex-chip { display: inline-flex; align-items: baseline; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: 12.5px; background: var(--surface-2); color: var(--ink-2); white-space: nowrap; }
.ex-chip strong { color: var(--ink); }
.ex-chip small { color: var(--ink-3); }
.ex-chip.sev-error { background: var(--bad-soft); color: var(--bad); }
.ex-chip.sev-warn { background: color-mix(in srgb, #f5c451 16%, transparent); color: light-dark(#7a5200, #f5c451); }
.ex-chip.sev-note { background: var(--accent-soft); color: var(--accent); }
.ex-chip.sev-error strong, .ex-chip.sev-warn strong, .ex-chip.sev-note strong { color: inherit; }
.ex-nos { display: flex; flex-wrap: wrap; gap: 4px; }
.ex-nos .btn.sm, .tbl td .btn.sm.mono { height: 28px; min-width: 32px; padding: 0 7px; }
.tbl.ex td.mono { font-size: 12.5px; word-break: break-word; }
.ob-prev { margin-top: 14px; }
.ob-prev pre { max-height: 260px; overflow: auto; padding: 12px 14px; border-radius: var(--r-ctl); background: var(--surface-2); font-size: 12.5px; white-space: pre-wrap; word-break: break-word; }
.fd { display: grid; gap: 10px; margin-top: 14px; }
.fd .row.wrap { flex-wrap: wrap; gap: 10px; }
.bad { color: var(--bad); }
@media (max-width: 760px) {
.tbl.ex td.mono { word-break: normal; overflow-wrap: anywhere; min-width: 14ch; }
.tbl.ex th:nth-child(3), .tbl.ex td:nth-child(3) { display: none; } /* el protocolo ya va en el mensaje */
}
/* ========== Armazón 1.3: barra lateral plegable, barra superior flotante y pestañas en el móvil ==========
Mismo lenguaje que BlueJr y RiskManager-Jr. Movimiento: muelle sin rebote al plegar, indicador que se desliza,
:active a 0,97 y entrada escalonada solo en la primera carga. Con movimiento reducido, sin desplazamientos. */
:root { --top-h: 80px; --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1); --hair: rgb(255 255 255 / 0.07); --hair-2: rgb(255 255 255 / 0.12); --sidebar: rgb(18 21 27 / 0.92); --tint: rgb(108 178 255 / 0.12); }
[data-theme='light'] { --hair: rgb(15 23 42 / 0.08); --hair-2: rgb(15 23 42 / 0.13); --sidebar: rgb(255 255 255 / 0.94); --tint: rgb(20 63 148 / 0.08); }
.app { --sw: 264px; display: grid; grid-template-columns: calc(var(--sw) + 12px) minmax(0, 1fr); min-height: 100dvh; transition: grid-template-columns 320ms var(--ease-drawer); }
body.side-mini .app { --sw: 68px; }
.col { min-width: 0; padding: 0 16px 40px; }
/* Lateral */
.side { --w: var(--sw); position: sticky; top: 0; z-index: 35; height: 100dvh; width: calc(var(--w) + 12px); padding: 12px 0 12px 12px; display: flex; flex-direction: column; overflow: hidden; transition: width 320ms var(--ease-drawer); }
.side::before { content: ''; position: absolute; inset: 12px 0 12px 12px; z-index: -1; border-radius: 24px; background: var(--sidebar); box-shadow: 0 0 0 1px var(--hair), var(--sh-panel); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%); transition: box-shadow 320ms var(--ease-out); }
.side > * { width: var(--w); transition: width 320ms var(--ease-drawer); }
body.side-mini .side:is(:hover, :focus-within) { --w: 264px; }
body.side-mini .side:is(:hover, :focus-within)::before { box-shadow: 0 0 0 1px var(--hair), var(--sh-overlay); }
body.side-mini .side :is(.txt, .cnt, .brand-txt, .lvl-txt) { opacity: 0; transition: opacity 140ms var(--ease-out); }
body.side-mini .side:is(:hover, :focus-within) :is(.txt, .cnt, .brand-txt, .lvl-txt) { opacity: 1; transition-delay: 90ms; }
.side-brand { display: flex; align-items: center; gap: 12px; padding: 18px 15px 12px; color: var(--ink); text-decoration: none; white-space: nowrap; }
.side-brand .logo, .brand-m .logo { display: block; width: 38px; height: 38px; border-radius: 22%; flex: none; object-fit: cover; background: #061a3d; box-shadow: 0 0 0 1px rgb(108 178 255 / 0.18), 0 6px 18px -8px rgb(6 26 61 / 0.7); } /* logo: baldosa azul marino en los dos temas */
.brand-txt { display: grid; min-width: 0; }
.brand-txt b { font-size: 17px; font-weight: 720; letter-spacing: -0.02em; }
.brand-txt small { font: 500 11px/1.3 var(--font-mono); letter-spacing: 0.06em; color: var(--ink-3); text-transform: uppercase; }
.side-nav { position: relative; flex: 1; padding: 6px 10px; overflow-y: auto; overflow-x: hidden; scrollbar-width: thin; }
.side-nav ul { list-style: none; margin: 2px 0 6px; padding: 0; }
.side-ind { position: absolute; left: 10px; right: 10px; top: 0; height: 40px; border-radius: 12px; background: var(--tint); opacity: 0; pointer-events: none; transition: transform 340ms var(--ease-out), height 340ms var(--ease-out), opacity 200ms; }
.side-ind::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--accent); }
.side-nav a { position: relative; display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 8px 12px; border-radius: 12px; color: var(--ink-2); text-decoration: none; font-weight: 550; font-size: 14.5px; white-space: nowrap; transition: background-color 180ms var(--ease-out), color 180ms var(--ease-out), transform 140ms var(--ease-out); }
.side-nav a:active { transform: scale(0.97); }
.side-nav a[aria-current='page'] { color: var(--ink); }
.side-nav a[aria-current='page'] > .i { color: var(--accent); }
.side-nav a.sub { min-height: 36px; padding-left: 13px; font-size: 13.5px; font-weight: 500; }
.side-nav .txt { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.side-nav .cnt { font: 500 12px var(--font-mono); color: var(--ink-3); }
.dotn { display: grid; place-items: center; width: 22px; height: 22px; flex: none; border-radius: 7px; border: 1.5px solid var(--ink-4); transition: transform 220ms var(--ease-out); }
.dotn b { font: 600 11px var(--font-mono); color: var(--ink-2); }
.dotn.mid { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 16%, transparent); }
.dotn.ok { border-color: var(--ok); background: color-mix(in srgb, var(--ok) 18%, transparent); }
@media (hover: hover) and (pointer: fine) {
.side-nav a:hover { background: color-mix(in srgb, var(--surface-2) 70%, transparent); color: var(--ink); }
.side-nav a:hover .dotn { transform: scale(1.12); }
}
body.ready .side-nav > a, body.ready .side-nav li { animation: none; }
.side-nav > a, .side-nav li { animation: side-in 300ms var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 25ms + 40ms); }
@keyframes side-in { from { opacity: 0; transform: translateX(-8px); } }
.side-foot { padding: 12px 10px 14px; border-top: 1px solid var(--hair); }
.lvl { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 12px; color: var(--ink); text-decoration: none; white-space: nowrap; transition: background-color 160ms var(--ease-out); }
.lvl:active { transform: scale(0.98); }
.lvl-ic { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: 11px; background: var(--ok-soft); color: var(--ok); }
.lvl-txt { display: grid; gap: 6px; min-width: 0; flex: 1; font-size: 13px; }
.lvl-txt b { font-weight: 650; overflow: hidden; text-overflow: ellipsis; }
.lvl.bump .lvl-ic { animation: bump 0.45s var(--spring); }
@media (hover: hover) and (pointer: fine) { .lvl:hover { background: var(--surface-2); } }
/* Barra superior flotante */
.top { position: sticky; top: 0; z-index: 30; padding-top: 12px; background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.top-in { display: flex; align-items: center; gap: 8px; height: auto; min-height: 56px; width: 100%; padding: 8px 10px; border-radius: 999px; background: var(--glass); box-shadow: 0 0 0 1px var(--hair), var(--sh-panel); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%); }
.top-in > :not(.grow) { flex-shrink: 0; }
.top .ibtn { border-radius: 50%; width: 40px; height: 40px; }
.brand-m { display: none; align-items: center; gap: 8px; color: var(--ink); text-decoration: none; font-weight: 720; letter-spacing: -0.02em; }
.brand-m .logo { width: 32px; height: 32px; }
.top .search-btn { min-width: 230px; width: auto; height: 40px; padding: 0 8px 0 14px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--hair-2); justify-content: flex-start; color: var(--ink-3); }
.top .search-btn .sb-t { flex: 1; text-align: left; display: inline; }
.top .search-btn kbd { display: inline-block; }
@media (hover: hover) and (pointer: fine) { .top .search-btn:hover { box-shadow: inset 0 0 0 1px var(--accent); } }
/* Interruptores del mismo tamaño: 80 × 40, relleno 3 y dos huecos de 36 × 32 */
.lang-sw { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--hair); }
.lang-sw button { min-width: 36px; height: 32px; border: 0; border-radius: 999px; background: none; color: var(--ink-3); font: 650 12px var(--font-mono); transition: background-color 200ms var(--ease-out), color 200ms var(--ease-out), box-shadow 200ms var(--ease-out); }
.lang-sw button[aria-pressed='true'] { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--hair-2), var(--sh-raise); }
.lang-sw button:active { transform: scale(0.94); }
/* Pestañas del móvil */
.tabbar { display: none; }
.more-list { display: grid; gap: 4px; }
.more-list a, .more-list button { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 14px; border: 0; border-radius: 14px; background: var(--surface-2); color: var(--ink); font: inherit; font-weight: 550; text-decoration: none; text-align: left; }
.more-list span { flex: 1; }
.more-list a:active, .more-list button:active { transform: scale(0.98); }
.hero { border-radius: 24px; margin-top: 14px; }
html { scroll-padding-top: calc(var(--top-h) + 16px); }
@media (max-width: 1100px) { .top .search-btn { min-width: 0; width: 40px; padding: 0; justify-content: center; } .top .search-btn .sb-t, .top .search-btn kbd { display: none; } }
@media (max-width: 900px) {
.app, body.side-mini .app { grid-template-columns: minmax(0, 1fr); }
.side, .only-desk { display: none !important; }
.brand-m { display: inline-flex; }
.col { padding: 0 max(12px, env(safe-area-inset-left)) calc(96px + env(safe-area-inset-bottom)); }
.top .search-btn { background: none; box-shadow: none; color: var(--ink-2); }
.tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom)); z-index: 40; padding: 6px; border-radius: 24px; background: var(--glass-thick); box-shadow: 0 0 0 1px var(--hair), var(--sh-overlay); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%); }
.tabbar a, .tabbar button { display: grid; justify-items: center; gap: 2px; min-height: 48px; padding: 7px 2px 5px; border: 0; border-radius: 18px; background: none; color: var(--ink-2); text-decoration: none; font: inherit; font-size: 11px; font-weight: 550; transition: background-color 200ms var(--ease-out), color 200ms var(--ease-out), transform 140ms var(--ease-out); }
.tabbar a:active, .tabbar button:active { transform: scale(0.94); }
.tabbar [aria-current='page'] { background: var(--tint); color: var(--ink); }
.tabbar [aria-current='page'] .i { color: var(--accent); }
.toasts { bottom: calc(96px + env(safe-area-inset-bottom)); }
.hero { margin-inline: -12px; border-radius: 0 0 24px 24px; margin-top: 10px; }
}
@media (max-width: 420px) { .brand-m b { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); } .top-in { gap: 4px; padding: 6px 8px; } }
@media (prefers-reduced-motion: reduce) {
.app, .side, .side > *, .side-ind, .theme-sw .knob { transition: none !important; }
.side-nav > a, .side-nav li { animation: none; }
}
/* ========== 1.4: interruptor de tema, buscador, perfil, «Acerca de» y portada sin barra ==========
El interruptor y el buscador se adaptan de Pin UI (MIT, © Rachit Thakur). */
/* Interruptor de tema: botón cuadrado; la luna en la cara clara, el sol en la oscura. Los dos giran en el mismo sentido */
.theme-sw { position: relative; display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 12px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--hair); color: var(--ink-2); cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent; transition: background-color 150ms ease; }
.theme-sw > span { grid-area: 1 / 1; display: grid; transition: transform 450ms var(--ease-out), opacity 220ms var(--ease-out); }
.theme-sw .i { width: 19px; height: 19px; }
.ts-moon { opacity: 1; transform: none; }
.ts-sun { opacity: 0; transform: rotate(90deg) scale(0.6); }
[data-theme='dark'] .ts-moon { opacity: 0; transform: rotate(-90deg) scale(0.6); }
[data-theme='dark'] .ts-sun { opacity: 1; transform: none; }
@media (hover: hover) and (pointer: fine) { .theme-sw:hover { background: var(--surface-3); color: var(--ink); } }
.theme-sw:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
/* Efecto: capa propia para la gota, las ondas y la lluvia (encima de todo y sin capturar el puntero).
Con View Transitions la capa es su propio grupo: así se sigue animando mientras el tema nuevo se revela debajo. */
.fx-layer { position: fixed; inset: 0; z-index: 2147483000; pointer-events: none; overflow: hidden; view-transition-name: mg-fx; contain: strict; }
.fx-drop { position: absolute; width: 22px; height: 30px; transform-origin: 50% 100%; will-change: transform; filter: drop-shadow(0 2px 3px rgb(0 0 0 / 0.25)); }
.fx-drop svg { display: block; width: 100%; height: 100%; overflow: visible; }
.fx-ripple { position: absolute; width: 40px; height: 40px; margin: -20px 0 0 -20px; border: 1.5px solid currentColor; border-radius: 50%; opacity: 0; }
.fx-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
html.fx-vt, html.fx-vt *, html.fx-vt *::before, html.fx-vt *::after { transition: none !important; } /* los colores los revela la inundación, no un fundido */
::view-transition-old(root), ::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
::view-transition-old(mg-fx) { display: none; }
::view-transition-new(mg-fx) { animation: none; }
::view-transition-group(mg-fx) { animation: none; z-index: 2; }
/* Portada: sin barra; los controles flotan sobre la ilustración */
body.is-home .col { position: relative; }
body.is-home .top { position: absolute; top: 0; left: 0; right: 0; z-index: 30; padding: 24px 16px 0; pointer-events: none; }
body.is-home .top-in { background: none; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; padding: 0 14px; pointer-events: none; }
body.is-home .top-in > * { pointer-events: auto; }
body.is-home .top :is(.ibtn, .search-btn, .lang-sw, .theme-sw) { background: rgb(6 16 34 / 0.48); color: #e8eef7; box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.14); -webkit-backdrop-filter: blur(14px) saturate(150%); backdrop-filter: blur(14px) saturate(150%); }
body.is-home .top .search-btn kbd { background: rgb(255 255 255 / 0.12); color: #e8eef7; box-shadow: none; }
body.is-home .top .lang-sw button { color: rgb(232 238 247 / 0.8); }
body.is-home .top .lang-sw button[aria-pressed='true'] { background: rgb(255 255 255 / 0.92); color: #0b1016; box-shadow: none; }
body.is-home .top .brand-m { color: #fff; }
@media (hover: hover) and (pointer: fine) { body.is-home .top :is(.ibtn, .search-btn, .theme-sw):hover { background: rgb(6 16 34 / 0.66); color: #fff; } }
body.is-home .hero { margin-top: 12px; }
body.is-home .hero-copy { padding-top: 112px; }
@media (max-width: 900px) { body.is-home .top { padding: 18px 2px 0; } body.is-home .top-in { padding: 0 8px; } body.is-home .hero { margin-top: 0; } body.is-home .hero-art { margin-top: 0; } }
@media (max-width: 760px) { body.is-home .hero-copy { padding-top: 0; } }
body.sc-open .top .search-btn { visibility: hidden; }
/* Buscador: tarjeta que nace de la píldora */
.scard { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: transparent; color: var(--ink); overflow: hidden; }
.scard::backdrop { background: rgb(4 8 14 / 0.38); -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); animation: fadeIn 0.3s var(--ease-out); }
.scard.closing::backdrop { animation: fadeOut 0.4s var(--ease-out) forwards; }
.sc-wrap { filter: drop-shadow(0 2px 6px rgb(0 0 0 / 0.18)) drop-shadow(0 24px 40px rgb(0 0 0 / 0.28)); }
[data-theme='light'] .sc-wrap { filter: drop-shadow(0 2px 6px rgb(15 23 42 / 0.08)) drop-shadow(0 24px 40px rgb(15 23 42 / 0.16)); }
.sc-card { position: absolute; left: var(--sc-l, 12px); top: var(--sc-t, 72px); width: var(--sc-w, 640px); max-height: calc(100dvh - var(--sc-t, 72px) - 16px); display: flex; flex-direction: column; padding: 6px; border-radius: 26px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--hair); }
.sc-bar { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 6px 0 16px; flex: none; }
.sc-glass { display: grid; color: var(--ink-3); }
.sc-input { flex: 1; min-width: 0; height: 100%; border: 0; background: transparent; color: var(--ink); font-size: 16px; outline: none; }
.sc-input::placeholder { color: var(--ink-3); }
.sc-x { display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 50%; background: var(--surface-2); color: var(--ink-2); transition: transform 160ms var(--ease-out), background-color 160ms; animation: scX 280ms var(--ease-out); }
.sc-x:active { transform: scale(0.88); }
@keyframes scX { from { opacity: 0; transform: scale(0.7) rotate(-45deg); } }
@media (hover: hover) and (pointer: fine) { .sc-x:hover { background: var(--surface-3); color: var(--ink); } }
.sc-body { display: flex; flex-direction: column; gap: 10px; min-height: 0; padding-top: 6px; }
.sc-panel { display: flex; flex-direction: column; min-height: 0; border-radius: 20px; background: var(--surface-2); padding: 4px 6px 6px; }
.sc-head { display: flex; align-items: center; justify-content: space-between; min-height: 40px; padding: 0 10px; }
.sc-label { font-size: 12.5px; font-weight: 650; color: var(--ink-3); }
.sc-act { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 10px; border: 0; border-radius: 99px; background: none; color: var(--ink-2); font-size: 12.5px; font-weight: 600; animation: fade 0.32s var(--ease-out); }
.sc-act:active { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) { .sc-act:hover { background: var(--surface-3); color: var(--ink); } }
.sc-listwrap { position: relative; display: flex; flex-direction: column; min-height: 0; overflow: hidden; border-radius: 14px; }
.sc-sheet { position: absolute; left: 0; right: 0; top: 0; z-index: 0; border-radius: 14px; background: var(--surface); box-shadow: var(--sh-raise); opacity: 0; pointer-events: none; transition: transform 240ms var(--ease-out), height 240ms var(--ease-out), opacity 180ms var(--ease-out); }
[data-theme='dark'] .sc-sheet { background: var(--surface-3); }
.sc-list { position: relative; z-index: 1; list-style: none; margin: 0; padding: 0; overflow: auto; overscroll-behavior: contain; max-height: min(52dvh, 460px); scrollbar-width: thin; }
.sc-row { position: relative; display: grid; grid-template-columns: 40px minmax(0, 1fr) auto auto; gap: 12px; align-items: center; min-height: 60px; padding: 8px 10px; border-radius: 14px; cursor: pointer; overflow: hidden; }
.sc-row + .sc-row::before { content: ''; position: absolute; top: 0; left: 62px; right: 12px; height: 1px; background: var(--hair); transition: opacity 160ms; }
.sc-row[aria-selected='true']::before, .sc-row[aria-selected='true'] + .sc-row::before { opacity: 0; }
.sc-tile { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; color: #fff; box-shadow: inset 0 1px 1px rgb(255 255 255 / 0.55), 0 6px 14px -7px var(--tg, rgb(0 0 0 / 0.5)); transition: transform 240ms var(--ease-out); }
.sc-tile .i { width: 19px; height: 19px; stroke-width: 2; }
.sc-row[aria-selected='true'] .sc-tile { transform: scale(1.05) translateY(-1px); }
.t-mod { background: linear-gradient(140deg, #c79bf3, #8b46e0); --tg: rgb(139 70 224 / 0.6); }
.t-les { background: linear-gradient(150deg, #7cc0ff, #2266e3); --tg: rgb(34 102 227 / 0.6); }
.t-task { background: linear-gradient(150deg, #ffc27a, #e9701f); --tg: rgb(233 112 31 / 0.6); }
.t-glo { background: linear-gradient(150deg, #8fe38a, #2f9e44); --tg: rgb(47 158 68 / 0.6); }
.t-flt { background: linear-gradient(150deg, #ff9aa8, #d6335a); --tg: rgb(214 51 90 / 0.6); }
.t-fld { background: linear-gradient(150deg, #6fe0d4, #0f8f86); --tg: rgb(15 143 134 / 0.6); }
.t-nav { background: linear-gradient(150deg, #a9b6c9, #4d5b70); --tg: rgb(77 91 112 / 0.6); }
.sc-t { display: grid; gap: 2px; min-width: 0; }
.sc-title, .sc-t small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sc-title { font-weight: 600; color: var(--ink); }
.sc-t small { color: var(--ink-3); font-size: 12.5px; }
.sc-k { font-size: 11px; font-weight: 650; letter-spacing: 0.04em; color: var(--ink-3); text-transform: uppercase; }
.sc-rm { position: relative; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; color: var(--ink-2); opacity: 0; transform: translateX(6px); transition: opacity 220ms var(--ease-out), transform 220ms var(--ease-out), background-color 160ms; }
.sc-row[aria-selected='true'] .sc-rm { opacity: 1; transform: none; }
.sc-rm:active { transform: scale(0.88); }
.sc-tip { position: absolute; right: calc(100% + 6px); top: 50%; padding: 4px 8px; border-radius: 7px; background: var(--ink); color: var(--surface); font-size: 12px; font-weight: 600; white-space: nowrap; opacity: 0; transform: translate(4px, -50%) scale(0.96); transform-origin: right center; pointer-events: none; transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .sc-rm:hover { background: var(--bad-soft); color: var(--bad); } .sc-rm:hover .sc-tip { opacity: 1; transform: translate(0, -50%); transition-delay: 250ms; } }
@media (hover: none) { .sc-rm { opacity: 0.85; transform: none; } }
.sc-empty { padding: 22px 12px; color: var(--ink-3); text-align: center; cursor: default; }
.sc-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 4px; }
.sc-chip { display: inline-flex; align-items: center; gap: 4px; height: 32px; padding: 0 12px 0 4px; border: 0; border-radius: 99px; color: #1c1c1c; font-size: 13px; font-weight: 600; white-space: nowrap; }
.sc-chip.lead { gap: 8px; padding: 0 12px 0 4px; background: var(--surface-2); color: var(--ink); box-shadow: inset 0 0 0 1px var(--hair); }
.sc-chip.lead:active { transform: scale(0.96); }
.sc-count { position: relative; display: grid; place-items: center; min-width: 24px; height: 24px; padding: 0 6px; overflow: hidden; border-radius: 99px; background: var(--ink); color: var(--surface); font: 650 12px var(--font-mono); }
.sc-count > span { grid-area: 1 / 1; }
.sc-cx { display: grid; place-items: center; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 50%; background: rgb(255 255 255 / 0.55); color: #1c1c1c; transition: transform 160ms var(--ease-out), background-color 160ms; }
.sc-cx .i { width: 13px; height: 13px; stroke-width: 2.4; }
.sc-cx:active { transform: scale(0.86); }
@media (hover: hover) and (pointer: fine) { .sc-cx:hover { background: rgb(255 255 255 / 0.9); } .sc-chip.lead:hover { background: var(--surface-3); } }
.c-mod { background: linear-gradient(90deg, #e2b6f5, #f1d8fa); }
.c-les { background: linear-gradient(90deg, #a8d3ff, #d3e8ff); }
.c-task { background: linear-gradient(90deg, #f7c76a, #fbe0a4); }
.c-glo { background: linear-gradient(90deg, #a9e2a0, #d4f2cd); }
.c-flt { background: linear-gradient(90deg, #ffb3bf, #ffd9df); }
.c-fld { background: linear-gradient(90deg, #95e6dc, #ccf3ee); }
.c-nav { background: linear-gradient(90deg, #c8d2e0, #e4e9f0); }
.sc-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 0 8px 6px; }
.sc-foot kbd { height: 20px; min-width: 20px; font-size: 11px; }
@media (max-width: 640px) { .sc-foot { display: none; } .sc-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; } .sc-k { display: none; } .sc-row { grid-template-columns: 40px minmax(0, 1fr) auto; } }
/* Avatares: iniciales sobre un degradado; blanco con contraste ≥ 4,5:1 en los seis colores */
.av { display: inline-grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: 11px; color: #fff; font: 700 13.5px/1 var(--font-sans); letter-spacing: 0.02em; box-shadow: inset 0 1px 1px rgb(255 255 255 / 0.35); }
.av .i { width: 18px; height: 18px; }
.av.xl { width: 88px; height: 88px; border-radius: 26px; font-size: 32px; letter-spacing: -0.01em; }
.av.xl .i { width: 38px; height: 38px; }
.av-azul { background: linear-gradient(150deg, #2563eb, #1e3a8a); }
.av-turquesa { background: linear-gradient(150deg, #0f766e, #134e4a); }
.av-verde { background: linear-gradient(150deg, #15803d, #14532d); }
.av-ambar { background: linear-gradient(150deg, #b45309, #78350f); }
.av-coral { background: linear-gradient(150deg, #be123c, #881337); }
.av-violeta { background: linear-gradient(150deg, #7c3aed, #4c1d95); }
/* Tarjeta de cuenta del lateral */
.acct { display: flex; align-items: center; gap: 10px; padding: 6px; margin-bottom: 6px; border-radius: 12px; color: var(--ink); text-decoration: none; white-space: nowrap; transition: background-color 160ms var(--ease-out), transform 140ms var(--ease-out); }
.acct:active { transform: scale(0.98); }
.acct-txt { display: grid; min-width: 0; flex: 1; font-size: 13px; }
.acct-txt b, .acct-txt small { overflow: hidden; text-overflow: ellipsis; }
.acct-txt b { font-weight: 650; }
.acct-txt small { color: var(--ink-3); font-size: 12px; }
.acct .acct-go { color: var(--ink-3); flex: none; }
.acct[aria-current='page'] { background: var(--tint); }
@media (hover: hover) and (pointer: fine) { .acct:hover { background: var(--surface-2); } }
body.side-mini .side :is(.acct-txt, .acct-go) { opacity: 0; transition: opacity 140ms var(--ease-out); }
body.side-mini .side:is(:hover, :focus-within) :is(.acct-txt, .acct-go) { opacity: 1; transition-delay: 90ms; }
.more-acct .av { width: 32px; height: 32px; font-size: 12px; }
.more-acct span { display: grid; }
.more-acct small { color: var(--ink-3); font-size: 12px; font-weight: 500; }
/* Perfil */
.pf-grid { display: grid; grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); gap: 20px; align-items: start; }
.pf-id { display: grid; gap: 22px; padding: 24px; }
.pf-hero { display: flex; align-items: center; gap: 18px; min-width: 0; }
.pf-who { display: grid; gap: 4px; min-width: 0; }
.pf-name { font-size: 24px; font-weight: 720; letter-spacing: -0.02em; line-height: 1.15; overflow-wrap: anywhere; }
.pf-line { color: var(--ink-2); overflow-wrap: anywhere; }
.pf-lv { display: inline-flex; align-items: center; gap: 6px; width: max-content; margin-top: 4px; padding: 3px 10px 3px 8px; border-radius: 99px; background: var(--ok-soft); color: var(--ok); font-size: 12.5px; font-weight: 650; }
.pf-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0; }
.pf-stats > div { padding: 12px; border-radius: 14px; background: var(--surface-2); }
.pf-stats dt { font-size: 12px; color: var(--ink-3); font-weight: 600; }
.pf-stats dd { margin: 2px 0 0; font-size: 22px; font-weight: 720; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.pf-stats dd small { font-size: 13px; color: var(--ink-3); font-weight: 600; }
.pf-id h3 { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; font-size: 14px; }
.pf-id h3 .i { color: var(--accent); }
.hm { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 1fr); gap: 3px; width: max-content; max-width: 100%; }
.hm-c { width: 13px; height: 13px; border-radius: 3.5px; background: var(--surface-3); }
.hm .hm-c { animation: hmIn 360ms var(--ease-out) backwards; animation-delay: calc(var(--d, 0) * 3ms); }
@keyframes hmIn { from { opacity: 0; transform: scale(0.6); } }
.hm-c.l1 { background: color-mix(in srgb, var(--accent) 35%, var(--surface-3)); }
.hm-c.l2 { background: color-mix(in srgb, var(--accent) 58%, var(--surface-3)); }
.hm-c.l3 { background: color-mix(in srgb, var(--accent) 80%, var(--surface-3)); }
.hm-c.l4 { background: var(--accent); }
.hm-leg { display: flex; align-items: center; gap: 3px; margin-top: 8px; font-size: 11.5px; color: var(--ink-3); }
.hm-leg span:first-child { margin-right: 4px; } .hm-leg span:last-child { margin-left: 4px; }
.pf-hm-sum { margin-top: 6px; }
.pf-badges ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 6px; }
.pf-badges li { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 12px; background: var(--surface-2); color: var(--ink-3); font-size: 13px; font-weight: 550; }
.pf-badges li.got { color: var(--ink); }
.pf-bic { display: grid; place-items: center; width: 26px; height: 26px; flex: none; border-radius: 8px; background: var(--surface-3); }
.pf-badges li.got .pf-bic { background: var(--ok-soft); color: var(--ok); }
.pf-form { display: grid; gap: 20px; padding: 24px; }
.pf-form h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.pf-form h2 .i { color: var(--accent); }
.fld { display: grid; gap: 8px; margin: 0; padding: 0; border: 0; min-width: 0; }
.fld > label, .fld > legend { padding: 0; font-weight: 650; font-size: 14px; }
.fld[hidden] { display: none; }
.fld .tinput { height: 44px; width: 100%; }
select.tinput { appearance: none; padding-right: 36px; background-image: linear-gradient(45deg, transparent 50%, var(--ink-3) 50%), linear-gradient(135deg, var(--ink-3) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; cursor: pointer; }
.pchips { display: flex; flex-wrap: wrap; gap: 6px; }
.pchip { position: relative; display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border-radius: 99px; background: var(--surface-2); color: var(--ink-2); font-size: 13.5px; font-weight: 600; cursor: pointer; transition: background-color 180ms var(--ease-out), color 180ms, box-shadow 180ms, transform 140ms var(--ease-out); }
.pchip input, .sw-c input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.pchip:active { transform: scale(0.97); }
.pchip:has(input:checked) { background: var(--accent); color: var(--accent-ink); box-shadow: var(--sh-raise); }
.pchip:has(input:focus-visible), .sw-c:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (hover: hover) and (pointer: fine) { .pchip:hover:not(:has(input:checked)) { background: var(--surface-3); color: var(--ink); } }
.swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.sw-c { position: relative; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; }
.sw-dot { width: 30px; height: 30px; border-radius: 50%; transition: transform 200ms var(--ease-out), box-shadow 200ms; }
.sw-c:has(input:checked) .sw-dot { box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--ink); transform: scale(0.92); }
.sw-c:active .sw-dot { transform: scale(0.88); }
.pf-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.pf-saved { display: inline-flex; align-items: center; gap: 6px; min-height: 24px; color: var(--ok); font-weight: 600; opacity: 0; transform: translateY(2px); transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out); }
.pf-saved.on { opacity: 1; transform: none; }
@media (max-width: 1023px) { .pf-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) { .pf-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } .pf-hero { flex-direction: column; align-items: flex-start; } .hm-c { width: 11px; height: 11px; } }
/* Acerca de */
.about h1 .ver { display: inline-block; vertical-align: middle; margin-left: 8px; padding: 3px 10px; border-radius: 99px; background: var(--accent-soft); color: var(--accent); font-size: 14px; font-weight: 650; letter-spacing: 0; }
.author { display: flex; gap: 22px; align-items: center; padding: 26px; }
.author h2 { font-size: 24px; letter-spacing: -0.02em; margin: 2px 0 4px; }
.au-txt { display: grid; gap: 2px; min-width: 0; }
.au-links { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 14px 0 0; padding: 0; }
.i.brand { stroke: none; }
.eco-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 14px; }
.eco { display: flex; flex-direction: column; gap: 10px; padding: 20px; border-radius: var(--r-card); background: var(--surface); box-shadow: var(--sh-panel); transition: transform 200ms var(--ease-out), box-shadow 200ms var(--ease-out); }
.eco.here { box-shadow: 0 0 0 2px var(--accent), var(--sh-panel); }
.eco-h { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.eco-h h3 { font-size: 17px; letter-spacing: -0.01em; }
.eco-ic { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 12px; background: var(--accent-soft); color: var(--accent); }
.eco-here { display: inline-flex; align-items: center; gap: 4px; margin-left: auto; padding: 3px 10px 3px 8px; border-radius: 99px; background: var(--accent); color: var(--accent-ink); font-size: 12px; font-weight: 700; }
.eco p { color: var(--ink-2); font-size: 14px; flex: 1; }
.eco-a { display: flex; flex-wrap: wrap; gap: 8px; }
@media (hover: hover) and (pointer: fine) { .eco:hover { transform: translateY(-2px); box-shadow: var(--sh-overlay); } .eco.here:hover { box-shadow: 0 0 0 2px var(--accent), var(--sh-overlay); } }
.about-2 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 56px; }
.about-2 h2 { display: flex; align-items: center; gap: 8px; font-size: 16px; margin-bottom: 8px; }
.about-2 h2 .i { color: var(--accent); }
.about-2 p, .ab-list { color: var(--ink-2); font-size: 14px; }
.ab-list { margin: 0; padding-left: 18px; display: grid; gap: 4px; }
@media (max-width: 1023px) { .about-2 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .author { flex-direction: column; align-items: flex-start; } }
/* Hoja inferior del móvil: sale desde abajo con la curva de los cajones y se cierra arrastrando */
@media (max-width: 900px) {
.dlg.sheet { width: 100%; max-width: none; margin: auto 0 0; }
.dlg.sheet .dlg-in { border-radius: 24px 24px 0 0; padding-bottom: env(safe-area-inset-bottom); touch-action: none; }
.dlg.sheet .dlg-in::before { content: ''; display: block; width: 38px; height: 5px; margin: 8px auto 0; border-radius: 99px; background: var(--ink-4); }
.dlg.sheet[open] .dlg-in { animation: sheetIn 0.42s cubic-bezier(0.32, 0.72, 0, 1); }
.dlg.sheet.closing .dlg-in { animation: sheetOut 0.2s cubic-bezier(0.32, 0.72, 0, 1) forwards; }
}
@keyframes sheetIn { from { transform: translateY(100%); } }
@keyframes sheetOut { to { transform: translateY(100%); } }
@media (prefers-reduced-motion: reduce) {
.theme-sw > span { transition: opacity 200ms ease; transform: none !important; }
.sc-sheet, .sc-rm, .sc-tile, .sc-tip { transition: opacity 120ms !important; transform: none !important; }
.sc-x, .sc-act, .hm .hm-c { animation: none; }
.dlg.sheet[open] .dlg-in, .dlg.sheet.closing .dlg-in { animation: none; }
}
@media (forced-colors: active) { .sc-card, .eco, .pf-stats > div { border: 1px solid CanvasText; } .sc-row[aria-selected='true'] { outline: 2px solid Highlight; } }
.more-list .more-acct .av { flex: none; }
.about section > .sec-h.sub { margin-top: 56px; }
@media (max-width: 760px) { .about section > .sec-h.sub { margin-top: 40px; } }