body { background: #f5f7fb; }
.card { border: 0; box-shadow: 0 8px 24px rgba(15, 23, 42, .08); }
.table thead th { background: #0f172a; color: #fff; white-space: nowrap; }
.badge-soft { background: #e9eefc; color: #1e3a8a; }
.form-label { font-weight: 600; }
.small-muted { color: #64748b; font-size: .9rem; }
.metric-card { min-height: 120px; }
.metric-number { font-size: 2rem; font-weight: 800; }
.text-pre { white-space: pre-wrap; }
.stat-card { padding: 1rem; min-height: 98px; }
.stat-card span { color: #64748b; font-size: .9rem; }
.stat-card strong { display: block; font-size: 1.4rem; margin-top: .25rem; }
.timeline-dot { width: .75rem; height: .75rem; border-radius: 999px; background: #0d6efd; display: inline-block; margin-right: .5rem; }


:root {
    --app-sidebar-width: 284px;
    --app-ink: #172033;
    --app-muted: #6b7280;
    --app-line: #d9e1ec;
    --app-sidebar: #111827;
    --app-sidebar-soft: #1f2937;
    --app-accent: #2563eb;
}

body {
    color: var(--app-ink);
}

.app-shell {
    min-height: 100vh;
    display: flex;
}

.app-sidebar {
    width: var(--app-sidebar-width);
    min-height: 100vh;
    position: sticky;
    top: 0;
    flex: 0 0 var(--app-sidebar-width);
    background: var(--app-sidebar);
    color: #fff;
}

.app-sidebar-inner {
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
}

.app-brand {
    display: flex;
    align-items: center;
    gap: .75rem;
    color: #fff;
    text-decoration: none;
    min-height: 44px;
}

.app-brand:hover {
    color: #fff;
}

.app-brand-mark {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #2563eb;
    font-weight: 800;
}

.app-brand strong,
.app-user-panel strong {
    display: block;
    line-height: 1.1;
}

.app-brand small,
.app-user-panel small {
    display: block;
    color: #b8c2d2;
    font-size: .78rem;
    margin-top: .15rem;
}

.app-search {
    height: 38px;
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: 0 .75rem;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 8px;
    background: rgba(255,255,255,.06);
    color: #dbeafe;
}

.app-search input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
}

.app-search input::placeholder {
    color: #9ca3af;
}

.app-quick-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: .5rem;
}

.app-nav {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    overflow-y: auto;
    padding-right: .15rem;
}

.app-nav-section {
    display: flex;
    flex-direction: column;
    gap: .25rem;
}

.app-nav-title {
    color: #94a3b8;
    font-size: .72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    padding: .15rem .65rem;
}

.app-nav-link {
    min-height: 38px;
    display: flex;
    align-items: center;
    gap: .7rem;
    color: #d1d5db;
    text-decoration: none;
    border-radius: 8px;
    padding: .45rem .65rem;
    font-weight: 600;
}

.app-nav-link i {
    width: 1.2rem;
    text-align: center;
    color: #93c5fd;
}

.app-nav-link:hover {
    color: #fff;
    background: rgba(255,255,255,.08);
}

.app-nav-link.active {
    color: #fff;
    background: #2454c6;
    box-shadow: inset 3px 0 0 #60a5fa;
}

.app-nav-link.active i {
    color: #fff;
}

.app-user-panel {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    border-top: 1px solid rgba(255,255,255,.1);
    padding-top: 1rem;
}

.app-main {
    min-width: 0;
    flex: 1;
}

.app-topbar {
    min-height: 64px;
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .75rem 1.25rem;
    border-bottom: 1px solid var(--app-line);
    background: rgba(255,255,255,.88);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 20;
}

.app-topbar-title {
    flex: 1;
    min-width: 0;
    font-weight: 800;
}

.app-mobile-menu {
    width: min(88vw, var(--app-sidebar-width));
    background: var(--app-sidebar);
    color: #fff;
}

.app-mobile-menu .offcanvas-header {
    border-bottom: 1px solid rgba(255,255,255,.1);
}

.app-mobile-menu .app-sidebar-inner {
    min-height: calc(100vh - 57px);
}

@media (max-width: 991.98px) {
    .app-shell {
        display: block;
    }

    .app-topbar {
        padding: .65rem .85rem;
    }

    .app-topbar .btn-primary span {
        display: none;
    }
}


.app-menu-ready .app-sidebar,
.app-menu-ready .app-main,
.app-menu-ready .app-edge-reveal {
    transition: margin-left .22s ease, transform .22s ease, opacity .18s ease;
}

.app-edge-reveal {
    position: fixed;
    inset: 0 auto 0 0;
    width: 10px;
    z-index: 40;
    pointer-events: none;
}

.app-menu-hidden .app-edge-reveal {
    pointer-events: auto;
}

.app-menu-toggle {
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 34px;
}

@media (min-width: 992px) {
    .app-menu-hidden .app-sidebar,
    .app-menu-prehidden .app-sidebar {
        margin-left: calc(var(--app-sidebar-width) * -1);
        transform: translateX(-8px);
        opacity: 0;
        pointer-events: none;
    }

    .app-menu-hidden .app-main,
    .app-menu-prehidden .app-main {
        margin-left: 0;
    }

    .app-menu-hidden .app-topbar {
        border-left: 1px solid var(--app-line);
    }
}


@media (min-width: 992px) {
    .app-shell {
        display: block;
        min-height: 100vh;
    }

    .app-sidebar {
        position: fixed;
        inset: 0 auto 0 0;
        height: 100vh;
        min-height: 100vh;
        z-index: 35;
        overflow: hidden;
    }

    .app-sidebar-inner {
        height: 100vh;
        min-height: 0;
        overflow: hidden;
    }

    .app-nav {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        overscroll-behavior: contain;
    }

    .app-main {
        margin-left: var(--app-sidebar-width);
        transition: margin-left .22s ease;
    }

    .app-menu-hidden .app-sidebar,
    .app-menu-prehidden .app-sidebar {
        margin-left: 0;
        transform: translateX(calc(var(--app-sidebar-width) * -1));
    }

    .app-menu-hidden .app-main,
    .app-menu-prehidden .app-main {
        margin-left: 0;
    }
}


.page-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.eyebrow {
    color: var(--app-muted);
    font-size: .74rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.page-heading-actions {
    display: flex;
    gap: .5rem;
    flex-wrap: wrap;
}

.process-form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 1rem;
    align-items: start;
}

.process-form-main {
    display: grid;
    gap: 1rem;
}

.form-section,
.summary-panel {
    background: #fff;
    border: 1px solid #e5ebf3;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, .06);
    padding: 1rem;
}

.form-section-header {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding-bottom: .85rem;
    margin-bottom: .85rem;
    border-bottom: 1px solid #edf1f7;
}

.form-section-header h2,
.summary-panel h2 {
    font-size: 1rem;
    font-weight: 800;
    margin: 0;
}

.section-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #e9f1ff;
    color: #1d4ed8;
}

.form-label.required::after {
    content: " *";
    color: #dc2626;
}

.process-form-aside {
    position: sticky;
    top: 82px;
}

.summary-panel dl {
    display: grid;
    gap: .65rem;
    margin: .75rem 0 0;
}

.summary-panel dl div {
    padding-bottom: .65rem;
    border-bottom: 1px solid #edf1f7;
}

.summary-panel dt {
    color: var(--app-muted);
    font-size: .76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.summary-panel dd {
    margin: .2rem 0 0;
    font-weight: 700;
    word-break: break-word;
}

.form-switch-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .85rem;
    border: 1px solid #e5ebf3;
    border-radius: 8px;
    background: #f8fafc;
}

.form-switch-row span {
    display: block;
    color: var(--app-muted);
    font-size: .88rem;
}

.form-action-bar {
    position: sticky;
    bottom: 0;
    z-index: 15;
    display: flex;
    justify-content: flex-end;
    gap: .5rem;
    margin-top: 1rem;
    padding: .75rem;
    border: 1px solid #e5ebf3;
    border-radius: 8px;
    background: rgba(255,255,255,.94);
    backdrop-filter: blur(10px);
    box-shadow: 0 -8px 24px rgba(15, 23, 42, .06);
}

@media (max-width: 1199.98px) {
    .process-form-grid {
        grid-template-columns: 1fr;
    }

    .process-form-aside {
        position: static;
        order: -1;
    }
}

@media (max-width: 767.98px) {
    .page-heading {
        display: block;
    }

    .page-heading-actions {
        margin-top: .75rem;
    }

    .form-action-bar {
        justify-content: stretch;
    }

    .form-action-bar .btn {
        flex: 1;
    }
}

.process-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .75rem;
}

.process-tab {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    min-height: 58px;
    padding: .85rem 1rem;
    color: var(--app-text);
    text-decoration: none;
    border: 1px solid #e1e7ef;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 8px 20px rgba(15, 23, 42, .04);
    transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.process-tab:hover {
    color: var(--app-primary);
    border-color: #b9c8dc;
    box-shadow: 0 12px 26px rgba(15, 23, 42, .08);
    transform: translateY(-1px);
}

.process-tab.active {
    color: var(--app-primary);
    border-color: var(--app-primary);
    box-shadow: inset 0 0 0 1px var(--app-primary), 0 12px 26px rgba(22, 99, 173, .12);
}

.process-tab span {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    min-width: 0;
    font-weight: 800;
}

.process-tab strong {
    min-width: 2.25rem;
    padding: .2rem .45rem;
    text-align: center;
    color: #fff;
    border-radius: 999px;
    background: var(--app-primary);
    font-size: .85rem;
}

@media (max-width: 991.98px) {
    .process-tabs {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .process-tabs {
        grid-template-columns: 1fr;
    }
}

.reset-impact-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .7rem;
}

.reset-impact-grid > div {
    display: flex;
    min-height: 76px;
    justify-content: space-between;
    flex-direction: column;
    padding: .75rem;
    border: 1px solid #f1d2d7;
    border-radius: 10px;
    background: #fff7f8;
}

.reset-impact-grid span { color: #6f4850; font-size: .76rem; }
.reset-impact-grid strong { color: #b42336; font-size: 1.45rem; }
.reset-preserved-list { display: grid; gap: .55rem; padding-left: 1.15rem; color: #456457; }

.reset-final-card {
    max-width: 680px;
    padding: clamp(1.5rem, 4vw, 2.5rem);
    border: 1px solid #efc3ca;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 24px 65px rgba(87, 16, 28, .14);
    text-align: center;
}

.reset-final-icon { display: grid; width: 64px; height: 64px; margin: 0 auto 1rem; place-items: center; color: #b42336; border-radius: 18px; background: #fff0f2; font-size: 1.65rem; }
.reset-final-card > p { color: #667085; }
.reset-final-total { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin: 1.3rem 0; padding: 1rem; border-radius: 12px; color: #742132; background: #fff4f5; text-align: left; }
.reset-final-total span { font-size: .82rem; }
.reset-final-total strong { font-size: 1.7rem; }
.reset-final-check { padding: .9rem .9rem .9rem 2.25rem; border: 1px solid #efc3ca; border-radius: 10px; background: #fff9fa; }

.config-section-nav { display: flex; gap: .5rem; overflow-x: auto; padding: .65rem; border: 1px solid #dce3ed; border-radius: 12px; background: #fff; position: sticky; top: 72px; z-index: 20; }
.config-section-nav a { flex: 0 0 auto; padding: .45rem .75rem; border-radius: 8px; color: #294764; text-decoration: none; font-weight: 600; }
.config-section-nav a:hover, .config-section-nav a:focus { background: #eaf2ff; color: #0d6efd; }
.config-anchor { scroll-margin-top: 145px; }
.config-save-bar { display: flex; position: sticky; bottom: 0; align-items: center; justify-content: flex-end; gap: 1rem; padding: .8rem; background: rgba(255,255,255,.96); border-top: 1px solid #e7ebf0; z-index: 15; }
.unsaved-indicator { display: none; color: #9a6700; font-size: .85rem; font-weight: 600; }
.config-form.has-unsaved-changes .unsaved-indicator { display: inline; }
.permission-toolbar { display: grid; grid-template-columns: minmax(220px, 2fr) minmax(180px, 1fr); gap: .75rem; }
.permission-table th { min-width: 150px; }
.permission-table th:first-child { min-width: 230px; }
.permission-group-actions { display: flex; flex-direction: column; align-items: flex-start; margin-top: .3rem; }
.permission-group-actions .btn { padding: 0; font-size: .72rem; }
.permission-cell { display: flex; align-items: center; gap: .4rem; cursor: pointer; }
.permission-module-badge { display: inline-block; min-width: 82px; margin-right: .5rem; color: #60758c; font-size: .7rem; }
.permission-save-bar { display: flex; position: sticky; bottom: 0; justify-content: flex-end; align-items: center; gap: 1rem; padding: .75rem; background: rgba(255,255,255,.97); z-index: 10; }
.permission-matrix.has-unsaved-changes .unsaved-indicator { display: inline; }
.process-section-nav { display: flex; gap: .4rem; overflow-x: auto; position: sticky; top: 72px; padding: .55rem; border: 1px solid #dce3ed; border-radius: 12px; background: rgba(255,255,255,.97); z-index: 18; }
.process-section-nav:empty { display: none; }
.process-section-nav a { flex: 0 0 auto; padding: .35rem .65rem; border-radius: 8px; text-decoration: none; color: #36536f; font-size: .84rem; font-weight: 600; }
.process-section-nav a:hover, .process-section-nav a:focus { background: #eaf2ff; color: #0d6efd; }
.process-detail-section { scroll-margin-top: 140px; }
.process-section-toggle { padding: .2rem .4rem; text-decoration: none; }

@media (max-width: 767.98px) {
    .config-section-nav { top: 64px; margin-inline: -.25rem; }
    .config-save-bar { justify-content: space-between; }
    .permission-toolbar { grid-template-columns: 1fr; }
    .permission-save-bar { justify-content: space-between; }
    .process-summary-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .45rem; }
    .process-summary-tabs .process-tab { padding: .55rem .65rem; min-height: auto; }
    .process-section-nav { top: 64px; }
    .process-main-header { align-items: flex-start !important; flex-direction: column; gap: .75rem; }
    .process-main-header > div:last-child { display: flex; flex-wrap: wrap; gap: .35rem; }
}

@media (max-width: 767.98px) {
    .reset-impact-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 420px) {
    .reset-impact-grid { grid-template-columns: 1fr; }
}

.app-nav {
    scrollbar-width: thin;
    scrollbar-color: rgba(148, 163, 184, .45) transparent;
}

.app-nav::-webkit-scrollbar { width: 6px; }
.app-nav::-webkit-scrollbar-track { background: transparent; }
.app-nav::-webkit-scrollbar-thumb { border-radius: 999px; background: rgba(148, 163, 184, .42); }
.app-nav::-webkit-scrollbar-thumb:hover { background: rgba(148, 163, 184, .62); }

.dashboard-welcome {
    position: relative;
    display: flex;
    align-items: center;
    gap: .95rem;
    overflow: hidden;
    padding: 1rem 1.25rem;
    color: #fff;
    border-radius: 16px;
    background: linear-gradient(125deg, #123d69 0%, #1763ad 58%, #2494c7 100%);
    box-shadow: 0 16px 38px rgba(18, 61, 105, .2);
}

.dashboard-welcome::after {
    content: "";
    position: absolute;
    width: 190px;
    height: 190px;
    right: -55px;
    top: -90px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .09);
}

.dashboard-welcome-icon {
    position: relative;
    z-index: 1;
    display: grid;
    flex: 0 0 48px;
    height: 48px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .26);
    border-radius: 15px;
    background: rgba(255, 255, 255, .14);
    font-size: 1.3rem;
}

.dashboard-welcome-copy { position: relative; z-index: 1; }
.dashboard-welcome-label { display: block; margin-bottom: .2rem; font-size: .7rem; font-weight: 800; letter-spacing: .14em; opacity: .82; }
.dashboard-welcome h1 { margin: 0 0 .2rem; font-size: clamp(1.25rem, 2.2vw, 1.75rem); font-weight: 800; }
.dashboard-welcome p { margin: 0; color: rgba(255, 255, 255, .84); }
.dashboard-scope-badge { display: inline-flex; align-items: center; gap: .35rem; margin-top: .55rem; padding: .28rem .55rem; color: #fff; border: 1px solid rgba(255, 255, 255, .3); border-radius: 999px; background: rgba(255, 255, 255, .12); font-size: .7rem; font-weight: 700; }
.dashboard-welcome-actions { display: flex; align-items: center; gap: .3rem; margin-top: .8rem; }
.dashboard-welcome-actions .btn-light { color: #164f88; font-weight: 700; }

.dashboard-section-heading,
.dashboard-card-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
}

.dashboard-section-heading { margin-bottom: .75rem; }
.dashboard-section-heading h2,
.dashboard-card-heading h2 { margin: 0; color: #172033; font-size: 1.05rem; font-weight: 800; }
.dashboard-section-kicker,
.dashboard-card-heading span { display: block; margin-bottom: .12rem; color: #2563eb; font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.dashboard-section-note { color: #64748b; font-size: .8rem; }

.dashboard-metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .8rem;
}

.metric-card {
    --metric-accent: #2563eb;
    --metric-soft: #eff6ff;
    position: relative;
    display: flex;
    min-height: 94px;
    align-items: center;
    gap: .75rem;
    padding: .9rem;
    color: #172033;
    border: 1px solid #e3e9f1;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 7px 20px rgba(15, 23, 42, .055);
    text-decoration: none;
    transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

a.metric-card:hover { color: #172033; border-color: color-mix(in srgb, var(--metric-accent) 40%, #e3e9f1); box-shadow: 0 12px 26px rgba(15, 23, 42, .1); transform: translateY(-2px); }
.metric-card-alert { --metric-accent: #dc3545; --metric-soft: #fff1f2; }
.metric-card-warning { --metric-accent: #d97706; --metric-soft: #fff7e6; }
.metric-card-info { --metric-accent: #0284c7; --metric-soft: #eaf8ff; }
.metric-card-primary { --metric-accent: #2563eb; --metric-soft: #eef4ff; }
.metric-card-success { --metric-accent: #16845b; --metric-soft: #eaf9f2; }
.metric-card-neutral { --metric-accent: #64748b; --metric-soft: #f1f5f9; }
.metric-card.is-zero { --metric-accent: #64748b; --metric-soft: #f4f6f8; }

.metric-icon { display: grid; flex: 0 0 38px; height: 38px; place-items: center; color: var(--metric-accent); border-radius: 10px; background: var(--metric-soft); font-size: 1.05rem; }
.metric-copy { display: flex; min-width: 0; flex: 1; flex-direction: column; }
.metric-copy small { color: #64748b; font-size: .76rem; font-weight: 700; }
.metric-copy strong { color: var(--metric-accent); font-size: 1.65rem; line-height: 1.08; }
.metric-copy em { overflow: hidden; color: #7b8798; font-size: .7rem; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.metric-arrow { color: #a4afbd; font-size: .72rem; }

.dashboard-shortcuts {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .8rem;
}

.dashboard-shortcuts > a { display: flex; min-height: 72px; align-items: center; gap: .7rem; padding: .8rem .9rem; color: #172033; border: 1px solid #e3e9f1; border-radius: 12px; background: #fff; box-shadow: 0 6px 18px rgba(15, 23, 42, .045); text-decoration: none; transition: .16s ease; }
.dashboard-shortcuts > a:hover { color: #1559a1; border-color: #b9cce2; box-shadow: 0 10px 24px rgba(15, 23, 42, .09); transform: translateY(-1px); }
.dashboard-shortcuts > a > i:first-child { display: grid; flex: 0 0 36px; height: 36px; place-items: center; color: #2563eb; border-radius: 9px; background: #eff6ff; }
.dashboard-shortcuts > a > i:last-child { margin-left: auto; color: #94a3b8; }
.dashboard-shortcuts span { display: flex; min-width: 0; flex-direction: column; }
.dashboard-shortcuts strong { font-size: .82rem; }
.dashboard-shortcuts small { overflow: hidden; color: #718096; font-size: .7rem; text-overflow: ellipsis; white-space: nowrap; }

.dashboard-chart-card,
.dashboard-list-card,
.dashboard-side-card { padding: 1rem; border: 1px solid #e7ecf3; border-radius: 13px; box-shadow: 0 8px 22px rgba(15, 23, 42, .055); }
.dashboard-card-heading { margin-bottom: .8rem; }
.dashboard-card-heading a { font-size: .78rem; font-weight: 700; text-decoration: none; }
.dashboard-card-heading small { display: block; margin-top: .18rem; color: #7b8798; font-size: .7rem; }
.dashboard-chart-wrap { position: relative; min-height: 270px; }
.dashboard-chart-wrap-status { min-height: 320px; }
.dashboard-chart-wrap-workload { min-height: 310px; }
.dashboard-chart-expand { display: inline-flex; flex: 0 0 auto; min-height: 34px; align-items: center; justify-content: center; gap: .35rem; padding: .35rem .65rem; color: #2563eb; border: 1px solid #d9e4f2; border-radius: 9px; background: #f5f9ff; font-size: .72rem; transition: .16s ease; }
.dashboard-chart-expand b { font-weight: 800; }
.dashboard-chart-expand:hover { color: #174f9c; border-color: #a8c4e8; background: #eaf3ff; transform: translateY(-1px); }
.dashboard-chart-expand:focus-visible { outline: 3px solid rgba(37, 99, 235, .22); outline-offset: 2px; }

.dashboard-workload-modal .modal-dialog { max-width: min(94vw, 1400px); }
.dashboard-workload-modal .modal-content { overflow: hidden; border: 0; border-radius: 16px; box-shadow: 0 24px 70px rgba(15, 23, 42, .24); }
.dashboard-workload-modal .modal-header { align-items: flex-start; padding: 1.15rem 1.35rem; border-bottom-color: #e7edf4; }
.dashboard-workload-modal .modal-title { color: #172033; font-size: 1.25rem; font-weight: 800; }
.dashboard-workload-modal .modal-header p { margin: .2rem 0 0; color: #718096; font-size: .78rem; }
.dashboard-modal-kicker { display: block; margin-bottom: .1rem; color: #2563eb; font-size: .68rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.dashboard-workload-modal .modal-body { padding: 1rem 1.35rem 1.35rem; }
.dashboard-workload-filters { display: grid; grid-template-columns: repeat(4, minmax(135px, 1fr)) auto; align-items: end; gap: .7rem; margin-bottom: .8rem; padding: .8rem; border: 1px solid #e1e8f0; border-radius: 11px; background: #f7f9fc; }
.dashboard-workload-filters label { display: block; margin-bottom: .25rem; color: #526175; font-size: .68rem; font-weight: 800; text-transform: uppercase; }
.dashboard-workload-open-list { display: inline-flex; min-height: 31px; align-items: center; justify-content: center; gap: .35rem; white-space: nowrap; }
.dashboard-workload-expanded-chart { position: relative; height: clamp(360px, 48vh, 560px); }
.dashboard-chart-help { display: flex; align-items: center; gap: .4rem; margin: .35rem 0 1rem; color: #64748b; font-size: .75rem; }
.dashboard-workload-insights { margin: 0 0 1rem; padding: 1rem; border: 1px solid #e3eaf2; border-radius: 12px; background: #fbfcfe; }
.dashboard-workload-insights-heading,
.dashboard-workload-critical-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; }
.dashboard-workload-insights-heading span,
.dashboard-workload-critical-heading span,
.dashboard-workload-table-heading span { display: block; margin-bottom: .12rem; color: #2563eb; font-size: .65rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.dashboard-workload-insights-heading h3,
.dashboard-workload-table-heading h3 { margin: 0; color: #1e293b; font-size: .98rem; font-weight: 800; }
.dashboard-workload-insights-heading > small,
.dashboard-workload-critical-heading > small { color: #7b8798; font-size: .7rem; }
.dashboard-workload-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .55rem; margin: .75rem 0 1rem; }
.dashboard-workload-summary-card { display: flex; min-height: 64px; align-items: center; gap: .55rem; padding: .55rem .65rem; border: 1px solid #e3e9f1; border-radius: 10px; background: #fff; }
.dashboard-workload-summary-card > i { display: grid; flex: 0 0 32px; height: 32px; place-items: center; color: var(--summary-color); border-radius: 8px; background: color-mix(in srgb, var(--summary-color) 11%, white); }
.dashboard-workload-summary-card span { display: flex; min-width: 0; flex-direction: column; }
.dashboard-workload-summary-card small { overflow: hidden; color: #718096; font-size: .67rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-workload-summary-card strong { color: var(--summary-color); font-size: 1.15rem; line-height: 1.05; }
.dashboard-responsible-detail { margin: .2rem 0 1rem; padding: .85rem; border: 1px solid #dbe6f2; border-radius: 11px; background: #fff; }
.dashboard-responsible-detail-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: .7rem; }
.dashboard-responsible-detail-heading span { display: block; color: #2563eb; font-size: .65rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.dashboard-responsible-detail-heading h4 { margin: .08rem 0 0; color: #1e293b; font-size: 1rem; font-weight: 800; }
.dashboard-responsible-health { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem; margin-bottom: .7rem; }
.dashboard-responsible-health-card { padding: .58rem .65rem; border: 1px solid #e4eaf1; border-radius: 9px; background: #f8fafc; }
.dashboard-responsible-health-card small { display: block; color: #718096; font-size: .65rem; font-weight: 700; }
.dashboard-responsible-health-card strong { display: block; margin-top: .12rem; color: #26364b; font-size: 1rem; }
.dashboard-responsible-breakdown { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.dashboard-responsible-breakdown-card { min-width: 0; padding: .7rem; border: 1px solid #e5ebf2; border-radius: 9px; background: #fbfcfe; }
.dashboard-responsible-breakdown-card .dashboard-workload-critical-heading { padding-top: 0; border-top: 0; }
.dashboard-breakdown-list { display: grid; gap: .38rem; margin-top: .55rem; }
.dashboard-breakdown-row { display: grid; grid-template-columns: minmax(110px, 1fr) minmax(90px, 1fr) auto; align-items: center; gap: .5rem; color: #526175; font-size: .7rem; }
.dashboard-breakdown-row > span:first-child { overflow: hidden; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-breakdown-bar { height: 7px; overflow: hidden; border-radius: 999px; background: #e8edf3; }
.dashboard-breakdown-bar i { display: block; height: 100%; border-radius: inherit; background: var(--breakdown-color, #3182ce); }
.dashboard-breakdown-row strong { color: #334155; font-size: .7rem; white-space: nowrap; }
.dashboard-workload-critical-heading { margin-bottom: .5rem; padding-top: .8rem; border-top: 1px solid #e5ebf2; }
.dashboard-workload-critical-heading h4 { margin: 0; color: #26364b; font-size: .88rem; font-weight: 800; }
.dashboard-workload-critical-wrap { position: relative; min-height: 90px; border: 1px solid #e3e9f1; border-radius: 10px; background: #fff; }
.dashboard-workload-critical { margin: 0; font-size: .74rem; }
.dashboard-workload-critical thead th { color: #5d6c80; border-bottom-color: #e1e8ef; background: #f6f8fb; font-size: .65rem; text-transform: uppercase; }
.dashboard-workload-critical tbody td { border-bottom-color: #edf1f5; }
.dashboard-workload-critical tbody tr:last-child td { border-bottom: 0; }
.dashboard-workload-critical a { color: #1d5f9f; font-weight: 800; text-decoration: none; }
.dashboard-workload-critical .is-overdue { color: #b42318; font-weight: 800; }
.workload-situation-badge { display: inline-flex; align-items: center; padding: .2rem .45rem; color: color-mix(in srgb, var(--workload-color) 78%, #172033); border: 1px solid color-mix(in srgb, var(--workload-color) 35%, white); border-radius: 999px; background: color-mix(in srgb, var(--workload-color) 12%, white); font-size: .66rem; font-weight: 800; white-space: nowrap; }
.dashboard-workload-no-critical { display: none; min-height: 90px; align-items: center; justify-content: center; flex-direction: column; gap: .25rem; color: #718096; text-align: center; }
.dashboard-workload-no-critical.is-visible { display: flex; }
.dashboard-workload-no-critical i { color: #16845b; font-size: 1.25rem; }
.dashboard-workload-no-critical strong { font-size: .78rem; }
.dashboard-workload-table-heading { margin: 1rem 0 .55rem; }
.dashboard-workload-table-wrap { max-height: 320px; border: 1px solid #e5ebf2; border-radius: 10px; }
.dashboard-workload-table { margin: 0; font-size: .76rem; white-space: nowrap; }
.dashboard-workload-table thead { position: sticky; z-index: 1; top: 0; }
.dashboard-workload-table thead th { color: #526175; border-bottom-color: #dfe7ef; background: #f6f8fb; font-size: .68rem; text-transform: uppercase; }
.dashboard-workload-table tbody th { color: #25364b; font-weight: 700; }
.dashboard-workload-table a { color: #1d5f9f; font-weight: 700; text-decoration: none; }
.dashboard-workload-table a:hover { text-decoration: underline; }
.dashboard-workload-table small { color: #77869a; font-size: .68rem; }
.workload-table-dot { display: inline-block; width: 8px; height: 8px; margin-right: .35rem; border-radius: 50%; background: var(--workload-color); }

.dashboard-status-view-tabs { display: inline-flex; gap: .25rem; margin-bottom: .8rem; padding: .25rem; border: 1px solid #dfe7ef; border-radius: 10px; background: #f4f7fa; }
.dashboard-status-view-tabs button { display: inline-flex; align-items: center; gap: .35rem; padding: .45rem .75rem; color: #64748b; border: 0; border-radius: 7px; background: transparent; font-size: .75rem; font-weight: 800; }
.dashboard-status-view-tabs button:hover { color: #1d5f9f; background: #edf4fc; }
.dashboard-status-view-tabs button.is-active { color: #1559a1; background: #fff; box-shadow: 0 2px 8px rgba(15, 23, 42, .09); }
.dashboard-status-filters { grid-template-columns: repeat(4, minmax(135px, 1fr)) auto; }
.dashboard-status-history-filters { grid-template-columns: repeat(3, minmax(160px, 1fr)); }
.dashboard-status-expanded-chart { position: relative; height: clamp(390px, 52vh, 620px); margin-bottom: .5rem; }
.dashboard-status-history-chart { position: relative; height: 260px; margin-bottom: .7rem; }
.dashboard-status-summary,
.dashboard-status-history-summary { margin-top: .5rem; }
.dashboard-status-detail-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: .8rem; }
.dashboard-status-detail-card { min-width: 0; overflow: hidden; padding: .85rem; border: 1px solid #e3eaf2; border-radius: 11px; background: #fbfcfe; }
.dashboard-status-detail-card .dashboard-workload-critical-heading { padding-top: 0; border-top: 0; }
.dashboard-status-detail-card .table-responsive { max-height: 330px; margin-top: .5rem; border: 1px solid #e3e9f1; border-radius: 9px; background: #fff; }
.dashboard-status-detail-card .table { margin-bottom: 0; }
.dashboard-status-detail-card a { color: #1d5f9f; font-weight: 800; text-decoration: none; }
.dashboard-status-name-cell { max-width: 190px; color: #526175; font-size: .68rem; }

.dashboard-empty { display: flex; min-height: 240px; align-items: center; justify-content: center; flex-direction: column; gap: .25rem; color: #94a3b8; text-align: center; }
.dashboard-empty i { margin-bottom: .2rem; font-size: 1.6rem; }
.dashboard-empty strong { color: #526175; font-size: .88rem; }
.dashboard-empty span { max-width: 300px; font-size: .75rem; }
.dashboard-empty-table { min-height: 145px; }
.dashboard-empty-compact { min-height: 90px; }

.dashboard-list-card .table thead th { padding: .65rem .55rem; color: #66758a; border-bottom-color: #e6ebf2; background: #f7f9fc; font-size: .7rem; text-transform: uppercase; }
.dashboard-list-card .table tbody td { padding: .7rem .55rem; border-bottom-color: #edf1f5; font-size: .78rem; }
.dashboard-list-card .table tbody strong { font-size: .78rem; }
.dashboard-list-card .badge { white-space: normal; }

.dashboard-ranking-row,
.dashboard-feed-row { display: flex; gap: .55rem; padding: .65rem 0; border-bottom: 1px solid #edf1f5; }
.dashboard-ranking-row:last-child,
.dashboard-feed-row:last-child { border-bottom: 0; }
.dashboard-ranking-row { align-items: center; justify-content: space-between; }
.dashboard-ranking-row span,
.dashboard-feed-row { flex-direction: column; }
.dashboard-ranking-row span { display: flex; }
.dashboard-ranking-row strong,
.dashboard-feed-row a { color: #26364b; font-size: .78rem; font-weight: 700; text-decoration: none; }
.dashboard-ranking-row small,
.dashboard-feed-row small { color: #8491a3; font-size: .7rem; }
.dashboard-ranking-row b { color: #1763ad; font-size: .82rem; white-space: nowrap; }
.dashboard-feed-row span { color: #536174; font-size: .75rem; }

@media (max-width: 1199.98px) {
    .dashboard-metrics-grid,
    .dashboard-shortcuts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-workload-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-status-filters,
    .dashboard-status-history-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dashboard-status-detail-grid { grid-template-columns: 1fr; }
}

@media (max-width: 575.98px) {
    .dashboard-welcome { align-items: flex-start; padding: 1.15rem; }
    .dashboard-welcome-icon { flex-basis: 44px; height: 44px; border-radius: 12px; font-size: 1.2rem; }
    .dashboard-welcome-actions { align-items: flex-start; flex-direction: column; }
    .dashboard-section-heading { align-items: flex-start; flex-direction: column; gap: .25rem; }
    .dashboard-metrics-grid,
    .dashboard-shortcuts { grid-template-columns: 1fr; }
    .metric-card { min-height: 86px; }
    .dashboard-chart-wrap-status { min-height: 360px; }
    .dashboard-chart-wrap-workload { min-height: 360px; }
    .dashboard-workload-modal .modal-dialog { max-width: calc(100vw - 1rem); margin: .5rem; }
    .dashboard-workload-modal .modal-body { padding: .8rem; }
    .dashboard-workload-filters { grid-template-columns: 1fr; }
    .dashboard-responsible-health,
    .dashboard-responsible-breakdown { grid-template-columns: 1fr; }
    .dashboard-status-filters,
    .dashboard-status-history-filters { grid-template-columns: 1fr; }
    .dashboard-workload-expanded-chart { height: 430px; }
    .dashboard-status-expanded-chart { height: 480px; }
    .dashboard-status-view-tabs { display: flex; }
    .dashboard-status-view-tabs button { flex: 1; justify-content: center; }
    .dashboard-workload-insights-heading,
    .dashboard-workload-critical-heading { align-items: flex-start; flex-direction: column; gap: .2rem; }
    .dashboard-workload-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.charge-textarea {
    min-height: 7rem;
    resize: vertical;
    overflow: auto;
}

.quality-confirm-box{padding:.85rem 1rem;border:1px solid #f0c36a;border-radius:.65rem;background:#fff8e6}
.checklist-total-progress{display:flex;align-items:baseline;gap:.4rem;color:#334155}.checklist-total-progress strong{font-size:1.35rem;color:#0f766e}.checklist-total-progress span{font-size:.82rem}
.checklist-module-picker{border:1px solid #dbe5ef;border-radius:.7rem;padding:.75rem 1rem;background:#f8fafc}.checklist-module-picker>summary,.checklist-item-details>summary{cursor:pointer;font-weight:700;color:#315f7d}
.module-option{height:100%;padding:.7rem .8rem;border:1px solid #dbe5ef;border-radius:.55rem;background:#fff;gap:.55rem;align-items:flex-start}.module-option .form-check-input{margin-left:0;flex:0 0 auto}
.checklist-filters{display:flex;flex-wrap:wrap;gap:.45rem}
.checklist-module-card{border:1px solid #dbe5ef;border-radius:.75rem;margin-bottom:.75rem;overflow:hidden;background:#fff}.checklist-module-card>summary{display:flex;justify-content:space-between;align-items:center;gap:1rem;padding:.9rem 1rem;cursor:pointer;font-weight:800;background:#f5f8fb;list-style:none}.checklist-module-card>summary::-webkit-details-marker{display:none}.checklist-module-card>summary:before{content:'›';font-size:1.3rem;transition:transform .15s}.checklist-module-card[open]>summary:before{transform:rotate(90deg)}.checklist-module-card>summary>span:first-of-type{flex:1}.checklist-module-progress{font-size:.82rem;padding:.2rem .55rem;border-radius:999px;background:#dceef0;color:#17696b}
.checklist-module-items{padding:0 1rem}.checklist-item{padding:1rem 0;border-bottom:1px solid #e7edf3}.checklist-item:last-child{border-bottom:0}.checklist-item.is-pending{border-left:3px solid #e9a23b;padding-left:.8rem}.checklist-item.is-done{opacity:.82}.checklist-item-main{display:flex;align-items:flex-start;gap:1rem}.checklist-decisions{display:flex;gap:.7rem;min-width:112px}.checklist-decisions label{display:flex;align-items:center;gap:.28rem;font-size:.82rem;font-weight:700;white-space:nowrap}.checklist-item-copy{display:flex;align-items:center;flex-wrap:wrap;gap:.45rem;flex:1}.checklist-item-copy small{display:block;flex-basis:100%;color:#718096}.checklist-item-details{margin:.65rem 0 0 128px}.checklist-item-details>summary{font-size:.8rem;font-weight:600}.checklist-empty-filter{padding:1.5rem;text-align:center;color:#718096;background:#f8fafc;border-radius:.6rem}
@media(max-width:767px){.checklist-item-main{display:block}.checklist-decisions{margin-bottom:.65rem}.checklist-item-details{margin-left:0}.checklist-module-items{padding:0 .75rem}}

/* Relatórios: muitos recursos com complexidade progressiva */
.report-filter-card{padding:1.15rem;border-color:#dbe5ef;box-shadow:0 8px 24px rgba(15,23,42,.045)}
.report-filter-head{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;flex-wrap:wrap;padding-bottom:1rem;border-bottom:1px solid #e8eef4}
.report-filter-title{font-size:1rem;font-weight:800;color:#1e3a5f;display:flex;align-items:center;gap:.5rem}
.report-period-badge,.report-comparison-badge{display:inline-flex;align-items:center;gap:.4rem;border-radius:999px;padding:.38rem .7rem;font-size:.78rem;font-weight:700;white-space:nowrap}
.report-period-badge{background:#e8f1ff;color:#1d4ed8;border:1px solid #c7dcff}
.report-comparison-badge{background:#f8fafc;color:#526176;border:1px solid #dde5ee}
.report-quick-filters{display:flex;align-items:center;gap:.45rem;flex-wrap:wrap;padding:1rem 0 .85rem}
.report-quick-filters .btn{border-radius:999px;padding:.36rem .85rem;font-weight:650}
.report-more-periods{position:relative}
.report-more-periods>summary{display:flex;align-items:center;gap:.4rem;cursor:pointer;color:#526176;font-size:.82rem;font-weight:700;padding:.38rem .7rem;list-style:none;border-radius:999px}
.report-more-periods>summary::-webkit-details-marker{display:none}
.report-more-periods[open]>summary{background:#f1f5f9;color:#1e3a5f}
.report-more-periods[open]>summary i{transform:rotate(180deg)}
.report-more-periods-menu{position:absolute;z-index:20;top:calc(100% + .4rem);left:0;display:flex;gap:.4rem;flex-wrap:wrap;min-width:320px;padding:.7rem;background:#fff;border:1px solid #dbe5ef;border-radius:.75rem;box-shadow:0 12px 30px rgba(15,23,42,.14)}
.report-primary-filters{padding-bottom:1rem}
.report-primary-filters .form-label,.report-filter-section-body .form-label{font-size:.78rem;font-weight:750;color:#526176;margin-bottom:.32rem}
.report-filter-sections{border-top:1px solid #e8eef4}
.report-filter-section{border-top:1px solid #e8eef4}
.report-filter-sections .report-filter-section:first-child{border-top:0}
.report-filter-section>summary{display:flex;justify-content:space-between;align-items:center;gap:1rem;cursor:pointer;padding:.85rem .15rem;list-style:none;color:#31546f}
.report-filter-section>summary::-webkit-details-marker{display:none}
.report-filter-section>summary span{display:flex;align-items:center;gap:.55rem;font-weight:750}
.report-filter-section>summary span:after{content:'›';font-size:1.25rem;line-height:1;transition:transform .15s}
.report-filter-section[open]>summary span:after{transform:rotate(90deg)}
.report-filter-section>summary small{color:#718096;font-size:.76rem;text-align:right}
.report-filter-section-body{padding:.15rem .15rem 1rem}
.report-filter-footer{display:flex;align-items:center;justify-content:space-between;gap:.75rem;flex-wrap:wrap;padding-top:.8rem;border-top:1px solid #e8eef4;color:#718096;font-size:.76rem}
.report-filter-footer a{text-decoration:none;font-weight:700;white-space:nowrap}
.report-custom-comparison[hidden]{display:none!important}
@media(max-width:767px){
  .report-filter-card{padding:.9rem}
  .report-filter-head{display:block}
  .report-filter-head>.d-flex{margin-top:.65rem}
  .report-period-badge,.report-comparison-badge{font-size:.72rem}
  .report-quick-filters{gap:.35rem}
  .report-quick-filters .btn{padding:.33rem .66rem}
  .report-more-periods{position:static}
  .report-more-periods-menu{left:.9rem;right:.9rem;min-width:0}
  .report-filter-section>summary{align-items:flex-start}
  .report-filter-section>summary small{max-width:45%}
}
.workspace-preview-name{padding:1rem 1.1rem;border:1px dashed #74a7af;border-radius:.7rem;background:#f0fafa;color:#175c63;font-weight:800;word-break:break-word}.workspace-action{display:flex;align-items:flex-start;gap:.8rem;padding:1rem;border:1px solid #dbe5ef;border-radius:.7rem;margin-bottom:.75rem;background:#f8fafc;cursor:pointer}.workspace-action .form-check-input{flex:0 0 auto;margin-top:.2rem}.workspace-action span{display:flex;flex-direction:column;gap:.2rem}.workspace-action small{color:#718096}.workspace-folder-tree{list-style:none;padding:0;margin:1rem 0 0}.workspace-folder-tree li{padding:.65rem .8rem;margin-bottom:.4rem;border-radius:.5rem;background:#f5f8fb;border-left:3px solid #2a8f91;font-weight:650;font-size:.9rem}

/* Tarefas: leitura compacta, prioridades claras e ações progressivas */
.task-tabs{display:flex;flex-wrap:wrap;gap:.55rem}
.task-tab{display:flex;align-items:center;justify-content:space-between;gap:1rem;min-width:145px;padding:.62rem .8rem;border:1px solid #dbe5ef;border-radius:.7rem;background:#fff;color:#43546a;text-decoration:none;font-size:.84rem;font-weight:750;box-shadow:0 4px 14px rgba(15,23,42,.04)}
.task-tab:hover{border-color:#9ab8d6;color:#175f9f}
.task-tab strong{display:inline-flex;align-items:center;justify-content:center;min-width:1.7rem;height:1.7rem;padding:0 .42rem;border-radius:999px;background:#edf2f7;color:#526176;font-size:.75rem}
.task-tab.active{border-color:#1763ad;background:#eaf3ff;color:#154f83;box-shadow:0 5px 16px rgba(23,99,173,.12)}
.task-tab.active strong{background:#1763ad;color:#fff}
.task-filter-card .form-label{margin-bottom:.3rem;color:#526176;font-size:.78rem;font-weight:750}
.task-list-card{overflow:visible}
.task-list-card .table-responsive{overflow-x:auto;overflow-y:visible}
.task-table{min-width:1050px}
.task-table thead th{padding:.68rem .65rem;border-bottom:1px solid #dfe7ef;background:#101a2e;color:#fff;font-size:.73rem;text-transform:uppercase;letter-spacing:.025em}
.task-table tbody td{padding:.78rem .65rem;border-bottom:1px solid #e7edf3;background:#fff;font-size:.82rem;vertical-align:middle}
.task-table tbody tr:last-child td{border-bottom:0}
.task-table tbody tr:hover td{background:#f8fafc}
.task-row.task-overdue td:first-child{box-shadow:inset 4px 0 0 #dc3545;padding-left:1rem}
.task-row.task-completed .task-title{text-decoration:line-through;text-decoration-color:#94a3b8}
.task-row.task-completed td{color:#718096;background:#fbfcfd}
.task-main-cell{width:42%;min-width:380px}
.task-title{color:#17243a;font-size:.88rem}
.task-description{display:-webkit-box;max-width:760px;margin-top:.28rem;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:2;line-height:1.35;white-space:pre-line}
.task-description.expanded{display:block;overflow:visible;-webkit-line-clamp:unset}
.task-description-toggle{margin-top:.18rem;padding:0;border:0;background:transparent;color:#1763ad;font-size:.74rem;font-weight:750}
.task-description-toggle:hover{text-decoration:underline}
.task-process-cell{max-width:230px}
.task-process-cell a{display:flex;flex-direction:column;gap:.1rem;color:#1763ad;text-decoration:none}
.task-process-cell a:hover{text-decoration:underline}
.task-process-cell span{display:-webkit-box;overflow:hidden;-webkit-box-orient:vertical;-webkit-line-clamp:2;line-height:1.3}
.task-responsible{display:inline-flex;align-items:center;gap:.35rem;max-width:170px}
.task-responsible i{color:#718096}
.task-table .badge{font-size:.7rem;font-weight:750;white-space:nowrap}
.task-table .dropdown-menu{min-width:185px;font-size:.82rem;box-shadow:0 10px 28px rgba(15,23,42,.14)}
.task-table .dropdown-item{padding:.48rem .8rem}
.task-empty{display:flex;min-height:180px;align-items:center;justify-content:center;flex-direction:column;gap:.25rem;color:#718096;text-align:center}
.task-empty i{font-size:2rem;color:#2a8f91}
.task-empty strong{color:#43546a}
.task-empty span{font-size:.8rem}
@media(max-width:767px){.task-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.task-tab{min-width:0}.task-main-cell{min-width:300px}.task-filter-card{padding:.85rem!important}}

/* Desenvolvimento: painel focado somente nos acompanhamentos iniciados */
.development-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:.75rem}
.development-metric{display:flex;align-items:center;gap:.8rem;min-height:105px;padding:1rem;border:1px solid #e1e8f0;border-radius:.8rem;background:#fff;color:#28384c;text-decoration:none;box-shadow:0 6px 18px rgba(15,23,42,.05);transition:border-color .15s,transform .15s,box-shadow .15s}
.development-metric:hover{border-color:#9cbad7;color:#1d4f7a;transform:translateY(-1px);box-shadow:0 8px 22px rgba(15,23,42,.08)}
.development-metric.active{border-color:#1763ad;box-shadow:0 0 0 2px rgba(23,99,173,.08),0 8px 22px rgba(15,23,42,.07)}
.development-metric-icon{display:inline-flex;align-items:center;justify-content:center;flex:0 0 2.55rem;width:2.55rem;height:2.55rem;border-radius:.7rem;font-size:1.15rem}
.development-metric>span:last-child{display:flex;min-width:0;flex-direction:column}
.development-metric small{color:#64748b;font-size:.73rem;font-weight:750;text-transform:uppercase;letter-spacing:.025em}
.development-metric strong{font-size:1.65rem;line-height:1.15}
.development-metric em{overflow:hidden;color:#7b899a;font-size:.72rem;font-style:normal;text-overflow:ellipsis;white-space:nowrap}
.development-filter-card .form-label{margin-bottom:.3rem;color:#526176;font-size:.78rem;font-weight:750}
.development-list-card{overflow:visible}
.development-list-card .table-responsive{overflow-x:auto;overflow-y:visible}
.development-table{min-width:1120px}
.development-table thead th{padding:.68rem .6rem;border-bottom:1px solid #dfe7ef;background:#101a2e;color:#fff;font-size:.7rem;text-transform:uppercase;letter-spacing:.025em;white-space:nowrap}
.development-table tbody td{padding:.78rem .6rem;border-bottom:1px solid #e7edf3;font-size:.8rem}
.development-table tbody tr:last-child td{border-bottom:0}
.development-table tbody tr:hover td{background:#f8fafc}
.development-table tr.development-needs-attention td:first-child{box-shadow:inset 3px 0 0 #f2b134;padding-left:.85rem}
.development-person{display:flex;align-items:center;gap:.65rem;min-width:190px;color:#203146;text-decoration:none}
.development-person:hover strong{color:#1763ad;text-decoration:underline}
.development-person>span:last-child{display:flex;min-width:0;flex-direction:column}
.development-person small{max-width:190px;overflow:hidden;color:#718096;text-overflow:ellipsis;white-space:nowrap}
.development-avatar{display:inline-flex;align-items:center;justify-content:center;flex:0 0 2rem;width:2rem;height:2rem;border-radius:999px;background:#e9f2fb;color:#1763ad;font-weight:800}
.development-attention{color:#b7791f;font-size:.78rem;font-weight:750;white-space:nowrap}
.development-progress{display:flex;align-items:center;gap:.45rem;min-width:105px}
.development-progress .progress{width:70px;height:.45rem;background:#e7edf3}
.development-progress .progress-bar{background:#2a8f91}
.development-progress span{font-size:.74rem;font-weight:750}
.development-empty{display:flex;min-height:170px;align-items:center;justify-content:center;flex-direction:column;gap:.25rem;color:#718096;text-align:center}
.development-empty i{font-size:2rem;color:#2a8f91}
.development-empty strong{color:#43546a}
.development-empty span{font-size:.8rem}
.development-action-alert{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.85rem 1rem;border:1px solid #f0c36a;border-left:4px solid #e3a21a;border-radius:.7rem;background:#fff8e6}
.development-action-alert>div:first-child{display:flex;flex-direction:column;gap:.15rem}
.development-action-alert strong{color:#7a5300}
.development-action-alert span{color:#715f39;font-size:.82rem}
.development-readiness-progress{width:180px;height:.45rem;background:#e7edf3}
@media(max-width:1199.98px){.development-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:767px){.development-metrics{grid-template-columns:1fr}.development-metric{min-height:88px}.development-action-alert{align-items:flex-start;flex-direction:column}.development-filter-card{padding:.85rem!important}}
.text-bg-orange {
    color: #212529 !important;
    background-color: #fd7e14 !important;
}

/* Tema claro/escuro: o Bootstrap cobre os componentes padrão e estes ajustes
   mantêm as superfícies próprias do HYDRA consistentes e legíveis. */
.app-theme-toggle {
    display: inline-flex;
    min-width: 38px;
    align-items: center;
    justify-content: center;
    gap: .4rem;
    white-space: nowrap;
}

.theme-toggle-guest {
    position: fixed;
    z-index: 1030;
    top: 1rem;
    right: 1rem;
}

@media (max-width: 575.98px) {
    .app-topbar .app-theme-toggle span { display: none; }
    .theme-toggle-guest .app-theme-toggle span { display: none; }
}

[data-bs-theme="dark"] {
    --app-ink: #e5edf7;
    --app-muted: #9badc2;
    --app-line: #334155;
    --app-sidebar: #080d18;
    --app-sidebar-soft: #172033;
    --app-accent: #60a5fa;
    --app-text: #e5edf7;
    --app-primary: #60a5fa;
    --bs-body-bg: #0b1120;
    --bs-body-color: #dce5f0;
    --bs-border-color: #344054;
    --bs-secondary-color: #aebccd;
    --bs-tertiary-bg: #1a2535;
}

[data-bs-theme="dark"] body { background: #0b1120; }
[data-bs-theme="dark"] .card {
    background-color: #151f2f;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .24);
}
[data-bs-theme="dark"] .app-topbar { background: rgba(15, 23, 42, .9); }
[data-bs-theme="dark"] .app-sidebar { box-shadow: 8px 0 28px rgba(0, 0, 0, .18); }
[data-bs-theme="dark"] .table { --bs-table-bg: transparent; --bs-table-color: #dce5f0; --bs-table-border-color: #344054; }
[data-bs-theme="dark"] .table thead th,
[data-bs-theme="dark"] .task-table thead th,
[data-bs-theme="dark"] .development-table thead th { background: #080d18; color: #f8fafc; }
[data-bs-theme="dark"] .table-hover > tbody > tr:hover > * { --bs-table-bg-state: #1d2a3d; }
[data-bs-theme="dark"] :is(.bg-light, .text-bg-light) { background-color: #243146 !important; color: #e5edf7 !important; }
[data-bs-theme="dark"] .btn-close:not(.btn-close-white) { filter: invert(1) grayscale(100%) brightness(180%); }
[data-bs-theme="dark"] .dropdown-menu { --bs-dropdown-bg: #172235; --bs-dropdown-link-color: #dce5f0; --bs-dropdown-link-hover-bg: #243146; }
[data-bs-theme="dark"] .modal-content,
[data-bs-theme="dark"] .offcanvas:not(.app-mobile-menu) { background-color: #151f2f; color: #dce5f0; }

[data-bs-theme="dark"] :is(
    .form-section, .summary-panel, .process-tab, .reset-final-card,
    .config-section-nav, .dashboard-panel, .dashboard-shortcuts > a,
    .dashboard-workload-summary-card, .dashboard-responsible-detail,
    .dashboard-workload-critical-wrap, .dashboard-status-detail-card,
    .dashboard-status-detail-card .table-responsive, .module-option,
    .checklist-module-card, .report-more-periods-menu, .task-tab,
    .development-metric
) { background: #151f2f; border-color: #344054; color: #dce5f0; }

[data-bs-theme="dark"] :is(
    .form-switch-row, .dashboard-filter-bar, .dashboard-status-detail-card,
    .checklist-module-card > summary, .checklist-empty-filter,
    .workspace-action, .workspace-folder-tree li
) { background: #111b2b; border-color: #344054; }

[data-bs-theme="dark"] :is(
    .form-action-bar, .config-save-bar, .permission-save-bar, .process-section-nav
) { background: rgba(15, 23, 42, .96); border-color: #344054; }

[data-bs-theme="dark"] :is(
    .dashboard-shortcuts > a, .dashboard-ranking-row strong,
    .dashboard-feed-row a, .task-title, .development-person,
    .development-metric
) { color: #dce5f0; }

[data-bs-theme="dark"] :is(
    .dashboard-metric-card, .dashboard-chart-card, .dashboard-list-card,
    .dashboard-workload-card, .dashboard-status-card
) { border-color: #344054; }

[data-bs-theme="dark"] .dashboard-list-card .table thead th { background: #111b2b; color: #aebccd; border-bottom-color: #344054; }
[data-bs-theme="dark"] :is(.task-table tbody td, .development-table tbody td) { background: #151f2f; border-bottom-color: #344054; }
[data-bs-theme="dark"] :is(.task-table tbody tr:hover td, .development-table tbody tr:hover td) { background: #1d2a3d; }
[data-bs-theme="dark"] .task-row.task-completed td { background: #111b2b; color: #9badc2; }
[data-bs-theme="dark"] .dashboard-status-view-tabs button.is-active { background: #243146; color: #93c5fd; }
[data-bs-theme="dark"] :is(.reset-impact-grid > div, .reset-final-icon, .reset-final-total, .reset-final-check, .quality-confirm-box, .development-action-alert) {
    background: #33281a;
    border-color: #735b2a;
}
[data-bs-theme="dark"] :is(.quality-confirm-box, .development-action-alert strong, .development-action-alert span) { color: #f6d58b; }
[data-bs-theme="dark"] .small-muted { color: #9badc2; }
[data-bs-theme="dark"] input::placeholder,
[data-bs-theme="dark"] textarea::placeholder { color: #7f90a6; opacity: 1; }

@media (prefers-reduced-motion: reduce) {
    .app-theme-toggle, .app-theme-toggle * { transition: none !important; }
}
