/* ==========================================================================
   Grupo API — hoja de estilos compartida
   Una sola hoja para las 6 webs (Grupo API, API Systems, API Media,
   API Comms, API Archive y Gestor Ciudadano). Cada web cambia el color
   de acento con el atributo data-brand en <body>.
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  --navy: #001c44;
  --navy-hero: #071a3f;
  --navy-deep: #00132f;
  --navy-2: #12316a;
  --ink: #001c44;
  --text: #4a5468;
  --muted: #6b7489;
  --line: #dde6f3;
  --line-soft: #e8eef8;
  --bg: #ffffff;
  --bg-soft: #f5f8ff;
  --ph: #e1ebfd;
  --ph-arc: #cddffb;
  --white: #ffffff;

  --green: #00e599;
  --pink: #ff3f8c;
  --blue: #5b9aff;
  --yellow: #ffb800;
  --purple: #6f46f2;
  --link-blue: #2f63e0;

  --accent: var(--link-blue);
  --on-accent: var(--white);

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 20px;
  --pill: 999px;

  --container: 1200px;
  --topbar-h: 36px;
  --gutter: clamp(20px, 5.5vw, 64px);
  --section-y: clamp(64px, 8vw, 110px);

  --font: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --shadow: 0 20px 50px -20px rgba(0, 28, 68, .25);
}

body[data-brand="systems"] { --accent: var(--green);  --on-accent: var(--navy); }
body[data-brand="media"]   { --accent: var(--blue);   --on-accent: var(--navy); }
body[data-brand="comms"]   { --accent: var(--pink);   --on-accent: var(--navy); }
body[data-brand="archive"] { --accent: var(--yellow); --on-accent: var(--navy); }
body[data-brand="gestor"]  { --accent: var(--purple); --on-accent: var(--white); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
[id] { scroll-margin-top: calc(var(--topbar-h) + 96px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; color: var(--ink); font-weight: 700; line-height: 1.15; letter-spacing: -.02em; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--navy); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm); }
.skip-link:focus { top: 12px; }

.container { width: min(var(--container), 100% - 2 * var(--gutter)); margin-inline: auto; }
.section { padding-block: var(--section-y); }
.section--soft { background: var(--bg-soft); }
.section--navy { background: var(--navy); color: rgba(255, 255, 255, .85); }
.section--navy h2, .section--navy h3 { color: var(--white); }
.section--tight { padding-block: clamp(40px, 5vw, 64px); }
.section + .section--flush-top { padding-top: 0; }

/* ---------- Tipografía ---------- */
.display { font-size: clamp(2.4rem, 5vw, 3.6rem); font-weight: 800; letter-spacing: -.035em; line-height: 1.06; }
.h1 { font-size: clamp(2.1rem, 4.2vw, 3.1rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.08; }
.h2 { font-size: clamp(1.75rem, 3.1vw, 2.35rem); }
.h2--xl { font-size: clamp(1.9rem, 3.4vw, 2.6rem); font-weight: 800; letter-spacing: -.03em; }
.h3 { font-size: clamp(1.15rem, 1.5vw, 1.3rem); }
.h4 { font-size: 1.05rem; }
.lead { font-size: clamp(1.05rem, 1.35vw, 1.2rem); line-height: 1.65; color: var(--text); }
.small { font-size: .875rem; }
.muted { color: var(--muted); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink); margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 22px; height: 4px; border-radius: 2px; background: var(--accent); }
.eyebrow--plain::before { display: none; }
.eyebrow--accent { color: var(--accent); }
.section--navy .eyebrow { color: var(--white); }

.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px 48px; margin-bottom: clamp(28px, 4vw, 44px); flex-wrap: wrap; }
.section-head > div:first-child { flex: 1 1 460px; max-width: 760px; }
.section-head__aside { flex: 0 1 360px; max-width: 380px; color: var(--muted); }
.section-head .link-arrow { margin-bottom: 6px; }

/* ---------- Botones y enlaces ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 24px; border-radius: var(--pill);
  font-weight: 700; font-size: .95rem; line-height: 1.2; white-space: nowrap;
  border: 1.5px solid transparent; cursor: pointer;
  transition: transform .15s ease, background-color .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.arrow { width: 13px; height: 13px; flex: none; }
.btn .arrow { width: 14px; height: 14px; }
.btn--primary { background: var(--navy); color: var(--white); }
.btn--primary:hover { background: #0b2b5e; }
.btn--accent { background: var(--accent); color: var(--on-accent); }
.btn--accent:hover { box-shadow: 0 10px 24px -10px var(--accent); }
.btn--outline { border-color: var(--navy); color: var(--navy); background: transparent; font-weight: 600; }
.btn--outline:hover { background: var(--navy); color: var(--white); }
.btn--ghost { border-color: rgba(255, 255, 255, .45); color: var(--white); font-weight: 600; }
.btn--ghost:hover { border-color: var(--white); background: rgba(255, 255, 255, .08); }
.btn--sm { min-height: 40px; padding: 8px 20px; font-size: .9rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 600; color: var(--ink); font-size: .95rem;
}
.link-arrow span { border-bottom: 2px solid var(--accent); padding-bottom: 1px; }
.link-arrow .arrow { width: 13px; height: 13px; transition: transform .15s ease; }
.link-arrow:hover .arrow { transform: translateX(3px); }
.link-arrow--plain span { border: 0; }
.link-arrow--blue { color: var(--link-blue); }

/* ---------- Topbar + cabecera ---------- */
/* La barra superior queda fija al hacer scroll: siempre se puede volver a Grupo API */
.topbar { background: var(--navy); color: rgba(255, 255, 255, .85); font-size: .8rem; position: sticky; top: 0; z-index: 30; }
.topbar__inner { display: flex; align-items: center; justify-content: space-between; height: var(--topbar-h); gap: 16px; }
.topbar__wordmark { font-size: .62rem; line-height: 1; letter-spacing: .04em; }
.topbar__inner--end { justify-content: flex-end; }
.topbar__group { display: inline-flex; align-items: center; gap: 8px; }
.topbar__group svg { height: 22px; width: auto; }
.topbar__links { display: flex; align-items: center; gap: 22px; }
.topbar a:hover, .topbar button:hover { color: var(--white); }
.topbar__webs { background: none; border: 0; padding: 0; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; color: inherit; font-size: inherit; }
.topbar__webs svg { width: 9px; height: 9px; transition: transform .2s ease; }
.topbar__webs[aria-expanded="true"] svg { transform: rotate(180deg); }
.lang a { opacity: .85; }
.lang a[aria-current="true"] { opacity: 1; font-weight: 600; }

.site-header { position: sticky; top: var(--topbar-h); z-index: 25; background: var(--white); border-bottom: 1px solid var(--line-soft); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 80px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); flex: none; }
.brand__mark { width: 40px; height: 46px; }
.brand__mark--round { width: 46px; height: 46px; }
.brand__text { display: flex; flex-direction: column; line-height: .95; font-size: 1.05rem; letter-spacing: .01em; }
.brand__text b { font-weight: 800; }
.brand__text span { font-weight: 400; letter-spacing: .02em; }
.brand__text--grupo span { font-weight: 400; }
.brand__text--gc b { font-size: 1.12rem; letter-spacing: -.01em; }
.brand__text--gc span { font-size: .62rem; letter-spacing: .12em; text-transform: uppercase; font-weight: 500; margin-top: 3px; }

.nav { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 32px); }
.nav__list { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 32px); }
.nav__list a { color: var(--ink); font-weight: 500; font-size: .95rem; position: relative; padding-block: 6px; }
.nav__list a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .2s ease; }
.nav__list a:hover::after, .nav__list a[aria-current="page"]::after { transform: scaleX(1); }
.nav-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); cursor: pointer; place-items: center; color: var(--ink); }
.nav-toggle svg { width: 20px; height: 20px; }

/* ---------- Panel "Webs del grupo" ---------- */
.group-panel { position: absolute; left: 0; right: 0; top: 100%; max-height: calc(100vh - var(--topbar-h)); max-height: calc(100dvh - var(--topbar-h)); overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; background: var(--white); box-shadow: 0 30px 60px -30px rgba(0, 28, 68, .35); border-top: 1px solid var(--line-soft); }
.group-panel[hidden] { display: none; }
.group-panel__inner { padding-block: 36px 44px; }
.group-panel__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 24px; margin-bottom: 26px; }
.group-panel__head p { color: var(--muted); margin-top: 6px; }
.group-panel__close { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--white); display: grid; place-items: center; cursor: pointer; flex: none; color: var(--ink); }
.group-panel__close svg { width: 14px; height: 14px; }
.group-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.group-card { display: block; padding: 24px 22px; border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease; }
.group-card:hover { border-color: var(--c); box-shadow: var(--shadow); transform: translateY(-2px); }
.group-card__kicker { font-size: .74rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.group-card__title { display: flex; align-items: center; gap: 10px; margin: 6px 0 10px; font-size: 1.35rem; font-weight: 700; color: var(--ink); }
.group-card__title::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--c); }
.group-card__title .arrow { width: 13px; height: 13px; margin-left: auto; }
.group-card p { font-size: .92rem; color: var(--muted); line-height: 1.55; }
.group-card.is-current { border-color: var(--c); }

/* ---------- Placeholders de imagen ---------- */
.ph {
  position: relative; overflow: hidden; background: var(--ph); border-radius: var(--radius-lg);
  min-height: 220px; min-width: 0; /* sin esto, la proporción convierte la altura mínima en un ancho mínimo */
  display: flex; align-items: flex-end;
}
.ph__label { position: relative; z-index: 2; padding: 14px 16px; font-size: .78rem; color: #5b6478; }
.ph--dark { background: #1b396b; border-radius: 0; }
.ph--dark .ph__label { color: rgba(255, 255, 255, .7); }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ph__deco { position: absolute; right: -12%; bottom: -14%; width: 52%; max-width: 270px; aspect-ratio: 84 / 100; pointer-events: none; }
.ph__deco svg { width: 100%; height: 100%; }
.ratio-4x3 { aspect-ratio: 4 / 3; }
.ratio-16x10 { aspect-ratio: 16 / 10; }
.ph[class*="ratio-"] { width: 100%; }
.ratio-3x2 { aspect-ratio: 3 / 2; }
.ratio-sq { aspect-ratio: 1 / 1; }

/* ---------- Hero de marca ---------- */
.hero { padding-block: clamp(48px, 7vw, 90px); border-bottom: 1px solid var(--line-soft); overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(32px, 4vw, 56px); align-items: center; }
.hero__text .display, .hero__text .h1 { margin-bottom: 22px; }
.hero__text .lead { max-width: 600px; margin-bottom: 30px; }
.hero__media { min-height: 420px; height: 100%; max-height: 480px; }
/* Cabecera de portada con fondo (Systems, Comms, Media, Archive): textos a la izquierda
   sobre una imagen o vídeo de fondo. Mientras no hay fondo se ve el símbolo de la marca. */
.hero--bg { position: relative; padding-block: clamp(64px, 9vw, 120px); }
.hero--bg .hero__text { position: relative; z-index: 2; max-width: 640px; }
.hero--bg .lead { max-width: 640px; }
.hero__bg { position: absolute; inset: 0; z-index: 0; }
.hero__bg img, .hero__bg video { width: 100%; height: 100%; object-fit: cover; }
/* Con imagen o vídeo: velo claro a la izquierda para que el texto se lea bien */
.hero__bg:not(:empty)::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(255, 255, 255, .94) 0%, rgba(255, 255, 255, .82) 42%, rgba(255, 255, 255, .15) 75%, rgba(255, 255, 255, 0) 100%); }
.hero--bg:has(.hero__bg:not(:empty)) .hero__arcs, .hero--bg:has(.hero__bg:not(:empty)) .hero__note { display: none; }
.hero__note { position: absolute; right: var(--gutter); bottom: 18px; z-index: 2; margin: 0; font-size: .75rem; color: var(--muted); }
.hero__arcs { position: absolute; z-index: 1; right: -60px; top: 0; bottom: 0; width: min(46vw, 560px); pointer-events: none; }
.hero__arcs svg { height: 100%; width: 100%; }

.breadcrumb { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .8rem; color: var(--muted); margin-bottom: 18px; }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb li:not(:last-child)::after { content: "›"; margin-left: 8px; }
.breadcrumb [aria-current] { color: var(--ink); font-weight: 600; }

.icon-badge {
  display: inline-grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px;
  border-radius: 10px; background: var(--accent); color: var(--on-accent);
  font-weight: 800; font-size: 1.15rem; letter-spacing: -.01em;
}
.card > .icon-badge, .check-card .icon-badge { align-self: flex-start; }
.icon-badge--lg { min-width: 58px; height: 58px; border-radius: 12px; font-size: 1.45rem; margin-bottom: 22px; }
.icon-badge--sm { min-width: 40px; height: 40px; font-size: .95rem; border-radius: 9px; }

/* ---------- Grids ---------- */
/* Rejilla: CSS Grid de Bootstrap 5 (.grid, .grid-cols-*, .gap-*, .g-col-*).
   Puntos de corte y separaciones en src/scss/bootstrap-grupoapi.scss. Por defecto, 20 px entre elementos. */
.gap-split { gap: clamp(32px, 5vw, 64px); }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 64px); align-items: center; }
.split--top { align-items: start; }
.split--faq { grid-template-columns: .6fr 1.4fr; }

/* ---------- Tarjetas ---------- */
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 26px 24px; display: flex; flex-direction: column; gap: 12px;
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
a.card:hover, .card--hover:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.card h3 { font-size: 1.25rem; }
.card p { font-size: .95rem; line-height: 1.6; color: var(--muted); }
.card .link-arrow { margin-top: auto; padding-top: 8px; }
.card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.card__kicker { display: flex; align-items: center; gap: 12px; font-size: .72rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--ink); }

.checklist { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 4px; display: grid; gap: 8px; }
.checklist li { display: flex; gap: 10px; font-size: .9rem; color: var(--ink); line-height: 1.4; }
.checklist li::before { content: ""; flex: none; width: 12px; height: 12px; margin-top: 3px; background: currentColor; -webkit-mask: var(--check) center / contain no-repeat; mask: var(--check) center / contain no-repeat; }
:root { --check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M1.5 6.5l3 3 6-7' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }

.dotlist { display: grid; gap: 9px; }
.dotlist li { display: flex; gap: 12px; font-size: .92rem; color: var(--ink); line-height: 1.45; }
.dotlist li::before { content: ""; flex: none; width: 7px; height: 7px; margin-top: 7px; border-radius: 50%; background: var(--accent); }

.check-card { display: flex; gap: 16px; padding: 22px 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.check-card__icon { flex: none; width: 30px; height: 30px; border-radius: 8px; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; }
.check-card__icon svg { width: 13px; height: 13px; }
.check-card h3, .check-card h4 { font-size: 1.05rem; margin-bottom: 4px; }
.check-card p { font-size: .9rem; color: var(--muted); line-height: 1.55; }

.feature { border-top: 3px solid var(--accent); padding-top: 22px; }
.feature h3 { font-size: 1.15rem; margin-bottom: 10px; }
.feature p { font-size: .93rem; color: var(--muted); }

.numbered .num { display: inline-block; font-size: clamp(2rem, 3vw, 2.4rem); font-weight: 800; color: var(--ink); line-height: 1; padding-bottom: 6px; border-bottom: 3px solid var(--accent); margin-bottom: 16px; letter-spacing: -.02em; }
.numbered h3 { font-size: 1.1rem; margin-bottom: 8px; }
.numbered p { font-size: .93rem; color: var(--muted); }

.step-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px; }
.step-card__n { width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; font-weight: 800; font-size: .95rem; margin-bottom: 16px; }
.step-card h3 { font-size: 1.1rem; margin-bottom: 10px; }
.step-card p { font-size: .9rem; color: var(--muted); }

/* Planes / modalidades */
.plan { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 30px 28px; display: flex; flex-direction: column; gap: 12px; }
.plan h3 { font-size: 1.3rem; }
.plan > p { font-size: .92rem; color: var(--muted); }
.plan .dotlist { margin-top: 6px; }
.plan--featured { background: var(--navy); border-color: var(--navy); }
.plan--featured h3, .plan--featured .dotlist li { color: var(--white); }
.plan--featured > p { color: rgba(255, 255, 255, .78); }
.plan__flag { align-self: flex-start; background: var(--accent); color: var(--on-accent); font-size: .68rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: 4px 10px; border-radius: var(--pill); }

/* Stats */
.stats { display: flex; flex-wrap: wrap; gap: 24px clamp(28px, 5vw, 64px); }
.gap-split .stats { flex-wrap: nowrap; gap: 24px clamp(20px, 3.5vw, 48px); }
.stats > div { min-width: 0; }
.stat__value { display: inline-block; font-size: clamp(2rem, 3.4vw, 2.6rem); font-weight: 800; color: var(--ink); line-height: 1; letter-spacing: -.03em; padding-bottom: 4px; border-bottom: 3px solid var(--accent); }
.stat__label { display: block; font-size: .85rem; color: var(--muted); margin-top: 8px; max-width: 160px; line-height: 1.35; }
.section--navy .stat__value { color: var(--white); }
.section--navy .stat__label { color: rgba(255, 255, 255, .8); max-width: 260px; }

/* Chips & tags */
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border: 1px solid var(--line); border-radius: var(--pill); background: var(--white); color: var(--ink); font-size: .88rem; font-weight: 500; }
.chip--sm { padding: 5px 11px; font-size: .78rem; background: var(--bg-soft); }
.chip--dot::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
button.chip { cursor: pointer; transition: background-color .15s ease, border-color .15s ease; }
button.chip:hover { border-color: var(--ink); }
button.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); font-weight: 600; }
.tag { display: inline-block; padding: 3px 10px; border-radius: var(--pill); background: var(--accent); color: var(--on-accent); font-size: .74rem; font-weight: 700; line-height: 1.5; }
.tag--navy { background: var(--navy); color: var(--white); }
.tag--steel { background: #3c6bb0; color: var(--white); }
.tag--royal { background: #1d3f7a; color: var(--white); }
.tag--outline { background: transparent; border: 1.5px solid var(--accent); color: var(--ink); }

/* Logos */
.logo-box { display: grid; place-items: center; min-height: 92px; padding: 12px; text-align: center; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); font-size: .82rem; color: var(--muted); }
.logo-box--sm { min-height: 66px; }
.logo-box strong { display: block; color: var(--ink); font-size: 1.15rem; font-weight: 800; }

/* Posts / casos */
.post .ph { min-height: 0; aspect-ratio: 16 / 9.4; margin-bottom: 14px; }
.post__meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: .82rem; color: var(--muted); margin-bottom: 10px; }
.post h3 { font-size: 1.1rem; line-height: 1.35; }
.post p { margin-top: 10px; font-size: .9rem; color: var(--muted); }
.post a:hover h3 { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 4px; }

/* Banda CTA */
.cta-band { position: relative; overflow: hidden; background: var(--navy); border-radius: var(--radius-lg); padding: clamp(36px, 5vw, 60px) clamp(28px, 5vw, 56px); display: flex; align-items: center; justify-content: space-between; gap: 24px 40px; flex-wrap: wrap; }
.cta-band h2 { color: var(--white); font-size: clamp(1.5rem, 2.6vw, 2rem); margin-bottom: 6px; position: relative; z-index: 1; }
.cta-band p { color: rgba(255, 255, 255, .82); position: relative; z-index: 1; }
.cta-band .btn { position: relative; z-index: 1; }
.cta-band__deco { position: absolute; right: 24%; top: -10%; height: 120%; opacity: .25; pointer-events: none; }
.cta-band__deco svg { height: 100%; width: auto; }

/* Formulario de contacto */
.contact { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.contact .h1 { margin-bottom: 20px; font-size: clamp(1.9rem, 3.3vw, 2.6rem); }
.contact__lead { color: var(--text); font-size: 1.05rem; max-width: 380px; }
.contact__list { margin-top: 30px; display: grid; gap: 14px; }
.contact__list li { display: flex; align-items: center; gap: 14px; color: var(--ink); font-size: .95rem; }
.contact__icon { width: 34px; height: 34px; border-radius: 50%; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; font-weight: 800; font-size: .8rem; flex: none; }
.seals { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.seals .logo-box { min-height: 62px; min-width: 0; flex: 0 1 116px; font-size: .74rem; }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.field { display: grid; gap: 8px; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: .85rem; font-weight: 500; color: var(--ink); }
.field input, .field textarea { width: 100%; min-height: 52px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--white); transition: border-color .15s ease, box-shadow .15s ease; }
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(0, 28, 68, .08); }
.form__foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 4px; }
.form__foot p { font-size: .8rem; color: var(--muted); flex: 1 1 260px; }
.form__foot a { text-decoration: underline; }
.form__status { grid-column: 1 / -1; font-size: .9rem; color: var(--ink); background: var(--white); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 10px; padding: 12px 16px; }
.form__status[hidden] { display: none; }
.form__status.is-error { border-left-color: #e5484d; }
.form__hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form { position: relative; }
.form button[disabled] { opacity: .6; cursor: progress; }

/* Páginas legales */
.legal-hero { background: var(--bg-soft); border-bottom: 1px solid var(--line-soft); padding-block: clamp(48px, 7vw, 84px); }
.legal-hero p { color: var(--muted); margin-top: 14px; }
.legal { display: grid; grid-template-columns: 240px 1fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.legal__toc { position: sticky; top: calc(var(--topbar-h) + 104px); display: grid; gap: 10px; font-size: .9rem; }
.legal__toc a { color: var(--muted); }
.legal__toc a:hover { color: var(--ink); }
.prose { max-width: 760px; color: var(--text); }
.prose h2 { font-size: 1.35rem; margin: 40px 0 14px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.05rem; margin: 24px 0 10px; }
.prose p, .prose ul, .prose table { margin-bottom: 14px; }
.prose ul { list-style: disc; padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose a { color: var(--link-blue); text-decoration: underline; }
.prose table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.prose th, .prose td { text-align: left; border-bottom: 1px solid var(--line); padding: 10px 8px; vertical-align: top; }
.prose th { color: var(--ink); }
.prose .note { background: var(--bg-soft); border-left: 4px solid var(--link-blue); padding: 14px 18px; border-radius: 8px; font-size: .9rem; }

/* FAQ */
.faq { display: grid; gap: 14px; }
.faq details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.faq summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 24px; font-weight: 700; color: var(--ink); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; font-weight: 700; font-size: 1.1rem; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details > div { padding: 0 24px 22px; font-size: .93rem; color: var(--text); }

/* Footer de marca */
.site-footer { background: var(--navy); color: rgba(255, 255, 255, .82); font-size: .9rem; }
.site-footer__top { display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap; padding-block: 52px 70px; }
.site-footer .brand { color: var(--white); margin-bottom: 18px; }
.site-footer__contact { text-align: right; line-height: 1.9; }
.site-footer__bottom { border-top: 1px solid rgba(255, 255, 255, .14); display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding-block: 20px 26px; font-size: .82rem; }
.site-footer__bottom ul { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.site-footer a:hover { color: var(--white); text-decoration: underline; }

/* ==========================================================================
   Grupo API (home corporativa)
   ========================================================================== */
.g-hero { position: relative; overflow: hidden; background: var(--navy-hero); color: var(--white); min-height: clamp(520px, 62vw, 640px); display: flex; align-items: center; }
.g-hero__media { position: absolute; inset: 0; }
.g-hero__media video, .g-hero__media img { width: 100%; height: 100%; object-fit: cover; }
.g-hero__mark { position: absolute; right: max(-120px, -8vw); top: 50%; transform: translateY(-50%); width: min(62vw, 700px); aspect-ratio: 1; pointer-events: none; }
.g-hero__mark svg { width: 100%; height: 100%; }
.g-hero__content { position: relative; z-index: 2; padding-block: 80px; }
.g-hero .eyebrow { color: #9bb5f2; font-weight: 600; letter-spacing: .18em; margin-bottom: 26px; }
.g-hero h1 { color: var(--white); font-size: clamp(2.2rem, 4.2vw, 3.1rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.12; max-width: 620px; margin-bottom: 36px; }
.g-hero__note { position: absolute; right: var(--gutter); bottom: 22px; z-index: 2; font-size: .75rem; color: rgba(255, 255, 255, .6); }

.biz-card { display: flex; flex-direction: column; }
.biz-card .ph { border-radius: 0; border-top: 5px solid var(--c); min-height: 0; aspect-ratio: 1 / 0.85; margin-bottom: 22px; }
.biz-card h3 { font-size: 1.3rem; margin-bottom: 10px; }
.biz-card p { font-size: .9rem; color: var(--muted); margin-bottom: 14px; }
.biz-card .link-arrow span { border-bottom-color: var(--c); }
.biz-card .ph:nth-of-type(1) { background: #14305f; }

.product { background: #f2f4f8; padding: clamp(40px, 6vw, 70px) clamp(28px, 6vw, 70px); display: grid; grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: center; }
.product .eyebrow { color: var(--link-blue); }
.product h2 { font-size: clamp(2rem, 3.4vw, 2.6rem); margin-bottom: 16px; }
.product__claim { font-size: 1.25rem; color: var(--ink); font-weight: 500; margin-bottom: 18px; }
.product__text { color: var(--muted); max-width: 470px; margin-bottom: 26px; }
.phone { width: min(210px, 70%); aspect-ratio: 9 / 18.5; margin-inline: auto; border: 9px solid var(--navy); border-radius: 30px; background: var(--white); display: grid; place-items: center; font-size: .78rem; color: var(--muted); }

.proj-card { position: relative; display: flex; align-items: flex-end; min-height: 0; aspect-ratio: 1 / 1.15; padding: 22px 22px 24px; color: var(--white); background: var(--bg-c, #14305f); transition: transform .2s ease; }
.proj-card:hover { transform: translateY(-3px); }
.proj-card small { display: block; font-size: .75rem; font-weight: 600; margin-bottom: 6px; }
.proj-card strong { display: block; font-size: 1.3rem; font-weight: 700; line-height: 1.2; margin-bottom: 8px; }
.proj-card span { font-size: .85rem; color: rgba(255, 255, 255, .85); }

.how .feature { border-top: 2px solid var(--navy); }
.how .feature__n { display: block; color: var(--link-blue); font-weight: 700; font-size: .85rem; margin-bottom: 10px; }

.jobs { display: grid; grid-template-columns: 1fr 1fr; background: #f2f4f8; }
.jobs .ph { border-radius: 0; min-height: 440px; background: #1b396b; }
.jobs__text { padding: clamp(40px, 7vw, 110px) clamp(28px, 6vw, 66px); align-self: center; }
.jobs__text .eyebrow { color: var(--link-blue); }
.jobs__text h2 { font-size: clamp(1.9rem, 3.2vw, 2.5rem); margin-bottom: 22px; }
.jobs__quote { font-style: italic; font-size: 1.15rem; color: var(--ink); margin-bottom: 14px; }
.jobs__who { font-size: .88rem; color: var(--muted); margin-bottom: 24px; }

.g-stats { background: var(--navy); color: rgba(255, 255, 255, .8); padding-block: 56px 70px; }
.g-stats .grid > div strong { display: block; color: var(--white); font-size: clamp(2.4rem, 4vw, 3rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; margin-bottom: 6px; }

.members { display: grid; grid-template-columns: 220px 1fr; gap: 32px; align-items: center; }
.members p { color: var(--muted); }
.members .logo-box { min-height: 76px; font-weight: 600; color: var(--ink); font-size: .8rem; }

.g-footer { background: var(--navy-deep); color: rgba(255, 255, 255, .8); font-size: .9rem; }
.g-footer__top { display: grid; grid-template-columns: 1fr auto; gap: 40px; padding-block: 56px 90px; }
.g-footer .brand { color: var(--white); margin-bottom: 20px; }
.g-footer__cols { display: grid; grid-template-columns: repeat(2, auto); gap: 24px 60px; }
.g-footer__cols h3 { color: var(--white); font-size: .95rem; font-weight: 700; margin-bottom: 12px; letter-spacing: 0; }
.g-footer__cols li { margin-bottom: 8px; }
.g-footer a:hover { color: var(--white); text-decoration: underline; }
.g-footer__bottom { border-top: 1px solid rgba(255, 255, 255, .14); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-block: 22px 28px; font-size: .82rem; }
.g-footer__bottom ul { display: flex; flex-wrap: wrap; gap: 8px 22px; }

/* ==========================================================================
   Piezas específicas
   ========================================================================== */
/* Systems */
.support { padding-block: clamp(44px, 5vw, 64px); }
.support__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; }
.support h2 { font-size: clamp(1.6rem, 2.8vw, 2.1rem); margin-bottom: 10px; }
.support p { max-width: 620px; }
.support small { display: block; margin-top: 14px; font-size: .75rem; color: rgba(255, 255, 255, .55); max-width: 620px; }
.aid { position: relative; overflow: hidden; background: var(--ph); border-radius: var(--radius-lg); padding: clamp(28px, 4vw, 40px) clamp(28px, 5vw, 56px); display: flex; align-items: center; justify-content: space-between; gap: 24px 40px; flex-wrap: wrap; }
.aid::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 8px; background: var(--accent); }
.aid h2 { font-size: clamp(1.4rem, 2.4vw, 1.85rem); margin-bottom: 12px; }
.aid p { color: var(--muted); margin-bottom: 16px; }
.aid .chip { font-weight: 700; font-size: .82rem; }
.aid > div { max-width: 640px; }
.partners-label { font-size: .78rem; font-weight: 700; letter-spacing: .16em; color: #3d4a63; text-transform: uppercase; margin: 28px 0 14px; padding-top: 28px; border-top: 1px solid var(--line); }

/* Media */
.slider { position: relative; }
.slider .ph { min-height: 440px; }
.slider__slide { position: absolute; inset: 0; opacity: 0; transition: opacity .6s ease; }
.slider__slide.is-active { opacity: 1; position: relative; }
.live { position: absolute; z-index: 3; top: 18px; left: 18px; display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: var(--pill); background: var(--white); font-size: .72rem; font-weight: 700; letter-spacing: .1em; color: var(--ink); }
.live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #ff4b3a; animation: pulse 1.6s infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.slider__dots { display: flex; justify-content: flex-end; gap: 6px; margin-top: 16px; }
.slider__dots button { width: 18px; height: 4px; border: 0; padding: 0; border-radius: 2px; background: #cddffb; cursor: pointer; }
.slider__dots button[aria-current="true"] { width: 28px; background: var(--accent); }
.ribbon { background: var(--bg-soft); border-bottom: 1px solid var(--line); font-size: .78rem; font-weight: 600; letter-spacing: .16em; color: #3d4a63; }
.ribbon .container { display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; padding-block: 16px; }
.hero__btns-stack { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.play { width: 11px; height: 11px; }
.caption { font-style: italic; font-size: .88rem; color: var(--muted); margin-top: 10px; }
.feature-link { display: inline-flex; align-items: center; gap: 10px; margin-top: 16px; color: var(--ink); font-weight: 700; }

/* Comms */
.esg { display: grid; grid-template-columns: auto 1fr 1.3fr auto; align-items: center; gap: 20px 28px; background: var(--navy); color: rgba(255, 255, 255, .82); border-radius: var(--radius); padding: 22px 30px; margin-bottom: 22px; font-size: .9rem; }
.esg h3 { color: var(--white); font-size: 1.2rem; }
.esg .tag { text-transform: uppercase; letter-spacing: .08em; font-weight: 800; }
.esg a { color: var(--white); font-weight: 700; display: inline-flex; align-items: center; gap: 12px; white-space: nowrap; }
.person .ph { min-height: 0; aspect-ratio: 1 / 1; margin-bottom: 14px; border-radius: var(--radius-lg); }
.person h3 { font-size: 1.05rem; }
.person p { font-size: .88rem; color: var(--muted); margin-top: 4px; }
.where { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.where h2 { font-size: clamp(1.4rem, 2.4vw, 1.75rem); }
.where h2 i { font-style: normal; color: var(--accent); margin-inline: 6px; }

/* Archive */
.svc-card .card__top { margin-bottom: 4px; }
.svc-card h3 { font-size: 1.15rem; line-height: 1.25; }
.svc-card p { font-size: .87rem; }
.svc-card[hidden] { display: none; }
.proj .ph { min-height: 0; aspect-ratio: 16 / 9.4; margin-bottom: 14px; }
.proj h3 { font-size: 1.1rem; line-height: 1.35; margin: 10px 0; }
.proj p { font-size: .9rem; color: var(--muted); }
.proj .stats { margin-top: 18px; gap: 16px 32px; }
.proj .stat__value { font-size: 1.6rem; }
.proj .stat__label { margin-top: 6px; }
.certs { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.certs .logo-box { min-height: 52px; min-width: 110px; }
.certs__label { font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #3d4a63; margin-right: 6px; }

/* Proyecto */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 36px; }
.facts div { border-left: 4px solid var(--accent); padding-left: 18px; }
.facts dt { font-size: .74rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #3d4a63; }
.facts dd { margin: 4px 0 0; font-weight: 700; color: var(--ink); }
.steps-list { display: grid; gap: 22px; }
.steps-list li { display: grid; grid-template-columns: 36px 1fr; gap: 14px; }
.steps-list .step-card__n { margin: 0; }
.steps-list h3 { font-size: 1.05rem; margin-bottom: 4px; }
.steps-list p { font-size: .9rem; color: var(--muted); }
.result { background: var(--navy-2); border-radius: var(--radius); padding: 30px 24px; }
.result strong { display: block; font-size: clamp(2rem, 3.4vw, 2.7rem); font-weight: 800; color: var(--white); letter-spacing: -.03em; line-height: 1.1; }
.result span { font-size: .9rem; color: rgba(255, 255, 255, .8); }
.gallery { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; }
.gallery .ph { min-height: 380px; }
.quote { display: grid; grid-template-columns: 90px 1fr; gap: 20px; background: var(--bg-soft); border-radius: var(--radius-lg); padding: clamp(36px, 6vw, 76px) clamp(28px, 5vw, 60px); }
.quote__mark { font-size: 6rem; line-height: .7; font-weight: 800; color: var(--accent); font-family: Georgia, serif; }
.quote blockquote { margin: 0; font-size: clamp(1.15rem, 1.8vw, 1.4rem); font-weight: 600; color: var(--ink); line-height: 1.4; }
.quote cite { display: block; margin-top: 14px; font-style: normal; color: var(--muted); font-size: .92rem; }

/* Gestor Ciudadano */
.gc-hero { position: relative; overflow: hidden; }
.gc-hero::after { content: ""; position: absolute; right: -6%; top: 6%; width: 46%; aspect-ratio: 1; border-radius: 50%; border: 90px solid #eef3fd; z-index: 0; }
.gc-hero .hero__grid { position: relative; z-index: 1; }
.mock { position: relative; min-height: 470px; }
.mock__panel { position: absolute; right: 0; top: 0; width: 82%; display: grid; grid-template-columns: 120px 1fr; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); font-size: .72rem; }
.mock__panel aside { background: var(--navy); color: rgba(255, 255, 255, .8); padding: 16px 12px; display: grid; align-content: start; gap: 10px; }
.mock__panel aside b { color: var(--white); font-size: .78rem; margin-bottom: 6px; }
.mock__panel aside .is-active { color: var(--white); font-weight: 700; }
.mock__body { padding: 18px 16px 14px; }
.mock__body h4 { font-size: .85rem; margin-bottom: 12px; }
.mock__kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.mock__kpis div { background: var(--bg-soft); border-radius: 8px; padding: 8px 10px; color: var(--muted); font-size: .62rem; }
.mock__kpis strong { display: block; color: var(--ink); font-size: 1rem; font-weight: 800; }
.bars { display: flex; align-items: flex-end; gap: 10px; height: 170px; padding: 14px 10px 0; background: var(--bg-soft); border-radius: 8px; }
.bars span { flex: 1; background: var(--accent); border-radius: 2px 2px 0 0; height: var(--h); transform-origin: bottom; animation: grow .9s ease both; }
@keyframes grow { from { transform: scaleY(0); } }
.mock__note { font-size: .6rem; color: var(--muted); margin-top: 8px; }
.mock__phone { position: absolute; left: 0; top: 34px; width: 210px; border: 9px solid var(--navy); border-radius: 30px; background: var(--white); overflow: hidden; box-shadow: var(--shadow); font-size: .62rem; z-index: 2; }
.mock__phone header { background: var(--accent); color: var(--white); padding: 22px 14px 18px; }
.mock__phone header b { display: flex; align-items: center; gap: 8px; font-size: .92rem; }
.mock__phone header b::before { content: ""; width: 16px; height: 16px; border-radius: 4px; background: rgba(255, 255, 255, .35); }
.mock__phone header p { margin-top: 8px; font-size: .62rem; opacity: .9; }
.mock__apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 12px 10px; }
.mock__apps span { display: grid; justify-items: center; gap: 4px; padding: 8px 2px; border-radius: 8px; background: var(--bg-soft); color: var(--ink); font-size: .56rem; }
.mock__apps i { width: 18px; height: 18px; border-radius: 5px; background: var(--accent); color: var(--white); display: grid; place-items: center; font-style: normal; font-weight: 800; font-size: .6rem; }
.mock__alert { margin: 2px 10px 10px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 9px; color: var(--muted); font-size: .56rem; }
.mock__alert b { display: block; color: var(--ink); font-size: .6rem; margin-bottom: 2px; }
.mock__tabs { display: flex; justify-content: space-between; border-top: 1px solid var(--line); padding: 10px 10px 12px; color: var(--muted); font-size: .54rem; }
.mock__tabs b { color: var(--ink); }
.mock--panel-only .mock__panel { position: relative; width: 100%; }
.mock--panel-only { min-height: 0; }

.kpi-band { background: var(--navy); padding-block: 44px 50px; color: rgba(255, 255, 255, .8); }
.kpi-band strong { display: block; color: var(--white); font-size: clamp(1.5rem, 2.4vw, 1.85rem); font-weight: 800; letter-spacing: -.02em; }
.kpi-band span { font-size: .88rem; }
.module h3 { display: flex; align-items: center; gap: 12px; font-size: 1.15rem; }
.module h3::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); flex: none; }
.module .chips { gap: 8px; }
.ai-note { display: flex; align-items: center; gap: 14px; margin-top: 32px; padding: 16px 22px; border: 1.5px dashed #b9c6de; border-radius: var(--radius); background: var(--white); color: var(--ink); font-size: .93rem; }
.ai-note b { font-weight: 700; }
.ai-note__icon { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: var(--white); display: grid; place-items: center; font-weight: 800; font-size: .8rem; }
.tool h3 { font-size: 1.45rem; }
.tool > p { font-size: 1rem; color: var(--muted); }
.card.whitelabel { flex-direction: row; align-items: center; gap: 14px; }
.whitelabel__shield { width: 38px; height: 38px; border-radius: 8px; background: var(--ph); display: grid; place-items: center; font-size: .5rem; color: var(--muted); flex: none; }
.whitelabel h3 { font-size: 1.1rem; }
.whitelabel p { font-size: .82rem; color: var(--muted); }
.roadmap { list-style: none; display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px; position: relative; margin-top: 10px; }
.roadmap::before { content: ""; position: absolute; left: 20px; right: 20%; top: 20px; height: 2px; background: rgba(255, 255, 255, .25); }
.roadmap li { position: relative; }
.roadmap .step-card__n { width: 40px; height: 40px; margin-bottom: 18px; position: relative; }
.roadmap h3 { color: var(--white); font-size: 1rem; margin-bottom: 10px; }
.roadmap p { font-size: .85rem; color: rgba(255, 255, 255, .75); }
.soft-card { background: var(--bg-soft); border-radius: var(--radius-lg); padding: 28px 24px; }
.soft-card h3 { font-size: 1.15rem; margin-bottom: 10px; }
.soft-card p { font-size: .93rem; color: var(--muted); }

/* ---------- Animación de entrada ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1100px) {
  .esg { grid-template-columns: auto 1fr auto; }
  .esg p { grid-column: 1 / -1; grid-row: 2; }
  .roadmap { grid-template-columns: repeat(3, 1fr); }
  .roadmap::before { display: none; }
}

@media (max-width: 960px) {
  .nav-toggle { display: grid; }
  .nav {
    position: fixed; inset: 0 0 0 auto; width: min(360px, 88vw); z-index: 60;
    flex-direction: column; align-items: stretch; gap: 24px;
    background: var(--white); padding: 90px 28px 28px; box-shadow: -20px 0 60px rgba(0, 28, 68, .2);
    transform: translateX(100%); transition: transform .3s ease; visibility: hidden;
  }
  .nav.is-open { transform: none; visibility: visible; }
  .nav__list { flex-direction: column; align-items: stretch; gap: 4px; }
  .nav__list a { display: block; padding: 12px 0; font-size: 1.1rem; border-bottom: 1px solid var(--line-soft); }
  .nav__list a::after { display: none; }
  .nav-backdrop { position: fixed; inset: 0; background: rgba(0, 20, 50, .45); z-index: 55; }
  .nav-backdrop[hidden] { display: none; }
  /* Con el menú abierto, la cabecera (y su panel) por encima del fondo oscuro */
  .nav-open .site-header { z-index: 60; }
  .nav__close { position: absolute; top: 22px; right: 22px; }
  .hero__grid, .split, .split--faq, .contact, .product, .jobs { grid-template-columns: 1fr; }
  .hero__media { min-height: 300px; }
  .hero__arcs { opacity: .35; }
  .hero__bg:not(:empty)::after { background: rgba(255, 255, 255, .86); }
  .hero__note { display: none; }
  .group-cards { grid-template-columns: repeat(2, 1fr); }
  .members { grid-template-columns: 1fr; }
  .legal { grid-template-columns: 1fr; }
  .legal__toc { position: static; }
  .g-footer__top { grid-template-columns: 1fr; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .gallery { grid-template-columns: 1fr 1fr; }
  .gallery .ph:first-child { grid-column: 1 / -1; }
  .mock { min-height: 440px; max-width: 560px; }
  .g-hero__mark { opacity: .5; }
}
@media (min-width: 961px) { .nav__close, .nav-backdrop { display: none !important; } }

@media (max-width: 640px) {
  .topbar__group span { display: none; }
  .topbar__links { gap: 14px; }
  .site-header__inner { min-height: 68px; }
  .group-cards, .facts { grid-template-columns: 1fr; }
  .form { grid-template-columns: 1fr; }
  .site-footer__contact { text-align: left; }
  .cta-band__deco { right: -10%; }
  .esg { grid-template-columns: 1fr; }
  .esg p { grid-row: auto; }
  .roadmap { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .quote { grid-template-columns: 1fr; }
  .g-footer__cols { grid-template-columns: 1fr 1fr; }
  .mock__panel { width: 100%; grid-template-columns: 1fr; top: 220px; }
  .mock__panel aside { display: none; }
  .mock { min-height: 560px; }
  .mock--panel-only .mock__panel { top: 0; }
  .mock--panel-only { min-height: 0; }
  .btn { white-space: normal; }
}

/* ---------------------------------------------------------------------------
   Páginas institucionales de Grupo API y fichas del catálogo de API Systems
   --------------------------------------------------------------------------- */
.page-hero { padding-bottom: 0; }
.page-hero__lead { max-width: 720px; font-size: 1.08rem; color: var(--text) !important; }
.subnav, .page-tabs .container { display: flex; gap: 6px 28px; flex-wrap: wrap; }
.subnav { margin-top: clamp(28px, 4vw, 44px); }
.subnav a, .page-tabs a { display: inline-block; padding: 12px 0; font-size: .92rem; font-weight: 600; color: var(--muted); border-bottom: 3px solid transparent; }
.subnav a:hover, .page-tabs a:hover { color: var(--ink); }
.subnav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }
.page-tabs { position: sticky; top: calc(var(--topbar-h) + 80px); z-index: 20; background: var(--white); border-bottom: 1px solid var(--line-soft); }

.purpose { max-width: 900px; }
.purpose__text { font-size: clamp(1.5rem, 3vw, 2.3rem); font-weight: 700; line-height: 1.3; color: var(--ink); letter-spacing: -.01em; }

.timeline { position: relative; display: grid; gap: 28px; padding-left: 0; list-style: none; }
.timeline::before { content: ""; position: absolute; left: 70px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.timeline li { display: grid; grid-template-columns: 140px 1fr; gap: 0; align-items: start; }
.timeline__year { position: relative; font-weight: 800; color: var(--ink); background: var(--white); border: 2px solid var(--accent); border-radius: var(--pill); padding: 6px 0; text-align: center; width: 110px; margin-left: 15px; z-index: 1; font-size: .9rem; }
.timeline li > div { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; }
.timeline h3 { font-size: 1.08rem; margin-bottom: 6px; }
.timeline p { font-size: .92rem; color: var(--muted); }

.cert-card { display: flex; flex-direction: column; gap: 14px; padding: 28px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--white); }
.cert-card__seal { align-self: flex-start; display: grid; place-items: center; width: 92px; height: 92px; border-radius: 50%; border: 3px solid var(--accent); color: var(--ink); font-weight: 800; font-size: .88rem; text-align: center; }
.cert-card h2 { font-size: 1.25rem; }
.cert-card p { font-size: .93rem; color: var(--muted); }
.cert-card__meta { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: .85rem; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line-soft); }
.cert-card__meta dt { color: var(--muted); }
.cert-card__meta dd { color: var(--ink); font-weight: 600; margin: 0; }

.h3-sub { font-size: 1.2rem; margin: clamp(40px, 5vw, 56px) 0 20px; }
.area { background: var(--white); border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--radius); padding: 20px; }
.area h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink); margin-bottom: 12px; }
.area li { font-size: .88rem; color: var(--text); padding: 6px 0; border-bottom: 1px solid var(--line-soft); }
.area li:last-child { border-bottom: 0; }
.note-band { display: grid; grid-template-columns: 240px 1fr auto; gap: 12px 32px; align-items: center; margin-top: clamp(32px, 4vw, 44px); padding: 24px 28px; border-radius: var(--radius); background: var(--navy); color: rgba(255, 255, 255, .85); }
.note-band strong { color: var(--white); font-size: 1.05rem; }
.note-band p { font-size: .92rem; }
.note-band .link-arrow { color: var(--accent); }

.flow { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; list-style: none; padding: 0; counter-reset: none; }
.flow li { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px; position: relative; }
.flow h3 { font-size: 1.05rem; margin-bottom: 8px; }
.flow p { font-size: .88rem; color: var(--muted); }

.catalog-card { padding: 22px; }
.catalog-card__num { font-size: .8rem; font-weight: 800; color: var(--ink); background: var(--accent); color: var(--on-accent); border-radius: var(--pill); padding: 3px 10px; align-self: flex-start; }
.catalog-card h3 { font-size: 1.02rem; }
.catalog-card p { font-size: .87rem; }

.price-block { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
.price-block__text { color: var(--muted); margin-top: 16px; }
.price-table { width: 100%; border-collapse: collapse; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; font-size: .95rem; }
.price-table th, .price-table td { text-align: left; padding: 16px 20px; border-bottom: 1px solid var(--line-soft); }
.price-table thead th { background: var(--navy); color: var(--white); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.price-table tbody th { font-weight: 600; color: var(--ink); }
.price-table td { font-weight: 700; color: var(--ink); white-space: nowrap; text-align: right; }
.price-table thead th:last-child { text-align: right; }
.price-table tr:last-child th, .price-table tr:last-child td { border-bottom: 0; }
/* Fichas de área agrupadas en bloques (v1.2) */
.include-group:first-child .h3-sub { margin-top: 0; }
/* Tabla de tiempos de respuesta (prioridad x plan) */
.price-table--matrix td, .price-table--matrix thead th:not(:first-child) { text-align: center; }
.price-table__note { font-size: .82rem; color: var(--muted); margin-top: 12px; }

@media (max-width: 960px) {
  .flow { grid-template-columns: repeat(2, 1fr); }
  .price-block { grid-template-columns: 1fr; }
  .note-band { grid-template-columns: 1fr; }
  .page-tabs .container { flex-wrap: nowrap; overflow-x: auto; }
  .page-tabs a { white-space: nowrap; }
}
@media (max-width: 640px) {
  .flow { grid-template-columns: 1fr; }
  .page-tabs { top: calc(var(--topbar-h) + 68px); }
  .timeline::before { left: 10px; }
  .timeline li { grid-template-columns: 1fr; gap: 10px; padding-left: 28px; }
  .timeline__year { margin-left: 0; width: auto; padding: 4px 14px; justify-self: start; }
  .price-table td { white-space: normal; }
}

/* Menú desplegable "Sobre nosotros" (Grupo API) */
.nav__item--drop { position: relative; }
.nav__drop-btn { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 6px 0; font: inherit; font-weight: 500; font-size: .95rem; color: var(--ink); cursor: pointer; }
.nav__drop-btn svg { width: 10px; height: 10px; transition: transform .2s ease; }
.nav__item--drop.is-open .nav__drop-btn svg { transform: rotate(180deg); }
.nav__drop { display: none; }
.nav__item--drop.is-open .nav__drop { display: block; }
@media (min-width: 961px) {
  .nav__item--drop:hover .nav__drop, .nav__item--drop:focus-within .nav__drop { display: block; }
  .nav__item--drop:hover .nav__drop-btn svg { transform: rotate(180deg); }
  .nav__drop { position: absolute; top: 100%; left: -18px; min-width: 230px; padding: 10px 0; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); z-index: 30; }
  .nav__drop::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
  .nav__drop a { display: block; padding: 9px 18px; font-size: .92rem; }
  .nav__drop a::after { display: none; }
  .nav__drop a:hover, .nav__drop a[aria-current="page"] { background: var(--bg-soft); }
}
@media (max-width: 960px) {
  .nav__drop-btn { width: 100%; justify-content: space-between; padding: 12px 0; font-size: 1.1rem; border-bottom: 1px solid var(--line-soft); }
  .nav__drop a { padding-left: 16px !important; font-size: 1rem !important; }
}

/* Equipos de API Archive */
.team-card { display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.team-card .ph { border-radius: 0; }
.team-card__body { padding: 22px 24px 24px; display: flex; flex-direction: column; gap: 10px; }
.team-card h3 { font-size: 1.2rem; }
.team-card__place { font-size: .85rem; font-weight: 600; color: var(--muted); }
.team-card p { font-size: .92rem; }
.team-card__facts { display: flex; gap: 22px; margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--line-soft); font-size: .85rem; color: var(--muted); }
.team-card__facts strong { color: var(--ink); font-size: 1.05rem; margin-right: 4px; }

/* ---------- Ajustes responsive (v1.3) ---------- */
/* Los hijos de rejillas y bloques de dos columnas pueden estrecharse por debajo de su contenido */
.contact > *, .form > *, .price-block > *, .field, .grid > * { min-width: 0; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.contact__list li { overflow-wrap: anywhere; }
@media (max-width: 960px) {
  .group-panel__inner { padding-block: 24px 32px; }
}
@media (max-width: 640px) {
  .group-panel__head h2 { font-size: 1.25rem; }
  .group-card { padding: 18px; }
  .gap-split .stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 22px 18px; }
  .gap-split .stat__value { font-size: 1.65rem; }
  .seals .logo-box { flex: 1 1 90px; }
  .form__foot .btn { width: 100%; justify-content: center; }
  .price-table th, .price-table td { padding: 14px 14px; }
  .price-table--matrix { font-size: .85rem; }
  .price-table--matrix th, .price-table--matrix td { padding: 12px 8px; }
  .price-table--matrix thead th { font-size: .66rem; letter-spacing: .04em; }
  .price-table--matrix th:first-child { padding-left: 14px; }
}
@media (max-width: 400px) {
  .price-table--matrix th, .price-table--matrix td { padding: 10px 5px; }
  .price-table--matrix thead th { font-size: .6rem; letter-spacing: 0; }
  .price-table--matrix th:first-child { padding-left: 10px; }
}
