


.card {
    color: var(--CI-grey);
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
    font-size: 10pt;
}

input{
    border-radius: 0.25rem;
    border: 0px;
    /* font-size: 16pt; */
    padding: .5rem 1rem;
    border:1px solid rgb(204,204,204);
    background-color: white;
}

.page {
    display: flex;
    width: 100%;
    height: 100vh;   /* lock the shell to the viewport */
    height: 100dvh;  /* visible viewport on phones with a collapsing browser bar */
    overflow: hidden; /* only .content scrolls — never the document */
}

.sidebar {
    min-width: 70px;
    width: max-content; /* grow with the widest label of the active language (#201) */
    flex-shrink: 0;     /* a wide .content must not squeeze the labels */
    padding: 4px;
    height: 100%;    /* fill the page shell exactly */
    padding-top: 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    color: #f0f0f0 !important;
    background-color: white;
    font-size: 10pt;
    display: flex;
    flex-direction: column;
    overflow-y: hidden; /* clip if nav somehow grows beyond shell */
    overflow-x: hidden; /* never a horizontal scrollbar (#201) */
}

.sidebar ul {
    margin: 0px;
    padding: 0px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.sidebar a {
    color: var(--CI-grey);
    ;
    text-decoration: none;
}

.sidebar a.current {
    color: var(--CI-blue);
    text-decoration: none;
}

.sidebar a:hover {
    color: var(--CI-blue);
    transition: color 0.1s ease-in-out;
}

.hover:hover {
    color: var(--CI-blue);
    transition: color 0.1s ease-in-out;
}

.sidebar li {
    display: block;
    /* padding: 20px 15px; */
    text-align: center;
    text-decoration: none;
    display: flex;
    flex-direction: column;
}

.sidebar .nav-link:hover {
    /* background-color: #c6d2df; */
}


.sidebar i {
    font-size: 20pt;
}

/* Unread notifications on the bell (#36) */
.sidebar .nav-icon {
    position: relative;
    display: inline-block;
}

.sidebar .nav-badge {
    position: absolute;
    top: -4px;
    right: -10px;
    min-width: 18px;
    padding: 1px 5px;
    border-radius: 9px;
    background: #dc3545;
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    line-height: 16px;
}

/* Sidebar header */
.sidebar-header {
    text-align: center;
    margin-bottom: 50px;
}

/* Organization logo/name from /manage/organization/ (#56) */
.org-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-top: 12px;
    max-width: 90px;
    margin-left: auto;
    margin-right: auto;
}

.org-brand img {
    max-width: 70px;
    max-height: 40px;
    object-fit: contain;
}

.org-brand__name {
    font-size: 0.7rem;
    line-height: 1.2;
    color: var(--CI-grey);
    overflow-wrap: anywhere;
}


/* Content grows while keeping footer at bottom */
.main {
    display: flex;
    flex-direction: column;
    width: 100%;
    flex-grow: 1;
    height: 100%;    /* fill the page shell */
    overflow: hidden;
}

.content {
    flex-grow: 1;
    min-height: 0;    /* allow shrinking inside the flex column so it scrolls, not the page */
    padding: 20px;
    overflow-y: auto; /* the ONE scrollable area */
}

/* Footer */
footer {
    flex-shrink: 0;   /* never squeezed out by long content (#196) */
    background-color: #f8f9fa;
    padding: 3px 10px;
    text-align: center;
    width: 100%;
    font-size: 10pt;
    line-height: 1.3;
}

footer p {
    margin: 0;
}

/* Unread count next to "Notifications" in the user menu (#185) */
.dropdown-menu .dropdown-badge {
    display: inline-block;
    margin-left: 6px;
    min-width: 18px;
    padding: 1px 5px;
    border-radius: 9px;
    background: #dc3545;
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    line-height: 16px;
    text-align: center;
}

/* Basic styling for the dropdown */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    display: none;    
    background-color: white;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
    min-width: 300px;
    left: 16px;
    bottom: 16px;
    font-size: 14px;
    position: fixed !important;
}

.dropdown-menu .dropdown-item {
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    color: black;
}

.dropdown-menu .dropdown-title {
    font-size: 16px;
    color: var(--CI-grey);
    font-weight: bold;
}

.dropdown-menu .dropdown-item.hover:hover {
    background-color: #f1f1f1;
}

.dropdown-menu .dropdown-divider {
    height: 1px !important;
    background-color: #e0e0e0;
    margin: 8px 0;
}

.dropdown-toggle {
    /* cursor: pointer; */
    color: var(--CI-grey);
}

select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-color: white;
    border: 1px solid #ccc;
    padding: 8px;
    font-size: 16px;
}

@media only screen and (max-width: 768px) {
    .sidebar img{
        height: 48px;
    }
    .page {
        flex-direction: column;
        /* #210: the page scrolls normally; the footer is the last thing in the flow, not fixed over the content */
        height: auto;
        min-height: 100vh;
        min-height: 100dvh;
        flex: 0 0 auto;  /* don't shrink to the body's height, or the sticky menu would scroll away */
        overflow: visible;
    }

    .sidebar {
        position: sticky;  /* menu stays reachable (#196) while the page scrolls */
        top: 0;
        flex-direction: row;
        flex-shrink: 0;
        width: 100%;
        height: auto;
        min-height: 70px;
        max-height: 40dvh;  /* a wrapped menu must not squeeze .content away */
        z-index: 3;
        flex-wrap: wrap;
        overflow-y: auto;
        padding: 4px;
        font-size: 8pt;
    }

    .main {
        height: auto;
        flex: 1 0 auto;  /* grows to push the footer down on short pages */
        overflow: visible;
    }
    
    .sidebar-header {
        text-align: center;
        margin-bottom: 0px;
        margin-right: 10px;
    }

    .sidebar li{
        flex-direction: row;
        padding: 8px 8px;
        max-width: 70px;
    }
    .sidebar i {
        font-size: 20pt;
    }

    .sidebar ul{
        display: flex;
        flex-direction: row;
        gap: 10px;
    }

    .dropdown-toggle{
        max-height: 70px;
    }

    .content{
        margin-left: 0px;
        padding: 5px ;
        flex-grow: 1;
        overflow: visible;  /* the page scrolls, not .content (#210) */
    }

    .main{
        padding: 0px;
    }
}

/* Printing: release the viewport lock so all pages print (#196) */
@media print {
    .page, .main, .content {
        height: auto;
        overflow: visible;
    }
}

/* ── Very small phones: keep nav in one row, no wrapping ────────── */
@media only screen and (max-width: 480px) {
    .sidebar ul        { gap: 4px; }
    .sidebar li        { max-width: 52px; padding: 6px 4px; }
    .sidebar i         { font-size: 15pt; }
    .sidebar .label    { font-size: 6pt; }
    .sidebar-header    { margin-right: 6px; }
    .sidebar-header img { height: 36px !important; }

    /* Dropdown: never wider than the viewport */
    .dropdown-menu {
        min-width: min(300px, calc(100vw - 2rem));
        max-width: calc(100vw - 2rem);
    }
}
/* A closure (#31) covers this day: shown on the overview and upcoming bookings. */
.closure-notice {
    margin: 0 0 8px;
    padding: 6px 10px;
    border: 1px solid #f5c2c7;
    border-radius: 6px;
    background: #fff5f5;
    color: #842029;
    font-size: 0.9em;
}
