/* ── Variables globales UPLA ────────────────────────────── */
:root {
    --azul: #0469ce;
    --azul-oscuro: #0e4d8d;
    --dark-blue: #034f9b;
    --dark-light: #222736;
    --cyan-upla: #0099CC;
    --negro: #000000;
    --rojo: #CC0000;
    --amarillo: #CC9900;
}

/* ── Base ───────────────────────────────────────────────── */
html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus,
.form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 30px;
}

.footer-sticky {
    position: fixed;
    bottom: 0;
    width: 100%;
    z-index: 1030;
}

.logo-img {
    width: 90%;
}



@media (max-width: 576px) {
    .div-img-upla {
        text-align: center;
    }

    #logo_such {
        height: 5%;
        width: auto;
    }

    #logo_acreditacion {
        height: 5%;
        max-height: 100px;
        width: auto;
    }
}

/* ── Encabezado de sección (compartido en todas las vistas) ─ */
.header-container {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--dark-blue) 100%);
    color: #fff;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(14, 77, 141, 0.18);
}

/* ── Pestañas con colores UPLA (base global) ────────────── */
.nav-tabs {
    border-bottom: 2px solid var(--azul-oscuro);
    gap: 3px;
}

.nav-tabs .nav-link {
    margin-bottom: -2px;
    border: none;
    border-radius: 6px 6px 0 0;
    color: #64748b;
    padding: 0.45rem 0.85rem;
    font-size: 0.82rem;
    font-weight: 500;
    background-color: #e8edf4;
    transition: background-color 0.18s, color 0.18s;
}

.nav-tabs .nav-link.active {
    color: #fff;
    background-color: var(--azul-oscuro);
    border-color: var(--azul-oscuro);
    font-weight: 600;
}

.nav-tabs .nav-link:hover:not(.active) {
    background-color: #c7d8ed;
    color: var(--azul-oscuro);
    border-color: transparent;
}

.badge-tab {
    font-size: 0.68rem;
    padding: 2px 6px;
    margin-left: 4px;
    border-radius: 10px;
    background-color: #fff;
    color: var(--azul-oscuro);
    vertical-align: middle;
}

.nav-tabs .nav-link.active .badge-tab {
    background-color: rgba(255, 255, 255, 0.25);
    color: #fff;
}

/* ── Cabecera de modal UPLA ─────────────────────────────── */
.modal-header-upla {
    background: linear-gradient(135deg, var(--azul-oscuro) 0%, var(--dark-blue) 100%);
    color: #fff;
    padding: 0.65rem 1rem;
}

.modal-header-upla .modal-title {
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
}

.modal-header-upla .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

/* Agrega esto a tu clase de pestañas (la barra horizontal de "Borradores", "Pendientes", etc.) */
.nav-tabs, .bdj-tabs, ul[role="tablist"] {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    white-space: nowrap !important;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 5px; /* Evita que el scrollbar tape el borde inferior */
}

    /* Opcional: estilizar la barra de scroll de las pestañas para que sea sutil */
    .nav-tabs::-webkit-scrollbar {
        height: 4px;
    }

    .nav-tabs::-webkit-scrollbar-thumb {
        background: #ccc;
        border-radius: 4px;
    }

/* 1. Prevent screen-level scrolling and set absolute bounds */
/*html, body {
    min-height: 100vh !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: hidden;*/ /* evita scroll horizontal accidental */
    /*overflow-y: auto;*/ /* permite scroll vertical normal */
/*}

.main-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.main-content {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    overflow-y: auto;*/ /* scroll interno si el contenido es más alto que la pantalla */
    /*overflow-x: hidden;
}*/

/* 4. Compact the tabs to fit in a single row without overflowing */
/*.nav-tabs,
.nav-pills,
ul[role="tablist"] {
    display: flex !important;
    flex-wrap: nowrap !important;
    width: 100% !important;
    justify-content: space-between;*/ /* Evenly distributes tabs across available width */
    /*gap: 2px;
}*/

    /* 5. Make each tab shrink dynamically to fit the container */
    /*.nav-tabs .nav-item,
    .nav-pills .nav-item,
    ul[role="tablist"] > li {
        flex: 1 1 0;*/ /* Allows tabs to shrink proportionally */
        /*min-width: 0;*/ /* Overrides default browser flex bounds */
        /*text-align: center;
    }*/

    /* 6. Ensure text truncates with ellipsis if a tab name is too long */
    /*.nav-tabs .nav-link,
    .nav-pills .nav-link {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        padding: 0.4rem 0.25rem !important;*/ /* Compact padding */
        /*font-size: 0.8rem !important;*/ /* Slightly smaller text for tight spaces */
        /*width: 100%;
        display: block;
    }*/
