.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    font-size: smaller;
    font-style: italic;
}

.truncate-1 {
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.modal-dialog.large {
    width: 80% !important;
    max-width: unset;
}

.modal-dialog.mid-large {
    width: 50% !important;
    max-width: unset;
}

@media (max-width:900px) {
    .modal-dialog.large {
        width: 100% !important;
        max-width: unset;
    }
    .modal-dialog.mid-large {
        width: 100% !important;
        max-width: unset;
    }
    .modal-dialog {
        margin: unset !important;
    }
}

#viewer_modal .btn-close {
    position: absolute;
    z-index: 999999;
    /*right: -4.5em;*/
    background: unset;
    color: white;
    border: unset;
    font-size: 27px;
    top: 0;
}

#viewer_modal .modal-dialog {
    width: 80%;
    max-width: unset;
    height: calc(90%);
    max-height: unset;
}

#viewer_modal .modal-content {
    background: black;
    border: unset;
    height: calc(100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

#viewer_modal img,
#viewer_modal video {
    max-height: calc(100%);
    max-width: calc(100%);
}

table.dataTable th,
table.dataTable td {
    padding: 5px !important;
}

.card.d-flex {
    flex-direction: row !important;
}

.card.d-flex>img {
    width: 20% !important;
}

.card.d-flex>.card-body {
    width: 80% !important;
}

span.btn {
    cursor: unset;
}

span.btn:hover {
    background: inherit;
}

#tourCarousel {
    height: 50vh !important;
}

#tourCarousel img {
    object-fit: fill;
}

div.stars {
    width: auto;
    display: inline-block
}

.mt-200 {
    margin-top: 200px
}

input.star {
    display: none
}

label.star {
    float: right;
    /* padding: 10px; */
    font-size: 30px;
    color: #333333;
    transition: all .2s
}

input.star:checked~label.star:before {
    content: '\2605';
    color: #ffc800;
    transition: all .25s
}

input.star-5:checked~label.star:before {
    color: #ffc800;
    /* text-shadow: 0 0 20px #952 */
}

input.star-1:checked~label.star:before {
    color: #F62
}

label.star:hover {
    transform: rotate(-15deg) scale(1.3)
}

label.star:before {
    content: '\2605';
    font-family: FontAwesome
}

#top-header {
    height: 70vh;
}

#top-header * {
    text-shadow: 3px 2px #000000b0;
}

#top-header .title {
    font-size: 5em;
    text-shadow: 4px 4px #000000f5;
}

#top-header:before {
    content: '';
    position: absolute;
    height: 80vh;
    width: calc(100%);
    top: 0;
    left: 0;
    background-image: var(--bg-img) !important;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center center;
    z-index: 0;
    filter: brightness(.95)
}

.company-name {
    font-size: 1.35rem;
    font-variant: all-petite-caps;
    font-family: monospace;
    font-weight: 600;
    color: #b5b5b5;
}

img.company-logo {
    transition: transform .02s ease-in;
}

img.company-logo:hover {
    transform: scale(1.02);
}

/* ===== Responsive compact UI (global admin) ===== */
body.ui-compact-desktop {
    font-size: 0.94rem;
}

body.ui-compact-tablet {
    font-size: 0.89rem;
}

body.ui-compact-mobile {
    font-size: 0.84rem;
}

body.ui-compact-desktop .content-header h1,
body.ui-compact-tablet .content-header h1,
body.ui-compact-mobile .content-header h1 {
    font-size: 1.2rem;
    line-height: 1.2;
}

body.ui-compact-desktop .card-title,
body.ui-compact-tablet .card-title,
body.ui-compact-mobile .card-title {
    font-size: 1rem;
}

body.ui-compact-desktop .form-control,
body.ui-compact-desktop .custom-select,
body.ui-compact-desktop .input-group-text,
body.ui-compact-desktop .btn {
    font-size: 0.88rem;
    min-height: calc(1.5em + .5rem + 2px);
    padding-top: .2rem;
    padding-bottom: .2rem;
}

body.ui-compact-tablet .form-control,
body.ui-compact-tablet .custom-select,
body.ui-compact-tablet .input-group-text,
body.ui-compact-tablet .btn,
body.ui-compact-mobile .form-control,
body.ui-compact-mobile .custom-select,
body.ui-compact-mobile .input-group-text,
body.ui-compact-mobile .btn {
    font-size: 0.82rem;
    min-height: calc(1.45em + .45rem + 2px);
    padding-top: .15rem;
    padding-bottom: .15rem;
}

body.ui-compact-tablet .table th,
body.ui-compact-tablet .table td,
body.ui-compact-mobile .table th,
body.ui-compact-mobile .table td {
    padding: .3rem .35rem;
}

body.ui-compact-desktop .nav-sidebar .nav-link,
body.ui-compact-tablet .nav-sidebar .nav-link,
body.ui-compact-mobile .nav-sidebar .nav-link {
    font-size: 0.88rem;
    padding-top: .35rem;
    padding-bottom: .35rem;
}

body.ui-compact-desktop .main-header .nav-link,
body.ui-compact-tablet .main-header .nav-link,
body.ui-compact-mobile .main-header .nav-link {
    font-size: 0.88rem;
}

body.ui-compact-desktop .dataTables_wrapper,
body.ui-compact-tablet .dataTables_wrapper,
body.ui-compact-mobile .dataTables_wrapper {
    font-size: 0.84rem;
}

body.ui-compact-desktop .dataTables_wrapper .dataTables_filter input,
body.ui-compact-desktop .dataTables_wrapper .dataTables_length select,
body.ui-compact-tablet .dataTables_wrapper .dataTables_filter input,
body.ui-compact-tablet .dataTables_wrapper .dataTables_length select,
body.ui-compact-mobile .dataTables_wrapper .dataTables_filter input,
body.ui-compact-mobile .dataTables_wrapper .dataTables_length select {
    height: calc(1.45em + .45rem + 2px);
    padding: .1rem .3rem;
    font-size: 0.8rem;
}

body.ui-compact-tablet .dataTables_wrapper .table,
body.ui-compact-mobile .dataTables_wrapper .table {
    width: 100% !important;
}

body.ui-compact-tablet .table-responsive,
body.ui-compact-mobile .table-responsive,
body.ui-compact-tablet .dataTables_wrapper,
body.ui-compact-mobile .dataTables_wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

body.ui-compact-mobile .dataTables_wrapper table.dataTable th,
body.ui-compact-mobile .dataTables_wrapper table.dataTable td {
    white-space: nowrap;
}

body.ui-compact-desktop .select2-container--bootstrap4 .select2-selection,
body.ui-compact-tablet .select2-container--bootstrap4 .select2-selection,
body.ui-compact-mobile .select2-container--bootstrap4 .select2-selection {
    min-height: calc(1.45em + .45rem + 2px);
    font-size: 0.82rem;
    padding-top: .1rem;
    padding-bottom: .1rem;
}

body.ui-compact-tablet .pagination .page-link,
body.ui-compact-mobile .pagination .page-link {
    padding: .2rem .45rem;
    font-size: 0.8rem;
}

/* Modo responsive sin deteccion por script */
@media (max-width: 1366px), (max-height: 760px) {
    body {
        font-size: 0.94rem;
    }
    .content-header h1 { font-size: 1.2rem; line-height: 1.2; }
    .card-title { font-size: 1rem; }
    .form-control, .custom-select, .input-group-text, .btn {
        font-size: 0.88rem;
        min-height: calc(1.5em + .5rem + 2px);
        padding-top: .2rem;
        padding-bottom: .2rem;
    }
    .nav-sidebar .nav-link, .main-header .nav-link { font-size: 0.88rem; }
    .dataTables_wrapper { font-size: 0.84rem; }
}

@media (max-width: 1024px) {
    body { font-size: 0.89rem; }
    .form-control, .custom-select, .input-group-text, .btn {
        font-size: 0.82rem;
        min-height: calc(1.45em + .45rem + 2px);
        padding-top: .15rem;
        padding-bottom: .15rem;
    }
    .table th, .table td { padding: .3rem .35rem; }
    .dataTables_wrapper .dataTables_filter input,
    .dataTables_wrapper .dataTables_length select {
        height: calc(1.45em + .45rem + 2px);
        padding: .1rem .3rem;
        font-size: 0.8rem;
    }
    .table-responsive, .dataTables_wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .select2-container--bootstrap4 .select2-selection {
        min-height: calc(1.45em + .45rem + 2px);
        font-size: 0.82rem;
        padding-top: .1rem;
        padding-bottom: .1rem;
    }
    .pagination .page-link {
        padding: .2rem .45rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 767px) {
    body { font-size: 0.84rem; }
    .dataTables_wrapper table.dataTable th,
    .dataTables_wrapper table.dataTable td {
        white-space: nowrap;
    }
}

@media (max-width: 767.98px) {
    body.sidebar-mini-md .content-wrapper,
    body.sidebar-mini-md .content-wrapper::before,
    body.sidebar-mini-md .main-footer,
    body.sidebar-mini-md .main-footer::before,
    body.sidebar-mini-md .main-header,
    body.sidebar-mini-md .main-header::before,
    body.sidebar-mini .content-wrapper,
    body.sidebar-mini .content-wrapper::before,
    body.sidebar-mini .main-footer,
    body.sidebar-mini .main-footer::before,
    body.sidebar-mini .main-header,
    body.sidebar-mini .main-header::before {
        margin-left: 0 !important;
    }

    /* Mobile app mode: sidebar off-canvas */
    .main-sidebar,
    .main-sidebar::before {
        margin-left: -250px !important;
        box-shadow: none !important;
    }

    body.sidebar-open .main-sidebar,
    body.sidebar-open .main-sidebar::before {
        margin-left: 0 !important;
    }
}
