/* ============================================================
   Mafe Garavito · Sistema ANCLA — hoja de estilos (v3)
   Identidad: azul noche + azul acero/pizarra, latón envejecido, gris perla frío. Tipografía sans
   (Manrope) para toda la jerarquía; serif (Fraunces) solo en citas.
   ============================================================ */

:root {
  --f-head: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-body: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --f-serif: 'Fraunces', Georgia, serif;

  /* NOCHE */
  --bg: #0A1020;
  --bg-deep: #0F1A33;
  --surface: #14213E;
  --surface-2: #1A2A4D;
  --steel: #1B2C4A;         /* azul acero: capa intermedia */
  --slate: #2A3D5E;         /* azul pizarra: tarjetas sobre acero */
  --line: rgba(190, 208, 232, 0.11);
  --line-strong: rgba(190, 208, 232, 0.22);
  --ink: #EAF0F8;           /* blanco frío */
  --ink-dim: #BFCADB;
  --mute: #8E9BB3;
  --gold: #A8874A;          /* latón envejecido */
  --gold-light: #CDB67F;
  --gold-ink: #CDB67F;      /* latón para texto sobre fondo oscuro */
  --on-gold: #1A1406;
  --glow-a: rgba(168, 135, 74, 0.15);
  --glow-b: rgba(44, 78, 150, 0.38);
  --tex: 0.55;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg: #EEF2F7;
  --bg-deep: #E2E9F1;
  --surface: #FFFFFF;
  --surface-2: #F5F8FB;
  --steel: #DCE4EE;
  --slate: #CBD6E4;
  --line: rgba(20, 34, 62, 0.11);
  --line-strong: rgba(20, 34, 62, 0.22);
  --ink: #0F1A33;
  --ink-dim: #3F4A63;
  --mute: #626D85;
  --gold: #8C6E34;
  --gold-light: #A8874A;
  --gold-ink: #7A5E28;
  --on-gold: #1A1406;
  --glow-a: rgba(168, 135, 74, 0.18);
  --glow-b: rgba(120, 150, 210, 0.22);
  --tex: 0.9;
  --shadow: 0 24px 60px rgba(30, 45, 80, 0.14);
  color-scheme: light;
}

/* Superficie perla: gris perla frío, solo donde la legibilidad lo pide */
.s-pearl {
  --bg: #E9EEF4;
  --surface: #FFFFFF;
  --surface-2: #F4F7FB;
  --line: rgba(20, 34, 62, 0.11);
  --line-strong: rgba(20, 34, 62, 0.22);
  --ink: #0F1A33;
  --ink-dim: #3F4A63;
  --mute: #626D85;
  --gold: #8C6E34;
  --gold-light: #A8874A;
  --gold-ink: #7A5E28;
  background: var(--bg);
  color: var(--ink);
}

/* Superficie acero/pizarra: siempre oscura, capa intermedia entre noche y perla */
.s-steel {
  --bg: #182843;
  --surface: #22355A;
  --surface-2: #2A3F68;
  --line: rgba(190, 208, 232, 0.13);
  --line-strong: rgba(190, 208, 232, 0.26);
  --ink: #EAF0F8;
  --ink-dim: #C3CEDF;
  --mute: #93A1BA;
  --gold: #A8874A;
  --gold-light: #CDB67F;
  --gold-ink: #CDB67F;
  background: linear-gradient(180deg, #162540 0%, #1C2E4D 100%);
  color: var(--ink);
  isolation: isolate;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--f-body); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  transition: background .35s ease, color .35s ease;
}
img, svg { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--f-head); color: var(--ink); margin: 0; letter-spacing: -0.018em; }
p { margin: 0; color: var(--ink-dim); }
a { color: inherit; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; position: relative; }
.wrap-narrow { max-width: 800px; margin: 0 auto; padding: 0 24px; position: relative; }

/* ---------- Jerarquía tipográfica ---------- */
h2.title { font-size: clamp(27px, 3.3vw, 40px); font-weight: 800; line-height: 1.14; max-width: 22ch; }
h2.title.wide { max-width: 26ch; }
h3.sub { font-size: 20px; font-weight: 700; line-height: 1.3; }
p.lede { font-size: 18px; line-height: 1.65; color: var(--ink-dim); max-width: 62ch; }
.small { font-size: 14px; line-height: 1.55; color: var(--mute); }

/* ---------- Superficies y ritmo ---------- */
section { position: relative; padding: 100px 0; }
@media (max-width: 720px) { section { padding: 68px 0; } }
.s-night { background: var(--bg); }
.s-deep { background: var(--bg-deep); isolation: isolate; }
/* textura cartográfica muy suave: líneas de profundidad */
.s-deep::before, .s-steel::before, .hero::after {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: var(--tex);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='720' height='360' viewBox='0 0 720 360' fill='none' stroke='%23B4C6E0' stroke-opacity='.07' stroke-width='1'%3E%3Cpath d='M0 40C90 8 180 76 270 40S450 8 540 40 630 72 720 40'/%3E%3Cpath d='M0 110C90 78 180 146 270 110S450 78 540 110 630 142 720 110'/%3E%3Cpath d='M0 180C90 148 180 216 270 180S450 148 540 180 630 212 720 180'/%3E%3Cpath d='M0 250C90 218 180 286 270 250S450 218 540 250 630 282 720 250'/%3E%3Cpath d='M0 320C90 288 180 356 270 320S450 288 540 320 630 352 720 320'/%3E%3C/svg%3E");
  background-size: 720px 360px;
}
:root[data-theme="light"] .s-deep::before,
:root[data-theme="light"] .hero::after { filter: brightness(.55) saturate(1.4); }

/* ---------- Encabezado de sección (numeración tipo carta de navegación) ---------- */
.sh { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.sh-idx {
  font-weight: 800; font-size: 12.5px; letter-spacing: .08em; color: var(--on-gold);
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  border-radius: 5px; padding: 3px 8px; line-height: 1.3;
}
.sh-label { font-size: 12.5px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--gold-ink); }
.sh::after { content: ''; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line-strong), transparent); max-width: 220px; }

/* ---------- Botones ---------- */
.btn-primary, .btn-secondary, .btn-cta {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--f-body); font-weight: 700; text-decoration: none; white-space: nowrap;
  border-radius: 8px; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, color .2s ease;
}
.btn-primary {
  font-size: 15.5px; padding: 15px 26px; color: var(--on-gold);
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  box-shadow: 0 10px 26px rgba(176, 141, 62, .28);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 14px 32px rgba(176, 141, 62, .36); }
.btn-secondary { font-size: 15.5px; padding: 14px 24px; color: var(--ink); border: 1.5px solid var(--line-strong); background: transparent; }
.btn-secondary:hover { border-color: var(--gold); color: var(--gold-ink); }
.btn-cta { font-size: 13.5px; padding: 10px 18px; color: var(--on-gold); background: linear-gradient(135deg, var(--gold-light), var(--gold)); }
.btn-primary:focus-visible, .btn-secondary:focus-visible, .btn-cta:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 3px; }

/* ---------- Navegación ---------- */
nav.topnav {
  position: sticky; top: 0; z-index: 60;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top, 0px);
}
nav.topnav .inner { max-width: 1120px; margin: 0 auto; padding: 13px 24px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.nav-brand { font-weight: 800; font-size: 16px; letter-spacing: -.01em; color: var(--ink); text-decoration: none; white-space: nowrap; line-height: 1.15; }
.nav-brand small { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .14em; color: var(--mute); text-transform: uppercase; margin-top: 3px; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a.nl { color: var(--ink-dim); text-decoration: none; font-size: 14px; font-weight: 600; white-space: nowrap; }
.nav-links a.nl:hover { color: var(--gold-ink); }
.nav-sections { display: none; gap: 22px; }
@media (min-width: 1380px) { .nav-sections { display: flex; } }
.nav-right { display: flex; align-items: center; gap: 12px; }
@media (max-width: 780px) { .nav-right a.nav-optional { display: none; } }
@media (max-width: 560px) {
  nav.topnav .inner { padding: 11px 14px; gap: 8px; }
  .nav-brand { font-size: 13px; }
  .nav-brand small { display: none; }
  .btn-cta { font-size: 11px; padding: 9px 11px; }
}
.theme-toggle {
  width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-strong);
  background: var(--surface); color: var(--gold-ink); cursor: pointer; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; transition: transform .2s ease;
}
.theme-toggle:hover { transform: scale(1.06); }
.theme-toggle svg { width: 18px; height: 18px; }
@media (max-width: 560px) { .theme-toggle { width: 32px; height: 32px; } .theme-toggle svg { width: 15px; height: 15px; } }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; padding: 76px 0 96px; overflow: hidden;
  background:
    radial-gradient(820px 520px at 88% 6%, var(--glow-a), transparent 62%),
    radial-gradient(900px 640px at -6% 100%, var(--glow-b), transparent 60%),
    var(--bg);
}
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 56px; align-items: center; }
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.08fr .92fr; gap: 64px; } }
.brandmark { display: inline-flex; align-items: center; gap: 10px; margin-bottom: 26px; font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-dim); }
.brandmark b {
  font-weight: 800; background: linear-gradient(135deg, var(--gold-light), var(--gold));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.brandmark i { width: 28px; height: 1px; background: var(--line-strong); }
.hero h1 { font-size: clamp(31px, 3.5vw, 48px); line-height: 1.07; letter-spacing: -.03em; font-weight: 800; }
.hero h1 .h1-a, .hero h1 .h1-b { display: block; }
.hero h1 .h1-a { font-weight: 600; color: var(--ink-dim); }
.hero h1 .h1-a::after { content: ''; display: block; width: 60px; height: 3px; border-radius: 2px; background: linear-gradient(90deg, var(--gold-light), var(--gold)); margin: 20px 0 20px; }
.hero p.lede { margin-top: 26px; max-width: 54ch; font-size: 18px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero-scope { margin-top: 26px; font-size: 14px; color: var(--mute); max-width: 56ch; }
@media (max-width: 560px) { .hero { padding: 48px 0 64px; } .hero-actions .btn-primary, .hero-actions .btn-secondary { width: 100%; } }

/* Diagrama del hero: personas + proceso → cultura comercial */
.hero-map { position: relative; padding: 4px 0 4px 34px; }
.hero-map::before {
  content: ''; position: absolute; left: 9px; top: 24px; bottom: 24px; width: 2px;
  background: linear-gradient(180deg, var(--gold-light), var(--gold) 55%, color-mix(in srgb, var(--gold) 35%, transparent));
}
.hm-node { position: relative; margin-bottom: 14px; }
.hm-node:last-child { margin-bottom: 0; }
.hm-node::before {
  content: ''; position: absolute; left: -33px; top: 26px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg); border: 2.5px solid var(--gold-light); z-index: 1;
}
.hm-node.hm-final::before { background: var(--gold-light); box-shadow: 0 0 0 5px color-mix(in srgb, var(--gold-light) 22%, transparent); }
.hm-card { background: color-mix(in srgb, var(--surface) 88%, transparent); border: 1px solid var(--line-strong); border-radius: 10px; padding: 20px 22px; }
.hm-final .hm-card { background: linear-gradient(135deg, color-mix(in srgb, var(--gold) 18%, var(--surface)), var(--surface)); border-color: color-mix(in srgb, var(--gold) 55%, transparent); }
.hm-tag { display: block; font-size: 11.5px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--gold-ink); margin-bottom: 6px; }
.hm-card h3 { font-size: 18px; font-weight: 700; line-height: 1.3; margin-bottom: 6px; }
.hm-card p { font-size: 14.5px; line-height: 1.55; }
.hm-plus { position: relative; z-index: 2; margin: -4px 0 10px; font-size: 12px; font-weight: 800; letter-spacing: .1em; color: var(--mute); text-transform: uppercase; }

/* ---------- 01 Cultura comercial ---------- */
.dims { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 44px; position: relative; }
@media (min-width: 900px) {
  .dims { grid-template-columns: repeat(3, 1fr); gap: 22px; }
  .dims::before { content: ''; position: absolute; left: 6%; right: 6%; top: 27px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold) 15%, var(--gold) 85%, transparent); opacity: .55; }
}
.dim { position: relative; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; padding: 28px 26px 26px; }
.dim-num {
  position: relative; z-index: 1; display: flex; align-items: center; justify-content: center;
  width: 54px; height: 54px; border-radius: 50%; margin-bottom: 20px;
  background: var(--bg-deep); border: 1.5px solid var(--gold-light); color: var(--gold-ink);
  font-weight: 800; font-size: 19px;
}
.dim h3 { font-size: 21px; font-weight: 800; line-height: 1.22; margin-bottom: 8px; }
.dim .dim-lead { font-size: 15.5px; color: var(--ink); margin-bottom: 16px; }
.dim ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.dim li { position: relative; padding-left: 18px; font-size: 14.5px; line-height: 1.5; color: var(--ink-dim); }
.dim li::before { content: ''; position: absolute; left: 0; top: .62em; width: 8px; height: 1.5px; background: var(--gold); }
.adn {
  margin-top: 26px; display: grid; grid-template-columns: 1fr; gap: 14px; padding: 24px 28px; border-radius: 12px;
  border: 1px solid color-mix(in srgb, var(--gold) 45%, transparent);
  background: linear-gradient(135deg, color-mix(in srgb, var(--gold) 12%, transparent), transparent 70%);
}
@media (min-width: 800px) { .adn { grid-template-columns: 200px 1fr; align-items: center; gap: 30px; } }
.adn-key { font-size: 22px; font-weight: 800; letter-spacing: -.02em; color: var(--gold-ink); line-height: 1.2; }
.adn p { font-size: 15.5px; color: var(--ink-dim); }

.duo { display: grid; grid-template-columns: 1fr; gap: 28px; align-items: center; margin-top: 64px; padding-top: 56px; border-top: 1px solid var(--line); }
@media (min-width: 800px) { .duo { grid-template-columns: 300px 1fr; gap: 54px; } }
.duo-photo { border-radius: 12px; overflow: hidden; border: 1px solid var(--line-strong); line-height: 0; max-width: 300px; box-shadow: var(--shadow); }
.duo-photo img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; object-position: center 25%; }
.duo h3 { font-size: 24px; font-weight: 800; line-height: 1.2; margin-bottom: 12px; }
.duo-quote { margin-top: 18px; font-family: var(--f-serif); font-style: italic; font-size: 19px; line-height: 1.45; color: var(--ink); }

/* ---------- 02 Sistema: manifiesto + ruta ---------- */
.manifest-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
.circuit-box { position: relative; border-radius: 14px; padding: 36px 34px; isolation: isolate; overflow: hidden; }
.circuit-box::before {
  content: ''; position: absolute; inset: 0; border-radius: inherit; padding: 1.5px;
  background: conic-gradient(from var(--circuit-a, 0deg), transparent 0%, var(--gold) 8%, var(--gold-light) 14%, var(--gold) 20%, transparent 32%, transparent 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: circuit-spin 6s linear infinite; z-index: 1;
}
.circuit-box::after { content: ''; position: absolute; inset: 1.5px; border-radius: 13px; background: var(--surface); z-index: 0; }
.circuit-box > * { position: relative; z-index: 2; }
@property --circuit-a { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
@keyframes circuit-spin { to { --circuit-a: 360deg; } }
.manifest { display: grid; grid-template-columns: 1fr; gap: 20px; align-items: start; }
@media (min-width: 760px) { .manifest { grid-template-columns: 74px 1fr; gap: 28px; } }
.anchor-icon { width: 54px; height: 54px; color: var(--gold-ink); }
.manifest h3 { font-size: 22px; font-weight: 800; margin-bottom: 10px; }
.manifest p { font-size: 16.5px; }

.route-eyebrow { margin: 64px 0 0; display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 8px 20px; }
.route-eyebrow h3 { font-size: 24px; font-weight: 800; }
.route-eyebrow span { font-size: 13px; color: var(--mute); }
.route-hint { display: none; align-items: center; justify-content: center; gap: 7px; font-size: 13px; color: var(--ink-dim); margin: 16px 0 0; }
.route-hint svg { width: 14px; height: 14px; color: var(--gold-ink); animation: hint-click 2.4s ease-in-out infinite; }
@media (hover: none) and (pointer: coarse) { .route-hint { display: flex; } }
@keyframes hint-click { 0%, 18%, 100% { transform: translate(0, 0) scale(1); } 9% { transform: translate(-1.5px, 1.5px) scale(.85); } }

.route-frame { position: relative; margin-top: 26px; border: 1px solid var(--line-strong); border-radius: 12px; background: color-mix(in srgb, var(--surface) 55%, transparent); padding: 0 24px 18px; overflow: hidden; }
.route-frame::before { /* retícula muy suave */
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px; opacity: .35;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 85%); mask-image: radial-gradient(ellipse at center, #000 30%, transparent 85%);
}
.route-stage { position: relative; height: 240px; margin: 70px 0 6px; }
.route-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.route-contour { fill: none; stroke: var(--line-strong); stroke-width: 1; opacity: .55; }
.route-path { fill: none; stroke: url(#anclaRouteGrad); stroke-width: 2.5; stroke-dasharray: 3 9; stroke-linecap: round; opacity: .85; animation: dash-flow 2.6s linear infinite; }
@keyframes dash-flow { to { stroke-dashoffset: -24; } }
.route-scale { position: absolute; left: 0; right: 0; bottom: -6px; height: 6px; background: repeating-linear-gradient(90deg, var(--line-strong) 0 1px, transparent 1px 14.285%); opacity: .8; }

.route-stage button.buoy {
  position: absolute; width: 18px; height: 18px; border-radius: 50%; padding: 0; appearance: none; -webkit-appearance: none;
  background: var(--bg); border: 2.5px solid var(--gold); transform: translate(-50%, -50%); cursor: pointer;
  transition: background .25s ease, box-shadow .25s ease, transform .2s ease;
}
.route-stage .buoy:hover { transform: translate(-50%, -50%) scale(1.15); }
.route-stage .buoy:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 4px; }
.route-stage .buoy.active { background: var(--gold-light); box-shadow: 0 0 16px 5px color-mix(in srgb, var(--gold-light) 50%, transparent); }
.route-stage .buoy-label { position: absolute; transform: translateX(-50%); font-size: 12.5px; line-height: 1.35; color: var(--ink-dim); white-space: nowrap; text-align: center; pointer-events: none; transition: color .25s ease; }
.route-stage .buoy-label b { display: block; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--mute); font-weight: 700; }
.route-stage .buoy-label.active-label { color: var(--gold-ink); font-weight: 700; }
.route-stage .buoy-label.active-label b { color: var(--gold-ink); }
.route-stage .boat { position: absolute; width: 36px; height: 36px; transform: translate(-50%, -50%); transition: left .65s cubic-bezier(.4, .1, .2, 1), top .65s cubic-bezier(.4, .1, .2, 1); filter: drop-shadow(0 0 8px color-mix(in srgb, var(--gold-light) 60%, transparent)); }
.route-stage .boat-bob { width: 100%; height: 100%; animation: boat-bob 2.2s ease-in-out infinite; color: var(--gold-light); }
.route-stage .boat svg { width: 100%; height: 100%; }
@keyframes boat-bob { 0%, 100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-5px) rotate(4deg); } }

.detail-panel {
  position: relative; max-width: 100%; margin: 6px 0 0; padding: 22px 26px 24px;
  border-top: 1px solid var(--line-strong); display: grid; grid-template-columns: 150px 1fr; gap: 6px 30px; align-items: start;
}
.detail-panel .detail-idx { grid-row: 1 / 3; font-size: 12px; letter-spacing: .16em; color: var(--gold-ink); font-weight: 800; text-transform: uppercase; padding-top: 6px; }
.detail-panel h3 { font-size: 21px; font-weight: 800; }
.detail-panel p { font-size: 15.5px; line-height: 1.6; max-width: 70ch; }
.detail-panel .tag-row { grid-column: 2; margin-top: 8px; }
.detail-panel .tag-row:empty { display: none; }
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-pill { font-size: 12.5px; font-weight: 600; color: var(--gold-ink); border: 1px solid var(--line-strong); border-radius: 20px; padding: 5px 12px; background: color-mix(in srgb, var(--gold) 9%, transparent); }

/* Ruta vertical (móvil) */
.route-v { display: none; margin: 30px 0 0; position: relative; }
.route-v ol { list-style: none; margin: 0; padding: 0; }
.route-v::before { content: ''; position: absolute; left: 21px; top: 22px; bottom: 22px; width: 0; border-left: 2.5px dotted color-mix(in srgb, var(--gold) 70%, transparent); }
.route-v li { position: relative; display: grid; grid-template-columns: 44px 1fr; gap: 16px; padding-bottom: 28px; }
.route-v li:last-child { padding-bottom: 0; }
.rv-node { position: relative; z-index: 1; width: 44px; height: 44px; border-radius: 50%; background: var(--bg); border: 2px solid var(--gold); color: var(--gold-ink); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 16px; transition: background .3s ease, box-shadow .3s ease, color .3s ease; }
.route-v li.is-active .rv-node { background: var(--gold-light); color: transparent; box-shadow: 0 0 16px 4px color-mix(in srgb, var(--gold-light) 50%, transparent); }
.rv-body h4 { font-size: 18px; font-weight: 800; margin: 8px 0 6px; transition: color .3s ease; }
.route-v li.is-active .rv-body h4 { color: var(--gold-ink); }
.rv-body p { font-size: 14.5px; line-height: 1.55; }
.rv-body .tag-row { margin-top: 12px; gap: 8px; }
.rv-body .tag-pill { font-size: 12px; padding: 5px 11px; }
.rv-boat { position: absolute; left: 5px; top: 22px; width: 34px; height: 34px; z-index: 3; transform: translateY(-50%); color: #1E1704; pointer-events: none; transition: top .6s cubic-bezier(.4, .1, .2, 1); }
.rv-boat svg { width: 100%; height: 100%; }
@media (max-width: 760px) {
  .route-frame { display: none; }
  .route-hint { display: none !important; }
  .route-v { display: block; }
}

/* ---------- 03 Implementación (marfil) ---------- */
.impl-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 26px 0 0; }
.impl-meta .tag-pill { background: var(--surface); }
.impl-track { position: relative; display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 44px; counter-reset: stop; }
@media (min-width: 720px) { .impl-track { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) {
  .impl-track { grid-template-columns: repeat(6, 1fr); gap: 12px; }
  .impl-track::before { content: ''; position: absolute; left: 4%; right: 4%; top: 21px; height: 2px; background: linear-gradient(90deg, var(--gold-light), var(--gold) 50%, var(--gold-light)); opacity: .7; }
}
.stop { position: relative; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; padding: 22px 18px 20px; }
@media (min-width: 1100px) { .stop { margin-top: 44px; } .stop::before { content: ''; position: absolute; left: 50%; top: -23px; width: 1px; height: 22px; background: var(--gold); opacity: .55; } }
.stop-node {
  display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 50%; margin-bottom: 14px;
  background: var(--bg); border: 2px solid var(--gold); color: var(--gold-ink); font-size: 13px; font-weight: 800;
}
@media (min-width: 1100px) { .stop-node { position: absolute; left: 50%; top: -42px; margin: 0; transform: translateX(-50%); width: 36px; height: 36px; z-index: 1; } .stop { padding-top: 26px; } }
.stop-kind { display: block; font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-ink); margin-bottom: 6px; }
.stop h3 { font-size: 16.5px; font-weight: 800; line-height: 1.28; margin-bottom: 8px; }
.stop p { font-size: 14px; line-height: 1.55; margin-bottom: 14px; }
.stop .tag-pill { font-size: 11.5px; padding: 4px 10px; background: color-mix(in srgb, var(--gold) 14%, transparent); }
.stop.stop-edge { background: var(--surface-2); }
.impl-bracket { margin-top: 18px; display: none; }
@media (min-width: 1100px) {
  .impl-bracket { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
  .impl-bracket div { grid-column: 2 / 6; border: 1.5px solid var(--gold); border-top: none; border-radius: 0 0 10px 10px; padding: 10px 14px 0; text-align: center; font-size: 13px; font-weight: 700; color: var(--gold-ink); height: 38px; }
}
.impl-notes { display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 30px; }
@media (min-width: 800px) { .impl-notes { grid-template-columns: 1fr 1fr; } }
.note { padding: 20px 22px; border: 1px solid var(--line-strong); border-left: 3px solid var(--gold); border-radius: 0 10px 10px 0; background: var(--surface); }
.note h4 { font-size: 15px; font-weight: 800; margin-bottom: 6px; }
.note p { font-size: 14.5px; line-height: 1.55; }

/* ---------- 04 Diagnóstico ---------- */
.diag { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 40px; align-items: stretch; }
@media (min-width: 940px) { .diag { grid-template-columns: 1.25fr auto 0.75fr; gap: 0; } }
.diag-in, .diag-out { border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); padding: 26px 26px 22px; }
.diag-in h3, .diag-out h3 { font-size: 13px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; color: var(--gold-ink); margin-bottom: 14px; }
.diag-in ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 0; }
@media (min-width: 620px) { .diag-in ul { grid-template-columns: 1fr 1fr; column-gap: 28px; } }
.diag-in li { position: relative; padding: 11px 0 11px 22px; border-top: 1px solid var(--line); font-size: 14.5px; line-height: 1.5; color: var(--ink-dim); }
.diag-in li::before { content: ''; position: absolute; left: 0; top: 1.05em; width: 9px; height: 9px; border-radius: 50%; border: 2px solid var(--gold); }
.diag-arrow { display: flex; align-items: center; justify-content: center; color: var(--gold-ink); padding: 8px; }
.diag-arrow svg { width: 44px; height: 44px; }
@media (max-width: 939px) { .diag-arrow { transform: rotate(90deg); padding: 0; height: 34px; } }
.diag-out ul { list-style: none; margin: 0 0 18px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.diag-out li { padding: 12px 16px; border-radius: 8px; background: color-mix(in srgb, var(--gold) 11%, transparent); border: 1px solid color-mix(in srgb, var(--gold) 35%, transparent); font-weight: 700; font-size: 15px; color: var(--ink); }
.diag-note { font-size: 14px; color: var(--mute); }
.diag-foot { margin-top: 26px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; }
.diag-foot p { max-width: 70ch; font-size: 15px; }

/* ---------- 05 Herramientas ---------- */
.tools { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 44px; }
@media (min-width: 640px) { .tools { grid-template-columns: 1fr 1fr; } }
@media (min-width: 980px) { .tools { grid-template-columns: repeat(3, 1fr); gap: 20px; } }
.tool { background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; padding: 26px 24px 22px; display: flex; flex-direction: column; transition: border-color .25s ease, transform .25s ease; }
.tool:hover { border-color: color-mix(in srgb, var(--gold) 60%, transparent); transform: translateY(-2px); }
.tool-ico { width: 44px; height: 44px; border-radius: 10px; margin-bottom: 18px; display: flex; align-items: center; justify-content: center; color: var(--gold-ink); background: color-mix(in srgb, var(--gold) 13%, transparent); }
.tool-ico svg { width: 22px; height: 22px; }
.tool h3 { font-size: 18px; font-weight: 800; line-height: 1.28; margin-bottom: 8px; }
.tool p { font-size: 14.5px; line-height: 1.58; flex: 1; }
.tool-link { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 12.5px; font-weight: 700; color: var(--gold-ink); letter-spacing: .02em; }
.tool-link span { color: var(--mute); font-weight: 600; }
.tools-foot { margin-top: 26px; font-size: 15px; max-width: 70ch; }

/* ---------- 06 Comunidad ---------- */
.comm { display: grid; grid-template-columns: 1fr; gap: 44px; align-items: center; }
@media (min-width: 940px) { .comm { grid-template-columns: 1fr 1fr; gap: 64px; } }
.comm-fig { position: relative; height: 320px; max-width: 460px; width: 100%; margin: 0 auto; }
.comm-fig svg.lines { position: absolute; inset: 0; width: 100%; height: 100%; }
.comm-fig .lines line { stroke: var(--gold); stroke-width: 1.5; stroke-dasharray: 3 7; opacity: .75; }
.comm-core { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 122px; height: 122px; border-radius: 50%; display: flex; align-items: center; justify-content: center; text-align: center; padding: 14px; font-weight: 800; font-size: 14px; line-height: 1.25; color: var(--ink); background: radial-gradient(circle at 30% 25%, color-mix(in srgb, var(--gold) 28%, var(--surface)), var(--surface)); border: 1.5px solid var(--gold); box-shadow: 0 0 0 8px color-mix(in srgb, var(--gold) 10%, transparent); }
.comm-n { position: absolute; transform: translate(-50%, -50%); width: 128px; text-align: center; font-size: 13px; font-weight: 700; line-height: 1.3; color: var(--ink); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 10px; padding: 11px 10px; }
.comm-n::before { content: ''; display: block; width: 10px; height: 10px; border-radius: 50%; background: var(--gold-light); margin: 0 auto 8px; }
.comm-list { list-style: none; margin: 26px 0 0; padding: 0; display: flex; flex-direction: column; gap: 0; }
.comm-list li { position: relative; padding: 14px 0 14px 28px; border-top: 1px solid var(--line); color: var(--ink-dim); font-size: 15.5px; }
.comm-list li:last-child { border-bottom: 1px solid var(--line); }
.comm-list li::before { content: ''; position: absolute; left: 0; top: 1.3em; width: 12px; height: 2px; background: var(--gold); }
.comm-list b { color: var(--ink); }
.comm-note { margin-top: 22px; font-size: 14.5px; color: var(--mute); }
@media (max-width: 560px) {
  .comm-fig { height: 380px; }
  .comm-n { width: 118px; font-size: 12.5px; }
}

/* ---------- Testimonio ---------- */
.case-card { margin-top: 30px; border: 1px solid var(--line-strong); border-radius: 12px; padding: 38px 34px; background: var(--surface); position: relative; }
.case-card::before { content: '“'; position: absolute; top: 4px; left: 24px; font-family: var(--f-serif); font-size: 84px; line-height: 1; color: var(--gold); opacity: .6; }
.case-company { font-size: 13.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--gold-ink); margin: 18px 0 14px; }
.case-quote { font-family: var(--f-serif); font-style: italic; font-size: clamp(19px, 2.4vw, 24px); line-height: 1.5; color: var(--ink); margin: 0 0 18px; }
.case-sign { font-size: 14px; color: var(--mute); }

/* ---------- Cotización ---------- */
.quote-wrap .circuit-box { padding: 44px 40px; }
@media (max-width: 560px) { .quote-wrap .circuit-box, .circuit-box { padding: 30px 22px; } }
.quote-grid { display: grid; grid-template-columns: 1fr; gap: 30px; margin-top: 8px; }
@media (min-width: 860px) { .quote-grid { grid-template-columns: 1fr 1fr; gap: 44px; } }
.quote-lead { margin: 0 0 12px; font-size: 13px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; color: var(--gold-ink); }
.quote-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 0; }
.quote-list li { position: relative; padding: 11px 0 11px 20px; border-top: 1px solid var(--line); font-size: 15px; color: var(--ink-dim); }
.quote-list li:last-child { border-bottom: 1px solid var(--line); }
.quote-list li::before { content: ''; position: absolute; left: 0; top: 1.15em; width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--gold); }
.quote-side { align-self: stretch; padding: 24px 26px; border-radius: 10px; background: color-mix(in srgb, var(--gold) 9%, transparent); border: 1px solid color-mix(in srgb, var(--gold) 38%, transparent); }
.quote-close { font-size: 17.5px; line-height: 1.6; font-weight: 600; color: var(--ink); }
.quote-cta { margin-top: 30px; }
.quote-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 22px; }

/* ---------- Continuidad (tarjetas que giran) ---------- */
.flip-grid { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 36px; }
@media (min-width: 640px) { .flip-grid { grid-template-columns: repeat(3, 1fr); } }
.flip-hint { font-size: 13px; color: var(--mute); margin-top: 22px; }
.flip-card { perspective: 1300px; height: 200px; cursor: pointer; position: relative; }
.flip-card:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; border-radius: 12px; }
.flip-hint-badge { position: absolute; top: -10px; right: -10px; z-index: 5; width: 32px; height: 32px; border-radius: 50%; background: linear-gradient(135deg, var(--gold-light), var(--gold)); display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 10px rgba(0, 0, 0, .3); pointer-events: none; }
.flip-hint-badge svg { width: 14px; height: 14px; color: var(--on-gold); animation: hint-click 2.4s ease-in-out infinite; }
.flip-inner { position: relative; width: 100%; height: 100%; transition: transform .65s cubic-bezier(.4, .2, .2, 1); transform-style: preserve-3d; }
.flip-card.flipped .flip-inner { transform: rotateY(180deg); }
@media (hover: hover) and (pointer: fine) { .flip-card:hover .flip-inner { transform: rotateY(180deg); } }
.flip-front, .flip-back { position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden; border-radius: 12px; display: flex; flex-direction: column; justify-content: center; padding: 24px; }
.flip-front { background: var(--surface); border: 1px solid var(--line-strong); }
.flip-front .idx { color: var(--gold-ink); font-size: 13px; font-weight: 800; letter-spacing: .1em; margin-bottom: 10px; }
.flip-front .title { font-weight: 800; color: var(--ink); font-size: 18px; line-height: 1.3; }
.flip-back { background: linear-gradient(150deg, #16264A 0%, #0D1730 100%); color: #EAF0F8; transform: rotateY(180deg); overflow-y: auto; border: 1px solid color-mix(in srgb, var(--gold) 50%, transparent); }
.flip-back p { color: #E2DDCF; font-size: 14px; line-height: 1.55; }

/* ---------- Acordeones ---------- */
.acc-list { margin-top: 30px; border-top: 1px solid var(--line-strong); }
details.acc { border-bottom: 1px solid var(--line-strong); padding: 0; }
details.acc summary { cursor: pointer; font-weight: 700; font-size: 17px; line-height: 1.4; color: var(--ink); list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px 0; font-family: var(--f-head); }
details.acc summary::-webkit-details-marker { display: none; }
details.acc summary::after { content: '+'; color: var(--gold-ink); font-size: 24px; font-weight: 400; flex-shrink: 0; transition: transform .2s ease; }
details.acc[open] summary::after { content: '–'; }
details.acc summary:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 2px; }
details.acc .acc-body { padding: 0 0 22px; max-width: 72ch; }
details.acc .acc-body p { font-size: 15.5px; line-height: 1.65; }

/* ---------- Pie ---------- */
footer.site-footer { background: #070C18; border-top: 1px solid var(--line); padding: 56px 0 44px; text-align: center; color: #EAF0F8; }
:root[data-theme="light"] footer.site-footer { background: #0E1730; }
footer.site-footer .fbrand { font-weight: 800; font-size: 18px; color: #EAF0F8; margin-bottom: 6px; letter-spacing: -.01em; }
footer.site-footer .fsub { font-size: 14px; color: #9AA4BC; margin-bottom: 26px; }
footer.site-footer .factions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
footer.site-footer .btn-secondary { color: #EAF0F8; border-color: rgba(234, 240, 248, .28); }

/* ---------- Aparición suave (solo con JS) ---------- */
.js .rv { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; transition-delay: var(--d, 0s); }
.js .rv.in { opacity: 1; transform: none; }

/* ---------- Movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .route-path, .route-stage .boat-bob, .route-hint svg, .flip-hint-badge svg, .circuit-box::before { animation: none; }
  .route-stage .boat, .rv-boat, .flip-inner { transition: none; }
  .js .rv { opacity: 1; transform: none; transition: none; }
}


/* ============================================================
   v8 · Identidad propia: carta de navegación, acero/pizarra, contacto
   ============================================================ */

/* Marca de rumbo en el borde superior de cada sección (muy sutil) */
section[data-rumbo]::after {
  content: attr(data-rumbo); position: absolute; top: 22px; right: 24px; z-index: 0;
  font-size: 10.5px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase;
  color: var(--mute); opacity: .75; pointer-events: none; font-variant-numeric: tabular-nums;
  padding-left: 54px;
  background: linear-gradient(90deg, transparent 0 0) no-repeat, repeating-linear-gradient(90deg, var(--line-strong) 0 1px, transparent 1px 9px) left center / 44px 7px no-repeat;
}
@media (max-width: 720px) { section[data-rumbo]::after { display: none; } }

/* Hero: retícula de navegación y rosa de los vientos */
.hero { isolation: isolate; }
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 88px 88px; opacity: .55;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 78% 40%, #000 0%, transparent 72%);
          mask-image: radial-gradient(ellipse 70% 80% at 78% 40%, #000 0%, transparent 72%);
}
.hero-rose {
  position: absolute; right: -90px; top: 8%; width: 460px; height: 460px; z-index: -1; pointer-events: none;
  color: var(--gold-light); opacity: .13;
}
@media (max-width: 900px) { .hero-rose { width: 300px; height: 300px; right: -120px; top: 2%; } }

/* Identidad de tarjetas: ficha con esquina de carta */
.stop, .tool, .dim, .diag-in, .diag-out { border-radius: 8px; }
.tool, .stop { border-top: 2px solid color-mix(in srgb, var(--gold) 70%, transparent); }
.s-steel .stop { background: var(--surface); border-color: var(--line-strong); border-top-color: var(--gold); }
.s-steel .stop.stop-edge { background: var(--surface-2); }
.s-steel .impl-meta .tag-pill { background: color-mix(in srgb, var(--surface) 80%, transparent); }
.s-steel .note { background: color-mix(in srgb, var(--surface) 75%, transparent); }
.stop-ref { display: block; margin-top: 12px; font-size: 10.5px; font-weight: 700; letter-spacing: .18em; color: var(--mute); text-transform: uppercase; }

.s-pearl .flip-front { border: 1px solid var(--line-strong); }

/* Transición oscura → perla: franja de sondeo */
.s-pearl { border-top: 1px solid var(--line-strong); }

/* ---------- Cotización: una intro, una lista, una llamada ---------- */
.quote-wrap .circuit-box { padding: 44px 40px; }
.quote-list.q5 { margin-top: 30px; display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 720px) { .quote-list.q5 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1020px) { .quote-list.q5 { grid-template-columns: repeat(5, 1fr); gap: 14px; } }
.quote-list.q5 li { border: 1px solid var(--line-strong); border-radius: 8px; padding: 18px 16px 18px 16px; background: color-mix(in srgb, var(--steel) 55%, transparent); font-size: 14.5px; line-height: 1.5; color: var(--ink); }
.quote-list.q5 li:last-child { border-bottom: 1px solid var(--line-strong); }
.quote-list.q5 li::before { position: static; display: block; width: 22px; height: 2px; border: 0; border-radius: 0; background: var(--gold); margin-bottom: 12px; }
.quote-after { margin-top: 26px; max-width: 70ch; font-size: 16.5px; line-height: 1.6; font-weight: 600; color: var(--ink); }

/* ---------- Contacto ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 40px; margin-top: 8px; align-items: start; }
@media (min-width: 980px) { .contact-grid { grid-template-columns: 5fr 7fr; gap: 56px; } }
.contact-steps { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 0; counter-reset: cs; }
.contact-steps li { position: relative; padding: 14px 0 14px 46px; border-top: 1px solid var(--line); font-size: 15px; color: var(--ink-dim); counter-increment: cs; }
.contact-steps li:last-child { border-bottom: 1px solid var(--line); }
.contact-steps li::before { content: counter(cs); position: absolute; left: 0; top: 12px; width: 30px; height: 30px; border-radius: 50%; border: 1.5px solid var(--gold); color: var(--gold-ink); font-weight: 800; font-size: 13px; display: flex; align-items: center; justify-content: center; }
.contact-steps b { color: var(--ink); }
.cform { background: var(--surface); border: 1px solid var(--line-strong); border-top: 2px solid var(--gold); border-radius: 10px; padding: 30px 28px 26px; box-shadow: var(--shadow); }
@media (max-width: 560px) { .cform { padding: 24px 18px 20px; } }
.cform .row { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 640px) { .cform .row.two { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; min-width: 0; border: 0; padding: 0; margin-left: 0; margin-right: 0; }
.field > label, .field > legend { font-size: 13.5px; font-weight: 700; color: var(--ink); padding: 0; }
.field .opt { font-weight: 500; color: var(--mute); }
.field input[type=text], .field select, .field textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: color-mix(in srgb, var(--bg) 70%, transparent);
  border: 1px solid var(--line-strong); border-radius: 8px; padding: 12px 14px; min-height: 46px; transition: border-color .2s ease, box-shadow .2s ease;
}
.field textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
.field select { appearance: none; -webkit-appearance: none; padding-right: 40px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none' stroke='%23A8874A' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1.5l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.field select option { color: #0F1A33; background: #fff; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--gold-light); box-shadow: 0 0 0 3px color-mix(in srgb, var(--gold-light) 28%, transparent); }
.field .err { display: none; font-size: 13px; color: #FF9C8F; font-weight: 600; }
:root[data-theme="light"] .field .err { color: #B3261E; }
.field.invalid .err { display: block; }
.field.invalid input[type=text], .field.invalid select, .field.invalid textarea, .field.invalid .chips-r { border-color: #E0705F; }
.chips-r { display: flex; flex-wrap: wrap; gap: 10px; border: 1px solid transparent; border-radius: 10px; }
.chips-r label { position: relative; cursor: pointer; }
.chips-r input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.chips-r span { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 18px; border-radius: 999px; border: 1.5px solid var(--line-strong); font-size: 14.5px; font-weight: 700; color: var(--ink-dim); transition: all .2s ease; }
.chips-r input:checked + span { background: linear-gradient(135deg, var(--gold-light), var(--gold)); color: var(--on-gold); border-color: transparent; }
.chips-r input:focus-visible + span { outline: 2px solid var(--gold-light); outline-offset: 3px; }
.chips-r label:hover span { border-color: var(--gold); }
.cform-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; margin-top: 8px; }
.cform-actions .btn-primary { border: 0; cursor: pointer; font-family: inherit; }
.cform-note { font-size: 13px; line-height: 1.5; color: var(--mute); max-width: 36ch; }
.cform-status { margin-top: 18px; font-size: 14.5px; line-height: 1.55; color: var(--ink); }
.cform-status:empty { display: none; }
.cform-status.is-ok { padding: 16px 18px; border-radius: 8px; background: color-mix(in srgb, var(--gold) 12%, transparent); border: 1px solid color-mix(in srgb, var(--gold) 45%, transparent); }
.cform-status a { color: var(--gold-ink); font-weight: 700; }
.cform-status textarea { width: 100%; margin-top: 12px; min-height: 150px; font: inherit; font-size: 14px; line-height: 1.5; color: var(--ink); background: color-mix(in srgb, var(--bg) 70%, transparent); border: 1px solid var(--line-strong); border-radius: 8px; padding: 12px; }
.cform-status button { margin-top: 10px; font: inherit; font-size: 14px; font-weight: 700; color: var(--gold-ink); background: transparent; border: 1.5px solid var(--line-strong); border-radius: 999px; padding: 10px 18px; cursor: pointer; min-height: 44px; }
.cform-status button:hover { border-color: var(--gold); }
.hp { position: absolute; left: -9999px; }
.hero { overflow: clip; }
.cform .row.two { align-items: end; }
.cform .row.two { align-items: start; }
.quote-cta .btn-primary { max-width: 100%; text-align: center; }
@media (max-width: 560px) { .quote-cta .btn-primary { width: 100%; padding-left: 16px; padding-right: 16px; } }


/* ============================================================
   MÓVIL COMPACTO (v8): páginas más cortas, mismo contenido
   ============================================================ */
.sticky-cta { display: none; }
@media (max-width: 720px) {
  body { padding-bottom: 84px; }
  section { padding: 50px 0; }
  p.lede { font-size: 16.5px; line-height: 1.6; }
  .sh { margin-bottom: 14px; }

  /* hero: diagrama solo con títulos */
  .hero-map .hm-card p { display: none; }
  .hm-card { padding: 14px 18px; }
  .hero-map { gap: 10px; }

  /* tarjetas que se abren al tocar */
  [data-m-toggle] { cursor: pointer; -webkit-tap-highlight-color: transparent; }
  [data-m-toggle]:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 3px; }
  .dim h3::after, .tool h3::after {
    content: ''; display: inline-block; width: 7px; height: 7px; margin-left: 10px;
    border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor;
    transform: translateY(-3px) rotate(45deg); opacity: .6; transition: transform .2s ease; color: var(--gold-ink);
  }
  [data-m-toggle].is-open h3::after { transform: translateY(0) rotate(-135deg); }
  .dim { padding: 18px 18px 18px; }
  .dim .dim-num { position: static; margin-bottom: 8px; }
  .dim:not(.is-open) .dim-lead, .dim:not(.is-open) ul { display: none; }
  .dim h3 { font-size: 18px; }
  .dims { gap: 10px; margin-top: 26px; }

  /* cultura: sin bloque ADN y con foto pequeña */
  .adn { display: none; }
  .duo { margin-top: 36px; padding-top: 32px; gap: 18px; }
  .duo-photo { max-width: 170px; }
  .duo .lede { display: none; }

  /* ancla */
  .anchor-icon { width: 38px; height: 38px; }

  /* implementación: recorrido horizontal */
  .impl-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; margin: 28px -24px 0; padding: 4px 24px 14px; -webkit-overflow-scrolling: touch; }
  .impl-track .stop { flex: 0 0 76%; scroll-snap-align: center; margin-top: 0; }
  .impl-notes { margin-top: 14px; gap: 10px; }

  /* herramientas: lista compacta */
  .tools { gap: 10px; margin-top: 24px; }
  .tool { flex-direction: row; flex-wrap: wrap; align-items: center; padding: 14px 16px; gap: 0 14px; }
  .tool .tool-ico { width: 38px; height: 38px; margin: 0; flex: none; }
  .tool h3 { flex: 1; font-size: 16.5px; margin: 0; }
  .tool:not(.is-open) p, .tool:not(.is-open) .tool-link { display: none; }
  .tool.is-open p, .tool.is-open .tool-link { flex: 0 0 100%; }
  .tool.is-open p { margin-top: 12px; }
  .tool .tool-link { margin-top: 12px; }

  /* diagnóstico y comunidad más breves */
  .diag-arrow { display: none; }
  .diag { gap: 12px; margin-top: 26px; }
  .diag-in, .diag-out { padding: 20px 18px 16px; }
  .diag-in li { padding-top: 9px; padding-bottom: 9px; }
  .comm-fig, .comm-list { display: none; }
  .comm-note { margin-top: 18px; }

  .case-card { padding: 22px 20px; }

  /* botón fijo de contacto */
  .sticky-cta {
    display: flex; justify-content: center; text-align: center; position: fixed; left: 14px; right: 14px; bottom: calc(14px + env(safe-area-inset-bottom)); z-index: 60;
    box-shadow: 0 10px 30px -8px rgba(0,0,0,.55), 0 0 0 1px var(--gold-light);
    opacity: 0; visibility: hidden; transform: translateY(140%);
    transition: transform .3s ease, opacity .25s ease, visibility 0s linear .3s;
  }
  .sticky-cta.is-on { opacity: 1; visibility: visible; transform: none; transition: transform .3s ease, opacity .25s ease; }
}
@media (prefers-reduced-motion: reduce) { .sticky-cta, .sticky-cta.is-on { transition: none; } }
@media (max-width: 720px) {
  .route-v li:not(.is-active) .chips { display: none; }
  .quote-wrap .circuit-box, .circuit-box { padding: 24px 18px; }
  .quote-list.q5 { gap: 8px; margin-top: 20px; }
  .quote-list.q5 li { padding: 12px 14px; font-size: 14.5px; display: flex; gap: 12px; align-items: flex-start; }
  .quote-list.q5 li::before { flex: none; width: 14px; margin: .7em 0 0; }
  .quote-after { margin-top: 18px; font-size: 15.5px; }
  .contact-steps { display: none; }
  .contact-grid { gap: 24px; }
  .cform { padding: 20px 16px 18px; }
  .field { margin-bottom: 12px; }
  #continuidad .lede { font-size: 15.5px; }
}
@media (max-width: 720px) {
  .dim h3, .tool h3 { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .dim h3::after, .tool h3::after { margin-left: 0; flex: none; }
}

/* ============================================================
   v9 · Implementación como recorrido con barco + ajustes de tamaño
   ============================================================ */
[hidden] { display: none !important; }
.impl-meta { display: block; margin: 20px 0 0; font-size: 15.5px; color: var(--ink-dim); }
.impl-meta b { color: var(--ink); font-weight: 700; }
.impl-list { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 12px; }
.impl-list li { padding: 16px 18px; border: 1px solid var(--line-strong); border-top: 2px solid var(--gold); border-radius: 8px; background: var(--surface); }
.impl-list h3 { font-size: 17px; margin: 4px 0 6px; }
.impl-list p { font-size: 14.5px; }
.impl-list .stop-kind { margin: 0; }

.impl-route { margin-top: 34px; }
.ir-track { position: relative; padding-top: 46px; }
.ir-line { position: absolute; left: calc(100% / 12); right: calc(100% / 12); top: 66px; height: 0; border-top: 2px dashed color-mix(in srgb, var(--gold) 70%, transparent); }
.ir-stops { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); }
.ir-stop { display: flex; flex-direction: column; align-items: center; gap: 10px; background: none; border: 0; padding: 0 2px; color: var(--ink-dim); font: inherit; cursor: pointer; min-width: 0; -webkit-tap-highlight-color: transparent; }
.ir-dot { width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--gold); background: var(--bg); color: var(--gold-ink); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; transition: background .3s ease, box-shadow .3s ease, color .3s ease; }
.ir-name { font-size: 13px; font-weight: 700; line-height: 1.25; text-align: center; transition: color .25s ease; }
.ir-stop:hover .ir-dot { border-color: var(--gold-light); }
.ir-stop:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 4px; border-radius: 8px; }
.ir-stop.active .ir-dot { background: var(--gold-light); color: var(--on-gold); box-shadow: 0 0 16px 4px color-mix(in srgb, var(--gold-light) 45%, transparent); }
.ir-stop.active .ir-name { color: var(--gold-ink); }
.ir-boat { position: absolute; top: 24px; width: 36px; height: 36px; transform: translate(-50%, -50%); left: calc(100% / 12); transition: left .6s cubic-bezier(.4, .1, .2, 1); filter: drop-shadow(0 0 8px color-mix(in srgb, var(--gold-light) 60%, transparent)); z-index: 2; pointer-events: none; }
.ir-boat .boat-bob { width: 100%; height: 100%; animation: boat-bob 2.2s ease-in-out infinite; color: var(--gold-light); }
.ir-boat svg { width: 100%; height: 100%; }
.ir-bracket { display: grid; grid-template-columns: repeat(6, 1fr); margin-top: 12px; }
.ir-bracket span { grid-column: 2 / 6; border: 1.5px solid color-mix(in srgb, var(--gold) 80%, transparent); border-top: 0; border-radius: 0 0 8px 8px; padding: 6px 10px 0; height: 28px; text-align: center; font-size: 12px; font-weight: 700; color: var(--gold-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ir-detail { margin-top: 20px; padding: 20px 22px; min-height: 124px; border: 1px solid var(--line-strong); border-left: 3px solid var(--gold); border-radius: 0 10px 10px 0; background: color-mix(in srgb, var(--surface) 75%, transparent); }
.ir-kind { display: block; font-size: 11.5px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; color: var(--gold-ink); margin-bottom: 6px; }
.ir-detail h3 { font-size: 20px; font-weight: 800; margin-bottom: 6px; }
.ir-detail p { font-size: 15.5px; max-width: 60ch; }

ul.impl-notes { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: 1fr; gap: 8px 36px; }
@media (min-width: 800px) { ul.impl-notes { grid-template-columns: 1fr 1fr; } }
ul.impl-notes li { padding-left: 14px; border-left: 2px solid var(--gold); font-size: 14.5px; line-height: 1.5; color: var(--ink-dim); }
ul.impl-notes b { color: var(--ink); }

@media (max-width: 720px) {
  .ir-dot { width: 34px; height: 34px; font-size: 13px; }
  .ir-line { top: 63px; }
  .ir-boat { top: 22px; width: 30px; height: 30px; }
  .ir-track { padding-top: 42px; }
  .ir-name { font-size: 11px; }
  .ir-bracket span { font-size: 11px; }
  .ir-detail { padding: 16px 16px; min-height: 140px; }
  .ir-detail h3 { font-size: 18px; }
  .impl-route { margin-top: 26px; }

  /* cajas más pequeñas */
  .flip-grid { gap: 10px; margin-top: 20px; }
  .flip-card { height: 112px; }
  .flip-front, .flip-back { padding: 14px 18px; }
  .flip-front .idx { margin-bottom: 4px; }
  .flip-front .title { font-size: 16.5px; }
  .flip-back p { font-size: 13.5px; line-height: 1.45; }
  .flip-hint-badge { width: 26px; height: 26px; top: -8px; right: -6px; }
  .flip-hint { margin-top: 14px; }
  #continuidad .lede { font-size: 15.5px; }
  .circuit-box { padding: 20px 18px; }
  .manifest { gap: 12px; }
  .manifest p { font-size: 15px; line-height: 1.55; }
  .manifest h3 { font-size: 18px; }
  .anchor-icon { display: block; width: 34px; height: 34px; }
  .manifest { grid-template-columns: 38px 1fr; gap: 14px; }
}
@media (prefers-reduced-motion: reduce) { .ir-boat { transition: none; } .ir-boat .boat-bob { animation: none; } }

.ir-bracket i { font-style: normal; }
@media (max-width: 720px) { .ir-bracket i { display: none; } }


/* ============================================================
   v10 · Un solo recorrido: bloques sobre la ruta; franja perla
   ============================================================ */
.s-pearl { --bg-deep: #DCE4EE; --steel: #DCE4EE; --slate: #CBD6E4; --shadow: 0 24px 60px rgba(30, 45, 80, 0.14); }
.s-pearl .dim, .s-pearl .duo-photo { box-shadow: 0 10px 30px -18px rgba(20, 34, 62, .35); }
.s-pearl .hm-card { background: var(--surface); }
.route-intro { margin: 10px 0 0; max-width: 64ch; font-size: 15.5px; color: var(--ink-dim); }

.route-blocks { position: relative; height: 62px; margin: 18px 0 0; }
.rb { position: absolute; top: 0; text-align: center; font-size: 12px; line-height: 1.3; color: var(--ink-dim); }
.rb .rb-line { display: block; height: 9px; border: 1.5px solid color-mix(in srgb, var(--gold) 85%, transparent); border-bottom: 0; border-radius: 7px 7px 0 0; margin-bottom: 7px; }
.rb b { display: block; font-size: 10.5px; letter-spacing: .15em; text-transform: uppercase; color: var(--gold-ink); }
.route-ends { display: flex; justify-content: space-between; gap: 18px; margin: 4px 0 6px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-dim); }
.route-ends b { color: var(--gold-ink); }

.rv-end { display: none; }
.rv-bk { display: block; font-size: 10.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--mute); margin-bottom: 3px; }
@media (max-width: 760px) {
  .rv-end { display: block; margin: 0 0 14px; padding: 8px 12px; font-size: 13px; color: var(--ink-dim); border-left: 2px solid var(--gold); }
  .rv-end b { color: var(--gold-ink); }
  .rv-end-bottom { margin: 16px 0 0; }
}
.impl-foot { margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--line); }
.impl-foot .impl-meta { margin: 0 0 12px; }
.impl-foot ul.impl-notes { margin-top: 0; }
@media (max-width: 720px) { .impl-foot { margin-top: 24px; padding-top: 16px; } }

/* Cultura comercial: gris solo en el encabezado y las tres dimensiones; el resto en azul */
#equipo { padding-top: 70px; }
#equipo .adn { margin-top: 0; }
#equipo .duo { margin-top: 56px; padding-top: 0; border-top: 0; }
@media (max-width: 720px) { #equipo { padding: 36px 0 44px; } #equipo .duo { margin-top: 0; } }

/* ¿Por qué un ancla?: ancla dorada visible + ancla grande como marca de agua al fondo */
.anchor-icon { color: var(--gold-ink); filter: drop-shadow(0 0 10px rgba(205,182,127,.35)); }
.circuit-box > .anchor-wm { position: absolute; z-index: 1; right: 44px; top: 50%; transform: translateY(-50%); width: 200px; height: auto; max-height: 150%; color: var(--gold-ink); opacity: .09; pointer-events: none; }
:root[data-theme="light"] .circuit-box > .anchor-wm { opacity: .12; }
@media (max-width: 720px) { .circuit-box > .anchor-wm { right: -30px; top: auto; bottom: -30px; transform: none; width: 190px; } }
@media (min-width: 1280px) and (max-width: 1439px) { .nav-right a.nav-optional { display: none; } }
@media (max-width: 440px) { .nav-right .btn-cta { display: none; } }

/* Menú de tres rayas y módulos (17 nov) */
.burger{height:42px;display:inline-flex;align-items:center;gap:9px;padding:0 14px;background:transparent;border:1px solid var(--gold);border-radius:10px;cursor:pointer;flex:none;color:var(--ink);font:inherit}
.burger .bl{display:flex;flex-direction:column;gap:4px}
.burger .bl i{display:block;width:18px;height:2px;background:var(--gold);border-radius:2px;transition:transform .2s,opacity .2s}
.burger b{font-size:14px;font-weight:700}
.burger:hover{background:color-mix(in srgb,var(--gold) 12%,transparent)}
.burger[aria-expanded="true"] .bl i:nth-child(1){transform:translateY(6px) rotate(45deg)}
.burger[aria-expanded="true"] .bl i:nth-child(2){opacity:0}
.burger[aria-expanded="true"] .bl i:nth-child(3){transform:translateY(-6px) rotate(-45deg)}
@media (max-width:560px){.burger b{display:none}.burger{padding:0 11px}}
.menu-panel{position:absolute;right:max(16px,env(safe-area-inset-right,0px));top:calc(100% + 8px);width:min(340px,calc(100vw - 32px));background:var(--bg-2,var(--surface));border:1px solid var(--line-strong);border-radius:14px;padding:10px;box-shadow:0 24px 60px rgba(0,0,0,.35);display:flex;flex-direction:column;z-index:60}
.menu-panel[hidden]{display:none}
.menu-panel a{display:block;padding:12px 14px;border-radius:10px;text-decoration:none;color:var(--ink);font-weight:700;font-size:15px}
.menu-panel a:hover{background:color-mix(in srgb,var(--gold) 12%,transparent)}
.menu-panel .mp-login{border-top:1px solid var(--line-strong);margin-top:6px;padding-top:14px}
.menu-panel .mp-other{display:flex;align-items:center;gap:10px;margin-top:6px;border:1px solid var(--gold);flex-wrap:wrap}
.menu-panel .mp-other small{width:100%;font-size:11px;letter-spacing:.14em;text-transform:uppercase;color:var(--mute,var(--dim));font-weight:700}
.menu-panel .mp-other i{margin-left:auto;font-style:normal;color:var(--gold)}
.mod-tag{font-size:11px;font-weight:800;letter-spacing:.14em;text-transform:uppercase;color:var(--gold);margin-bottom:10px}
.tool .mod-inc{flex:0;margin-top:14px;padding-top:12px;border-top:1px solid var(--line-strong);font-size:13px;font-weight:700;color:var(--ink)}
@media (min-width:1380px){.menu-panel a.in-bar{display:none}}
.menu-panel a.in-bar-login{display:none}
