body { background: #f5f6f8; color: #252b37; }
#notification { z-index: 1090; }
body:has(#workbench-debug) #notification { bottom: 34px !important; }
.user-identity { display: inline-flex; align-items: center; gap: .55rem; vertical-align: middle; }
.user-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.user-avatar-initials { display: inline-flex; align-items: center; justify-content: center; background: #e7edff; color: #3151a4; font-size: 12px; font-weight: 700; }
.user-avatar-preview .user-avatar { width: 64px; height: 64px; font-size: 22px; }
.app-shell { display: grid; grid-template-columns: 220px minmax(0, 1fr); min-height: calc(100vh - 58px); }
.app-shell.guest { display: block; }
.content-wrap { max-width: 1440px; margin: 0 auto; }
.card { border-color: #e4e7ec; border-radius: .65rem; }
.table > :not(caption) > * > * { padding: 1rem; }
.table-responsive { overflow-y: hidden; }
.table-responsive.planning-task-list { max-height: 420px; overflow: auto; }
.planning-task-list thead { position: sticky; top: 0; z-index: 1; }
.planning-task-list [data-task-sp-input] { min-width: 76px; }
.planning-task-list [data-task-assignee] { min-width: 150px; }
.sprint-detail-tasks form { min-width: 155px; }
.sprint-detail-tasks td:first-child { min-width: 220px; }
.sprint-goal { white-space: pre-wrap; }
.sprint-legend-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 7px; background: var(--legend-color); }
.sprint-donut { width: min(100%, 240px); }
.sprint-work-chart { width: 100%; height: auto; }
[data-sprint-detail] { padding-bottom: 32px; }
.table thead th { font-size: .78rem; letter-spacing: .02em; font-weight: 600; color: #667085; }
table[data-resource="worklogs"] :is(th,td):first-child { min-width: 125px; white-space: nowrap; }
table[data-resource="worklogs"] :is(th,td):nth-child(3) { min-width: 190px; }
table[data-resource="worklogs"] :is(th,td):nth-child(5) { min-width: 95px; white-space: nowrap; }
.auth-card { max-width: 470px; margin-top: clamp(1rem, 7vh, 5rem); }
.planning-member-list { max-height: 320px; overflow-y: auto; }
.planning-leave-column { width: 210px; }
.health-matrix { min-width: 700px; font-size: .8rem; }
.health-matrix th, .health-matrix td { padding: .7rem !important; text-align: center; }
.health-matrix th:first-child { text-align: left; }
.health-message { overflow-wrap: anywhere; }
[data-health-results] article { scroll-margin-top: 1rem; }
[aria-busy="true"] { opacity: .55; transition: opacity .12s; }
.modal-body [data-form-content] > h1 { display: none; }

/* Neutral shell and persistent, grouped navigation. */
[data-crud-actions-menu] { --bs-dropdown-padding-y: 0; --bs-dropdown-item-padding-y: .2rem; --bs-dropdown-item-padding-x: .75rem; --bs-dropdown-font-size: .8125rem; min-width: 8rem; }
[data-crud-actions-menu] li, [data-crud-actions-menu] form { margin: 0; padding: 0; }
[data-crud-actions-menu] .dropdown-item { margin: 0; min-height: 0; font-size: .8125rem; line-height: 1.4; padding: .2rem .75rem; }
[data-crud-actions-menu] .dropdown-divider { margin: 0; }
:root { --bs-primary: #315de6; --bs-primary-rgb: 49, 93, 230; --header-height: 58px; }
.app-header { height: var(--header-height); background: #212529; position: sticky; top: 0; z-index: 1030; }
.app-header .navbar-brand { color: #fff; font-size: 1.35rem; letter-spacing: .01em; }
.brand-descriptor { font-size: .95rem; font-weight: 400; color: #c8cdd5; margin-left: .25rem; }
.header-user { color: #d5d9df; font-size: .875rem; }
.app-header .btn-outline-secondary { --bs-btn-color: #d5d9df; --bs-btn-border-color: #6c757d; --bs-btn-hover-bg: #495057; }
.app-header > .ms-auto > a:not(.btn) { color: #d5d9df; }
.app-shell { grid-template-columns: 248px minmax(0, 1fr); min-height: calc(100dvh - var(--header-height)); }
.sidebar { position: sticky; top: var(--header-height); height: calc(100dvh - var(--header-height)); align-self: start; display: flex; flex-direction: column; padding-bottom: 36px !important; }
.sidebar-heading { padding: .25rem .65rem .85rem; font-size: .75rem; color: #667085; line-height: 1.5; flex-shrink: 0; }
.sidebar-heading strong { font-size: .95rem; font-weight: 600; color: #344054; }
.sidebar [data-main-navigation] { flex: 1; min-height: 0; flex-wrap: nowrap; overflow-y: auto; gap: 0 !important; }
.sidebar .nav-link { display: flex; align-items: center; gap: .55rem; padding: .4rem .65rem; border-radius: .35rem; font-size: .82rem; color: #485364; flex-shrink: 0; }
.sidebar .nav-link:hover { background: #f3f5f8; color: #244ac4; }
.sidebar .nav-link.active { background: #edf1ff; color: #244ac4; font-weight: 600; }
.nav-symbol { width: 1rem; text-align: center; }
.nav-group { margin-top: .8rem; flex-shrink: 0; }
.nav-group-heading { font-size: .65rem; font-weight: 700; color: #7a8493; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 .3rem; padding: 0 .65rem; }
.nav-group-links { border-left: 1px solid #e4e7ec; margin-left: .65rem; padding-left: .4rem; }
.sidebar .nav-settings { margin-top: auto; padding-top: .7rem; border-top: 1px solid #e4e7ec; border-radius: 0; }
.btn-primary { --bs-btn-bg: #315de6; --bs-btn-border-color: #315de6; }
.menu-toggle { display: none; color: #fff; }
[data-crud-filters] button { min-width: 80px; white-space: nowrap; }
@media (max-width: 991px) {
    .app-shell { grid-template-columns: minmax(0, 1fr); }
    .menu-toggle { display: inline-block; }
    .sidebar { display: none; position: fixed; top: var(--header-height); left: 0; bottom: 0; width: min(280px, 88vw); z-index: 1020; box-shadow: 12px 0 36px rgb(0 0 0 / 12%); }
    .menu-open .sidebar { display: flex; }
    .header-user .user-identity > span:last-child { display: none; }
}

/* Header: compact identity, page context and account actions. */
:root { --header-height: 76px; }
.app-header { background: #182231; border-bottom: 1px solid #344155; box-shadow: 0 2px 10px rgb(16 24 40 / 8%); }
.app-header .header-brand { display: flex; align-items: center; gap: .8rem; margin-right: 0; min-width: 224px; }
.brand-monogram { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid #6883b3; border-radius: 10px; background: #293d5d; color: #fff; font-size: 1.1rem; font-weight: 700; letter-spacing: -.03em; }
.brand-copy { display: flex; flex-direction: column; gap: .15rem; }
.brand-copy strong { font-size: 1.05rem; font-weight: 600; line-height: 1.2; }
.brand-copy small { color: #b4c1d3; font-size: .66rem; letter-spacing: .025em; }
.header-context { display: flex; flex-direction: column; gap: .15rem; border-left: 1px solid #3b4657; padding-left: 1.4rem; min-width: 0; margin-right: 1rem; }
.header-context span { color: #a6b5c9; font-size: .65rem; text-transform: uppercase; letter-spacing: .08em; }
.header-context strong { color: #eef2f8; font-size: .85rem; font-weight: 500; max-width: 36vw; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.header-user { padding: .4rem .7rem; border-radius: .55rem; }
.header-user:hover { background: #293547; color: #fff; }
.header-logout { color: #c0cbda; border: 1px solid #465268; border-radius: .5rem; width: 36px; height: 36px; display: grid; place-items: center; padding: 0; }
.header-logout:hover { color: #fff; background: #334156; border-color: #6d809b; }
.nav-symbol { color: #7b8798; width: 1.1rem; flex-shrink: 0; font-size: .85rem; }
.sidebar .nav-link.active .nav-symbol { color: #315de6; }
@media (max-width: 991px) {
    .header-context { display: none; }
    .app-header .header-brand { min-width: 0; }
}
@media (max-width: 480px) {
    .app-header { padding-left: .65rem !important; padding-right: .65rem !important; }
    .brand-monogram { width: 34px; height: 36px; font-size: .95rem; }
    .brand-copy small { font-size: .56rem; }
    .brand-copy strong { font-size: .9rem; }
    .app-header .header-brand { gap: .5rem; }
    .app-header > .ms-auto { gap: .4rem !important; }
    .header-user { padding: .3rem; }
}
.sidebar .nav-settings { position: sticky; bottom: 0; z-index: 1; background: #fff; box-shadow: 0 -6px 8px #fff; }

.crud-sort { color: inherit; text-decoration: none; display: inline-flex; align-items: center; gap: .2rem; padding: .2rem 0; }
.crud-sort:hover, .crud-sort.is-active { color: #244ac4; }
.crud-sort:focus-visible { outline: 2px solid #315de6; outline-offset: 4px; border-radius: 2px; }
.crud-sort:not(.is-active) > span { opacity: .45; }

.crud-record-link { color: var(--bs-link-color); text-decoration: none; font-weight: 400; }
.crud-record-link:hover { color: var(--bs-link-hover-color); text-decoration: underline; }
.crud-detail-value { white-space: pre-wrap; }
[data-crud-actions-menu] { z-index: 1060; min-width: 11rem; }

.modal-body [data-crud-detail] h1 { display: none; }

.crud-detail-table > tbody > tr > th { width: 34%; min-width: 140px; font-size: .875rem; }
.crud-detail-table > tbody > tr > * { padding: .85rem 1rem; }
.crud-detail-table > tbody > tr:last-child > * { border-bottom: 0; }
.crud-detail-table { --bs-table-striped-bg: #f5f7fa; }
.crud-detail-table td { overflow-wrap: anywhere; }

.worklog-task-label { display: inline-block; max-width: min(320px, 40vw); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; text-align: left; }
