/* TendenciasFX · Herramientas gratuitas · estilos comunes v2.0 (14-10-2026)
   Una sola hoja para todas las herramientas: la cabecera y el pie con el aspecto de tendenciasfx.com,
   la plantilla de la página (tfx-herr-*) y los componentes de las calculadoras.
   No depende de WordPress ni del tema. Sin fuentes de terceros: Oswald y Quicksand si están
   instaladas o en _comun/fuentes/ (ver el final); si no, las del sistema más parecidas. */

:root {
  --tinta: #2f323a; --tinta2: #52565e; --tenue: #6b7079;
  --gris: #474c55; --claro: #e1e0dc; --borde: #b9bbc0; --fondo: #f6f6f4;
  --verde: #82c341; --verde-texto: #4d8316; --oro: #f9c20a;
  --nominal: #3d7a14; --real: #c48a00; --puesto: #9a9ca1; --error: #b3261e;
  --oswald: Oswald, "Bahnschrift Condensed", "Arial Narrow", "Roboto Condensed", "Avenir Next Condensed", sans-serif;
  --quick: Quicksand, "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --texto: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --ancho: 1040px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html.tfx-herr-con-barra { scroll-padding-bottom: 80px; }
body { margin: 0; background: #f4f4f4; color: var(--tinta); font: 17px/1.65 var(--texto); }
img { max-width: 100%; height: auto; }
a { color: var(--verde-texto); }
a:hover { color: #3c6711; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--nominal); outline-offset: 2px; }
.tfx-herr-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.tfx-herr-saltar { position: absolute; left: 8px; top: -60px; z-index: 50; padding: 10px 14px; background: var(--oro); color: var(--tinta); font-family: var(--quick); font-weight: 600; }
.tfx-herr-saltar:focus { top: 8px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

/* 1. CABECERA DEL SITIO (como la de tendenciasfx.com) */
.tfx-herr-sitio-cab { background: var(--gris); }
.tfx-herr-sitio-cab-in { max-width: 1180px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.tfx-herr-logo { display: block; line-height: 0; }
.tfx-herr-logo img { width: 198px; height: auto; }
.tfx-herr-menu { display: flex; gap: 28px; }
.tfx-herr-menu a { color: #fff; text-decoration: none; font: 500 16px/1.2 var(--quick); padding: 10px 0; }
.tfx-herr-menu a:hover { color: var(--verde); }
.tfx-herr-menu-movil { display: none; position: relative; }
.tfx-herr-menu-movil summary { list-style: none; cursor: pointer; color: var(--verde); border: 1px solid var(--verde); padding: 8px 12px; font: 500 15px/1 var(--quick); }
.tfx-herr-menu-movil summary::-webkit-details-marker { display: none; }
.tfx-herr-menu-movil nav { position: absolute; right: 0; top: calc(100% + 8px); z-index: 30; min-width: 190px; background: var(--gris); box-shadow: 0 8px 20px rgba(0,0,0,.25); }
.tfx-herr-menu-movil nav a { display: block; padding: 12px 16px; color: #fff; text-decoration: none; font: 500 16px/1.2 var(--quick); border-top: 1px solid #5b606a; }
@media (max-width: 921px) {
  .tfx-herr-menu { display: none; }
  .tfx-herr-menu-movil { display: block; }
  .tfx-herr-logo img { width: 150px; }
}

/* 2. PÁGINA */
.tfx-herr-pag { max-width: var(--ancho); margin: 8px auto 0; background: #fff; }
.tfx-herr-cabecera { background: linear-gradient(135deg, #1f3a12 0%, #3a6420 100%); color: #fff; padding: 40px clamp(20px, 5vw, 56px) 44px; }
.tfx-herr-migas { margin: 0 0 14px; font: 14px/1.4 var(--quick); color: #c9cbcf; }
.tfx-herr-migas a { color: #c9cbcf; text-decoration: none; }
.tfx-herr-migas a:hover { color: var(--oro); }
.tfx-herr-migas span[aria-hidden] { margin: 0 6px; }
.tfx-herr-insignia { display: inline-block; margin: 0 0 14px; padding: 4px 12px; background: var(--oro); color: var(--tinta); font: 500 13px/1.4 var(--quick); letter-spacing: .05em; text-transform: uppercase; }
.tfx-herr-h1 { margin: 0 0 12px; font: 300 clamp(32px, 4.4vw, 48px)/1.15 var(--oswald); letter-spacing: .01em; color: #fff; }
.tfx-herr-frase { margin: 0 0 18px; max-width: 760px; font-size: 19px; line-height: 1.5; color: #e6e7e9; }
.tfx-herr-autor { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0; font: 15px/1.4 var(--quick); color: #e6e7e9; }
.tfx-herr-autor img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 2px solid var(--verde); }
.tfx-herr-autor a { color: var(--oro); text-decoration: none; }
.tfx-herr-herramienta { padding: 24px; border: 1px solid var(--claro); border-top: 0; }
.tfx-herr-cuerpo { padding: 8px clamp(20px, 5vw, 56px) 40px; }
.tfx-herr-seccion { margin: 40px 0 0; }
.tfx-herr-h2 { margin: 0 0 14px; font: 300 30px/1.2 var(--oswald); color: var(--gris); }
.tfx-herr-h3 { margin: 22px 0 8px; font: 600 19px/1.35 var(--quick); color: var(--tinta); }
.tfx-herr-seccion p { margin: 0 0 14px; }
.tfx-herr-respuesta { padding: 20px 24px; background: var(--fondo); border-left: 4px solid var(--verde); }
.tfx-herr-quehacer { padding: 20px 24px; border: 1px solid var(--claro); border-left: 4px solid var(--oro); }
.tfx-herr-respuesta > :last-child, .tfx-herr-quehacer > :last-child { margin-bottom: 0; }
.tfx-herr-tabla-ancha { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.tfx-herr-tabla-simple { width: 100%; max-width: 680px; margin: 4px 0 18px; border-collapse: collapse; font-size: 16px; font-variant-numeric: tabular-nums; }
.tfx-herr-tabla-simple caption { padding: 0 0 6px; text-align: left; font: 600 15px/1.4 var(--quick); color: var(--verde-texto); }
.tfx-herr-tabla-simple th, .tfx-herr-tabla-simple td { padding: 8px 10px; border-bottom: 1px solid var(--claro); text-align: left; vertical-align: top; }
.tfx-herr-tabla-simple td { text-align: right; }
.tfx-herr-tabla-simple tbody th { font-weight: 400; color: var(--tinta2); }
.tfx-herr-tabla-simple thead th { text-align: right; font-weight: 600; }
.tfx-herr-tabla-simple thead th:first-child { text-align: left; }
.tfx-herr-tabla-simple .tfx-herr-destacada > * { font-weight: 700; color: var(--tinta); }
.tfx-herr-tabla-esc { min-width: 420px; }
.tfx-herr-tabla-casos td { white-space: normal; }
.tfx-herr-tabla-casos td:last-child { white-space: nowrap; font-weight: 600; }
.tfx-herr-tabla-casos td:nth-child(2) { text-align: left; font-family: Consolas, "Courier New", monospace; font-size: 14px; }
@media (max-width: 520px) { .tfx-herr-tabla-simple { font-size: 14px; } .tfx-herr-tabla-simple th, .tfx-herr-tabla-simple td { padding: 7px 6px; } }
.tfx-herr-seccion-video:has(.tfx-herr-video[data-video=""]) { display: none; }
.tfx-herr-video { position: relative; width: 100%; max-width: 760px; aspect-ratio: 16 / 9; background: var(--tinta); display: flex; align-items: center; justify-content: center; }
.tfx-herr-video iframe, .tfx-herr-video-boton { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.tfx-herr-video-boton { padding: 0; background: #000; cursor: pointer; }
.tfx-herr-video-boton img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: .85; }
.tfx-herr-video-play { position: absolute; left: 50%; top: 50%; width: 76px; height: 54px; margin: -27px 0 0 -38px; background: var(--oro); border-radius: 12px; }
.tfx-herr-video-play::after { content: ""; position: absolute; left: 31px; top: 16px; border-style: solid; border-width: 11px 0 11px 19px; border-color: transparent transparent transparent var(--tinta); }
.tfx-herr-faq-item { padding: 0 0 6px; border-bottom: 1px solid var(--claro); }
.tfx-herr-fuentes ul { margin: 0 0 14px 1.2em; padding: 0; }
.tfx-herr-fuentes li, .tfx-herr-fuentes p { font-size: 15px; line-height: 1.6; }
.tfx-herr-fuentes li { margin: 0 0 8px; }
.tfx-herr-insertar textarea { display: block; width: 100%; min-height: 128px; margin: 0 0 10px; padding: 10px 12px; border: 1px solid var(--borde); background: var(--fondo); font: 13px/1.5 Consolas, "Courier New", monospace; color: var(--tinta); resize: vertical; }
/* lo que falta por escribir (JH): se ve a propósito y desaparece con el texto final */
.tfx-herr-pendiente { padding: 10px 12px; background: #fff8dc; border: 1px dashed #c9a100; color: #5c4700; font-size: 15px; line-height: 1.5; }
.tfx-herr-cabecera .tfx-herr-pendiente { background: rgba(255,248,220,.14); border-color: var(--oro); color: #fff4c2; }
h2.tfx-herr-pendiente { font-size: 24px; }

/* 3. LAS DOS CAJAS DEL FINAL Y EL PIE */
.tfx-herr-cajas { max-width: var(--ancho); margin: 28px auto; display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 20px; padding: 0 0; }
.tfx-herr-caja { background: #fff; border: 1px solid var(--claro); border-top: 4px solid var(--verde); padding: 22px 24px; }
.tfx-herr-caja-tit { margin: 0 0 6px; font: 300 24px/1.25 var(--oswald); color: var(--gris); }
.tfx-herr-caja p { margin: 0 0 14px; font-size: 16px; }
.tfx-herr-caja-fila { display: flex; gap: 8px; flex-wrap: wrap; }
.tfx-herr-caja-fila input { flex: 1 1 200px; min-width: 0; height: 46px; padding: 0 12px; border: 1px solid var(--borde); font: 16px var(--texto); }
.tfx-herr-oculto { position: absolute; left: -9999px; }
@media (max-width: 767px) { .tfx-herr-cajas { grid-template-columns: 1fr; margin: 20px 12px; } }
.tfx-herr-sitio-pie { background: var(--gris); color: #e1e0dc; }
.tfx-herr-sitio-pie-in { max-width: 1180px; margin: 0 auto; padding: 36px 20px 20px; display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 24px; }
.tfx-herr-sitio-pie h2 { margin: 0 0 6px; font: 700 16px/1.4 var(--quick); color: var(--verde); }
.tfx-herr-sitio-pie ul { list-style: none; margin: 0; padding: 0; }
.tfx-herr-sitio-pie li { margin: 0 0 6px; }
.tfx-herr-sitio-pie a { color: #fff; text-decoration: none; font: 16px/1.5 var(--quick); }
.tfx-herr-sitio-pie a:hover { color: var(--verde); }
.tfx-herr-redes { display: flex; gap: 10px; margin-top: 14px; }
.tfx-herr-redes a { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border: 1px solid #6b7079; }
.tfx-herr-redes svg { width: 20px; height: 20px; fill: #fff; }
.tfx-herr-copy { max-width: 1180px; margin: 0 auto; padding: 12px 20px 28px; font: 13px/1.5 var(--quick); color: #c9cbcf; }
@media (max-width: 767px) { .tfx-herr-sitio-pie-in { grid-template-columns: 1fr 1fr; } }

/* 4. BOTONES (los de la web: gris oscuro y oro, esquinas rectas) */
.tfx-herr-boton { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; margin: 0; padding: 10px 14px; border: 1px solid var(--gris); border-radius: 0; background: var(--gris); color: var(--oro); font: 600 14.5px/1.2 var(--quick); letter-spacing: .01em; text-decoration: none; cursor: pointer; transition: background .2s, color .2s; }
.tfx-herr-boton:hover { background: var(--verde); border-color: var(--verde); color: #fff; }
.tfx-herr-boton-claro { background: #fff; color: var(--tinta); }
.tfx-herr-boton-oro { background: var(--oro); border-color: var(--oro); color: var(--tinta); }
.tfx-herr-enlace { display: inline; padding: 0; margin: 0; border: 0; background: none; color: var(--verde-texto); font: inherit; text-decoration: underline; cursor: pointer; }
.tfx-herr-estado { min-height: 1.4em; margin: 6px 0 0; font-size: 14px; line-height: 1.4; color: var(--verde-texto); }
.tfx-herr-estado:empty { display: none; }

/* 5. LA CALCULADORA (widget, también en /insertar/) */
.tfx-herr-app { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; font: 16px/1.5 var(--texto); color: var(--tinta); }
.tfx-herr-app:not(.tfx-herr-app-lista) { min-height: 600px; }
@media (min-width: 860px) {
  .tfx-herr-app { grid-template-columns: minmax(300px, 370px) minmax(0, 1fr); grid-template-rows: auto auto auto 1fr; gap: 20px 28px; align-items: start; }
  .tfx-herr-app .tfx-herr-privacidad, .tfx-herr-app .tfx-herr-modos { grid-column: 1 / -1; }
  .tfx-herr-app .tfx-herr-form { grid-row: 3 / span 3; position: sticky; top: 12px; }
  .tfx-herr-app .tfx-herr-resultado, .tfx-herr-app .tfx-herr-compartir, .tfx-herr-app .tfx-herr-aviso { grid-column: 2; }
}
.tfx-herr-cargando { margin: 0; color: var(--tenue); }
.tfx-herr-privacidad { margin: 0; display: flex; align-items: center; gap: 8px; font: 500 14px/1.4 var(--quick); color: var(--tinta2); }
.tfx-herr-privacidad svg { flex: none; width: 18px; height: 18px; fill: var(--verde-texto); }
.tfx-herr-modos { display: flex; border: 1px solid var(--gris); width: max-content; max-width: 100%; }
.tfx-herr-modos label { position: relative; margin: 0; cursor: pointer; flex: 1 1 auto; }
.tfx-herr-modos input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tfx-herr-modos span { display: flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 16px; text-align: center; font: 600 15px/1.2 var(--quick); color: var(--tinta2); background: #fff; }
.tfx-herr-modos input:checked + span { background: var(--gris); color: #fff; }
.tfx-herr-modos input:focus-visible + span { outline: 2px solid var(--nominal); outline-offset: -4px; }
@media (max-width: 480px) { .tfx-herr-modos { width: 100%; } .tfx-herr-modos label { flex: 1 1 50%; } .tfx-herr-modos span { height: 100%; padding: 8px 8px; font-size: 14px; } }
.tfx-herr-form { margin: 0; min-width: 0; }
.tfx-herr-grupo { margin: 0 0 16px; padding: 0; border: 0; min-width: 0; }
.tfx-herr-leyenda { margin: 0 0 10px; padding: 0; font: 600 13px/1.3 var(--quick); letter-spacing: .08em; text-transform: uppercase; color: var(--verde-texto); }
.tfx-herr-campo { margin: 0 0 14px; min-width: 0; }
.tfx-herr-campo > label, .tfx-herr-etiqueta { display: block; margin: 0 0 6px; font: 600 15px/1.3 var(--quick); color: var(--tinta); }
.tfx-herr-fila { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 0 12px; }
@media (max-width: 359px) { .tfx-herr-fila { grid-template-columns: 1fr; } }
.tfx-herr-entrada { display: flex; align-items: stretch; height: 48px; background: #fff; border: 1px solid var(--borde); }
.tfx-herr-entrada:focus-within { border-color: var(--nominal); box-shadow: 0 0 0 2px rgba(61,122,20,.28); }
.tfx-herr-entrada:has([aria-invalid="true"]) { border-color: var(--error); }
.tfx-herr-entrada input { flex: 1 1 auto; min-width: 0; width: 100%; height: 100%; margin: 0; padding: 0 12px; border: 0; border-radius: 0; background: transparent; outline: none; font: 17px/1.2 var(--texto); color: var(--tinta); font-variant-numeric: tabular-nums; }
.tfx-herr-entrada input:disabled { background: var(--fondo); color: var(--tenue); }
.tfx-herr-unidad { display: flex; align-items: center; padding: 0 12px; background: var(--fondo); color: var(--tinta2); font-size: 15px; white-space: nowrap; border-right: 1px solid var(--claro); }
.tfx-herr-unidad-fin { border-right: 0; border-left: 1px solid var(--claro); }
.tfx-herr-app select { display: block; width: 100%; height: 48px; margin: 0; padding: 0 38px 0 12px; border: 1px solid var(--borde); border-radius: 0; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23474c55' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 14px center; -webkit-appearance: none; appearance: none; font: 16px/1.2 var(--texto); color: var(--tinta); }
.tfx-herr-app select:focus { outline: none; border-color: var(--nominal); box-shadow: 0 0 0 2px rgba(61,122,20,.28); }
.tfx-herr-app select:disabled { background-color: var(--fondo); color: var(--tenue); }
.tfx-herr-ayuda, .tfx-herr-error { margin: 6px 0 0; font-size: 13.5px; line-height: 1.4; color: var(--tenue); }
.tfx-herr-error { color: var(--error); font-weight: 600; }
.tfx-herr-opciones-rent { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 0 0 8px; }
.tfx-herr-radio { display: flex; align-items: center; gap: 8px; min-height: 32px; font-size: 15px; cursor: pointer; }
.tfx-herr-radio input, .tfx-herr-check input { width: 20px; height: 20px; margin: 0; flex: none; accent-color: var(--nominal); }
.tfx-herr-periodo { display: flex; flex-wrap: wrap; }
.tfx-herr-periodo label { position: relative; margin: 0; cursor: pointer; }
.tfx-herr-periodo input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tfx-herr-periodo span { display: block; padding: 9px 12px; border: 1px solid var(--borde); margin-right: -1px; font: 600 14px/1.2 var(--quick); color: var(--tinta2); background: #fff; }
.tfx-herr-periodo input:checked + span { background: var(--gris); border-color: var(--gris); color: #fff; }
.tfx-herr-periodo input:focus-visible + span { outline: 2px solid var(--nominal); outline-offset: 2px; }
.tfx-herr-periodo input:disabled + span { opacity: .45; cursor: not-allowed; }
.tfx-herr-mas { margin: 0 0 14px; border: 1px solid var(--claro); background: #fff; }
.tfx-herr-mas > summary { cursor: pointer; padding: 12px 14px; min-height: 44px; font: 600 15px/1.3 var(--quick); color: var(--verde-texto); }
.tfx-herr-mas[open] > summary { border-bottom: 1px solid var(--claro); }
.tfx-herr-mas-in { padding: 14px 14px 2px; }
.tfx-herr-acciones { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 4px 0 0; font-size: 15px; }

/* resultado */
.tfx-herr-resultado { min-width: 0; padding: 20px; background: var(--fondo); border-top: 4px solid var(--verde); }
.tfx-herr-vacio { padding: 26px 6px; text-align: center; }
.tfx-herr-vacio-txt { margin: 0 0 16px; font-size: 17px; color: var(--tinta2); }
.tfx-herr-res-titulo { margin: 0 0 12px; font: 600 15px/1.4 var(--quick); color: var(--tinta2); }
.tfx-herr-principal { padding: 16px 18px; background: #fff; border: 1px solid var(--claro); border-left: 5px solid var(--real); }
.tfx-herr-cifra-et { display: flex; align-items: center; gap: 8px; font: 600 14px/1.3 var(--quick); color: var(--tinta2); }
.tfx-herr-cifra-et i { display: inline-block; width: 18px; height: 4px; border-radius: 2px; background: var(--real); }
.tfx-herr-principal strong { display: block; margin: 4px 0 0; font: 300 clamp(38px, 5vw, 52px)/1.05 var(--oswald); color: var(--tinta); overflow-wrap: anywhere; }
.tfx-herr-cifra-nota { display: block; margin: 6px 0 0; font-size: 13.5px; line-height: 1.4; color: var(--tenue); }
.tfx-herr-escenarios { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 8px; margin: 10px 0 0; }
.tfx-herr-esc { padding: 10px 12px; background: #fff; border: 1px solid var(--claro); border-top: 3px solid rgba(196,138,0,.45); min-width: 0; }
.tfx-herr-esc-medio { border-top-color: var(--real); background: #fffaf0; }
.tfx-herr-esc-et { display: block; font: 600 13px/1.3 var(--quick); letter-spacing: .04em; text-transform: uppercase; color: var(--tinta2); }
.tfx-herr-esc strong { display: block; margin: 2px 0 0; font: 300 23px/1.2 var(--oswald); color: var(--tinta); overflow-wrap: anywhere; }
.tfx-herr-esc-nota { display: block; margin: 2px 0 0; font-size: 12.5px; line-height: 1.35; color: var(--tenue); }
@media (max-width: 480px) {
  .tfx-herr-escenarios { grid-template-columns: 1fr; gap: 6px; }
  .tfx-herr-esc { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 0 10px; border-top-width: 1px; border-left: 3px solid rgba(196,138,0,.45); }
  .tfx-herr-esc-medio { border-left-color: var(--real); }
  .tfx-herr-esc strong { grid-column: 2; grid-row: 1 / span 2; font-size: 22px; }
  .tfx-herr-esc-nota { grid-column: 1; }
}
.tfx-herr-supuesto, .tfx-herr-duplica { margin: 10px 0 0; font-size: 13.5px; line-height: 1.45; color: var(--tinta2); }
.tfx-herr-duplica { padding: 8px 10px; background: #fff; border: 1px solid var(--claro); font-size: 14px; }
.tfx-herr-detalle-tit { margin: 16px 0 0; font: 600 14px/1.3 var(--quick); color: var(--tinta2); }
.tfx-herr-desglose { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 0 18px; margin: 8px 0 0; padding: 0; }
@media (max-width: 420px) { .tfx-herr-desglose { grid-template-columns: 1fr; } }
.tfx-herr-desglose > div { padding: 10px 0; border-top: 1px solid var(--claro); min-width: 0; }
.tfx-herr-desglose dt { margin: 0; font-size: 14px; font-weight: 600; color: var(--tinta2); }
.tfx-herr-desglose dd { margin: 2px 0 0; font: 300 23px/1.2 var(--oswald); color: var(--tinta); overflow-wrap: anywhere; }
.tfx-herr-desglose dd.tfx-herr-sub { font: 13px/1.35 var(--texto); color: var(--tenue); }
.tfx-herr-grafico { position: relative; margin: 18px 0 0; padding: 0; }
.tfx-herr-grafico-titulo { margin: 0 0 6px; font: 600 15px/1.3 var(--quick); }
.tfx-herr-leyenda-graf { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 0 0 6px; padding: 0; list-style: none; }
.tfx-herr-leyenda-graf li { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 13px; line-height: 1.4; color: var(--tinta2); }
.tfx-herr-leyenda-graf i { display: inline-block; width: 16px; height: 3px; border-radius: 2px; }
.tfx-herr-leyenda-graf i.tfx-herr-clave-banda { height: 10px; background: rgba(196,138,0,.3); }
.tfx-herr-leyenda-graf i.tfx-herr-clave-area { height: 10px; background: rgba(154,156,161,.3); }
.tfx-herr-leyenda-graf .tfx-herr-leyenda-nota { color: var(--tenue); font-style: italic; }
.tfx-herr-lienzo { width: 100%; min-height: 240px; background: #fff; border: 1px solid var(--claro); cursor: crosshair; touch-action: pan-y; }
.tfx-herr-lienzo svg { display: block; max-width: none; height: auto; }
.tfx-herr-rejilla { stroke: #e6e7e9; stroke-width: 1; }
.tfx-herr-eje { fill: var(--tenue); font: 12px var(--texto); font-variant-numeric: tabular-nums; }
.tfx-herr-tooltip { position: absolute; z-index: 2; min-width: 170px; padding: 8px 10px; background: #fff; border: 1px solid #d9dadd; box-shadow: 0 4px 14px rgba(0,0,0,.12); pointer-events: none; }
.tfx-herr-tooltip p { display: flex; align-items: center; gap: 6px; margin: 0; font-size: 13px; line-height: 1.5; color: var(--tenue); }
.tfx-herr-tooltip .tfx-herr-tt-ano { font-weight: 600; color: var(--tinta); }
.tfx-herr-tooltip i { display: inline-block; width: 12px; height: 3px; border-radius: 2px; }
.tfx-herr-tooltip strong { color: var(--tinta); font-variant-numeric: tabular-nums; }
.tfx-herr-tabla { margin: 14px 0 0; }
.tfx-herr-tabla summary { cursor: pointer; padding: 8px 0; min-height: 44px; font: 600 15px/1.8 var(--quick); color: var(--verde-texto); }
.tfx-herr-tabla-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; background: #fff; border: 1px solid var(--claro); }
.tfx-herr-tabla table { width: 100%; margin: 0; border-collapse: collapse; font-size: 13.5px; line-height: 1.35; font-variant-numeric: tabular-nums; }
.tfx-herr-tabla th, .tfx-herr-tabla td { padding: 7px 10px; border-bottom: 1px solid #ecece9; text-align: right; white-space: nowrap; }
.tfx-herr-tabla thead th { position: sticky; top: 0; background: var(--fondo); font-weight: 600; color: var(--tinta2); }
.tfx-herr-tabla th[scope="row"], .tfx-herr-tabla thead th:first-child { position: sticky; left: 0; text-align: left; background: var(--fondo); }
/* fijar y comparar, y los «¿y si…?» */
.tfx-herr-comparar { margin: 16px 0 0; padding: 14px; background: #fff; border: 1px solid var(--claro); }
.tfx-herr-comparar-tit { margin: 0 0 8px; font: 600 15px/1.3 var(--quick); }
.tfx-herr-fijado { margin: 10px 0 0; padding: 10px 12px; background: var(--fondo); font-size: 14px; line-height: 1.5; }
.tfx-herr-fijado strong { font-variant-numeric: tabular-nums; }
.tfx-herr-ysi { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; }
.tfx-herr-ysi button { flex: 1 1 210px; text-align: left; justify-content: flex-start; }
.tfx-herr-ysi button[aria-pressed="true"] { background: var(--oro); border-color: var(--oro); color: var(--tinta); }
.tfx-herr-ysi-res { margin: 10px 0 0; padding: 0; list-style: none; }
.tfx-herr-ysi-res li { margin: 0 0 8px; padding: 10px 12px; background: var(--fondo); border-left: 3px solid var(--real); font-size: 14px; line-height: 1.5; }
.tfx-herr-ysi-res .tfx-herr-pendiente { margin-top: 6px; font-size: 13.5px; }
.tfx-herr-mas-pos { color: var(--nominal); font-weight: 600; }
.tfx-herr-menos { color: var(--error); font-weight: 600; }
.tfx-herr-compartir { margin: 0; }
.tfx-herr-compartir-tit { margin: 0 0 8px; font: 600 15px/1.3 var(--quick); }
.tfx-herr-botones { display: flex; flex-wrap: wrap; gap: 8px; }
.tfx-herr-aviso { margin: 0; font-size: 13px; line-height: 1.45; color: var(--tenue); }
/* barra fija abajo en el móvil con la cifra principal */
.tfx-herr-barra { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); background: var(--gris); color: #fff; box-shadow: 0 -4px 14px rgba(0,0,0,.2); font: 500 14px/1.3 var(--quick); }
.tfx-herr-barra strong { display: block; font: 300 22px/1.1 var(--oswald); color: #fff; }
.tfx-herr-barra .tfx-herr-boton { min-height: 40px; }
@media (min-width: 860px) { .tfx-herr-barra { display: none !important; } }

/* 6. VERSIÓN PARA INSERTAR (/insertar/) */
.tfx-herr-insertada { margin: 0; padding: 12px; background: #fff; }
.tfx-herr-h1-insertada { margin: 0 0 12px; font: 300 26px/1.2 var(--oswald); color: var(--tinta); }
.tfx-herr-marca { margin: 14px 0 0; padding-top: 10px; border-top: 1px solid var(--claro); font: 13px/1.5 var(--texto); color: var(--tenue); }

@media (max-width: 767px) {
  .tfx-herr-pag { margin-top: 0; }
  .tfx-herr-cabecera { padding: 28px 18px 30px; }
  .tfx-herr-herramienta { padding: 16px 12px; }
  .tfx-herr-cuerpo { padding: 4px 16px 32px; }
  .tfx-herr-resultado { padding: 16px 12px; }
  .tfx-herr-frase { font-size: 17px; }
  .tfx-herr-h2 { font-size: 26px; }
  .tfx-herr-respuesta, .tfx-herr-quehacer { padding: 16px; }
}

/* 7. IMPRIMIR O GUARDAR EN PDF */
@media print {
  body { background: #fff; font-size: 12pt; }
  .tfx-herr-sitio-cab, .tfx-herr-sitio-pie, .tfx-herr-copy, .tfx-herr-cajas, .tfx-herr-barra, .tfx-herr-compartir, .tfx-herr-modos,
  .tfx-herr-acciones, .tfx-herr-comparar, .tfx-herr-seccion-video, .tfx-herr-insertar, .tfx-herr-saltar, .tfx-herr-faq,
  .tfx-herr-vacio button, .tfx-herr-tooltip { display: none !important; }
  .tfx-herr-pag, .tfx-herr-cabecera { margin: 0; box-shadow: none; }
  .tfx-herr-cabecera { background: none; color: var(--tinta); padding: 0 0 12px; }
  .tfx-herr-h1, .tfx-herr-frase, .tfx-herr-autor { color: var(--tinta); }
  .tfx-herr-app { display: block; }
  .tfx-herr-resultado, .tfx-herr-grafico, .tfx-herr-tabla table { break-inside: avoid; }
  .tfx-herr-tabla-scroll { overflow: visible; }
  a { color: var(--tinta); text-decoration: none; }
}

/* 8. FUENTES PROPIAS (pendiente: copiar los .woff2 a _comun/fuentes/ y quitar el comentario; licencia SIL OFL 1.1)
@font-face { font-family: Oswald; font-style: normal; font-weight: 300; font-display: swap; src: url(/herramientas/_comun/fuentes/oswald-300.woff2) format("woff2"); }
@font-face { font-family: Quicksand; font-style: normal; font-weight: 400 600; font-display: swap; src: url(/herramientas/_comun/fuentes/quicksand.woff2) format("woff2"); }
*/
