.application-shell { margin: 0; min-height: 100dvh; display: flex; flex-direction: column; background: linear-gradient(180deg, rgb(240 237 229 / 70%) 0%, rgb(240 237 229 / 76%) 45%, var(--bg) 92%) top center / 100% calc(max(40vw, 440px) + 2px) no-repeat, url('/static/orbital-fleet-shell.webp') top center / max(100%, 1100px) auto no-repeat, var(--bg); color: var(--text); }
.application-shell { background-blend-mode: normal, luminosity, normal; }
.application-shell * { box-sizing: border-box; }
.application-shell a, .application-shell button, .application-shell summary { min-height: 44px; }
.application-shell a { color: #282f3f; text-decoration: none; }
.application-shell a:hover { color: #171b24; text-decoration: underline; }
.application-shell :focus-visible { outline: 3px solid #785a34; outline-offset: 3px; }
.application-shell [hidden] { display: none !important; }
.shell-header { font-size: 1.15rem; display: grid; grid-template-columns: auto minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, auto); align-items: center; gap: 24px; padding: 12px 24px; border-bottom: 1px solid #c4beac; position: relative; z-index: 60; }
.shell-brand { display: flex; align-items: center; gap: 12px; max-width: 270px; font-weight: 700; }
.shell-brand img { width: 36px; height: 36px; object-fit: contain; }
.shell-brand span { overflow-wrap: anywhere; }
.shell-brand-full { white-space: nowrap; line-height: 1.25; }
.shell-menu, .shell-menu-content { display: contents; }
.shell-account-indicator { display: none; }
@media (min-width: 64rem) {
  .shell-account-indicator { display: block; position: absolute; top: 0; left: 12px; width: 8px; height: 10px; background: var(--gold); clip-path: polygon(0 0, 100% 50%, 0 100%); pointer-events: none; opacity: 0; transition: transform 180ms ease, opacity 160ms ease; }
  .application-shell .shell-account a:not(.shell-sign-in) { min-height: 36px; padding: 5px 8px 5px 20px; border-bottom-color: transparent; transition: color 180ms ease; }
  .shell-account a[data-account-highlighted] { color: var(--gold); text-shadow: 0 0 14px rgb(180 138 66 / 35%); }
  .shell-menu::details-content { content-visibility: visible; display: contents; }
  .shell-menu > summary { display: flex; align-items: center; gap: 8px; list-style: none; }
  .shell-menu > summary::-webkit-details-marker { display: none; }
  .shell-menu > summary::before { content: ''; flex: 0 0 7px; width: 7px; height: 9px; background: currentColor; clip-path: polygon(0 0, 100% 50%, 0 100%); }
  .shell-menu[open] > summary::before { transform: rotate(90deg); }
  .shell-menu > summary .shell-desktop-label { display: block; min-width: 0; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
}
.shell-menu > summary { grid-column: 6; grid-row: 1; justify-self: end; padding: 10px; cursor: pointer; max-width: 210px; overflow-wrap: anywhere; }
.shell-global { grid-column: 3; grid-row: 1; display: flex; gap: 16px; align-items: center; }
.shell-global > a { display: flex; align-items: center; white-space: nowrap; }
.application-shell [aria-current="page"] { color: #785a34; border-bottom: 2px solid var(--gold); }
.shell-account { position: absolute; right: 24px; top: 100%; background: #dfdacb; border: 1px solid #b1ac9b; padding: 12px; width: min(240px, calc(100vw - 32px)); max-height: calc(100dvh - 100px); overflow: auto; }
.shell-menu:not([open]) .shell-account { display: none; }
.shell-account nav { display: flex; flex-direction: column; }
.shell-account a { display: flex; align-items: center; padding: 8px; overflow-wrap: anywhere; }
.shell-account button { cursor: pointer; }
.application-shell .shell-sign-in { justify-content: center; align-items: center; padding: 6px 10px; min-height: 36px; border: 1px solid var(--gold); border-radius: 8px; background: var(--gold); color: #1e232f; font-weight: 400; text-decoration: none; box-shadow: 0 0 18px rgb(180 138 66 / 16%); }
.application-shell .shell-sign-in:hover { background: #e5c783; border-color: var(--gold); color: #1e232f; text-decoration: none; }
.shell-privileged, .shell-logout { border-top: 1px solid #b1ac9b; margin-top: 8px; padding-top: 8px; }
.shell-logout button { width: 100%; text-align: left; }
.shell-notice { font-size: .9rem; }
.shell-mobile-label, .shell-mobile-utility { display: none; }
.shell-group-label { display: none; }
.shell-account .shell-group-label { display: block; text-transform: uppercase; font-size: .77625rem; font-weight: 400; color: #3f4a62; margin: 10px 8px 2px; }
.shell-desktop-label { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.shell-menu:has(.shell-sign-in) > summary { display: none; }
.shell-menu:has(.shell-sign-in) .shell-account { display: block; position: static; grid-column: 6; grid-row: 1; justify-self: end; width: auto; border: 0; padding: 0; background: none; }
.shell-main { width: min(100%, 1440px); margin: 0 auto; padding: 32px; flex: 1; min-width: 0; }
.shell-width-reading { max-width: 850px; }
.shell-context { min-width: 0; }
/* Home's ordered account actions precede the independent participation boxes. */
.home-content { max-width: 896px; margin: 0 auto; padding-bottom: 64px; overflow-wrap: anywhere; }
.home-content h1 { margin: 0 0 28px; }
.home-box { border: 1px solid var(--line-strong); border-radius: 8px; background: rgb(23 27 36 / 90%); padding: clamp(16px, 3vw, 24px); margin-bottom: 20px; }
.home-box h2 { margin: 0 0 12px; font-size: 1.5rem; }
.home-box p { color: #363f54; line-height: 1.65; margin: 12px 0 18px; }
.home-account-actions { border-color: var(--gold); }
.home-account-actions ol { margin: 0; padding-left: 1.7rem; }
.home-account-actions li { padding: 8px 0 0 4px; }
.home-account-actions li + li { border-top: 1px solid var(--line-strong); padding-top: 16px; }
.home-account-actions li::marker { color: var(--gold); font-weight: 600; }
.home-action-link, .home-workspace-links { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.home-content .home-primary, .home-content .home-button { display: inline-flex; align-items: center; min-height: 44px; padding: 10px 16px; border: 1px solid var(--line-strong); border-radius: 6px; background: #243b59; color: #1a1e28; font-weight: 600; line-height: 1.5; }
.home-content .home-primary { background: var(--gold); color: #1e232f; border-color: var(--gold); }
.home-content .home-secondary { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
.home-optional { color: #363f54; font-size: .9rem; }
.home-workspaces h2 { margin: 4px 0 12px; font-size: 1.2rem; }
.home-public-notice { padding: 16px; border: 1px solid var(--line-strong); border-radius: 6px; margin: 16px 0; }
/* Public content keeps the reviewed reading order within the shared shell. */
.public-content { max-width: 1120px; margin-inline: auto; padding-block: 24px 48px; overflow-wrap: anywhere; line-height: 1.65; }
.public-content h1 { margin: 16px 0 20px; max-width: 22ch; font-size: clamp(2rem, 4vw, 3.5rem); line-height: 1.12; letter-spacing: -.025em; }
.public-content h2 { margin: 0 0 16px; font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.25; }
.public-content h3 { margin: 0 0 12px; font-size: 1.25rem; line-height: 1.3; }
.public-content p { max-width: 65ch; margin: 0 0 16px; color: #363f54; }
.public-content .public-eyebrow { color: #785a34; font-size: .8rem; font-weight: 700; letter-spacing: .035em; text-transform: uppercase; }
.public-landing-hero { display: grid; grid-template-columns: minmax(0, 1fr) 280px; align-items: center; gap: clamp(24px, 5vw, 72px); }
.public-hero-logo { display: block; width: 280px; height: auto; max-width: 100%; object-fit: contain; }
.public-section { margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--line); }
.public-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 24px; }
.public-content .public-primary, .public-content .public-secondary, .public-text-link, .public-account-notice a, .public-getting-started p a { display: inline-flex; align-items: center; min-height: 44px; }
.public-content .public-primary { background: var(--gold); border: 1px solid var(--gold); border-radius: 6px; color: #1e232f; padding: 10px 16px; font-weight: 650; line-height: 1.4; text-decoration: none; }
.public-content .public-primary:hover { background: #e5c783; border-color: var(--gold); color: #1e232f; }
.public-content .public-secondary, .public-content .public-text-link, .public-account-notice a, .public-getting-started p a { color: var(--blue); text-decoration: underline; text-underline-offset: .2em; font-weight: 600; }
.public-divisions, .public-resources { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 24px; }
.public-divisions > div, .public-resources > div { min-width: 0; }
.public-resources { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.public-resources > div { display: flex; flex-direction: column; align-items: flex-start; padding: 20px; background: rgb(23 27 36 / 90%); border: 1px solid var(--line); border-radius: 8px; }
.public-resources .public-text-link { margin-top: auto; }
.public-principles { margin: 0; }
.public-principles > div { display: grid; grid-template-columns: 10rem minmax(0, 1fr); gap: 24px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.public-principles dt { font-weight: 650; color: var(--text); }
.public-principles dd { margin: 0; color: #363f54; }
.public-about .public-getting-started { margin-top: 32px; }
.public-policy h1 { max-width: none; }
.public-policy .public-policy-updated { color: #5b6273; font-size: .9rem; }
.public-policy ul { max-width: 65ch; margin: 0 0 16px; padding-left: 1.25rem; color: #363f54; }
.public-policy li { margin-bottom: 8px; }
.public-policy p a, .public-policy li a { color: var(--blue); text-decoration: underline; text-underline-offset: .2em; }
.public-policy section > h3 { margin-top: 24px; }
.public-join-steps { margin: 0 0 16px; padding-left: 1.5rem; display: grid; gap: 8px; max-width: 70ch; }
.public-account-notice { margin: 0 0 32px; background: #e1dccd; border-color: #785a34; }
.public-account-notice p { margin-bottom: 8px; }
.public-recovery { padding-top: 48px; }
.public-browsing { padding-top: 24px; border-top: 1px solid var(--line); }
.public-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.shell-account-unavailable { margin: 0; padding: 8px; color: #363f54; }
@media (width < 48rem) {
  .public-content { padding-top: 8px; }
  .public-landing-hero { display: block; }
  .public-hero-logo { display: none; }
  .public-divisions, .public-resources { grid-template-columns: minmax(0, 1fr); }
  .public-principles > div { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .public-section { margin-top: 28px; padding-top: 24px; }
  .public-recovery { padding-top: 24px; }
}
/* Workspace-only layout; account pages and KB retain their own widths/context. */
.shell-main:has(.workspace-navigation) { display: grid; grid-template-columns: 14rem minmax(0, 1fr); gap: 1.5rem; align-content: start; }
.shell-main:has(.workspace-navigation) .workspace-heading { grid-column: 1 / -1; margin-bottom: 0; }
.workspace-navigation { overflow-wrap: anywhere; }
.workspace-navigation details { background: rgb(23 27 36 / 90%); border: 1px solid var(--line-strong); border-radius: 6px; }
.workspace-navigation nav { display: flex; flex-direction: column; gap: 4px; padding: 6px; }
.workspace-navigation nav a { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; padding: 10px 12px; border-left: 3px solid transparent; border-bottom: 0; line-height: 1.4; }
.workspace-navigation nav a[aria-current] { border-left-color: var(--gold); border-bottom: 0; background: #e0dbcc; color: #785a34; font-weight: 600; }
.workspace-navigation nav small { color: #3f4a62; }
.workspace-navigation summary { padding: 12px; cursor: pointer; border-radius: 6px; }
.workspace-skip { font-size: .9rem; }
.workspace-content { min-width: 0; overflow-wrap: anywhere; }
.workspace-heading { min-width: 0; overflow-wrap: anywhere; margin-bottom: 24px; }
.workspace-heading h1 { margin: 8px 0 16px; font-size: clamp(1.65rem, 3vw, 2.4rem); line-height: 1.3; }
.workspace-heading h1 a { display: inline; }
.workspace-introduction { color: #333c50; margin: 0; line-height: 1.6; }
.workspace-directory { list-style: none; padding: 0; margin: 0; border-top: 1px solid #b1ac9b; }
.workspace-directory li { border-bottom: 1px solid #b1ac9b; }
.workspace-directory a { display: grid; grid-template-columns: minmax(0, 1fr) minmax(9rem, 12rem); align-items: center; gap: 12px 24px; padding: 20px 16px; line-height: 1.5; }
.workspace-directory a:hover { background: #d9d3c3; text-decoration: none; }
.workspace-directory strong { font-size: 1.075rem; }
.workspace-description { display: block; color: #3f4a62; margin-top: 4px; }
.workspace-marker { color: #323b4f; font-size: .9rem; }
.workspace-message { padding: 20px; border: 1px solid #b1ac9b; border-radius: 6px; background: rgb(223 218 203 / 80%); }
.workspace-state { font-weight: 600; color: #785a34; }
.workspace-message a, .workspace-recovery-links a { display: inline-flex; align-items: center; padding: 8px 12px; border: 1px solid #b1ac9b; border-radius: 6px; }
.workspace-recovery-links { display: flex; flex-wrap: wrap; gap: 12px; }
@media (min-width: 64rem) {
  .workspace-navigation summary { display: none; }
  .workspace-navigation details::details-content { content-visibility: visible; }
}
@media (width < 64rem) {
  .shell-main:has(.workspace-navigation) { display: block; }
  .shell-main:has(.workspace-navigation) .workspace-heading { margin-bottom: 24px; }
  .workspace-navigation { margin-bottom: 24px; }
  .workspace-navigation nav { padding-top: 8px; }
}
@media (width < 48rem) {
  .workspace-directory a { grid-template-columns: minmax(0, 1fr); padding: 18px 12px; gap: 8px; }
}
.shell-destination { min-height: 240px; padding: 32px 0; }
.shell-destination h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); overflow-wrap: anywhere; }
.shell-state { color: #785a34; }
.shell-footer { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; border-top: 1px solid #c4beac; min-height: 64px; padding: 8px 32px; }
.shell-footer a { display: flex; align-items: center; }
.shell-footer-short { display: none; align-items: center; min-height: 44px; padding: 0 4px; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
.shell-footer-short abbr { text-decoration: none; }
.shell-footer-short::after { content: ''; margin-left: 8px; border: 5px solid transparent; border-top-color: currentColor; transform: translateY(3px); }
.shell-footer-short[aria-expanded="true"]::after { border-top-color: transparent; border-bottom-color: currentColor; transform: translateY(-2px); }
.shell-footer-links { display: contents; }
.shell-footer-legal { display: flex; gap: 24px; margin-left: auto; }
.shell-footer-discord-label { display: none; }
.application-shell .shell-footer-discord { justify-content: center; min-width: 32px; min-height: 32px; color: #4f5f80; }
.application-shell .shell-footer-discord:hover, .application-shell .shell-footer-discord:focus-visible { color: #5865f2; }
[data-shell-status-text] { white-space: pre-line; line-height: 1.8; }
[id="shell:overlays"] { display: flex; gap: 12px; padding: 0; flex-wrap: wrap; }
.shell-overlay { border: 1px solid #b1ac9b; padding: 0 12px; max-width: 100%; }
.shell-overlay summary { cursor: pointer; padding: 10px 0; }
.shell-overlay > div { max-height: 40dvh; overflow: auto; max-width: 320px; overflow-wrap: anywhere; }
.shell-status-dock { position: fixed; right: max(20px, env(safe-area-inset-right)); bottom: 8px; z-index: 50; width: 48px; padding: 0; background: #dfdacb; border-radius: 6px; }
.shell-status-dock > summary { position: relative; display: block; width: 46px; height: 46px; padding: 0; list-style: none; }
.shell-status-dock > summary::-webkit-details-marker { display: none; }
.shell-status-dock > div { position: absolute; right: 0; bottom: 60px; width: max-content; max-width: calc(100vw - 40px); max-height: min(400px, calc(100dvh - 110px)); padding: 16px; background: #dfdacb; border: 1px solid #b1ac9b; border-radius: 6px; box-shadow: var(--shadow); }
.shell-status-icon { position: absolute; inset: 0; margin: auto; color: var(--green); filter: drop-shadow(0 0 6px rgb(33 131 68 / 45%)); }
.shell-status-dock[open] > summary, .shell-status-dock > summary:hover { background: #cbc5b3; border-radius: 6px; }
/* Keep pointer travel between the trigger and panel inside the disclosure. */
.shell-status-dock[open]::before { content: ''; position: absolute; right: 0; bottom: 46px; width: 100%; height: 16px; }
.shell-voice-dock { position: fixed; left: max(20px, env(safe-area-inset-left)); bottom: max(20px, env(safe-area-inset-bottom)); z-index: 50; width: min(310px, calc(100vw - 104px)); padding: 0; border-radius: 6px; background: linear-gradient(135deg, rgb(228 223 210 / 96%), rgb(236 232 221 / 96%)), var(--surface); box-shadow: 0 14px 36px rgb(0 0 0 / 42%); }
.shell-voice-dock > summary { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 9px 13px; list-style: none; }
.shell-voice-dock > summary::-webkit-details-marker { display: none; }
.shell-voice-dock > summary > span:last-child { min-width: 0; }
.shell-voice-dock > summary strong, .shell-voice-dock > summary small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell-voice-dock > summary strong { color: var(--text); font-size: 14px; }
.shell-voice-dock > summary small { color: var(--muted); font-size: 12px; font-weight: 700; }
.shell-voice-dot { width: 13px; height: 13px; flex: 0 0 13px; border-radius: 50%; background: var(--muted); }
.shell-voice-dock[data-voice-active] { border-color: rgb(163 21 0 / 64%); box-shadow: 0 14px 36px rgb(0 0 0 / 42%), 0 0 22px rgb(163 21 0 / 22%); }
.shell-voice-dock[data-voice-active] .shell-voice-dot { background: #a3000d; box-shadow: 0 0 0 0 rgb(163 0 13 / 68%), 0 0 16px rgb(163 0 13 / 72%); animation: voice-record-pulse 1.25s ease-in-out infinite; }
.shell-voice-dock > div { position: absolute; bottom: calc(100% + 10px); left: 0; width: min(540px, calc(100vw - 40px)); max-width: none; max-height: min(640px, calc(100dvh - 130px)); padding: 18px; border: 1px solid rgb(120 90 52 / 42%); border-radius: var(--radius); background: linear-gradient(150deg, rgb(224 220 205 / 98%), rgb(238 234 224 / 98%)), var(--surface); box-shadow: var(--shadow), 0 0 34px rgb(51 124 120 / 20%); overflow-wrap: normal; }
.shell-voice-dock[hidden] { display: none; }
.shell-voice-dock[open]::before { content: ''; position: absolute; left: 0; bottom: 100%; width: min(540px, calc(100vw - 40px)); height: 12px; }
.shell-voice-header { padding-bottom: 14px; border-bottom: 1px solid rgb(120 90 52 / 18%); }
.shell-voice-header .eyebrow { margin: 0 0 6px; }
.shell-voice-header h2 { max-width: 340px; margin: 0 0 6px; overflow-wrap: anywhere; font-size: 20px; line-height: 1.15; }
.shell-voice-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 14px 0 0; }
.shell-voice-grid div { min-width: 0; padding: 10px; border: 1px solid rgb(120 90 52 / 18%); border-radius: 6px; background: rgb(240 237 229 / 34%); }
.shell-voice-grid dt { color: var(--muted); font-size: 11px; font-weight: 800; text-transform: uppercase; }
.shell-voice-grid dd { min-height: 21px; margin: 4px 0 0; color: var(--text); font-size: 13px; font-weight: 800; overflow-wrap: anywhere; }
.shell-voice-tools { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.application-shell .shell-voice-tools button { min-width: 0; padding-inline: 8px; border-color: rgb(120 90 52 / 28%); color: var(--text); background: rgb(229 225 211 / 82%); cursor: pointer; }
.application-shell .shell-voice-tools button[aria-pressed="true"], .application-shell .shell-voice-tools button:hover:not(:disabled), .application-shell .shell-voice-tools button:focus-visible { border-color: var(--gold); color: #1e232f; background: var(--gold); }
.shell-voice-context { min-height: 146px; margin-top: 14px; padding: 14px; border: 1px solid rgb(120 90 52 / 18%); border-radius: 6px; background: rgb(240 237 229 / 36%); }
.shell-voice-empty { display: grid; min-height: 116px; margin: 0; place-items: center; color: var(--muted); text-align: center; }
.shell-voice-form { display: grid; gap: 12px; margin: 0; }
.shell-voice-form .field { display: grid; gap: 6px; }
.shell-voice-form input, .shell-voice-form textarea { width: 100%; font: inherit; }
.shell-voice-form button { justify-self: start; }
.shell-voice-results { display: grid; gap: 6px; max-height: 220px; overflow: auto; }
.shell-voice-results:empty { display: none; }
.application-shell .shell-voice-results button { display: grid; justify-content: start; justify-items: start; gap: 2px; width: 100%; padding: 8px 10px; border-color: rgb(120 90 52 / 28%); color: var(--text); background: rgb(229 225 211 / 82%); text-align: left; cursor: pointer; }
.application-shell .shell-voice-results button:hover, .application-shell .shell-voice-results button:focus-visible { border-color: var(--gold); }
.application-shell .shell-voice-results button[aria-pressed="true"] { border-color: var(--gold); background: rgb(180 138 66 / 16%); }
.shell-voice-results small { color: var(--muted); font-size: 12px; }
.shell-voice-search-status { margin: 0; color: var(--muted); font-size: 13px; }
.shell-voice-search-status:empty { display: none; }
@keyframes voice-record-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgb(163 0 13 / 68%), 0 0 16px rgb(163 0 13 / 72%); } 50% { box-shadow: 0 0 0 8px rgb(163 0 13 / 0%), 0 0 20px rgb(163 0 13 / 90%); } }
@media (max-width: 47.99rem) { .shell-voice-grid, .shell-voice-tools { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { .shell-voice-dock[data-voice-active] .shell-voice-dot { animation: none; } }
/* Operation shortcuts stack above the pickup dock; its open panel covers them. */
.shell-operation-dock { position: fixed; left: max(20px, env(safe-area-inset-left)); bottom: max(20px, env(safe-area-inset-bottom)); z-index: 49; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; width: min(310px, calc(100vw - 104px)); }
.shell-operation-dock[hidden] { display: none; }
.application-shell .shell-operation-box { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 9px 13px; border: 1px solid rgb(120 90 52 / 64%); border-radius: 6px; color: var(--text); text-decoration: none; background: linear-gradient(135deg, rgb(228 223 210 / 96%), rgb(236 232 221 / 96%)), var(--surface); box-shadow: 0 14px 36px rgb(0 0 0 / 42%), 0 0 22px rgb(51 124 120 / 22%); }
.application-shell .shell-operation-box:hover, .application-shell .shell-operation-box:focus-visible { border-color: rgb(120 90 52 / 92%); background: linear-gradient(135deg, rgb(219 213 197 / 98%), rgb(232 228 216 / 98%)), var(--surface); }
.shell-operation-box > span:last-child { min-width: 0; }
.shell-operation-box strong, .shell-operation-box small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shell-operation-box strong { color: var(--text); font-size: 14px; }
.shell-operation-box small { color: var(--muted); font-size: 12px; font-weight: 700; }
.shell-operation-dot { width: 13px; height: 13px; flex: 0 0 13px; border-radius: 50%; background: #337c78; box-shadow: 0 0 0 0 rgb(51 124 120 / 68%), 0 0 16px rgb(51 124 120 / 72%); animation: operation-live-pulse 1.25s ease-in-out infinite; }
@keyframes operation-live-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgb(51 124 120 / 68%), 0 0 16px rgb(51 124 120 / 72%); } 50% { box-shadow: 0 0 0 8px rgb(51 124 120 / 0%), 0 0 20px rgb(51 124 120 / 90%); } }
@media (prefers-reduced-motion: reduce) { .shell-operation-dot { animation: none; } }
.shell-footer { padding-right: 84px; }
.shell-header { background: rgb(36 59 89 / 94%); border-color: rgb(120 90 52 / 24%); backdrop-filter: blur(10px); }
.shell-brand { letter-spacing: 1.5px; text-transform: uppercase; font-size: 14.95px; }
.shell-global { position: relative; }
.shell-global > a { position: relative; color: #272f3e; font-size: 14.95px; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; transition: color 160ms ease, text-shadow 160ms ease; }
.shell-global > a:hover, .shell-global > a:focus-visible { color: var(--text); text-shadow: 0 0 14px rgb(51 124 120 / 42%); text-decoration: none; }
.application-shell .shell-global [aria-current="page"] { color: var(--gold); border-bottom-color: var(--gold); }
.shell-nav-indicator { display: none; position: absolute; left: 0; bottom: 0; height: 2px; border-radius: 999px; background: var(--gold); box-shadow: 0 0 16px rgb(180 138 66 / 74%); pointer-events: none; opacity: 0; transition: transform 180ms ease, width 180ms ease, opacity 160ms ease; }
.shell-global:not([data-indicator-animated]) .shell-nav-indicator { transition: none; }
.shell-account, .shell-status-dock > div { background: linear-gradient(145deg, #e0dbcc, #edeae0); border-color: var(--line); box-shadow: var(--panel-glow), var(--shadow); }
.shell-footer { background: rgb(240 237 229 / 78%); border-color: var(--line); }
@media (min-width: 64rem) {
  .shell-global[data-indicator-ready] > a[aria-current="page"] { border-bottom-color: transparent; }
  .shell-global[data-indicator-ready] .shell-nav-indicator { display: block; }
}
@media (prefers-reduced-motion: reduce) {
  .shell-nav-indicator, .shell-global > a, .shell-account-indicator, .shell-account a { transition: none; }
}
.shell-skip { position: fixed; top: -100px; left: 12px; padding: 12px; background: #dfdacb; z-index: 100; }
.shell-skip:focus { top: 8px; }
.application-shell .onboarding-shell { max-width: 100%; min-width: 0; }
@media (max-width: 63.99rem) {
  .shell-header { display: flex; justify-content: space-between; padding: 12px 16px; }
  .shell-brand { max-width: min(65vw, 280px); }
  .shell-menu { display: block; }
  .shell-menu > summary, .shell-menu:has(.shell-sign-in) > summary { display: block; }
  .shell-mobile-label { display: inline; }
  .shell-group-label { display: block; text-transform: uppercase; font-size: .77625rem; color: #3f4a62; margin: 10px 8px 2px; }
  .shell-desktop-label { display: none; }
  .shell-menu-content { display: none; position: absolute; top: 100%; right: 0; width: min(100vw, 260px); max-height: calc(100dvh - 85px); overflow-y: auto; overscroll-behavior: contain; padding: 16px max(16px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)); background: #dfdacb; border: 1px solid #b1ac9b; }
  .shell-menu[open] .shell-menu-content { display: block; }
  .shell-global { display: flex; flex-direction: column; align-items: stretch; gap: 0; }
  .application-shell .shell-global a, .application-shell .shell-account a { min-height: 36px; padding: 5px 8px; }
  .shell-global > a { font-weight: 500; letter-spacing: .8px; }
  .application-shell .shell-global > a { padding-left: 20px; }
  .application-shell .shell-account a:not(.shell-sign-in) { padding-left: 20px; border-bottom-color: transparent; color: #272f3e; }
  .application-shell .shell-account a:not(.shell-sign-in)[data-highlighted] { color: var(--gold); text-shadow: 0 0 14px rgb(180 138 66 / 35%); }
  .shell-global .shell-nav-indicator { z-index: 2; }
  .shell-global[data-indicator-ready] .shell-nav-indicator { display: block; top: 0; bottom: auto; height: 10px; border-radius: 0; clip-path: polygon(0 0, 100% 50%, 0 100%); }
  .application-shell .shell-global[data-indicator-ready] > a { border-bottom-color: transparent; color: #272f3e; }
  .application-shell .shell-global[data-indicator-ready] > a[data-highlighted] { color: var(--gold); text-shadow: 0 0 14px rgb(180 138 66 / 35%); }
  .shell-mobile-utility { display: block; border-top: 1px solid #b1ac9b; }
  .shell-mobile-utility a { display: flex; align-items: center; }
  .shell-account, .shell-menu:has(.shell-sign-in) .shell-account { display: block; position: static; border: 0; border-top: 1px solid #b1ac9b; padding: 8px 0; margin-top: 8px; width: 100%; max-height: none; overflow: visible; }
  .shell-main { padding: 24px 16px; }
  .shell-footer { padding: 8px 84px 8px 16px; }
  /* Below desktop the status dock sits in the footer's reserved right edge instead of floating over content. */
  [id="shell:overlays"] { position: relative; padding: 0; }
  .shell-status-dock { position: absolute; bottom: 8px; }
}
@media (max-width: 47.99rem) {
  .shell-footer { flex-wrap: nowrap; gap: 12px; height: 64px; min-height: 64px; padding: 8px 72px 8px 16px; }
  .shell-status-dock { right: max(8px, env(safe-area-inset-right)); }
  [id="shell:overlays"] { padding: 0; }
  /* Narrow footers collapse every link into the TTP menu, opened upward. */
  .shell-footer { position: relative; }
  .shell-footer .shell-footer-name, .shell-footer-links { display: none; }
  .shell-footer-short { display: inline-flex; flex: 0 0 auto; }
  .shell-footer[data-footer-open] .shell-footer-links { position: absolute; left: 16px; bottom: calc(100% + 8px); z-index: 45; display: flex; flex-direction: column; min-width: 200px; padding: 8px 0; background: #e7e3d8; border: 1px solid var(--line); border-radius: 6px; box-shadow: var(--shadow); }
  .shell-footer[data-footer-open] .shell-footer-links a { min-height: 44px; padding: 0 16px; }
  .shell-footer[data-footer-open] .shell-footer-legal { display: contents; }
  .application-shell .shell-footer[data-footer-open] .shell-footer-discord { justify-content: flex-start; gap: 8px; color: inherit; }
  .shell-footer[data-footer-open] .shell-footer-discord-label { display: inline; }
}
/* Dropdown typography is independent of the persistent header. */
.shell-account { font-size: 1.035rem; }
@media (max-width: 63.99rem) {
  .shell-menu-content { font-size: 1.035rem; }
  .shell-global > a { font-size: 13.455px; }
}
@media (max-width: 63.99rem) {
  .shell-brand-full { display: block; overflow-wrap: normal; }
  .shell-brand { min-width: 0; flex: 1 1 auto; }
  .shell-brand img, .shell-menu > summary { flex-shrink: 0; }
}
.shell-mobile-label { white-space: nowrap; }

/* Self-view Profile uses the account shell without a workspace rail. */
.profile-content { max-width: 48rem; }
.profile-identity { display: flex; align-items: center; gap: 1.5rem; padding: 1.5rem; border: 1px solid #b1ac9b; border-radius: 12px; background: #dfdacb; }
.profile-avatar { position: relative; flex: 0 0 96px; width: 96px; height: 96px; }
.profile-avatar img { display: block; width: 96px; height: 96px; border-radius: 50%; object-fit: cover; }
.profile-avatar .profile-avatar-remote { position: absolute; inset: 0; }
.profile-avatar [hidden] { display: none; }
.profile-name { min-width: 0; overflow-wrap: anywhere; font-size: 1.5rem; font-weight: 600; }
.profile-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 1.5rem; }
@media (max-width: 30rem) { .profile-identity { flex-direction: column; align-items: flex-start; } }

/* Profile Service record (TRD Profile Service record). Sizes are step classes: the CSP blocks inline styles. */
.profile-content.profile-content-wide { max-width: 72rem; }
.profile-identity-text { min-width: 0; }
.service-record-chip { display: inline-block; margin: .5rem 0 0; padding: .15rem .65rem; border: 1px solid var(--sr-accent); border-radius: 999px; color: var(--sr-accent-text); font-size: .85rem; font-weight: 600; }
.profile-content-wide { --sr-panel: #e6e1d3; --sr-line: #bfb9a7; --sr-bar: #337c78; --sr-bar-soft: rgb(51 124 120 / 45%); --sr-accent: #b8862b; --sr-accent-text: #7a5512; --sr-earned: rgb(184 134 43 / 12%); --sr-track: rgb(23 27 36 / 10%); --sr-defense: #b8862b; --sr-industry: #337c78; --sr-support: #7d8597; --sr-ok: #218344; --sr-warn: #a31500; }
.service-record { margin-top: 2.5rem; }
.service-record h2, .service-record h3, .service-record h4, .service-record-history h2 { margin: 0; }
.service-record-header { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.service-record-eyebrow { margin: 0 0 .25rem; color: var(--sr-accent-text); font-size: .75rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.service-record-periods { display: inline-flex; flex-wrap: wrap; gap: .25rem; padding: .25rem; border: 1px solid var(--sr-line); border-radius: 10px; }
.service-record-periods a { padding: .35rem .75rem; border-radius: 7px; color: var(--muted); text-decoration: none; font-size: .9rem; }
.service-record-periods a[aria-current="true"] { background: var(--sr-panel); color: var(--text); font-weight: 600; box-shadow: inset 0 0 0 1px var(--sr-line); }
.service-record-panel { min-width: 0; margin: 0 0 1rem; padding: 1.25rem; border: 1px solid var(--sr-line); border-radius: 12px; background: var(--sr-panel); }
.service-record-panel-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .5rem 1rem; margin-bottom: 1rem; }
.service-record-muted { margin: 0; color: var(--muted); font-size: .9rem; }
.service-record-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.service-record-tile { padding: 1rem 1.25rem; border: 1px solid var(--sr-line); border-radius: 12px; background: var(--sr-panel); }
.service-record-tile p { margin: 0; }
.service-record-tile-label { color: var(--muted); font-size: .85rem; }
.service-record-tile-value { margin: .35rem 0 !important; font-size: 2rem; font-weight: 700; line-height: 1.1; }
.service-record-tile-value span { margin-left: .2rem; color: var(--muted); font-size: 1rem; font-weight: 500; }
.service-record-tile-note { color: var(--muted); font-size: .85rem; }
.service-record-tile-note.is-accent { color: var(--sr-accent-text); }
.service-record-chart { margin-inline: 0; }
.service-record-legend { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: 0; color: var(--muted); font-size: .85rem; }
.service-record-key-you { display: inline-block; width: .75rem; height: .75rem; border-radius: 2px; background: var(--sr-bar); }
.service-record-key-typical { display: inline-block; width: 1.25rem; margin-left: .5rem; border-top: 2px dashed var(--muted); }
.service-record-bars { position: relative; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: .5rem; height: 13rem; margin-bottom: 2.25rem; border-bottom: 1px solid var(--sr-line); }
.service-record-bar-column { position: relative; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; min-width: 0; height: 100%; }
.service-record-bar-track, .service-record-plot { position: relative; display: block; width: 100%; height: calc(100% - 1.25rem); }
.service-record-plot { position: absolute; left: 0; right: 0; bottom: 0; height: calc(100% - 1.25rem); pointer-events: none; z-index: 1; }
.service-record-bar { position: absolute; bottom: 0; left: 50%; display: block; width: min(100%, 2.75rem); min-height: 2px; border-radius: 4px 4px 0 0; background: var(--sr-bar); transform: translateX(-50%); }
.service-record-bar-value { position: absolute; left: 0; right: 0; line-height: 1.2; padding-bottom: .15rem; color: var(--text); font-size: .8rem; font-weight: 600; text-align: center; }
.service-record-bar-label { position: absolute; bottom: -1.5rem; color: var(--muted); font-size: .75rem; }
.service-record-typical { position: absolute; left: 0; right: 0; height: 0; border-top: 2px dashed var(--muted); opacity: .7; }
.service-record-bar.is-best { background: var(--sr-accent); }
.service-record-bar.is-partial { background: repeating-linear-gradient(135deg, var(--sr-bar) 0 6px, var(--sr-bar-soft) 6px 12px); }
.service-record-bar.is-best.is-partial { background: repeating-linear-gradient(135deg, var(--sr-accent) 0 6px, var(--sr-earned) 6px 12px); }
.service-record-subheading { margin: 1.5rem 0 .75rem !important; font-size: 1.1rem; }
.service-record-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.service-record-card { margin: 0; }
.service-record-card h4 { color: var(--sr-accent-text); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; }
.service-record-card p { margin: .5rem 0 0; }
.service-record-card-value { font-size: 1.5rem; font-weight: 700; }
.service-record-meter { display: block; height: .4rem; margin-top: .6rem; overflow: hidden; border-radius: 999px; background: var(--sr-track); }
.service-record-meter > span { display: block; height: 100%; border-radius: 999px; background: var(--sr-bar); }
.service-record-meter > span.is-first { background: var(--sr-accent); }
.service-record-ranked, .service-record-places, .service-record-split-legend, .service-record-people { margin: .75rem 0 0; padding: 0; list-style: none; }
.service-record-ranked li + li { margin-top: .6rem; }
.service-record-ranked-row, .service-record-places li, .service-record-split-legend li, .service-record-people li { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.service-record-places { list-style: decimal inside; }
.service-record-places li { display: list-item; }
.service-record-places li span + span { float: right; color: var(--muted); }
.service-record-places li + li, .service-record-split-legend li + li, .service-record-people li + li { margin-top: .45rem; }
.service-record-split { display: flex; height: .6rem; margin-top: .75rem; overflow: hidden; border-radius: 999px; background: var(--sr-track); }
.service-record-split > span { display: block; height: 100%; }
.service-record-split-legend li span:nth-child(2) { flex: 1; }
.service-record-swatch { width: .7rem; height: .7rem; border-radius: 2px; }
.service-record .is-defense { background: var(--sr-defense); } .service-record .is-industry { background: var(--sr-industry); } .service-record .is-support { background: var(--sr-support); }
.service-record-people li span:nth-child(2) { flex: 1; }
.service-record-initials { display: inline-grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; background: var(--sr-track); font-size: .75rem; font-weight: 700; }
.service-record-track + .service-record-track { margin-top: 1.25rem; }
.service-record-track-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .25rem 1rem; margin-bottom: .6rem; }
.service-record-track-head h4 { color: var(--sr-accent-text); font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; }
.service-record-badges { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: .6rem; margin: 0; padding: 0; list-style: none; }
.service-record-badge { display: flex; flex-direction: column; align-items: center; gap: .3rem; min-width: 0; padding: .75rem .4rem; border: 1px solid var(--sr-line); border-radius: 10px; text-align: center; color: var(--muted); }
.service-record-badge.is-earned { border-color: var(--sr-accent); background: var(--sr-earned); color: var(--text); }
.service-record-badge.is-next { border-style: dashed; }
.service-record-badge-mark { display: inline-grid; place-items: center; width: 2.6rem; height: 2.6rem; border: 2px solid currentColor; border-radius: 50%; font-size: .8rem; font-weight: 700; }
.service-record-badge.is-earned .service-record-badge-mark { border-color: var(--sr-accent); color: var(--sr-accent-text); }
.service-record-badge-name { font-size: .85rem; font-weight: 600; overflow-wrap: anywhere; }
.service-record-badge-note { font-size: .75rem; }
.service-record-table-scroll { overflow-x: auto; }
.service-record-table { width: 100%; min-width: 36rem; border-collapse: collapse; font-size: .9rem; }
.service-record-table th { color: var(--muted); font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-align: left; text-transform: uppercase; }
.service-record-table td a, .service-record-card p a { text-decoration: underline; }
.service-record-table th, .service-record-table td { padding: .55rem .5rem; border-bottom: 1px solid var(--sr-line); }
.service-record-tag { display: inline-block; padding: .1rem .5rem; border-radius: 999px; background: var(--sr-track); font-size: .75rem; white-space: nowrap; }
.service-record-tag.is-on-time { color: var(--sr-ok); } .service-record-tag.is-late, .service-record-tag.is-left { color: var(--sr-warn); } .service-record-tag.is-led { color: var(--sr-accent-text); }
.service-record-new h3 { margin-bottom: .5rem; }
.service-record-footnote { margin: 1rem 0 0; color: var(--muted); font-size: .85rem; }
.svc-h-0 { height: 0%; } .svc-h-5 { height: 5%; } .svc-h-10 { height: 10%; } .svc-h-15 { height: 15%; } .svc-h-20 { height: 20%; } .svc-h-25 { height: 25%; } .svc-h-30 { height: 30%; } .svc-h-35 { height: 35%; } .svc-h-40 { height: 40%; } .svc-h-45 { height: 45%; } .svc-h-50 { height: 50%; } .svc-h-55 { height: 55%; } .svc-h-60 { height: 60%; } .svc-h-65 { height: 65%; } .svc-h-70 { height: 70%; } .svc-h-75 { height: 75%; } .svc-h-80 { height: 80%; } .svc-h-85 { height: 85%; } .svc-h-90 { height: 90%; } .svc-h-95 { height: 95%; } .svc-h-100 { height: 100%; }
.svc-b-0 { bottom: 0%; } .svc-b-5 { bottom: 5%; } .svc-b-10 { bottom: 10%; } .svc-b-15 { bottom: 15%; } .svc-b-20 { bottom: 20%; } .svc-b-25 { bottom: 25%; } .svc-b-30 { bottom: 30%; } .svc-b-35 { bottom: 35%; } .svc-b-40 { bottom: 40%; } .svc-b-45 { bottom: 45%; } .svc-b-50 { bottom: 50%; } .svc-b-55 { bottom: 55%; } .svc-b-60 { bottom: 60%; } .svc-b-65 { bottom: 65%; } .svc-b-70 { bottom: 70%; } .svc-b-75 { bottom: 75%; } .svc-b-80 { bottom: 80%; } .svc-b-85 { bottom: 85%; } .svc-b-90 { bottom: 90%; } .svc-b-95 { bottom: 95%; } .svc-b-100 { bottom: 100%; }
.svc-w-0 { width: 0%; } .svc-w-5 { width: 5%; } .svc-w-10 { width: 10%; } .svc-w-15 { width: 15%; } .svc-w-20 { width: 20%; } .svc-w-25 { width: 25%; } .svc-w-30 { width: 30%; } .svc-w-35 { width: 35%; } .svc-w-40 { width: 40%; } .svc-w-45 { width: 45%; } .svc-w-50 { width: 50%; } .svc-w-55 { width: 55%; } .svc-w-60 { width: 60%; } .svc-w-65 { width: 65%; } .svc-w-70 { width: 70%; } .svc-w-75 { width: 75%; } .svc-w-80 { width: 80%; } .svc-w-85 { width: 85%; } .svc-w-90 { width: 90%; } .svc-w-95 { width: 95%; } .svc-w-100 { width: 100%; }
@media (width < 48rem) {
  .service-record-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
  .service-record-tile { padding: .8rem; }
  .service-record-tile-value { font-size: 1.6rem; }
  .service-record-bars { gap: .2rem; height: 11rem; }
  .service-record-bar-value { font-size: .7rem; }
  .service-record-bar-label { font-size: .65rem; }
  .service-record-cards { grid-template-columns: minmax(0, 1fr); }
  .service-record-badges { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Account Settings retains one narrow, wrapping content column inside the shell. */
.settings-content { max-width: 70rem; margin-inline: auto; }
.settings-section-links { display: flex; flex-wrap: wrap; gap: .75rem 1.5rem; margin-block: 1.5rem 2rem; }
.settings-panel { min-width: 0; padding: clamp(1rem, 3vw, 2rem); margin-block: 1.5rem; border: 1px solid #bfb9a7; background: #dad4c4; border-radius: .5rem; scroll-margin-top: 7rem; overflow-wrap: anywhere; }
.settings-panel h2 { margin-top: 0; }
.settings-form-row { display: flex; flex-wrap: wrap; align-items: end; gap: 1rem 1.5rem; margin-top: .5rem; }
.settings-form-row select { width: min(100%, 20rem); min-width: 0; max-width: 100%; }
.settings-form-row button { flex: 0 0 auto; max-width: 100%; white-space: normal; }
.settings-feedback { margin-top: 1rem; }
.settings-details { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: .75rem 1.5rem; }
.settings-details dd { margin: 0; }
.settings-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
@media (max-width: 40rem) { .settings-details { grid-template-columns: 1fr; } .settings-details dt { font-weight: 600; } }
.settings-feedback[role="alert"] { color: #a33800; }
.settings-feedback[role="status"] { color: #2a7954; }
@media (max-width: 30rem) { .settings-form-row { align-items: stretch; flex-direction: column; } }

/* Slice 13 content consumes the workspace frame and existing feature styles. */
.application-shell .command-module { width: 100%; min-width: 0; }
.application-shell .command-module .content-band { min-width: 0; }
.application-shell .command-module .table-wrap,
.application-shell .command-module .table-band { max-width: 100%; overflow-x: auto; }
.application-shell .command-module .review-hero,
.application-shell .command-module .app-header { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }
.application-shell .command-approval-confirmation summary { cursor: pointer; font-weight: 600; }
.application-shell .command-module :is(input, select, textarea) { max-width: 100%; }
@media (max-width: 767px) {
  .application-shell .command-module :is(.summary-grid, .stats-control-grid, .interview-form-grid) { grid-template-columns: minmax(0, 1fr); }
  .application-shell .command-module .filters { flex-wrap: wrap; }
  .application-shell .command-module .detail-field-list .field-row { overflow-wrap: anywhere; }
}

/* Command membership review keeps facts and optional interview context distinct. */
.application-shell .command-module .command-approval-context { display: grid; gap: .75rem; min-width: 0; }
.application-shell .command-module .command-approval-context > div { padding: .85rem; border: 1px solid rgb(123 122 119 / 42%); border-radius: .4rem; }
.application-shell .command-module .command-approval-context p { margin: .4rem 0 0; }
.application-shell .command-module .command-capability-notice { padding: .85rem; border: 1px solid rgb(123 122 119 / 42%); border-radius: .4rem; }
.application-shell .command-module .command-first-seen-help { margin-block: .5rem; }
.application-shell .command-module .command-table:focus-visible { outline: 2px solid #785a34; outline-offset: 3px; }
.application-shell .command-module .command-interviews-table { min-width: 860px; }
.application-shell .command-module .member-list-table td:first-child { overflow-wrap: anywhere; max-width: 20rem; }
.application-shell .command-module .command-approval-confirmation summary { min-height: 44px; padding-block: .7rem; cursor: pointer; }
.application-shell .command-module .interview-unsaved-alert[hidden] { display: none; }
.application-shell .command-module .command-table { position: relative; }
.application-shell .command-module .metric-cluster { max-width: 100%; }
.application-shell .command-module .metric-cluster strong { min-width: 0; flex: 1; padding-inline: .5rem; }

/* A failed Stats refresh remains visually distinct from retained results. */
.application-shell .command-module .stats-refresh-feedback { border: 1px solid #b48a42; background: #785a34; }
.application-shell .command-module .stats-refresh-feedback [data-stats-refresh-error] { color: #785a34; font-weight: 600; }
.application-shell .command-module .stats-result-context h2 { margin: 0 0 .5rem; font-size: 1.05rem; line-height: 1.4; }
/* System Admin module tools retain the workspace's responsive frame. */
.system-admin-tool { min-width: 0; container-type: inline-size; overflow-wrap: anywhere; }
.system-admin-tool .field { min-width: 0; }
.system-admin-tool button:enabled:not([aria-disabled="true"]) { cursor: pointer; }
.system-admin-tool input:not([type="checkbox"]):not([type="hidden"]),
.system-admin-tool select, .system-admin-tool textarea { width: 100%; min-width: 0; max-width: 100%; font-size: 1rem; box-sizing: border-box; }
.system-admin-tool textarea { min-height: 7rem; }
.system-admin-tool button, .system-admin-tool .button-link,
.system-admin-tool .feature-flag-detail-link, .system-admin-tool summary { min-height: 44px; }
.system-admin-tool .button-link, .system-admin-tool .feature-flag-detail-link { display: inline-flex; align-items: center; padding: .6rem .8rem; }
.system-admin-filters { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 1rem; margin-bottom: 1.5rem; }
.system-admin-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; }
.system-admin-tool .checkbox-dropdown { min-width: 0; }
/* The open menu overlays the filters and table instead of pushing them down. */
.system-admin-tool .checkbox-menu { position: absolute; top: 100%; left: 0; z-index: 30; width: min(max(100%, 320px), calc(100vw - 32px)); max-height: 20rem; overflow-y: auto; }
.system-admin-tool .checkbox-menu label { min-height: 44px; display: flex; align-items: center; gap: .75rem; }
.system-admin-tool .checkbox-menu input { flex: none; }
/* Horizontal table overflow must still allow vertical wheel scrolling of the page. */
.system-admin-tool .system-admin-scroll { max-width: 100%; overflow-x: auto; overscroll-behavior-y: auto; margin: 1rem 0; }
.system-admin-tool table { width: 100%; table-layout: fixed; }
.system-admin-tool table caption { text-align: left; padding: .75rem; font-weight: 600; }
.system-admin-tool th, .system-admin-tool td { white-space: normal; overflow-wrap: anywhere; }
.system-admin-tool .audit-log-table { min-width: 48rem; }
.system-admin-tool .metadata-json { white-space: pre-wrap; overflow-wrap: anywhere; word-break: break-word; }
.system-admin-tool .pagination { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; margin-top: 1rem; }
.system-admin-tool .feature-flag-table { min-width: 54rem; }
.system-admin-tool .feature-flag-table th:first-child { width: 34%; }
.system-admin-tool .feature-flag-table th:last-child { width: 6rem; }
.system-admin-tool .feature-flag-table code { display: block; white-space: normal; overflow-wrap: anywhere; }
.system-admin-tool .feature-flag-detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; width: min(100%, calc(100cqi - 2rem)); min-width: 0; }
.system-admin-tool .feature-flag-detail-panel { min-width: 0; padding: 1rem; }
.system-admin-tool .feature-flag-detail-panel h2 { scroll-margin-top: 1rem; }
.system-admin-tool .feature-flag-form { margin-top: 1rem; }
.system-admin-tool .system-admin-feedback { margin-bottom: 1rem; }
@container (max-width: 760px) {
  .system-admin-tool .feature-flag-detail-grid { grid-template-columns: minmax(0, 1fr); }
}
@container (max-width: 600px) {
  .system-admin-filters { grid-template-columns: minmax(0, 1fr); }
  .system-admin-tool .feature-flag-detail-panel { padding: .5rem; }
}

/* Role Sync records and the bounded Account Support view. */
.system-admin-tool .system-admin-records { display: grid; gap: 1.5rem; }
.system-admin-tool .system-admin-work-record { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 2rem; padding: 1.5rem; border: 1px solid var(--line); border-radius: .75rem; background: var(--surface); }
.system-admin-related { display: flex; flex-wrap: wrap; gap: .75rem 2rem; margin-bottom: 1.5rem; padding-block: .5rem; }
[data-shell-page="system-admin-role-sync"] .system-admin-tool .system-admin-related a { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; text-decoration: none; }
.system-admin-related a:hover { text-decoration: underline; }
.system-admin-related span { color: var(--muted); font-size: .875rem; }
.system-admin-work-heading { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
.system-admin-work-heading h2 { margin: .25rem 0 0; font-size: 1.25rem; }
.system-admin-work-reference { margin: 0; color: var(--muted); font-size: .875rem; }
.system-admin-work-heading .badge { flex-shrink: 0; }
.system-admin-work-section h3 { margin: 0 0 .75rem; font-size: .875rem; color: var(--muted); }
.system-admin-tool .system-admin-work-record .system-admin-facts { background: none; border: 0; border-radius: 0; padding: 0; margin: 0; }
.system-admin-tool .system-admin-work-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; border-top: 1px solid var(--line); padding-top: 1rem; }
.system-admin-tool .system-admin-work-actions p { margin: 0; font-size: .875rem; }
.system-admin-tool .system-admin-work-record > *, .system-admin-tool .system-admin-panels > * { min-width: 0; }
.system-admin-tool .system-admin-panels { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; margin-block: 1.5rem; }
.system-admin-tool .system-admin-panels > section { border-top: 1px solid var(--line); padding-top: 1rem; }
.system-admin-tool [data-account-picker][hidden] { display: none; }
.system-admin-tool [data-account-picker] select { text-overflow: ellipsis; }
.system-admin-tool .system-admin-facts { margin-block: 1rem; }
.system-admin-tool .system-admin-facts > div { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: .5rem; margin-block: .6rem; }
.system-admin-tool .system-admin-facts dd { min-width: 0; margin: 0; }
.system-admin-tool .system-admin-facts dt { color: var(--muted); }
.system-admin-tool .system-admin-work-actions form { margin: 0; }
[data-shell-page="system-admin-role-sync"] .system-admin-tool a,
[data-shell-page="system-admin-account-support"] .system-admin-tool a { display: inline-flex; align-items: center; min-height: 44px; }
@container (max-width: 760px) {
  .system-admin-tool .system-admin-work-record, .system-admin-tool .system-admin-panels { grid-template-columns: minmax(0, 1fr); }
}
@container (max-width: 600px) {
  .system-admin-tool .system-admin-facts > div { grid-template-columns: minmax(0, 1fr); gap: .2rem; }
}

/* Operations administration keeps each independently selected section bounded. */
.operations-admin #attendance-exports { padding: 1.5rem; border: 1px solid var(--line); border-radius: .75rem; background: var(--surface); }
.operations-admin #attendance-exports h2 { margin-top: 0; }
.operations-export-batch { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; margin-block: 1.5rem; }
.operations-export-batch p { flex-basis: 100%; margin: 0; font-size: .875rem; }
.operations-export-history { border: 1px solid var(--line); border-radius: .5rem; }
.system-admin-tool .operations-export-table { min-width: 58rem; margin: 0; }
.operations-export-table th:first-child { width: 22%; }
.operations-export-table th:last-child { width: 6.5rem; }
.operations-export-table th[scope="row"] { font-weight: 400; text-transform: none; letter-spacing: normal; }
.operations-export-table th, .operations-export-table td { padding: .9rem .75rem; text-align: left; vertical-align: top; }
.operations-export-table form { margin: 0; }
.operations-export-secondary { display: block; color: var(--muted); margin-top: .4rem; font-size: .8rem; }
.operations-admin-section { border-top: 1px solid var(--border); margin-top: 2rem; padding-top: 1.5rem; scroll-margin-top: 6rem; }
.operations-admin-records { display: grid; gap: 1rem; list-style: none; margin: 1rem 0; padding: 0; }
.operations-admin-records > li { min-width: 0; overflow-wrap: anywhere; border: 1px solid var(--border); border-radius: .5rem; padding: 1rem; }
.operations-admin-form { display: grid; gap: 1rem; max-width: 48rem; margin-block: 1rem; }
.operations-admin-form .field { display: grid; gap: .4rem; min-width: 0; }
.operations-admin-form textarea { min-height: 7rem; resize: vertical; }
.operations-admin-summary { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .5rem; }
.operations-admin-summary dd { margin: 0; }
.operations-admin-confirm { display: flex; align-items: center; gap: .75rem; min-height: 44px; }
.operations-admin-confirm input { flex: 0 0 1.25rem; width: 1.25rem; height: 1.25rem; }
.operations-admin .system-admin-actions a { min-height: 44px; display: inline-flex; align-items: center; }
.operations-admin .system-admin-filters { margin-block: 1rem; }

/* Organization owns these rules; shared shell geometry stays unchanged. */
.organization-content { min-width: 0; }
.organization-content p, .organization-content h2, .organization-content h3 { overflow-wrap: anywhere; }
.organization-prose { max-width: 70ch; }
.organization-jumps { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 24px 0; }
.organization-jumps a { display: inline-flex; align-items: center; }
.organization-council, .organization-division, .organization-contacts { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); }
.organization-summary { min-width: 0; }
.organization-entity-heading { display: flex; align-items: center; gap: 16px; min-width: 0; margin-bottom: 20px; }
.organization-entity-heading h2, .organization-entity-heading h3 { flex: 1; min-width: 0; margin: 0; }
.organization-entity-heading-has-logo > h2, .organization-entity-heading-has-logo > h3 { scroll-margin-top: calc(var(--organization-logo-size) + 16px); }
.organization-division > .organization-entity-heading { --organization-logo-size: 128px; }
.organization-wing > .organization-entity-heading { --organization-logo-size: 80px; }
.organization-logo { display: flex; align-items: center; justify-content: center; flex: 0 0 var(--organization-logo-size); width: var(--organization-logo-size); height: var(--organization-logo-size); }
.organization-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.organization-logo-placeholder { border: 1px dashed var(--line-strong); border-radius: 8px; background: rgb(51 124 120 / 5%); color: var(--muted); font-size: 11px; line-height: 1.3; text-align: center; }
.organization-wings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 20px; }
.organization-wing { min-width: 0; padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.organization-wing h3 { margin-top: 0; }
.organization-graphic { min-width: 0; margin: 0; }
.organization-graphic img { display: block; width: auto; max-width: 100%; height: auto; }
.organization-graphic figcaption { color: var(--muted); margin-top: 8px; }
.organization-contact-region { max-width: 100%; overflow-x: auto; }
.organization-contact-table { width: 100%; min-width: 0; border-collapse: collapse; table-layout: fixed; }
.organization-contact-table th, .organization-contact-table td { padding: 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.organization-username { user-select: text; }
@media (min-width: 48rem) {
  .organization-summary-with-graphic { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 24px; }
}
@media (max-width: 47.999rem) {
  .organization-division > .organization-entity-heading { --organization-logo-size: 80px; }
  .organization-wing > .organization-entity-heading { --organization-logo-size: 64px; }
  .organization-wings { grid-template-columns: minmax(0, 1fr); }
  .organization-contact-table th, .organization-contact-table td { padding: 10px 6px; }
}

.home-box, .home-box p, .public-resources > div, .public-resources > div p, .workspace-navigation details, .workspace-navigation nav a { color: #f0ede4; }
.home-box p, .public-resources > div p { color: #d9d5c9; }
.home-box h2, .home-box h3, .public-resources > div h3, .workspace-navigation summary, .home-content .home-button { color: #f0ede4; }
.public-resources .public-text-link, .home-box a:not(.home-primary):not(.home-button) { color: #8fd3ce; }
/* Keep hovered links light on the Obsidian panels; the shell hover rule would turn them dark. */
.application-shell .workspace-navigation nav a:not([aria-current]):hover { color: #f0ede4; }
.application-shell .public-resources .public-text-link:hover, .application-shell .home-box a:not(.home-primary):not(.home-button):hover { color: #8fd3ce; }
.workspace-navigation nav a:not([aria-current]) small { color: #d9d5c9; }

.shell-header, .shell-header a, .shell-header summary, .shell-brand { color: #f0ede4; }
.shell-header a:hover { color: #e5c783; }
.application-shell .shell-header [aria-current="page"] { color: #e5c783; }
.shell-account { background: #faf9f5; }
.shell-account a, .shell-account button { color: #171b24; }
.shell-footer { background: #e7e3d8; }

/* Voice pickup and operation shortcut docks carry a tint of their state color: red for live voice, Imperial Navy for operations. */
.shell-voice-dock { border-color: rgb(163 21 0 / 42%); background: linear-gradient(135deg, rgb(163 21 0 / 10%), rgb(163 21 0 / 5%)), linear-gradient(135deg, rgb(228 223 210 / 96%), rgb(236 232 221 / 96%)), var(--surface); box-shadow: 0 14px 36px rgb(0 0 0 / 26%), 0 0 18px rgb(163 21 0 / 10%); }
.shell-voice-dock[data-voice-active] { border-color: rgb(163 21 0 / 72%); background: linear-gradient(135deg, rgb(163 21 0 / 17%), rgb(163 21 0 / 9%)), linear-gradient(135deg, rgb(228 223 210 / 96%), rgb(236 232 221 / 96%)), var(--surface); box-shadow: 0 14px 36px rgb(0 0 0 / 26%), 0 0 22px rgb(163 21 0 / 24%); }
.application-shell .shell-operation-box { border-color: rgb(36 59 89 / 66%); background: linear-gradient(135deg, rgb(36 59 89 / 17%), rgb(36 59 89 / 9%)), linear-gradient(135deg, rgb(228 223 210 / 96%), rgb(236 232 221 / 96%)), var(--surface); box-shadow: 0 14px 36px rgb(0 0 0 / 26%), 0 0 22px rgb(36 59 89 / 24%); }
.application-shell .shell-operation-box:hover, .application-shell .shell-operation-box:focus-visible { border-color: rgb(36 59 89 / 92%); background: linear-gradient(135deg, rgb(36 59 89 / 25%), rgb(36 59 89 / 14%)), linear-gradient(135deg, rgb(219 213 197 / 98%), rgb(232 228 216 / 98%)), var(--surface); }
.shell-operation-dot { background: #2f5d94; box-shadow: 0 0 0 0 rgb(47 93 148 / 68%), 0 0 16px rgb(47 93 148 / 72%); }
@keyframes operation-live-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgb(47 93 148 / 68%), 0 0 16px rgb(47 93 148 / 72%); } 50% { box-shadow: 0 0 0 8px rgb(47 93 148 / 0%), 0 0 20px rgb(47 93 148 / 90%); } }
/* Appearance control in the header: a circle with the active scheme's icon slides out into a pill holding the three options and the chosen name. */
/* Desktop: the wrapper dissolves so the nav keeps its grid column; the control takes column 5, directly left of the account menu. */
.shell-header-utility { display: contents; }
.shell-appearance { position: relative; display: block; width: 40px; height: 40px; grid-column: 5; grid-row: 1; justify-self: end; }
.shell-appearance::details-content { content-visibility: visible; display: contents; }
.shell-appearance[open] { z-index: 65; }
.application-shell .shell-header .shell-appearance-toggle { position: absolute; top: 0; right: 0; z-index: 2; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; border: 1px solid transparent; border-radius: 50%; background: transparent; color: #f0ede4; cursor: pointer; list-style: none; box-shadow: none; transition: color 160ms ease, background-color 160ms ease, transform 160ms ease; }
.shell-appearance-toggle::-webkit-details-marker, .shell-appearance-toggle::marker { display: none; content: ''; }
.application-shell .shell-header .shell-appearance-toggle:hover, .application-shell .shell-header .shell-appearance-toggle:focus-visible { color: #e5c783; background: rgb(240 237 229 / 10%); border-color: rgb(240 237 229 / 18%); }
.application-shell .shell-header .shell-appearance[open] > .shell-appearance-toggle { color: #e5c783; background: transparent; border-color: transparent; }
.application-shell .shell-header .shell-appearance-toggle:active { transform: scale(.92); }
.shell-appearance-current, .shell-appearance-label > span { display: none; }
.shell-appearance-current svg { display: block; }
:root[data-color-scheme="light"] .shell-appearance [data-scheme="light"], :root[data-color-scheme="dark"] .shell-appearance [data-scheme="dark"], :root[data-color-scheme="system"] .shell-appearance [data-scheme="system"] { display: block; }
/* The pill grows leftwards from the circle and overlays the header's spare space, so nothing reflows. */
.shell-appearance-menu { position: absolute; top: 0; right: 0; z-index: 1; display: flex; align-items: center; gap: 2px; box-sizing: border-box; height: 40px; max-width: 40px; padding: 0 42px 0 5px; border: 1px solid rgb(240 237 229 / 26%); border-radius: 20px; background: #35537c; color: #f0ede4; white-space: nowrap; overflow: hidden; opacity: 0; visibility: hidden; pointer-events: none; transition: max-width 240ms cubic-bezier(.2, .8, .2, 1), opacity 140ms ease, visibility 0s linear 240ms; }
.shell-appearance[open] > .shell-appearance-menu { max-width: 320px; opacity: 1; visibility: visible; pointer-events: auto; transition: max-width 240ms cubic-bezier(.2, .8, .2, 1), opacity 140ms ease, visibility 0s; }
@media (prefers-reduced-motion: reduce) { .shell-appearance-menu { transition: none; } }
.shell-appearance-options { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 2px; }
.application-shell .shell-header .shell-appearance-option { display: inline-flex; flex: 0 0 30px; align-items: center; justify-content: center; box-sizing: border-box; width: 30px; height: 30px; min-width: 0; min-height: 0; padding: 0; border: 1px solid transparent; border-radius: 50%; background: transparent; color: #f0ede4; cursor: pointer; box-shadow: none; transition: color 140ms ease, background-color 140ms ease; }
.application-shell .shell-header .shell-appearance-option:hover, .application-shell .shell-header .shell-appearance-option:focus-visible { color: #e5c783; background: rgb(240 237 229 / 12%); }
.application-shell .shell-header .shell-appearance-option[aria-pressed="true"] { color: #1e232f; background: var(--gold); border-color: var(--gold); }
.shell-appearance-option svg { display: block; }
.shell-appearance-label { display: inline-block; flex: 0 0 auto; padding: 0 2px 0 8px; font-size: .9rem; font-weight: 600; letter-spacing: .2px; color: #f0ede4; }
@media (max-width: 63.99rem) {
  .shell-header-utility { display: flex; align-items: center; flex-shrink: 0; gap: 2px; }
  .shell-appearance { width: 44px; height: 44px; }
  .application-shell .shell-header .shell-appearance-toggle { width: 44px; height: 44px; }
  .shell-appearance-menu { height: 44px; max-width: 44px; padding-right: 46px; border-radius: 22px; }
  .application-shell .shell-header .shell-appearance-option { flex-basis: 34px; width: 34px; height: 34px; }
}

/* System Admin -> Access (Access Groups slice 2). */
.system-admin-access .access-tabs { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 1.25rem; border-bottom: 1px solid var(--line); }
.system-admin-access .access-tabs a { display: inline-flex; align-items: center; min-height: 44px; padding: .5rem .9rem; text-decoration: none; border-bottom: 3px solid transparent; }
.system-admin-access .access-tabs a[aria-current="page"] { border-bottom-color: currentColor; font-weight: 600; }
.system-admin-access .access-groups { display: grid; grid-template-columns: minmax(12rem, 16rem) minmax(0, 1fr); gap: 1.5rem; align-items: start; }
@container (max-width: 760px) { .system-admin-access .access-groups { grid-template-columns: minmax(0, 1fr); } }
.system-admin-access .access-group-list ul { list-style: none; margin: 0; padding: 0; }
.system-admin-access .access-group-list li a { display: flex; align-items: center; min-height: 44px; padding: .4rem .75rem; text-decoration: none; border-radius: 6px; }
.system-admin-access .access-group-list li a[aria-current="true"] { font-weight: 600; outline: 2px solid currentColor; outline-offset: -2px; }
.system-admin-access .access-group-panel { min-width: 0; }
.system-admin-access .access-area { min-width: 0; margin: 0 0 1rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 6px; }
.system-admin-access .access-area legend { font-weight: 600; padding: 0 .25rem; }
/* Permission row: checkbox in its own column; label, badges and description share the text column. */
.system-admin-access .access-permission { display: grid; grid-template-columns: 1.125rem minmax(0, 1fr); column-gap: .75rem; padding: .75rem 0; border-top: 1px solid var(--line); }
.system-admin-access .access-permission:first-of-type { border-top: 0; }
.system-admin-access .access-permission > input[type="checkbox"] { align-self: start; width: 1.125rem; height: 1.125rem; margin: .15rem 0 0; }
.system-admin-access .access-permission-title { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem .5rem; }
.system-admin-access .access-permission-title label { font-weight: 600; line-height: 1.4; cursor: pointer; }
.system-admin-access .access-permission:has(input:disabled) .access-permission-title label { cursor: default; }
.system-admin-access .access-permission-title .badge { min-height: 0; padding: 1px 8px; font-size: .78rem; font-weight: 600; line-height: 1.4; white-space: nowrap; }
.system-admin-access .access-badge-plain { color: var(--muted); background: transparent; border: 1px solid currentColor; }
.system-admin-access .access-permission p { margin: .2rem 0 0; }
.system-admin-access .access-permission-inherited input, .system-admin-access .access-permission-standing input { outline: 2px dashed currentColor; outline-offset: 1px; }
/* Editor facts: the value column stacks its list and Add control with a gap
   instead of running text into the button. */
.system-admin-access .system-admin-facts > div { align-items: start; }
.system-admin-access .system-admin-facts dd { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; }
.system-admin-access .system-admin-facts dd > .access-role-list { flex: 1 0 100%; }
.system-admin-access .system-admin-facts dt,
.system-admin-access .system-admin-facts dd > .muted { min-height: 2.75rem; display: inline-flex; align-items: center; }
.system-admin-access .access-role-list { list-style: none; margin: 0; padding: 0; }
.system-admin-access .access-role-list li { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; min-height: 2rem; }
.system-admin-access .access-role-swatch { display: inline-block; width: .75rem; height: .75rem; border-radius: 50%; background: var(--access-role-color, transparent); border: 1px solid currentColor; }
.system-admin-access .access-check-search { display: flex; flex-wrap: wrap; gap: .75rem; align-items: end; max-width: 36rem; }
.system-admin-access .access-check-search .field { flex: 1 1 16rem; }
.system-admin-access .access-check-table { min-width: 32rem; }
.system-admin-access [role="listbox"] { list-style: none; margin: 0; padding: 0; }
.system-admin-access [role="listbox"]:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.system-admin-access [role="option"] { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; min-height: 44px; padding: .4rem .75rem; border-radius: 6px; cursor: pointer; }
.system-admin-access [role="option"][aria-selected="true"] { font-weight: 600; outline: 2px solid currentColor; outline-offset: -2px; }
.system-admin-access .access-list-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .75rem; }
.system-admin-access button.secondary { background: transparent; color: inherit; border: 1px solid currentColor; }
.system-admin-access button.secondary:disabled { opacity: .55; cursor: not-allowed; }
.system-admin-access .link-button { background: none; border: 0; padding: .25rem .4rem; min-height: 44px; color: inherit; text-decoration: underline; cursor: pointer; }
.system-admin-access .link-button:disabled { text-decoration: none; opacity: .6; cursor: not-allowed; }
.system-admin-access .access-who .field { max-width: 32rem; }
.system-admin-access .access-who textarea, .system-admin-access .access-who input, .system-admin-access .access-who select { width: 100%; max-width: 100%; box-sizing: border-box; }
.system-admin-access .access-savebar { position: sticky; bottom: .75rem; z-index: 40; box-shadow: 0 6px 18px rgb(0 0 0 / 18%); display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-top: 1rem; padding: .75rem 1rem; background: var(--surface, #fff); border: 1px solid var(--line); border-radius: 6px; }
.system-admin-access .access-pending { margin: 0 auto 0 0; }
/* Keep Save clear of the fixed shell docks: the voice/operation dock (bottom left, every width) and the status dock (bottom right, desktop). */
@media (min-width: 64rem) { .system-admin-access .access-savebar { bottom: 66px; } }
.application-shell:has(.shell-voice-dock, .shell-operation-dock:not([hidden])) .system-admin-access .access-savebar { bottom: calc(max(20px, env(safe-area-inset-bottom)) + 66px); }
.system-admin-access .access-notice { margin: 0 0 1rem; padding: .75rem 1rem; border: 1px solid currentColor; border-radius: 6px; }
.system-admin-access .access-dialog { width: min(40rem, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); overflow: auto; box-sizing: border-box; padding: 1.25rem; border: 1px solid var(--line); border-radius: 8px; color: inherit; background: var(--surface, #fff); }
.system-admin-access .access-dialog::backdrop { background: rgb(0 0 0 / .45); }
.system-admin-access .access-dialog-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .5rem; margin-top: 1rem; }
.system-admin-access .access-add-results { list-style: none; margin: 0; padding: 0; max-height: 18rem; overflow: auto; }
.system-admin-access .access-add-results li { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.system-admin-access .access-unsaved { font-size: .8em; }

/* Runtime Settings (read-only page) */
.runtime-settings-state { color: var(--muted); }
.runtime-settings-section { margin-block: 1.5rem; }
.runtime-settings-section h2, .runtime-settings-attention h2 { font-size: 1.1rem; margin-bottom: .25rem; }
.runtime-settings-help { display: block; font-size: .85rem; color: var(--muted); }
.runtime-settings-attention { padding: 12px 16px; border: 1px solid #b1ac9b; border-radius: 6px; }
/* Runtime Settings editing */
.runtime-settings .runtime-settings-changed dt::after { content: " · changed"; color: var(--muted); font-weight: 400; }
.runtime-settings button.secondary { background: transparent; color: inherit; border: 1px solid currentColor; }
.runtime-settings button:disabled { opacity: .55; cursor: not-allowed; }
.runtime-settings-picker { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.runtime-settings-picker-button { min-height: 44px; padding: 0 12px; text-align: left; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: inherit; }
.runtime-settings-picker-panel { position: absolute; top: calc(100% + 4px); left: 0; z-index: 20; width: min(26rem, calc(100vw - 2rem)); padding: .5rem; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: 0 8px 24px rgb(0 0 0 / 25%); }
.runtime-settings-picker-search { width: 100%; box-sizing: border-box; min-height: 40px; }
.runtime-settings-picker-list { list-style: none; margin: .4rem 0 0; padding: 0; max-height: 18rem; overflow: auto; }
.runtime-settings-picker-list [role="option"] { padding: .55rem .5rem; border-radius: 4px; cursor: pointer; }
.runtime-settings-picker-list [role="option"]:hover, .runtime-settings-picker-list [role="option"]:focus { outline: 2px solid var(--line); }
.runtime-settings-picker-list [aria-selected="true"] { font-weight: 600; }
.runtime-settings-picker-list [aria-selected="true"]::before { content: "✓ "; }
.runtime-settings-picker-group { padding: .5rem .5rem .2rem; font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.runtime-settings-picker-note, .runtime-settings-hint { font-size: .85rem; color: var(--muted); }
.runtime-settings-id { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .8rem; color: var(--muted); }
.runtime-settings-chips { display: flex; flex-wrap: wrap; gap: .3rem; width: 100%; }
.runtime-settings-chip { display: inline-flex; align-items: center; gap: .2rem; padding: 2px 4px 2px 10px; border: 1px solid var(--line); border-radius: 999px; }
.runtime-settings-chip-remove { min-width: 32px; min-height: 32px; border: 0; background: transparent; color: inherit; cursor: pointer; }
.runtime-settings-number-row { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.runtime-settings-number { width: 7rem; min-height: 40px; }
.runtime-settings-text { width: min(32rem, 100%); min-height: 40px; box-sizing: border-box; }
.runtime-settings-field-error { display: block; font-size: .85rem; color: #a31500; }
.runtime-settings-footer { position: sticky; bottom: 0; z-index: 10; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.runtime-settings-footer p { margin: 0; }
.runtime-settings-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .5rem; margin-left: auto; }
.runtime-settings-review { width: min(48rem, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); overflow: auto; box-sizing: border-box; padding: 1.25rem; border: 1px solid var(--line); border-radius: 8px; color: inherit; background: var(--surface, #fff); }
.runtime-settings-review::backdrop { background: rgb(0 0 0 / .45); }
.runtime-settings-diff { width: 100%; border-collapse: collapse; }
.runtime-settings-diff th { text-align: left; font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.runtime-settings-diff td, .runtime-settings-diff th { padding: .5rem; border-bottom: 1px solid var(--line); vertical-align: top; overflow-wrap: anywhere; }
.runtime-settings-consequence { margin: .4rem 0 0; font-size: .85rem; }
.runtime-settings-check { display: flex; gap: .6rem; align-items: flex-start; margin-top: .75rem; }
.runtime-settings-refusals h3, .runtime-settings-warnings h3 { font-size: 1rem; margin-bottom: .25rem; }
.runtime-settings-refusals { color: #a31500; }
.system-admin-inline-action { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-block: 1rem; }
.system-admin-inline-action p { margin: 0; }

/* System Admin, Media (Rich Content Release 1). */
.media-admin-thumb { display: block; max-width: 96px; height: auto; border-radius: 4px; background: var(--surface-muted, transparent); }
.media-admin-confirm .media-admin-thumb { max-width: 160px; }
.media-admin-totals { margin-bottom: 1.5rem; }
.media-admin-uses { margin: 0; padding-left: 1rem; }
.media-admin-table td { vertical-align: top; }
/* UX review UX-6: the Media table's delete link and visibility badge. */
.media-admin-table a.button-link.danger-button { border-color: rgb(163 21 0 / 62%); color: #a31300; background: rgb(135 36 28 / 38%); }
.media-admin-table a.button-link.danger-button:hover, .media-admin-table a.button-link.danger-button:focus-visible { border-color: #a31500; background: rgb(132 38 31 / 58%); }
.media-admin-badge { display: inline-block; padding: .1rem .5rem; border: 1px solid var(--line-strong, currentColor); border-radius: 999px; font-size: .85rem; }
.media-admin-table { min-width: 48rem; }
.media-admin-apply { width: auto; }

/* Feature Flags filters (issue #825). */
.system-admin-tool .feature-flag-filters { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: var(--radius); }
.system-admin-tool .feature-flag-filter-component { flex: 0 1 16rem; }
.system-admin-tool .feature-flag-filter-keyword { flex: 1 1 10rem; }
.system-admin-tool .feature-flag-filter-value { margin: 0; padding: 0; border: 0; min-width: 0; }
.system-admin-tool .feature-flag-filter-value legend { padding: 0; margin-bottom: .35rem; }
.system-admin-tool .feature-flag-segments { display: inline-flex; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.system-admin-tool .feature-flag-segments label { position: relative; display: inline-flex; align-items: center; justify-content: center; min-width: 3.5rem; min-height: 44px; padding: 0 .9rem; font-weight: 600; cursor: pointer; border-left: 1px solid var(--line); }
.system-admin-tool .feature-flag-segments label:first-child { border-left: 0; }
.system-admin-tool .feature-flag-segments input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.system-admin-tool .feature-flag-segments label:has(input:checked) { background: var(--blue); color: var(--on-accent, #f0ede4); }
.system-admin-tool .feature-flag-segments label:has(input:focus-visible) { outline: 2px solid var(--blue-hot); outline-offset: -3px; }
.system-admin-tool .feature-flag-filter-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; margin-left: auto; min-height: 44px; }
.system-admin-tool .feature-flag-count { font-weight: 600; font-variant-numeric: tabular-nums; }
.system-admin-tool .feature-flag-empty { display: grid; justify-items: center; gap: .5rem; padding: 2rem 1rem; margin: 1rem 0; text-align: center; border: 1px solid var(--line); border-radius: var(--radius); }
.system-admin-tool .feature-flag-empty p { margin: 0; }
.system-admin-flags [hidden] { display: none !important; }
.system-admin-tool .feature-flag-value { display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.system-admin-tool .feature-flag-dot { flex: none; width: .65rem; height: .65rem; border-radius: 50%; background: var(--muted); }
.system-admin-tool .feature-flag-dot.is-on { background: var(--green); }
.system-admin-tool .feature-flag-compact-value { display: none; margin: .25rem 0 .5rem; }
.system-admin-tool .feature-flag-cell { max-width: calc(100cqi - 2rem); }
.system-admin-tool .feature-flag-form-row { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem; }
.system-admin-tool .feature-flag-form-row .field { flex: 1 1 9rem; }
.system-admin-tool .feature-flag-form .success { margin: 0; font-weight: 600; }
.system-admin-tool .feature-flag-audit-list { list-style: none; padding: 0; }
.system-admin-tool .feature-flag-audit-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: .15rem 1rem; color: var(--text); padding-bottom: .5rem; border-bottom: 1px solid var(--line); }
.system-admin-tool .feature-flag-audit-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.system-admin-tool .feature-flag-audit-when { flex-basis: 100%; }
.system-admin-tool .feature-flag-audit-change { min-width: 6.5em; font-weight: 700; font-variant-numeric: tabular-nums; }
.system-admin-tool mark { background: color-mix(in srgb, var(--gold) 45%, transparent); color: inherit; border-radius: 2px; padding: 0 1px; }
@container (max-width: 640px) {
  .system-admin-tool .feature-flag-filter-component { flex: 1 1 100%; }
  .system-admin-tool .feature-flag-filter-actions { margin-left: 0; width: 100%; justify-content: space-between; }
  .system-admin-tool .feature-flag-compact-value { display: flex; }
}
.system-admin-tool .feature-flag-detail-link { white-space: nowrap; }
.system-admin-tool .feature-flag-editor-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.system-admin-tool .feature-flag-editor-heading h2 { margin: 0; }
.system-admin-tool .feature-flag-status-row.is-expanded td:first-child { box-shadow: inset 4px 0 0 var(--blue); }
