/* =========================
   APPLICATION DRAWERS
   Purpose: shared application-shell treatment for the navigation and notification
   drawers (offcanvas panels) and their launcher buttons, plus the navigation drawer
   content rendered by the shared NavigationDrawerContent component.
   Served from BlazorComponentsLibrary as _content/BlazorComponentsLibrary/css/app-drawer.css.
   These rules are global (not scoped) because the drawer markup is split between the
   shared component and each host's offcanvas wrapper.
   ========================= */

.app-drawer.offcanvas {
    --app-drawer-accent: var(--color-teal, #008080);
    --app-drawer-surface: #f4f7f7;
    --app-drawer-border: rgba(20, 65, 65, 0.16);
    top: 0;
    bottom: 0;
    height: auto;
    width: min(25rem, calc(100vw - 1.5rem));
    overflow: hidden;
    color: var(--bs-body-color);
    background: var(--app-drawer-surface);
    border: 1px solid var(--app-drawer-border) !important;
    border-radius: var(--bs-border-radius);
    box-shadow: 0 1.25rem 3.5rem rgba(18, 54, 54, 0.2);
}

.app-drawer.offcanvas-start {
    left: 0;
}

.app-drawer.offcanvas-end {
    right: 0;
}

.app-drawer__header {
    min-height: 5rem;
    padding: 1rem 1.1rem;
    background:
        radial-gradient(circle at 12% 0%, rgba(0, 128, 128, 0.14), transparent 48%),
        rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid var(--app-drawer-border);
}

.app-drawer__heading {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 0.8rem;
}

.app-drawer .min-w-0 {
    min-width: 0;
}

.app-drawer__icon {
    display: inline-flex;
    width: 2.6rem;
    height: 2.6rem;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    color: var(--app-drawer-accent);
    background: rgba(0, 128, 128, 0.11);
    border: 1px solid rgba(0, 128, 128, 0.16);
    border-radius: 0.85rem;
    font-size: 1.05rem;
}

.app-drawer__eyebrow {
    overflow: hidden;
    color: var(--bs-secondary-color);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    line-height: 1.2;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.app-drawer__title {
    margin: 0.1rem 0 0;
    color: #174646;
    font-size: 1.12rem;
    font-weight: 750;
    line-height: 1.25;
}

.app-drawer__close {
    width: 2.35rem;
    height: 2.35rem;
    flex: 0 0 auto;
    padding: 0.65rem;
    background-color: rgba(23, 70, 70, 0.08);
    border-radius: 50%;
    box-shadow: none;
}

.app-drawer__close:focus-visible,
.drawer-launcher:focus-visible {
    outline: 0.2rem solid rgba(0, 128, 128, 0.28);
    outline-offset: 0.15rem;
    box-shadow: none;
}

.app-drawer__body {
    scrollbar-color: rgba(0, 128, 128, 0.3) transparent;
}

.app-drawer__footer {
    background: rgba(255, 255, 255, 0.94);
    border-top: 1px solid var(--app-drawer-border);
}

.drawer-launcher {
    position: relative;
    display: inline-flex;
    width: 2.8rem;
    height: 2.8rem;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    padding: 0;
    color: #315b5b;
    background: #fff;
    border: 1px solid rgba(20, 65, 65, 0.18);
    border-radius: 50%;
    box-shadow: 0 0.25rem 0.8rem rgba(18, 54, 54, 0.09);
    transition: color 150ms ease, background-color 150ms ease, border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.drawer-launcher:hover {
    color: var(--color-teal, #008080);
    background: #f1f9f9;
    border-color: rgba(0, 128, 128, 0.38);
    box-shadow: 0 0.4rem 1rem rgba(18, 54, 54, 0.14);
    transform: translateY(-1px);
}

.drawer-launcher:active {
    transform: translateY(0);
}

.drawer-launcher__icon {
    font-size: 1.15rem;
    line-height: 1;
}

.drawer-launcher__spinner {
    width: 1.15rem;
    height: 1.15rem;
    border-width: 0.14rem;
}

.drawer-launcher__badge {
    position: absolute;
    top: -0.32rem;
    right: -0.4rem;
    display: inline-flex;
    min-width: 1.35rem;
    height: 1.35rem;
    align-items: center;
    justify-content: center;
    padding: 0 0.28rem;
    color: #fff;
    background: #6c757d;
    border: 2px solid #fff;
    border-radius: 999px;
    font-size: 0.66rem;
    font-weight: 800;
    line-height: 1;
}

.drawer-launcher--today {
    color: var(--bs-success);
    background: var(--bs-success-bg-subtle);
    border-color: var(--bs-success-border-subtle);
}

.drawer-launcher--today .drawer-launcher__badge {
    background: var(--bs-success);
}

.drawer-launcher--upcoming {
    color: #8a6500;
    background: var(--bs-warning-bg-subtle);
    border-color: var(--bs-warning-border-subtle);
}

.drawer-launcher--upcoming .drawer-launcher__badge {
    color: #332701;
    background: var(--bs-warning);
}

@media (max-width: 575.98px) {
    .app-drawer.offcanvas {
        width: calc(100vw - 0.7rem);
    }
}

@media (prefers-reduced-motion: reduce) {
    .drawer-launcher {
        transition: none;
    }
}


/* =========================
   NAVIGATION DRAWER
   Purpose: navigation drawer launcher, account panel, filter, accordion sections and footer links.
   ========================= */

.navigation-drawer-launcher {
    margin-inline-end: 0.75rem;
}

.navigation-drawer {
    width: min(26rem, calc(100vw - 1.5rem));
}

.navigation-account-panel {
    padding: 0.8rem;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(20, 65, 65, 0.12);
}

.navigation-account,
.navigation-login {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.65rem;
    color: #294d4d;
    background: #f3f8f8;
    border: 1px solid rgba(0, 128, 128, 0.14);
    border-radius: 0.95rem;
    text-decoration: none;
}

.navigation-account__profile {
    display: flex;
    min-width: 0;
    flex: 1;
    align-items: center;
    gap: 0.7rem;
    color: inherit;
    text-decoration: none;
}

.navigation-account__profile:hover,
.navigation-login:hover {
    color: var(--color-teal, #008080);
}

.navigation-account__icon {
    display: inline-flex;
    width: 2.4rem;
    height: 2.4rem;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    color: var(--color-teal, #008080);
    background: #fff;
    border: 1px solid rgba(0, 128, 128, 0.16);
    border-radius: 0.8rem;
}

.navigation-account__copy {
    display: flex;
    min-width: 0;
    flex: 1;
    flex-direction: column;
}

.navigation-account__label {
    color: var(--bs-secondary-color);
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    line-height: 1.2;
    text-transform: uppercase;
}

.navigation-account__email {
    overflow: hidden;
    font-size: 0.9rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.navigation-account__chevron {
    color: rgba(41, 77, 77, 0.45);
    font-size: 0.74rem;
}

.navigation-account__logout {
    display: inline-flex;
    width: 2.35rem;
    height: 2.35rem;
    align-items: center;
    justify-content: center;
    padding: 0;
    color: var(--bs-danger);
    background: #fff;
    border: 1px solid var(--bs-danger-border-subtle);
    border-radius: 0.75rem;
    transition: color 150ms ease, background-color 150ms ease;
}

.navigation-account__logout:hover {
    color: #fff;
    background: var(--bs-danger);
}

.navigation-account__logout:focus-visible,
.navigation-account__profile:focus-visible,
.navigation-login:focus-visible {
    outline: 0.2rem solid rgba(0, 128, 128, 0.24);
    outline-offset: 0.15rem;
}

.navigation-drawer__body {
    padding: 0.45rem 0 !important;
    background: #f4f7f7;
}

.navigation-drawer [hidden] {
    display: none !important;
}

.navigation-filter-panel {
    padding: 0.75rem 0.8rem;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(20, 65, 65, 0.12);
}

.navigation-filter {
    display: flex;
    min-height: 2.85rem;
    align-items: center;
    gap: 0.65rem;
    padding: 0 0.7rem 0 0.85rem;
    background: #f7fafa;
    border: 1px solid rgba(20, 65, 65, 0.16);
    border-radius: 0.85rem;
    transition: background-color 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}

.navigation-filter:focus-within {
    background: #fff;
    border-color: rgba(0, 128, 128, 0.48);
    box-shadow: 0 0 0 0.2rem rgba(0, 128, 128, 0.11);
}

.navigation-filter__icon {
    flex: 0 0 auto;
    color: rgba(41, 77, 77, 0.58);
    font-size: 0.9rem;
}

.navigation-filter__input {
    min-width: 0;
    flex: 1;
    padding: 0;
    color: #294d4d;
    background: transparent;
    border: 0;
    outline: 0;
    font-size: 0.92rem;
    font-weight: 600;
}

.navigation-filter__input::placeholder {
    color: rgba(41, 77, 77, 0.58);
    font-weight: 500;
}

.navigation-filter__input::-webkit-search-cancel-button {
    display: none;
}

.navigation-filter__clear {
    display: inline-flex;
    width: 1.8rem;
    height: 1.8rem;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    padding: 0;
    color: #466262;
    background: rgba(20, 65, 65, 0.07);
    border: 0;
    border-radius: 50%;
    font-size: 0.78rem;
}

.navigation-filter__clear:hover,
.navigation-filter__clear:focus-visible {
    color: #075f5f;
    background: rgba(0, 128, 128, 0.13);
}

.navigation-filter__clear:focus-visible {
    outline: 0.16rem solid rgba(0, 128, 128, 0.24);
    outline-offset: 0.1rem;
}

.navigation-filter-empty {
    min-height: 9rem;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 0.65rem;
    color: var(--bs-secondary-color);
    font-size: 0.92rem;
    font-weight: 650;
}

.navigation-filter-empty:not([hidden]) {
    display: flex;
}

.navigation-filter-empty > i {
    color: rgba(0, 128, 128, 0.52);
    font-size: 1.65rem;
}

.navigation-drawer .accordion,
.navigation-drawer .accordion-item {
    background: transparent;
}

.navigation-drawer .accordion-item {
    overflow: hidden;
    margin: 0.45rem 0.75rem;
    border: 1px solid rgba(20, 65, 65, 0.1);
    border-radius: 0.9rem;
    box-shadow: 0 0.25rem 0.8rem rgba(18, 54, 54, 0.045);
}

.navigation-drawer .accordion-button {
    min-height: 3.25rem;
    padding: 0.8rem 0.95rem;
    color: #365a5a;
    background: #fff;
    box-shadow: none;
    font-size: 0.95rem;
}

.navigation-drawer .accordion-button:not(.collapsed) {
    color: #075f5f;
    background: #eaf5f5;
    box-shadow: inset 0.22rem 0 var(--color-teal, #008080);
}

.navigation-drawer .accordion-button:focus-visible {
    outline: 0.2rem solid rgba(0, 128, 128, 0.23);
    outline-offset: -0.2rem;
    box-shadow: none;
}

.navigation-drawer .accordion-button > i,
.navigation-drawer .list-group-item > i {
    width: 1.25rem;
    color: var(--color-teal, #008080);
    text-align: center;
}

.navigation-drawer .accordion-body {
    padding: 0.35rem !important;
    background: rgba(255, 255, 255, 0.76);
    border-top: 1px solid rgba(20, 65, 65, 0.08);
}

.navigation-drawer .accordion-body .list-group-item {
    margin: 0.12rem 0;
    padding: 0.65rem 0.8rem;
    color: #466262;
    background: transparent;
    border-radius: 0.65rem;
    font-size: 0.88rem;
}

.navigation-drawer .accordion-body .list-group-item:hover,
.navigation-drawer .accordion-body .list-group-item:focus-visible {
    color: #075f5f;
    background: rgba(0, 128, 128, 0.08);
}

.navigation-drawer__body > .accordion > .list-group {
    overflow: hidden;
    margin: 0.45rem 0.75rem;
    border: 1px solid rgba(20, 65, 65, 0.1);
    border-radius: 0.9rem;
}

.navigation-drawer__body > .accordion > .list-group .list-group-item {
    padding: 0.85rem 0.95rem;
    color: #365a5a;
    background: #fff;
}

.navigation-drawer hr {
    margin: 0.45rem 0.75rem !important;
    color: rgba(20, 65, 65, 0.15);
}

.drawer-sub-divider {
    height: 1px;
    margin: 0.25rem 0.75rem;
    background: linear-gradient(to right, transparent, rgba(0, 128, 128, 0.2), transparent);
    border: 0;
}

.navigation-drawer__footer {
    padding: 0.45rem !important;
}

.navigation-footer-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.2rem;
}

.navigation-footer-links .list-group-item {
    min-width: 0;
    padding: 0.55rem 0.65rem;
    overflow: hidden;
    color: var(--bs-secondary-color);
    background: transparent;
    border-radius: 0.65rem;
    font-size: 0.8rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.navigation-footer-links .list-group-item:hover,
.navigation-footer-links .list-group-item:focus-visible {
    color: #075f5f;
    background: rgba(0, 128, 128, 0.08);
}

@media (max-width: 575.98px) {
    .navigation-drawer {
        width: calc(100vw - 0.7rem);
    }
}

@media (prefers-reduced-motion: reduce) {
    .navigation-account__logout,
    .navigation-filter {
        transition: none;
    }
}
