/* CDC: mejoras visuales 2026-11-26 */

/* ============ 1. Titulares de artĆ­culos y categorĆ­as ============ */
/* h1: blanco (antes rojo neĆ³n #f00000, contraste 4,4) y tamaĆ±o fluido (antes 47,6 px fijos en mĆ³vil) */
#content_full .page-header h1 {
  color: #ffffff !important;
  font-size: clamp(1.75rem, 1.15rem + 1.9vw, 2.45rem) !important;
  line-height: 1.2 !important;
  font-weight: 700 !important;
  letter-spacing: -0.015em;
  margin: 0 0 0.35em !important;
}
#content_full .page-header h1::after {
  content: "";
  display: block;
  width: 56px;
  height: 3px;
  margin-top: 0.55em;
  background: #e41e27;
  border-radius: 2px;
}
/* h2 del cuerpo: rojo de marca, mĆ�s grueso y mĆ�s contenido (antes #f00000, peso 300, 35 px) */
.com-content-article__body h2 {
  color: #e41e27 !important;
  font-size: clamp(1.45rem, 1.1rem + 1.2vw, 1.95rem) !important;
  font-weight: 600 !important;
  line-height: 1.25 !important;
  margin: 1.7em 0 0.55em !important;
}
/* LĆ­nea Ā«CategorĆ­a: ā€¦Ā» con mĆ�s contraste */
.com-content-article .article-info.text-muted,
.com-content-article .article-info.text-muted dd {
  color: #b9a79b !important;
}

/* ============ 2. Ancho de lectura del texto (70 caracteres) ============ */
/* No afecta a imĆ�genes, figuras, tablas ni tarjetas de herramienta */
.com-content-article__body > p:not(:has(img)):not(:has(figure)),
.com-content-article__body > ul,
.com-content-article__body > ol,
.com-content-article__body > blockquote {
  max-width: 70ch;
}

/* ============ 3. Enlaces dentro del contenido (antes azul #1c72c7, contraste 4,0) ============ */
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]) {
  color: #e8c4a8 !important;
  text-decoration: underline;
  text-decoration-color: rgba(232, 196, 168, 0.45);
  text-underline-offset: 3px;
}
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]):hover,
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]):focus-visible {
  color: #ffffff !important;
  text-decoration-color: #e41e27;
}
.cdc-tool-card a { text-decoration: none; }

/* ============ 4. Tablas en mĆ³vil: desplazamiento interno en vez de romper la pĆ�gina ============ */
@media (max-width: 767.98px) {
  .com-content-article__body table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    font-size: 0.88rem;
  }
  .com-content-article__body table th,
  .com-content-article__body table td {
    padding: 6px 8px;
    min-width: 96px;
    vertical-align: top;
  }
}

/* ============ 5. Logo de la cabecera ============ */
#logo img.logo-image,
#logo .primary-logo-image {
  height: 52px !important;
  width: auto !important;
  max-width: none !important;
}

/* ============ 6. Cabecera mĆ³vil: logo y hamburguesa en una sola fila, sin redes ============ */
@media (max-width: 767.98px) {
  #socialmedia { display: none !important; }
  .header-wrap {
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: space-between !important;
  }
  #logo { padding: 0 0 0 14px !important; width: auto !important; }
  #logo img.logo-image,
  #logo .primary-logo-image { height: 40px !important; }
  .slideout-toggle-open { margin-left: auto; flex: 0 0 auto; }
}

/* ============ 7. MenĆŗ mĆ³vil (slideout): primer nivel en blanco, submenĆŗs sin tocar ============ */
#slideout > ul.menu > li > a,
#slideout > ul.menu > li > a:link,
#slideout > ul.menu > li > a:visited {
  color: #ffffff !important;
}
#slideout > ul.menu > li > a:hover,
#slideout > ul.menu > li > a:active,
#slideout > ul.menu > li.active > a {
  color: #e41e27 !important;
}

/* ============ 8. Aviso de cookies compacto (plugin cookiehint, estilo flatline) ============ */
#redim-cookiehint {
  padding: 10px 20px !important;
  max-height: 72vh;
  overflow-y: auto;
}
#redim-cookiehint .redim-cc-head { margin: 0 0 6px !important; }
#redim-cookiehint .redim-cc-headline { font-size: 0.85rem !important; line-height: 1.2 !important; margin: 0 !important; }
#redim-cookiehint .redim-cc-content p {
  font-size: 11.5px !important;
  line-height: 1.4 !important;
  margin: 0 0 8px !important;
}
#redim-cookiehint .redim-cc-cookiebuttons { margin: 4px 0 0 !important; gap: 8px !important; }
#redim-cookiehint .redim-cc-btn { padding: 8px 14px !important; font-size: 11.5px !important; }
#redim-cookiehint #cookiehintinfo { margin: 2px 0 0 !important; font-size: 11px !important; }
@media (max-width: 767.98px) {
  #redim-cookiehint { padding: 10px 14px !important; }
  #redim-cookiehint .redim-cc-cookiebuttons { flex-wrap: nowrap !important; gap: 6px !important; }
  #redim-cookiehint .redim-cc-btn { padding: 8px 8px !important; font-size: 11px !important; flex: 1 1 auto; }
  #redim-cookiehint .redim-cc-head { display: none !important; }
  #redim-cookiehint .redim-cc-content p { font-size: 11px !important; line-height: 1.38 !important; }
}

/* ============ 9. Pie de pĆ�gina ============ */
#container_base footer { padding: 30px 32px !important; }
#container_base footer .copyright p,
#container_base footer .copyright span { font-size: 13px !important; line-height: 1.7 !important; }
#container_base footer .footermenu { padding: 6px 0 !important; }

/* ============ 10. Etiqueta Ā«NuevoĀ» como pastilla pequeĆ±a junto al tĆ­tulo ============ */
.cdc-badge-nuevo,
.cdc-ultimos .cdc-badge-nuevo,
.cdc-destacado .cdc-badge-nuevo {
  display: inline-block !important;
  margin-left: 0.6em;
  padding: 0.18em 0.6em;
  font-size: 0.68rem !important;
  font-weight: 700;
  line-height: 1.45;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  vertical-align: middle;
  color: #ffffff !important;
  background: #c4161d;
  border-radius: 999px;
}

/* ============ 11. Portada: tĆ­tulos de secciĆ³n coherentes ============ */
.top-1 .module_header h2,
.bottom-1 .module_header h2,
.bottom-1 .module_header h3,
.base-1 .module_header h2 {
  text-align: center !important;
  color: #e41e27 !important;
  font-size: clamp(1.55rem, 1.2rem + 1.2vw, 2.05rem) !important;
  font-weight: 600 !important;
  line-height: 1.25 !important;
}
.base-2 .module_header h3 { color: #e41e27 !important; }

/* ============ 12. Pie con enlaces a las secciones (mĆ³dulo HTML Ā«Secciones del sitioĀ») ============ */
.cdc-footer-nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 28px 40px;
  max-width: 1076px;
  margin: 0 auto;
  padding: 34px 0 10px;
  border-top: 1px solid rgba(184, 125, 100, 0.25);
}
.cdc-footer-nav h4 {
  margin: 0 0 0.8rem;
  color: #e41e27;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.cdc-footer-nav ul { list-style: none; margin: 0; padding: 0; }
.cdc-footer-nav li { margin: 0 0 0.2rem !important; padding: 0 !important; line-height: 1.45 !important; }
.cdc-footer-nav a { color: #e8c4a8 !important; font-size: 0.92rem; text-decoration: none; }
.cdc-footer-nav a:hover,
.cdc-footer-nav a:focus-visible { color: #ffffff !important; text-decoration: underline; }

/* ============ 13. Migas de pan (arriba y abajo) ============ */
#container_top1_modules .mod-breadcrumbs,
#container_top1_modules .breadcrumb {
  margin: 0 !important;
  padding: 0.7rem 0 0 !important;
  font-size: 0.9rem !important;
  background: transparent !important;
}
#container_top1_modules:has(.mod-breadcrumbs) { background: #000 !important; }
#container_top1_modules:has(.mod-breadcrumbs) #top1_modules { padding: 0 32px !important; }
#container_top1_modules .mod-breadcrumbs a,
#container_top1_modules .breadcrumb a { color: #e8c4a8 !important; text-decoration: none; }
#container_top1_modules .mod-breadcrumbs a:hover { color: #ffffff !important; text-decoration: underline; }
#container_top1_modules .mod-breadcrumbs__here { color: #b9a79b; }
#container_top1_modules .mod-breadcrumbs { gap: 0; }
#container_top1_modules .module,
#container_top1_modules .module_surround,
#container_top1_modules .module_content { margin: 0 !important; padding: 0 !important; }

/* CDC: submenĆŗs del menĆŗ mĆ³vil en blanco apagado (2026-11-26) */
#slideout ul.mod-menu__sub a,
#slideout ul.mod-menu__sub a:link,
#slideout ul.mod-menu__sub a:visited { color: rgba(255,255,255,0.7) !important; }
#slideout ul.mod-menu__sub a:hover,
#slideout ul.mod-menu__sub a:active,
#slideout ul.mod-menu__sub li.active > a { color: #e41e27 !important; }

/* CDC: columnas del pie centradas en su espacio (2026-11-26) */
@media (min-width: 768px) {
  .cdc-footer-nav { grid-template-columns: repeat(3, 1fr); }
  .cdc-footer-nav > div { justify-self: center; min-width: 200px; }
}



/* CDC: enlaces del contenido en blanco, rojo al pasar el raton (2026-11-26) */
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]),
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]):link,
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]):visited { color: #ffffff !important; text-decoration-color: rgba(255,255,255,0.35) !important; }
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]):hover,
.com-content-article__body a:not(.cdc-tool-btn):not(.btn):not([class*="cdc-btn"]):focus-visible { color: #e41e27 !important; text-decoration-color: #e41e27 !important; }






/* CDC: mejoras movil (cookies, menu) (2026-11-27) */

/* --- Parte 1: aviso de cookies compacto en movil --- */
/* Los selectores llevan #redim-cookiehint-bottom + #redim-cookiehint para ganar a style-flatline.css */
@media (max-width: 767.98px) {
  #redim-cookiehint-bottom #redim-cookiehint.redim-tpl.redim-tpl-flyout-right {
    padding: 8px 12px 4px !important;
    max-height: 32vh !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
  }
  /* con "Configurar cookies" abierto se deja mas altura y se desplaza dentro */
  #redim-cookiehint-bottom #redim-cookiehint.redim-tpl.redim-tpl-flyout-right:has(.redim-cc-details:not([hidden])) {
    max-height: 75vh !important;
  }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-head { display: none !important; }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-content { margin: 0 0 6px !important; }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-content p {
    margin: 0 !important;
    font-size: 11px !important;
    line-height: 1.35 !important;
  }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-cookiebuttons {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 6px !important;
    margin: 0 !important;
    max-width: none !important;
  }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-btn {
    flex: 1 1 0 !important;
    width: auto !important;
    min-width: 0 !important;
    min-height: 40px !important;
    margin: 0 !important;
    padding: 4px 4px !important;
    font-size: 10.5px !important;
    line-height: 1.15 !important;
    letter-spacing: 0.02em !important;
  }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-toggle-details { flex-grow: 1.15 !important; }
  #redim-cookiehint-bottom #redim-cookiehint .redim-cc-save-row { margin-top: 8px !important; }
  #redim-cookiehint-bottom #redim-cookiehint #cookiehintinfo {
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.2 !important;
    text-align: center !important;
  }
  #redim-cookiehint-bottom #redim-cookiehint #cookiehintinfo a {
    display: inline-block !important;
    padding: 6px 10px !important;
    font-size: 11px !important;
  }
}

/* --- Parte 3: menu movil (#slideout) mas vistoso --- */
/* Solo CSS; no toca el JS de abrir/cerrar ni los displays de los submenus */
@media (max-width: 1140px) {
  /* fondo con degradado calido muy sutil y filo rojo a la izquierda */
  #slideout.slideout-menu {
    background: linear-gradient(180deg, #1a1311 0%, #0d0b0a 38%, #070707 100%) !important;
    border-left: 2px solid rgba(228, 30, 39, 0.75) !important;
    box-shadow: inset 14px 0 18px -14px rgba(0, 0, 0, 0.6) !important;
  }

  /* barra superior con el logo (a la izquierda) y el icono de cerrar (a la derecha) */
  #slideout .slideout-toggle-close {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    min-height: 64px !important;
    padding: 6px 15px !important;
    background: rgba(255, 255, 255, 0.03) !important;
    border-bottom: 1px solid rgba(232, 196, 168, 0.22) !important;
  }
  #slideout .slideout-toggle-close::before {
    content: "";
    position: absolute;
    left: 16px;
    top: 50%;
    width: 150px;
    height: 36px;
    transform: translateY(-50%);
    background: url("/images/logos/logo-cdc-header.webp") left center / contain no-repeat;
  }

  /* lista principal */
  #slideout .menu { padding: 8px 0 24px !important; }
  #slideout .menu li { margin-bottom: 0 !important; }
  #slideout .menu > li { border-bottom: 1px solid rgba(232, 196, 168, 0.12); }

  /* elementos principales: blanco intenso, mas altos, barra roja al tocar/activo */
  #slideout ul.menu > li > a,
  #slideout ul.menu > li > a:link,
  #slideout ul.menu > li > a:visited {
    align-items: center !important;
    min-height: 52px !important;
    padding: 12px 16px 12px 18px !important;
    border-left: 3px solid transparent !important;
    color: #ffffff !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    letter-spacing: 0.01em !important;
    opacity: 1 !important;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease !important;
  }
  #slideout ul.menu > li > a:hover,
  #slideout ul.menu > li > a:active,
  #slideout ul.menu > li > a:focus-visible,
  #slideout ul.menu > li.active > a {
    color: #e41e27 !important;
    border-left-color: #e41e27 !important;
    background: linear-gradient(90deg, rgba(228, 30, 39, 0.18), rgba(228, 30, 39, 0)) !important;
  }
  /* seccion desplegada: barra roja y fondo suave, el texto sigue en blanco */
  #slideout ul.menu > li.open > a:not(:hover):not(:active) {
    border-left-color: #e41e27 !important;
    background: linear-gradient(90deg, rgba(228, 30, 39, 0.10), rgba(228, 30, 39, 0)) !important;
  }

  /* flecha (chevron) en los elementos con submenu; gira al abrir */
  #slideout .menu li.parent > a::after {
    content: "";
    flex: 0 0 auto;
    width: 8px;
    height: 8px;
    margin: -3px 4px 0 auto;
    border-right: 2px solid #e8c4a8;
    border-bottom: 2px solid #e8c4a8;
    transform: rotate(45deg);
    transition: transform 0.25s ease;
  }
  #slideout .menu li.parent.open > a::after {
    margin-top: 3px;
    transform: rotate(-135deg);
  }

  /* submenus: sangria con hilo dorado, blanco apagado, rojo al tocar/activo */
  #slideout ul.mod-menu__sub {
    margin: 0 0 8px 26px !important;
    padding: 0 !important;
    border-left: 1px solid rgba(232, 196, 168, 0.28);
  }
  #slideout ul.mod-menu__sub a,
  #slideout ul.mod-menu__sub a:link,
  #slideout ul.mod-menu__sub a:visited {
    align-items: center !important;
    min-height: 42px !important;
    padding: 9px 12px 9px 14px !important;
    font-size: 14px !important;
    line-height: 1.3 !important;
    opacity: 1 !important;
    color: rgba(255, 255, 255, 0.7) !important;
    transition: background 0.2s ease, box-shadow 0.2s ease, color 0.2s ease !important;
  }
  #slideout ul.mod-menu__sub a:hover,
  #slideout ul.mod-menu__sub a:active,
  #slideout ul.mod-menu__sub a:focus-visible,
  #slideout ul.mod-menu__sub li.active > a {
    color: #e41e27 !important;
    box-shadow: inset 2px 0 0 #e41e27 !important;
    background: rgba(228, 30, 39, 0.08) !important;
  }
  #slideout ul.mod-menu__sub li.parent > a::after {
    width: 6px;
    height: 6px;
    border-color: rgba(232, 196, 168, 0.7);
  }

  /* detalle final: firma discreta al pie de la lista */
  #slideout ul.menu::after {
    content: "cuartodecomunicaciones.com";
    display: block;
    margin: 22px 18px 0;
    padding-top: 14px;
    border-top: 1px solid rgba(232, 196, 168, 0.18);
    color: rgba(232, 196, 168, 0.55);
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.08em;
    text-align: center;
  }
}
/* CDC: texto blanco en la etiqueta Nuevo (2026-11-27) */
body .cdc-badge-nuevo,
body .cdc-ultimos .cdc-badge-nuevo,
body .cdc-destacado .cdc-badge-nuevo { color: #ffffff !important; background: #c4161d !important; }
/* CDC: separacion entre botones de las tarjetas de articulo (2026-11-27) */
.com-content-article__body .cdc-tool-card > a[style*="inline-flex"] { margin: 0.4rem 0.35rem !important; }
.com-content-article__body .cdc-tool-card > a[style*="inline-flex"] { margin: 0.4rem auto !important; align-self: center !important; width: auto !important; }

/* CDC: contadores portada (2026-11-27) */
/* Solo el modulo j51 Numbers 142, en la posicion top-3 de la portada. */
/* Las comillas y el texto de las frases viven en el modulo; el CSS no los cambia. */

/* Evita que la banda a todo el ancho genere un scroll horizontal */
#container_top3_modules {
  overflow-x: hidden;
}

/* Espacio respecto a las tarjetas de arriba, banda oscura calida y filetes dorados */
#container_top3_modules .j51_numbers142 {
  position: relative;
  z-index: 0;
  margin: 50px 0 0 !important;
  padding: 36px 8px 40px !important;
}
#container_top3_modules .j51_numbers142::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  background: #14110f;
  border-top: 1px solid rgba(232, 196, 168, 0.25);
  border-bottom: 1px solid rgba(232, 196, 168, 0.25);
  pointer-events: none;
}

/* Cifras: Open Sans, negrita, rojo de la web, mismo tamano que ahora */
#container_top3_modules .j51_numbers142 .j51_numbers_number,
#container_top3_modules .j51_numbers142 .j51_number_value {
  font-family: "Open Sans", Arial, Verdana, sans-serif !important;
  font-size: 40px !important;
  font-weight: 800 !important;
  line-height: 1.15 !important;
  letter-spacing: -0.02em;
  color: #e41e27 !important;
  font-variant-numeric: tabular-nums;
}

/* Etiquetas (DESCARGAS, etc.): mismo tratamiento que el kicker del hero, en dorado */
#container_top3_modules .j51_numbers142 .j51_number_title {
  margin: 6px 0 8px !important;
  font-family: "Open Sans", Arial, Verdana, sans-serif !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  letter-spacing: 0.15em !important;
  text-transform: uppercase !important;
  line-height: 1.3 !important;
  color: #e8c4a8 !important;
}

/* Frases: blanco/beige apagado, mas pequenas */
#container_top3_modules .j51_numbers142 .j51_number_caption {
  margin: 0 auto !important;
  max-width: 16.5em;
  font-size: 13px !important;
  font-weight: 400 !important;
  line-height: 1.4 !important;
  color: rgba(232, 196, 168, 0.72) !important;
}

/* Escritorio: separadores verticales finos entre las cuatro cifras */
@media (min-width: 768px) {
  #container_top3_modules .j51_numbers142 .j51_numbers_item {
    padding: 8px 22px !important;
  }
  #container_top3_modules .j51_numbers142 .j51_numbers_item:not(:last-child) {
    border-right: 1px solid rgba(232, 196, 168, 0.25);
  }
}

/* Movil: rejilla 2x2, sin separadores */
@media (max-width: 767.98px) {
  #container_top3_modules .j51_numbers142 {
    margin-top: 50px !important;
    padding: 28px 4px 32px !important;
  }
  #container_top3_modules .j51_numbers142 .j51_numbers_item {
    flex: 0 0 50% !important;
    max-width: 50% !important;
    padding: 16px 10px !important;
    border: 0 !important;
  }
}
/* CDC: contadores alineados arriba (2026-11-26) */
#container_top3_modules .j51_numbers142 { align-items: flex-start !important; }
#container_top3_modules .j51_numbers142 .j51_numbers_item { justify-content: flex-start !important; align-self: stretch !important; }
/* CDC: signo + en descargas y comandos (2026-11-26) */
#container_top3_modules #counter142i1::after,
#container_top3_modules #counter142i2::after { content: "+"; margin-left: 2px; font-size: 0.75em; vertical-align: 0.12em; }
#container_top3_modules #counter142i3::after { content: "+"; margin-left: 2px; font-size: 0.75em; vertical-align: 0.12em; }

/* CDC: pildora proximamente (2026-11-26) */
.com-content-article__body .cdc-pill-pronto,
.cdc-pill-pronto {
  display: inline-block;
  padding: 0.15em 0.65em;
  font-size: 0.68em;
  font-weight: 700;
  font-style: normal;
  line-height: 1.5;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  vertical-align: 0.1em;
  color: #14110f !important;
  background: #e8c4a8 !important;
  border-radius: 999px;
}