:root {
    --bg0: #0b1220;
    --bg1: #0f172a;

    --sef-card: rgba(17, 24, 39, .62);
    --line: rgba(255, 255, 255, .06);

    --text: #e5e7eb;
    --muted: #94a3b8;

    --accent: #f59e0b;

    --shadow: 0 18px 50px rgba(0, 0, 0, .45);

    --radius: 18px;
}

/* RESET */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;

    background:
        radial-gradient(700px 500px at 20% 10%, rgba(245, 158, 11, .18), transparent 60%),
        radial-gradient(900px 600px at 80% 20%, rgba(59, 130, 246, .15), transparent 60%),
        radial-gradient(800px 550px at 40% 90%, rgba(34, 197, 94, .10), transparent 60%),
        linear-gradient(180deg, var(--bg1), var(--bg0));

    color: var(--text);
    min-height: 100vh;
}

/* APP LAYOUT */

.sef-app {
    min-height: 100vh;
    display: flex;
}

/* SIDEBAR DESKTOP */

.sef-sidebar {
    width: 270px;
    padding: 22px 16px;

    border-right: 1px solid var(--line);

    background: rgba(15, 23, 42, .55);

    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    position: sticky;
    top: 0;
    height: 100vh;
}

/* BRAND */

.sef-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 18px;
}

.sef-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: .5px;
}

.sef-logo img {
    height: 28px;
    width: auto;
    display: block;
}


.sef-badge {
    font-size: 11px;

    color: var(--accent);

    padding: 6px 10px;

    border-radius: 999px;

    background: rgba(245, 158, 11, .12);

    border: 1px solid rgba(245, 158, 11, .25);
}

/* NAVIGATION */

.sef-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 14px;
}

.sef-nav a {
    display: flex;
    align-items: center;
    gap: 12px;

    padding: 12px;

    text-decoration: none;

    color: var(--muted);

    border-radius: 14px;

    border: 1px solid transparent;

    transition: .18s ease;
}

.sef-nav a i {
    font-size: 16px;
    width: 20px;
    text-align: center;
}

.sef-nav a:hover {
    background: rgba(255, 255, 255, .04);
    border-color: rgba(255, 255, 255, .06);

    color: var(--text);

    transform: translateY(-1px);
}

.sef-nav a.active {
    color: var(--accent);

    background: rgba(245, 158, 11, .12);

    border-color: rgba(245, 158, 11, .22);
}

.sef-nav-section {

    font-size: 11px;

    text-transform: uppercase;

    color: #94a3b8;

    margin-top: 18px;
    margin-bottom: 6px;

    padding-left: 10px;

    letter-spacing: .6px;
}

/* MAIN */

.sef-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* TOPBAR */

.sef-topbar {
    height: 70px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 0 18px;

    border-bottom: 1px solid var(--line);

    background: rgba(15, 23, 42, .55);

    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

.sef-top-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* HAMBURGER */

.sef-hamburger {
    width: 42px;
    height: 42px;

    display: none;

    align-items: center;
    justify-content: center;

    border-radius: 14px;

    border: 1px solid var(--line);

    background: rgba(255, 255, 255, .03);

    color: var(--text);

    cursor: pointer;

    transition: .18s ease;
}

.sef-hamburger:hover {
    background: rgba(255, 255, 255, .06);
    transform: translateY(-1px);
}

/* TITLE */

.sef-top-title {
    color: #ffffff;
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.sef-top-title strong {
    font-size: 14px;
}

.sef-top-title span {
    font-size: 12px;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 6px;
}

.sef-top-title span i {
    font-size: 12px;
    opacity: .8;
}

/* USER */

.sef-user-pill {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;

    padding: 10px 12px;

    border-radius: 999px;

    border: 1px solid var(--line);

    background: rgba(255, 255, 255, .03);

    max-width: 55vw;
}

.sef-avatar {
    width: 34px;
    height: 34px;

    border-radius: 12px;

    background: rgba(245, 158, 11, .15);

    border: 1px solid rgba(245, 158, 11, .22);

    display: flex;
    align-items: center;
    justify-content: center;

    color: var(--accent);

    font-weight: 800;
}

.sef-meta {
    min-width: 0;
}

.sef-name {
    font-size: 13px;
    font-weight: 600;

    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sef-sub {
    font-size: 11px;
    color: var(--muted);

    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* CONTENT */

.sef-content {
    padding: 18px;
}

@media(min-width:960px) {

    .sef-content {
        padding: 28px 28px 40px;
        max-width: 1300px;
        margin: 0 auto;
        width: 100%;
    }

}

/* CARDS */

.sef-card {
    background: var(--sef-card);

    color: var(--text);
    border: 1px solid var(--line);

    border-radius: var(--radius);

    padding: 18px;

    box-shadow: var(--shadow);

    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    transition: .2s;
    margin-bottom: 4px;
}

.sef-content.full-width {
    max-width: 100% !important;
}

.sef-card:hover {
    transform: translateY(-2px);
}

.sef-card-title {
    font-size: 12px;
    color: var(--muted);
    margin-bottom: 8px;
}

.sef-card-value {
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -.5px;
    color: #ffffff;
}

/* GRID */
.sef-grid {
    display: grid;
    gap: 14px;
}

.kpi {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media(min-width:720px) {

    .kpi {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

}

/* LIST */

.list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.item {
    display: flex;
    gap: 12px;

    padding: 12px;

    border-radius: 14px;

    border: 1px solid var(--line);

    background: rgba(255, 255, 255, .03);

    transition: .18s;
}

.item:hover {
    background: rgba(255, 255, 255, .05);
    transform: translateY(-1px);
}

.item i {
    color: var(--accent);
}

/* PROGRESS BAR */

.bar {
    height: 10px;

    border-radius: 999px;

    background: rgba(255, 255, 255, .06);

    border: 1px solid var(--line);

    overflow: hidden;
}

.bar span {
    display: block;

    height: 100%;
    width: 62%;

    background: linear-gradient(90deg, rgba(245, 158, 11, .9), rgba(59, 130, 246, .7));
}

/* DRAWER MOBILE */

.drawer-overlay {
    position: fixed;

    inset: 0;

    background: rgba(0, 0, 0, .55);

    display: none;

    z-index: 60;
}

.drawer {
    position: fixed;

    top: 0;
    bottom: 0;
    left: 0;

    width: 86vw;
    max-width: 320px;

    transform: translateX(-105%);
    transition: .22s ease;

    z-index: 70;

    padding: 22px 16px;

    background: rgba(15, 23, 42, .92);

    border-right: 1px solid var(--line);

    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);

    /* NUEVO */
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 120px;
}

.drawer.open {
    transform: translateX(0);
}

.drawer::-webkit-scrollbar {
    width: 6px;
}

.drawer::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, .15);
    border-radius: 20px;
}

.drawer::-webkit-scrollbar-track {
    background: transparent;
}

/* MOBILE NAV */

.sef-bottom-sef-nav {
    position: fixed;

    bottom: 0;
    left: 0;
    right: 0;

    height: 70px;

    background: rgba(15, 23, 42, .95);

    backdrop-filter: blur(12px);

    display: none;

    justify-content: space-around;
    align-items: center;

    border-top: 1px solid rgba(255, 255, 255, .05);

    z-index: 999;
}

.sef-nav-item {
    text-decoration: none;

    color: var(--muted);

    font-size: 11px;

    display: flex;
    flex-direction: column;

    align-items: center;

    gap: 4px;

    transition: .2s;
}

.sef-nav-item i {
    font-size: 18px;
}

.sef-nav-item.active {
    color: var(--accent);
}

/* BOTON CENTRAL */
.sef-nav-center {
    position: relative;
    top: -18px;
}

.center-btn {
    width: 56px;
    height: 56px;

    border-radius: 50%;

    background: linear-gradient(135deg, #f59e0b, #d97706);

    display: flex;
    align-items: center;
    justify-content: center;

    color: white;

    font-size: 22px;

    box-shadow: 0 8px 20px rgba(0, 0, 0, .4);
}

/* MOBILE */

@media(max-width:959px) {
    .sef-sidebar {
        display: none;
    }

    .sef-bottom-sef-nav {
        display: flex;
    }

    .sef-content {
        padding-bottom: 90px;
    }
}

/* ===============================
SEF MODAL DARK
=============================== */

.sef-modal .modal-content {
    background: rgba(15, 23, 42, .95);
    border: 1px solid var(--line);
    border-radius: 20px;
    backdrop-filter: blur(18px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .6);
    color: var(--text);
}

.sef-modal .modal-header {

    background: linear-gradient(135deg,
            #f59e0b,
            #d97706);

    color: #000;

    border-bottom: none;

}

.sef-modal .modal-title {
    font-weight: 700;
}

.sef-modal .modal-footer {
    border-top: 1px solid var(--line);
}

/* ===============================
SEF INPUTS MODERN
=============================== */

.sef-input {
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 12px;
    color: var(--text);
    padding: 12px 14px;
    transition: .2s;
}

.sef-input:focus {
    background: rgba(255, 255, 255, .06);
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(245, 158, 11, .2);
    color: #fff;
}

.sef-input::placeholder {
    color: #fff;
}

/* labels */

.sef-label {
    font-size: 13px;
    color: var(--muted);
    margin-bottom: 6px;
}

/* ===============================
SWITCH SEF (BOOTSTRAP EXTEND)
=============================== */

.form-switch .form-check-input {

    width: 72px;
    height: 18px;

    cursor: pointer;

    border: none;

    border-radius: 50px;

    background-color: #b62100;

    transition: all .25s ease;

}

/* Thumb color */

.form-switch .form-check-input:checked {

    background-color: #f59e0b;

}

/* Focus glow */

.form-switch .form-check-input:focus {

    box-shadow: 0 0 0 3px rgba(245, 158, 11, .25);

}

/* Label spacing */

.form-check {
    display: flex;
    align-items: center;
    gap: 12px;
}

.form-check-label {
    color: var(--text);
    font-size: 14px;
}

/* TABLE DARK */

.sef-table {
    background: rgba(255, 255, 255, .03);
    border-radius: 12px;
    overflow: hidden;
}

.sef-table th {
    background: rgba(255, 255, 255, .05);
    color: var(--muted);
    font-size: 12px;
}

.sef-table td {
    color: var(--text);
}

/* ===============================
SEF FORM INPUTS
=============================== */

.sef-input {

    background: rgba(255, 255, 255, .05);

    border: 1px solid rgba(255, 255, 255, .08);

    border-radius: 12px;

    padding: 12px 14px;

    color: var(--text);

    font-size: 14px;

    transition: all .2s ease;

}

.sef-input::placeholder {
    color: #fff;
}

/* FOCUS */

.sef-input:focus {

    background: rgba(255, 255, 255, .07);

    border-color: var(--accent);

    box-shadow: 0 0 0 2px rgba(245, 158, 11, .25);

    color: #fff;

}

/* DATETIME */

.sef-input[type="datetime-local"] {

    color-scheme: dark;

}

/* LABEL */

.sef-label {

    font-size: 13px;

    color: var(--muted);

    margin-bottom: 6px;

    display: block;

}

/* MODAL BODY */

.sef-modal .modal-body {

    background: linear-gradient(180deg,
            rgba(15, 23, 42, .95),
            rgba(11, 18, 32, .95));

}

/* ===============================
FORCE DARK INPUTS (OVERRIDE BOOTSTRAP)
=============================== */

.form-control.sef-input {

    background: rgba(255, 255, 255, .05) !important;

    border: 1px solid rgba(255, 255, 255, .08) !important;

    color: var(--text) !important;

    border-radius: 12px;

    padding: 12px 14px;

}

.form-control.sef-input:focus {

    background: rgba(255, 255, 255, .08) !important;

    border-color: var(--accent) !important;

    box-shadow: 0 0 0 2px rgba(245, 158, 11, .25) !important;

    color: #fff !important;

}

.form-control.sef-input::placeholder {
    color: #ffffffae !important;
}



/* datetime icon dark */

.sef-input[type="datetime-local"] {
    color-scheme: dark;
}


/* ===============================
SEF INPUT GROUP MODERN
=============================== */

.sef-input-group {
    position: relative;
}

.sef-input-icon {

    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-size: 15px;
    pointer-events: none;
}

.sef-input {

    width: 100%;

    background: rgba(255, 255, 255, .05) !important;

    border: 1px solid rgba(255, 255, 255, .08) !important;

    border-radius: 14px;

    padding: 12px 14px 12px 42px;

    color: var(--text) !important;

    font-size: 14px;

    transition: all .25s ease;

}

.sef-input::placeholder {
    color: #6b7280;
}

/* FOCUS EFFECT */

.sef-input:focus {

    background: rgba(255, 255, 255, .08) !important;

    border-color: var(--accent) !important;

    box-shadow:
        0 0 0 2px rgba(245, 158, 11, .25),
        0 6px 18px rgba(0, 0, 0, .35);

    color: #fff !important;

}

/* datetime icon dark */

.sef-input[type="datetime-local"] {
    color-scheme: dark;
}

/* ===============================
FORM SPACING
=============================== */

.sef-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

@media(max-width:720px) {

    .sef-form-row {
        grid-template-columns: 1fr;
    }

}

/* ===============================
SWITCH BOX UX
=============================== */

.sef-switch-box {

    display: flex;
    align-items: center;
    gap: 14px;

    padding: 12px 14px;

    border-radius: 14px;

    background: rgba(255, 255, 255, .03);

    border: 1px solid var(--line);

}

.sef-switch-info {

    display: flex;
    flex-direction: column;

}

.sef-switch-info strong {

    font-size: 14px;

}

.sef-switch-info small {

    font-size: 12px;
    color: var(--muted);

}

.input-detectado {

    border-color: #22c55e !important;

    background: rgba(34, 197, 94, .08) !important;

}

.input-loading {
    border-color: #3b82f6 !important;
    background: rgba(59, 130, 246, .08) !important;
}

/* ===============================
SEF TABLE ACOMPAÑANTES
=============================== */

.sef-table {

    background: rgba(255, 255, 255, .03);

    border-radius: 14px;

    overflow: hidden;

    border: 1px solid var(--line);

}

.sef-table thead {

    background: rgba(255, 255, 255, .06);

}

.sef-table thead th {

    font-size: 12px;

    color: var(--muted);

    border: none;

    padding: 10px 12px;

}

.sef-table tbody td {

    border-top: 1px solid var(--line);

    padding: 10px 12px;

    vertical-align: middle;

}

.sef-table tbody tr {

    transition: .15s ease;

}

.sef-table tbody tr:hover {

    background: rgba(255, 255, 255, .04);

}

.sef-btn-delete {

    border-radius: 10px;

    font-size: 12px;

    padding: 4px 10px;

}

/* ===============================
SEF MODAL GREEN HEADER
=============================== */

.sef-modal-header-green {

    background: linear-gradient(135deg, #16a34a, #15803d);

    color: #fff;

    border-bottom: none;

}

.sef-table {

    background: rgba(255, 255, 255, .04) !important;

    border: 1px solid var(--line);

    color: var(--text);

}

.sef-table tbody tr {

    background: transparent;

}

.sef-table td {

    background: transparent !important;

    color: var(--text);

}

.sef-table th {

    background: rgba(255, 255, 255, .06);

}

/* ===============================
SEF CHIPS ACOMPAÑANTES
=============================== */

.sef-chips {

    display: flex;
    flex-wrap: wrap;
    gap: 8px;

}

.sef-chip {

    display: flex;
    align-items: center;
    gap: 8px;

    padding: 6px 10px;

    border-radius: 999px;

    background: rgba(255, 255, 255, .06);

    border: 1px solid var(--line);

    font-size: 13px;

}

.sef-chip span {

    color: var(--text);

}

.sef-chip button {

    border: none;
    background: none;

    color: #ef4444;

    font-size: 14px;

    cursor: pointer;

    padding: 0 4px;

}

/* ===============================
SECCIÓN NUEVO ACOMPAÑANTE
=============================== */

.sef-acomp-box {

    border: 1px solid rgba(245, 158, 11, .35);

    border-radius: 16px;

    padding: 16px;

    background: linear-gradient(180deg,
            rgba(245, 158, 11, .05),
            rgba(15, 23, 42, .4));

}

.sef-acomp-box .sef-label:first-child {
    color: var(--accent);
    font-weight: 600;
}

.sef-card-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    gap: 10px;
    font-size: 14px;
    cursor: pointer;
}

.sef-card-link i {
    font-size: 26px;
    color: var(--primary);
}

.sef-card-link:hover {
    transform: translateY(-2px);
}

#mapa-accesos {
    position: relative;
    height: 260px;
    background: url('dist/img/mapa_condominio.png');
    background-size: cover;
    border-radius: 10px;
}

.punto {
    position: absolute;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
}

.acceso-verde {
    background: #2ecc71;
}

.acceso-rojo {
    background: #e74c3c;
}

.sef-card {
    position: relative;
    padding: 18px;
    border-radius: 14px;
    background: linear-gradient(145deg, #0b1c35, #071425);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

/* ICONO DECORATIVO */

.sef-card-icon {
    position: absolute;
    top: 10px;
    right: 16px;
    font-size: 46px;
    opacity: 0.08;
}

/* TITULO */

.sef-card-title {
    font-size: 13px;
    color: #9aa4b2;
    margin-bottom: 6px;
}

/* NUMERO */

.sef-card-value {
    font-size: 34px;
    font-weight: 700;
    color: white;
}

/* FOOTER KPI */

.sef-card-footer {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 12px;
    color: #9aa4b2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: 0.2s;
}

.sef-card-footer:hover {
    color: white;
}

.sef-card-footer i {
    margin-left: 6px;
    font-size: 11px;
}

.actividad-footer {
    margin-top: 14px;
    padding-top: 12px;
    padding-bottom: 4px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);

    font-size: 12px;
    color: #9aa4b2;

    cursor: pointer;

    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 6px;

    transition: 0.2s ease;
}

.actividad-footer:hover {
    color: #ffffff;
}

.actividad-footer i {
    font-size: 11px;
    opacity: .7;
}

.actividad-footer i {
    transition: transform .2s ease;
}

.actividad-footer:hover i {
    transform: translateX(3px);
}

#actividad-tiempo-real {
    padding-bottom: 6px;
}

.tabla-responsive-wrap {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-top: 12px;
    border-radius: 12px;
}

#tabla-fastpass {
    width: 100% !important;
    min-width: 780px;
    border-collapse: collapse !important;
}

#tabla-fastpass thead th {
    background: rgba(255, 255, 255, 0.06);
    color: #9aa4b2;
    font-size: 12px;
    font-weight: 600;
    border: none !important;
    padding: 12px 14px !important;
    white-space: nowrap;
}

#tabla-fastpass thead th:first-child {
    border-top-left-radius: 10px;
    border-bottom-left-radius: 10px;
}

#tabla-fastpass thead th:last-child {
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
}

#tabla-fastpass tbody td {
    background: transparent !important;
    color: #ffffff;
    border: none !important;
    padding: 14px !important;
    vertical-align: middle;
}

#tabla-fastpass tbody td {
    word-break: normal;
    white-space: normal;
}

#tabla-fastpass tbody td:nth-child(3),
#tabla-fastpass tbody td:nth-child(4) {
    min-width: 120px;
}

/* ocultar fila processing */

.dataTables_processing {
    display: none !important;
}

/* ocultar fila fantasma */

#tabla-fastpass tbody tr.dataTables_empty td {
    background: transparent !important;
    border: none !important;
}

#tabla-fastpass tbody tr {
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    /*background:rgba(255,255,255,.02);*/
    background: transparent;
}

#tabla-fastpass tbody tr td:first-child {
    border-top-left-radius: 12px;
    border-bottom-left-radius: 12px;

}

#tabla-fastpass tbody tr td:last-child {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

/*
#tabla-fastpass tbody tr:hover td {
    background: rgba(255, 255, 255, 0.05);
}*/

#tabla-fastpass .btn {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

#tabla-fastpass .btn-warning {
    background: #facc15;
    color: #111827;
}

#tabla-fastpass .btn-danger {
    background: #f43f5e;
    color: #ffffff;
}

.dataTables_wrapper {
    color: #cbd5e1;
}

.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate {
    color: #cbd5e1 !important;
    margin-bottom: 10px;
    font-size: 13px;
}

.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.10);
    color: #fff;
    border-radius: 8px;
    padding: 6px 10px;
    outline: none;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    color: #cbd5e1 !important;
    border: none !important;
    background: transparent !important;
    border-radius: 8px;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: rgba(255, 255, 255, 0.10) !important;
    color: #fff !important;
}

@media (max-width: 768px) {
    #tabla-fastpass {
        min-width: 720px;
    }

    #tabla-fastpass thead th,
    #tabla-fastpass tbody td {
        font-size: 13px;
        padding: 12px 10px !important;
    }

    #tabla-fastpass .btn {
        width: 32px;
        height: 32px;
        margin-right: 4px;
    }
}

#tabla-fastpass tbody td {
    vertical-align: middle;
}

#tabla-fastpass td {
    white-space: nowrap;
}

#tabla-fastpass td:nth-child(3),
#tabla-fastpass td:nth-child(4) {
    white-space: normal;
}

#tabla-fastpass thead th {
    border-bottom: none !important;
}

.dataTables_scrollHeadInner table {
    margin-bottom: 0 !important;
}

#tabla-fastpass thead tr {
    height: auto;
}

.dataTables_wrapper .dataTables_scrollBody {
    border-top: none !important;
}

/* =====================================
FIX FILA GRIS DATATABLE
===================================== */

/* eliminar fondo gris del tbody */

table.dataTable tbody {
    background: transparent !important;
}

/* eliminar fondo de fila processing */

.dataTables_wrapper .dataTables_processing {
    background: transparent !important;
    border: none !important;
}

/* eliminar fondo default datatable */

table.dataTable.display tbody tr.odd,
table.dataTable.display tbody tr.even {
    background: transparent !important;
}

/* evitar overlay gris */

table.dataTable.no-footer {
    border-bottom: none !important;
}

/* ===============================
FIX HEADER DATATABLE DARK MODE
=============================== */

table.dataTable thead th,
table.dataTable thead td,
table.dataTable thead th.sorting,
table.dataTable thead th.sorting_asc,
table.dataTable thead th.sorting_desc,
table.dataTable thead th.sorting_disabled {

    background: rgba(255, 255, 255, 0.06) !important;
    color: #9aa4b2 !important;
    border: none !important;
}

/* quitar fondo blanco que mete datatables */

.dataTables_wrapper table.dataTable thead th {
    background: rgba(255, 255, 255, 0.06) !important;
}

/* quitar línea inferior que genera el efecto gris */

table.dataTable.no-footer {
    border-bottom: none !important;
}

.cards-condominios {
    display: grid;
    /*grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));*/
    gap: 18px;
    grid-template-columns: repeat(3, 1fr);
}

.sef-card-condominio {
    background: linear-gradient(145deg, #0b1a2b, #0f2238);
    border-radius: 14px;
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    transition: 0.3s ease;
    color: #fff;
}

.sef-card-condominio:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6);
}

/* Tablet */
@media (max-width: 1024px) {
    .cards-condominios {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Móvil */
@media (max-width: 640px) {
    .cards-condominios {
        grid-template-columns: 1fr;
    }
}

/* HEADER */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.codigo {
    font-weight: bold;
    color: #f59e0b;
}

.estado {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
}

.estado.activo {
    background: #16a34a;
}

.estado.suspendido {
    background: #f59e0b;
}

.estado.eliminado {
    background: #dc2626;
}

/* TITLE */
.card-title {

    color: #fff;
    margin-top: 10px;
    font-size: 16px;
    font-weight: 600;
}

/* META */
.card-meta {
    margin-top: 10px;
    font-size: 13px;
    color: #ccc;
}

/* MAP */
.card-map {
    margin-top: 12px;
    height: 180px;
    border-radius: 10px;
    overflow: hidden;
}

.card-map iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.map-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: #111;
    color: #888;
    font-size: 13px;
}

/* ACTIONS */
.card-actions {
    margin-top: 12px;
    display: flex;
    justify-content: space-between;
}

.card-actions a {
    font-size: 13px;
    color: #3b82f6;
    text-decoration: none;
}

.card-actions a:hover {
    text-decoration: underline;
}

/* BADGES */
.badge.qr {
    background: #2563eb;
    padding: 3px 8px;
    border-radius: 10px;
}

.badge.no {
    background: #6b7280;
    padding: 3px 8px;
    border-radius: 10px;
}

.card-map iframe {
    transition: transform 0.3s ease;
}

.sef-card-condominio:hover iframe {
    transform: scale(1.05);
}

.sef-card-oficial {
    background: linear-gradient(145deg, #0f172a, #0b1220);
    border-radius: 14px;
    padding: 16px;
    backdrop-filter: blur(6px);
    /* 🔥 BORDE SUTIL */
    border: 1px solid rgba(255, 255, 255, 0.06);

    /* 🔥 SOMBRA PROFUNDA */
    box-shadow:
        0 10px 25px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.02) inset;

    /* transición suave */
    transition: all 0.25s ease;
    min-height: 200px;
}

.sef-card-oficial:hover {
    transform: translateY(-4px);

    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.8),
        0 0 0 1px rgba(245, 158, 11, 0.2) inset;

    border: 1px solid rgba(245, 158, 11, 0.3);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.card-header .nombre {
    font-weight: 700;
    font-size: 15px;
    color: #fff;
}

.card-header .codigo {
    font-size: 12px;
    color: var(--muted);
}

.card-body {
    margin-top: 10px;
    font-size: 13px;
    color: #ccc;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 15px;
}

.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f59e0b;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* AVATAR GRANDE */
.avatar-lg {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    background: #f59e0b;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 22px;
}

/* HEADER */
.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: space-between;
}

/* INFO */
.header-info {
    flex: 1;
}

.nombre {
    font-weight: 700;
    color: #fff;
}

.puesto {
    font-size: 13px;
    color: #f59e0b;
    font-weight: 600;
}

/* PORTACIÓN */
.portacion {
    margin-top: 8px;
}

.portacion-fechas {
    display: flex;
    flex-direction: column;
    font-size: 12px;
    color: #ccc;
}

/* FOOTER */
.card-footer {
    margin-top: 12px;
    text-align: right;
}

.portacion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
}

.portacion-fechas {
    display: flex;
    flex-direction: column;
    font-size: 12px;
    color: #ccc;
    margin-top: 4px;
}

.detalle-header {
    display: flex;
    align-items: center;
    gap: 15px;
}

.avatar-xl {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background: #f59e0b;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: bold;
}

.detalle-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-top: 10px;
}

.detalle-grid div {
    background: rgba(255, 255, 255, 0.03);
    padding: 10px;
    border-radius: 8px;
}

.cards-roles {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.sef-card-rol {
    background: #0f172a;
    border-radius: 12px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.card-title {
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
}

.dia {
    margin-bottom: 10px;
}

.dia-titulo {
    color: #f59e0b;
    font-weight: 600;
    font-size: 13px;
}

.turno {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    padding: 3px 0;
}

.turno.libre {
    background: rgba(220, 53, 69, 0.15);
    border-radius: 6px;
    padding: 4px 6px;
}

.turno.libre .hora {
    color: #ff6b6b;
    font-weight: 600;
}

.turno.libre .oficial {
    color: #fff;
}



/* Select2 */
/* ===== SELECT2 MEJORADO PRO ===== */

.select2-container--default .select2-selection--single {
    background: rgba(255, 255, 255, .06) !important;
    border: 1px solid rgba(255, 255, 255, .14) !important;
    border-radius: 14px !important;
    height: 48px !important;
    display: flex !important;
    align-items: center !important;
    z-index: 9999 !important;
}

.select2-container--default .select2-selection__rendered {
    color: #ffffff !important;
    padding-left: 14px !important;
    line-height: 48px !important;
    font-size: 14px;
}

.select2-dropdown {

    z-index: 9999 !important;
    background: #0e1626 !important;
    border: 1px solid rgba(255, 255, 255, .12) !important;
    border-radius: 14px !important;
    padding: 10px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .6);
}

/* BUSCADOR MÁS GRANDE */
.select2-search {
    width: 100% !important;
    margin-bottom: 8px;
}

.select2-search__field {
    width: 100% !important;
    background: rgba(255, 255, 255, .08) !important;
    border: 1px solid rgba(255, 255, 255, .18) !important;
    color: #fff !important;
    border-radius: 10px !important;
    padding: 10px 12px !important;
    font-size: 14px;
}

/* OPCIONES */
.select2-results__option {
    padding: 12px 14px;
    border-radius: 10px;
    color: #fff;
    font-size: 14px;
}

.select2-results__option--highlighted {
    background: linear-gradient(90deg, rgba(240, 180, 41, .45), rgba(240, 180, 41, .15)) !important;
    color: #fff !important;
}

/* SCROLL MÁS LIMPIO */
.select2-results {
    max-height: 240px;
    overflow-y: auto;
}

.select2-results::-webkit-scrollbar {
    width: 6px;
}

.select2-results::-webkit-scrollbar-thumb {
    background: rgba(240, 180, 41, .5);
    border-radius: 10px;
}

.sef-btn-pdf {
    border-radius: 10px;
    padding: 6px 10px;
}

.toggle-pass {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9aa4b2;
    cursor: pointer;
    font-size: 14px;
    transition: .2s;
}

.toggle-pass:hover {
    color: #fff;
}

.input-ok {
    border: 1px solid #16a34a !important;
}

.input-error {
    border: 1px solid #dc3545 !important;
}

.req {
    color: #ef4444;
    margin-left: 4px;
}

.sef-card .tabla-responsive-wrap {
    max-height: 300px;
    overflow-y: auto;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    width: 100%;
}

@media (max-width: 992px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

#appLoader {
    position: fixed;
    inset: 0;
    background: #0f172a;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

#appLoader img {
    width: 80px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        opacity: .5
    }

    50% {
        opacity: 1
    }

    100% {
        opacity: .5
    }
}