/* ===========================================================================
   E-Ticket República Dominicana — hoja de estilos
   Paleta de la bandera dominicana y nada más: azul ultramar, rojo bermellón y
   blanco. Los neutros son blancos fríos derivados del propio azul, para que el
   conjunto no se ensucie con grises ajenos a la bandera.

   Contraste comprobado sobre blanco: azul 13,7:1 y rojo 5,6:1, ambos por encima
   del mínimo AA de 4,5:1 para texto normal.
   =========================================================================== */

:root {
  --azul: #002D62;        /* azul de la bandera */
  --azul-hondo: #001B3D;
  --azul-vivo: #0A4396;
  --rojo: #CE1126;        /* rojo de la bandera */
  --rojo-hondo: #A50E1E;

  --papel: #ffffff;
  --papel-2: #f3f6fb;     /* blanco frío, tintado con el azul */
  --papel-3: #e6ecf5;
  --linea: #d3dcea;
  --linea-fuerte: #b3c0d4;

  --tinta: #10203a;
  --tinta-suave: #56647d;

  --radio: 10px;
  --radio-chico: 6px;

  --hueco: clamp(1rem, 3vw, 2rem);
  --franja: clamp(3rem, 6.5vw, 5rem);

  --tipo: "Inter", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
          Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
html, body { max-width: 100%; overflow-x: clip; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  font-family: var(--tipo);
  font-size: clamp(1rem, .97rem + .16vw, 1.07rem);
  line-height: 1.68;
  color: var(--tinta);
  background: var(--papel);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.2; font-weight: 700; letter-spacing: -.015em; text-wrap: balance; }
h1 { font-size: clamp(1.9rem, 1.3rem + 2.3vw, 2.9rem); }
h2 { font-size: clamp(1.38rem, 1.1rem + 1.25vw, 1.9rem); }
h3 { font-size: clamp(1.1rem, 1rem + .5vw, 1.3rem); }

p { margin: 0 0 1.1em; }
a { color: var(--azul-vivo); text-underline-offset: 2px; }
a:hover { color: var(--azul); }
img, svg { max-width: 100%; height: auto; }
ul, ol { margin: 0 0 1.2em; padding-left: 1.3em; }
hr { border: 0; border-top: 1px solid var(--linea); margin: 2.5rem 0; }
::selection { background: rgb(206 17 38 / 16%); }

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

.oculto {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.saltar { position: absolute; left: -9999px; top: .5rem; z-index: 90; background: var(--azul-hondo); color: #fff; padding: .6rem 1rem; border-radius: var(--radio-chico); }
.saltar:focus { left: .5rem; color: #fff; }

/* --- contenedores -------------------------------------------------------- */

.caja { width: min(100% - 2.5rem, 1180px); margin-inline: auto; }
.caja--texto { width: min(100% - 2.5rem, 770px); }

.antetitulo {
  margin: 0 0 .55rem;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--rojo);
}
.antetitulo--claro { color: #b7d0ef; }

.seccion__titulo { margin-bottom: 1.7rem; }

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

.boton {
  --fondo: var(--rojo);
  --frente: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .75rem 1.45rem;
  border: 2px solid transparent;
  border-radius: var(--radio-chico);
  background: var(--fondo);
  color: var(--frente);
  font-weight: 650;
  font-size: .96rem;
  text-decoration: none;
  transition: background-color .15s ease, transform .15s ease;
}
.boton:hover { color: var(--frente); transform: translateY(-1px); }
.boton--principal { --fondo: var(--rojo); }
.boton--principal:hover { --fondo: var(--rojo-hondo); }
.boton--sobrefoto { --fondo: transparent; --frente: #fff; border-color: rgb(255 255 255 / 55%); }
.boton--sobrefoto:hover { --fondo: rgb(255 255 255 / 14%); }
.boton--suave { --fondo: transparent; --frente: var(--tinta); border-color: var(--linea-fuerte); }
.boton--suave:hover { --fondo: var(--papel-2); }
.boton--chico { padding: .48rem 1rem; font-size: .88rem; }
.boton--grande { padding: .92rem 1.75rem; font-size: 1.02rem; }

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

.cabecera {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgb(255 255 255 / 94%);
  backdrop-filter: saturate(150%) blur(8px);
  border-bottom: 1px solid var(--linea);
}
.cabecera__fila { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 74px; padding-block: .55rem; }

.marca { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: inherit; min-width: 0; }
.marca__icono { flex: none; border-radius: var(--radio-chico); }
.marca__texto { display: grid; min-width: 0; }
.marca__nombre { font-weight: 750; font-size: 1.02rem; line-height: 1.2; letter-spacing: -.02em; color: var(--azul); }
.marca__nota { font-size: .73rem; color: var(--tinta-suave); line-height: 1.3; }

.menu { display: flex; align-items: center; gap: .4rem 1.1rem; flex-wrap: wrap; justify-content: flex-end; }
.menu__item { color: var(--tinta); text-decoration: none; font-weight: 620; font-size: .93rem; padding: .28rem 0; border-bottom: 2px solid transparent; }
.menu__item:hover { color: var(--rojo); border-bottom-color: var(--rojo); }

.idiomas { display: inline-flex; border: 1px solid var(--linea-fuerte); border-radius: var(--radio-chico); overflow: hidden; }
.idiomas__op { padding: .28rem .62rem; font-size: .77rem; font-weight: 700; letter-spacing: .04em; color: var(--tinta-suave); text-decoration: none; }
.idiomas__op + .idiomas__op { border-left: 1px solid var(--linea-fuerte); }
.idiomas__op:hover { background: var(--papel-2); color: var(--tinta); }
.idiomas__op.activo { background: var(--azul); color: #fff; }

@media (max-width: 780px) { .marca__nota { display: none; } .menu__item { display: none; } }
@media (max-width: 470px) {
  .cabecera__fila { flex-wrap: wrap; }
  .marca { flex: 1 1 100%; }
  .menu { flex: 1 1 100%; justify-content: space-between; padding-bottom: .2rem; }
}

/* --- apertura partida ---------------------------------------------------- */

/* Dos mitades a sangre: panel azul con el texto y fotografía a la derecha. No
   hay texto sobre la imagen, así que la foto no necesita velo y conserva todo
   su color. */
.apertura { background: var(--azul); color: #fff; }
@media (min-width: 950px) {
  .apertura { display: grid; grid-template-columns: 1fr 1fr; align-items: stretch; }
}

.apertura__panel {
  display: flex;
  align-items: center;
  padding-block: var(--franja);
  padding-inline: max(1.25rem, calc((100vw - 1180px) / 2 + 1.25rem)) clamp(1.25rem, 4vw, 3.5rem);
}
@media (max-width: 949px) {
  .apertura__panel { padding-inline: 1.25rem; }
}
.apertura__texto { max-width: 34rem; }
.apertura__texto h1 { margin-bottom: .55em; }
.apertura__entrada { font-size: clamp(1.02rem, .95rem + .4vw, 1.16rem); color: rgb(255 255 255 / 90%); }
.apertura__acciones { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.7rem; }
.apertura__nota { margin: 1.6rem 0 0; font-size: .82rem; color: rgb(255 255 255 / 62%); }
.apertura__nota a { color: rgb(255 255 255 / 82%); }

.apertura__marco { position: relative; min-height: 300px; }
.apertura__foto { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 46%; }
@media (max-width: 949px) {
  .apertura__marco { min-height: 0; aspect-ratio: 16 / 9; }
  .apertura__foto { position: static; }
}
/* Filete rojo que cose las dos mitades. */
@media (min-width: 950px) {
  .apertura__marco::before {
    content: "";
    position: absolute; left: 0; top: 0; bottom: 0; width: 5px;
    background: var(--rojo); z-index: 2;
  }
}

/* --- tira de datos ------------------------------------------------------- */

.tira { border-bottom: 1px solid var(--linea); }
.tira__fila {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}
.tira__dato { padding: 1.4rem 1.3rem; border-left: 1px solid var(--linea); }
.tira__dato:first-child { border-left: 0; padding-left: 0; }
.tira__dato dt { font-size: 1.18rem; font-weight: 750; color: var(--azul); letter-spacing: -.02em; }
.tira__dato dd { margin: .15rem 0 0; font-size: .86rem; color: var(--tinta-suave); }
@media (max-width: 700px) {
  .tira__dato { border-left: 0; border-top: 1px solid var(--linea); padding-inline: 0; }
  .tira__dato:first-child { border-top: 0; }
}

/* --- comparación antes / ahora ------------------------------------------- */

.compara { padding-block: var(--franja); background: var(--papel-2); }
.compara__cabeza { max-width: 46rem; }
.compara__entrada { font-size: 1.05rem; color: var(--tinta-suave); margin-bottom: 2rem; }
.compara__par { display: grid; gap: 1px; background: var(--linea); border: 1px solid var(--linea); border-radius: var(--radio); overflow: hidden; }
@media (min-width: 780px) { .compara__par { grid-template-columns: 1fr 1fr; } }
.compara__lado { background: var(--papel); padding: 1.7rem 1.7rem 1.9rem; }
.compara__lado h3 {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .12em;
  padding-bottom: .7rem; margin-bottom: 1.1rem; border-bottom: 2px solid var(--linea);
}
.compara__lado ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .8rem; }
.compara__lado li { position: relative; padding-left: 1.9rem; font-size: .95rem; }
.compara__lado li::before {
  position: absolute; left: 0; top: -.05em;
  font-size: 1.1rem; font-weight: 700; line-height: 1.5;
}
.compara__lado--antes h3 { color: var(--tinta-suave); }
.compara__lado--antes li { color: var(--tinta-suave); }
.compara__lado--antes li::before { content: "×"; color: var(--rojo); }
.compara__lado--ahora h3 { color: var(--azul); border-bottom-color: var(--azul); }
.compara__lado--ahora li::before { content: "✓"; color: var(--azul); font-size: .95rem; }

/* --- ruta del servicio --------------------------------------------------- */

.ruta { padding-block: var(--franja); }
.ruta__lista { list-style: none; margin: 0 0 2rem; padding: 0; display: grid; gap: 2rem; }
@media (min-width: 860px) {
  .ruta__lista { grid-template-columns: repeat(3, 1fr); gap: 0; }
  /* Línea continua que enhebra los tres hitos. */
  .ruta__hito { padding-inline: 0 2rem; position: relative; }
  .ruta__hito::after {
    content: "";
    position: absolute; left: 0; right: 0; top: 1.1rem; height: 2px;
    background: var(--linea); z-index: 0;
  }
  .ruta__hito:last-child::after { right: 2rem; }
}
.ruta__hito h3 { font-size: 1.08rem; margin: .9rem 0 .35rem; }
.ruta__hito p { margin: 0; font-size: .94rem; color: var(--tinta-suave); max-width: 24rem; }
.ruta__marca {
  position: relative; z-index: 1;
  display: grid; place-items: center;
  width: 2.2rem; height: 2.2rem;
  border-radius: 50%;
  background: var(--azul);
  color: #fff; font-weight: 750; font-size: .98rem;
  box-shadow: 0 0 0 6px var(--papel);
}
.ruta__pie { margin: 0; }

/* --- puntos clave -------------------------------------------------------- */

.puntos { padding-block: var(--franja); border-top: 1px solid var(--linea); }
.puntos__lista { margin: 0; display: grid; gap: 2.2rem 3rem; }
@media (min-width: 820px) { .puntos__lista { grid-template-columns: 1fr 1fr; } }
.puntos__item dt {
  display: flex; align-items: baseline; gap: .8rem;
  font-weight: 700; font-size: 1.1rem; color: var(--azul);
  margin-bottom: .45rem;
}
.puntos__n { font-size: .8rem; font-weight: 800; color: var(--rojo); letter-spacing: .04em; }
.puntos__item dd { margin: 0 0 0 2.4rem; font-size: .95rem; color: var(--tinta-suave); }

/* --- texto largo --------------------------------------------------------- */

.ensayo { padding-block: var(--franja); }

.texto { font-size: 1.04rem; }
.texto > *:first-child { margin-top: 0; }
.texto h2 { margin-top: 2.5rem; padding-top: 1.6rem; border-top: 1px solid var(--linea); scroll-margin-top: 6rem; }
.texto h3 { margin-top: 2rem; color: var(--azul); }
.texto li { margin-bottom: .45em; }
.texto li::marker { color: var(--rojo); font-weight: 700; }

.texto blockquote {
  margin: 1.9rem 0;
  padding: 1.05rem 1.35rem;
  background: var(--papel-2);
  border-left: 4px solid var(--azul);
  border-radius: 0 var(--radio) var(--radio) 0;
}
.texto blockquote p:last-child { margin-bottom: 0; }

.texto figure { margin: 2.1rem 0; }
.texto figure img { width: 100%; border: 1px solid var(--linea); border-radius: var(--radio); background: var(--papel-2); }
.texto figcaption { margin-top: .5rem; font-size: .85rem; color: var(--tinta-suave); text-align: center; }

.texto table { width: 100%; border-collapse: collapse; margin: 1.9rem 0; font-size: .93rem; }
.texto :is(th, td) { padding: .65rem .8rem; border: 1px solid var(--linea); text-align: left; vertical-align: top; }
.texto thead th { background: var(--azul); color: #fff; border-color: var(--azul); font-weight: 650; }
.texto tbody tr:nth-child(even) { background: var(--papel-2); }

.texto code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .88em; background: var(--papel-2); padding: .12em .38em; border-radius: 4px; }

/* web.js envuelve las tablas para que se desplacen solas; la consulta es el
   respaldo cuando no hay JavaScript */
.tabla-scroll { overflow-x: auto; margin: 1.9rem 0; -webkit-overflow-scrolling: touch; border-radius: var(--radio-chico); }
.tabla-scroll table { margin: 0; min-width: 34rem; }
@media (max-width: 640px) { .texto > table { display: block; overflow-x: auto; } }

/* --- avisos -------------------------------------------------------------- */

.aviso { margin: 2.1rem 0; padding: 1.2rem 1.35rem; border-radius: var(--radio); background: var(--papel-2); border: 1px solid var(--linea); }
.aviso > *:last-child { margin-bottom: 0; }
.aviso strong { display: block; margin-bottom: .35rem; font-size: 1.02rem; color: var(--azul); }
.aviso--tip { border-left: 5px solid var(--azul); background: var(--papel-2); }
.aviso--cta {
  border: 0;
  padding: 1.9rem 1.5rem;
  text-align: center;
  color: #fff;
  background: var(--azul);
}
.aviso--cta strong { color: #fff; }
.aviso--cta a:not(.boton) { color: #fff; }
.aviso--cta .boton { margin-top: .5rem; }

/* --- listado de artículos ------------------------------------------------ */

.recientes { padding-block: var(--franja); background: var(--papel-2); }
.recientes__cabeza { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.masenlace { font-weight: 650; font-size: .94rem; text-decoration: none; }
.masenlace:hover { text-decoration: underline; }

/* Filas en lugar de rejilla de tarjetas: se leen en vertical, como un índice. */
.listado { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--linea); }
.listado__fila {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.4rem;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--linea);
  transition: background-color .14s ease;
}
.listado__fila:hover { background: var(--papel); }
.listado__miniatura {
  display: block; aspect-ratio: 16 / 9; overflow: hidden;
  border: 1px solid var(--linea); border-radius: var(--radio-chico); background: var(--papel);
}
.listado__miniatura img { width: 100%; height: 100%; object-fit: cover; }
.listado__fecha { font-size: .74rem; letter-spacing: .05em; text-transform: uppercase; color: var(--tinta-suave); }
.listado__cuerpo :is(h2, h3) { font-size: 1.14rem; margin: .3rem 0 .35rem; }
.listado__cuerpo :is(h2, h3) a { color: var(--azul); text-decoration: none; }
.listado__cuerpo :is(h2, h3) a:hover { color: var(--rojo); }
.listado__cuerpo p { margin: 0; font-size: .93rem; color: var(--tinta-suave); }
.listado__flecha { font-size: 1.3rem; color: var(--rojo); padding-right: .4rem; }

.listado--indice .listado__fila { padding: 1.5rem 0; }

@media (max-width: 720px) {
  .listado__fila { grid-template-columns: 110px minmax(0, 1fr); gap: 1rem; }
  .listado__flecha { display: none; }
}

/* --- índice -------------------------------------------------------------- */

.indice__cabeza { padding-block: var(--franja) 0; }
.indice__entrada { font-size: 1.07rem; color: var(--tinta-suave); }
.indice__cuerpo { padding-block: var(--franja); }
.indice__pie { padding-bottom: var(--franja); }

/* --- página de tema ------------------------------------------------------ */

.tema { padding-block: clamp(1.4rem, 4vw, 2.3rem) var(--franja); }
.migas { font-size: .84rem; color: var(--tinta-suave); margin-bottom: 1.3rem; display: flex; gap: .5rem; flex-wrap: wrap; }
.migas a { color: var(--tinta-suave); text-decoration: none; }
.migas a:hover { color: var(--rojo); text-decoration: underline; }

.tema__cabeza { padding-bottom: 1.7rem; border-bottom: 1px solid var(--linea); margin-bottom: 2.2rem; }
.tema__entradilla { font-size: 1.11rem; color: var(--tinta-suave); }
.tema__firma { font-size: .83rem; color: var(--tinta-suave); display: flex; gap: .5rem; flex-wrap: wrap; margin: 0; }

.tema__pie { margin-top: 2.9rem; padding-top: 1.7rem; border-top: 1px solid var(--linea); display: flex; gap: .8rem; flex-wrap: wrap; }

/* --- preguntas frecuentes ------------------------------------------------ */

.faq { padding-block: var(--franja); background: var(--papel-2); }
.faq__lista { display: grid; gap: .65rem; }
.faq__item { background: var(--papel); border: 1px solid var(--linea); border-radius: var(--radio); overflow: hidden; }
.faq__p { cursor: pointer; list-style: none; padding: .98rem 3rem .98rem 1.15rem; font-weight: 650; position: relative; color: var(--azul); }
.faq__p::-webkit-details-marker { display: none; }
.faq__p::after {
  content: "";
  position: absolute; right: 1.2rem; top: 50%;
  width: .6rem; height: .6rem; margin-top: -.4rem;
  border-right: 2.4px solid var(--rojo); border-bottom: 2.4px solid var(--rojo);
  transform: rotate(45deg);
  transition: transform .18s ease;
}
.faq__item[open] .faq__p::after { transform: rotate(-135deg); margin-top: -.14rem; }
.faq__p:hover { background: var(--papel-2); }
.faq__r { padding: 0 1.15rem 1.05rem; color: var(--tinta-suave); }
.faq__r p:last-child { margin-bottom: 0; }

/* --- páginas con formulario ---------------------------------------------- */

.formulario__cabeza { padding-block: var(--franja) 1.4rem; background: var(--papel-2); text-align: center; }
.formulario__cabeza p { color: var(--tinta-suave); }
.formulario__cuerpo { padding-block: 2rem var(--franja); }
.formulario__cuerpo .caja { max-width: 900px; }

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

.pie { background: var(--azul-hondo); color: rgb(255 255 255 / 76%); padding-block: var(--franja) 1.9rem; font-size: .92rem; }
.pie a { color: rgb(255 255 255 / 84%); text-decoration: none; }
.pie a:hover { color: #fff; text-decoration: underline; }
.pie__rejilla { display: grid; gap: 2.2rem; }
@media (min-width: 760px) { .pie__rejilla { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .pie__rejilla { grid-template-columns: 1.7fr .75fr .75fr 1.4fr; } }

.marca--pie .marca__nombre { color: #fff; }
.marca--pie .marca__nota { color: rgb(255 255 255 / 58%); display: block; }

.pie__seguro { margin: 1.25rem 0; font-size: .84rem; color: rgb(255 255 255 / 66%); }
.pagos__etiqueta { font-size: .73rem; text-transform: uppercase; letter-spacing: .11em; color: rgb(255 255 255 / 48%); margin-bottom: .5rem; }
.pagos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .45rem; }
.pagos img { display: block; border-radius: 4px; box-shadow: 0 0 0 1px rgb(255 255 255 / 12%); }

.pie__columna h2 { font-size: .77rem; text-transform: uppercase; letter-spacing: .13em; color: #fff; margin-bottom: .85rem; }
.pie__columna ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .48rem; }
.pie__contacto p { font-size: .86rem; }
.pie__aviso { font-size: .78rem; color: rgb(255 255 255 / 60%); line-height: 1.6; }
.pie__aviso a { text-decoration: underline; }

.pie__base { margin: 2.3rem 0 0; padding-top: 1.35rem; border-top: 1px solid rgb(255 255 255 / 14%); display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.pie__base small { font-size: .75rem; color: rgb(255 255 255 / 50%); }

/* --- impresión ----------------------------------------------------------- */

@media print {
  .cabecera, .pie, .tema__pie, .aviso--cta, .saltar { display: none !important; }
  body { color: #000; font-size: 11pt; }
  .texto a::after { content: " (" attr(href) ")"; font-size: .85em; color: #555; }
}
