/* =====================================================================
   Trámites en línea (ventanilla electrónica) — prefijo tr-
   Usa las variables de site.css (--navy-*, --gold, --sea, --line, --paper…)
   ===================================================================== */

/* ---------- Hero y buscador ---------- */
.tr-hero { padding: 64px 0 56px; }
.tr-kicker { display: inline-block; font: 600 .82rem var(--font-cond); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 8px; }
.tr-buscar { position: relative; max-width: 680px; margin-top: 26px; }
.tr-buscar input { width: 100%; box-sizing: border-box; font: 500 1.05rem var(--font); padding: 16px 18px 16px 52px; border-radius: 10px; border: 2px solid transparent; background: var(--white); color: var(--ink); box-shadow: 0 10px 30px rgba(0, 0, 0, .25); }
.tr-buscar input:focus { outline: none; border-color: var(--gold); }
.tr-buscar__ico { position: absolute; left: 17px; top: 50%; transform: translateY(-50%); color: var(--muted); display: flex; }
.tr-hero__acc { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }

/* ---------- Barra del ciudadano ---------- */
.tr-barra { background: var(--navy-900); color: rgba(255, 255, 255, .85); border-bottom: 1px solid rgba(255, 255, 255, .08); font-size: .93rem; }
.tr-barra__fila { display: flex; align-items: center; justify-content: space-between; gap: 10px 18px; flex-wrap: wrap; padding-top: 9px; padding-bottom: 9px; }
.tr-barra__quien { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--gold-soft); }
.tr-barra__nav { display: flex; align-items: center; gap: 6px 16px; flex-wrap: wrap; }
.tr-barra__nav a, .tr-barra__nav button { display: inline-flex; align-items: center; gap: 6px; color: var(--white); text-decoration: none; background: none; border: 0; font: inherit; cursor: pointer; padding: 4px 2px; }
.tr-barra__nav a:hover, .tr-barra__nav button:hover { color: var(--gold-soft); }
.tr-barra__nav form { margin: 0; }

/* ---------- Pasos ---------- */
.tr-pasos-sec { padding: 44px 0; }
.tr-pasos { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: p; }
.tr-pasos li { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 18px; position: relative; }
.tr-pasos li span { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--navy-700); color: var(--gold); font: 700 1.1rem var(--font-cond); margin-bottom: 10px; }
.tr-pasos strong { display: block; font: 700 1.15rem var(--font-cond); color: var(--navy-800); }
.tr-pasos p { margin: 4px 0 0; color: var(--muted); font-size: .95rem; }

/* ---------- Catálogo ---------- */
.tr-dep { margin-bottom: 40px; }
.tr-dep__tit { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; font-size: 1.15rem; color: var(--muted); font-family: var(--font); font-weight: 600; border-bottom: 2px solid var(--line); padding-bottom: 10px; margin-bottom: 18px; }
.tr-dep__tit span { font: 700 1.7rem var(--font-cond); color: var(--navy-800); letter-spacing: .02em; }
.tr-area { margin-bottom: 26px; }
.tr-area__tit { font-size: 1.2rem; color: var(--navy-700); margin-bottom: 10px; }
.tr-area__tit small { color: var(--muted); font-weight: 500; font-family: var(--font); font-size: .9rem; }
.tr-lista { display: grid; gap: 10px; }
.tr-item { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); transition: box-shadow .2s ease, border-color .2s ease; }
.tr-item[open] { border-color: var(--sea); box-shadow: var(--shadow); }
.tr-item summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 12px; padding: 15px 18px; }
.tr-item summary::-webkit-details-marker { display: none; }
.tr-item summary:hover .tr-item__nom { color: var(--sea); }
.tr-item__nom { flex: 1; font-weight: 600; color: var(--navy-800); line-height: 1.35; }
.tr-item__meta { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.tr-item__mas { width: 26px; height: 26px; flex: none; border-radius: 50%; background: var(--paper); position: relative; }
.tr-item__mas::before, .tr-item__mas::after { content: ""; position: absolute; left: 50%; top: 50%; width: 11px; height: 2px; background: var(--navy-700); transform: translate(-50%, -50%); transition: transform .2s ease; }
.tr-item__mas::after { transform: translate(-50%, -50%) rotate(90deg); }
.tr-item[open] .tr-item__mas::after { transform: translate(-50%, -50%) rotate(0); }
.tr-item__cuerpo { padding: 0 18px 18px; border-top: 1px solid var(--line); }
.tr-item__cuerpo h5 { font: 700 1rem var(--font-cond); color: var(--navy-700); margin: 16px 0 6px; letter-spacing: .03em; text-transform: uppercase; }
.tr-tag { display: inline-block; font-size: .8rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #FFF4D6; color: #6B4E00; white-space: nowrap; }
.tr-tag--gratis { background: #E3F5EC; color: #11613E; }
.tr-tag--plazo { background: #E8F1F9; color: #1D5A87; }
.tr-sinres { margin-bottom: 20px; }

.tr-datos { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px 20px; margin: 16px 0 0; }
.tr-datos div { min-width: 0; }
.tr-datos dt { display: flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.tr-datos dd { margin: 2px 0 0; color: var(--ink); overflow-wrap: anywhere; }
.tr-datos--col { grid-template-columns: 1fr; gap: 12px; }
.tr-datos--sol { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin: 0; }
.tr-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.tr-checks li { position: relative; padding-left: 26px; }
.tr-checks li::before { content: ""; position: absolute; left: 2px; top: .45em; width: 12px; height: 7px; border-left: 2px solid var(--sea); border-bottom: 2px solid var(--sea); transform: rotate(-45deg); }
.tr-checks--doc li::before { border: 2px solid var(--gold); width: 9px; height: 11px; border-radius: 2px; transform: none; top: .35em; }
.tr-hint { font-size: .92rem; color: var(--muted); margin: 12px 0; }
.tr-item .btns { margin-top: 18px; }
.tr-btn-linea { background: transparent; border-color: var(--navy-700); color: var(--navy-700); }
.tr-btn-linea:hover { background: var(--navy-700); color: var(--white); }

.tr-ayuda { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.tr-ayuda h2 { color: var(--navy-800); font-size: 1.8rem; }
.tr-ayuda > div:first-child { max-width: 640px; }

/* ---------- Tarjetas y formularios ---------- */
.tr-angosto { max-width: 760px; }
.tr-angosto--sm { max-width: 480px; }
.tr-tarjeta { background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 26px; box-shadow: 0 4px 18px rgba(6, 20, 38, .05); margin-bottom: 20px; }
.tr-h2 { font-size: 1.45rem; color: var(--navy-800); margin-bottom: 14px; }
.tr-form fieldset { border: 0; padding: 0; margin: 0 0 22px; min-width: 0; }
.tr-form legend { font: 700 1.2rem var(--font-cond); color: var(--navy-800); padding: 0; margin-bottom: 12px; width: 100%; border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.tr-campo { margin-bottom: 16px; min-width: 0; }
.tr-campo label { display: flex; align-items: center; gap: 6px; font-weight: 600; color: var(--navy-800); margin-bottom: 6px; font-size: .97rem; }
.tr-campo input:not([type=checkbox]):not([type=radio]):not([type=file]), .tr-campo select, .tr-campo textarea {
    width: 100%; box-sizing: border-box; font: 400 1rem var(--font); color: var(--ink);
    padding: 11px 13px; border: 1.5px solid #C9D3DE; border-radius: 8px; background: var(--white);
}
.tr-campo textarea { resize: vertical; min-height: 90px; }
.tr-campo input:focus, .tr-campo select:focus, .tr-campo textarea:focus { outline: none; border-color: var(--sea); box-shadow: 0 0 0 3px rgba(47, 127, 184, .18); }
.tr-campo small { display: block; margin-top: 5px; color: var(--muted); font-size: .86rem; }
.tr-campo--error input, .tr-campo--error select, .tr-campo--error textarea { border-color: #C0392B !important; }
.tr-campo .tr-campo__err { color: #B02A1C; font-weight: 600; }
.tr-req { color: #B02A1C; }
.tr-dos { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.tr-check { display: flex !important; align-items: flex-start !important; gap: 10px !important; font-weight: 400 !important; cursor: pointer; }
.tr-check input { width: 20px; height: 20px; margin: 2px 0 0; flex: none; accent-color: var(--navy-700); }
.tr-trampa { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.tr-archivo input[type=file] { width: 100%; box-sizing: border-box; padding: 12px; border: 1.5px dashed #AFC0D2; border-radius: 8px; background: var(--paper); font: inherit; font-size: .93rem; cursor: pointer; }
.tr-archivo input[type=file]:hover { border-color: var(--sea); }
.tr-archivo .tr-archivo__info { color: var(--navy-700); }
.tr-ancho { width: 100%; justify-content: center; }
.tr-form__pie { text-align: center; margin: 16px 0 0; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; font-size: .95rem; }
.tr-ol { padding-left: 22px; display: grid; gap: 8px; margin: 0 0 22px; }
.tr-mini { display: block; font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; color: var(--muted); margin-bottom: 6px; }

.tr-alerta { padding: 13px 16px; border-radius: 8px; margin-bottom: 18px; font-size: .97rem; border: 1px solid; display: flex; gap: 8px; align-items: flex-start; }
.tr-alerta--ok { background: #E7F6EE; border-color: #A9DCC0; color: #0E5A37; }
.tr-alerta--error { background: #FCECEA; border-color: #F0B8B1; color: #8E2318; }
.tr-alerta--aviso { background: #FFF8E6; border-color: var(--gold-soft); color: #5A4A1E; display: block; }

.tr-2col { display: grid; grid-template-columns: 340px 1fr; gap: 24px; align-items: start; }
.tr-2col--det { grid-template-columns: 1.1fr 1fr; }
.tr-resumen { position: sticky; top: 96px; }
.tr-resumen h3 { font-size: 1.1rem; color: var(--navy-700); margin: 18px 0 8px; }

/* ---------- Estados ---------- */
.tr-estado { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: .85rem; padding: 4px 12px; border-radius: 999px; white-space: nowrap; }
.tr-estado::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.tr-estado--recibida { background: #E8F1F9; color: #1D5A87; }
.tr-estado--revision { background: #EEEAFB; color: #4B3A9A; }
.tr-estado--correccion { background: #FFF1DB; color: #8A5300; }
.tr-estado--autorizada { background: #E3F5EC; color: #11613E; }
.tr-estado--denegada { background: #FCE7E5; color: #9A2A1E; }

.tr-resumen-estados { list-style: none; margin: 0 0 22px; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.tr-resumen-estados li { background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; font-size: .88rem; color: var(--muted); border-top: 4px solid; }
.tr-resumen-estados strong { display: block; font: 700 1.7rem var(--font-cond); color: var(--navy-800); }
.tr-resumen-estados--recibida { border-top-color: #2F7FB8 !important; }
.tr-resumen-estados--revision { border-top-color: #6B57C9 !important; }
.tr-resumen-estados--correccion { border-top-color: #E0A030 !important; }
.tr-resumen-estados--autorizada { border-top-color: #1E8E5A !important; }
.tr-resumen-estados--denegada { border-top-color: #C0392B !important; }
.tr-cab-lista { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.tr-cab-lista .tr-h2 { margin: 0; }
.tr-vacio { text-align: center; color: var(--muted); }
.tr-sols { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.tr-sol { display: flex; flex-direction: column; gap: 4px; background: var(--white); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; text-decoration: none; color: inherit; transition: transform .15s ease, box-shadow .2s ease, border-color .2s ease; }
.tr-sol:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: var(--sea); }
.tr-sol__exp { font: 700 .95rem var(--font-cond); letter-spacing: .06em; color: var(--sea); }
.tr-sol__nom { color: var(--navy-800); line-height: 1.35; }
.tr-sol__meta { font-size: .88rem; color: var(--muted); }
.tr-sol__pie { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-top: 10px; font-size: .85rem; color: var(--muted); }

.tr-estado-cab { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.tr-estado-cab .btns { margin: 0; }
.tr-progreso { list-style: none; margin: 0; padding: 0; display: flex; flex: 1; min-width: 260px; max-width: 520px; }
.tr-progreso li { flex: 1; position: relative; text-align: center; font-size: .85rem; color: var(--muted); padding-top: 26px; }
.tr-progreso li span { position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 18px; height: 18px; border-radius: 50%; background: var(--white); border: 3px solid #C9D3DE; z-index: 1; }
.tr-progreso li::before { content: ""; position: absolute; top: 8px; left: -50%; width: 100%; height: 3px; background: #C9D3DE; }
.tr-progreso li:first-child::before { display: none; }
.tr-progreso li.is-hecho { color: var(--navy-800); font-weight: 600; }
.tr-progreso li.is-hecho span { border-color: var(--sea); background: var(--sea); }
.tr-progreso li.is-hecho::before { background: var(--sea); }
.tr-progreso li.is-alerta span { border-color: #E0A030; background: #E0A030; }
.tr-progreso li.is-no span { border-color: #C0392B; background: #C0392B; }
.tr-correccion { border-left: 5px solid #E0A030; }

.tr-tiempo { list-style: none; margin: 0; padding: 0 0 0 22px; border-left: 2px solid var(--line); }
.tr-tiempo li { position: relative; padding: 0 0 22px 8px; }
.tr-tiempo li::before { content: ""; position: absolute; left: -31px; top: 3px; width: 14px; height: 14px; border-radius: 50%; background: var(--white); border: 3px solid var(--sea); }
.tr-tiempo--correccion::before { border-color: #E0A030 !important; }
.tr-tiempo--autorizada::before { border-color: #1E8E5A !important; background: #1E8E5A !important; }
.tr-tiempo--denegada::before { border-color: #C0392B !important; background: #C0392B !important; }
.tr-tiempo--revision::before { border-color: #6B57C9 !important; }
.tr-tiempo__cab { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.tr-tiempo__cab strong { color: var(--navy-800); }
.tr-tiempo time { font-size: .85rem; color: var(--muted); }
.tr-tiempo__quien { font-size: .85rem; color: var(--sea); font-weight: 600; }
.tr-tiempo p { margin: 6px 0 0; background: var(--paper); border-radius: 8px; padding: 10px 12px; font-size: .95rem; overflow-wrap: anywhere; }
.tr-docs { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.tr-docs li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.tr-docs__ico { color: var(--sea); display: flex; }
.tr-docs__txt { flex: 1; min-width: 0; }
.tr-docs__txt strong { display: block; font-size: .95rem; color: var(--navy-800); }
.tr-docs__txt small { display: block; color: var(--muted); font-size: .82rem; overflow-wrap: anywhere; }
.tr-docs a { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px; color: var(--navy-700); background: var(--paper); flex: none; }
.tr-docs a:hover { background: var(--navy-700); color: var(--white); }

/* ---------- Comprobante imprimible ---------- */
.tr-comp-body { margin: 0; background: #E9EEF4; font-family: 'Barlow', 'Segoe UI', Arial, sans-serif; color: #0E1B2C; }
.tr-comp-acc { display: flex; justify-content: center; gap: 14px; padding: 16px; flex-wrap: wrap; }
.tr-comp-acc button, .tr-comp-acc a { font: 700 .95rem inherit; font-family: inherit; padding: 10px 18px; border-radius: 8px; border: 0; background: #0B2240; color: #fff; cursor: pointer; text-decoration: none; }
.tr-comp-acc a { background: #fff; color: #0B2240; border: 2px solid #0B2240; }
.tr-comp { max-width: 800px; margin: 0 auto 40px; background: #fff; padding: 40px 44px; box-sizing: border-box; border-top: 8px solid #0B2240; box-shadow: 0 10px 30px rgba(6, 20, 38, .12); }
.tr-comp__cab { display: flex; align-items: center; gap: 16px; border-bottom: 2px solid #E0B23C; padding-bottom: 14px; }
.tr-comp__cab strong { display: block; font-size: 1.3rem; color: #07182E; }
.tr-comp__cab span { font-size: .9rem; color: #5A6878; }
.tr-comp h1 { font-size: 1.5rem; margin: 22px 0 4px; color: #07182E; }
.tr-comp__exp { font-size: 1.15rem; margin: 0 0 18px; }
.tr-comp__exp strong { letter-spacing: .05em; color: #13325C; }
.tr-comp__grid { display: grid; grid-template-columns: 1fr 180px; gap: 24px; align-items: start; }
.tr-comp table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.tr-comp th { text-align: left; width: 150px; color: #5A6878; font-weight: 600; vertical-align: top; padding: 7px 10px 7px 0; border-bottom: 1px solid #E3E8EE; }
.tr-comp td { padding: 7px 0; border-bottom: 1px solid #E3E8EE; overflow-wrap: anywhere; }
.tr-comp__qr { margin: 0; text-align: center; font-size: .78rem; color: #5A6878; }
.tr-comp__qr img { display: block; margin: 0 auto 8px; image-rendering: pixelated; }
.tr-comp__qr code { font-size: .7rem; word-break: break-all; color: #0E1B2C; }
.tr-comp__nota { margin: 24px 0 0; font-size: .85rem; color: #5A6878; border-top: 1px solid #E3E8EE; padding-top: 14px; }

/* ---------- Responsivo ---------- */
@media (max-width: 960px) {
    .tr-2col, .tr-2col--det { grid-template-columns: 1fr; }
    .tr-resumen { position: static; }
    .tr-pasos { grid-template-columns: repeat(2, 1fr); }
    .tr-resumen-estados { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 600px) {
    .tr-hero { padding: 44px 0 40px; }
    .tr-pasos { grid-template-columns: 1fr; }
    .tr-pasos li { display: grid; grid-template-columns: 38px 1fr; column-gap: 12px; padding: 14px; }
    .tr-pasos li span { grid-row: span 2; margin: 0; }
    .tr-dos { grid-template-columns: 1fr; }
    .tr-tarjeta { padding: 18px; }
    .tr-item summary { flex-wrap: wrap; padding: 14px; }
    .tr-item__nom { flex-basis: calc(100% - 40px); }
    .tr-item__meta { order: 3; justify-content: flex-start; width: 100%; }
    .tr-item__cuerpo { padding: 0 14px 14px; }
    .tr-resumen-estados { grid-template-columns: repeat(2, 1fr); }
    .tr-sols { grid-template-columns: 1fr; }
    .tr-buscar input { font-size: 1rem; padding-left: 46px; }
    .tr-comp { padding: 24px 18px; }
    .tr-comp__grid { grid-template-columns: 1fr; }
    .tr-comp th { width: 110px; }
}
@media print {
    .tr-comp-body { background: #fff; }
    .tr-comp-acc { display: none; }
    .tr-comp { box-shadow: none; margin: 0; max-width: none; padding: 0; border-top-width: 6px; }
    .tr-comp__grid { grid-template-columns: 1fr 170px; }
}
.tr-tag--consultar { background: #EEF1F5; color: #4A5868; }

/* ---------- v2: contadores, filtros, ficha y comentarios ---------- */
.tr-contadores { list-style: none; margin: 30px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; max-width: 900px; }
.tr-contadores li { background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14); border-radius: 10px; padding: 12px 14px; display: grid; grid-template-columns: auto 1fr; column-gap: 10px; align-items: baseline; }
.tr-contadores strong { font: 700 2rem var(--font-cond); color: var(--gold); grid-row: span 2; line-height: 1; }
.tr-contadores span { font: 700 1.05rem var(--font-cond); color: var(--white); letter-spacing: .04em; }
.tr-contadores small { color: rgba(255, 255, 255, .65); font-size: .78rem; line-height: 1.3; }
.tr-filtros { display: grid; grid-template-columns: 1fr; gap: 12px; margin: 0 0 14px; }
.tr-filtros .tr-buscar { margin: 0; max-width: none; }
.tr-filtros .tr-buscar input { box-shadow: none; border: 1.5px solid #C9D3DE; }
.tr-filtros .tr-buscar input:focus { border-color: var(--sea); }
.tr-filtros__area { margin: 0; max-width: 460px; }
.tr-filtros__area select { width: 100%; font: 500 .97rem var(--font); padding: 10px 12px; border-radius: 8px; border: 1.5px solid #C9D3DE; background: var(--white); color: var(--ink); }
.tr-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tr-chips button { font: 600 .92rem var(--font); padding: 8px 14px; border-radius: 999px; border: 1.5px solid #C9D3DE; background: var(--white); color: var(--navy-700); cursor: pointer; display: inline-flex; align-items: center; gap: 8px; }
.tr-chips button b { background: var(--paper); border-radius: 999px; padding: 0 8px; font-size: .8rem; }
.tr-chips button:hover { border-color: var(--sea); }
.tr-chips button.is-on { background: var(--navy-700); border-color: var(--navy-700); color: var(--white); }
.tr-chips button.is-on b { background: rgba(255, 255, 255, .18); }
.tr-conteo { color: var(--muted); font-size: .92rem; min-height: 1.2em; margin: 0 0 12px; }
.tr-tag--nota { background: #FFF1C9; color: #7A5500; }

.tr-ficha__acc { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.tr-estrellas { color: #D79B00; letter-spacing: 2px; }
.tr-coms { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.tr-com { border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; }
.tr-com__cab { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.tr-com__cab strong { color: var(--navy-800); }
.tr-com__cab small { color: var(--muted); }
.tr-com p { margin: 8px 0 0; overflow-wrap: anywhere; }
.tr-com__resp { margin-top: 10px; background: var(--paper); border-left: 3px solid var(--sea); border-radius: 0 8px 8px 0; padding: 10px 12px; font-size: .95rem; }
.tr-com__resp b { display: block; font-size: .8rem; color: var(--sea); text-transform: uppercase; letter-spacing: .05em; }
.tr-escala { display: grid; gap: 6px; }
.tr-escala label { font-weight: 400 !important; }
.tr-promedio { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.tr-promedio strong { font: 700 2.4rem var(--font-cond); color: var(--navy-800); line-height: 1; }
@media (max-width: 760px) {
    .tr-contadores { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tr-contadores small { display: none; }
}

/* ---------- v3: flujo de estados, motivo de corrección/denegación ---------- */
.tr-estado--proceso { background: #E2F4F6; color: #0E6470; }
.tr-estado--finalizada { background: #E6EBF1; color: #23364D; }
.tr-tiempo--proceso::before { border-color: #1B8A99 !important; }
.tr-tiempo--finalizada::before { border-color: #23364D !important; background: #23364D !important; }
.tr-resumen-estados { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)) !important; }
.tr-resumen-estados--proceso { border-top-color: #1B8A99 !important; }
.tr-resumen-estados--finalizada { border-top-color: #23364D !important; }
.tr-progreso { max-width: 680px; }
.tr-progreso li.is-actual { color: var(--navy-800); font-weight: 700; }
.tr-progreso li.is-actual span { box-shadow: 0 0 0 5px rgba(47, 127, 184, .18); }
.tr-progreso li.is-alerta.is-actual span { box-shadow: 0 0 0 5px rgba(224, 160, 48, .22); }
.tr-progreso li.is-no.is-actual span { box-shadow: 0 0 0 5px rgba(192, 57, 43, .18); }
.tr-estado-desc { margin: -6px 0 18px; color: var(--muted); font-size: .95rem; }

.tr-motivo { border: 2px solid #E0A030; background: #FFF9EE; }
.tr-motivo--no { border-color: #C0392B; background: #FFF5F4; }
.tr-motivo .tr-h2 { color: #8A5300; }
.tr-motivo--no .tr-h2 { color: #9A2A1E; }
.tr-motivo h3 { font: 700 1.05rem var(--font-cond); color: var(--navy-800); margin: 16px 0 6px; }
.tr-motivo__fecha { margin: 0; font-size: .85rem; color: var(--muted); }
.tr-motivo__txt { margin: 0; background: var(--white); border-radius: 8px; padding: 12px 14px; border: 1px solid var(--line); overflow-wrap: anywhere; }
.tr-motivo__que { margin: 16px 0 0; padding: 12px 14px; border-radius: 8px; background: var(--white); border-left: 4px solid var(--sea); }
.tr-fallas { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.tr-fallas li { position: relative; padding: 10px 12px 10px 38px; border-radius: 8px; background: var(--white); border: 1px solid #F1C9C4; }
.tr-fallas li::before { content: "✕"; position: absolute; left: 12px; top: 9px; width: 18px; height: 18px; border-radius: 50%; background: #C0392B; color: #fff; font-size: .7rem; font-weight: 700; display: grid; place-items: center; }
.tr-fallas strong { display: block; color: var(--navy-800); }
.tr-fallas span { display: block; font-size: .92rem; color: #7A2A20; margin-top: 2px; }
.tr-fallas--mini { margin-top: 8px; }
.tr-fallas--mini li { padding: 6px 10px 6px 32px; font-size: .9rem; }
.tr-fallas--mini li::before { left: 9px; top: 7px; width: 15px; height: 15px; font-size: .6rem; }

/* ¿Cómo se hace un trámite? */
.tr-como { margin-top: 26px; }
.tr-como__tit { font: 700 1.25rem var(--font-cond); color: var(--navy-800); margin: 0 0 4px; }
.tr-como__sub { margin: 0 0 14px; color: var(--muted); font-size: .95rem; }
.tr-flujo { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.tr-flujo li { background: var(--white); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; border-top: 4px solid #2F7FB8; position: relative; }
.tr-flujo li strong { display: block; color: var(--navy-800); font-size: .95rem; }
.tr-flujo li p { margin: 4px 0 0; color: var(--muted); font-size: .86rem; line-height: 1.45; }
.tr-flujo li:not(:last-child)::after { content: "›"; position: absolute; right: -10px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 1.3rem; z-index: 1; }
.tr-flujo .is-revision { border-top-color: #6B57C9; }
.tr-flujo .is-proceso { border-top-color: #1B8A99; }
.tr-flujo .is-autorizada { border-top-color: #1E8E5A; }
.tr-flujo .is-finalizada { border-top-color: #23364D; }
.tr-ramas { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.tr-ramas div { border-radius: 10px; padding: 10px 14px; font-size: .9rem; border: 1px solid var(--line); background: var(--white); }
.tr-ramas .is-correccion { border-left: 4px solid #E0A030; }
.tr-ramas .is-denegada { border-left: 4px solid #C0392B; }
.tr-ramas strong { color: var(--navy-800); }
@media (max-width: 960px) {
    .tr-flujo { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .tr-flujo li::after { display: none; }
}
@media (max-width: 600px) {
    .tr-flujo, .tr-ramas { grid-template-columns: 1fr; }
    .tr-progreso li { font-size: .72rem; }
}
.tr-tiempo .tr-fallas li::before { left: 9px; top: 8px; width: 15px; height: 15px; border: 0 !important; background: #C0392B !important; }
.tr-tiempo .tr-fallas li { padding: 6px 10px 6px 32px; }
