/* permisointernacionaldeconducir.com
   Línea visual institucional basada en el logo: azul marino (#012448) y verde azulado (#01717c).
   Cabecera blanca con el emblema, barra de navegación marina, bloques sobrios y alto contraste,
   como un portal de información pública. Títulos en Figtree (cercana al logotipo) y textos en
   Public Sans, una tipografía abierta pensada para sitios de servicio público.
   Los pictogramas de estado mantienen las formas de la señalética vial de la Convención de Viena. */

@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-display: swap;
  font-weight: 300 900;
  src: url(fonts/figtree-latin-wght-normal.woff2) format('woff2-variations');
}
@font-face {
  font-family: 'Public Sans';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url(fonts/public-sans-latin-wght-normal.woff2) format('woff2-variations');
}
@font-face {
  font-family: 'Public Sans';
  font-style: italic;
  font-display: swap;
  font-weight: 100 900;
  src: url(fonts/public-sans-latin-wght-italic.woff2) format('woff2-variations');
}

/* ---------- Tokens ---------- */
:root {
  /* Marca (logo) */
  --navy: #012448;
  --navy-2: #0b3463;
  --navy-3: #1c4a7d;
  --navy-deep: #00172f;
  --teal: #01717c;
  --teal-2: #015a63;
  --teal-bright: #3cbcc5;

  /* Superficies y texto */
  --page: #ffffff;
  --surface: #f3f6f9;
  --panel: #ffffff;
  --ink: #15212d;
  --heading: #012448;
  --muted: #4a5868;
  --rule: #d7dfe7;
  --rule-strong: #b6c3d0;
  --block: #012448;          /* fondos marinos: navegación, portada, avisos */
  --block-ink: #ffffff;
  --block-soft: #c3d2e3;
  --accent: #01717c;         /* acentos verde azulado sobre fondo claro */
  --accent-soft: #e6f2f3;
  --link: #0a5291;
  --link-hover: #012448;
  --link-visited: #5a3b8e;
  --focus: #ffbf47;
  --shadow: 0 1px 2px rgba(1, 36, 72, 0.06), 0 6px 18px rgba(1, 36, 72, 0.07);

  /* Colores de señal (también usados en estilos en línea de algunas páginas) */
  --sign-blue: var(--accent);
  --sign-blue-ink: #ffffff;
  --sign-green: #17784a;
  --sign-red: #c21f2e;
  --sign-amber: #f2b600;

  --display: 'Figtree', 'Public Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --sans: 'Public Sans', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --serif: var(--sans);
  --radius: 6px;
  --radius-sign: 8px;
  --radius-panel: 8px;
  --wrap: 1200px;

  --step--1: 0.875rem;
  --step-0: 1rem;
  --step-1: 1.0625rem;
  --step-2: 1.3rem;
  --step-3: 1.65rem;
  --step-4: 2.1rem;
  --step-5: 2.7rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page: #0b1521;
    --surface: #101d2c;
    --panel: #12202f;
    --ink: #e2e9f1;
    --heading: #eef4fa;
    --muted: #a0b0c1;
    --rule: #233448;
    --rule-strong: #34495f;
    --block: #0c2746;
    --block-soft: #b4c6da;
    --accent: #4cc3cc;
    --accent-soft: rgba(76, 195, 204, 0.12);
    --link: #8cc8ff;
    --link-hover: #ffffff;
    --link-visited: #c3aaf5;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 6px 18px rgba(0, 0, 0, 0.25);
    --sign-green: #2f9d68;
    --sign-red: #e04a57;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --page: #0b1521;
  --surface: #101d2c;
  --panel: #12202f;
  --ink: #e2e9f1;
  --heading: #eef4fa;
  --muted: #a0b0c1;
  --rule: #233448;
  --rule-strong: #34495f;
  --block: #0c2746;
  --block-soft: #b4c6da;
  --accent: #4cc3cc;
  --accent-soft: rgba(76, 195, 204, 0.12);
  --link: #8cc8ff;
  --link-hover: #ffffff;
  --link-visited: #c3aaf5;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 6px 18px rgba(0, 0, 0, 0.25);
  --sign-green: #2f9d68;
  --sign-red: #e04a57;
  color-scheme: dark;
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--step-1);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; }

a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:visited { color: var(--link-visited); }
a:hover { color: var(--link-hover); text-decoration-thickness: 2px; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 2px; }
a:focus-visible { background: var(--focus); color: #0b0c0c; outline-color: var(--focus); box-shadow: 0 3px 0 #0b0c0c; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--display);
  color: var(--heading);
  line-height: 1.18;
  letter-spacing: -0.012em;
  margin: 1.7em 0 0.55em;
  text-wrap: balance;
}
h1 { font-size: clamp(2rem, 1.35rem + 2.1vw, var(--step-5)); font-weight: 800; line-height: 1.1; letter-spacing: -0.022em; margin-top: 0.15em; }
h2 { font-size: var(--step-3); font-weight: 750; }
h3 { font-size: var(--step-2); font-weight: 700; }
h4 { font-size: var(--step-1); font-weight: 700; }

/* Marca de sección: barra corta verde azulado sobre cada h2 del contenido */
main h2::before {
  content: "";
  display: block;
  width: 44px;
  height: 4px;
  border-radius: 2px;
  background: var(--accent);
  margin-bottom: 0.6em;
}

p { margin: 0 0 1em; }
strong { font-weight: 700; }

.skip {
  position: absolute; left: -999px; top: 0;
  background: var(--focus); color: #0b0c0c; padding: 10px 16px; font-family: var(--display); font-weight: 700; z-index: 20;
}
.skip:focus { left: 8px; top: 8px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }

/* ---------- Franja superior ---------- */
.topbar { background: var(--navy-deep); color: #d3deea; font-size: 0.82rem; line-height: 1.4; }
.topbar-inner { display: flex; align-items: center; min-height: 36px; padding-top: 6px; padding-bottom: 6px; }
.topbar p { margin: 0; display: flex; align-items: center; gap: 8px; }
.topbar .ico { width: 16px; height: 16px; color: var(--teal-bright); }

/* ---------- Cabecera ---------- */
.masthead { background: var(--panel); font-family: var(--display); }
.masthead-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 20px 32px; flex-wrap: wrap;
  padding-top: 18px; padding-bottom: 18px;
}
.brand { display: inline-flex; align-items: center; gap: 14px; color: inherit; text-decoration: none; }
.brand:visited { color: inherit; }
.brand:hover { color: inherit; }
.brand:focus-visible { background: transparent; box-shadow: none; outline: 3px solid var(--focus); outline-offset: 4px; }
.brand-emblem { display: block; width: 74px; height: 60px; flex: none; }
.brand-name { display: block; font-weight: 800; line-height: 1.02; letter-spacing: -0.02em; }
.brand-l1 { display: block; font-size: 1.62rem; color: var(--heading); }
.brand-l2 { display: block; font-size: 1.62rem; color: var(--accent); }
.brand-sub { display: block; margin-top: 6px; font-family: var(--sans); font-weight: 500; font-size: 0.8rem; letter-spacing: 0; color: var(--muted); }

.masthead-meta { list-style: none; margin: 0; padding: 0; display: flex; gap: 10px 26px; flex-wrap: wrap; font-family: var(--sans); font-size: 0.88rem; color: var(--muted); }
.masthead-meta li { display: flex; align-items: center; gap: 8px; }
.masthead-meta .ico { width: 22px; height: 22px; color: var(--accent); }

.nav { background: var(--block); border-bottom: 4px solid var(--teal); }
.nav-inner { display: flex; flex-wrap: wrap; gap: 0; }
.nav a {
  color: #fff; text-decoration: none; font-family: var(--display); font-weight: 650; font-size: 1.02rem; letter-spacing: 0.005em;
  padding: 14px 18px 13px; position: relative;
}
.nav a:first-child { margin-left: -18px; }
.nav a:visited { color: #fff; }
.nav a:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.1); }
.nav a[aria-current="page"]::after,
.nav a:hover::after {
  content: ""; position: absolute; left: 18px; right: 18px; bottom: -4px; height: 4px; background: var(--teal-bright);
}
.nav a:focus-visible { background: var(--focus); color: #0b0c0c; box-shadow: none; outline: none; }

/* ---------- Estructura: columna de trámites + contenido ---------- */
.layout {
  max-width: var(--wrap); margin: 0 auto; padding: 36px 24px 72px;
  display: grid; grid-template-columns: 300px minmax(0, 1fr); grid-template-areas: "aside main";
  gap: 48px; align-items: start;
}
.layout > main { grid-area: main; min-width: 0; }
.layout > aside { grid-area: aside; }

.crumbs { font-family: var(--sans); font-size: var(--step--1); color: var(--muted); margin-bottom: 14px; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 6px; }
.crumbs li { display: inline-flex; align-items: center; gap: 6px; }
.crumbs li + li::before { content: ""; width: 6px; height: 6px; border-right: 1.6px solid var(--rule-strong); border-top: 1.6px solid var(--rule-strong); transform: rotate(45deg); margin-right: 2px; }
.crumbs a { color: var(--link); }
.crumbs [aria-current="page"] { color: var(--muted); }

.lead { font-size: 1.22rem; line-height: 1.55; color: var(--ink); max-width: 64ch; }
.prose { max-width: 70ch; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: 0.45em; }
.prose li::marker { color: var(--accent); }
.prose table { border-collapse: collapse; width: 100%; font-size: var(--step-0); margin: 1em 0 1.6em; border: 1px solid var(--rule); }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--rule); vertical-align: top; }
.prose thead th { background: var(--surface); font-family: var(--display); font-weight: 700; color: var(--heading); border-bottom: 2px solid var(--rule-strong); }
.prose tbody th { font-family: var(--display); font-weight: 700; color: var(--heading); background: var(--surface); width: 30%; }
.prose blockquote { margin: 1.2em 0; padding: 12px 18px; border-left: 4px solid var(--accent); background: var(--surface); }
.prose caption { padding: 0 0 8px; }
.muted { color: var(--muted); }
.small { font-size: var(--step--1); }

/* ---------- Portada (inicio) ---------- */
.sign {
  position: relative;
  background-color: var(--block);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 400' fill='none' stroke='%23ffffff' stroke-opacity='.11' stroke-width='1.4'%3E%3Ccircle cx='200' cy='200' r='190'/%3E%3Cellipse cx='200' cy='200' rx='95' ry='190'/%3E%3Cellipse cx='200' cy='200' rx='164.5' ry='190'/%3E%3Cpath d='M200 10v380M10 200h380M35.5 105h329M35.5 295h329M105 35.5h190M105 364.5h190'/%3E%3C/svg%3E"),
    linear-gradient(135deg, var(--block) 0%, var(--navy-2) 100%);
  background-repeat: no-repeat;
  background-position: right -90px top -40px, 0 0;
  background-size: 440px 440px, auto;
  color: var(--block-ink);
  border-radius: var(--radius-sign);
  border-top: 6px solid var(--teal-bright);
  padding: 38px 36px 30px;
  box-shadow: var(--shadow);
}
.sign h1 { color: #fff; margin: 0 0 12px; font-size: clamp(2rem, 1.3rem + 2.4vw, 3rem); max-width: 18ch; }
.sign h1::before { display: none; }
.sign p { color: #d7e2ef; margin: 0 0 22px; font-size: 1.12rem; max-width: 56ch; }

.search { position: relative; max-width: 640px; }
.search label { display: block; font-family: var(--display); font-weight: 700; font-size: 1.05rem; margin-bottom: 8px; color: var(--ink); }
.sign .search label { color: #fff; }
.search-row { display: flex; gap: 0; }
.search input {
  flex: 1; min-width: 0; font: inherit; font-size: 1.15rem; padding: 13px 16px; height: 56px;
  border-radius: var(--radius) 0 0 var(--radius); border: 2px solid var(--navy); border-right: 0; background: #fff; color: #0b1a29;
}
.sign .search input { border-color: #fff; }
.search input::placeholder { color: #66737f; }
.search input:focus { outline: 3px solid var(--focus); outline-offset: 0; box-shadow: inset 0 0 0 2px #0b0c0c; }
.search button {
  font-family: var(--display); font-size: 1.05rem; font-weight: 750; padding: 0 24px; height: 56px; cursor: pointer;
  border-radius: 0 var(--radius) var(--radius) 0; background: var(--teal); color: #fff; border: 2px solid var(--teal);
}
.search button:hover { background: var(--teal-2); border-color: var(--teal-2); }
.sign .search button { background: var(--teal-bright); border-color: var(--teal-bright); color: var(--navy); }
.sign .search button:hover { background: #6fd2d9; border-color: #6fd2d9; }
.search button:focus-visible { outline: 3px solid var(--focus); outline-offset: 0; box-shadow: inset 0 0 0 2px #0b0c0c; }

.results {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 5;
  background: var(--panel); color: var(--ink); border: 1px solid var(--rule-strong); border-radius: var(--radius);
  list-style: none; margin: 0; padding: 6px; box-shadow: 0 14px 34px rgba(1, 23, 47, 0.28);
  max-height: 360px; overflow: auto; font-family: var(--sans);
}
.results[hidden] { display: none; }
.results a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 4px; color: inherit; text-decoration: none; }
.results a:visited { color: inherit; }
.results a:hover, .results a[aria-selected="true"] { background: var(--accent-soft); color: var(--ink); }
.results a[aria-selected="true"] { box-shadow: inset 3px 0 0 var(--accent); }
.results .r-name { font-weight: 700; flex: 1; }
.results .r-status { font-size: var(--step--1); color: var(--muted); }
.results .r-empty { padding: 10px; color: var(--muted); }

/* Destinos frecuentes */
.destinos {
  list-style: none; margin: 28px 0 0; padding: 20px 0 0; border-top: 1px solid rgba(255, 255, 255, 0.22);
  display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px;
}
.destinos::before {
  content: "Destinos frecuentes"; grid-column: 1 / -1;
  font-family: var(--display); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--block-soft);
}
.destinos a {
  display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 1px 11px; padding: 10px 14px; min-height: 58px;
  background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.16); border-radius: var(--radius);
  color: #fff; text-decoration: none; font-family: var(--display); font-weight: 700; font-size: 1.04rem; line-height: 1.2;
  transition: background-color 0.15s, border-color 0.15s;
}
.destinos a:visited { color: #fff; }
.destinos a:hover { background: rgba(255, 255, 255, 0.13); border-color: rgba(255, 255, 255, 0.4); color: #fff; }
.destinos a .ico { grid-row: span 2; width: 24px; height: 24px; }
.destinos .d-name { grid-column: 2; }
.destinos .d-status { grid-column: 2; font-family: var(--sans); font-weight: 500; font-size: 0.8rem; line-height: 1.25; color: var(--block-soft); }

/* ---------- Pictogramas de estado (forma de señal + texto) ---------- */
.status { display: inline-flex; align-items: center; gap: 8px; font-family: var(--display); font-weight: 700; color: var(--heading); }
.ico { color: var(--muted); width: 22px; height: 22px; flex: none; }
.ico-lg { width: 64px; height: 64px; }
.sign .status, .sign .ico { color: #fff; }
.sign .results .ico { color: var(--muted); }

.status-card {
  display: flex; gap: 20px; align-items: flex-start;
  background: var(--panel); border: 1px solid var(--rule); border-left: 6px solid var(--rule-strong); border-radius: var(--radius-panel);
  padding: 22px 24px; margin: 22px 0 30px; max-width: 70ch; box-shadow: var(--shadow);
}
.status-card:has([href="#s-obligatorio"]) { border-left-color: #1f4fa0; }
.status-card:has([href="#s-recomendado"]) { border-left-color: var(--sign-red); }
.status-card:has([href="#s-depende"]) { border-left-color: var(--sign-amber); }
.status-card:has([href="#s-no-requerido"]) { border-left-color: var(--sign-green); }
.status-card .status-label { font-family: var(--display); font-weight: 800; color: var(--heading); font-size: 1.45rem; line-height: 1.2; margin: 2px 0 8px; }
.status-card p { margin: 0; }

/* ---------- Columna izquierda: dónde tramitar ---------- */
.empresas { font-family: var(--sans); font-size: 0.94rem; line-height: 1.5; }
.empresas-box { background: var(--panel); border: 1px solid var(--rule); border-radius: var(--radius-panel); overflow: hidden; box-shadow: var(--shadow); }
.empresas h2 { font-size: 1.12rem; margin: 0; padding: 18px 20px 6px; background: var(--block); color: #fff; }
.empresas h2::before { display: none; }
.empresas .intro { margin: 0; padding: 0 20px 16px; background: var(--block); color: var(--block-soft); font-size: 0.86rem; border-bottom: 4px solid var(--teal); }
.empresa { padding: 16px 20px 18px; border-top: 1px solid var(--rule); }
.empresa:first-of-type { border-top: 0; }
.empresa.destacada { box-shadow: inset 4px 0 0 var(--accent); background: var(--accent-soft); }
.empresa h3 { font-size: 1.04rem; margin: 0 0 2px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.empresa h3 a { color: var(--heading); text-decoration: none; }
.empresa h3 a:hover { text-decoration: underline; }
.tag {
  font-family: var(--display); font-size: 0.68rem; font-weight: 750; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 3px; background: var(--teal); color: #fff; white-space: nowrap; vertical-align: middle;
}
.empresa .web { display: inline-block; margin-bottom: 8px; font-weight: 600; font-size: 0.9rem; }
.empresa .estado { display: flex; align-items: center; gap: 8px; font-weight: 700; margin: 2px 0 6px; color: var(--ink); }
.empresa .estado::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--sign-green); box-shadow: 0 0 0 3px color-mix(in srgb, var(--sign-green) 22%, transparent); flex: none; }
.empresa p { margin: 0 0 6px; }
.c-pais { margin: 12px 0 2px !important; font-family: var(--display); font-weight: 700; font-size: 0.78rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.contactos { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 4px; }
.contactos li { display: flex; gap: 8px; align-items: center; min-width: 0; }
.contactos .ico { width: 16px; height: 16px; color: var(--accent); }
.contactos .pais { color: var(--muted); font-size: 0.8rem; min-width: 70px; }
.contactos a { overflow-wrap: anywhere; font-size: 0.9rem; }
.nw { white-space: nowrap; }
.aviso {
  display: flex; gap: 8px; align-items: flex-start; margin-top: 10px; padding: 9px 12px;
  border-radius: 0 var(--radius) var(--radius) 0; border-left: 4px solid var(--sign-amber);
  background: color-mix(in srgb, var(--sign-amber) 14%, var(--panel)); font-weight: 600; color: var(--ink);
}
.aviso .ico { width: 18px; height: 18px; margin-top: 2px; }
.empresas .pie { padding: 14px 20px 16px; border-top: 1px solid var(--rule); background: var(--surface); font-size: 0.84rem; color: var(--muted); margin: 0; }

/* Leyenda de estados */
.leyenda {
  display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 0 24px; margin: 0; max-width: 70ch; align-items: baseline;
  border: 1px solid var(--rule); border-radius: var(--radius-panel); padding: 4px 20px; background: var(--panel);
}
.leyenda dt, .leyenda dd { margin: 0; padding: 13px 0; border-top: 1px solid var(--rule); }
.leyenda dt:first-of-type, .leyenda dt:first-of-type + dd { border-top: 0; }

/* ---------- Tabla de países ---------- */
.filtros {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px 16px; align-items: end; margin: 10px 0 14px; font-family: var(--sans);
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius-panel); padding: 16px 18px;
}
@media (min-width: 1100px) { .filtros { grid-template-columns: 1fr 0.9fr 1.3fr 0.95fr; } }
.filtros label { display: grid; gap: 5px; font-family: var(--display); font-size: 0.9rem; font-weight: 700; color: var(--heading); }
.filtros input, .filtros select {
  font: inherit; font-family: var(--sans); font-weight: 400; font-size: 1rem; padding: 9px 11px; height: 44px;
  border-radius: var(--radius); border: 2px solid var(--rule-strong); background: var(--panel); color: var(--ink); width: 100%; min-width: 0;
}
.filtros input:focus, .filtros select:focus { outline: 3px solid var(--focus); outline-offset: 0; border-color: var(--navy); }
.contador { font-family: var(--display); font-weight: 700; font-size: var(--step--1); color: var(--muted); margin: 0 0 10px; }
.tabla-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--rule); border-radius: var(--radius-panel); box-shadow: var(--shadow); }
table.paises { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 0.97rem; }
table.paises caption { font-family: var(--sans); }
table.paises th {
  text-align: left; font-family: var(--display); font-weight: 750; font-size: 0.8rem; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--heading); padding: 12px 16px; border-bottom: 2px solid var(--rule-strong); border-top: 1px solid var(--rule);
  position: sticky; top: 0; background: var(--surface);
}
table.paises td { padding: 11px 16px; border-bottom: 1px solid var(--rule); vertical-align: middle; }
table.paises tbody tr:nth-child(even) td { background: color-mix(in srgb, var(--surface) 55%, var(--panel)); }
table.paises tbody tr:hover td { background: var(--accent-soft); }
table.paises tr:last-child td { border-bottom: 0; }
table.paises td a { font-weight: 700; }
table.paises .status { font-weight: 650; font-size: 0.95rem; }
table.paises .conv { white-space: nowrap; color: var(--muted); }
table.paises tr[hidden] { display: none; }

/* ---------- Fichas, listas y bloques ---------- */
.ficha-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; margin: 12px 0 28px; max-width: 70ch; font-family: var(--sans); }
.dato { background: var(--surface); border: 1px solid var(--rule); border-top: 3px solid var(--accent); border-radius: var(--radius-panel); padding: 14px 18px 16px; }
.ficha-grid .dato h3 { margin: 0 0 6px; font-size: 0.78rem; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); font-weight: 750; }
.dato p { margin: 0; font-size: 1rem; line-height: 1.5; }
.check { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.yes { color: var(--sign-green); font-weight: 800; display: inline-flex; align-items: center; gap: 6px; }
.yes::before { content: ""; width: 16px; height: 16px; border-radius: 50%; background: var(--sign-green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='m4.2 8.3 2.5 2.5 5-5.4' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat; }
.no { color: var(--muted); font-weight: 700; }

.fuentes { font-family: var(--sans); font-size: 0.95rem; max-width: 70ch; padding-left: 1.4em; margin: 0 0 1em; }
.fuentes li { margin-bottom: 8px; padding-left: 4px; }
.fuentes li::marker { color: var(--accent); font-weight: 700; }
.fuentes .host { color: var(--muted); font-size: 0.85rem; }

.nota {
  font-family: var(--sans); font-size: 0.92rem; color: var(--muted); max-width: 70ch;
  background: var(--surface); border-left: 4px solid var(--rule-strong); padding: 12px 16px; border-radius: 0 var(--radius) var(--radius) 0;
}

.cta {
  max-width: 70ch; margin: 34px 0; padding: 22px 26px 20px; border-radius: var(--radius-sign);
  background: var(--block); color: #fff; font-family: var(--sans);
  border-left: 6px solid var(--teal-bright); box-shadow: var(--shadow);
}
.cta h2, .cta h3 { color: #fff; margin: 0 0 8px; font-size: 1.32rem; }
.cta h2::before { display: none; }
.cta p { margin: 0 0 6px; color: #dce6f1; }
.cta p:last-child { margin: 12px 0 0; }
.cta a, .cta a:visited { color: #fff; font-weight: 700; text-decoration-thickness: 2px; }
.cta a:hover { color: var(--teal-bright); }
.cta a:focus-visible { color: #0b0c0c; }
.cta .status { color: #fff; }
.cta .ico { color: #fff; }

.articulos { list-style: none; padding: 0; margin: 0; max-width: 72ch; }
.articulo { padding: 18px 0 20px; border-top: 1px solid var(--rule); display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 6px 22px; }
.articulo:first-child { border-top: 2px solid var(--rule-strong); }
.articulo .ref {
  justify-self: start; align-self: start; font-family: var(--display); font-weight: 750; font-size: 0.88rem; line-height: 1.3;
  color: var(--accent); background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  padding: 4px 10px; border-radius: 4px;
}
.articulo h3 { margin: 0 0 4px; font-size: 1.15rem; }
.articulo p { margin: 0; }

/* Tarjetas de convenciones y road trips */
.convs, .posts { list-style: none; padding: 0; margin: 0; max-width: 72ch; display: grid; gap: 12px; }
.convs li, .posts li {
  background: var(--panel); border: 1px solid var(--rule); border-left: 4px solid var(--navy-3); border-radius: var(--radius-panel);
  padding: 16px 20px; transition: border-color 0.15s, box-shadow 0.15s;
}
.convs li:hover, .posts li:hover { border-left-color: var(--accent); box-shadow: var(--shadow); }
.convs h3 { margin: 0 0 4px; font-size: 1.18rem; }
.convs h3 a, .posts h3 a { color: var(--heading); text-decoration: none; }
.convs h3 a:hover, .posts h3 a:hover { text-decoration: underline; color: var(--heading); }
.convs .meta, .posts .meta { font-family: var(--sans); font-size: var(--step--1); color: var(--muted); margin-bottom: 6px; }
.convs .meta:last-child { margin-bottom: 0; }
.convs p:last-child { margin-bottom: 0; }
.posts h3 { margin: 0 0 6px; font-size: 1.28rem; }
.posts p { margin: 0; }

.post-meta { font-family: var(--sans); font-size: 0.95rem; color: var(--muted); margin: 0 0 20px; padding-bottom: 16px; border-bottom: 1px solid var(--rule); }
.ruta-datos {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 4px 0; max-width: 70ch; margin: 20px 0 28px;
  background: var(--surface); color: var(--ink); border: 1px solid var(--rule); border-top: 4px solid var(--accent);
  border-radius: var(--radius-panel); padding: 14px 10px; font-family: var(--sans);
}
.ruta-datos div { padding: 6px 12px; }
.ruta-datos dt { font-family: var(--display); font-size: 0.74rem; font-weight: 750; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); }
.ruta-datos dd { margin: 2px 0 0; font-family: var(--display); font-weight: 750; font-size: 1.05rem; line-height: 1.3; color: var(--heading); }

/* Preguntas frecuentes (acordeón) */
.faq { max-width: 70ch; border-top: 2px solid var(--rule-strong); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  list-style: none; position: relative; cursor: pointer; padding: 15px 44px 15px 0;
  font-family: var(--display); font-weight: 700; font-size: 1.08rem; color: var(--heading); line-height: 1.35;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 8px; top: 50%; width: 22px; height: 22px; margin-top: -11px; border-radius: 50%;
  background:
    linear-gradient(currentColor, currentColor) center / 10px 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2px 10px no-repeat;
  color: var(--accent); border: 1.5px solid currentColor;
}
.faq details[open] summary::after { background: linear-gradient(currentColor, currentColor) center / 10px 2px no-repeat; }
.faq summary:hover { color: var(--accent); }
.faq details p { margin: 0 0 16px; padding-right: 44px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 10px 0 0; font-family: var(--sans); }
.chips a {
  display: inline-flex; align-items: center; gap: 7px; padding: 7px 13px; border-radius: 4px; border: 1px solid var(--rule-strong);
  background: var(--panel); text-decoration: none; color: var(--ink); font-weight: 600; font-size: 0.93rem;
}
.chips a:visited { color: var(--ink); }
.chips a:hover { border-color: var(--accent); background: var(--accent-soft); color: var(--ink); }
.chips .ico { width: 18px; height: 18px; }

.pager { display: flex; flex-wrap: wrap; gap: 12px; font-family: var(--display); margin-top: 22px; }
.pager a {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border: 2px solid var(--navy-3); border-radius: var(--radius);
  font-weight: 700; text-decoration: none; color: var(--heading);
}
.pager a:visited { color: var(--heading); }
.pager a::after { content: "→"; }
.pager a[rel="prev"]::after { content: none; }
.pager a[rel="prev"]::before { content: "←"; }
.pager a:hover { background: var(--block); border-color: var(--block); color: #fff; }

.seccion { margin-top: 48px; }
.seccion > h2:first-child { margin-top: 0; }

details > summary { cursor: pointer; }

/* ---------- Pie ---------- */
.contratapa { background: var(--navy); color: #c5d3e3; font-family: var(--sans); font-size: 0.92rem; border-top: 6px solid var(--teal); }
.contratapa-inner { padding-top: 40px; padding-bottom: 36px; display: grid; grid-template-columns: minmax(260px, 1.6fr) repeat(3, minmax(160px, 1fr)); gap: 32px; }
.contratapa h2 { font-family: var(--display); font-size: 0.82rem; letter-spacing: 0.08em; text-transform: uppercase; color: #fff; margin: 0 0 12px; }
.contratapa-marca h2 { font-size: 1.15rem; letter-spacing: -0.01em; text-transform: none; }
.footer-emblem { display: block; width: 62px; height: 50px; margin-bottom: 14px; padding: 6px 8px; box-sizing: content-box; background: #fff; border-radius: 8px; }
.contratapa ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.contratapa a, .contratapa a:visited { color: #fff; text-decoration-color: rgba(255, 255, 255, 0.45); }
.contratapa a:hover { color: var(--teal-bright); text-decoration-color: currentColor; }
.contratapa a:focus-visible { color: #0b0c0c; }
.contratapa p { margin: 0 0 10px; line-height: 1.55; }
.contratapa-base { background: var(--navy-deep); color: #9fb2c7; font-size: 0.82rem; }
.contratapa-base .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; padding-top: 14px; padding-bottom: 14px; }
.contratapa-base p { margin: 0; }

/* ---------- Modo oscuro: emblema sobre placa clara ---------- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand-emblem { background: #fff; border-radius: 10px; padding: 4px 5px; box-sizing: content-box; width: 64px; height: 52px; }
  :root:not([data-theme="light"]) .masthead { border-bottom: 1px solid var(--rule); }
}
:root[data-theme="dark"] .brand-emblem { background: #fff; border-radius: 10px; padding: 4px 5px; box-sizing: content-box; width: 64px; height: 52px; }
:root[data-theme="dark"] .masthead { border-bottom: 1px solid var(--rule); }

/* ---------- Adaptación a pantallas chicas ---------- */
@media (max-width: 1020px) {
  .contratapa-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 920px) {
  .wrap { padding-left: 16px; padding-right: 16px; }
  .layout { grid-template-columns: minmax(0, 1fr); grid-template-areas: "main" "aside"; gap: 40px; padding: 22px 16px 56px; }
  .layout > aside { position: static; }
  .masthead-meta { display: none; }
  .masthead-inner { padding-top: 14px; padding-bottom: 14px; }
  .sign { padding: 28px 20px 22px; background-size: 320px 320px, auto; background-position: right -120px top -60px, 0 0; }
  h1 { font-size: var(--step-4); }
}
@media (max-width: 640px) {
  .brand-emblem { width: 58px; height: 47px; }
  .brand-l1, .brand-l2 { font-size: 1.28rem; }
  .brand-sub { font-size: 0.74rem; }
  .topbar { font-size: 0.76rem; }
  .nav-inner { display: grid; grid-template-columns: 1fr 1fr; padding: 0; }
  .nav a { margin: 0 !important; padding: 12px 16px; font-size: 0.96rem; border-top: 1px solid rgba(255, 255, 255, 0.1); }
  .nav a:nth-child(odd) { border-right: 1px solid rgba(255, 255, 255, 0.1); }
  .nav a[aria-current="page"]::after, .nav a:hover::after { left: 0; right: 0; bottom: 0; height: 3px; }
  .search input { font-size: 1.05rem; height: 52px; }
  .search button { height: 52px; padding: 0 16px; }
  .destinos { grid-template-columns: 1fr 1fr; gap: 8px; }
  .destinos a { padding: 9px 10px; gap: 1px 9px; font-size: 0.98rem; }
  .destinos a .ico { width: 20px; height: 20px; }
  .status-card { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; padding: 18px; gap: 0 14px; }
  .status-card > div { display: contents; }
  .status-card .ico-lg { width: 44px; height: 44px; }
  .status-card .status-label { margin: 0; }
  .status-card p:not(.status-label) { grid-column: 1 / -1; margin-top: 12px; }
  .status-card p.muted { margin-top: 10px !important; }
  .leyenda { grid-template-columns: 1fr; padding: 4px 16px; }
  .leyenda dd { border-top: 0; padding-top: 0; }
  .articulo { grid-template-columns: 1fr; }
  .contratapa-inner { grid-template-columns: 1fr; gap: 26px; }
  .cta { padding: 20px 18px 18px; }
  .filtros { grid-template-columns: 1fr; }
}

@media print {
  .topbar, .masthead-meta, .nav, .contratapa, .layout > aside, .search { display: none; }
  .layout { display: block; padding: 0; }
  .sign { background: none; color: #000; border: 1px solid #999; box-shadow: none; }
  .sign h1, .sign p { color: #000; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
