:root {
  /* Colores principales brillantes con accesibilidad WCAG AA/AAA */
  --title-color: #ffb800;
  --title-color-base: #eaa615;
  --title-bright: #ffc800;
  --title-color-dark: #b87c00;
  --title-gradient: linear-gradient(135deg, #ffd000 0%, #ffb000 55%, #eaa615 100%);
  --title-tint: #fff9e6;

  --subtitle-color: #1190d3;
  --subtitle-bright: #00b4ff;
  --subtitle-accessible: #075985; /* Ratio > 7.5:1 sobre blanco (WCAG AAA) */
  --subtitle-gradient: linear-gradient(135deg, #00b4ff 0%, #1190d3 100%);
  --subtitle-tint: #eef8ff;

  /* Fondo blanco, gris platino y escala tipográfica de alto contraste WCAG AAA */
  --bg-white: #ffffff;
  --bg-platinum: #e5e8ec;
  --bento-bg: #ffffff;
  --bento-surface: #f8fbff;
  --text-main: #0f172a;     /* Ratio 17.8:1 sobre blanco (WCAG AAA) */
  --text-muted: #334155;    /* Ratio 10.3:1 sobre blanco (WCAG AAA) */
  --border-bento: #cbd5e1;  /* Borde nítido para tarjetas Bento */
  --border-soft: #dce8f3;

  /* Tipografía principal de toda la web: Satoshi */
  --font-heading: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Satoshi', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* Sombras estilo Bento suaves y definidas */
  --shadow-bento: 0 6px 20px -4px rgba(15, 23, 42, 0.07), 0 2px 6px -1px rgba(15, 23, 42, 0.04);
  --shadow-bento-hover: 0 16px 36px -6px rgba(17, 144, 211, 0.15), 0 4px 12px -2px rgba(15, 23, 42, 0.06);

  /* Radios estilo Bento: tarjetas de radio suave y botones medio/píldora */
  --radius-bento-sm: 16px;
  --radius-bento: 22px;
  --radius-bento-lg: 28px;
  --radius-btn-med: 14px;
  --radius-btn-pill: 999px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
  overflow-x: hidden;
  max-width: 100%;
}

body {
  font-family: var(--font-body);
  color: var(--text-main);
  background-color: var(--bg-white);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100%;
}

/* Accesibilidad WCAG AA/AAA: Foco de teclado altamente visible */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #004499;
  outline-offset: 3px;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.22s ease;
}

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ==========================================
   BARRA SUPERIOR Y CABECERA (FONDO BLANCO)
   ========================================== */
.top-bar {
  background-color: var(--bg-white);
  color: var(--text-muted);
  font-size: 0.85rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-soft);
}

.top-bar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.top-bar-badge {
  font-weight: 800;
  color: var(--subtitle-accessible);
  background-color: var(--subtitle-tint);
  border: 1px solid rgba(17, 144, 211, 0.35);
  padding: 0.22rem 0.85rem;
  border-radius: var(--radius-btn-pill);
}

.top-bar-text {
  color: var(--text-muted);
  font-weight: 600;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  border-bottom: 1.5px solid var(--border-soft);
  transition: box-shadow 0.25s ease;
}

.site-header.scrolled {
  box-shadow: var(--shadow-bento);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 90px;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
}

.brand-logo-img {
  height: 72px;
  width: auto;
  object-fit: contain;
  display: block;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.nav-link {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  padding: 0.55rem 0.95rem;
  border-radius: var(--radius-btn-pill);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--subtitle-accessible);
  background-color: var(--subtitle-tint);
}

.nav-cta {
  background-color: var(--subtitle-accessible);
  color: var(--bg-white) !important;
  padding: 0.62rem 1.4rem;
  border-radius: var(--radius-btn-pill);
  box-shadow: 0 4px 14px rgba(7, 89, 133, 0.25);
}

.nav-cta:hover {
  background-color: var(--title-color);
  color: #000000 !important;
  transform: translateY(-2px);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.9rem;
}

/* Selector de idioma ES / VAL (Normativa RACV) */
.lang-switcher {
  display: inline-flex;
  align-items: center;
  background-color: var(--bento-surface);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-btn-pill);
  padding: 0.2rem;
  gap: 0.15rem;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-radius: var(--radius-btn-pill);
  padding: 0.36rem 0.72rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lang-btn:hover {
  color: #000000;
}

.lang-btn.active {
  background-color: #ffffff;
  color: #000000;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12);
}

.lang-senyera-dot {
  width: 14px;
  height: 10px;
  border-radius: 2px;
  display: inline-block;
  flex-shrink: 0;
  background-image:
    linear-gradient(90deg, #0072BC 0%, #0072BC 28%, transparent 28%, transparent 100%),
    linear-gradient(
      180deg,
      #FCDD09 0%,    #FCDD09 11.11%,
      #DA121A 11.11%, #DA121A 22.22%,
      #FCDD09 22.22%, #FCDD09 33.33%,
      #DA121A 33.33%, #DA121A 44.44%,
      #FCDD09 44.44%, #FCDD09 55.55%,
      #DA121A 55.55%, #DA121A 66.66%,
      #FCDD09 66.66%, #FCDD09 77.77%,
      #DA121A 77.77%, #DA121A 88.88%,
      #FCDD09 88.88%, #FCDD09 100%
    );
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.18);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.6rem;
  min-width: 44px;
  min-height: 44px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}

.mobile-menu-btn span {
  display: block;
  width: 25px;
  height: 3px;
  border-radius: 2px;
  background-color: var(--text-main);
}

/* ==========================================
   HERO BANNER SIN FONDO EN EL TEXTO Y CON BORDE NEGRO EN LAS LETRAS
   ========================================== */
.hero-section {
  position: relative;
  background-color: var(--bg-white);
  padding: 4.5rem 0 5rem;
  overflow: hidden;
  border-bottom: 1.5px solid var(--border-soft);
}

.hero-banner-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Sin fondo blanco sobre la imagen: solo un velo mínimo para realzar la foto */
.hero-banner-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.22) 0%,
    rgba(0, 0, 0, 0.08) 60%,
    rgba(0, 0, 0, 0.0) 100%
  );
}

.hero-container {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  min-height: 450px;
}

/* Sin fondo ni recuadro detrás del texto en el banner */
.hero-card {
  background: transparent;
  backdrop-filter: none;
  max-width: 780px;
  padding: 0;
  border-radius: 0;
  box-shadow: none;
  border: none;
}

/* Subtítulo del banner: relleno blanco de la letra con borde azul fino hacia el exterior */
.hero-subtitle {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(1.1rem, 1.9vw, 1.38rem);
  font-weight: 900;
  color: #ffffff;
  background: transparent;
  box-shadow: none;
  padding: 0;
  margin-bottom: 0.55rem;
  letter-spacing: 0.025em;
  paint-order: stroke fill;
  -webkit-text-stroke: 1.5px #29b6ff;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

/* Subtítulo H2 "Una voz directa para defender los intereses valencianos" */
.hero-subtitle-h2,
h2.hero-title {
  display: block;
  font-family: var(--font-heading);
  font-size: clamp(1.45rem, 2.6vw, 2rem);
  font-weight: 900;
  line-height: 1.24;
  color: #ffffff;
  background: transparent;
  margin-bottom: 1.15rem;
  letter-spacing: 0.02em;
  paint-order: stroke fill;
  -webkit-text-stroke: 2px #29b6ff;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

/* Título principal H1 del banner con trazo exterior limpio que no invade el interior */
.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(2.5rem, 4.6vw, 3.6rem);
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: 0.015em;
  color: #ffc400;
  margin-bottom: 0.5rem;
  paint-order: stroke fill;
  -webkit-text-stroke: 5px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
}

/* Párrafo descriptivo del banner y su etiqueta <strong> con paint-order hacia el exterior */
.hero-lead,
.hero-lead strong {
  font-family: var(--font-heading);
  font-size: 1.18rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.015em;
  paint-order: stroke fill;
  -webkit-text-stroke: 2.8px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.55);
}

.hero-lead {
  margin-bottom: 2rem;
  max-width: 660px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ==========================================
   BOTONES DE RADIO MEDIO O PÍLDORA CON CONTRASTE WCAG AAA
   ========================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  min-height: 48px;
  padding: 0.88rem 1.75rem;
  border-radius: var(--radius-btn-pill);
  font-family: var(--font-heading);
  font-weight: 900;
  font-size: 1rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.22s ease;
}

/* Botón primario: texto oscuro #0f172a sobre dorado brillante #ffc400 = Ratio 12.1:1 (WCAG AAA) */
.btn-primary {
  background: var(--title-gradient);
  color: #0f172a;
  border-color: #0f172a;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.22);
}

.btn-primary:hover {
  background: var(--subtitle-gradient);
  color: #ffffff;
  border-color: #000000;
  transform: translateY(-2px);
}

/* Botón secundario en radio medio/píldora con alto contraste */
.btn-secondary {
  background-color: #ffffff;
  color: var(--subtitle-accessible);
  border: 2px solid #0f172a;
  border-radius: var(--radius-btn-med);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
}

.btn-secondary:hover {
  background-color: var(--subtitle-accessible);
  color: #ffffff;
  border-color: var(--subtitle-accessible);
  transform: translateY(-2px);
}

/* ==========================================
   SECCIÓN DE ACCESO RÁPIDO (BENTO CORPORATIVO 2x2)
   ========================================== */
.quick-access-section {
  background-color: var(--bg-white);
  padding: 3rem 0 1.25rem;
}

.quick-access-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.quick-access-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 235px;
  padding: 2.35rem 2.5rem 2.15rem;
  border-radius: var(--radius-bento);
  box-shadow: var(--shadow-bento);
  transition: transform 0.28s ease, box-shadow 0.28s ease;
  text-decoration: none;
  overflow: hidden;
}

.quick-access-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-bento-hover);
}

.quick-access-title {
  font-family: var(--font-heading);
  font-size: clamp(1.9rem, 2.9vw, 2.55rem);
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin-bottom: 0.75rem;
}

.quick-access-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
}

.quick-access-text {
  font-family: var(--font-body);
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.55;
  max-width: 86%;
}

.quick-access-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-btn-pill);
  flex-shrink: 0;
  transition: transform 0.25s ease, background-color 0.25s ease;
}

.quick-access-card:hover .quick-access-arrow {
  transform: translateX(5px);
}

/* 1. Quiénes Somos — Azul Corporativo Agenda Valenciana */
.qa-card-blue {
  background: linear-gradient(135deg, #1190d3 0%, #0969a3 100%);
  border: 2px solid #075985;
  color: #ffffff;
}

.qa-card-blue .quick-access-title,
.qa-card-blue .quick-access-text {
  color: #ffffff;
}

.qa-card-blue .quick-access-arrow {
  background-color: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

/* 2. Nuestro Candidato — Dorado/Amarillo Corporativo Agenda Valenciana */
.qa-card-gold {
  background: linear-gradient(135deg, #ffd000 0%, #ffb800 60%, #eaa615 100%);
  border: 2px solid #d99000;
  color: #000000;
}

.qa-card-gold .quick-access-title,
.qa-card-gold .quick-access-text {
  color: #000000;
}

.qa-card-gold .quick-access-arrow {
  background-color: rgba(0, 0, 0, 0.1);
  color: #000000;
}

/* 3. Programa — Dorado Suave / Ámbar Corporativo Luminoso */
.qa-card-deep-blue {
  background: linear-gradient(135deg, #fff3c4 0%, #ffe066 100%);
  border: 2px solid #eaa615;
  color: #000000;
}

.qa-card-deep-blue .quick-access-title,
.qa-card-deep-blue .quick-access-text {
  color: #000000;
}

.qa-card-deep-blue .quick-access-arrow {
  background-color: #ffb800;
  color: #000000;
}

/* 4. Contacto — Azul Celeste Corporativo (#29b6ff / #1190d3) */
.qa-card-sky {
  background: linear-gradient(135deg, #29b6ff 0%, #1190d3 100%);
  border: 2px solid #0b72ab;
  color: #ffffff;
}

.qa-card-sky .quick-access-title,
.qa-card-sky .quick-access-text {
  color: #ffffff;
}

.qa-card-sky .quick-access-arrow {
  background-color: rgba(255, 255, 255, 0.22);
  color: #ffffff;
}

/* ==========================================
   SISTEMA BENTO GRID Y ENCABEZADOS DE SECCIÓN
   ========================================== */
.section {
  background-color: var(--bg-white);
  padding: 4.75rem 0;
  border-bottom: 1px solid var(--border-soft);
}

/* Fondo gris platino para Quiénes Somos, Programa y Contacto */
#quienes-somos,
#programa,
#contacto {
  background-color: var(--bg-platinum);
}

.section-header {
  margin-bottom: 2.5rem;
}

.section-header-center {
  text-align: center;
  max-width: 840px;
  margin-left: auto;
  margin-right: auto;
}

/* Subtítulo en píldora con relleno negro sin borde azul */
.section-subtitle {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #000000;
  -webkit-text-stroke: 0;
  background-color: var(--subtitle-tint);
  border: 1.5px solid var(--subtitle-color);
  padding: 0.36rem 1.05rem;
  border-radius: var(--radius-btn-pill);
  margin-bottom: 0.7rem;
}

/* Títulos principales en #eaa615 / #ffb800 con trazo negro exterior (paint-order: stroke fill) */
.section-title {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 3.6vw, 3rem);
  font-weight: 900;
  letter-spacing: 0.015em;
  color: var(--title-color);
  paint-order: stroke fill;
  -webkit-text-stroke: 3.5px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-shadow: none;
  line-height: 1.15;
}

/* Línea decorativa con los colores y proporción de la Senyera de la Comunitat Valenciana:
   Franja vertical azul junto al asta (#0072BC) y cuatro barras rojas (#DA121A) sobre fondo amarillo (#FCDD09) */
.section-rule {
  width: 96px;
  height: 11px;
  background-image:
    linear-gradient(90deg, #0072BC 0%, #0072BC 24%, transparent 24%, transparent 100%),
    linear-gradient(
      180deg,
      #FCDD09 0%,    #FCDD09 11.11%,
      #DA121A 11.11%, #DA121A 22.22%,
      #FCDD09 22.22%, #FCDD09 33.33%,
      #DA121A 33.33%, #DA121A 44.44%,
      #FCDD09 44.44%, #FCDD09 55.55%,
      #DA121A 55.55%, #DA121A 66.66%,
      #FCDD09 66.66%, #FCDD09 77.77%,
      #DA121A 77.77%, #DA121A 88.88%,
      #FCDD09 88.88%, #FCDD09 100%
    );
  margin-top: 0.85rem;
  border-radius: var(--radius-btn-pill);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.18);
}

.section-header-center .section-rule {
  margin-left: auto;
  margin-right: auto;
}

/* ==========================================
   TARJETAS BENTO DE IMAGEN Y NOTAS DE FUENTE
   ========================================== */
.media-frame {
  background: var(--bento-bg);
  border-radius: var(--radius-bento);
  padding: 1rem;
  box-shadow: var(--shadow-bento);
  border: 1.5px solid var(--border-bento);
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.media-frame:hover {
  box-shadow: var(--shadow-bento-hover);
}

.image-wrapper {
  position: relative;
  border-radius: var(--radius-bento-sm);
  overflow: hidden;
  background: var(--bento-surface);
  flex: 1;
  min-height: 320px;
  display: flex;
  align-items: stretch;
  justify-content: center;
}

.responsive-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  border-radius: var(--radius-bento-sm);
  transition: transform 0.35s ease;
}

.media-frame:hover .responsive-img {
  transform: scale(1.02);
}

.img-placeholder {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2.5rem 1.5rem;
  color: var(--subtitle-accessible);
  gap: 0.65rem;
}

.image-wrapper.img-missing .responsive-img {
  display: none;
}

.image-wrapper.img-missing .img-placeholder {
  display: flex;
}

.placeholder-title {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-main);
}

.placeholder-file {
  font-size: 0.78rem;
  background: var(--bg-white);
  padding: 0.3rem 0.7rem;
  border-radius: var(--radius-btn-pill);
  color: var(--subtitle-accessible);
  border: 1px solid var(--border-bento);
}

.media-caption {
  padding: 0.75rem 0.4rem 0.2rem;
  font-size: 0.85rem;
  color: var(--subtitle-accessible);
  font-weight: 700;
}

.photo-source-note {
  padding: 0.65rem 0.4rem 0.2rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: right;
  font-weight: 600;
}

.photo-source-note a {
  color: var(--subtitle-accessible);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.photo-source-note a:hover {
  color: var(--text-main);
}

/* ==========================================
   APARTADO 1: QUIÉNES SOMOS (RETÍCULA BENTO)
   ========================================== */
.about-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

.about-text-col {
  grid-column: span 7;
  display: flex;
  flex-direction: column;
}

.about-image-col {
  grid-column: span 5;
  display: flex;
  flex-direction: column;
}

.friendly-card {
  background: var(--bento-bg);
  padding: 2.25rem;
  border-radius: var(--radius-bento);
  box-shadow: var(--shadow-bento);
  border: 1.5px solid var(--border-bento);
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: box-shadow 0.25s ease;
}

.friendly-card:hover {
  box-shadow: var(--shadow-bento-hover);
}

.card-subtitle {
  font-family: var(--font-heading);
  font-size: 1.38rem;
  font-weight: 900;
  color: #000000;
  -webkit-text-stroke: 0;
  margin-bottom: 1rem;
  line-height: 1.35;
}

.about-paragraph {
  font-size: 1.03rem;
  line-height: 1.8;
  color: var(--text-main);
}

.pillars-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 1.75rem;
  padding-top: 1.5rem;
  border-top: 1.5px solid var(--border-soft);
}

.pillar-chip {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background-color: var(--bento-surface);
  border: 1.5px solid var(--border-bento);
  color: var(--text-main);
  font-size: 0.84rem;
  font-weight: 800;
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-bento-sm);
}

.pillar-chip svg {
  color: var(--subtitle-accessible);
  flex-shrink: 0;
}

/* ==========================================
   APARTADO 2: CANDIDATO (RETÍCULA BENTO)
   ========================================== */
.candidate-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

.candidate-photo-col {
  grid-column: span 5;
  display: flex;
  flex-direction: column;
}

.candidate-bio-col {
  grid-column: span 7;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  justify-content: space-between;
}

.candidate-header-box {
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento);
  padding: 1.65rem 2rem;
  box-shadow: var(--shadow-bento);
}

.candidate-role {
  display: inline-block;
  background-color: var(--subtitle-tint);
  color: var(--subtitle-accessible);
  border: 1.5px solid var(--subtitle-color);
  font-family: var(--font-heading);
  font-size: 0.84rem;
  font-weight: 900;
  padding: 0.32rem 0.95rem;
  border-radius: var(--radius-btn-pill);
  margin-bottom: 0.6rem;
}

.candidate-name {
  font-family: var(--font-heading);
  font-size: clamp(1.95rem, 3vw, 2.55rem);
  font-weight: 900;
  letter-spacing: 0.015em;
  background-color: #ffffff;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3.2px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  line-height: 1.16;
  margin-bottom: 0.3rem;
}

.candidate-subtitle {
  font-family: var(--font-heading);
  font-size: 1.12rem;
  font-weight: 800;
  color: #000000;
  -webkit-text-stroke: 0;
}

.candidate-bio-text {
  background: var(--bento-bg);
  padding: 1.85rem 2rem;
  border-radius: var(--radius-bento);
  border: 1.5px solid var(--border-bento);
  border-left: 6px solid var(--title-color);
  box-shadow: var(--shadow-bento);
  margin-bottom: 0;
  flex: 1;
  display: flex;
  align-items: center;
}

.candidate-bio-text p {
  font-size: 1.03rem;
  line-height: 1.78;
  color: var(--text-main);
}

.inline-external-link {
  color: var(--subtitle-accessible);
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.inline-external-link:hover {
  color: var(--text-main);
  background-color: var(--title-tint);
}

.candidate-credentials {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.credential-card {
  background: var(--bento-surface);
  padding: 1.25rem 1.45rem;
  border-radius: var(--radius-bento);
  border: 1.5px solid var(--border-bento);
  box-shadow: var(--shadow-bento);
}

.credential-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.92rem;
  font-weight: 900;
  color: var(--subtitle-accessible);
  margin-bottom: 0.35rem;
}

.credential-card p {
  font-size: 0.92rem;
  color: var(--text-main);
  line-height: 1.55;
}

.credential-card a {
  color: var(--subtitle-accessible);
  font-weight: 800;
  text-decoration: underline;
}

/* ==========================================
   APARTADO 3: PROGRAMA ELECTORAL (RETÍCULA BENTO)
   ========================================== */
/* Eslogan en diseño abierto (sin tarjeta blanca, respirando sobre el fondo) */
.program-slogan-open {
  margin: 2.25rem 0 0.5rem;
  padding: 2.25rem 0;
  background: transparent;
  border-top: 1px solid #cbd5e1;
  border-bottom: 1px solid #cbd5e1;
  text-align: center;
}

.program-slogan-pill {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.48rem 1.15rem;
  border-radius: 9999px;
  font-family: var(--font-heading);
  font-size: 0.86rem;
  font-weight: 700;
  background-color: var(--subtitle-tint);
  color: #0f172a;
  border: 1.5px solid var(--subtitle-color);
  margin-bottom: 1.15rem;
  text-decoration: none;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.program-slogan-pill:hover {
  background-color: var(--title-tint);
  border-color: var(--title-color-base);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px -4px rgba(15, 23, 42, 0.1);
}

.pill-cta-divider {
  color: var(--subtitle-color);
  font-weight: 900;
}

.pill-cta-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: var(--subtitle-accessible);
  font-weight: 900;
}

.program-slogan-pill:hover .pill-cta-link svg {
  transform: translateX(3px);
}

.pill-cta-link svg {
  transition: transform 0.2s ease;
}

.program-slogan-heading {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 3.4vw, 2.5rem); /* 32px a 40px */
  line-height: 1.16;
  font-weight: 900; /* negrita pura */
  color: #000000;
  letter-spacing: -0.025em;
  margin-bottom: 0.65rem;
}

.program-slogan-sub {
  font-family: var(--font-body);
  font-size: clamp(1.05rem, 1.5vw, 1.2rem);
  font-weight: 500;
  line-height: 1.55;
  color: #334155;
  max-width: 44rem;
  margin: 0 auto;
}

.program-hero-banner {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
  align-items: stretch;
  margin-bottom: 1.75rem;
}

.program-hero-info {
  grid-column: span 7;
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento);
  padding: 2.25rem;
  box-shadow: var(--shadow-bento);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.program-hero-info-full,
.program-hero-banner-full .program-hero-info {
  grid-column: span 12;
}

.program-photo-frame {
  grid-column: span 5;
}

.program-badge-29n {
  display: inline-block;
  align-self: flex-start;
  background: var(--title-tint);
  color: #0f172a;
  border: 1.5px solid var(--title-color-base);
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 900;
  padding: 0.36rem 1rem;
  border-radius: var(--radius-btn-pill);
  margin-bottom: 0.95rem;
}

.program-banner-title {
  font-family: var(--font-heading);
  font-size: clamp(1.6rem, 2.4vw, 2.1rem);
  font-weight: 900;
  letter-spacing: 0.015em;
  background-color: #ffffff;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  line-height: 1.22;
  margin-bottom: 0.85rem;
}

.program-banner-subtitle {
  font-family: var(--font-heading);
  font-size: 1.02rem;
  font-weight: 800;
  color: #000000;
  -webkit-text-stroke: 0;
  margin-bottom: 1.4rem;
}

.program-quick-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.quick-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 40px;
  background: var(--subtitle-tint);
  border: 1.5px solid var(--subtitle-color);
  color: var(--subtitle-accessible);
  font-family: var(--font-heading);
  font-size: 0.86rem;
  font-weight: 800;
  padding: 0.42rem 0.95rem;
  border-radius: var(--radius-btn-pill);
  transition: all 0.2s ease;
}

.quick-pill span {
  color: #0f172a;
  background: var(--title-bright);
  padding: 0.1rem 0.45rem;
  border-radius: var(--radius-btn-pill);
  font-size: 0.78rem;
  font-weight: 900;
}

.quick-pill:hover {
  background: var(--subtitle-accessible);
  color: var(--bg-white);
  transform: translateY(-2px);
}

/* Retícula Bento de los 6 puntos del Programa */
.program-cards-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
}

.program-card {
  grid-column: span 6;
  background: var(--bento-bg);
  border-radius: var(--radius-bento);
  padding: 2.15rem;
  box-shadow: var(--shadow-bento);
  border: 1.5px solid var(--border-bento);
  border-top: 6px solid var(--title-color);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.program-card:nth-child(even) {
  border-top-color: var(--subtitle-color);
}

.program-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-bento-hover);
}

.program-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.9rem;
}

.program-number {
  font-family: var(--font-heading);
  font-size: 2.35rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.015em;
  color: var(--title-color);
  paint-order: stroke fill;
  -webkit-text-stroke: 3px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.program-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-btn-med);
  background: var(--subtitle-tint);
  border: 1.5px solid var(--subtitle-color);
  color: var(--subtitle-accessible);
  display: flex;
  align-items: center;
  justify-content: center;
}

.program-card-title {
  font-family: var(--font-heading);
  font-size: 1.48rem;
  font-weight: 900;
  letter-spacing: 0.015em;
  background-color: #ffffff;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-shadow: none;
  line-height: 1.25;
  margin-bottom: 0.35rem;
}

.program-card-subtitle {
  font-family: var(--font-heading);
  font-size: 0.98rem;
  font-weight: 800;
  color: #000000;
  -webkit-text-stroke: 0;
  margin-bottom: 1.15rem;
  padding-bottom: 0.85rem;
  border-bottom: 1.5px solid var(--border-soft);
}

.program-measures {
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
}

.program-measures li {
  position: relative;
  padding-left: 1.35rem;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-main);
}

.program-measures li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.58rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--subtitle-color);
}

.program-measures li strong {
  color: var(--subtitle-accessible);
  font-weight: 800;
}

/* ==========================================
   APARTADO: NUESTRA LISTA (CONGRESO Y SENADO)
   ========================================== */
.lista-top-pair {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.lista-chamber-block {
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-top: 6px solid var(--subtitle-color);
  border-radius: var(--radius-bento);
  padding: 1.75rem 1.5rem 2rem;
  box-shadow: var(--shadow-bento);
  display: flex;
  flex-direction: column;
  align-items: center;
}

#bloque-senado {
  border-top-color: var(--title-color);
}

.lista-chamber-block-full {
  width: 100%;
  border-top-color: var(--subtitle-color);
}

.lista-chamber-header {
  width: 100%;
  text-align: center;
  margin-bottom: 1.35rem;
  padding-bottom: 0.85rem;
  border-bottom: 1.5px solid var(--border-soft);
}

.lista-chamber-title {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 2.2vw, 1.7rem);
  font-weight: 900;
  letter-spacing: 0.05em;
  color: var(--title-color);
  paint-order: stroke fill;
  -webkit-text-stroke: 2.8px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  background: var(--subtitle-tint);
  border: 1.5px solid var(--subtitle-color);
  padding: 0.35rem 1.4rem;
  border-radius: var(--radius-btn-pill);
}

.lista-congreso-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  width: 100%;
  align-items: stretch;
}

.team-card-item {
  background: var(--bento-surface);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento-sm);
  padding: 1.35rem 1rem 1.4rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.lista-top-pair .team-card-item {
  max-width: 420px;
}

.team-card-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-bento-hover);
  border-color: var(--subtitle-color);
}

.team-photo-link {
  display: block;
  text-decoration: none;
}

/* Contenedor de foto siempre del mismo tamaño moderado y con el fondo unificado (#ede1dd) */
.team-photo-box {
  width: 175px;
  height: 215px;
  margin: 0 auto 1rem;
  background-color: #ede1dd;
  border-radius: var(--radius-bento-sm);
  border: 1.5px solid var(--border-bento);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, border-color 0.25s ease;
}

.team-photo-link:hover .team-photo-box {
  transform: scale(1.03);
  border-color: var(--subtitle-accessible);
}

.team-member-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  background-color: #ede1dd;
}

.team-member-img-chirivella {
  object-position: 24% center;
}

.team-member-info {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  width: 100%;
}

.team-member-name {
  font-family: var(--font-heading);
  font-size: 1.14rem;
  font-weight: 900;
  letter-spacing: 0.01em;
  text-align: center;
  line-height: 1.28;
  margin-bottom: 0.45rem;
}

.team-name-link {
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 2.5px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  text-decoration: none;
  transition: color 0.2s ease;
}

.team-name-link:hover {
  color: var(--title-bright);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.team-member-role {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 800;
  color: #000000;
  text-align: center;
  line-height: 1.45;
  margin-bottom: 0.9rem;
}

.team-cv-badge {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--subtitle-accessible);
  background: var(--subtitle-tint);
  border: 1px solid rgba(17, 144, 211, 0.35);
  padding: 0.36rem 0.85rem;
  border-radius: var(--radius-btn-pill);
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.team-cv-badge:hover {
  background: var(--subtitle-accessible);
  color: #ffffff;
}

/* ==========================================
   PÁGINAS SECUNDARIAS: PROGRAMA Y CURRÍCULUM CANDIDATOS
   ========================================== */
.subpage-back-row {
  margin-bottom: 1.5rem;
}

.btn-back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--subtitle-accessible);
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  padding: 0.55rem 1.15rem;
  border-radius: var(--radius-btn-pill);
  box-shadow: var(--shadow-bento);
  transition: all 0.2s ease;
}

.btn-back-link:hover {
  background: var(--subtitle-accessible);
  color: #ffffff;
  border-color: var(--subtitle-accessible);
  transform: translateX(-3px);
}

.cv-profile-card {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2.25rem;
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-top: 6px solid var(--subtitle-color);
  border-radius: var(--radius-bento);
  padding: 2.25rem;
  box-shadow: var(--shadow-bento);
  align-items: start;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.cv-profile-main {
  width: 100%;
  min-width: 0;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.cv-content-body {
  width: 100%;
  min-width: 0;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.cv-content-body a {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.cv-profile-sidebar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.cv-photo-frame {
  width: 220px;
  height: 270px;
  background-color: #ede1dd;
  border-radius: var(--radius-bento-sm);
  border: 1.5px solid var(--border-bento);
  overflow: hidden;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.1);
}

.cv-profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  background-color: #ede1dd;
}

.cv-profile-img[src*="Agenda-Valenciana-JoseRamonChirivella"] {
  object-position: 24% center;
}

.cv-chamber-badge {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 900;
  color: var(--subtitle-accessible);
  background: var(--subtitle-tint);
  border: 1.5px solid var(--subtitle-color);
  padding: 0.35rem 1.1rem;
  border-radius: var(--radius-btn-pill);
  text-align: center;
}

.cv-profile-header {
  border-bottom: 1.5px solid var(--border-soft);
  padding-bottom: 1.15rem;
  margin-bottom: 1.35rem;
}

.cv-candidate-name,
.cv-profile-name {
  font-family: var(--font-heading);
  font-size: clamp(1.65rem, 2.6vw, 2.2rem);
  font-weight: 900;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  line-height: 1.2;
  margin-bottom: 0.4rem;
}

.cv-candidate-role,
.cv-profile-subtitle {
  font-family: var(--font-heading);
  font-size: 1.02rem;
  font-weight: 800;
  color: #000000;
}

.cv-section-heading {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--subtitle-accessible);
  margin-bottom: 1rem;
}

.cv-content-body h3,
.cv-content-body h4 {
  font-family: var(--font-heading);
  font-size: 1.08rem;
  font-weight: 900;
  color: var(--subtitle-accessible);
  margin: 1.35rem 0 0.55rem;
}

.cv-content-body p {
  font-size: 0.96rem;
  line-height: 1.72;
  color: var(--text-main);
  margin-bottom: 0.85rem;
}

.cv-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.cv-list li {
  position: relative;
  padding-left: 1.25rem;
  font-size: 0.94rem;
  line-height: 1.62;
  color: var(--text-main);
}

.cv-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--subtitle-color);
}

/* ==========================================
   APARTADO 4: NOTICIAS (DESTACADO ARRANQUE DE CAMPAÑA Y RETÍCULA BENTO)
   ========================================== */
.campaign-launch-wrapper {
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-top: 6px solid var(--subtitle-color);
  border-radius: var(--radius-bento);
  padding: 1.75rem 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-bento);
}

.campaign-launch-table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
}

.campaign-launch-table td {
  vertical-align: middle;
}

.campaign-launch-col-images {
  width: 48%;
  padding-right: 1.85rem;
}

.campaign-launch-col-text {
  width: 52%;
}

.campaign-images-pair {
  display: grid;
  grid-template-columns: 0.88fr 1.12fr;
  gap: 0.9rem;
  align-items: stretch;
}

.campaign-launch-img {
  width: 100%;
  height: 295px;
  object-fit: cover;
  object-position: center;
  border-radius: var(--radius-bento-sm);
  border: 1.5px solid var(--border-bento);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
  display: block;
}

.campaign-launch-date-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-heading);
  font-size: 0.8rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--subtitle-accessible);
  background: var(--subtitle-tint);
  border: 1.5px solid var(--subtitle-color);
  padding: 0.3rem 0.9rem;
  border-radius: var(--radius-btn-pill);
  margin-bottom: 0.95rem;
}

.campaign-launch-text {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.72;
  color: var(--text-main);
  margin-bottom: 1.15rem;
}

.campaign-launch-social-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
  background: var(--bento-surface);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento-sm);
  padding: 0.75rem 1rem;
}

.social-inline-pill,
.footer-social-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  font-family: var(--font-heading);
  font-size: 0.86rem;
  font-weight: 800;
  padding: 0.36rem 0.82rem;
  border-radius: var(--radius-btn-pill);
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease, color 0.2s ease;
}

.social-pill-x {
  background-color: #0f172a;
  color: #ffffff !important;
  border: 1.5px solid #0f172a;
}

.social-pill-x:hover {
  background-color: #1e293b;
  color: var(--title-color) !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.18);
  text-decoration: none !important;
}

.social-pill-ig {
  background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
  color: #ffffff !important;
  border: 1.5px solid #cc2366;
}

.social-pill-ig:hover {
  filter: brightness(1.08);
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(220, 39, 67, 0.25);
  text-decoration: none !important;
}

.social-inline-pill svg,
.footer-social-pill svg {
  flex-shrink: 0;
}

.footer-social {
  margin-top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-social-label {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--text-main);
}

.footer-social-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}

/* ==========================================
   DESTACADO X (TWITTER): VÍDEO Y TABLA 5 COLUMNAS
   ========================================== */
.campaign-x-wrapper {
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-top: 6px solid #0f172a;
  border-radius: var(--radius-bento);
  padding: 1.75rem 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-bento);
}

.x-video-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 1.85rem;
}

.x-section-badge-row {
  width: 100%;
  display: flex;
  justify-content: flex-start;
  margin-bottom: 1.1rem;
}

.x-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #ffffff;
  background: #0f172a;
  border: 1.5px solid #0f172a;
  padding: 0.35rem 0.95rem;
  border-radius: var(--radius-btn-pill);
}

.x-video-embed-box {
  width: 100%;
  max-width: 580px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  min-height: 280px;
}

.x-video-embed-box .twitter-tweet {
  margin: 0 auto !important;
}

.x-table-section {
  width: 100%;
  border-top: 1px solid var(--border-soft);
  padding-top: 1.5rem;
}

.x-table-section-title {
  font-family: var(--font-heading);
  font-size: 1.12rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.x-table-section-title svg {
  flex-shrink: 0;
}

.x-posts-table-container {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.6rem;
}

.x-posts-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0.85rem 0;
  table-layout: fixed;
  min-width: 880px;
}

.x-posts-col {
  width: 20%;
  vertical-align: top;
  padding: 0;
}

.x-post-cell-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  min-height: 195px;
  background: var(--bento-surface);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento-sm);
  padding: 1rem 0.95rem;
  text-decoration: none !important;
  color: var(--text-main) !important;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.x-post-cell-card:hover {
  transform: translateY(-3px);
  border-color: var(--subtitle-color);
  box-shadow: 0 8px 20px rgba(17, 144, 211, 0.14);
}

.x-post-cell-card-accent {
  background: #f0f7ff;
  border-color: #bcd9f5;
}

.x-post-cell-card-accent:hover {
  border-color: var(--subtitle-color);
}

.x-cell-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  margin-bottom: 0.65rem;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--text-muted);
}

.x-cell-user-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: #0f172a;
  font-weight: 800;
}

.x-cell-date-tag {
  font-size: 0.72rem;
  color: var(--subtitle-accessible);
  background: var(--subtitle-tint);
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius-btn-pill);
  font-weight: 700;
}

.x-cell-content {
  font-family: var(--font-body);
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--text-main);
  margin-bottom: 0.9rem;
  flex-grow: 1;
}

.x-cell-foot {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--subtitle-accessible);
  margin-top: auto;
  padding-top: 0.55rem;
  border-top: 1px dashed var(--border-soft);
}

.x-post-cell-card:hover .x-cell-foot {
  color: var(--subtitle-bright);
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
}

.news-card {
  font-family: Georgia, 'Times New Roman', Times, serif;
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento);
  padding: 1rem 1.15rem 1.2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-bento);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.news-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-bento-hover);
  border-color: var(--subtitle-color);
}

.news-img-box {
  display: block;
  width: 100%;
  height: 150px;
  border-radius: var(--radius-bento-sm);
  overflow: hidden;
  margin-bottom: 0.7rem;
  background: var(--bento-surface);
  border: 1px solid var(--border-soft);
  flex-shrink: 0;
}

.news-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  transition: transform 0.35s ease;
}

.news-card:hover .news-thumb {
  transform: scale(1.04);
}

.news-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.news-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.45rem;
}

/* Nombre del medio en tamaño normal bajo la foto, menor que el titular y con contraste AAA */
.news-source {
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--subtitle-accessible);
}

.news-date {
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: 0.78rem;
  font-weight: 400;
  font-style: italic;
  color: var(--text-muted);
}

.news-title,
.news-title a {
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.34;
  letter-spacing: -0.005em;
  background-color: transparent;
  color: #000000;
  -webkit-text-stroke: 0;
  text-shadow: none;
}

.news-title {
  margin-bottom: 0.45rem;
}

.news-title a:hover {
  color: var(--subtitle-accessible);
  text-decoration: underline;
  text-underline-offset: 2px;
  -webkit-text-stroke: 0;
}

.news-excerpt {
  font-family: Georgia, 'Times New Roman', Times, serif;
  font-size: 0.88rem;
  line-height: 1.55;
  color: var(--text-main);
  margin-bottom: 0.85rem;
  flex-grow: 1;
}

.news-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 800;
  color: var(--subtitle-accessible);
  background: var(--subtitle-tint);
  border: 1px solid rgba(17, 144, 211, 0.3);
  padding: 0.42rem 0.85rem;
  border-radius: var(--radius-btn-pill);
  align-self: flex-start;
  margin-top: auto;
}

.news-link:hover {
  background: var(--subtitle-accessible);
  color: #ffffff;
}

/* ==========================================
   APARTADO 5: CONTACTO (RETÍCULA BENTO Y ACCESIBILIDAD WCAG)
   ========================================== */
.contact-wrapper {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

.contact-info {
  grid-column: span 5;
  background: var(--bento-bg);
  border: 1.5px solid var(--border-bento);
  border-radius: var(--radius-bento);
  padding: 2.25rem;
  box-shadow: var(--shadow-bento);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.contact-subtitle {
  font-family: var(--font-heading);
  font-size: 1.48rem;
  font-weight: 900;
  color: #000000;
  -webkit-text-stroke: 0;
  line-height: 1.3;
  margin-bottom: 0.85rem;
}

.contact-description {
  color: var(--text-main);
  font-size: 0.98rem;
  margin-bottom: 1.75rem;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.95rem;
  background: var(--bento-surface);
  padding: 1rem 1.15rem;
  border-radius: var(--radius-bento-sm);
  border: 1.5px solid var(--border-bento);
}

.detail-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-btn-med);
  background: var(--title-tint);
  border: 1.5px solid var(--title-color-base);
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-detail-item strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 900;
  color: var(--text-main);
}

.contact-detail-item span {
  font-size: 0.88rem;
  color: var(--subtitle-accessible);
  font-weight: 700;
}

.contact-form-card {
  grid-column: span 7;
  background: var(--bento-bg);
  border-radius: var(--radius-bento);
  padding: 2.25rem;
  box-shadow: var(--shadow-bento);
  border: 1.5px solid var(--border-bento);
}

.form-card-title {
  font-family: var(--font-heading);
  font-size: 1.55rem;
  font-weight: 900;
  letter-spacing: 0.015em;
  background-color: #ffffff;
  color: #ffffff;
  paint-order: stroke fill;
  -webkit-text-stroke: 3px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  margin-bottom: 0.25rem;
}

.form-card-subtitle {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 800;
  color: #000000;
  -webkit-text-stroke: 0;
  margin-bottom: 1.4rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group {
  margin-bottom: 1.1rem;
}

.form-group label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.4rem;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  min-height: 46px;
  padding: 0.78rem 1rem;
  border: 1.5px solid #94a3b8;
  border-radius: var(--radius-btn-med);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text-main);
  background-color: var(--bg-white);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--subtitle-accessible);
  box-shadow: 0 0 0 3px rgba(7, 89, 133, 0.22);
}

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
  font-size: 0.86rem;
  color: var(--text-main);
  font-weight: 500;
}

.form-check input {
  width: 18px;
  height: 18px;
  margin-top: 0.2rem;
  accent-color: var(--subtitle-accessible);
}

.privacy-legal-box {
  background-color: var(--bento-surface);
  border: 1px solid var(--border-bento);
  border-radius: var(--radius-bento-sm);
  padding: 0.85rem 1rem;
  margin-bottom: 1.35rem;
  font-size: 0.75rem;
  line-height: 1.55;
  color: var(--text-muted);
}

.privacy-legal-box strong {
  color: #000000;
  font-weight: 800;
}

.privacy-legal-box a {
  color: var(--subtitle-accessible);
  font-weight: 800;
  text-decoration: underline;
}

.btn-full {
  width: 100%;
}

.form-feedback {
  margin-top: 1rem;
  font-size: 0.9rem;
  font-weight: 700;
  text-align: center;
}

.form-feedback.success {
  color: #14532d;
  background: #dcfce7;
  border: 1.5px solid #16a34a;
  padding: 0.8rem;
  border-radius: var(--radius-btn-med);
}

.form-feedback.error {
  color: #7f1d1d;
  background: #fee2e2;
  border: 1.5px solid #dc2626;
  padding: 0.8rem;
  border-radius: var(--radius-btn-med);
}

/* ==========================================
   FOOTER (SOBRE FONDO BLANCO)
   ========================================== */
.site-footer {
  background-color: var(--bg-white);
  color: var(--text-main);
  padding: 3.5rem 0 2rem;
  border-top: 1.5px solid var(--border-bento);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 1fr;
  gap: 2rem;
  padding-bottom: 2.25rem;
  border-bottom: 1px solid var(--border-soft);
}

.footer-logo-img {
  height: 76px;
}

.footer-summary {
  margin-top: 1rem;
  font-size: 0.92rem;
  max-width: 420px;
  color: var(--text-muted);
}

.footer-links h4 {
  font-family: var(--font-heading);
  color: var(--title-color);
  letter-spacing: 0.015em;
  paint-order: stroke fill;
  -webkit-text-stroke: 2.2px #000000;
  stroke-linejoin: round;
  stroke-linecap: round;
  font-size: 1.08rem;
  font-weight: 900;
  margin-bottom: 0.9rem;
}

.footer-links ul {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.footer-links a {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--subtitle-accessible);
}

.footer-links a:hover {
  color: var(--text-main);
  text-decoration: underline;
}

.footer-bottom {
  padding-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.footer-credits {
  font-size: 0.82rem;
}

.footer-credits a {
  color: var(--subtitle-accessible);
  font-weight: 700;
  text-decoration: none;
}

.footer-credits a:hover {
  color: var(--text-main);
  text-decoration: underline;
}

/* ==========================================
   RESPONSIVE DESIGN (BENTO ADAPTATIVO)
   ========================================== */
@media (max-width: 992px) {
  .about-grid,
  .candidate-grid,
  .program-hero-banner,
  .program-cards-grid,
  .contact-wrapper {
    grid-template-columns: 1fr;
  }

  .about-text-col,
  .about-image-col,
  .candidate-photo-col,
  .candidate-bio-col,
  .program-hero-info,
  .program-hero-info-full,
  .program-hero-banner-full .program-hero-info,
  .program-photo-frame,
  .program-card,
  .contact-info,
  .contact-form-card {
    grid-column: 1 / -1;
    width: 100%;
    min-width: 0;
  }

  .news-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .campaign-launch-table,
  .campaign-launch-table tbody,
  .campaign-launch-table tr,
  .campaign-launch-table td {
    display: block;
    width: 100%;
  }

  .campaign-launch-col-images {
    padding-right: 0;
    margin-bottom: 1.35rem;
  }

  .campaign-launch-col-text {
    width: 100%;
  }

  .lista-congreso-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .cv-profile-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
  }

  .cv-profile-sidebar {
    width: 100%;
  }

  .cv-profile-main {
    width: 100%;
    min-width: 0;
  }

  .cv-profile-header {
    text-align: center;
  }

  .cv-profile-header .section-rule {
    margin-left: auto;
    margin-right: auto;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 1rem;
  }

  .top-bar-inner {
    justify-content: center;
  }

  .top-bar-badge {
    font-size: 0.76rem;
    padding: 0.2rem 0.7rem;
    text-align: center;
  }

  .top-bar-text {
    display: none;
  }

  .nav-container {
    height: 72px;
  }

  .brand-logo-img {
    height: 48px;
    max-width: 130px;
  }

  .header-actions {
    gap: 0.45rem;
  }

  .lang-btn {
    font-size: 0.75rem;
    padding: 0.3rem 0.55rem;
  }

  .footer-logo-img {
    height: 64px;
    max-width: 170px;
  }

  .mobile-menu-btn {
    display: flex;
  }

  .main-nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--bg-white);
    border-bottom: 1.5px solid var(--border-bento);
    box-shadow: var(--shadow-bento-hover);
    padding: 1rem 1.25rem;
    display: none;
  }

  .main-nav.open {
    display: block;
  }

  .nav-list {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .section {
    padding: 2.5rem 0;
  }

  .section-header {
    margin-bottom: 1.5rem;
  }

  .section-subtitle {
    font-size: 0.78rem;
    padding: 0.3rem 0.85rem;
  }

  .section-title {
    font-size: clamp(1.65rem, 6.5vw, 2.1rem);
    -webkit-text-stroke: 2.5px #000000;
  }

  .hero-section {
    padding: 2.75rem 0 3.25rem;
  }

  .hero-container {
    min-height: auto;
  }

  .hero-title {
    font-size: clamp(1.9rem, 7.5vw, 2.4rem);
    -webkit-text-stroke: 3.5px #000000;
  }

  .hero-subtitle {
    font-size: 0.98rem;
    -webkit-text-stroke: 1.2px #29b6ff;
  }

  .hero-subtitle-h2,
  h2.hero-title {
    font-size: 1.22rem;
    -webkit-text-stroke: 1.5px #29b6ff;
  }

  .hero-lead,
  .hero-lead strong {
    font-size: 1rem;
    -webkit-text-stroke: 2px #000000;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .quick-access-grid,
  .pillars-strip,
  .form-row,
  .candidate-credentials,
  .news-grid,
  .lista-top-pair,
  .lista-congreso-grid {
    grid-template-columns: 1fr;
  }

  .quick-access-card,
  .friendly-card,
  .program-hero-info,
  .program-card,
  .contact-form-card,
  .contact-info,
  .lista-chamber-block,
  .cv-profile-card,
  .campaign-launch-wrapper,
  .campaign-x-wrapper {
    padding: 1.3rem 1.05rem;
  }

  .campaign-images-pair {
    grid-template-columns: 1fr;
  }

  .campaign-launch-img {
    height: auto;
    max-height: 360px;
  }

  /* Ajustes responsive de Programa Electoral (programa.html e index) */
  .program-badge-29n {
    font-size: 0.75rem;
    padding: 0.28rem 0.75rem;
  }

  .program-banner-title {
    font-size: 1.32rem;
    -webkit-text-stroke: 2.2px #000000;
    line-height: 1.26;
  }

  .program-banner-subtitle {
    font-size: 0.92rem;
    margin-bottom: 1.05rem;
  }

  .program-quick-nav {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    width: 100%;
  }

  .quick-pill {
    font-size: 0.78rem;
    padding: 0.38rem 0.65rem;
    min-height: 38px;
    width: 100%;
    justify-content: flex-start;
  }

  .program-number {
    font-size: 1.85rem;
    -webkit-text-stroke: 2.3px #000000;
  }

  .program-icon {
    width: 40px;
    height: 40px;
  }

  .program-card-title {
    font-size: 1.24rem;
    -webkit-text-stroke: 2.2px #000000;
    line-height: 1.28;
  }

  .program-card-subtitle {
    font-size: 0.9rem;
    margin-bottom: 0.9rem;
    padding-bottom: 0.7rem;
  }

  .program-measures {
    gap: 0.75rem;
  }

  .program-measures li {
    font-size: 0.9rem;
    line-height: 1.58;
    padding-left: 1.1rem;
  }

  /* Ajustes responsive de Currículum de Candidatos (candidato-*.html) */
  .subpage-back-row {
    margin-bottom: 1rem;
  }

  .btn-back-link {
    font-size: 0.84rem;
    padding: 0.48rem 0.95rem;
  }

  .cv-photo-frame {
    width: 165px;
    height: 205px;
    margin: 0 auto;
  }

  .cv-chamber-badge {
    font-size: 0.78rem;
    padding: 0.3rem 0.9rem;
  }

  .cv-profile-header {
    padding-bottom: 0.95rem;
    margin-bottom: 1.1rem;
  }

  .cv-candidate-name,
  .cv-profile-name {
    font-size: 1.36rem;
    -webkit-text-stroke: 2.2px #000000;
    line-height: 1.26;
    word-break: break-word;
  }

  .cv-candidate-role,
  .cv-profile-subtitle {
    font-size: 0.9rem;
    line-height: 1.45;
  }

  .cv-content-body h3,
  .cv-content-body h4 {
    font-size: 1rem;
    margin: 1.1rem 0 0.45rem;
  }

  .cv-content-body p {
    font-size: 0.9rem;
    line-height: 1.62;
  }

  .cv-list li {
    font-size: 0.9rem;
    line-height: 1.58;
    padding-left: 1.05rem;
  }
}

@media (max-width: 390px) {
  .program-quick-nav {
    grid-template-columns: 1fr;
  }
}
