/* ===== Nou Codi — identidad nou_codi▌ (papel, tinta y cursor azul) ===== */
:root {
  /* Fondo claro (papel) */
  --bg: #F7F6F2;
  --bg-2: #EFEDE6;
  --surface: #FFFFFF;
  --text: #0F1115;
  --text-2: #3B4049;
  --muted: #5C616B;
  --faint: #6B7079;
  --line: rgba(15,17,21,.09);
  --line-2: rgba(15,17,21,.16);
  --tint: rgba(15,17,21,.025);
  --tint-2: rgba(15,17,21,.05);
  /* Azul del cursor */
  --accent: #2B50FF;
  --accent-hover: #1E3FE8;
  --accent-text: #2B50FF;
  --accent-soft: rgba(43,80,255,.07);
  --accent-line: rgba(43,80,255,.32);
  --ok: #0E8A5E;
  --ok-soft: rgba(14,138,94,.08);
  --ok-line: rgba(14,138,94,.3);
  --crit: #C23636;
  --high: #A8600E;
  --warn-soft: rgba(168,96,14,.08);
  --shadow: 0 1px 2px rgba(15,17,21,.04), 0 12px 32px -12px rgba(15,17,21,.12);
  --radius: 12px;
  --sans: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

/* Zonas oscuras (tinta): mismas piezas, colores invertidos */
.ink {
  --bg: #0F1115;
  --bg-2: #0F1115;
  --surface: #171A21;
  --text: #EDEEF0;
  --text-2: #C3C7CF;
  --muted: #979CA7;
  --faint: #6A707C;
  --line: rgba(255,255,255,.08);
  --line-2: rgba(255,255,255,.14);
  --tint: rgba(255,255,255,.03);
  --tint-2: rgba(255,255,255,.06);
  --accent-text: #8DA2FF;
  --accent-soft: rgba(43,80,255,.16);
  --accent-line: rgba(141,162,255,.4);
  --ok: #4CC79A;
  --ok-soft: rgba(76,199,154,.1);
  --ok-line: rgba(76,199,154,.35);
  --crit: #F08A8A;
  --high: #E8B57A;
  --warn-soft: rgba(232,181,122,.1);
  --shadow: none;
  color-scheme: dark;
  background: var(--bg);
  color: var(--text);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { font-family: var(--sans); background: var(--bg); color: var(--text); line-height: 1.65; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
a { color: inherit; }
.hidden { display: none; }
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(1160px, 100% - 48px); margin-inline: auto; }
.narrow { width: min(740px, 100% - 48px); }
.mono { font-family: var(--mono); }
.small { font-size: .875rem; }
.muted { color: var(--muted); }
.center { text-align: center; }

h1, h2, h3, h4 { color: var(--text); }
h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); line-height: 1.04; letter-spacing: -.045em; font-weight: 700; }
h2 { font-size: clamp(1.85rem, 3.5vw, 2.8rem); line-height: 1.1; letter-spacing: -.035em; font-weight: 700; margin-bottom: 1.25rem; max-width: 780px; }
h3 { font-size: 1.08rem; letter-spacing: -.015em; font-weight: 600; margin-bottom: .4rem; }
h4 { font-weight: 600; letter-spacing: -.01em; }
.lead { font-size: clamp(1.05rem, 1.5vw, 1.2rem); color: var(--muted); max-width: 620px; }
.eyebrow { font-family: var(--mono); color: var(--accent-text); font-size: .8rem; font-weight: 500; margin-bottom: 1rem; }

/* Logo: nou_codi▌ */
.logo { font-family: var(--mono); font-weight: 700; font-size: 1.2rem; letter-spacing: -.03em; text-decoration: none; color: var(--text); white-space: nowrap; }
.cursor, .caret { display: inline-block; width: .55em; height: .9em; margin-left: .08em; vertical-align: -.1em; background: var(--accent-text); }
.caret { animation: blink 1.1s steps(1) infinite; }
.caret-fixed { animation: none; }
.caret { width: .5em; height: 1.05em; vertical-align: -.2em; margin-left: 0; }
h1 .caret, h2 .caret { width: .42em; height: .8em; vertical-align: -.06em; margin-left: .12em; }
@keyframes blink { 50% { opacity: 0; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; background: var(--accent); color: #fff; text-decoration: none;
  padding: .85rem 1.4rem; border-radius: 8px; border: 1px solid transparent; cursor: pointer;
  font-family: var(--mono); font-size: .9rem; font-weight: 600; letter-spacing: -.01em; line-height: 1.3;
  transition: background .2s, border-color .2s, transform .2s; }
.btn:hover { background: var(--accent-hover); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .6; cursor: progress; }
.btn-sm { padding: .5rem .95rem; font-size: .82rem; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line-2); }
.btn-ghost:hover { background: var(--tint-2); }
.btn-block { display: flex; width: 100%; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 10; background: rgba(247,246,242,.86); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 66px; gap: 1rem; }
.nav-links { display: flex; gap: 1.6rem; }
.nav-links a { text-decoration: none; font-size: .92rem; color: var(--muted); transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: .75rem; }
.nav-actions > a.small { color: var(--muted); text-decoration: none; }
.nav-actions > a.small:hover { color: var(--text); }
.lang { display: inline-flex; align-items: center; gap: .45rem; font-family: var(--mono); background: none; border: 1px solid var(--line-2); border-radius: 8px; padding: .35rem .65rem; cursor: pointer; font-size: .78rem; color: var(--text); text-decoration: none; }
.lang:hover { background: var(--tint-2); }
.lang img { width: 18px; height: 12px; border-radius: 2px; object-fit: cover; }
.menu-toggle { display: none; width: 40px; height: 36px; background: none; border: 1px solid var(--line-2); border-radius: 8px; cursor: pointer; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.menu-toggle span { width: 16px; height: 1.5px; background: var(--text); transition: transform .2s; }
.menu-open .menu-toggle span:first-child { transform: translateY(3.25px) rotate(45deg); }
.menu-open .menu-toggle span:last-child { transform: translateY(-3.25px) rotate(-45deg); }

/* Hero */
.hero { position: relative; overflow: hidden; padding: clamp(4rem, 10vw, 7.5rem) 0 clamp(4rem, 8vw, 6.5rem); }
.hero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--line-2) 1px, transparent 1px); background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 80% 30%, #000, transparent 70%); mask-image: radial-gradient(ellipse 70% 80% at 80% 30%, #000, transparent 70%); }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: 3.5rem; align-items: center; }
.hero .lead { margin: 1.5rem 0 2rem; }
.hero-cta { display: flex; gap: .75rem; flex-wrap: wrap; }
.price-note { margin-top: 2rem; font-size: .82rem; color: var(--muted); display: flex; align-items: center; gap: .45rem; flex-wrap: wrap; }
.price-note strong { color: var(--text); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px var(--ok-soft); }

/* Ventana de terminal */
.hero-panel { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line-2); box-shadow: 0 30px 60px -30px rgba(15,17,21,.45); }
.panel-bar { display: flex; align-items: center; gap: .4rem; padding: .75rem 1rem; border-bottom: 1px solid var(--line); background: var(--surface); }
.panel-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--tint-2); }
.panel-bar p { margin-left: auto; font-size: .72rem; color: var(--muted); }
.panel-body { padding: 1.3rem 1.3rem 1.45rem; font-size: .84rem; display: grid; gap: .6rem; }
.ln { display: flex; justify-content: space-between; gap: 1rem; color: var(--muted); opacity: 0; animation: fade .5s forwards; }
.ln:nth-child(1) { animation-delay: .2s; } .ln:nth-child(2) { animation-delay: .6s; } .ln:nth-child(3) { animation-delay: .9s; }
.ln:nth-child(4) { animation-delay: 1.2s; } .ln:nth-child(5) { animation-delay: 1.6s; } .ln:nth-child(6) { animation-delay: 1.9s; }
.ln:first-child, .ln:last-child { justify-content: flex-start; gap: .6rem; color: var(--text); }
.ln.ok span::before { content: "✓ "; color: var(--ok); }
.ln b { color: var(--text); font-weight: 600; }
.ln.res { margin-top: .4rem; padding-top: .85rem; border-top: 1px solid var(--line); }
.ln.res span::before { content: "→ "; color: var(--accent-text); }
.ln.res b { color: var(--accent-text); }
.prompt { color: var(--accent-text); }

/* Secciones */
.section { padding: clamp(4.5rem, 9vw, 7rem) 0; border-top: 1px solid var(--line); }
.section-soft { background: var(--bg-2); }
.section.ink { border-top-color: transparent; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 3.5rem; align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 1rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-top: 1rem; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.6rem; transition: border-color .25s, box-shadow .25s; }
.card:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.card p { color: var(--muted); }
.card .num { font-family: var(--mono); color: var(--accent-text); font-size: .8rem; font-weight: 500; margin-bottom: 1rem; }
.card .num::after { content: "_"; color: var(--faint); }
.card-head { display: flex; align-items: center; gap: .75rem; margin-bottom: .6rem; }
.card-head h3 { margin: 0; }
.ico { flex: none; width: 34px; height: 34px; padding: 6px; border-radius: 8px; background: var(--accent-soft); fill: none; stroke: var(--accent-text); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* Auditoría */
.audit-grid { margin-top: 3rem; align-items: center; }
.checklist { list-style: none; display: grid; gap: 1.4rem; }
.checklist li { padding-left: 2rem; position: relative; }
.checklist li::before { content: "✓"; position: absolute; left: 0; top: 0; font-family: var(--mono); color: var(--accent-text); font-weight: 700; }
.checklist strong { display: block; font-weight: 600; }
.checklist span { color: var(--muted); }

.price-card { border-radius: var(--radius); padding: 2.1rem; display: grid; gap: .5rem; background: var(--surface); border: 1px solid var(--line-2); box-shadow: 0 30px 60px -30px rgba(15,17,21,.45); }
.price-label { color: var(--accent-text); }
.price-card .price { font-family: var(--mono); font-size: 3.4rem; font-weight: 700; letter-spacing: -.05em; line-height: 1.05; margin-bottom: .5rem; }
.price-card .price small { font-family: var(--sans); font-size: .95rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.price-card s { color: var(--faint); }
.price-rise { margin-top: .75rem; padding: .8rem 1rem; border-radius: 8px; background: var(--tint); border: 1px solid var(--line); color: var(--muted); }
.price-rise b { color: var(--text); white-space: nowrap; }
.price-terms { list-style: none; display: grid; gap: .5rem; color: var(--muted); margin-top: .25rem; }
.price-terms li { padding-left: 1.4rem; position: relative; }
.price-terms li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); }
.price-card .btn { margin: 1rem 0 .25rem; }

/* Muestra del informe */
.report { position: relative; margin-top: 2.5rem; max-width: 1040px; background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--radius); padding: clamp(1.25rem, 3vw, 2.1rem); box-shadow: var(--shadow); }
.report-head { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; font-size: .76rem; letter-spacing: .04em; padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.report-tabs { display: flex; gap: .4rem; flex-wrap: wrap; padding: 1.1rem 0; border-bottom: 1px solid var(--line); }

/* Pestañas y filtros: mismo estilo en la muestra y en los casos de uso */
.report-tabs button, .filters button { font-family: var(--mono); font-size: .82rem; font-weight: 500; color: var(--text-2); background: var(--surface);
  border: 1px solid var(--line-2); border-radius: 8px; padding: .55rem 1rem; cursor: pointer; box-shadow: 0 1px 0 var(--line);
  transition: color .2s, border-color .2s, background .2s, transform .2s; }
.report-tabs button:hover, .filters button:hover { color: var(--text); border-color: var(--text); }
.report-tabs button:active, .filters button:active { transform: translateY(1px); }
.report-tabs button[aria-selected="true"], .filters button[aria-pressed="true"] { color: var(--bg); background: var(--text); border-color: var(--text); box-shadow: none; }
.report-panel { padding-top: .5rem; min-height: 240px; animation: fade .3s ease; }
.report.equal .report-panel { height: var(--panel-h); overflow: hidden; -webkit-mask-image: linear-gradient(to bottom, #000 82%, transparent); mask-image: linear-gradient(to bottom, #000 82%, transparent); }
.report.equal #r-road { -webkit-mask-image: none; mask-image: none; }
.report-panel > p { margin-top: .75rem; color: var(--muted); }
.blur { filter: blur(6px); user-select: none; }
.report-rows { list-style: none; }
.report-rows li { display: grid; grid-template-columns: 2.5rem 1fr auto; gap: 1rem; align-items: center; padding: .95rem 0; border-bottom: 1px solid var(--line); }
.report-rows li:last-child { border-bottom: 0; }
.report-rows .mono { color: var(--accent-text); font-size: .8rem; }
.report-rows span { color: var(--text-2); }
.report-rows em { font-style: normal; font-family: var(--mono); font-size: .72rem; color: var(--muted); padding: .18rem .55rem; border: 1px solid var(--line-2); border-radius: 6px; white-space: nowrap; }
.report-score { display: flex; justify-content: space-between; align-items: center; padding: 1rem 0; color: var(--muted); border-bottom: 1px solid var(--line); }
.report-score b { font-family: var(--mono); color: var(--text); font-size: 1.4rem; letter-spacing: -.03em; }
.sev-crit { color: var(--crit) !important; border-color: currentColor !important; }
.sev-high { color: var(--high) !important; border-color: currentColor !important; }
.report-lock { margin-top: 1rem; padding: 1.2rem; border-radius: 10px; background: var(--accent-soft); border: 1px dashed var(--accent-line);
  display: flex; gap: 1rem; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.report-lock p { max-width: 540px; color: var(--text-2); }

/* Oportunidad (como en el informe real) */
.op { border: 1px solid var(--line-2); border-radius: 10px; padding: 1.25rem 1.35rem; margin-top: 1rem; background: var(--tint); }
.op-top { display: flex; align-items: flex-start; gap: .7rem; }
.op h4 { font-size: 1.05rem; line-height: 1.35; }
.op-paso { font-family: var(--mono); font-size: .76rem; color: var(--muted); margin-top: .35rem; }
.op-desc { margin: .6rem 0 1rem; color: var(--text-2); font-size: .95rem; }
.op-cifras { display: grid; grid-template-columns: repeat(5, 1fr); gap: .6rem; }
.op-cifras > div { display: flex; flex-direction: column; gap: .15rem; padding: .75rem .85rem; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.op-cifras .hl { border-color: var(--accent-line); background: var(--accent-soft); }
.op-cifras b { font-size: 1.05rem; color: var(--text); }
.op-cifras small { font-size: .72rem; color: var(--muted); }
.op-etq { font-family: var(--mono); font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.dots { display: flex; gap: 3px; margin-top: .2rem; }
.dots i { width: 8px; height: 8px; border-radius: 2px; background: var(--tint-2); border: 1px solid var(--line); }
.dots i.on { background: var(--accent-text); border-color: transparent; }
.op-aviso { margin: 1rem 0; padding: .7rem 1rem; border-left: 3px solid var(--high); background: var(--warn-soft); border-radius: 6px; font-size: .88rem; color: var(--text-2); }
.op-aviso b { color: var(--text); }
.op-extra { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; font-size: .84rem; color: var(--muted); }
.op-extra ul { padding-left: 1rem; margin-top: .3rem; }

/* Resumen: beneficios y tablas */
.bf-title { display: block; margin: 1.25rem 0 .75rem; }
.bf { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; }
.bf > div { display: flex; flex-direction: column; gap: .25rem; padding: 1rem; border: 1px solid var(--line); border-radius: 8px; background: var(--tint); }
.bf b { font-family: var(--mono); font-size: clamp(1.2rem, 2.2vw, 1.55rem); letter-spacing: -.04em; line-height: 1.15; color: var(--text); margin-top: .2rem; }
.bf strong { font-size: .86rem; font-weight: 500; color: var(--text-2); }
.bf-note { font-size: .8rem; color: var(--muted); margin: .75rem 0 0; }
.rep-h { font-size: 1rem; margin: 1.75rem 0 .6rem; }
.rep-table { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; }
.rep-table table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.rep-table th { font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; text-align: center; padding: .7rem .8rem; border-bottom: 1px solid var(--line); background: var(--tint); }
.rep-table td { padding: .75rem .8rem; border-bottom: 1px solid var(--line); text-align: center; color: var(--text-2); }
.rep-table td:first-child { text-align: left; }
.rep-table tr:last-child td { border-bottom: 0; }
.rep-table td b { color: var(--text); }
.rep-table td small { color: var(--muted); }

/* Hoja de ruta (Gantt) */
.rm-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; padding: 1.25rem 0 1rem; }
.rm-kpis > div { display: flex; flex-direction: column; padding: 1rem; border: 1px solid var(--line); border-radius: 8px; background: var(--tint); }
.rm-kpis b { font-family: var(--mono); font-size: clamp(1.3rem, 2.8vw, 1.75rem); letter-spacing: -.04em; color: var(--text); }
.rm-kpis span { font-size: .88rem; font-weight: 600; }
.rm-kpis small { font-size: .76rem; color: var(--muted); }
.gantt { border: 1px solid var(--line); border-radius: 8px; padding: 1rem 1.1rem; }
.g-fase + .g-fase { margin-top: 1rem; }
.g-cab { display: flex; justify-content: space-between; gap: .5rem; font-size: .84rem; margin-bottom: .4rem; }
.g-cab b { font-weight: 600; }
.g-cab span { font-family: var(--mono); color: var(--muted); font-size: .72rem; white-space: nowrap; }
.g-fila { display: grid; grid-template-columns: minmax(140px, 36%) 1fr; gap: .75rem; align-items: center; min-height: 22px; }
.g-etq { font-size: .78rem; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-pista { position: relative; height: 10px; border-radius: 3px; background: var(--tint-2); }
.g-pista i { position: absolute; top: 0; bottom: 0; border-radius: 3px; min-width: 10px; }
.f0 .g-pista i { background: var(--text); }
.f1 .g-pista i { background: var(--accent); }
.f2 .g-pista i { background: var(--ok); }
.g-fila.blur, .g-fase.blur { filter: blur(5px); }

/* Casos de uso */
.filters { display: flex; gap: .4rem; flex-wrap: wrap; margin: 2rem 0 1.25rem; }
.cases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.case { display: flex; flex-direction: column; gap: .5rem; padding: 1.4rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .25s, box-shadow .25s; }
.case:hover { border-color: var(--line-2); box-shadow: var(--shadow); }
.case[hidden] { display: none; }
.case h3 { margin: 0; }
.case p { color: var(--muted); font-size: .93rem; }
.case .tag { align-self: flex-start; font-family: var(--mono); font-size: .7rem; color: var(--accent-text); padding: .15rem .55rem; background: var(--accent-soft); border-radius: 4px; }
.case-for { margin-top: auto; padding-top: .6rem; border-top: 1px solid var(--line); font-size: .82rem !important; }
.case-for span:first-child { color: var(--text); font-weight: 500; }
.case-you { border-style: dashed; border-color: var(--accent-line); background: var(--accent-soft); }
.case-you .tag { background: var(--surface); }
.case-link { margin-top: auto; padding-top: .6rem; font-family: var(--mono); color: var(--accent-text); font-weight: 600; text-decoration: none; font-size: .86rem; }
.case-link:hover { text-decoration: underline; text-underline-offset: 3px; }

.impl-note { margin-top: 1.5rem; padding: 1.3rem 1.5rem; border-radius: 0 var(--radius) var(--radius) 0; background: var(--surface); border: 1px solid var(--line); border-left: 3px solid var(--accent); }
.impl-note span { color: var(--muted); }

/* Pasos */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; margin-top: 2.5rem; counter-reset: paso; }
.steps li { border-top: 2px solid var(--line-2); padding-top: 1.1rem; transition: border-color .3s; }
.steps li:hover { border-top-color: var(--accent); }
.steps .mono { display: block; color: var(--accent-text); font-size: .8rem; font-weight: 500; margin-bottom: .8rem; }
.steps p { color: var(--muted); }

/* Equipo */
.team { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2.5rem; }
.person { display: flex; flex-direction: column; gap: 1.1rem; padding: 1.75rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.person-head { display: flex; align-items: center; gap: 1rem; }
.person h3 { font-size: 1.2rem; margin: 0; }
.person .role { font-size: .78rem; color: var(--accent-text); }
.person > p { color: var(--muted); }
.facts { list-style: none; display: flex; flex-wrap: wrap; gap: .6rem; margin-top: auto; padding-top: 1.1rem; border-top: 1px solid var(--line); }
.facts li { flex: 1 1 120px; display: flex; flex-direction: column; gap: .1rem; padding: .7rem .85rem; border: 1px solid var(--line); border-radius: 8px; background: var(--tint); }
.facts b { font-family: var(--mono); font-size: 1.15rem; white-space: nowrap; letter-spacing: -.04em; color: var(--text); }
.team-close { display: flex; align-items: center; justify-content: space-between; gap: 1.25rem 1.75rem; flex-wrap: wrap; margin-top: 1rem; padding: 1.75rem 2rem;
  border-radius: var(--radius); background: var(--accent-soft); border: 1px solid var(--accent-line); }
.team-close p { flex: 1 1 420px; font-size: 1rem; font-weight: 500; color: var(--text); line-height: 1.55; }
.facts span { font-size: .78rem; color: var(--muted); line-height: 1.4; }
.avatar { flex: none; width: 72px; height: 72px; border-radius: 20px; display: flex; align-items: center; justify-content: center; font-family: var(--mono); font-weight: 700; font-size: 1.3rem; letter-spacing: -.03em;
  background: #0F1115; color: #F7F6F2; }
.avatar::after { content: ""; display: inline-block; width: .5em; height: .85em; margin-left: .06em; vertical-align: -.08em; background: #8DA2FF; }

/* FAQ */
details { border-bottom: 1px solid var(--line-2); padding: 1.25rem 0; }
summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
summary::-webkit-details-marker { display: none; }
summary:hover { color: var(--accent-text); }
summary::after { content: "+"; font-family: var(--mono); color: var(--muted); transition: transform .2s; }
details[open] summary::after { transform: rotate(45deg); color: var(--accent-text); }
details p { color: var(--muted); margin-top: .75rem; }

/* Formulario */
.form { display: grid; gap: 1rem; margin-top: 2rem; padding: clamp(1.25rem, 3vw, 2rem); background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--radius); }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form label { display: grid; gap: .4rem; font-size: .88rem; color: var(--text-2); }
.form input, .form select, .form textarea { font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--line-2); border-radius: 8px; padding: .8rem 1rem; transition: border-color .2s, box-shadow .2s; }
.form input::placeholder, .form textarea::placeholder { color: var(--faint); }
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--accent-text); box-shadow: 0 0 0 3px var(--accent-soft); }
.form .check { display: flex; gap: .6rem; align-items: start; }
.form .check input { margin-top: .3rem; accent-color: var(--accent); }
.form a { color: var(--accent-text); }
.form-msg { min-height: 1.5rem; text-align: center; font-family: var(--mono); font-size: .86rem; }

/* Selector de país */
.combo { position: relative; }
.combo input { width: 100%; padding-right: 2.5rem; }
.combo::after { content: ""; position: absolute; right: 1rem; top: 50%; width: 7px; height: 7px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.combo-list { position: absolute; z-index: 5; top: calc(100% + 6px); left: 0; right: 0; max-height: 260px; overflow-y: auto; list-style: none; padding: .35rem; margin: 0;
  background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; box-shadow: 0 20px 50px rgba(0,0,0,.4); }
.combo-list li { padding: .55rem .75rem; border-radius: 6px; cursor: pointer; color: var(--text-2); font-size: .92rem; }
.combo-list li[aria-selected="true"], .combo-list li:hover { background: var(--accent-soft); color: var(--text); }
.combo-list .empty { color: var(--muted); cursor: default; background: none !important; }

/* Páginas legales */
.legal { padding: 4rem 0 6rem; }
.legal h1 { font-size: 2.3rem; margin-bottom: 1.5rem; }
.legal h2 { font-size: 1.25rem; margin: 2rem 0 .75rem; }
.legal p, .legal li { color: var(--text-2); margin-bottom: .75rem; }
.legal ul { padding-left: 1.25rem; }
.legal a { color: var(--accent-text); }
.legal table { width: 100%; border-collapse: collapse; font-size: .9rem; margin: 1rem 0; }
.legal th, .legal td { border: 1px solid var(--line-2); padding: .55rem; text-align: left; color: var(--text-2); }
.legal th { background: var(--tint); }

/* Footer */
.footer { padding: 3.5rem 0 2rem; border-top: 1px solid var(--line); }
.footer-inner { display: flex; justify-content: space-between; gap: 2rem; flex-wrap: wrap; margin-bottom: 2rem; }
.footer-inner > div { display: grid; gap: .5rem; justify-items: start; }
.footer-links { display: grid; gap: .5rem; }
.footer a { color: var(--muted); text-decoration: none; }
.footer a:hover { color: var(--text); }
.footer .logo { color: var(--text); font-size: 1.35rem; margin-bottom: .25rem; }

/* ===== Ficha de resultados del hero ===== */
/* Ficha de resultados: misma ventana de tinta que la terminal, en lenguaje de negocio */
.rc-bar { justify-content: space-between; }
.rc-bar p { margin-left: 0; font-size: .72rem; color: var(--muted); }
.rc-status { display: flex; align-items: center; gap: .45rem; color: var(--ok) !important; }
.rc-body { padding: 1.25rem 1.3rem 1.3rem; display: grid; gap: 1rem; }
.rc-row { opacity: 0; animation: fade .5s forwards; }
.rc-row:nth-child(1) { animation-delay: .2s; } .rc-row:nth-child(2) { animation-delay: .55s; } .rc-row:nth-child(3) { animation-delay: .9s; }
.rc-row:nth-child(4) { animation-delay: 1.25s; } .rc-row:nth-child(5) { animation-delay: 1.6s; }
.rc-meta { font-size: .76rem; color: var(--muted); }
.rc-k { display: block; font-family: var(--mono); font-size: .72rem; color: var(--muted); }
.rc-main { display: grid; gap: .15rem; }
.rc-big { font-size: clamp(1.6rem, 3.2vw, 2.15rem); font-weight: 700; letter-spacing: -.045em; line-height: 1.1; color: var(--text); white-space: nowrap; }
.rc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.rc-grid > div { display: grid; gap: .15rem; padding: .7rem .85rem; border: 1px solid var(--line-2); border-radius: 8px; background: var(--tint); }
.rc-grid b { font-size: 1.15rem; letter-spacing: -.03em; color: var(--text); }
.rc-grid small { font-family: var(--sans); font-size: .78rem; font-weight: 400; color: var(--muted); letter-spacing: 0; }
.rc-risk { border-color: rgba(240,138,138,.4) !important; }
.rc-risk b { color: var(--crit); }
.rc-start { padding-top: .9rem; border-top: 1px solid var(--line); }
.rc-start ol { list-style: none; display: grid; gap: .5rem; margin-top: .55rem; }
.rc-start li { display: grid; grid-template-columns: 1.6rem 1fr auto; gap: .6rem; align-items: baseline; font-size: .86rem; color: var(--text-2); }
.rc-n { color: var(--accent-text); font-size: .78rem; }
.rc-w { font-size: .72rem; color: var(--muted); white-space: nowrap; }
.rc-save { font-style: normal; font-size: .74rem; color: var(--ok); white-space: nowrap; }
.rc-foot { font-size: .72rem; color: var(--faint); }
.rc-foot .caret { width: .5em; height: 1em; margin-left: .3em; }

/* Cómo funciona: tiempo de cada paso */
.step-time { font-style: normal; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .rc-row { animation: none; opacity: 1; }
}
@media (max-width: 560px) {
  .rc-big { white-space: normal; }
  .rc-bar p { white-space: nowrap; font-size: .66rem; }
  .rc-body { padding: 1.1rem 1rem 1.15rem; gap: .85rem; }
  .rc-grid b { font-size: 1.05rem; }
  .rc-start li { grid-template-columns: 1.4rem 1fr auto; gap: .5rem; font-size: .82rem; }
  .rc-save { display: block; }
  .rc-grid small { display: block; }
}

/* Hoja de ruta de la muestra: 4 tarjetas, la de «con nosotros» destacada */
.rm-4 { grid-template-columns: repeat(4, 1fr); }
.rm-nos { border-color: var(--accent-line) !important; background: var(--accent-soft) !important; }
.rm-nos b { color: var(--accent-text); }
@media (max-width: 960px) { .rm-4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .rm-kpis.rm-4 > div:last-child { grid-column: auto; } }

/* ===== Franja de estándares ===== */
.estandares { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.estandares-in { display: flex; align-items: center; gap: .75rem 2rem; flex-wrap: wrap; padding-block: 1.1rem; }
.estandares-t { font-size: .78rem; color: var(--accent-text); flex: none; }
.estandares ul { list-style: none; display: flex; flex-wrap: wrap; gap: .6rem 1.75rem; }
.estandares li { display: grid; gap: .05rem; }
.estandares b { font-family: var(--mono); font-size: .86rem; letter-spacing: -.02em; }
.estandares span { font-size: .78rem; color: var(--muted); }

/* ===== Muestra: pestaña Procesos (mapa sencillo con un carril por puesto) ===== */
.proc-chips { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; margin: 1rem 0 .9rem; }
.proc-chip { font-size: .8rem; padding: .2rem .6rem; border: 1px solid var(--line-2); border-radius: 999px; color: var(--muted); }
.proc-chip.on { color: var(--text); border-color: var(--text); }
.swim { border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; }
.swim-lane { display: grid; grid-template-columns: 7.5rem 1fr; border-top: 1px solid var(--line); }
.swim-lane:first-child { border-top: 0; }
.swim-rol { display: flex; align-items: center; padding: .6rem .75rem; font-family: var(--mono); font-size: .74rem; color: var(--muted); background: var(--tint); border-right: 1px solid var(--line); }
.swim-pista { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .4rem; padding: .6rem; align-items: center; min-height: 4.2rem; }
.paso { grid-column: var(--c); display: grid; gap: .1rem; padding: .45rem .5rem; border: 1px solid var(--line-2); border-radius: 6px; background: var(--surface); font-size: .74rem; line-height: 1.3; color: var(--text-2); }
.paso i { font-style: normal; font-family: var(--mono); font-size: .68rem; font-weight: 700; color: var(--accent-text); }
.paso small { font-family: var(--mono); font-size: .68rem; color: var(--muted); }
.paso.dolor { background: #FFF6D5; border-color: #E8C46A; }
.swim-leyenda { display: flex; align-items: center; gap: .45rem; font-size: .78rem; color: var(--muted); margin: .6rem 0 0; }
.l-dolor { width: 12px; height: 12px; border-radius: 3px; background: #FFF6D5; border: 1px solid #E8C46A; }
.proc-kpis { padding: 0 0 1rem; }
.asi { margin-top: .5rem; padding: .9rem 1rem; border: 1px dashed var(--accent-line); border-radius: 8px; font-size: .9rem; color: var(--text-2); }

/* ===== Calculadora ===== */
.calc { margin-top: 2.5rem; padding: 1.5rem; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--surface); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 1rem 2rem; align-items: center; }
.calc h3 { font-size: 1.15rem; }
.calc-campos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; }
.calc-campos label { display: grid; gap: .35rem; font-size: .8rem; color: var(--text-2); align-content: end; }
.calc-campos input { font: inherit; font-family: var(--mono); color: var(--text); background: var(--bg); border: 1px solid var(--line-2); border-radius: 8px; padding: .6rem .75rem; width: 100%; }
.calc-campos input:focus { outline: none; border-color: var(--accent-text); box-shadow: 0 0 0 3px var(--accent-soft); }
.calc-res { grid-column: 1 / -1; padding-top: 1rem; border-top: 1px solid var(--line); display: grid; gap: .5rem; }
.calc-horas { font-size: .9rem; }
.calc-costo { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .4rem; }
.calc-costo select { font: inherit; font-family: var(--mono); font-size: .85rem; color: var(--text); background: var(--bg); border: 1px solid var(--line-2); border-radius: 8px; padding: .6rem .5rem; }
.proc-mas { margin-top: .75rem; }
.calc-res b { font-family: var(--mono); font-size: 1.5rem; letter-spacing: -.04em; color: var(--accent-text); }

/* ===== Botón fijo en el teléfono ===== */
.cta-fija { display: none; }
@media (max-width: 560px) {
  .cta-fija { display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9; padding: .65rem max(16px, env(safe-area-inset-right, 0px)) calc(.65rem + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); background: rgba(247,246,242,.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line); transition: transform .25s; }
  .cta-fija[hidden] { display: block; transform: translateY(110%); }
  .footer { padding-bottom: 5.5rem; }
}

@media (max-width: 960px) {
  .calc { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .calc-campos { grid-template-columns: 1fr; }
  .swim-lane { grid-template-columns: 1fr; }
  .swim-rol { border-right: 0; border-bottom: 1px solid var(--line); padding: .4rem .6rem; }
  .swim-pista { grid-template-columns: 1fr; }
  .paso { grid-column: auto; }
  .estandares-in { gap: .6rem; }
}
@media print { .reveal { opacity: 1 !important; transform: none !important; } .cta-fija { display: none !important; } }

/* Animación de entrada, muy sutil (v2.js) */
.reveal { opacity: 0; transform: translateY(8px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cursor, .caret { animation: none; }
  .ln { animation: none; opacity: 1; }
}

/* Responsive */
@media (max-width: 960px) {
  .menu-toggle { display: flex; }
  .nav-links { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; gap: 0; padding: .5rem 24px 1rem; background: var(--bg); box-shadow: 0 20px 40px rgba(15,17,21,.12); border-bottom: 1px solid var(--line); }
  .menu-open .nav-links { display: flex; }
  .nav-links a { padding: .8rem 0; font-size: 1rem; color: var(--text); border-bottom: 1px solid var(--line); }
  .nav-links a:last-child { border-bottom: 0; }
  .hero-grid, .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { gap: 1.25rem; }
  .audit-grid { gap: 2.5rem; }
  .cases { grid-template-columns: 1fr 1fr; }
  .op-cifras, .bf { grid-template-columns: repeat(2, 1fr); }
  .op-cifras > div:last-child { grid-column: 1 / -1; }
  .op-extra { grid-template-columns: 1fr; }
  .grid-4, .steps { grid-template-columns: 1fr 1fr; }
  .team { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .grid-4, .steps, .form .row { grid-template-columns: 1fr; }
  .report-rows li { grid-template-columns: 2rem 1fr; }
  .report-rows em { grid-column: 2; justify-self: start; }
  .cases, .bf { grid-template-columns: 1fr; }
  .rm-kpis { grid-template-columns: 1fr 1fr; }
  .rm-kpis > div:last-child { grid-column: 1 / -1; }
  .rep-table table { font-size: .78rem; }
  .rep-table th { font-size: .58rem; padding: .55rem .4rem; }
  .rep-table td { padding: .6rem .4rem; }
  .rep-table td small { display: block; }
  .g-fila { grid-template-columns: 1fr; gap: .3rem; padding: .35rem 0; }
  .g-etq { white-space: normal; }
  .g-cab { flex-direction: column; gap: 0; }
  .op { padding: 1rem; }
  .price-card { padding: 1.5rem; }
  .price-card .price { font-size: 2.8rem; }
  .filters { flex-wrap: nowrap; overflow-x: auto; margin-inline: -24px; padding-inline: 24px; scrollbar-width: none; }
  .filters button { flex: none; }
  .nav-actions .btn-sm { display: none; }
}
