/* Control Bolivia — prototipo P1.5-R2 (Blueprint Maestro v.3)
   Paleta aprobada: #1783C1 · #0A3C6E · #0C1D32 · #FFFFFF
   Movimiento: transiciones CSS, curva ease-out propia, prefers-reduced-motion respetado. */

:root {
  color-scheme: light;

  --brand: #1783c1;
  --brand-deep: #0a3c6e;
  --ink: #0c1d32;
  --white: #ffffff;

  --bg: var(--white);
  --surface: #f2f6fa;
  --surface-2: #e4edf5;
  --text: var(--ink);
  --text-muted: #46596d;
  --line: #d5e0ea;
  --line-strong: #b3c6d8;
  --accent: var(--brand);
  --accent-strong: #12639a;   /* texto de enlace: 6.3:1 sobre blanco */
  --accent-soft: #e8f2fa;
  --on-brand: var(--white);
  --error: #b42318;
  --success: #106b45;
  --overlay: rgba(12, 29, 50, 0.62);
  --shadow: 0 12px 30px rgba(12, 29, 50, 0.10);

  --radius: 4px;
  --radius-lg: 8px;
  --max: 1240px;
  --gutter: 20px;
  --tap: 44px;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --dur-fast: 140ms;
  --dur-base: 200ms;
  --dur-slow: 280ms;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0c1d32;
  --surface: #102740;
  --surface-2: #16324f;
  --text: #ffffff;
  --text-muted: #a8bdd1;
  --line: #1e3a57;
  --line-strong: #2f5478;
  --accent: #4fa8e0;
  --accent-strong: #86c7ef;
  --accent-soft: #10293f;
  --error: #ff9d94;
  --success: #74d6a6;
  --overlay: rgba(4, 12, 22, 0.72);
  --shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h, 72px) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  transition: background-color var(--dur-base) var(--ease-out), color var(--dur-base) var(--ease-out),
              opacity var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out);
}

img { max-width: 100%; height: auto; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 16px; letter-spacing: -0.02em; font-weight: 700; }
h1 {
  font-size: clamp(2.15rem, 1.35rem + 3.15vw, 3.55rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
h2 {
  font-size: clamp(1.45rem, 1.1rem + 1.65vw, 2.2rem);
  font-weight: 600; line-height: 1.14; letter-spacing: -0.026em; text-wrap: balance;
}
h3 {
  font-size: clamp(1.06rem, 1rem + 0.42vw, 1.28rem);
  font-weight: 600; line-height: 1.25; letter-spacing: -0.012em;
}
p { margin: 0 0 16px; }
ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: var(--accent-strong); text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }
/* en superficies oscuras el hover necesita un tono claro propio */
.site-footer a:hover,
.trust-strip a:hover { color: #8fc6ef; }
.cta-band a:hover { color: #ffffff; }
.search-block a:hover { color: #bfe6f5; }

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

.container { width: min(100% - (var(--gutter) * 2), var(--max)); margin-inline: auto; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 12px; top: -80px; z-index: 60;
  background: var(--brand-deep); color: #fff;
  padding: 12px 18px; border-radius: var(--radius); text-decoration: none;
}
.skip-link:focus { top: 12px; color: #fff; }

/* --------------------------------------------------------------- botones */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: var(--tap); min-width: var(--tap);
  padding: 11px 20px;
  border: 1px solid transparent; border-radius: var(--radius);
  font: inherit; font-weight: 600; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out),
              border-color var(--dur-fast) var(--ease-out),
              color var(--dur-fast) var(--ease-out),
              transform var(--dur-fast) var(--ease-out);
}
.btn-primary { background: var(--brand-deep); color: #fff; }
.btn-primary:hover { background: #072f57; color: #fff; }
.btn-primary:disabled { background: var(--text-muted); cursor: not-allowed; }
.btn-secondary { background: var(--bg); color: var(--text); border-color: var(--line-strong); }
.btn-secondary:hover { border-color: var(--accent); color: var(--accent-strong); background: var(--accent-soft); }
.btn-ghost { background: transparent; color: var(--text); border-color: rgba(255, 255, 255, 0.42); }
.slide-actions .btn-ghost { color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: #fff; }
.btn-quiet { background: transparent; color: var(--text); border-color: transparent; padding: 8px 10px; }
.btn-quiet:hover { background: var(--surface-2); color: var(--text); }
.btn-lg { padding: 14px 26px; font-size: 1.05rem; }
.btn .icon { flex: none; }

@media (hover: hover) and (pointer: fine) {
  .btn:hover { transform: translateY(-1px); }
  .btn:active { transform: translateY(0); }
}

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: var(--tap); height: var(--tap);
  background: transparent; border: 1px solid transparent; border-radius: var(--radius);
  color: var(--text); cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.icon-btn:hover { background: var(--surface-2); }

.text-link { font-weight: 600; }

/* --------------------------------------------------------------- cabecera */

/* La barra de utilidades vive fuera del <header> para que este pueda fijarse
   durante todo el scroll sin arrastrar la barra secundaria. */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(12, 29, 50, 0.04);
  transition: background-color var(--dur-base) var(--ease-out);
}
.main-bar { position: relative; z-index: 1; }

.utility-bar { background: var(--ink); color: #cbd5e1; font-size: 0.8rem; border-bottom: 1px solid #1b3350; }
[data-theme="dark"] .utility-bar { background: #071320; color: #a9bdd0; border-bottom-color: #16293f; }
.utility-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; padding: 3px 0; flex-wrap: nowrap; }
.utility-note { margin: 0; color: #9fb4c9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.utility-tools { display: flex; align-items: center; gap: 2px; flex-wrap: nowrap; flex: none; }
.utility-link {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: 38px; padding: 4px 10px; flex: none; white-space: nowrap;
  background: transparent; border: 0; border-radius: var(--radius);
  color: #cbd5e1; font: inherit; font-weight: 600; letter-spacing: 0.04em;
  text-decoration: none; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.utility-link:hover { background: rgba(255, 255, 255, 0.10); color: #fff; }
.utility-link[aria-pressed="true"] { background: rgba(255, 255, 255, 0.14); color: #fff; }
.utility-link.is-disabled { color: #7e93a8; cursor: not-allowed; }
.utility-link.is-disabled:hover { background: transparent; }
.utility-sep { width: 1px; height: 18px; background: rgba(255, 255, 255, 0.22); margin: 0 4px; }
.theme-icon-sun { display: none; }
[data-theme="dark"] .theme-icon-sun { display: inline-flex; }
[data-theme="dark"] .theme-icon-moon { display: none; }

.main-inner {
  display: flex; align-items: center; gap: 14px; flex-wrap: nowrap;
  min-height: 72px;
}
/* El logo oscuro del propietario llega en un lienzo con aire superior: se recorta
   con overflow para mostrar solo la lockup (sin alterar el archivo original). */
.brand { position: relative; display: inline-block; flex: none; width: 172px; height: 38px; overflow: hidden; }
.brand img { position: absolute; left: 0; display: block; width: 172px; height: auto; }
.brand .logo-light { top: 0; }
.brand .logo-dark { display: none; bottom: 0; }
[data-theme="dark"] .brand .logo-light { display: none; }
[data-theme="dark"] .brand .logo-dark { display: block; }

.nav-opportunity {
  display: inline-flex; align-items: center; min-height: var(--tap);
  padding: 8px 12px; border-radius: var(--radius);
  color: var(--accent-strong); font-weight: 700; text-decoration: none; white-space: nowrap;
  transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.nav-opportunity:hover { background: var(--accent-soft); color: var(--accent-strong); }
.nav-divider { width: 1px; height: 26px; background: var(--line-strong); flex: none; }

.primary-nav { margin-left: 4px; flex: 0 0 auto; }
.nav-list { display: flex; align-items: center; gap: 2px; flex-wrap: nowrap; }
.nav-link {
  display: inline-flex; align-items: center; min-height: var(--tap);
  padding: 8px 12px; border-radius: var(--radius);
  color: var(--text); font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: background-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.nav-link:hover { background: var(--surface-2); color: var(--text); }
.nav-link.is-current { color: var(--accent-strong); font-weight: 700; }

/* buscador de cabecera */
.header-search { position: relative; margin-right: auto; flex: 0 0 auto; }
.search-trigger {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 40px; padding: 8px 14px;
  background: var(--bg); color: var(--text);
  border: 1px solid var(--accent); border-radius: var(--radius);
  font: inherit; font-size: 0.9rem; font-weight: 600; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out),
              color var(--dur-fast) var(--ease-out),
              transform var(--dur-fast) var(--ease-out);
}
.search-trigger:hover { background: var(--accent-soft); color: var(--accent-strong); }
.search-trigger .icon { color: var(--accent-strong); }
/* La pulsación luminosa del buscador se anima con WAAPI desde el script
   (un solo disparo por evento, máximo dos, curva --ease-out del sistema). */
@media (hover: hover) and (pointer: fine) {
  .search-trigger:hover { transform: translateY(-1px); }
}
.search-form { position: relative; }
.search-field {
  display: flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--accent); border-radius: var(--radius);
  padding: 0 6px;
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
  animation: search-attention 1100ms var(--ease-out) 1 both;
}
/* Atención breve del contorno: un solo pulso, sin desplazar elementos. */
@keyframes search-attention {
  0% { box-shadow: 0 0 0 0 rgba(23, 131, 193, 0); }
  30% { box-shadow: 0 0 0 6px rgba(23, 131, 193, 0.38); }
  100% { box-shadow: 0 0 0 0 rgba(23, 131, 193, 0); }
}
.search-field:focus-within { border-color: var(--accent); background: var(--bg); }
.search-field .icon { color: var(--text-muted); flex: none; }
.search-field input {
  flex: 1 1 auto; min-width: 0; min-height: var(--tap);
  border: 0; background: transparent; font: inherit; color: var(--text); padding: 0 4px;
}
.search-field input:focus-visible { outline-offset: -2px; }
.search-field input::-webkit-search-cancel-button,
.search-field input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; }
.search-field-lg { min-height: 54px; padding: 0 10px; }
.search-field-lg input { min-height: 52px; font-size: 1.02rem; }
.search-field-launch { width: 100%; cursor: pointer; text-align: left; }
.search-placeholder { color: var(--text-muted); flex: 1 1 auto; }
.search-launch-label { color: var(--accent-strong); font-weight: 700; padding-right: 6px; }
.search-clear { width: 34px; height: 34px; color: var(--text-muted); }

.suggestions {
  position: absolute; top: calc(100% + 6px); left: auto; right: 0; z-index: 60;
  width: min(420px, 92vw);
  display: none; max-height: min(60vh, 460px); overflow-y: auto;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow); padding: 8px;
}
.suggestions[data-open="true"] {
  display: block;
  animation: suggestions-in var(--dur-base) var(--ease-out);
  transform-origin: top center;
}
@keyframes suggestions-in {
  from { opacity: 0; transform: translateY(-6px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.suggestion-group {
  padding: 10px 10px 4px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted);
}
.suggestion {
  display: grid; grid-template-columns: 44px 1fr; gap: 12px; align-items: start;
  width: 100%; padding: 8px 10px; border: 0; border-radius: var(--radius);
  background: transparent; font: inherit; color: inherit; text-align: left; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out);
}
.suggestion:hover, .suggestion.is-active { background: var(--accent-soft); }
.suggestion-thumb {
  display: grid; place-items: center; width: 44px; height: 44px; overflow: hidden;
  background: var(--surface-2); color: var(--accent-strong); border-radius: var(--radius);
}
.suggestion-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.suggestion-body { display: grid; gap: 1px; min-width: 0; }
.suggestion-title { font-weight: 600; }
.suggestion-subtitle { font-size: 0.84rem; color: var(--text-muted); }
.suggestion-type {
  grid-column: 2; justify-self: start;
  padding: 2px 8px; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--accent-strong); background: var(--accent-soft); border-radius: 999px; white-space: nowrap;
}
.suggestion-actions { display: grid; gap: 2px; padding: 8px 4px 4px; border-top: 1px solid var(--line); margin-top: 6px; }
.suggestion-action {
  display: flex; align-items: center; gap: 8px; width: 100%;
  padding: 10px; border: 0; border-radius: var(--radius);
  background: transparent; font: inherit; font-weight: 600; color: var(--text); text-align: left; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out);
}
.suggestion-action:hover { background: var(--accent-soft); color: var(--accent-strong); }
.suggestion-empty { padding: 14px 10px; color: var(--text-muted); font-size: 0.9rem; }

.menu-toggle { display: none; }

/* --------------------------------------------------------------- hero / slider */

.hero { position: relative; background: var(--ink); }
.hero-slider { position: relative; overflow: hidden; }
.slides { position: relative; }
.slide {
  position: absolute; inset: 0; opacity: 0; visibility: hidden;
  transition: opacity var(--dur-slow) var(--ease-out), visibility var(--dur-slow) var(--ease-out);
}
.slide.is-active { position: relative; opacity: 1; visibility: visible; }
.slide-media { position: relative; z-index: 0; display: block; width: 100%; height: clamp(320px, 42vw, 520px); object-fit: cover; }
.slide::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, var(--overlay) 0%, rgba(12, 29, 50, 0.42) 48%, rgba(12, 29, 50, 0.18) 100%);
  pointer-events: none;
}
.slide-content {
  position: absolute; z-index: 2; left: 50%; bottom: 74px; transform: translateX(-50%);
  display: grid; gap: 10px; padding: 0; max-width: var(--max);
  color: #fff;
}
.slide-content h2 {
  margin: 0; color: #fff; max-width: 22ch;
  font-weight: 300; letter-spacing: -0.03em; line-height: 1.08;
}
.slide-text { margin: 0; max-width: 52ch; color: #dbe7f2; }
.slide-kicker {
  margin: 0; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
  color: #8fc6ef;
}
.slide-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }

.slider-controls {
  position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  width: min(100% - (var(--gutter) * 2), var(--max));
}
.slider-arrows { display: flex; align-items: center; gap: 10px; }
.slider-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px;
  border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.55);
  background: rgba(12, 29, 50, 0.62); color: #fff; cursor: pointer;
  backdrop-filter: blur(2px);
  transition: background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out),
              transform var(--dur-fast) var(--ease-out);
}
.slider-btn:hover { background: var(--brand); border-color: var(--brand); }
.slider-dots { display: flex; align-items: center; gap: 8px; }
.slider-dot {
  position: relative; width: 32px; height: 44px; border: 0; padding: 0;
  background: transparent; cursor: pointer;
}
.slider-dot::after {
  content: ""; position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%);
  height: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.45);
  transition: background-color var(--dur-base) var(--ease-out);
}
.slider-dot.is-active::after { background: #fff; }

/* --------------------------------------------------------------- secciones */

.section { padding: 60px 0; }
.section-alt { background: var(--surface); border-block: 1px solid var(--line); }
.section-head { max-width: 70ch; margin-bottom: 32px; }
.section-intro { color: var(--text-muted); margin: 0; }
.eyebrow {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent-strong); margin-bottom: 12px;
}
.lead { font-size: clamp(1.05rem, 1rem + 0.35vw, 1.25rem); color: var(--text-muted); max-width: 62ch; }

.dual-composition { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.dual-side { position: relative; }
.dual-side--b { z-index: 2; }
.dual-media {
  margin: 0; aspect-ratio: 3 / 2; overflow: hidden;
  background: var(--surface-2); border: 1px solid var(--line);
}
.dual-media img {
  display: block; width: 100%; height: 100%; object-fit: cover;
  transition: transform 320ms var(--ease-out);
}
/* Intersección diagonal solo en las imágenes: los textos y acciones viven en
   su propia columna y nunca se solapan. */
.dual-side--a .dual-media { margin-right: -72px; clip-path: polygon(0 0, 100% 0, 84% 100%, 0 100%); }
.dual-side--b .dual-media { clip-path: polygon(16% 0, 100% 0, 100% 100%, 0 100%); }
.dual-body { padding: 26px 0 0; max-width: 44ch; }
.dual-body h3 { margin-bottom: 10px; font-weight: 600; letter-spacing: -0.015em; }
.dual-body p { color: var(--text-muted); margin-bottom: 14px; }
.dual-links { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.dual-side { transition: transform 260ms var(--ease-out); }
.dual-side:focus-within .dual-media { outline: 3px solid var(--accent); outline-offset: 3px; }
@media (hover: hover) and (pointer: fine) {
  .dual-side:hover { transform: translateY(-3px); }
  .dual-side:hover .dual-media img { transform: scale(1.035); }
}

.split-grid { display: grid; gap: 20px; }
.split-card {
  display: grid; gap: 14px; padding: 24px;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
  transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.split-card h3 { margin: 0; }
.split-card p { color: var(--text-muted); margin: 0; }
@media (hover: hover) and (pointer: fine) {
  .split-card:hover { border-color: var(--accent); transform: translateY(-2px); }
}

.card-grid { display: grid; gap: 16px; }
.media-card {
  display: grid; gap: 12px; padding: 0; overflow: hidden;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
  transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.media-card-body { padding: 0 20px 20px; display: grid; gap: 8px; }
.media-card h3 { margin: 0; font-size: 1.08rem; }
.media-card p { margin: 0; color: var(--text-muted); font-size: 0.95rem; }
.media-card-link { text-decoration: none; color: inherit; }
@media (hover: hover) and (pointer: fine) {
  .media-card:hover { border-color: var(--accent); transform: translateY(-2px); }
}
.media-figure { margin: 0; background: var(--surface-2); }
.media-figure img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.media-thumb {
  display: grid; place-items: center; width: 56px; height: 56px;
  background: var(--surface-2); color: var(--accent-strong); border-radius: var(--radius);
}
.card-tag {
  justify-self: start; padding: 2px 8px;
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--accent-strong); background: var(--accent-soft); border-radius: 999px;
}
.card-note { font-size: 0.8rem; color: var(--text-muted); margin: 0; }

/* líneas promocionales */
.promo-grid { display: grid; gap: 14px; }
.promo {
  display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start;
  padding: 18px 20px; border: 1px solid var(--line); border-left: 1px solid var(--accent);
  border-radius: var(--radius); background: var(--bg);
}
.promo-icon { color: var(--accent-strong); }
.promo h3 { margin: 0 0 4px; font-size: 1.02rem; }
.promo p { margin: 0; color: var(--text-muted); font-size: 0.94rem; }

/* accesos rápidos */
.quick-grid { display: grid; gap: 12px; }
.quick {
  display: grid; grid-template-columns: 40px 1fr auto; gap: 14px; align-items: center;
  padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg); text-decoration: none; color: inherit;
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.quick:hover { border-color: var(--accent); background: var(--accent-soft); }
.quick-icon { color: var(--accent-strong); }
.quick-title { font-weight: 700; }
.quick-text { display: block; color: var(--text-muted); font-size: 0.88rem; }
.quick-arrow { color: var(--text-muted); }

/* categorías con imagen */
.cat-grid { display: grid; gap: 16px; }
.cat-card {
  display: grid; gap: 0; overflow: hidden; text-decoration: none; color: inherit;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
  transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .cat-card:hover { border-color: var(--accent); transform: translateY(-2px); }
}
.cat-card figure { margin: 0; background: var(--surface-2); }
.cat-card img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.cat-card-body { padding: 16px 18px 18px; display: grid; gap: 6px; }
.cat-card h3 { margin: 0; font-size: 1.02rem; }
.cat-card p { margin: 0; color: var(--text-muted); font-size: 0.9rem; }

/* marcas */
.brand-strip { display: grid; gap: 12px; }
.brand-logo {
  display: grid; place-items: center; padding: 12px; height: 68px;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius);
}
.brand-logo img { max-height: 40px; width: auto; object-fit: contain; filter: grayscale(1); opacity: 0.8;
  transition: filter var(--dur-base) var(--ease-out), opacity var(--dur-base) var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .brand-logo:hover img { filter: none; opacity: 1; }
}

/* --------------------------------------------------------------- confianza */

.trust-strip { background: var(--ink); color: #fff; }
.trust-inner { display: grid; gap: 14px; padding: 26px 0; }
.trust-inner p { margin: 0; display: grid; gap: 2px; }
.trust-inner strong { font-size: 1.05rem; }
.trust-inner span { font-size: 0.85rem; color: #b9c9da; }

/* --------------------------------------------------------------- CTA */

.cta-band { background: var(--brand-deep); color: #fff; }
.cta-inner { display: grid; gap: 18px; padding: 44px 0; align-items: center; }
.cta-inner h2 { margin-bottom: 8px; color: #fff; }
.cta-inner p { margin: 0; color: #d3e4f2; max-width: 60ch; }
.cta-inner .btn-primary { background: #fff; color: var(--brand-deep); }
.cta-inner .btn-primary:hover { background: #e9f1f7; color: var(--brand-deep); }

/* --------------------------------------------------------------- nosotros */

.prose-grid { display: grid; gap: 28px; }
.prose { max-width: 68ch; }
.prose p { color: var(--text-muted); }
.lead-text { font-size: 1.2rem; color: var(--text) !important; font-weight: 600; }

.cap-grid { display: grid; gap: 16px; }
.cap-card {
  padding: 20px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
  transition: border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .cap-card:hover { border-color: var(--accent); transform: translateY(-2px); }
}
.cap-icon { color: var(--accent-strong); margin-bottom: 12px; }
.cap-card h3 { font-size: 1.05rem; margin-bottom: 6px; }
.cap-card p { margin: 0; color: var(--text-muted); font-size: 0.95rem; }

.pillar-grid { display: grid; gap: 16px; }
.pillar {
  padding: 24px; background: var(--bg); border-left: 1px solid var(--accent); border-radius: var(--radius);
}
.pillar h3 { font-size: 1.05rem; margin-bottom: 8px; }
.pillar p { margin: 0; color: var(--text-muted); }

.steps-list { display: grid; gap: 14px; }
.step {
  display: grid; grid-template-columns: 56px 1fr; gap: 16px; align-items: start;
  padding: 20px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.step-index {
  font-size: 0.9rem; font-weight: 700; color: var(--accent-strong);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 0; text-align: center;
}
.step h3 { font-size: 1.05rem; margin-bottom: 4px; }
.step p { margin: 0; color: var(--text-muted); }

.check-list { display: grid; gap: 12px; }
.check-list li { position: relative; padding-left: 30px; color: var(--text-muted); }
.check-list li::before {
  content: "✓"; position: absolute; left: 0; top: 0;
  width: 20px; height: 20px; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent-strong); border-radius: 3px; font-size: 0.8rem; font-weight: 700;
}

/* --------------------------------------------------------------- proyectos */

.project-grid { display: grid; gap: 18px; }
.project-card {
  display: grid; gap: 14px; align-content: start;
  padding: 24px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.project-media { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.project-state {
  display: inline-flex; align-items: center; gap: 8px; margin: 0;
  padding: 4px 10px; font-size: 0.8rem; font-weight: 600;
  background: var(--surface-2); color: var(--text-muted); border-radius: 999px;
}
.state-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text-muted); }
.project-facts { display: grid; gap: 4px; margin: 0; }
.project-facts dt {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted);
}
.project-facts dd { margin: 0 0 10px; color: var(--text-muted); }

.opportunity-cta { display: grid; gap: 18px; align-items: center; }
.opportunity-cta p { color: var(--text-muted); max-width: 62ch; }

/* --------------------------------------------------------------- páginas legales */

.legal-prose { max-width: 78ch; }
.legal-block { padding-bottom: 26px; margin-bottom: 26px; border-bottom: 1px solid var(--line); }
.legal-block:last-of-type { border-bottom: 0; }
.legal-block h2 { font-size: 1.1rem; margin-bottom: 8px; }
.legal-block p { color: var(--text-muted); margin: 0; }
.legal-note { margin-top: 28px; padding: 14px 16px; font-size: 0.9rem;
  color: var(--muted); background: var(--surface); border: 1px dashed var(--line-strong); border-radius: var(--radius); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; font-size: 0.85rem; }
.footer-legal a { color: #cfe1f0; text-decoration: none; }
.footer-legal a:hover { color: #fff; text-decoration: underline; }

/* --------------------------------------------------------------- formularios deshabilitados */

.form-disabled { padding: 22px 24px; border: 1px solid var(--line-strong);
  border-left: 4px solid var(--accent); border-radius: var(--radius); background: var(--surface); }
.form-disabled h2 { font-size: 1.05rem; margin-bottom: 8px; }
.form-disabled p { margin: 0 0 8px; color: var(--text-muted); }
.form-disabled p:last-child { margin-bottom: 0; }
.form-disabled .channel-link { display: inline-flex; align-items: center; gap: 6px;
  font-weight: 600; color: var(--accent-strong); }

/* --------------------------------------------------------------- contacto */

.contact-grid { display: grid; gap: 32px; }
.channel-list { display: grid; gap: 4px; margin: 0 0 16px; }
.channel-list dt {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted);
}
.channel-list dd { margin: 0 0 12px; font-size: 1.05rem; }
.channel-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.channel-link .icon { color: var(--accent-strong); }
.contact-form-wrap {
  padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
}

/* --------------------------------------------------------------- confirmación de envío */

.form-shell { position: relative; }
.confirm {
  display: grid; gap: 14px; justify-items: start;
  padding: 30px 26px; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg);
  animation: confirm-in 320ms var(--ease-out) both;
}
.confirm[hidden] { display: none; }
@keyframes confirm-in {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.confirm-mark { color: var(--success); }
.confirm-circle {
  stroke-dasharray: 145; stroke-dashoffset: 145;
  animation: confirm-draw 560ms var(--ease-out) forwards;
}
.confirm-check {
  stroke-dasharray: 34; stroke-dashoffset: 34;
  animation: confirm-draw 420ms var(--ease-out) 240ms forwards;
}
@keyframes confirm-draw { to { stroke-dashoffset: 0; } }
.confirm-title { margin: 0; font-size: 1.2rem; font-weight: 600; }
.confirm-title:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.confirm-text { margin: 0; color: var(--text-muted); font-size: 0.95rem; max-width: 52ch; }
.confirm-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }

/* --------------------------------------------------------------- formularios */

.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field-row { display: grid; gap: 16px; }
.field label { font-weight: 600; font-size: 0.95rem; }
.req { color: var(--error); }
.field input, .field select, .field textarea {
  width: 100%; min-height: var(--tap);
  padding: 11px 12px;
  font: inherit; color: var(--text);
  background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--radius);
  transition: border-color var(--dur-fast) var(--ease-out);
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { border-color: var(--accent); }
.field [aria-invalid="true"] { border-color: var(--error); }
.field-check { grid-template-columns: 22px 1fr; align-items: start; gap: 10px; }
.field-check input { width: 22px; height: 22px; min-height: 22px; margin-top: 2px; }
.field-check label { font-weight: 500; font-size: 0.95rem; }
.hint { margin: 0; font-size: 0.85rem; color: var(--text-muted); }
.field-error { margin: 0; font-size: 0.85rem; color: var(--error); min-height: 0; }
.field-error:empty { display: none; }
.error-summary {
  margin-bottom: 18px; padding: 16px; border: 1px solid var(--error); border-left-width: 4px;
  border-radius: var(--radius); background: var(--surface-2);
}
.error-summary h3 { margin: 0 0 8px; font-size: 1rem; color: var(--error); }
.error-summary ul { display: grid; gap: 6px; }
.error-summary a { color: var(--error); font-weight: 600; }
.form-status { margin: 4px 0 14px; font-size: 0.95rem; min-height: 0; }
.form-status[data-state="success"] { color: var(--success); font-weight: 600; }
.form-status[data-state="error"] { color: var(--error); font-weight: 600; }
.form-status:empty { display: none; }
.demo-note {
  display: inline-block; margin: 0 0 12px; padding: 4px 10px;
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.04em;
  color: var(--text-muted); background: var(--surface-2); border: 1px dashed var(--line-strong); border-radius: 999px;
}

/* --------------------------------------------------------------- buscador (bloque y diálogo) */

.search-block { background: var(--brand-deep); color: #fff; padding: 34px 0; }
.search-block h2 { color: #fff; }
.search-block .hint { color: #b9cfe4; }
.search-block .demo-note { background: transparent; color: #cfe1f0; border-color: rgba(255, 255, 255, 0.3); }
.search-block .search-field { background: #fff; border-color: transparent; }
.search-form-inline { display: grid; gap: 10px; margin: 14px 0 10px; }
.search-scope { display: grid; gap: 10px; align-items: center; }
@media (min-width: 640px) { .search-scope { grid-template-columns: 1fr auto; } }

.dialog {
  width: min(94vw, 620px); max-height: 88vh; overflow: auto;
  padding: 24px; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg); color: var(--text);
  transform-origin: center;
  transition: opacity 250ms var(--ease-out), transform 250ms var(--ease-out),
              overlay 250ms allow-discrete, display 250ms allow-discrete;
}
@starting-style {
  .dialog[open] { opacity: 0; transform: scale(0.96); }
}
.dialog::backdrop {
  background: rgba(12, 29, 50, 0.62);
  transition: opacity 250ms var(--ease-out), overlay 250ms allow-discrete, display 250ms allow-discrete;
}
@starting-style {
  .dialog[open]::backdrop { opacity: 0; }
}
.dialog-search { width: min(94vw, 780px); }
.dialog-search .search-field-lg { margin-top: 4px; }
.dialog-search .results { max-height: min(52vh, 420px); overflow-y: auto; }
.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.dialog-head h2 { font-size: 1.25rem; margin: 0; }
.dialog-intro { color: var(--text-muted); margin: 12px 0 18px; }
.dialog-foot { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.search-status { font-size: 0.9rem; color: var(--text-muted); min-height: 1.2em; }
.results { display: grid; gap: 8px; margin-top: 10px; }
.result-item {
  display: grid; grid-template-columns: 56px 1fr auto; gap: 14px; align-items: center;
  padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg);
  cursor: pointer; width: 100%; text-align: left; font: inherit; color: inherit;
  transition: background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.result-group {
  padding: 14px 12px 6px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted);
}
.result-item:hover, .result-item.is-active { border-color: var(--accent); background: var(--accent-soft); }
.result-thumb {
  display: grid; place-items: center; width: 56px; height: 56px; overflow: hidden;
  background: var(--surface-2); color: var(--accent-strong); border-radius: var(--radius);
}
.result-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.result-body { display: grid; gap: 2px; min-width: 0; }
.result-title { font-weight: 600; }
.result-subtitle { font-size: 0.88rem; color: var(--text-muted); }
.result-type {
  justify-self: start; padding: 1px 8px; font-size: 0.7rem; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent-strong);
  background: var(--accent-soft); border-radius: 999px;
}
.result-empty { color: var(--text-muted); padding: 12px 0; }
.result-group-title {
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-muted); margin-top: 8px;
}

/* --------------------------------------------------------------- pie */

.site-footer { background: var(--ink); color: #dfe9f2; margin-top: 0; }
.footer-grid { display: grid; gap: 26px; padding: 40px 0 24px; }
.footer-logo-wrap { width: 150px; height: 30px; overflow: hidden; }
.footer-logo { display: block; width: 150px; height: auto; margin-top: -47px; }
.footer-brand p, .footer-contact p { margin: 10px 0 0; font-size: 0.9rem; }
.footer-note { color: #9db3c8; font-size: 0.85rem; }
.footer-label {
  font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: #9db3c8;
}
.footer-nav ul { display: grid; gap: 8px; }
.footer-nav a { color: #dfe9f2; text-decoration: none; }
.footer-nav a:hover { color: #8fc6ef; text-decoration: underline; }
.footer-contact a { color: #8fc6ef; }
.footer-legal {
  padding: 14px 0 26px; margin: 0; border-top: 1px solid #1e3350;
  font-size: 0.8rem; color: #9db3c8;
}
.social-row { display: flex; align-items: center; gap: 8px; margin-top: 12px; }
.social-icon {
  display: inline-grid; place-items: center; width: 38px; height: 38px;
  border: 1px solid #24405f; border-radius: var(--radius); color: #cfe1f0;
  cursor: default;
  transition: border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.social-icon:hover { border-color: #8fc6ef; color: #fff; }

/* --------------------------------------------------------------- entrada */

.entry { min-height: 100vh; display: grid; place-items: center; background: var(--surface); }
.entry-inner { text-align: center; display: grid; gap: 18px; justify-items: center; padding: 48px 0; }
.entry-inner img { background: #fff; border-radius: 4px; padding: 8px 12px; }
.entry-options { display: grid; gap: 14px; width: 100%; max-width: 460px; }
.entry-option {
  display: grid; gap: 4px; justify-items: center; padding: 22px;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius-lg);
  text-decoration: none; color: var(--text);
  transition: border-color var(--dur-fast) var(--ease-out);
}
.entry-option:hover { border-color: var(--accent); }
.entry-lang { font-size: 1.4rem; font-weight: 800; letter-spacing: 0.06em; color: var(--accent-strong); }
.entry-name { font-size: 1.1rem; font-weight: 600; }
.entry-note { font-size: 0.88rem; color: var(--text-muted); }
.entry-status { font-size: 0.9rem; color: var(--text-muted); min-height: 1.2em; }

/* --------------------------------------------------------------- transición de idioma */

html.is-leaving body { opacity: 0; transform: translateY(-6px); }
html.is-entering body { opacity: 0; transform: translateY(8px); }

/* --------------------------------------------------------------- responsive */

@media (min-width: 640px) {
  :root { --gutter: 28px; }
  .field-row { grid-template-columns: 1fr 1fr; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .cap-grid { grid-template-columns: repeat(2, 1fr); }
  .pillar-grid { grid-template-columns: repeat(3, 1fr); }
  .project-grid { grid-template-columns: repeat(2, 1fr); }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .promo-grid { grid-template-columns: repeat(2, 1fr); }
  .quick-grid { grid-template-columns: repeat(2, 1fr); }
  .brand-strip { grid-template-columns: repeat(3, 1fr); }
  .trust-inner { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .search-form-inline { grid-template-columns: 1fr auto; align-items: center; }
  .cta-inner { grid-template-columns: 1fr auto; }
  .opportunity-cta { grid-template-columns: 1fr auto; }
  .split-grid { grid-template-columns: repeat(2, 1fr); }
  .prose-grid { grid-template-columns: 0.8fr 1.2fr; gap: 40px; }
  .footer-grid { grid-template-columns: 1.2fr 1fr 1fr; }
}

@media (min-width: 900px) {
  .cap-grid { grid-template-columns: repeat(3, 1fr); }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .promo-grid { grid-template-columns: repeat(4, 1fr); }
  .quick-grid { grid-template-columns: repeat(3, 1fr); }
  .brand-strip { grid-template-columns: repeat(5, 1fr); }
  .card-grid { grid-template-columns: repeat(3, 1fr); }
  .project-grid { grid-template-columns: repeat(3, 1fr); }
  .contact-grid { grid-template-columns: 0.8fr 1.2fr; gap: 48px; }
  .section { padding: 80px 0; }
  .slide-content { bottom: 82px; }
}

@media (min-width: 1080px) {
  .cap-grid { grid-template-columns: repeat(5, 1fr); }
  .cat-grid { grid-template-columns: repeat(4, 1fr); }
  .quick-grid { grid-template-columns: repeat(3, 1fr); }
  .brand-strip { grid-template-columns: repeat(5, 1fr); }
}

/* Por debajo de 1280 px el buscador sale de la barra principal y ocupa su propia
   fila (no sticky): la cabecera sticky se mantiene en 68–72 px. */
@media (max-width: 1279px) and (min-width: 1080px) {
  .nav-link { padding: 8px 9px; font-size: 0.9rem; }
  .nav-opportunity { padding: 8px 9px; font-size: 0.92rem; }
  .brand { width: 150px; height: 33px; }
  .brand img { width: 150px; }
}

@media (max-width: 1079px) {
  .main-inner { min-height: 68px; }
  .brand { width: 140px; height: 31px; }
  .brand img { width: 140px; }
  .menu-toggle { display: inline-flex; }
  .primary-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    display: none; flex-direction: column; gap: 2px;
    padding: 14px var(--gutter) 20px;
    background: var(--bg); border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .primary-nav[data-open="true"] { display: flex; }
  .nav-list { flex-direction: column; align-items: stretch; }
  .nav-link { padding: 10px 12px; }
  .nav-divider { display: none; }
  .utility-note { display: none; }
}

@media (max-width: 899px) {
  .dual-composition { grid-template-columns: 1fr; gap: 34px; }
  .dual-side--a .dual-media { margin-right: 0; }
  .dual-side--a .dual-media, .dual-side--b .dual-media { clip-path: none; }
  .dual-media { aspect-ratio: 4 / 3; }
  .dual-body { max-width: none; padding-top: 20px; }
  .dual-links .btn { width: 100%; }
}

@media (max-width: 639px) {
  :root { --gutter: 16px; }
  .utility-text { display: none; }
  /* el disparador conserva icono y texto: es reconocible y no compite con la marca */
  .search-trigger { min-height: 40px; padding: 8px 12px; gap: 6px; }
  .search-trigger .icon { width: 19px; height: 19px; }
  .main-inner { gap: 6px; flex-wrap: wrap; }
  .brand { width: 76px; height: 17px; }
  .brand img { width: 76px; }
  .nav-opportunity { padding: 8px 2px; font-size: 0.76rem; letter-spacing: -0.014em; white-space: nowrap; }
  .search-trigger { font-size: 0.8rem; padding: 8px 10px; }
  .search-trigger span { white-space: nowrap; }
  .utility-link { min-width: 38px; justify-content: center; padding: 4px 8px; }
  .utility-tools { width: 100%; justify-content: flex-end; }
  .slide-content { bottom: 66px; }
  .slide-media { height: 400px; }
  .step { grid-template-columns: 1fr; }
  .dialog { padding: 18px; }
  .quick { grid-template-columns: 36px 1fr; }
  .quick-arrow { display: none; }
  .suggestion { grid-template-columns: 40px 1fr; }
  .suggestion-type { grid-column: 2; justify-self: start; }
  .result-item { grid-template-columns: 44px 1fr; align-items: start; }
  .result-type { grid-column: 2; justify-self: start; }
  .result-thumb { width: 44px; height: 44px; }
}

@media (max-width: 359px) {
  .main-inner { gap: 6px; }
  .brand { width: 68px; height: 16px; }
  .brand img { width: 68px; }
  .nav-opportunity { font-size: 0.7rem; padding: 8px 2px; }
  /* sin ancho suficiente, el buscador pasa a una segunda fila compacta */
  .header-search { order: 5; flex: 1 0 100%; margin-right: 0; padding-bottom: 10px; }
  .search-trigger { width: 100%; justify-content: flex-start; }
}

body.menu-open { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
  html.is-leaving body, html.is-entering body { transform: none !important; }
  .suggestions[data-open="true"] { animation: none; }
  .search-field { animation: none; }
  .confirm, .confirm-circle, .confirm-check { animation: none; }
  .confirm-circle, .confirm-check { stroke-dashoffset: 0; }
  .slide { transition: opacity 0.01ms; }
}
