:root {
    --navy: #06172a;
    --navy2: #0b223b;
    --blue: #2f73e5;
    --blue2: #eaf2ff;
    --green: #2dab80;
    --green2: #eaf8f3;
    --red: #d9505c;
    --red2: #fff0f1;
    --ink: #172030;
    --muted: #718096;
    --line: #e2e8f0;
    --soft: #f6f8fb;
    --white: #fff;
    --shadow: 0 8px 28px rgba(20, 40, 70, .09);
    --sidebar: 238px
}

* {
    box-sizing: border-box
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #eef2f7;
    color: var(--ink)
}

button,
input,
select {
    font: inherit
}

button {
    cursor: pointer
}

.hidden {
    display: none !important
}

.app-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: var(--sidebar) minmax(0, 1fr)
}

.app-shell.sidebar-collapsed {
    grid-template-columns: 76px minmax(0, 1fr)
}

.sidebar {
    height: 100vh;
    position: sticky;
    top: 0;
    padding: 22px 16px 18px;
    display: flex;
    flex-direction: column;
    background: radial-gradient(circle at 15% 0, rgba(52, 119, 239, .18), transparent 25%), linear-gradient(180deg, #06172a, #081a2c);
    color: #fff;
    overflow: hidden;
    z-index: 20
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 4px 28px;
    white-space: nowrap
}

.brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(145deg, #3c82f2, #1d59c8);
    display: grid;
    place-items: center;
    position: relative;
    box-shadow: 0 8px 20px rgba(34, 102, 225, .28);
    flex: 0 0 auto
}

.brand-mark span {
    position: absolute;
    width: 16px;
    height: 3px;
    border-radius: 99px;
    background: #fff
}

.brand-mark span:nth-child(1) {
    transform: translateY(-5px)
}

.brand-mark span:nth-child(2) {
    width: 11px
}

.brand-mark span:nth-child(3) {
    width: 7px;
    transform: translateY(5px)
}

.brand strong {
    display: block;
    font-size: 15px
}

.brand small {
    display: block;
    font-size: 10px;
    color: #ffffff88;
    margin-top: 2px
}

.nav-list {
    display: grid;
    gap: 7px
}

.nav-item {
    height: 43px;
    padding: 0 13px;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: #ffffffb3;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    font-size: 12px;
    position: relative;
    white-space: nowrap
}

.nav-item:hover {
    background: #ffffff0d;
    color: #fff
}

.nav-item.active {
    background: rgba(66, 118, 191, .15);
    color: #77aaff
}

.nav-item.active:before {
    content: "";
    position: absolute;
    left: -8px;
    width: 3px;
    height: 22px;
    border-radius: 99px;
    background: #4386f4
}

.nav-icon {
    width: 20px;
    text-align: center;
    font-size: 16px
}

.sidebar-footer {
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid #ffffff14;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap
}

.avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, #347af0, #1c59c9);
    font-weight: 800;
    font-size: 11px;
    flex: 0 0 auto
}

.avatar.small {
    width: 33px;
    height: 33px
}

.profile-copy {
    flex: 1
}

.profile-copy strong,
.profile-copy span {
    display: block
}

.profile-copy strong {
    font-size: 11px
}

.profile-copy span {
    font-size: 9px;
    color: #ffffff77;
    margin-top: 3px
}

.icon-button {
    width: 34px;
    height: 34px;
    border: 1px solid #ffffff18;
    border-radius: 9px;
    background: #ffffff0a;
    color: inherit;
    display: grid;
    place-items: center
}

.app-shell.sidebar-collapsed .brand>div:last-child,
.app-shell.sidebar-collapsed .nav-item span:last-child,
.app-shell.sidebar-collapsed .profile-copy {
    display: none
}

.app-shell.sidebar-collapsed .nav-item {
    justify-content: center;
    padding: 0
}

.app-shell.sidebar-collapsed #sidebarCollapse {
    display: none
}

.main-shell {
    min-width: 0
}

.topbar {
    min-height: 76px;
    padding: 12px 28px;
    display: flex;
    align-items: center;
    gap: 18px;
    background: #ffffffee;
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 10
}

.topbar-title {
    display: grid;
    gap: 2px;
    min-width: 180px
}

.topbar-title span {
    font-size: 10px;
    color: var(--muted)
}

.topbar-title strong {
    font-size: 16px
}

.topbar-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px
}

.date-control {
    display: flex;
    align-items: center;
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 11px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 2px 8px rgba(20, 40, 70, .04)
}

.date-control>button {
    border: 0;
    background: #fff;
    color: #263244;
    height: 40px
}

.date-control>button:first-child,
.date-control>button:last-child {
    width: 32px;
    font-size: 18px
}

.date-control>button:nth-child(2) {
    min-width: 142px;
    display: grid;
    place-items: center
}

.date-control span {
    font-size: 11px;
    font-weight: 700
}

.date-control small {
    display: block;
    font-size: 8px;
    color: var(--muted);
    margin-top: 1px
}

.date-control input {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none
}

.bell {
    background: #fff;
    color: #42516a;
    border-color: var(--line);
    position: relative
}

.bell i {
    width: 6px;
    height: 6px;
    background: var(--blue);
    border-radius: 50%;
    position: absolute;
    right: 6px;
    top: 6px;
    box-shadow: 0 0 0 2px #fff
}

.user-chip {
    min-height: 42px;
    padding: 4px 10px 4px 5px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    display: flex;
    align-items: center;
    gap: 8px
}

.user-chip>span:last-child {
    display: grid;
    text-align: left
}

.user-chip strong {
    font-size: 10px
}

.user-chip small {
    font-size: 8px;
    color: var(--muted);
    margin-top: 2px
}

.mobile-menu {
    display: none
}

.content-area {
    padding: 28px;
    max-width: 1480px;
    margin: 0 auto
}

.page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px
}

.page-header h1 {
    margin: 0;
    font-size: 24px;
    letter-spacing: -.035em
}

.page-header p {
    margin: 6px 0 0;
    color: var(--muted);
    font-size: 12px
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(260px, .72fr);
    gap: 20px
}

.stat-grid {
    grid-column: 1/-1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px
}

.stat-card,
.panel {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: 0 2px 8px rgba(20, 40, 70, .04)
}

.stat-card {
    padding: 15px 16px;
    min-height: 92px
}

.stat-card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--muted);
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: .04em
}

.stat-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: #f5f9ff;
    color: var(--blue);
    display: grid;
    place-items: center
}

.stat-value {
    margin-top: 10px;
    font-size: 23px;
    font-weight: 800;
    letter-spacing: -.04em
}

.stat-sub {
    margin-top: 4px;
    color: var(--muted);
    font-size: 9px
}

.mini-progress {
    height: 4px;
    border-radius: 99px;
    background: #edf1f6;
    overflow: hidden;
    margin-top: 8px
}

.mini-progress span {
    display: block;
    height: 100%;
    background: var(--green)
}

.panel {
    overflow: hidden
}

.panel-header {
    min-height: 48px;
    padding: 13px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--line)
}

.panel-header strong {
    font-size: 12px
}

.panel-header small {
    font-size: 9px;
    color: var(--muted)
}

.panel-body {
    padding: 16px
}

.link-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--blue);
    font-size: 10px;
    font-weight: 700
}

.timeline {
    position: relative
}

.timeline:before {
    content: "";
    position: absolute;
    top: 14px;
    bottom: 16px;
    left: 20px;
    width: 1px;
    background: #d4dde9
}

.timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 14px;
    min-height: 76px
}

.timeline-marker {
    display: flex;
    justify-content: center
}

.timeline-dot {
    width: 10px;
    height: 10px;
    margin-top: 16px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: #9bb8e6;
    box-shadow: 0 0 0 2px #9bb8e6;
    z-index: 1
}

.timeline-dot.completed {
    background: var(--green);
    box-shadow: 0 0 0 2px #2dab8030
}

.timeline-dot.in_progress {
    background: var(--blue);
    box-shadow: 0 0 0 3px #2f73e530
}

.timeline-dot.overdue {
    background: var(--red);
    box-shadow: 0 0 0 2px #d9505c30
}

.timeline-card {
    width: 100%;
    margin-bottom: 10px;
    padding: 12px 13px;
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    border: 1px solid var(--line);
    border-left: 3px solid #4d83dd;
    border-radius: 8px;
    background: #fff;
    text-align: left;
    color: inherit
}

.timeline-card:hover {
    border-color: #c5d4e6;
    box-shadow: 0 8px 22px rgba(21, 41, 70, .08);
    transform: translateY(-1px)
}

.timeline-time {
    font-size: 11px;
    font-weight: 800
}

.timeline-main strong {
    display: block;
    font-size: 11px
}

.timeline-main p {
    margin: 3px 0 0;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.4
}

.task-meta {
    margin-top: 7px;
    display: flex;
    gap: 6px;
    flex-wrap: wrap
}

.meta-pill {
    min-height: 20px;
    padding: 3px 7px;
    border-radius: 5px;
    background: #f5f9ff;
    border: 1px solid #e2ebf9;
    color: #4772b5;
    font-size: 8px;
    font-weight: 700;
    display: inline-flex;
    align-items: center
}

.meta-pill.category {
    color: #42516a;
    background: #f7f8fa;
    border-color: #ebedf1
}

.status-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    border: 2px solid #d8e2ef;
    color: var(--muted);
    font-size: 8px;
    font-weight: 800
}

.status-circle.completed {
    border-color: var(--green);
    color: #238c69;
    background: var(--green2)
}

.status-circle.in_progress {
    border-color: var(--blue);
    color: var(--blue);
    background: #f4f8ff
}

.status-circle.overdue {
    border-color: var(--red);
    color: var(--red);
    background: var(--red2)
}

.right-dashboard-column {
    display: grid;
    gap: 20px;
    align-content: start
}

.quick-links {
    display: grid;
    gap: 8px
}

.quick-link,
.recent-resource {
    width: 100%;
    text-decoration: none;
    color: inherit
}

.quick-link {
    min-height: 40px;
    padding: 9px 10px;
    display: flex;
    align-items: center;
    gap: 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff
}

.quick-link:hover {
    background: #f7faff
}

.quick-link-icon,
.resource-icon {
    width: 26px;
    height: 26px;
    display: grid;
    place-items: center;
    border-radius: 6px;
    background: #f4f8ff;
    color: var(--blue);
    font-size: 10px;
    flex: 0 0 auto
}

.quick-link span {
    font-size: 9px;
    font-weight: 700
}

.quick-link small {
    display: block;
    font-size: 8px;
    color: var(--muted);
    margin-top: 2px
}

.recent-resource {
    padding: 9px 0;
    display: flex;
    gap: 9px;
    align-items: flex-start;
    border: 0;
    border-bottom: 1px solid #eef1f5;
    background: transparent;
    text-align: left
}

.recent-resource:last-child {
    border-bottom: 0
}

.resource-copy strong {
    display: block;
    font-size: 9px
}

.resource-copy span {
    display: block;
    font-size: 8px;
    color: var(--muted);
    margin-top: 3px
}

.timeline-page-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 270px;
    gap: 20px
}

.timeline-large .timeline-item {
    min-height: 88px
}

.timeline-large .timeline-card {
    min-height: 74px
}

.period-heading {
    margin: 4px 0 14px 62px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: .07em
}

.period-heading:after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--line)
}

.progress-ring {
    --value: 0;
    width: 92px;
    aspect-ratio: 1;
    margin: 8px auto 18px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: radial-gradient(circle closest-side, #fff 76%, transparent 77% 100%), conic-gradient(var(--green) calc(var(--value)*1%), #e7edf3 0)
}

.progress-ring span {
    font-size: 18px;
    font-weight: 800
}

.progress-ring small {
    display: block;
    text-align: center;
    color: var(--muted);
    font-size: 8px
}

.day-summary {
    display: grid;
    gap: 10px
}

.summary-row {
    display: flex;
    justify-content: space-between;
    font-size: 10px
}

.summary-row span {
    color: var(--muted)
}

.search-toolbar {
    padding: 12px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 160px;
    gap: 10px;
    border-bottom: 1px solid var(--line)
}

.search-box,
.filter-select {
    height: 40px;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
    color: #263244;
    outline: none
}

.search-box {
    padding: 0 12px
}

.filter-select {
    padding: 0 10px
}

.task-table {
    width: 100%;
    border-collapse: collapse
}

.task-table th,
.task-table td {
    padding: 12px 14px;
    border-bottom: 1px solid #edf0f4;
    text-align: left;
    font-size: 10px;
    vertical-align: middle
}

.task-table th {
    color: var(--muted);
    font-size: 8px;
    text-transform: uppercase;
    letter-spacing: .05em;
    background: #fafbfd
}

.task-table tr:hover td {
    background: #fbfdff
}

.table-task strong {
    display: block;
    font-size: 10px
}

.table-task small {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    line-height: 1.4
}

.badge {
    padding: 4px 7px;
    border-radius: 99px;
    display: inline-flex;
    font-size: 8px;
    font-weight: 700;
    color: #42516a;
    background: #f2f5f8
}

.badge.high,
.badge.critical {
    color: #a84d16;
    background: #fff5e6
}

.badge.completed {
    color: #238c69;
    background: var(--green2)
}

.badge.in_progress {
    color: var(--blue);
    background: #f4f8ff
}

.primary-button,
.secondary-button,
.success-button {
    min-height: 36px;
    padding: 0 12px;
    border-radius: 8px;
    font-size: 9px;
    font-weight: 800
}

.primary-button {
    border: 1px solid #2767d5;
    color: #fff;
    background: linear-gradient(180deg, #3479ee, #2766d8);
    box-shadow: 0 5px 13px #2767d533
}

.secondary-button {
    border: 1px solid #d5deea;
    color: #42516a;
    background: #fff
}

.success-button {
    border: 1px solid #48b38d;
    color: #238c69;
    background: #f4fcf9
}

.compact {
    min-height: 31px;
    padding: 0 10px
}

.empty-state {
    padding: 50px 20px;
    text-align: center;
    color: var(--muted)
}

.empty-icon {
    width: 54px;
    height: 54px;
    margin: 0 auto 12px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #f4f8ff;
    color: var(--blue);
    font-size: 22px
}

.empty-state strong {
    display: block;
    color: #263244;
    font-size: 12px
}

.empty-state p {
    margin: 6px auto 0;
    max-width: 420px;
    font-size: 10px;
    line-height: 1.5
}

.settings-grid,
.progress-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px
}

.settings-card,
.progress-card {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(20, 40, 70, .04)
}

.settings-card strong,
.progress-card strong {
    display: block;
    font-size: 12px
}

.settings-card p,
.progress-card p {
    margin: 6px 0 14px;
    color: var(--muted);
    font-size: 9px;
    line-height: 1.5
}

.progress-stat {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -.04em
}

.progress-bar {
    height: 8px;
    margin-top: 12px;
    border-radius: 99px;
    background: #edf1f5;
    overflow: hidden
}

.progress-bar span {
    display: block;
    height: 100%;
    background: var(--green)
}

.loading-state,
.error-state {
    min-height: 50vh;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 12px;
    color: var(--muted);
    font-size: 11px
}

.spinner {
    width: 30px;
    height: 30px;
    border: 3px solid #dfe7f1;
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: spin .8s linear infinite
}

@keyframes spin {
    to {
        transform: rotate(360deg)
    }
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    padding: 24px;
    display: grid;
    place-items: center;
    background: rgba(3, 15, 28, .66);
    backdrop-filter: blur(6px);
    z-index: 100
}

.task-modal {
    width: min(1050px, 96vw);
    max-height: calc(100vh - 48px);
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(0, 0, 0, .28)
}

.task-scroller {
    max-height: calc(100vh - 48px);
    overflow-y: auto;
}

.modal-header {
    min-height: 62px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    background: #fffffff5;
    backdrop-filter: blur(12px);
    z-index: 3
}

.back-button {
    border: 0;
    background: transparent;
    color: var(--blue);
    font-size: 10px;
    font-weight: 700
}

.modal-actions {
    display: flex;
    align-items: center;
    gap: 8px
}

.icon-button.light {
    color: #42516a;
    border-color: var(--line);
    background: #fff
}

.modal-loading {
    min-height: 520px;
    display: grid;
    place-items: center
}

.task-detail-layout {
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    min-height: 520px
}

.task-step-nav {
    padding: 26px 20px;
    border-right: 1px solid var(--line);
    background: #fbfcfe
}

.task-step-nav h3 {
    margin: 0 0 8px;
    font-size: 12px
}

.task-step-nav>p {
    margin: 0 0 22px;
    color: var(--muted);
    font-size: 9px
}

.step-nav-list {
    display: grid;
    position: relative
}

.step-nav-list:before {
    content: "";
    position: absolute;
    left: 11px;
    top: 14px;
    bottom: 14px;
    width: 1px;
    background: #d9e2ed
}

.step-nav-item {
    min-height: 58px;
    padding: 8px 0 8px 34px;
    position: relative
}
 
.step-nav-number {
    width: 22px;
    height: 22px;
    display: grid;
    place-items: center;
    position: absolute;
    left: 0;
    top: 8px;
    border: 1px solid #cbd5e1;
    border-radius: 50%;
    background: #fff;
    color: var(--muted);
    font-size: 8px;
    font-weight: 800;
    text-align: center;
    align-content: center;
    z-index: 1
}

.step-nav-item.active .step-nav-number {
    border-color: var(--blue);
    background: var(--blue);
    color: #fff
}

.step-nav-item strong {
    display: block;
    font-size: 9px
}

.step-nav-item span {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    font-size: 8px;
    line-height: 1.35
}

.task-detail-main {
    padding: 26px 28px 32px
}

.task-detail-title h2 {
    margin: 0;
    font-size: 20px;
    letter-spacing: -.025em
}

.task-detail-title p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 10px
}

.task-detail-meta {
    margin: 14px 0 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px
}

.tutorial-step-card {
    margin-bottom: 14px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff
}

.tutorial-step-card h3 {
    margin: 0;
    font-size: 12px
}

.tutorial-step-card p {
    margin: 7px 0 0;
    color: #42516a;
    font-size: 10px;
    line-height: 1.6
}

.step-actions {
    margin-top: 13px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap
}

.tutorial-media {
    margin-top: 14px;
    min-height: 185px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: linear-gradient(180deg, #0a1c2feb, #0b1f35fa);
    overflow: hidden;
    display: grid;
    place-items: center
}

.tutorial-media img,
.tutorial-media video {
    display: block;
    max-width: 100%;
    max-height: 420px
}

.media-placeholder {
    padding: 30px;
    text-align: center;
    color: #ffffffb3;
    font-size: 10px
}

.media-placeholder strong {
    display: block;
    color: #fff;
    margin-bottom: 4px
}

.tip-callout,
.warning-callout {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 7px;
    font-size: 9px;
    line-height: 1.5
}

.tip-callout {
    color: #715216;
    background: #fff9ec;
    border: 1px solid #f5e2b8
}

.warning-callout {
    color: #9b3d47;
    background: #fff4f5;
    border: 1px solid #f3d0d4
}

.checklist-box,
.quiz-box {
    margin-top: 20px;
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden
}

.checklist-header,
.quiz-header {
    padding: 12px 14px;
    border-bottom: 1px solid var(--line);
    background: #fafbfd
}

.checklist-item {
    min-height: 45px;
    padding: 9px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #edf0f4;
    font-size: 10px
}

.checklist-item:last-child {
    border-bottom: 0
}

.checklist-item input {
    width: 17px;
    height: 17px;
    accent-color: var(--green)
}

.required-marker {
    margin-left: auto;
    color: #98a3b4;
    font-size: 8px
}

.quiz-question {
    padding: 14px;
    border-bottom: 1px solid #edf0f4
}

.quiz-question>strong {
    display: block;
    font-size: 10px;
    line-height: 1.45
}

.quiz-options {
    display: grid;
    gap: 7px;
    margin-top: 10px
}

.quiz-option {
    padding: 9px 10px;
    display: flex;
    align-items: center;
    gap: 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    font-size: 9px
}

.quiz-option:hover {
    background: #f7faff
}

.quiz-result {
    margin-top: 8px;
    padding: 9px 10px;
    border-radius: 7px;
    font-size: 9px;
    line-height: 1.5
}

.quiz-result.correct {
    color: #238c69;
    background: var(--green2)
}

.quiz-result.incorrect {
    color: var(--red);
    background: var(--red2)
}

.toast-stack {
    position: fixed;
    right: 20px;
    bottom: 20px;
    display: grid;
    gap: 8px;
    z-index: 300
}

.toast {
    min-width: 230px;
    max-width: 360px;
    padding: 11px 13px;
    border-radius: 9px;
    color: #fff;
    background: #12263e;
    box-shadow: var(--shadow);
    font-size: 10px
}

.toast.success {
    background: #1f8d69
}

.toast.error {
    background: #b54750
}

@media(max-width:1050px) {

    .dashboard-grid,
    .timeline-page-layout {
        grid-template-columns: 1fr
    }

    .stat-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .right-dashboard-column {
        grid-template-columns: repeat(2, 1fr)
    }
}

@media(max-width:820px) {

    .app-shell,
    .app-shell.sidebar-collapsed {
        grid-template-columns: 1fr
    }

    .sidebar {
        position: fixed;
        left: 0;
        width: 238px;
        transform: translateX(-100%);
        transition: transform .18s ease
    }

    .sidebar.mobile-open {
        transform: translateX(0)
    }

    .mobile-menu {
        width: 36px;
        height: 36px;
        display: grid;
        place-items: center;
        border: 1px solid var(--line);
        border-radius: 9px;
        background: #fff;
        color: #42516a
    }

    .topbar {
        padding: 10px 15px
    }

    .user-chip {
        display: none
    }

    .content-area {
        padding: 18px 14px 28px
    }

    .task-detail-layout {
        grid-template-columns: 1fr
    }

    .task-step-nav {
        display: none
    }

    .search-toolbar {
        grid-template-columns: 1fr
    }
}

@media(max-width:610px) {

    .topbar-title span,
    .bell {
        display: none
    }

    .date-control>button:nth-child(2) {
        min-width: 112px
    }

    .page-header {
        flex-direction: column
    }

    .stat-grid {
        grid-template-columns: 1fr 1fr
    }

    .timeline-card {
        grid-template-columns: 46px minmax(0, 1fr) auto;
        gap: 8px;
        padding: 10px
    }

    .timeline-item {
        grid-template-columns: 38px minmax(0, 1fr);
        gap: 9px
    }

    .timeline:before {
        left: 15px
    }

    .timeline-main p {
        display: none
    }

    .right-dashboard-column,
    .settings-grid,
    .progress-card-grid {
        grid-template-columns: 1fr
    }

    .modal-backdrop {
        padding: 0
    }

    .task-modal {
        width: 100%;
        max-height: 100vh;
        min-height: 100vh;
        border-radius: 0
    }

    .task-detail-main {
        padding: 20px 16px 28px
    }

    #modalBookmark {
        display: none
    }
}

/* =========================================================
   Simplified Manager Hub layout - July 2026
   ========================================================= */

html,
body {
    height: 100%;
    overflow: hidden;
    font-size: 16px;
}

.main-shell {
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.content-area {
    flex: 1;
    min-height: 0;
    width: 100%;
    padding: 22px 28px;
    overflow: hidden;
}

#viewRoot {
    height: 100%;
    min-height: 0;
}

.nav-item {
    font-size: 14px;
}

.brand strong {
    font-size: 16px;
}

.brand small {
    font-size: 11px;
}

.profile-copy strong {
    font-size: 13px;
}

.profile-copy span {
    font-size: 11px;
}

.topbar-title span {
    font-size: 12px;
}

.topbar-title strong {
    font-size: 18px;
}

.date-control span {
    font-size: 13px;
}

.date-control small {
    font-size: 10px;
}

.user-chip strong {
    font-size: 12px;
}

.user-chip small {
    font-size: 10px;
}

.page-header h1 {
    font-size: 28px;
}

.page-header p {
    font-size: 14px;
}

.stat-card-top {
    font-size: 11px;
}

.stat-value {
    font-size: 28px;
}

.stat-sub {
    font-size: 11px;
}

.panel-header strong {
    font-size: 14px;
}

.panel-header small {
    font-size: 11px;
}

.timeline-time {
    font-size: 13px;
}

.timeline-main strong {
    font-size: 14px;
}

.timeline-main p {
    font-size: 11px;
    line-height: 1.5;
}

.meta-pill {
    font-size: 10px;
}

.dashboard-screen {
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.dashboard-static {
    flex: 0 0 auto;
}

.dashboard-heading {
    margin-bottom: 14px;
}

.dashboard-stat-grid {
    grid-column: auto;
}

.dashboard-timeline-panel {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.timeline-fixed-header {
    flex: 0 0 auto;
    background: #fff;
}

.timeline-fixed-header > div {
    display: grid;
    gap: 3px;
}

.current-time-label {
    padding: 6px 9px;
    border-radius: 7px;
    background: #f3f7fd;
    color: var(--blue);
    font-size: 11px;
    font-weight: 700;
}

.timeline-scroll {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    padding: 18px 22px 40px;
    scroll-behavior: smooth;
}

.timeline-scroll::-webkit-scrollbar {
    width: 10px;
}

.timeline-scroll::-webkit-scrollbar-track {
    background: #f4f6f9;
}

.timeline-scroll::-webkit-scrollbar-thumb {
    background: #c9d4e3;
    border: 2px solid #f4f6f9;
    border-radius: 99px;
}

.timeline-scroll .timeline-item {
    min-height: 92px;
}

.timeline-scroll .timeline-card {
    min-height: 78px;
    padding: 14px 16px;
}

.current-time-task .timeline-card {
    border-color: #8fb4ef;
    border-left-color: var(--blue);
    background: linear-gradient(90deg, #f5f9ff 0%, #fff 24%);
    box-shadow: 0 8px 24px rgba(47, 115, 229, .11);
}

.current-time-task .timeline-dot {
    background: var(--blue);
    box-shadow: 0 0 0 5px rgba(47, 115, 229, .16);
}

.current-time-task .timeline-time::after {
    content: "Current";
    display: block;
    width: max-content;
    margin-top: 4px;
    padding: 2px 5px;
    border-radius: 4px;
    background: var(--blue);
    color: #fff;
    font-size: 8px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.links-grid {
    height: 100%;
    overflow-y: auto;
    padding: 2px 4px 24px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-content: start;
    gap: 16px;
}

.link-tile {
    position: relative;
    min-height: 160px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 4px 16px rgba(20, 40, 70, .05);
    overflow: hidden;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.link-tile:hover {
    transform: translateY(-2px);
    border-color: #bfd0e8;
    box-shadow: 0 12px 30px rgba(20, 40, 70, .1);
}

.link-tile-main,
.empty-custom-link {
    width: 100%;
    min-height: 160px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 13px;
    border: 0;
    background: transparent;
    color: inherit;
    text-align: left;
    text-decoration: none;
}

.link-tile-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, #edf4ff, #f7faff);
    color: var(--blue);
    font-size: 17px;
    font-weight: 800;
}

.link-tile-content {
    display: grid;
    gap: 5px;
}

.link-tile-content strong {
    font-size: 15px;
}

.link-tile-content small {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}

.link-tile-action {
    margin-top: auto;
    color: var(--blue);
    font-size: 11px;
    font-weight: 800;
}

.custom-link-tile {
    border-style: dashed;
}

.empty-custom-link {
    cursor: pointer;
}

.link-tile-edit {
    position: absolute;
    right: 12px;
    top: 12px;
    padding: 5px 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    color: var(--muted);
    font-size: 10px;
}

.links-empty {
    grid-column: 1 / -1;
}

.user-page-grid {
    height: 100%;
    overflow-y: auto;
    padding: 2px 4px 24px;
    display: grid;
    grid-template-columns: minmax(280px, .85fr) minmax(0, 1.4fr);
    gap: 18px;
    align-content: start;
}

.user-profile-card {
    grid-row: span 2;
}

.user-profile-hero {
    padding: 26px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid var(--line);
}

.user-large-avatar {
    width: 68px;
    height: 68px;
    border-radius: 20px;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, #397ff0, #1e5dcc);
    color: #fff;
    font-size: 20px;
    font-weight: 850;
}

.user-profile-hero h2 {
    margin: 0;
    font-size: 21px;
}

.user-profile-hero p,
.user-profile-hero span {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.user-detail-list {
    padding: 10px 22px 22px;
}

.user-detail-list > div {
    padding: 13px 0;
    display: flex;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid #edf1f5;
}

.user-detail-list span {
    color: var(--muted);
    font-size: 12px;
}

.user-detail-list strong {
    font-size: 12px;
    text-align: right;
}

.user-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.user-stat-card {
    min-height: 128px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(20, 40, 70, .05);
}

.user-stat-card span {
    color: var(--muted);
    font-size: 11px;
}

.user-stat-card strong {
    display: block;
    margin-top: 10px;
    font-size: 27px;
}

.user-stat-card small {
    display: block;
    margin-top: 5px;
    color: var(--muted);
    font-size: 10px;
}

.account-form-card {
    align-self: start;
}

.account-form {
    padding: 18px;
    display: grid;
    gap: 14px;
}

.account-form label,
.simple-dialog-form label {
    display: grid;
    gap: 6px;
    color: #435068;
    font-size: 12px;
    font-weight: 700;
}

.account-form input,
.simple-dialog-form input {
    height: 42px;
    padding: 0 12px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: #fff;
    outline: none;
}

.account-form input:focus,
.simple-dialog-form input:focus {
    border-color: #8bafe8;
    box-shadow: 0 0 0 3px rgba(47, 115, 229, .08);
}

.account-form .primary-button {
    width: max-content;
}

.simple-dialog-backdrop {
    position: fixed;
    inset: 0;
    padding: 20px;
    display: grid;
    place-items: center;
    background: rgba(4, 17, 31, .62);
    backdrop-filter: blur(5px);
    z-index: 400;
}

.simple-dialog {
    width: min(470px, 96vw);
    border-radius: 17px;
    background: #fff;
    box-shadow: 0 26px 80px rgba(0, 0, 0, .28);
}

.simple-dialog-header {
    padding: 17px 18px;
    display: flex;
    justify-content: space-between;
    gap: 15px;
    border-bottom: 1px solid var(--line);
}

.simple-dialog-header h3 {
    margin: 0;
    font-size: 17px;
}

.simple-dialog-header p {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 11px;
}

.simple-dialog-form {
    padding: 18px;
    display: grid;
    gap: 14px;
}

.simple-dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding-top: 4px;
}

@media (max-width: 1150px) {
    .links-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .user-page-grid {
        grid-template-columns: 1fr;
    }

    .user-profile-card {
        grid-row: auto;
    }
}

@media (max-width: 850px) {
    html,
    body {
        overflow: auto;
    }

    .main-shell {
        height: auto;
        min-height: 100vh;
        overflow: visible;
    }

    .content-area,
    #viewRoot {
        height: auto;
        overflow: visible;
    }

    .dashboard-screen {
        height: calc(100vh - 94px);
    }

    .dashboard-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .links-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .user-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 580px) {
    .content-area {
        padding: 16px 12px;
    }

    .dashboard-heading {
        display: none;
    }

    .dashboard-stat-grid {
        gap: 8px;
    }

    .stat-card {
        min-height: 82px;
        padding: 12px;
    }

    .stat-value {
        font-size: 23px;
    }

    .timeline-scroll {
        padding: 14px 10px 34px;
    }

    .timeline-scroll .timeline-item {
        grid-template-columns: 34px minmax(0, 1fr);
        gap: 7px;
    }

    .timeline-scroll .timeline-card {
        grid-template-columns: 47px minmax(0, 1fr) auto;
        gap: 8px;
        padding: 11px 9px;
    }

    .links-grid,
    .user-stat-grid {
        grid-template-columns: 1fr;
    }

    .link-tile,
    .link-tile-main,
    .empty-custom-link {
        min-height: 140px;
    }

    .user-profile-hero {
        align-items: flex-start;
    }
}

/* Category colours and icons on timeline tasks */
.timeline-card {
    border-left-color: var(--task-colour, #4d83dd);
}

.timeline-leading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 62px;
}

.timeline-category-icon-wrap {
    width: 42px;
    height: 42px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border-radius: 11px;
    background: color-mix(in srgb, var(--task-colour, #4d83dd) 10%, white);
    border: 1px solid color-mix(in srgb, var(--task-colour, #4d83dd) 24%, white);
    overflow: hidden;
}

.timeline-category-icon {
    width: 32px;
    height: 32px;
    display: block;
    object-fit: contain;
}

.timeline-category-icon-fallback {
    width: 100%;
    height: 100%;
    place-items: center;
    color: var(--task-colour, #4d83dd);
    font-size: 18px;
    font-weight: 800;
}

.timeline-leading .timeline-time {
    width: 100%;
    text-align: center;
    line-height: 1;
}

.timeline-item .timeline-dot {
    background: var(--task-colour, #9bb8e6);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--task-colour, #9bb8e6) 28%, white);
}

.timeline-item .timeline-dot.completed {
    background: var(--green);
    box-shadow: 0 0 0 2px #2dab8030;
}

.timeline-item .timeline-dot.in_progress {
    background: var(--blue);
    box-shadow: 0 0 0 3px #2f73e530;
}

.timeline-item .timeline-dot.overdue {
    background: var(--red);
    box-shadow: 0 0 0 2px #d9505c30;
}

.current-time-task .timeline-card {
    border-left-color: var(--task-colour, var(--blue));
}

@media (max-width: 580px) {
    .timeline-category-icon {
        width: 27px;
        height: 27px;
        border-radius: 8px;
        font-size: 12px;
    }

    .timeline-leading {
        gap: 6px;
    }
}


/* Icon above time layout */
.timeline-scroll .timeline-card,
.timeline-card {
    grid-template-columns: 72px minmax(0, 1fr) auto;
}

@media (max-width: 580px) {
    .timeline-scroll .timeline-card,
    .timeline-card {
        grid-template-columns: 58px minmax(0, 1fr) auto;
    }

    .timeline-leading {
        min-width: 52px;
        gap: 5px;
    }

    .timeline-category-icon-wrap {
        width: 36px;
        height: 36px;
        border-radius: 9px;
    }

    .timeline-category-icon {
        width: 28px;
        height: 28px;
    }
}


/* =========================================================
   User authentication
   ========================================================= */

.login-screen {
    min-height: 100vh;
    padding: 24px;
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 16% 6%, rgba(54, 124, 238, .25), transparent 28%),
        radial-gradient(circle at 88% 88%, rgba(45, 171, 128, .12), transparent 25%),
        linear-gradient(145deg, #051525, #09243f);
}

.login-card {
    width: min(440px, 100%);
    padding: 32px;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 22px;
    background: rgba(255, 255, 255, .98);
    box-shadow: 0 30px 90px rgba(0, 0, 0, .32);
}

.login-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.login-brand strong,
.login-brand small {
    display: block;
}

.login-brand strong {
    font-size: 16px;
}

.login-brand small {
    margin-top: 2px;
    color: var(--muted);
    font-size: 11px;
}

.login-heading {
    margin: 30px 0 24px;
}

.login-heading > span {
    color: var(--blue);
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .07em;
}

.login-heading h1 {
    margin: 6px 0 0;
    font-size: 28px;
    letter-spacing: -.035em;
}

.login-heading p {
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 13px;
}

.login-form {
    display: grid;
    gap: 16px;
}

.login-form label {
    display: grid;
    gap: 7px;
    color: #35435a;
    font-size: 12px;
    font-weight: 750;
}

.login-form input {
    width: 100%;
    height: 46px;
    padding: 0 13px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink);
    outline: none;
}

.login-form input:focus {
    border-color: #86abe8;
    box-shadow: 0 0 0 4px rgba(47, 115, 229, .09);
}

.password-field {
    position: relative;
}

.password-field input {
    padding-right: 65px;
}

.password-field button {
    position: absolute;
    right: 7px;
    top: 7px;
    height: 32px;
    padding: 0 9px;
    border: 0;
    border-radius: 7px;
    background: #f1f5fa;
    color: #536178;
    font-size: 10px;
    font-weight: 750;
}

.login-error {
    padding: 10px 12px;
    border: 1px solid #f0c6cb;
    border-radius: 9px;
    background: #fff2f3;
    color: #b83e49;
    font-size: 11px;
    line-height: 1.45;
}

.login-submit {
    width: 100%;
    min-height: 45px;
    margin-top: 2px;
    font-size: 12px;
}

.login-submit:disabled {
    cursor: wait;
    opacity: .68;
}

.sidebar-logout {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 8px;
    background: rgba(255,255,255,.055);
    color: rgba(255,255,255,.72);
}

.sidebar-logout:hover {
    background: rgba(255,255,255,.1);
    color: #fff;
}

.account-logout-row {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
}

.account-logout-button {
    min-height: 39px;
}

.app-shell.auth-loading,
.login-screen.auth-loading {
    pointer-events: none;
}

@media (max-width: 580px) {
    .login-screen {
        padding: 14px;
    }

    .login-card {
        padding: 25px 20px;
        border-radius: 18px;
    }

    .login-heading h1 {
        font-size: 24px;
    }
}
