#reportes-plantillas-root,
#reportes-gestor-root {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex: 1;
    min-height: 0;
}

.reportes-gestor-shell {
    --reportes-gestor-shell-gutter: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex: 1;
    min-height: 0;
    padding: 0 var(--reportes-gestor-shell-gutter) 1.5rem;
}

.reportes-gestor-shell > .tab-wrapper {
    margin-inline: calc(var(--reportes-gestor-shell-gutter) * -1);
}

.reportes-gestor-subtabs-shell {
    padding-left: 0;
    border-radius: 1.1rem 1.1rem 0 0;
    overflow: hidden;
}

.reportes-gestor-subtabs-row {
    padding-inline: 1.25rem;
}

.reportes-gestor-subtabs-row .tab {
    min-width: 7rem;
}

.reportes-gestor-hero {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
    padding: 1.4rem 1.5rem;
    border: 1px solid #d9e4ef;
    border-radius: 1.4rem;
    background:
        linear-gradient(135deg, rgba(0, 128, 128, 0.08), rgba(255, 212, 51, 0.12)),
        #fff;
}

.reportes-gestor-eyebrow {
    margin: 0 0 0.35rem;
    font: 600 0.8rem/1.2 "Poppins", sans-serif;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #008080;
}

.reportes-gestor-title {
    margin: 0;
    font: 700 clamp(1.5rem, 1.6vw, 1.9rem)/1.15 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-copy,
.reportes-gestor-copy-small,
.reportes-gestor-caption,
.reportes-gestor-summary-meta,
.reportes-gestor-table td,
.reportes-gestor-table th {
    font-family: "Poppins", sans-serif;
    color: #5f6f86;
}

.reportes-gestor-copy {
    margin: 0.65rem 0 0;
    max-width: 54rem;
    font-size: 0.98rem;
    line-height: 1.6;
}

.reportes-gestor-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    justify-content: flex-end;
}

.reportes-gestor-badge,
.reportes-gestor-inline-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.48rem 0.9rem;
    border-radius: 999px;
    font: 600 0.85rem/1 "Poppins", sans-serif;
}

.reportes-gestor-badge.is-ok,
.reportes-gestor-inline-status.is-ok {
    background: #e4f6eb;
    color: #1c7e43;
    border: 1px solid #98d9af;
}

.reportes-gestor-badge.is-neutral,
.reportes-gestor-inline-status.is-neutral {
    background: #eaf3ff;
    color: #2a609a;
    border: 1px solid #bad5f4;
}

.reportes-gestor-badge.is-muted,
.reportes-gestor-inline-status.is-muted {
    background: #eef2f6;
    color: #6c7787;
    border: 1px solid #d6dee8;
}

.reportes-gestor-inline-status.is-warn {
    background: #fff0db;
    color: #a45a00;
    border: 1px solid #f4cb8b;
}

.reportes-gestor-summary,
.reportes-gestor-grid {
    display: grid;
    gap: 1rem;
}

.reportes-gestor-summary {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.reportes-gestor-grid {
    grid-template-columns: minmax(0, 2fr) minmax(19rem, 1fr);
}

.reportes-gestor-summary-card,
.reportes-gestor-panel-card {
    background: #fff;
    border: 1px solid #d9e4ef;
    border-radius: 1.2rem;
}

.reportes-gestor-bulk-card {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(31rem, 1.25fr);
    align-items: center;
    gap: 1rem;
    padding: 0.95rem 1.25rem;
    border: 1px solid #cfddea;
    border-radius: 1.35rem;
    background:
        linear-gradient(135deg, rgba(0, 128, 128, 0.09), rgba(255, 201, 7, 0.16) 58%, rgba(255, 255, 255, 0.98)),
        #fff;
    box-shadow: 0 14px 34px rgba(33, 49, 77, 0.08);
    overflow: hidden;
}

.reportes-gestor-bulk-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 7px;
    background: linear-gradient(180deg, #008080 0%, #ffc907 100%);
}

.reportes-gestor-bulk-card.is-active {
    border-color: #efbe3f;
    box-shadow: 0 18px 38px rgba(255, 201, 7, 0.2);
}

.reportes-gestor-summary-card,
.reportes-gestor-panel-card {
    padding: 1.25rem 1.35rem;
}

.reportes-gestor-bulk-title {
    margin: 0;
    font: 700 clamp(1.35rem, 1.45vw, 1.75rem)/1.1 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-bulk-copy {
    min-width: 0;
}

.reportes-gestor-bulk-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 0.65rem;
}

.reportes-gestor-bulk-actions {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.65rem 0.85rem;
    border: 1px solid rgba(123, 151, 187, 0.38);
    border-radius: 1.15rem;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.reportes-gestor-bulk-card.is-active .reportes-gestor-bulk-actions {
    border-color: rgba(239, 190, 63, 0.85);
    background: rgba(255, 252, 243, 0.92);
}

.reportes-gestor-bulk-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem;
}

.reportes-gestor-bulk-switch-copy {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.reportes-gestor-bulk-switch-title {
    font: 700 1rem/1.2 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-bulk-actions .reportes-gestor-caption {
    white-space: nowrap;
    font-size: 0.9rem;
    line-height: 1.4;
}

.reportes-gestor-bulk-toggle .presupuesto-print-option-switch {
    gap: 12px;
}

.reportes-gestor-bulk-toggle .reportes-gestor-print-option-state {
    min-width: 34px;
    height: 14px;
    font-size: 13px;
}

.reportes-gestor-bulk-toggle .presupuesto-print-option-track {
    width: 48px;
    height: 26px;
}

.reportes-gestor-bulk-toggle .presupuesto-print-option-knob {
    top: 2px;
    left: 2px;
    width: 22px;
    height: 22px;
}

.reportes-gestor-bulk-toggle input:checked + .presupuesto-print-option-switch .presupuesto-print-option-track {
    background: #78bfbe;
}

.reportes-gestor-bulk-toggle input:checked + .presupuesto-print-option-switch .presupuesto-print-option-knob {
    transform: translateX(22px);
    background: #008080;
}

.reportes-gestor-summary-label {
    display: block;
    margin-bottom: 0.35rem;
    font: 600 0.78rem/1.3 "Poppins", sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #008080;
}

.reportes-gestor-summary-value {
    display: block;
    margin-bottom: 0.3rem;
    font: 700 1.05rem/1.3 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-card-header {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    align-items: center;
}

.reportes-gestor-card-header h3 {
    margin: 0;
    font-family: "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-request-scroll-shell {
    margin-top: 1.15rem;
    max-height: min(52vh, 32rem);
    overflow-y: auto;
    padding-right: 0.35rem;
    padding-bottom: 0.35rem;
}

.reportes-gestor-panel-card-queue {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 0;
}

.reportes-gestor-panel-card-queue .reportes-gestor-request-scroll-shell {
    flex: 1;
    min-height: 0;
    max-height: none;
}

.reportes-gestor-request-sections {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.reportes-gestor-request-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.reportes-gestor-request-section-header {
    padding: 0.85rem 1rem;
    border: 1px solid #d7e3ee;
    border-radius: 1rem;
    background: linear-gradient(180deg, #f8fbff 0%, #eef5fd 100%);
    font: 700 0.95rem/1.2 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-request-groups {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.reportes-gestor-request-group {
    display: grid;
    grid-template-columns: 5.5rem minmax(0, 1fr);
    gap: 0.75rem;
    align-items: stretch;
}

.reportes-gestor-request-code {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
    padding: 0.85rem 0.65rem;
    border: 1px solid #efbe3f;
    border-radius: 1.15rem;
    background: linear-gradient(180deg, #ffe39a 0%, #ffd66c 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.reportes-gestor-request-code span {
    font: 700 0.95rem/1 "Poppins", sans-serif;
    color: #0f1a2d;
}

.reportes-gestor-request-items {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.reportes-gestor-request-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.9rem;
    padding: 0.8rem 0.9rem;
    border: 1px solid #84b7ff;
    border-radius: 1.05rem;
    background: linear-gradient(180deg, #d9e7f8 0%, #cadcf2 100%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.45),
        0 1px 2px rgba(28, 54, 93, 0.05);
}

.reportes-gestor-request-item-body {
    display: flex;
    min-width: 0;
}

.reportes-gestor-request-name {
    display: block;
    font: 500 0.92rem/1.35 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-request-item-meta {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 0;
}

.reportes-gestor-request-format {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 3.75rem;
    padding: 0.4rem 0.7rem;
    border: 1px solid #a9bfdc;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.65);
    font: 700 0.74rem/1 "Poppins", sans-serif;
    letter-spacing: 0.04em;
    color: #47627f;
}

.reportes-gestor-print-cell {
    text-align: center;
}

.reportes-gestor-print-toggle {
    display: inline-flex;
    align-items: center;
    position: relative;
}

.reportes-gestor-print-toggle input {
    position: absolute;
    opacity: 0;
    inset: 0;
    cursor: pointer;
}

.reportes-gestor-print-toggle .presupuesto-print-option-switch {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.reportes-gestor-print-option-state {
    position: relative;
    min-width: 30px;
    height: 12px;
    font: 700 12px/1 "Poppins", sans-serif;
    letter-spacing: 0.03em;
    text-align: right;
}

.reportes-gestor-print-option-state-off,
.reportes-gestor-print-option-state-on {
    position: absolute;
    top: 0;
    right: 0;
    transition: opacity 0.18s ease, color 0.18s ease;
}

.reportes-gestor-print-option-state-off {
    color: #6b7280;
    opacity: 1;
}

.reportes-gestor-print-option-state-on {
    color: #0c7c99;
    opacity: 0;
}

.reportes-gestor-print-toggle .presupuesto-print-option-track {
    position: relative;
    width: 38px;
    height: 20px;
    border-radius: 999px;
    background: #c8ccd1;
    transition: background 0.18s ease;
}

.reportes-gestor-print-toggle .presupuesto-print-option-knob {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    transition: transform 0.18s ease, background 0.18s ease;
}

.reportes-gestor-print-toggle input:checked + .presupuesto-print-option-switch .reportes-gestor-print-option-state-off {
    opacity: 0;
}

.reportes-gestor-print-toggle input:checked + .presupuesto-print-option-switch .reportes-gestor-print-option-state-on {
    opacity: 1;
}

.reportes-gestor-print-toggle input:checked + .presupuesto-print-option-switch .presupuesto-print-option-track {
    background: #9eb6f5;
}

.reportes-gestor-print-toggle input:checked + .presupuesto-print-option-switch .presupuesto-print-option-knob {
    transform: translateX(18px);
    background: #2f67d8;
}

.reportes-gestor-print-toggle input:disabled {
    cursor: not-allowed;
}

.reportes-gestor-print-toggle input:disabled + .presupuesto-print-option-switch {
    opacity: 0.6;
}

.reportes-gestor-print-toggle input:focus-visible + .presupuesto-print-option-switch {
    outline: 2px solid #74a7db;
    outline-offset: 2px;
}

.reportes-gestor-card-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1.25rem;
    padding: 0.95rem 1rem 1.1rem;
    min-height: 4.9rem;
    border: 1px solid #cfdbe8;
    border-radius: 1rem;
    background: linear-gradient(180deg, #f9fbfe 0%, #edf3f9 100%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.92),
        0 4px 10px rgba(33, 49, 77, 0.06);
}

.reportes-gestor-card-actions-end {
    justify-content: flex-end;
}

.reportes-gestor-generate-btn {
    min-height: 42px;
    min-width: 148px;
    padding: 0 20px;
    border-radius: 999px;
    font-family: "Verdana", sans-serif;
    font-size: 15px;
    font-weight: 700;
    border: 0;
    background: #ffc907;
    color: #111111;
    box-shadow: 0 10px 22px rgba(255, 201, 7, 0.3);
}

.reportes-gestor-bulk-actions .reportes-gestor-generate-btn {
    align-self: flex-end;
    width: fit-content;
    min-width: 148px;
}

.reportes-gestor-generate-btn:hover:not(:disabled) {
    background: rgb(244, 208, 63);
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.2), 0 3px 8px 0 rgba(0, 0, 0, 0.15);
}

.reportes-gestor-generate-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}

.reportes-gestor-clear-btn {
    min-height: 36px;
    min-width: 180px;
    padding: 0 22px;
    white-space: nowrap;
}

.reportes-gestor-save-modal {
    width: min(620px, calc(100vw - 32px));
}

.reportes-gestor-save-modal-body {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    align-items: center;
    text-align: center;
}

.reportes-gestor-save-modal-label {
    font: 700 0.94rem/1.2 "Poppins", sans-serif;
    color: #21314d;
}

.reportes-gestor-save-folder-row {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.8rem;
    width: 100%;
}

.reportes-gestor-save-folder-picker {
    min-width: 196px;
}

.reportes-gestor-save-folder-name {
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    max-width: min(320px, 100%);
    padding: 0 1rem;
    border: 1px solid #cfdbe8;
    border-radius: 999px;
    background: #ffffff;
    font: 500 0.94rem/1.3 "Poppins", sans-serif;
    color: #5e7087;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reportes-gestor-save-modal-help {
    margin: 0;
    font: 500 0.88rem/1.45 "Poppins", sans-serif;
    color: #6a7b92;
}

.reportes-gestor-save-modal-browser-note {
    margin: 0;
    padding: 0.8rem 0.95rem;
    border: 1px solid #c9d7eb;
    border-radius: 0.95rem;
    background: #f4f8ff;
    font: 600 0.88rem/1.45 "Poppins", sans-serif;
    color: #466389;
}

.reportes-gestor-save-progress {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
    max-width: 420px;
}

.reportes-gestor-save-progress-bar {
    position: relative;
    width: 100%;
    height: 14px;
    border-radius: 999px;
    overflow: hidden;
    background: #e7eef8;
    border: 1px solid #cbd8e8;
}

.reportes-gestor-save-progress-fill {
    display: block;
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #11a2e8 0%, #0b73c4 100%);
    transition: width 0.25s ease;
}

.reportes-gestor-save-progress-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    font: 600 0.88rem/1.35 "Poppins", sans-serif;
    color: #49607f;
}

.reportes-gestor-save-modal-status {
    margin: 0;
    padding: 0.8rem 0.95rem;
    border: 1px solid #d8e3ee;
    border-radius: 0.95rem;
    background: #f8fbff;
    font: 600 0.9rem/1.45 "Poppins", sans-serif;
    color: #405066;
}

.reportes-gestor-save-modal-status[data-state="success"] {
    border-color: #a4dfba;
    background: #eaf8ef;
    color: #1f7e46;
}

.reportes-gestor-save-modal-status[data-state="error"] {
    border-color: #f0c0c0;
    background: #fff4f4;
    color: #9d3b3b;
}

.reportes-gestor-card-actions .btn {
    min-width: 8.5rem;
    padding: 0.72rem 1rem;
    border-radius: 0.95rem;
    border: 1px solid transparent;
    font: 600 0.92rem/1 "Poppins", sans-serif;
    cursor: not-allowed;
}

.reportes-gestor-card-actions .btn-primary {
    background: #008080;
    color: #fff;
    border-color: #008080;
}

.reportes-gestor-card-actions .btn-secondary {
    background: #fff;
    color: #21314d;
    border-color: #c8d5e3;
}

.reportes-gestor-card-actions .btn:disabled {
    opacity: 0.55;
}

@media (max-width: 1100px) {
    .reportes-gestor-summary,
    .reportes-gestor-grid,
    .reportes-gestor-bulk-card {
        grid-template-columns: 1fr;
    }

    .reportes-gestor-hero {
        flex-direction: column;
    }

    .reportes-gestor-badges {
        justify-content: flex-start;
    }
}

@media (max-width: 720px) {
    .reportes-gestor-shell,
    .reportes-gestor-subtabs-row {
        padding-inline: 1rem;
    }

    .reportes-gestor-shell {
        --reportes-gestor-shell-gutter: 1rem;
    }

    .reportes-gestor-hero,
    .reportes-gestor-bulk-card,
    .reportes-gestor-summary-card,
    .reportes-gestor-panel-card {
        padding: 1rem;
    }

    .reportes-gestor-card-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .reportes-gestor-request-group {
        grid-template-columns: 1fr;
    }

    .reportes-gestor-request-code {
        min-height: 4rem;
    }

    .reportes-gestor-request-item {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .reportes-gestor-request-item-meta {
        flex-wrap: wrap;
        justify-content: space-between;
    }

    .reportes-gestor-bulk-switch-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .reportes-gestor-bulk-actions .reportes-gestor-generate-btn {
        width: 100%;
    }

    .reportes-gestor-card-actions {
        flex-direction: column;
    }

    .reportes-gestor-save-folder-row {
        flex-direction: column;
    }

    .reportes-gestor-save-folder-picker,
    .reportes-gestor-save-folder-name {
        width: 100%;
        max-width: none;
        justify-content: center;
    }
}

/* Reportes formatos tab */
.reportes-titulos-shell {
    width: min(100%, 98rem);
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    gap: 0.7rem;
    margin-inline: auto;
}

.reportes-titulos-entity-bar {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 1.1rem;
    padding: 1.05rem 1.2rem;
    border: 1px solid #cbd5e1;
    border-radius: 1.15rem;
    background: linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.reportes-titulos-entity-heading {
    font-family: "Poppins", sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #0f172a;
}

.reportes-titulos-entity-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.85rem;
}

.reportes-titulos-entity-button {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-height: 4.25rem;
    padding: 0.9rem 1rem;
    border: 1px solid #bfd2ea;
    border-radius: 1rem;
    background: #ffffff;
    color: #1e293b;
    text-align: left;
    cursor: pointer;
    transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

.reportes-titulos-entity-button:hover {
    border-color: #89acd6;
    box-shadow: 0 10px 22px rgba(37, 99, 235, 0.12);
    transform: translateY(-1px);
}

.reportes-titulos-entity-button.is-active {
    border-color: #0f8b8d;
    background: linear-gradient(135deg, #e9fbf9 0%, #d8f5f1 100%);
    box-shadow: 0 12px 24px rgba(15, 139, 141, 0.18);
}

.reportes-titulos-entity-button-top {
    width: 100%;
    display: grid;
    grid-template-columns: 4rem minmax(0, 1fr);
    align-items: center;
    gap: 0.8rem;
}

.reportes-titulos-entity-logo-wrap {
    width: 4rem;
    height: 4rem;
    display: grid;
    place-items: center;
    border-radius: 1rem;
    background: linear-gradient(180deg, #f8fbff 0%, #eef6ff 100%);
    border: 1px solid #d2deed;
    overflow: hidden;
}

.reportes-titulos-entity-logo {
    display: block;
    max-width: 85%;
    max-height: 85%;
    object-fit: contain;
}

.reportes-titulos-entity-logo-conagua {
    max-height: 92%;
}

.reportes-titulos-entity-logo-siop {
    max-width: 92%;
}

.reportes-titulos-entity-logo-fallback {
    width: 2.4rem;
    height: 2.4rem;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: linear-gradient(135deg, #0f8b8d 0%, #0ea5a7 100%);
    color: #ffffff;
    font-family: "Poppins", sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
}

.reportes-titulos-entity-button-copy {
    min-width: 0;
    display: grid;
    gap: 0.18rem;
}

.reportes-titulos-entity-button-name {
    font-family: "Poppins", sans-serif;
    font-size: 1rem;
    font-weight: 700;
}

.reportes-titulos-entity-button-meta {
    font-family: Verdana, sans-serif;
    font-size: 0.78rem;
    color: #64748b;
}

.reportes-titulos-status {
    display: grid;
    gap: 0.65rem;
}

.reportes-titulos-status .textContent {
    margin: 0;
    padding: 0.8rem 0.95rem;
    border: 1px solid #d8e0ea;
    border-radius: 0.9rem;
    background: rgba(255, 255, 255, 0.9);
}

.reportes-titulos-panels {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
    width: 100%;
}

.reportes-titulos-entity-panel {
    min-width: 0;
    min-height: 0;
}

.reportes-titulos-entity-panel.is-active {
    display: flex;
    flex-direction: column;
}

.reportes-titulos-entity-panel[hidden] {
    display: none !important;
}

.reportes-titulos-placeholder {
    padding: 1.25rem;
    border: 1px solid #cbd5e1;
    border-radius: 1.15rem;
    background: linear-gradient(180deg, #fbfdff 0%, #ffffff 100%);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
}

.reportes-titulos-placeholder-header {
    display: grid;
    gap: 0.35rem;
    margin-bottom: 1rem;
}

.reportes-titulos-placeholder-badge {
    width: fit-content;
    padding: 0.3rem 0.65rem;
    border-radius: 999px;
    background: #e0f2fe;
    color: #075985;
    font-family: "Poppins", sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
}

.reportes-titulos-placeholder-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}

.reportes-titulos-placeholder-card {
    display: grid;
    gap: 0.45rem;
    min-height: 10rem;
    padding: 1rem;
    border: 1px dashed #b8c6d9;
    border-radius: 1rem;
    background: #f8fbff;
    align-content: start;
}

.reportes-titulos-placeholder-card-tag {
    width: fit-content;
    padding: 0.36rem 0.7rem;
    border-radius: 999px;
    background: #eef5ff;
    color: #285ea6;
    font-family: "Poppins", sans-serif;
    font-size: 0.82rem;
    font-weight: 600;
}

.reportes-titulos-grid {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
}

.reportes-titulos-grid-header,
.reportes-titulos-row {
    display: grid;
    grid-template-columns: 5.5rem minmax(0, 1fr) minmax(0, 1fr) 11rem 6.5rem;
    gap: 0.9rem;
    align-items: start;
}

.reportes-titulos-grid-header {
    margin-top: 0.35rem;
}

.reportes-titulos-grid-title {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 2.7rem;
    padding: 0.65rem 0.9rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.85rem;
    background: #f8fafc;
    color: #0f172a;
    font-family: Verdana, sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    text-align: center;
}

.reportes-titulos-grid-title-selector {
    line-height: 1.2;
}

.reportes-titulos-grid-title-disposition {
    min-width: 0;
}

.reportes-titulos-grid-spacer {
    min-height: 1px;
}

.reportes-titulos-row {
    padding: 0.3rem 0;
}

.reportes-titulos-row-split {
    grid-auto-rows: minmax(0, auto);
    align-items: stretch;
}

.reportes-titulos-code {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
    padding: 0.95rem 0.75rem;
    border: 1px solid #f0c84b;
    border-radius: 0.9rem;
    background: linear-gradient(180deg, #ffe08a 0%, #ffd55c 100%);
    color: #111827;
    font-family: Verdana, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    text-align: center;
}

.reportes-titulos-code-grouped {
    grid-row: span var(--reportes-titulos-span);
    align-self: stretch;
}

.reportes-titulos-column {
    min-width: 0;
}

.reportes-titulos-column-selectable {
    padding: 0.28rem;
    border: 1px solid transparent;
    border-radius: 1rem;
    transition: background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.reportes-titulos-column-selectable.reportes-titulos-column-active {
    background: #dbeafe;
    border-color: #93c5fd;
    box-shadow: 0 10px 24px rgba(59, 130, 246, 0.12);
}

.reportes-titulos-textarea {
    width: 100%;
    min-height: 100%;
    resize: vertical;
    line-height: 1.45;
}

.reportes-titulos-textarea-readonly {
    background: #f8fafc;
    color: #0f172a;
}

.reportes-titulos-column-selectable .reportes-titulos-textarea {
    margin: 0;
}

.reportes-titulos-textarea-system.reportes-titulos-textarea-active,
.reportes-titulos-textarea-proposed.reportes-titulos-textarea-active {
    background: #dbeafe;
    border-color: #93c5fd;
    color: #0f172a;
}

.reportes-titulos-column-selectable.reportes-titulos-column-active .reportes-titulos-textarea[readonly] {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
}

.reportes-titulos-textarea-proposed[readonly] {
    cursor: default;
}

.reportes-titulos-textarea-proposed:not([readonly]) {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
    background: #fff;
}

.reportes-titulos-selector-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
}

.reportes-titulos-disposition-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100%;
}

.reportes-titulos-disposition-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.7rem;
    min-height: 2.7rem;
    padding: 0.4rem 0.75rem;
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    background: #f8fafc;
    color: #0f172a;
    font-family: Verdana, sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.reportes-titulos-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.reportes-titulos-switch-disposition .reportes-titulos-switch-ui {
    width: 4.35rem;
}

.reportes-titulos-switch-input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.reportes-titulos-switch-ui {
    position: relative;
    display: inline-grid;
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
    width: 5.5rem;
    padding: 0.22rem;
    border-radius: 999px;
    background: #dbe4f4;
    box-shadow: inset 0 0 0 1px #c7d2e5;
}

.reportes-titulos-switch-option {
    position: relative;
    z-index: 1;
    font-family: Verdana, sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    text-align: center;
    color: #4b5563;
    transition: color 0.18s ease;
}

.reportes-titulos-switch-input + .reportes-titulos-switch-ui .reportes-titulos-switch-option {
    color: #4b5563;
}

.reportes-titulos-switch-knob {
    position: absolute;
    top: 0.22rem;
    left: 0.22rem;
    width: calc(50% - 0.22rem);
    height: calc(100% - 0.44rem);
    border-radius: 999px;
    background: #2563eb;
    box-shadow: 0 8px 16px rgba(37, 99, 235, 0.28);
    transition: transform 0.18s ease;
}

.reportes-titulos-switch-input:checked + .reportes-titulos-switch-ui .reportes-titulos-switch-knob {
    transform: translateX(100%);
}

.reportes-titulos-switch-input:not(:checked) + .reportes-titulos-switch-ui .reportes-titulos-switch-option:first-child,
.reportes-titulos-switch-input:checked + .reportes-titulos-switch-ui .reportes-titulos-switch-option:nth-child(2) {
    color: #fff;
}

.reportes-titulos-switch-input:focus-visible + .reportes-titulos-switch-ui {
    outline: 3px solid rgba(37, 99, 235, 0.18);
    outline-offset: 2px;
}

.reportes-titulos-layout {
    justify-content: flex-start;
    align-items: stretch;
    gap: 1.1rem;
    width: min(100%, 98rem);
    min-height: 0;
    padding-top: 0.35rem;
    padding-bottom: 0.6rem;
    margin-inline: auto;
}

.reportes-titulos-sidebar {
    flex: 0 0 14rem;
    justify-content: flex-start;
    gap: 0.7rem;
    padding: 1rem;
    border: 1px solid #aebdd1;
    border-radius: 1rem;
    background: linear-gradient(180deg, #fbfdff 0%, #ffffff 100%);
    box-shadow: 0 0.9rem 1.6rem rgba(27, 58, 102, 0.12);
}

.reportes-titulos-layout .parametros-content {
    min-height: 0;
}

.reportes-titulos-layout .parametros-content .formularioEdit {
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-gutter: stable;
}

.reportes-titulos-layout .reportes-titulos-sidebar .parametros-button {
    min-height: 2.45rem;
    padding: 0.65rem 0.8rem;
    border: 1px solid #a9c7f6 !important;
    border-radius: 0.72rem;
    background: #edf5ff !important;
    color: #2e63a2 !important;
    font-family: "Poppins", sans-serif;
    font-size: 0.92rem;
    font-weight: 600;
    line-height: 1.15;
    text-align: left;
    box-shadow: none;
    transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.reportes-titulos-layout .reportes-titulos-sidebar .parametros-button:hover {
    background: #e7f1ff !important;
    border-color: #8fb8f3 !important;
}

.reportes-titulos-layout .reportes-titulos-sidebar .parametros-button.is-active {
    border-color: #95dbb7 !important;
    background: #ebfbf1 !important;
    color: #22885d !important;
}

.parametros-flash-tooltip {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 1200;
    max-width: min(24rem, calc(100vw - 2rem));
    padding: 0.8rem 1rem;
    border-radius: 0.75rem;
    background: rgba(17, 24, 39, 0.94);
    color: #f9fafb;
    font-family: Verdana, sans-serif;
    font-size: 0.88rem;
    line-height: 1.35;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.24);
    opacity: 0;
    transform: translateY(-0.5rem);
    pointer-events: none;
    transition: opacity 180ms ease, transform 180ms ease;
}

.parametros-flash-tooltip.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 900px) {
    .reportes-titulos-entity-bar {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .reportes-titulos-entity-actions,
    .reportes-titulos-placeholder-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .reportes-titulos-entity-button-top {
        grid-template-columns: 3.5rem minmax(0, 1fr);
    }

    .reportes-titulos-entity-logo-wrap {
        width: 3.5rem;
        height: 3.5rem;
    }

    .reportes-titulos-summary {
        width: min(100%, 48rem);
        gap: 0.55rem;
    }
    .reportes-titulos-row {
        grid-template-columns: 1fr;
        gap: 0.65rem;
        padding: 0.8rem;
        border: 1px solid #dbe3ef;
        border-radius: 1rem;
        background: rgba(255, 255, 255, 0.72);
    }

    .reportes-titulos-code {
        min-height: auto;
    }

    .reportes-titulos-code-grouped {
        grid-row: auto;
    }

    .reportes-titulos-selector-cell {
        justify-content: flex-start;
    }

    .reportes-titulos-disposition-cell {
        justify-content: flex-start;
    }

}
