:root {
    color-scheme: light;
    --ink: #17212b;
    --muted: #647381;
    --line: #dfe7ed;
    --surface: #ffffff;
    --bg: #eef4f5;
    --teal: #147d78;
    --teal-dark: #0c5c59;
    --teal-soft: #dff2ef;
    --danger: #a64040;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background: radial-gradient(circle at top left, #ffffff 0, var(--bg) 48%, #dce9ec 100%);
}

.page-shell {
    width: min(1100px, calc(100% - 40px));
    min-height: 100vh;
    margin: 0 auto;
    padding: 72px 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 440px);
    align-content: center;
    gap: 72px;
}

.brand-panel { align-self: center; }
.eyebrow { color: var(--teal); font-size: .76rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
h1, h2, p { margin-top: 0; }
h1 { max-width: 560px; margin-bottom: 20px; font-size: clamp(2.4rem, 6vw, 5rem); line-height: .98; letter-spacing: -.055em; }
h2 { margin: 8px 0 10px; font-size: 1.65rem; letter-spacing: -.03em; }
.brand-panel > p { max-width: 460px; color: var(--muted); font-size: 1.08rem; line-height: 1.6; }
.muted { color: var(--muted); line-height: 1.55; }

.card { padding: 34px; background: rgba(255, 255, 255, .94); border: 1px solid rgba(223, 231, 237, .95); border-radius: 24px; box-shadow: 0 24px 70px rgba(41, 70, 78, .12); }
label { display: block; margin: 20px 0 8px; font-size: .88rem; font-weight: 700; }
input { width: 100%; padding: 13px 14px; color: var(--ink); background: #fbfdfd; border: 1px solid var(--line); border-radius: 10px; font: inherit; outline: none; }
input:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(20, 125, 120, .14); }
.input-with-action { position: relative; display: flex; align-items: center; }
.input-with-action input { padding-right: 78px; }
.input-action { position: absolute; right: 8px; min-height: 30px; padding: 0 8px; color: var(--teal-dark); background: var(--surface-tint); border: 1px solid #cbe3df; border-radius: 7px; font: inherit; font-size: .68rem; font-weight: 750; cursor: pointer; }
.input-action:hover { background: #e4f4f0; border-color: #9fc8c4; }
textarea { display: block; width: 100%; max-width: 100%; min-height: 120px; padding: 13px 14px; color: var(--ink); background: #fbfdfd; border: 1px solid var(--line); border-radius: 10px; font: inherit; line-height: 1.5; outline: none; resize: vertical; overflow: auto; }
textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(20, 125, 120, .14); }
.button { min-height: 46px; padding: 0 18px; border: 0; border-radius: 10px; font: inherit; font-weight: 800; cursor: pointer; }
.button-primary { width: 100%; margin-top: 26px; color: #fff; background: var(--teal); }
.button-primary:hover { background: var(--teal-dark); }
.button-quiet { color: var(--teal-dark); background: transparent; }
.health-chip { display: inline-flex; margin-top: 30px; padding: 9px 12px; color: var(--teal-dark); background: var(--teal-soft); border-radius: 999px; font-size: .82rem; font-weight: 700; }
.health-chip.is-error { color: var(--danger); background: #f9e4e4; }
.alert { margin: 18px 0 -2px; padding: 12px; color: var(--danger); background: #fff0f0; border: 1px solid #f1caca; border-radius: 10px; font-size: .9rem; line-height: 1.4; }
.mfa-copy { padding: 12px; color: var(--teal-dark); background: var(--teal-soft); border-radius: 10px; line-height: 1.45; }
.check-row { display: flex; align-items: center; gap: 8px; font-weight: 500; }
.check-row input { width: auto; }
.dashboard { grid-column: 1 / -1; }
.dashboard-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.metric-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 28px 0; }
.metric { padding: 18px; background: #f5f9f9; border: 1px solid var(--line); border-radius: 14px; }
.metric strong, .metric span { display: block; }
.metric span { margin-top: 6px; color: var(--muted); font-size: .85rem; }

@media (max-width: 780px) {
    .page-shell { grid-template-columns: 1fr; gap: 34px; padding: 42px 0; }
    h1 { font-size: clamp(2.4rem, 14vw, 4rem); }
    .metric-grid { grid-template-columns: 1fr; }
}

/* Painel Central */
.page-shell:has(.app-shell:not([hidden])) { width: 100%; min-height: 100vh; margin: 0; padding: 0; display: block; }
.page-shell:has(.app-shell:not([hidden])) .brand-panel { display: none; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 248px minmax(0, 1fr); gap: 0; overflow: visible; background: rgba(255,255,255,.72); border: 0; border-radius: 0; box-shadow: none; }
.sidebar { position: sticky; top: 0; z-index: 5; display: flex; height: 100vh; min-height: 100vh; flex-direction: column; padding: 22px 14px; color: #e9f8f5; background: #103f42; }
.sidebar-brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 28px; }
.sidebar-brand strong, .sidebar-brand small { display: block; }
.sidebar-brand small { margin-top: 3px; color: #a9ceca; font-size: .7rem; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; color: #103f42; background: #b7eee2; border-radius: 11px; font-size: .75rem; font-weight: 900; }
.nav-list { display: grid; gap: 5px; overflow-y: auto; scrollbar-width: thin; }
.nav-item { display: flex; align-items: center; gap: 11px; width: 100%; padding: 12px 11px; color: #b5d5d1; background: transparent; border: 0; border-radius: 10px; font: inherit; font-size: .88rem; font-weight: 700; text-align: left; cursor: pointer; }
.nav-item span { width: 19px; color: #87b9b3; font-size: 1.05rem; text-align: center; }
.nav-item:hover, .nav-item.is-active { color: #fff; background: rgba(183,238,226,.13); }
.nav-item.is-active span { color: #b7eee2; }
.sidebar-footer { display: flex; align-items: center; gap: 8px; margin-top: auto; padding: 16px 8px 4px; color: #a9ceca; font-size: .72rem; }
.status-dot { width: 7px; height: 7px; background: #79e2a8; border-radius: 50%; box-shadow: 0 0 0 4px rgba(121,226,168,.12); }
.workspace { min-width: 0; min-height: 100vh; padding: 30px 42px 42px; background: #f8fbfb; }
.topbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 25px; }
.topbar h2 { margin-bottom: 0; }
.topbar-actions { display: flex; align-items: center; gap: 13px; }
.user-pill { max-width: 240px; overflow: hidden; padding: 8px 12px; color: var(--teal-dark); background: var(--teal-soft); border-radius: 999px; font-size: .78rem; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.view { min-width: 0; animation: view-in .18s ease-out; }
@keyframes view-in { from { opacity: .3; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.app-alert { margin: 0 0 18px; }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.section-heading h3 { margin: 0 0 4px; font-size: 1.2rem; letter-spacing: -.025em; }
.section-heading p { margin: 0; color: var(--muted); font-size: .86rem; }
.button-small { min-height: 38px; padding: 0 13px; font-size: .78rem; }
.button-outline { color: var(--teal-dark); background: #fff; border: 1px solid #b9d8d5; }
.button-danger { color: #9e3d43; background: #fff2f2; }
.overview-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.overview-card { padding: 19px; background: #fff; border: 1px solid var(--line); border-radius: 15px; }
.overview-card .metric-label { color: var(--muted); font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.overview-card .metric-number { display: block; margin-top: 12px; color: var(--ink); font-size: 2rem; letter-spacing: -.05em; }
.overview-card .metric-note { display: block; margin-top: 8px; color: var(--muted); font-size: .76rem; }
.overview-columns { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr); gap: 18px; }
.panel { padding: 21px; background: #fff; border: 1px solid var(--line); border-radius: 15px; }
.panel h3 { margin: 0 0 15px; font-size: 1rem; }
.activity-list { display: grid; gap: 2px; }
.activity-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid #edf2f3; font-size: .83rem; }
.activity-item:last-child { border-bottom: 0; }
.activity-item strong { display: block; font-size: .82rem; }
.activity-item small { display: block; margin-top: 4px; color: var(--muted); }
.empty-state { padding: 28px 14px; color: var(--muted); text-align: center; font-size: .86rem; }
.toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 15px; }
.toolbar input, .toolbar select { width: auto; min-width: 160px; padding: 10px 11px; }
.toolbar input { flex: 1; max-width: 330px; }
.toolbar input[type="date"] { flex: 0 1 150px; max-width: 170px; }
.toolbar select { max-width: 190px; }
.data-panel { overflow: hidden; padding: 0; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 650px; }
th, td { padding: 14px 17px; border-bottom: 1px solid #edf2f3; font-size: .8rem; text-align: left; vertical-align: middle; }
th { color: var(--muted); background: #fbfdfd; font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; }
tr:last-child td { border-bottom: 0; }
td strong, td span { display: block; }
td strong { font-size: .82rem; }
td small { display: block; margin-top: 4px; color: var(--muted); }
.badge { display: inline-block; padding: 5px 8px; border-radius: 999px; color: #49616a; background: #eef3f4; font-size: .7rem; font-weight: 800; }
.badge-success { color: #176f54; background: #e2f6ed; }
.badge-warning { color: #83631d; background: #fff4d6; }
.badge-danger { color: #9e3d43; background: #ffe7e7; }
.row-actions { display: flex; flex-wrap: wrap; gap: 7px; }
.link-button { padding: 4px 0; color: var(--teal-dark); background: transparent; border: 0; font: inherit; font-size: .75rem; font-weight: 800; cursor: pointer; }
.link-button.danger { color: #a64040; }
.pagination { display: flex; align-items: center; justify-content: space-between; padding: 13px 17px; color: var(--muted); font-size: .75rem; }
.pagination-actions { display: flex; gap: 5px; }
.pagination button { min-height: 30px; padding: 0 9px; color: var(--teal-dark); background: #fff; border: 1px solid var(--line); border-radius: 7px; font: inherit; cursor: pointer; }
.pagination button:disabled { cursor: default; opacity: .45; }
.modal-backdrop { position: fixed; z-index: 10; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(16,63,66,.45); }
.modal { width: min(100%, 570px); max-height: min(90vh, 760px); overflow: auto; padding: 28px; }
.modal-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.modal-heading h2 { margin-bottom: 0; }
.icon-button { width: 32px; height: 32px; color: var(--muted); background: #f1f6f6; border: 0; border-radius: 50%; font-size: 1.35rem; line-height: 1; cursor: pointer; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 15px; }
.form-grid .full { grid-column: 1 / -1; }
.modal form label { margin-top: 14px; }
.modal .button-primary { margin-top: 24px; }
.form-help { margin: 6px 0 0; color: var(--muted); font-size: .75rem; line-height: 1.45; }
.course-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.course-card { padding: 18px; background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.course-card h3 { margin: 0 0 8px; font-size: .98rem; }
.course-card p { min-height: 36px; margin: 0 0 16px; color: var(--muted); font-size: .78rem; }
.course-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 13px; border-top: 1px solid #edf2f3; }
.course-details { margin-top: 12px; padding: 12px; color: var(--muted); background: #f6fafa; border-radius: 9px; font-size: .78rem; }
.audit-meta { color: var(--muted); font-size: .75rem; }
.loading-state { padding: 38px 14px; color: var(--muted); text-align: center; font-size: .86rem; }
.report-filters { margin-bottom: 18px; }
.list-toolbar { display: grid; grid-template-columns: minmax(220px, 1.8fr) minmax(150px, .8fr) auto; align-items: end; gap: 12px; margin: 0 0 12px; padding: 14px; background: var(--surface-tint); border: 1px solid var(--line); border-radius: 12px; box-shadow: none; }
.list-toolbar label { display: block; margin-bottom: 6px; color: var(--muted); font-size: .68rem; font-weight: 750; }
.list-toolbar input, .list-toolbar select { width: 100%; min-height: 40px; padding: 10px 12px; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 9px; font: inherit; }
.list-toolbar-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.list-result-count { margin: 0 0 12px; color: var(--muted); font-size: .72rem; }
.report-filters select, .settings-grid select { width: 100%; padding: 13px 14px; color: var(--ink); background: #fbfdfd; border: 1px solid var(--line); border-radius: 10px; font: inherit; }
.report-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 22px; }
.report-actions .button-primary { width: auto; margin-top: 0; }
.report-result { min-width: 0; }
.report-summary { margin-top: 0; }
.success-box { padding: 16px; color: #176f54; background: #e2f6ed; border: 1px solid #bfe5d2; border-radius: 12px; font-size: .85rem; }
.success-box a { color: #0b654d; font-weight: 800; }
.success-box small { display: block; margin-top: 6px; }
.profile-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.profile-card { padding: 18px; background: #fff; border: 1px solid var(--line); border-radius: 14px; }
.profile-card .section-heading { align-items: flex-start; margin-bottom: 14px; }
.profile-card h3 { margin-bottom: 5px; font-size: .98rem; }
.profile-card p { margin: 0; }
.profile-count { display: grid; place-items: center; min-width: 30px; height: 30px; color: var(--teal-dark); background: var(--teal-soft); border-radius: 50%; font-weight: 900; }
.permission-list { display: flex; flex-wrap: wrap; gap: 6px; }
.permission-list span { padding: 5px 7px; color: #536a72; background: #f1f5f5; border-radius: 6px; font-size: .68rem; }
.settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-bottom: 18px; }
.settings-grid .panel h3 { margin-bottom: 4px; }
.settings-grid .button-primary { width: auto; margin-top: 22px; }
.templates-panel { margin-top: 18px; }
.template-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.template-item { display: grid; gap: 5px; padding: 14px; color: var(--ink); background: #fbfdfd; border: 1px solid var(--line); border-radius: 10px; text-align: left; cursor: pointer; }
.template-item:hover { border-color: #a6d1cd; background: #f3fbfa; }
.template-item strong { color: var(--teal-dark); font-size: .78rem; }
.template-item span { overflow: hidden; font-size: .8rem; text-overflow: ellipsis; white-space: nowrap; }
.template-item small { color: var(--muted); font-size: .7rem; }
.permission-picker { display: grid; max-height: 280px; overflow: auto; gap: 3px; padding: 9px; background: #f7fafa; border: 1px solid var(--line); border-radius: 10px; }
.permission-picker .check-row { align-items: flex-start; margin: 0; padding: 8px; }
.permission-picker .check-row:hover { background: #fff; border-radius: 7px; }
.permission-picker .check-row span { display: grid; gap: 3px; }
.permission-picker .check-row strong { font-size: .75rem; }
.permission-picker .check-row small { color: var(--muted); font-size: .7rem; font-weight: 400; }

@media (max-width: 1000px) {
    .overview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .overview-columns { grid-template-columns: 1fr; }
    .course-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .profile-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 780px) {
    .page-shell:has(.app-shell:not([hidden])) { width: 100%; padding: 0; }
    .app-shell { min-height: 100vh; grid-template-columns: 1fr; border-radius: 0; }
    .sidebar { padding: 14px; }
    .sidebar-brand { padding-bottom: 14px; }
    .nav-list { display: flex; overflow-x: auto; }
    .nav-item { min-width: max-content; }
    .sidebar-footer { display: none; }
    .workspace { padding: 24px 16px 36px; }
    .topbar { align-items: flex-start; flex-direction: column; }
    .topbar-actions { width: 100%; justify-content: space-between; }
    .toolbar { align-items: stretch; flex-direction: column; }
    .toolbar input, .toolbar select { width: 100%; max-width: none; }
    .form-grid, .course-card-grid { grid-template-columns: 1fr; }
    .form-grid .full { grid-column: auto; }
    .settings-grid, .template-list, .profile-grid { grid-template-columns: 1fr; }
}

/* Design system Transoft — camada visual consolidada */
:root {
    --ink: #17252f;
    --ink-soft: #41535d;
    --muted: #71828b;
    --line: #e4ebee;
    --line-strong: #d3dfe3;
    --surface: #ffffff;
    --surface-subtle: #f7fafb;
    --surface-tint: #eef7f6;
    --canvas: #f4f7f8;
    --navy: #152b38;
    --navy-deep: #10232e;
    --teal: #117b75;
    --teal-dark: #075b58;
    --teal-soft: #dff2ef;
    --brand-primary: #117b75;
    --brand-accent: #c3eee6;
    --accent: #d4a449;
    --danger: #b54b54;
    --shadow-sm: 0 1px 2px rgba(18, 39, 48, .04), 0 5px 16px rgba(18, 39, 48, .04);
    --shadow-md: 0 14px 34px rgba(18, 39, 48, .08);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html { background: var(--canvas); }
body { color: var(--ink); background: var(--canvas); }
button, input, select, textarea { font-family: inherit; }
button { transition: background-color .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease, transform .16s ease; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(17, 123, 117, .2); outline-offset: 2px; }
[hidden] { display: none !important; }

.page-shell { width: min(100%, 1480px); min-height: 100vh; margin: 0 auto; padding: 34px; }
.page-shell:has(.app-shell:not([hidden])) { width: 100%; max-width: none; min-height: 100vh; margin: 0; padding: 0; display: block; }
.page-shell:has(.app-shell:not([hidden])) .brand-panel { display: none; }
.app-shell { min-height: 100vh; display: grid !important; grid-template-columns: 256px minmax(0, 1fr); gap: 0; overflow: visible; background: var(--surface-subtle); border: 0; border-radius: 0; box-shadow: none; }
.app-shell[hidden], .login-card[hidden] { display: none !important; }
.sidebar { position: sticky; top: 0; z-index: 5; display: flex; height: 100vh; flex-direction: column; min-height: 100vh; padding: 28px 16px 20px; color: #e7f3f2; background: linear-gradient(180deg, var(--navy) 0%, var(--navy-deep) 100%); }
.sidebar-brand { display: flex; align-items: center; gap: 12px; padding: 0 12px 34px; }
.sidebar-brand strong { color: #fff; font-size: .98rem; letter-spacing: -.01em; }
.sidebar-brand small { margin-top: 4px; color: #a5bdc1; font-size: .68rem; letter-spacing: .01em; }
.brand-mark { width: 38px; height: 38px; color: var(--navy); background: #c3eee6; border-radius: 10px; box-shadow: 0 7px 16px rgba(0,0,0,.14); }
.nav-list { display: grid; gap: 3px; overflow-y: auto; scrollbar-width: thin; }
.nav-item { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 0 13px; color: #a9c1c5; background: transparent; border: 1px solid transparent; border-radius: 9px; font-size: .82rem; font-weight: 700; letter-spacing: .005em; }
.nav-item span { display: grid; place-items: center; width: 20px; color: #83a7aa; font-size: 1rem; }
.nav-item:hover { color: #fff; background: rgba(255,255,255,.06); }
.nav-item.is-active { color: #fff; background: rgba(195,238,230,.12); border-color: rgba(195,238,230,.12); box-shadow: inset 3px 0 0 #c3eee6; }
.nav-item.is-active span { color: #c3eee6; }
.sidebar-footer { margin-top: auto; padding: 18px 13px 0; border-top: 1px solid rgba(201,231,229,.12); color: #a9c1c5; font-size: .7rem; }
.status-dot { background: #71dba3; }
.workspace { min-width: 0; min-height: 100vh; padding: 0 44px 54px; background: var(--canvas); }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 118px; margin: 0 -44px 28px; padding: 27px 44px 24px; background: rgba(255,255,255,.92); border-bottom: 1px solid var(--line); }
.topbar-title { min-width: 0; }
.topbar-heading-row { display: flex; align-items: center; gap: 10px; }
.sidebar-toggle { display: none; width: 36px; height: 36px; padding: 0; color: var(--teal-dark); background: var(--surface-tint); border: 1px solid #c5dbd9; border-radius: 9px; font-size: 1.05rem; cursor: pointer; }
.topbar h2 { margin: 7px 0 0; color: var(--ink); font-size: 1.55rem; font-weight: 750; letter-spacing: -.035em; }
.breadcrumbs { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; color: var(--muted); font-size: .72rem; font-weight: 650; }
.breadcrumb-separator { color: #b4c2c6; }
.breadcrumbs span:last-child { color: var(--teal-dark); }
.topbar .eyebrow { color: var(--muted); font-size: .64rem; letter-spacing: .12em; }
.topbar-actions { gap: 16px; }
.command-button { display: inline-flex; align-items: center; gap: 9px; min-height: 36px; padding: 0 11px; color: var(--muted); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 8px; font-size: .73rem; font-weight: 700; cursor: pointer; }
.command-button:hover { color: var(--teal-dark); border-color: #9fc8c4; background: var(--surface-tint); }
.command-button kbd { padding: 3px 5px; color: var(--teal-dark); background: var(--surface-tint); border: 1px solid #d5ebe7; border-radius: 5px; font-size: .62rem; font-weight: 800; }
.user-pill { padding: 8px 12px; color: var(--ink-soft); background: var(--surface-tint); border: 1px solid #d5ebe7; font-size: .72rem; }
.topbar-actions .button-quiet { width: auto; min-height: 36px; padding: 0 12px; color: var(--teal-dark); background: transparent; border: 1px solid var(--line-strong); border-radius: 8px; font-size: .76rem; }
.topbar-actions .button-quiet:hover { background: var(--surface-tint); border-color: #b5d9d5; }
.view-refresh-status { color: var(--muted); font-size: .68rem; white-space: nowrap; }
.sidebar-close { display: none; }
body.menu-is-open { overflow: hidden; }
.login-recovery-link { display: block; width: 100%; margin-top: 14px; text-align: center; }
.password-reset-card { align-self: center; }
.password-reset-card .button-quiet { display: block; width: 100%; margin-top: 10px; }
.password-reset-card .form-help { margin-top: 7px; }
.setup-panel { min-width: 0; }
.setup-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.setup-heading h3 { margin: 4px 0 0; }
.setup-heading > strong { color: var(--teal-dark); font-size: 1.35rem; }
.setup-progress { height: 8px; margin: 15px 0 8px; overflow: hidden; background: #e4eeee; border-radius: 999px; }
.setup-progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), #55b8a8); border-radius: inherit; transition: width .25s ease; }
.setup-list { display: grid; gap: 8px; margin-top: 14px; }
.setup-item { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 8px; padding: 9px 0; border-top: 1px solid var(--line); }
.setup-item strong, .setup-item small { display: block; }
.setup-item strong { color: var(--ink-soft); font-size: .76rem; }
.setup-item small { margin-top: 3px; color: var(--muted); font-size: .67rem; }
.setup-item.is-done strong { color: var(--teal-dark); }
.setup-check { display: grid; width: 21px; height: 21px; place-items: center; color: var(--muted); background: var(--surface-subtle); border: 1px solid var(--line-strong); border-radius: 50%; font-size: .72rem; font-weight: 800; }
.setup-item.is-done .setup-check { color: #fff; background: var(--teal); border-color: var(--teal); }
.view { animation: view-in .2s ease-out; }
.section-heading { align-items: center; margin-bottom: 20px; }
.section-heading h3 { margin: 0 0 5px; color: var(--ink); font-size: 1.12rem; font-weight: 750; letter-spacing: -.025em; }
.section-heading p { color: var(--muted); font-size: .78rem; }
.button { min-height: 40px; border-radius: 8px; font-size: .77rem; font-weight: 750; }
.button-primary { color: #fff; background: var(--teal); box-shadow: 0 5px 12px rgba(17,123,117,.18); }
.button-primary:hover { background: var(--teal-dark); box-shadow: 0 7px 16px rgba(17,123,117,.24); transform: translateY(-1px); }
.button-outline { color: var(--teal-dark); background: var(--surface); border: 1px solid #c5dbd9; box-shadow: none; }
.button-outline:hover { background: var(--surface-tint); border-color: #9fc8c4; }
.button-quiet { color: var(--teal-dark); }
.app-alert { max-width: 900px; margin: 0 0 20px; box-shadow: var(--shadow-sm); }
.overview-grid { gap: 14px; margin-bottom: 18px; }
.overview-card { position: relative; min-height: 132px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.overview-card::after { position: absolute; top: 17px; right: 18px; width: 7px; height: 7px; background: #b7ded9; border-radius: 50%; content: ""; }
.overview-card .metric-label { font-size: .66rem; letter-spacing: .1em; }
.overview-card .metric-number { margin-top: 17px; font-size: 1.95rem; font-weight: 760; }
.overview-card .metric-note { margin-top: 7px; font-size: .72rem; }
.operation-status-list { display: grid; gap: 9px; margin-bottom: 15px; }
.operation-status-list div { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 10px; background: var(--surface-subtle); border: 1px solid var(--line); border-radius: 8px; color: var(--muted); font-size: .72rem; }
.operation-status-list strong { color: var(--teal-dark); font-size: .86rem; }
.operation-status-list strong.is-danger { color: var(--danger); }
.operations-health { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 20px; padding: 18px 20px; background: linear-gradient(120deg, #eefaf7, #fff); border: 1px solid #c9e6df; border-radius: 15px; }
.operations-health strong, .operations-health small { display: block; }
.operations-health strong { margin-top: 6px; color: var(--teal-dark); font-size: 1.05rem; }
.operations-health small { margin-top: 4px; color: var(--muted); font-size: .72rem; }
.health-checks { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.health-check { display: inline-flex; align-items: center; gap: 6px; padding: 6px 9px; color: var(--muted); background: #fff; border: 1px solid var(--line); border-radius: 999px; font-size: .68rem; font-weight: 700; text-transform: capitalize; }
.health-check i { width: 7px; height: 7px; background: #c6d1d4; border-radius: 50%; }
.health-check.is-ok { color: #176f54; border-color: #c8ead9; }
.health-check.is-ok i { background: #43aa75; }
.health-check.is-error { color: var(--danger); border-color: #f1caca; }
.health-check.is-error i { background: var(--danger); }
.operations-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(280px, .75fr); gap: 18px; margin-bottom: 18px; }
.operations-summary { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.operations-failures { overflow: hidden; padding: 0; }
.operations-failures .section-heading { padding: 21px 21px 0; }
.text-danger { color: var(--danger) !important; }
.overview-columns { gap: 18px; }
.panel { padding: 22px; border: 1px solid var(--line); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.panel h3 { color: var(--ink); font-weight: 750; }
.activity-item { padding: 14px 0; }
.activity-item strong { color: var(--ink-soft); font-size: .78rem; }
.activity-item small { font-size: .7rem; }
.link-button { color: var(--teal); font-size: .72rem; }
.link-button:hover { color: var(--teal-dark); text-decoration: underline; }
.toolbar { gap: 8px; padding: 12px; background: var(--surface-subtle); border: 1px solid var(--line); border-radius: var(--radius-md); }
.toolbar input, .toolbar select { min-height: 38px; padding: 9px 11px; border-color: var(--line-strong); border-radius: 8px; font-size: .76rem; }
.filter-presets { display: flex; flex: 1 1 100%; flex-wrap: wrap; gap: 6px; order: -1; }
.filter-presets .button { min-height: 32px; padding-inline: 10px; font-size: .7rem; }
.button-ghost { color: var(--teal-dark); background: var(--surface-tint); border: 1px solid #d2e8e4; box-shadow: none; }
.button-ghost:hover { background: #e4f4f0; border-color: #9fc8c4; }
.report-actions .button-ghost { min-height: 36px; }
.data-panel { border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.table-sort-button { display: inline-flex; align-items: center; gap: 7px; width: 100%; padding: 0; color: inherit; background: transparent; border: 0; font: inherit; font-weight: inherit; text-align: left; cursor: pointer; }
.table-sort-button:hover { color: var(--teal-dark); }
.table-sort-icon { color: var(--teal); font-size: .78rem; opacity: .75; }
table { min-width: 720px; }
th, td { padding: 15px 18px; border-bottom-color: #edf2f3; }
th { color: #83939a; background: #fbfcfc; font-size: .64rem; letter-spacing: .1em; }
td strong { color: var(--ink-soft); font-size: .78rem; }
td small { font-size: .69rem; }
tbody tr { transition: background-color .14s ease; }
tbody tr:hover { background: #fbfdfd; }
.badge { padding: 5px 8px; border: 1px solid #e2eaec; font-size: .65rem; letter-spacing: .02em; }
.badge-success { border-color: #c8ead9; }
.badge-warning { border-color: #f0dfad; }
.badge-danger { border-color: #f0c9cc; }
.pagination { min-height: 50px; padding: 12px 17px; }
.pagination button { min-height: 30px; border-radius: 7px; }
.course-card, .profile-card { border-color: var(--line); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.course-card:hover, .profile-card:hover { border-color: #c5deda; box-shadow: var(--shadow-md); }
.course-card h3, .profile-card h3 { font-weight: 750; }
.course-card p { font-size: .75rem; }
.settings-grid { gap: 18px; }
.settings-grid .panel, .templates-panel { box-shadow: var(--shadow-sm); }
.settings-grid input, .settings-grid select, .settings-grid textarea, .modal input, .modal select, .modal textarea { min-height: 40px; border-color: var(--line-strong); border-radius: 8px; font-size: .78rem; }
.settings-grid textarea, .modal textarea { min-height: auto; }
label { color: var(--ink-soft); font-size: .75rem; }
input, select, textarea { color: var(--ink); background: var(--surface); border-color: var(--line-strong); border-radius: 8px; }
.form-grid > *, .settings-grid > *, .modal form > * { min-width: 0; }
.modal textarea, .settings-grid textarea, .legal-editor textarea { width: 100%; max-width: 100%; resize: vertical; }
.modal-backdrop { background: rgba(13, 29, 38, .56); backdrop-filter: blur(4px); }
.modal { border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: 0 24px 80px rgba(10, 31, 40, .22); }
.modal-heading { margin-bottom: 24px; }
.modal-heading h2 { color: var(--ink); font-size: 1.3rem; }
.icon-button:hover { color: var(--ink); background: #e7f1f0; }
.profile-count { border: 1px solid #c7e5e0; }
.empty-state, .loading-state { padding: 44px 18px; font-size: .78rem; }

.course-details { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 14px; }
.version-row, .module-row, .item-row { display: grid; gap: 10px; align-items: center; padding: 13px 0; border-bottom: 1px solid var(--line); }
.version-row { grid-template-columns: minmax(0, 1fr) auto; }
.module-row { grid-template-columns: minmax(0, 1fr) auto; margin-left: 12px; }
.item-row { grid-template-columns: minmax(0, 1fr) auto auto; margin-left: 20px; padding: 10px 0; }
.version-row:last-child, .module-row:last-child, .item-row:last-child { border-bottom: 0; }
.version-row strong, .module-row strong, .item-row strong { color: var(--ink-soft); font-size: .76rem; }
.version-row small, .module-row small, .item-row small { display: block; margin-top: 4px; color: var(--muted); font-size: .68rem; }
.version-details { grid-column: 1 / -1; margin-top: 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface-subtle); }
.version-readiness { grid-column: 1 / -1; margin-top: 4px; padding: 13px 14px; background: #fbfdfd; border: 1px solid var(--line); border-radius: 10px; }
.readiness-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--ink-soft); font-size: .75rem; }
.readiness-counters { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 7px; margin-top: 11px; }
.readiness-counters span { display: grid; gap: 3px; padding: 8px; color: var(--muted); background: var(--surface-subtle); border-radius: 7px; font-size: .62rem; }
.readiness-counters strong { color: var(--teal-dark); font-size: .82rem; }
.readiness-errors { display: grid; gap: 6px; margin: 11px 0 0; padding: 0; list-style: none; }
.readiness-errors li { display: flex; gap: 8px; padding: 8px; color: #8e4d30; background: #fff7ed; border: 1px solid #f1d6b7; border-radius: 7px; font-size: .68rem; }
.readiness-errors strong { flex: 0 0 auto; color: #9a4a2c; }
.readiness-success { margin: 11px 0 0; color: #176f54; font-size: .7rem; font-weight: 700; }
.module-items { grid-column: 1 / -1; margin-top: 4px; padding: 8px 12px; border-left: 2px solid #c8e7e1; background: var(--surface); border-radius: 0 9px 9px 0; }
.studio-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 4px; color: var(--muted); font-size: .7rem; }
.studio-toolbar strong { color: var(--ink-soft); font-size: .74rem; }
.tenant-card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tenant-learning-card { display: flex; flex-direction: column; gap: 14px; padding: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.tenant-learning-card:hover { border-color: #c5deda; box-shadow: var(--shadow-md); }
.tenant-learning-card h3 { margin: 5px 0 0; font-size: 1rem; }
.tenant-learning-card p { min-height: 38px; margin: 0; color: var(--muted); font-size: .78rem; line-height: 1.55; }
.card-heading, .card-footer, .module-heading, .tenant-item, .ranking-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.card-footer { margin-top: auto; color: var(--muted); font-size: .72rem; }
.progress-track { height: 7px; overflow: hidden; background: #e8f0f0; border-radius: 999px; }
.progress-track span { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), #55b8a4); border-radius: inherit; transition: width .25s ease; }
.tenant-learning-card > small, .tenant-detail-panel small, .ranking-row small { color: var(--muted); font-size: .68rem; }
.tenant-card-list { display: grid; gap: 8px; }
.tenant-course-card { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px; color: inherit; background: #fbfdfd; border: 1px solid var(--line); border-radius: 10px; text-align: left; cursor: pointer; }
.tenant-course-card:hover { border-color: #b9d8d5; background: var(--teal-soft); }
.tenant-course-card strong, .tenant-course-card small { display: block; }
.tenant-course-card strong { font-size: .8rem; }
.tenant-course-card small { margin-top: 4px; color: var(--muted); font-size: .68rem; }
.tenant-course-card .progress-track { width: 120px; }
.tenant-detail-panel { margin-top: 20px; }
.course-progress-summary { max-width: 420px; margin: -3px 0 20px; }
.tenant-modules { display: grid; gap: 12px; }
.tenant-module { padding: 16px; background: var(--surface-subtle); border: 1px solid var(--line); border-radius: 12px; }
.module-heading { margin-bottom: 11px; }
.module-heading strong, .module-heading small { display: block; }
.module-heading strong { color: var(--ink-soft); font-size: .84rem; }
.module-heading small { margin-top: 4px; font-size: .7rem; }
.tenant-item-list { display: grid; gap: 7px; }
.tenant-item { align-items: flex-start; padding: 12px; background: #fff; border: 1px solid #e7eef0; border-radius: 9px; }
.tenant-item.is-complete { border-color: #c8ead9; background: #fbfffd; }
.tenant-item > div:first-child { min-width: 0; }
.tenant-item strong, .tenant-item small { display: block; }
.tenant-item strong { margin-top: 3px; color: var(--ink-soft); font-size: .78rem; }
.tenant-item small { margin-top: 4px; color: var(--muted); font-size: .68rem; }
.tenant-item-side { display: grid; justify-items: end; gap: 7px; }
.item-type { color: var(--teal); font-size: .61rem; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; }
.tenant-rich-text { margin-top: 12px; color: var(--ink-soft); font-size: .76rem; line-height: 1.65; }
.tenant-rich-text p { margin: 0 0 8px; }
.tenant-rich-text p:last-child { margin-bottom: 0; }
.path-course-list { display: grid; margin-top: 16px; }
.path-course-list .progress-track { width: 120px; margin-bottom: 3px; }
.ranking-list { display: grid; }
.ranking-row { padding: 12px 0; border-bottom: 1px solid #edf2f3; }
.ranking-row:last-child { border-bottom: 0; }
.ranking-position { display: grid; place-items: center; width: 28px; height: 28px; color: var(--teal-dark); background: var(--teal-soft); border-radius: 9px; font-size: .76rem; font-weight: 900; }
.ranking-row > div { flex: 1; }
.ranking-row strong { display: block; font-size: .78rem; }
.ranking-points { color: var(--teal-dark); font-size: .76rem; font-weight: 900; }
.tenant-assessment-panel { margin-top: 18px; border-color: #cfe3e0; }
.assessment-question-list { display: grid; gap: 14px; }
.assessment-question { min-width: 0; margin: 0; padding: 17px; border: 1px solid var(--line); border-radius: 11px; }
.assessment-question legend { width: 100%; padding: 0; color: var(--ink-soft); font-size: .82rem; font-weight: 800; line-height: 1.5; }
.assessment-question legend > span { display: inline-grid; place-items: center; width: 24px; height: 24px; margin-right: 7px; color: var(--teal-dark); background: var(--teal-soft); border-radius: 7px; font-size: .7rem; }
.assessment-question legend small { color: var(--muted); font-size: .68rem; font-weight: 600; }
.assessment-options { display: grid; gap: 8px; margin-top: 14px; }
.assessment-option { display: flex; align-items: flex-start; gap: 9px; margin: 0; padding: 11px 12px; color: var(--ink-soft); background: #fbfdfd; border: 1px solid #e7eef0; border-radius: 8px; font-size: .76rem; font-weight: 600; cursor: pointer; }
.assessment-option:hover { border-color: #b9d8d5; background: var(--teal-soft); }
.assessment-option input { width: auto; margin-top: 2px; }
.answer-status { display: block; margin-top: 10px; color: var(--muted); font-size: .65rem; }
.answer-status.is-saved { color: #176f54; }
.answer-status.is-error { color: var(--danger); }
.assessment-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; padding-top: 15px; border-top: 1px solid var(--line); }
.assessment-footer .button { width: auto; margin-top: 0; }
.assessment-result { margin-top: 14px; }
.assessment-result-card { display: flex; align-items: center; gap: 12px; padding: 13px; border-radius: 9px; font-size: .78rem; }
.assessment-result-card strong { font-weight: 900; }
.assessment-result-card span { font-weight: 800; }
.assessment-result-card small { margin-left: auto; color: var(--muted); }
.assessment-result-card.is-passed { color: #176f54; background: #e2f6ed; }
.assessment-result-card.is-failed { color: #9e3d43; background: #ffe7e7; }
.assessment-result-card.is-passed strong, .assessment-result-card.is-failed strong { color: inherit; }
.video-frame { margin: 0 0 18px; overflow: hidden; background: #112b31; border-radius: 14px; box-shadow: var(--shadow-md); }
.video-frame-heading { display: flex; align-items: center; justify-content: space-between; padding: 11px 14px; color: #eaf8f5; font-size: .76rem; }
.video-frame-heading .link-button { color: #b7eee2; }
.video-frame iframe { display: block; width: 100%; min-height: 360px; border: 0; }
.assignment-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(260px, .75fr); gap: 18px; align-items: start; }
.assignment-form, .assignment-summary { min-height: 100%; }
.assignment-form .button { width: auto; margin-top: 6px; }
.assignment-feedback { min-height: 20px; margin-top: 14px; color: var(--teal-dark); font-size: .72rem; font-weight: 700; }
.assignment-summary { background: linear-gradient(145deg, #f7fcfb, #fff); }
.assignment-summary h3 { margin: 8px 0 18px; font-size: 1rem; }
.assignment-summary p { margin-top: 20px; color: var(--muted); font-size: .74rem; line-height: 1.55; }
.assignment-history { margin-top: 18px; }
.assignment-history .section-heading { margin-bottom: 8px; }
.assignment-counts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.assignment-counts div { padding: 13px; background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.assignment-counts strong, .assignment-counts span { display: block; }
.assignment-counts strong { color: var(--teal-dark); font-size: 1.35rem; }
.assignment-counts span { margin-top: 4px; color: var(--muted); font-size: .66rem; }
.report-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 16px; }
.report-actions .button { width: auto; margin-top: 0; }
.success-box { display: grid; gap: 7px; padding: 18px; color: #176f54; background: #e2f6ed; border: 1px solid #c8ead9; border-radius: 11px; font-size: .78rem; }
.success-box a { color: #0e6650; font-weight: 800; }
.success-box small { color: #4b7d6c; font-size: .68rem; }
.group-stat-row { display: flex; gap: 8px; color: var(--muted); font-size: .68rem; }
.group-stat-row span { padding: 5px 8px; background: var(--surface-tint); border-radius: 7px; }
.group-detail { margin-top: 15px; padding-top: 15px; border-top: 1px solid var(--line); }
.group-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.group-detail-grid section { min-width: 0; }
.group-detail-grid h4 { margin: 0 0 4px; color: var(--ink-soft); font-size: .8rem; }
.group-detail-grid .section-heading { align-items: flex-start; margin-bottom: 8px; }
.group-detail-grid .section-heading p { font-size: .68rem; }
.group-people { display: grid; gap: 6px; }
.group-person { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 10px; background: #fbfdfd; border: 1px solid #e7eef0; border-radius: 8px; }
.group-person strong, .group-person small { display: block; }
.group-person strong { color: var(--ink-soft); font-size: .72rem; }
.group-person small { margin-top: 3px; color: var(--muted); font-size: .64rem; }
.group-inline-form { display: flex; gap: 7px; margin-top: 9px; }
.group-inline-form select { min-width: 0; flex: 1; min-height: 34px; font-size: .7rem; }
.group-inline-form .button { flex: 0 0 auto; min-height: 34px; }
.legal-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 18px; }
.legal-links button { padding: 0; color: var(--muted); background: transparent; border: 0; font-size: .67rem; cursor: pointer; }
.legal-links button:hover, .legal-links button:focus-visible { color: var(--teal-dark); text-decoration: underline; }
.legal-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.legal-card { display: grid; gap: 8px; min-height: 150px; color: var(--ink); text-align: left; cursor: pointer; transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease; }
.legal-card:hover, .legal-card:focus-visible { border-color: #9ccbc4; box-shadow: var(--shadow-md); transform: translateY(-2px); }
.legal-card strong { color: var(--teal-dark); font-size: 1.25rem; }
.legal-card > span:not(.eyebrow):not(.badge) { color: var(--muted); font-size: .7rem; }
.legal-editor textarea { min-height: 280px; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .74rem; line-height: 1.55; }
.legal-editor-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.legal-editor-actions .button { width: auto; margin-top: 0; }
.legal-editor-actions .form-help { margin: 0; }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 16px; }
.modal-actions .button { width: auto; margin-top: 0; }
.modal input[type="file"] { width: 100%; padding: 10px; background: var(--surface-subtle); border: 1px dashed #a9cbc6; border-radius: 8px; font-size: .74rem; cursor: pointer; }
.modal input[type="file"]::file-selector-button { margin-right: 10px; padding: 7px 10px; color: var(--teal-dark); background: var(--surface-tint); border: 1px solid #c5dbd9; border-radius: 6px; font: inherit; font-size: .7rem; font-weight: 750; cursor: pointer; }
.upload-feedback { min-height: 18px; margin-top: 9px; color: var(--teal-dark); font-size: .7rem; line-height: 1.4; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.sidebar-scrim { position: fixed; z-index: 18; inset: 0; background: rgba(13, 29, 38, .42); backdrop-filter: blur(2px); }
.command-palette-backdrop { position: fixed; z-index: 30; inset: 0; display: grid; place-items: start center; padding: 12vh 20px 20px; background: rgba(13, 29, 38, .5); backdrop-filter: blur(5px); }
.command-palette { width: min(100%, 620px); max-height: min(70vh, 620px); overflow: hidden; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: 0 28px 90px rgba(10, 31, 40, .28); }
.command-palette-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.command-palette-heading h2 { margin: 6px 0 0; font-size: 1.25rem; }
.command-palette > input { min-height: 46px; padding: 0 14px; font-size: .86rem; }
.command-palette-hint { margin: 9px 2px 12px; color: var(--muted); font-size: .68rem; }
.command-results { display: grid; gap: 4px; max-height: 410px; overflow-y: auto; }
.command-result { display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; padding: 12px 13px; color: var(--ink-soft); background: transparent; border: 1px solid transparent; border-radius: 9px; text-align: left; cursor: pointer; }
.command-result:hover, .command-result.is-selected { color: var(--teal-dark); background: var(--surface-tint); border-color: #c5e1dd; }
.command-result strong, .command-result small { display: block; }
.command-result strong { font-size: .78rem; }
.command-result small { margin-top: 3px; color: var(--muted); font-size: .68rem; }
.command-result kbd { color: var(--muted); font-size: .65rem; }
.command-empty { padding: 25px 12px; color: var(--muted); text-align: center; font-size: .78rem; }
.legal-public-content { max-height: min(62vh, 620px); overflow: auto; color: var(--ink-soft); font-size: .78rem; line-height: 1.7; }
.legal-public-content h1, .legal-public-content h2, .legal-public-content h3 { margin: 0 0 12px; color: var(--ink); }
.legal-public-content p { margin: 0 0 12px; }
.legal-public-content a { color: var(--teal-dark); }
.brand-logo { display: block; width: 38px; height: 38px; flex: 0 0 38px; object-fit: contain; background: var(--brand-accent); border-radius: 10px; box-shadow: 0 7px 16px rgba(0,0,0,.14); }
.brand-mark { color: var(--navy); background: var(--brand-accent); }
.button-primary { background: var(--brand-primary); }
.button-primary:hover { background: color-mix(in srgb, var(--brand-primary) 78%, #0b3035); }
.branding-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); gap: 18px; align-items: stretch; }
.branding-layout .button-primary { width: auto; margin-top: 18px; }
.branding-logo-panel { display: flex; flex-direction: column; }
.branding-logo-panel .button-outline { width: auto; margin-top: 8px; align-self: flex-start; }
.branding-preview { display: grid; place-items: center; width: 104px; height: 104px; margin: 6px 0 10px; color: var(--navy); background: var(--brand-accent); border: 1px solid var(--line); border-radius: 18px; font-size: 1.5rem; font-weight: 900; }
.branding-preview img { width: 80px; height: 80px; object-fit: contain; }
.branding-color-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.color-input { display: flex; align-items: center; gap: 9px; }
.color-input input[type="color"] { width: 48px; height: 40px; padding: 4px; cursor: pointer; }
.color-input code { color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .04em; }
.learning-analytics { margin-top: 20px; }
.analytics-toolbar { display: grid; grid-template-columns: repeat(2, minmax(140px, 1fr)) auto; align-items: end; gap: 12px; margin-bottom: 16px; padding: 14px; background: var(--surface-subtle); border: 1px solid var(--line); border-radius: var(--radius-md); }
.analytics-toolbar label { display: block; margin-bottom: 6px; }
.analytics-toolbar-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.analytics-toolbar-actions .button { width: auto; margin-top: 0; }
.analytics-summary { margin-bottom: 16px; }
.analytics-course-panel { margin-top: 16px; }
.assessment-editor { display: grid; gap: 16px; }
.assessment-editor-summary, .assessment-editor-toolbar, .assessment-editor-question-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.assessment-editor-summary { padding: 14px; background: var(--surface-subtle); border: 1px solid var(--line); border-radius: var(--radius-md); }
.assessment-editor-summary h3, .assessment-editor-question h4 { margin: 4px 0 0; }
.assessment-editor-toolbar { align-items: center; padding-bottom: 2px; }
.assessment-editor-list { display: grid; gap: 12px; max-height: 52vh; overflow-y: auto; }
.assessment-editor-question { padding: 15px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); }
.assessment-editor-actions { justify-content: flex-end; margin-top: 10px; }
.assessment-editor-options { display: grid; gap: 7px; margin-top: 13px; }
.assessment-editor-option { display: flex; align-items: center; gap: 8px; padding: 8px 10px; color: var(--ink-soft); background: var(--surface-subtle); border-radius: 8px; font-size: .76rem; }
.assessment-editor-option > span:first-child { color: var(--teal-dark); font-weight: 900; }
.assessment-editor-option small { margin-left: auto; color: var(--teal-dark); font-size: .64rem; font-weight: 800; }
.assessment-editor-option .link-button { margin-left: auto; }
@media (max-width: 780px) { .branding-layout { grid-template-columns: 1fr; } .branding-color-grid { grid-template-columns: 1fr; } }
@media (max-width: 780px) { .analytics-toolbar { grid-template-columns: 1fr; } .analytics-toolbar-actions { justify-content: flex-start; } }
@media (max-width: 620px) { .assessment-editor-summary, .assessment-editor-toolbar, .assessment-editor-question-heading { align-items: flex-start; flex-direction: column; } }
@media (max-width: 780px) { .tenant-card-grid { grid-template-columns: 1fr; } .tenant-item, .card-heading, .card-footer, .module-heading { align-items: flex-start; flex-direction: column; } .tenant-item-side { width: 100%; justify-items: start; } .tenant-course-card .progress-track, .path-course-list .progress-track { width: 100px; } .video-frame iframe { min-height: 230px; } .list-toolbar { grid-template-columns: 1fr; align-items: stretch; } .list-toolbar-actions { justify-content: flex-start; } }
@media (max-width: 780px) { .readiness-counters { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .version-row, .module-row, .item-row { grid-template-columns: 1fr; } .version-row .row-actions, .module-row > .link-button, .item-row .row-actions { justify-self: start; } }

@media (max-width: 900px) { .assignment-layout { grid-template-columns: 1fr; } }
@media (max-width: 900px) { .operations-layout { grid-template-columns: 1fr; } .operations-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); } .operations-health { align-items: flex-start; flex-direction: column; } .health-checks { justify-content: flex-start; } }
@media (max-width: 900px) { .legal-grid { grid-template-columns: 1fr; } }
@media (max-width: 780px) { .group-detail-grid { grid-template-columns: 1fr; } .group-inline-form { align-items: stretch; flex-direction: column; } }

@media (max-width: 960px) {
    .workspace { padding-right: 28px; padding-left: 28px; }
    .topbar { margin-right: -28px; margin-left: -28px; padding-right: 28px; padding-left: 28px; }
}
@media (max-width: 780px) {
    .page-shell { padding: 0; }
    .app-shell { grid-template-columns: 1fr; }
    .sidebar-toggle { display: inline-grid; place-items: center; }
    .sidebar { position: fixed; z-index: 20; inset: 0 auto 0 0; width: min(82vw, 288px); height: 100vh; min-height: 100vh; padding: 22px 16px 20px; transform: translateX(-105%); transition: transform .2s ease; box-shadow: 16px 0 40px rgba(10, 31, 40, .18); }
    .app-shell.is-menu-open .sidebar { transform: translateX(0); }
    .sidebar-brand { position: relative; padding-right: 42px; }
    .sidebar-close { position: absolute; top: -2px; right: 0; display: inline-grid; width: 32px; height: 32px; place-items: center; padding: 0; color: #d4eeeb; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.18); border-radius: 8px; font-size: 1.25rem; line-height: 1; cursor: pointer; }
    .sidebar-brand { padding-bottom: 28px; }
    .nav-list { display: grid; overflow-y: auto; padding-bottom: 2px; }
    .nav-item { min-width: 0; min-height: 44px; }
    .toolbar input, .toolbar select, .toolbar input[type="date"] { flex: 1 1 100%; max-width: none; }
    .nav-item.is-active { box-shadow: inset 3px 0 0 #c3eee6; }
    .workspace { min-height: auto; padding: 0 16px 34px; }
    .topbar { align-items: flex-start; min-height: 140px; margin: 0 -16px 22px; padding: 22px 16px; }
    .topbar-actions { width: 100%; justify-content: flex-end; gap: 8px; }
    .command-button { padding: 0 9px; }
    .command-button kbd { display: none; }
    .user-pill { max-width: 150px; }
}
