/* 
    Import reset rules for compatibility with MDB (Material Design for Bootstrap) 
        
    Copyright (c) 2024, Mapache Digital
*/

@import url("mdb.css");

html {
    /* Reset the base font size.  This will equal to 1 rem. */
    font-size: 12px;
}

@media (max-width: 575px) {
    .footer {
        line-height: 42px;
        height: 50px;
        overflow: hidden;
    }

    body {
        margin-bottom: 42px;
    }
}

@media (min-width: 768px) {
    html {
        /* Reset the base font size.  This will equal to 1 rem. */
        font-size: 14px;
    }
}

@media (max-width: 989px) {
    /* Make better use of real state on smaller screens when using bootstrap containers */
    .container {
        max-width: 95% !important;
    }
}

.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: 60px;
}

/* -------------------------------------------------
   Site specific
   -------------------------------------------------- */

/* For showing long descriptions nicely. Place the text inside a <span> to avoid new lines. */
.long-description {
    white-space: pre-wrap;
    display: inline-block;
}

.long-description-container {
    max-height: 6.25rem;
    overflow: hidden;
}

/* For showing resized thumbnails */
.thumbnail {
    padding: 10px;
    text-align: end;
}

    .thumbnail .image {
    }

        .thumbnail .image img {
            border-radius: 3px;
            height: 90px;
            width: 100%;
            object-fit: cover;
        }

    .thumbnail .caption {
        padding: 4px;
        text-align: center;
        margin-top: 4px;
    }

        .thumbnail .caption span {
            font-size: smaller;
            overflow: hidden;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
        }

    .thumbnail .button {
        color: rgba(150, 150, 150, 0.6);
        padding: 4px;
        position: relative;
        top: -91px;
    }

        .thumbnail .button i {
            font-size: 28px;
        }


/* General styles */
.roboto {
    font-family: 'Roboto', sans-serif;
}

.bebas {
    font-family: 'Bebas Neue', cursive;
}

.anton {
    font-family: 'Anton', sans-serif;
}

.work-sans {
    font-family: 'Work Sans', sans-serif;
}

.font-size-medium {
    font-size: 1rem !important;
}

.body-container {
    margin-bottom: 61px;
    margin-top: 54px;
    padding-top: 1rem;
}

@media (max-width: 575px) {
    .body-container {
        margin-bottom: 43px;
    }
}

/* Navbar */
.navbar .logo-top {
    height: 30px;
}

/* For the tasks */
.tasks-list .closed td {
    text-decoration: line-through;
    opacity: 0.35;
    background-color: rgba(220,220,220,0.3);
}

.tasks-list .closed a {
    color: var(--bs-body-color);
}

.tasks-list .draft td {
    opacity: 0.667;
    background-color: rgba(220,220,220,0.3);
}

.tasks-list .priorityLow td {
    background-color: rgba(175,238,238,0.35);
}

.tasks-list .priorityNormal td {
    /* Green */
    background-color: rgba(152,251,152,0.35);
}

.tasks-list .priorityHigh td {
    /* Yellow */
    background-color: rgba(255,245,0,0.3);
}

.tasks-list .priorityUrgent td {
    /* Orange */
    background-color: rgba(255,165,0,0.3);
}

.tasks-list .priorityImmediate td {
    /* Red */
    background-color: rgba(220,20,60,0.25);
}

.content-feat {
    background: #f6f6f6;
    border-radius: 10px;
}

/* Add a margin below a form control whenever there are a span for validation errors.*/
.form-control:has(~ span.text-danger) {
    margin-bottom: 0.25rem;
}

.form-control.disabled, .form-control.disabled:focus {
    background-color: var(--bs-secondary-bg);
    opacity: 1;
}

    .form-control.disabled:focus {
        box-shadow: 0 0 0 0.1rem var(--bs-secondary-color);
    }

.table-badge {
    position: absolute;
    z-index: 1;
    overflow: hidden;
    width: 35px;
    height: 35px;
    margin: -12px -16.8px;
}

    .table-badge .table-badge-content {
        position: absolute;
        text-transform: uppercase;
        font-weight: bold;
        font-size: 0.5em;
        transform: rotate(-45deg) translate(-27%,-27%);
        text-align: center;
        min-width: 48px;
        padding: 3px 4px;
        line-height: 1;
    }

    .table-badge .table-badge-overdue {
        background-color: rgb(178, 34, 34);
        color: white;
    }

    .table-badge .table-badge-pending {
        background-color: rgb(255, 206, 59);
        color: black;
    }

@media (min-width: 768px) {
    .table-badge {
        margin: -14px -19.35px;
    }

        .table-badge .table-badge-content {
            transform: rotate(-45deg) translate(-29%,-27%);
            min-width: 51px;
            font-size: 0.45em;
        }
}

.entity-number {
    z-index: 9;
    position: relative;
}

.dropzone {
    background: var(--bs-body-bg) !important;
    border-radius: var(--bs-border-radius) !important;
    border: var(--bs-border-width) solid var(--bs-border-color) !important;
}

    .dropzone .dz-preview.dz-image-preview {
        background: var(--bs-body-bg) !important;
    }

a.disabled, span.disabled {
    pointer-events: none;
    color: var(--bs-secondary);
}

/* Dark mode settings */
@media (prefers-color-scheme: dark) {
    .content-feat {
        background: #313131;
    }

    .tasks-list tbody a {
        /*color: rgb(4,17,72);*/
        color: rgb(0,1,85);
    }

    .tasks-list .priorityImmediate td {
        /* Red */
        background-color: rgba(255,64,102,0.45);
    }

    .tasks-list .priorityUrgent td {
        /* Orange */
        background-color: rgba(255,165,0,0.45);
    }

    .tasks-list .priorityHigh td {
        /* Yellow */
        background-color: rgba(255,245,0,0.45);
    }

    .tasks-list .priorityNormal td {
        /* Green */
        background-color: rgba(152,251,152,0.4);
    }

    .tasks-list .priorityLow td {
        /* Blue */
        background-color: rgba(175,238,238,0.3);
    }

    .table > :not(caption) > * > * {
        color: rgb(var(--bs-body-color-rgb)) !important;
    }
}
