:root {
    color-scheme: dark;
    --bg: #06090d;
    --bg-soft: #0c1218;
    --panel: #11161d;
    --panel-soft: #151b23;
    --panel-alt: #0f141a;
    --body-bg: #080b10;
    --shell-panel: rgba(16, 21, 28, 0.92);
    --sidebar-bg: #080c11;
    --surface-soft: rgba(255, 255, 255, 0.04);
    --surface-faint: rgba(255, 255, 255, 0.03);
    --field-bg: #080d12;
    --field-border: rgba(255, 255, 255, 0.14);
    --line: rgba(255, 255, 255, 0.08);
    --line-strong: rgba(255, 255, 255, 0.14);
    --text: #edf1f5;
    --muted: #8e9aa7;
    --green: #7bd938;
    --green-soft: rgba(123, 217, 56, 0.15);
    --blue: #36a3ff;
    --blue-soft: rgba(54, 163, 255, 0.16);
    --orange: #d89a39;
    --orange-soft: rgba(216, 154, 57, 0.16);
    --red: #bb5555;
    --red-soft: rgba(187, 85, 85, 0.16);
    --green-ink: #dff9c7;
    --blue-ink: #bfe5ff;
    --orange-ink: #f0d6af;
    --red-ink: #efc6c6;
    --slate-soft: rgba(255, 255, 255, 0.08);
    --slate-ink: #d0d8de;
    --control-ink: #d7dfe6;
    --accent-contrast: #08110d;
    --shadow: 0 28px 80px rgba(0, 0, 0, 0.36);
}

:root[data-theme="light"] {
    color-scheme: light;
    --bg: #eef3f7;
    --bg-soft: #f7fafc;
    --panel: #ffffff;
    --panel-soft: #f4f7fa;
    --panel-alt: #edf2f7;
    --body-bg: #eef3f7;
    --shell-panel: rgba(255, 255, 255, 0.94);
    --sidebar-bg: #f8fafc;
    --surface-soft: rgba(20, 35, 50, 0.05);
    --surface-faint: rgba(20, 35, 50, 0.035);
    --field-bg: #ffffff;
    --field-border: rgba(20, 35, 50, 0.18);
    --line: rgba(20, 35, 50, 0.12);
    --line-strong: rgba(20, 35, 50, 0.2);
    --text: #142230;
    --muted: #5f6c78;
    --green: #25884d;
    --green-soft: rgba(37, 136, 77, 0.14);
    --blue: #126bb3;
    --blue-soft: rgba(18, 107, 179, 0.13);
    --orange: #a66a17;
    --orange-soft: rgba(166, 106, 23, 0.14);
    --red: #a43d3d;
    --red-soft: rgba(164, 61, 61, 0.14);
    --green-ink: #176537;
    --blue-ink: #0d4e85;
    --orange-ink: #7c4a0b;
    --red-ink: #7d2929;
    --slate-soft: rgba(42, 58, 74, 0.08);
    --slate-ink: #3c4b58;
    --control-ink: #354452;
    --accent-contrast: #04150d;
    --shadow: 0 18px 42px rgba(32, 52, 72, 0.12);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    font-family: Inter, Arial, sans-serif;
    background: var(--body-bg);
    color: var(--text);
    line-height: 1.45;
    overflow-x: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

.ops-bg,
.ops-grid,
.ops-glow {
    position: fixed;
    inset: 0;
    pointer-events: none;
}

.ops-bg {
    background: var(--body-bg);
    z-index: 0;
}

.ops-grid {
    z-index: 0;
    opacity: 0.18;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.65), transparent 85%);
}

.ops-glow {
    filter: blur(72px);
    opacity: 0.6;
}

.ops-glow-one {
    width: 24rem;
    height: 24rem;
    border-radius: 50%;
    background: rgba(54, 163, 255, 0.1);
    top: -12rem;
    left: -10rem;
}

.ops-glow-two {
    width: 24rem;
    height: 24rem;
    border-radius: 50%;
    background: rgba(123, 217, 56, 0.08);
    right: -10rem;
    bottom: -12rem;
}

.app-layout {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 248px minmax(0, 1fr);
    min-height: 100vh;
}

.app-sidebar {
    position: sticky;
    top: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    height: 100vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 0.9rem 0.85rem;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--line);
    backdrop-filter: blur(18px);
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding-bottom: 0.85rem;
    border-bottom: 1px solid var(--line);
}

.sidebar-brand-text {
    min-width: 0;
}

.sidebar-mark {
    width: 2rem;
    height: 2rem;
    border-radius: 10px;
    display: grid;
    place-items: center;
    color: #07110c;
    font-weight: 800;
    background: linear-gradient(135deg, var(--green), #5ef0a3);
}

.sidebar-brand h1,
.page-section h2,
.page-section h3,
.panel-card h3 {
    margin: 0;
}

.sidebar-brand h1 {
    font-size: 1rem;
    line-height: 1.15;
    font-weight: 700;
}

.sidebar-brand-kicker,
.panel-kicker,
.sidebar-label,
.page-kicker {
    margin: 0 0 0.25rem;
    color: var(--muted);
    font-size: 0.73rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.sidebar-group {
    display: grid;
    gap: 0.25rem;
}

.sidebar-collapse-toggle {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    width: 100%;
    padding: 0.48rem 0.65rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--surface-soft);
    color: var(--control-ink);
    font: inherit;
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
}

.sidebar-collapse-toggle:hover,
.sidebar-collapse-toggle:focus-visible {
    border-color: var(--line-strong);
    background: var(--panel-soft);
}

.sidebar-collapse-icon {
    width: 1.45rem;
    height: 1.45rem;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 4px;
    background: var(--field-bg);
    color: var(--green-ink);
    font-size: 1.15rem;
    line-height: 1;
}

.sidebar-collapse-label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-link,
.sidebar-utility {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.55rem;
    min-height: 38px;
    padding: 0.64rem 0.85rem;
    border-radius: 10px;
    color: var(--control-ink);
    font-size: 0.9rem;
    border: 1px solid transparent;
}

.sidebar-link-main {
    display: flex;
    align-items: center;
    min-width: 0;
    gap: 0.55rem;
}

.sidebar-link-icon {
    width: 1.45rem;
    height: 1.45rem;
    display: inline-grid;
    place-items: center;
    flex: 0 0 auto;
    border-radius: 4px;
    color: var(--green-ink);
    background: var(--field-bg);
    font-size: 0.9rem;
    font-weight: 900;
    line-height: 1;
}

.sidebar-link-label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sidebar-link:hover,
.sidebar-utility:hover,
.sidebar-link:focus-visible,
.sidebar-utility:focus-visible {
    background: var(--surface-soft);
}

.sidebar-link.is-active {
    background: rgba(123, 217, 56, 0.16);
    border-color: rgba(123, 217, 56, 0.28);
    color: var(--green-ink);
    box-shadow: inset 4px 0 0 var(--green);
}

.sidebar-link.is-active .sidebar-link-icon {
    color: #07110c;
    background: linear-gradient(135deg, var(--green), #5ef0a3);
}

.sidebar-link:focus-visible,
.sidebar-utility:focus-visible,
.sidebar-collapse-toggle:focus-visible,
.menu-toggle-compact:focus-visible {
    outline: 3px solid rgba(92, 245, 159, 0.6);
    outline-offset: 2px;
}

.sidebar-link.nav-alert-red {
    border-color: rgba(255, 75, 55, 0.72);
    background: rgba(165, 28, 19, 0.42);
    color: #ffeae6;
    animation: opsNavRedFlash 0.85s ease-in-out infinite;
}

.sidebar-link.nav-alert-yellow {
    border-color: rgba(255, 208, 74, 0.78);
    background: rgba(178, 126, 17, 0.36);
    color: #fff7d2;
    animation: opsNavYellowFlash 1s ease-in-out infinite;
}

.sidebar-link.nav-alert-orange {
    border-color: rgba(255, 143, 55, 0.78);
    background: rgba(173, 75, 15, 0.38);
    color: #fff0dc;
    animation: opsNavOrangeFlash 0.95s ease-in-out infinite;
}

.sidebar-link.nav-alert-brand {
    border-color: rgba(92, 245, 159, 0.76);
    background: rgba(17, 138, 115, 0.34);
    color: #eafff5;
    animation: opsNavBrandFlash 0.9s ease-in-out infinite;
}

.sidebar-link.nav-alert-dismissed {
    animation: none !important;
}

.sidebar-link.nav-alert-dismissed:not(.is-active) {
    border-color: rgba(255, 255, 255, 0.08);
    background: transparent;
    color: var(--muted);
}

.nav-alert-badge {
    min-width: 1.45rem;
    height: 1.45rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border-radius: 999px;
    padding: 0 0.35rem;
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
}

.nav-alert-badge[hidden] {
    display: none !important;
}

.nav-alert-badge-red {
    background: #ff4b37;
    color: #270502;
}

.nav-alert-badge-yellow {
    background: #ffd04a;
    color: #241801;
}

.nav-alert-badge-orange {
    background: #ff8f37;
    color: #260e01;
}

.nav-alert-badge-brand {
    background: linear-gradient(135deg, #5cf59f, #2aa8ff);
    color: #02110c;
}

.retry-outbound-list {
    gap: 0.7rem;
}

.retry-outbound-row {
    border-left: 5px solid #ff4b37;
}

.retry-action-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.inline-retry-form {
    margin: 0;
}

.retry-button {
    border-color: rgba(255, 75, 55, 0.55);
    background: rgba(255, 75, 55, 0.15);
    color: #ffd9d3;
}

.retry-button:hover {
    background: rgba(255, 75, 55, 0.28);
}

.incident-archive-form {
    margin: 0.75rem 0 0;
}

.delete-failed-button {
    border-color: rgba(255, 210, 97, 0.6);
    background: rgba(255, 210, 97, 0.12);
    color: #ffe7a8;
}

.delete-failed-button:hover {
    background: rgba(255, 210, 97, 0.24);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.sidebar-footer {
    margin-top: auto;
    display: grid;
    gap: 0.4rem;
    padding-top: 0.8rem;
    border-top: 1px solid var(--line);
}

.nav-tooltip {
    position: fixed;
    z-index: 1000;
    max-width: min(260px, calc(100vw - 1rem));
    padding: 0.45rem 0.6rem;
    border: 1px solid var(--line-strong);
    border-radius: 4px;
    background: var(--shell-panel);
    color: var(--text);
    box-shadow: var(--shadow);
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1.25;
    pointer-events: none;
    opacity: 0;
    transform: translateY(-50%) translateX(-0.2rem);
    transition: opacity 120ms ease, transform 120ms ease;
}

.nav-tooltip.is-visible {
    opacity: 1;
    transform: translateY(-50%) translateX(0);
}

.app-frame {
    min-width: 0;
    padding: 0.75rem 0.9rem 0.9rem;
}

.frame-toggle-row {
    display: none;
    margin-bottom: 0.75rem;
}

.topbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.9rem;
    padding: 0.8rem 0.95rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--shell-panel);
    box-shadow: var(--shadow);
}

.topbar-actions,
.topbar-stats,
.profile-chip,
.message-stack,
.activity-row,
.panel-header,
.queue-overview-stats,
.inbox-toolbar,
.snippet-cell,
.time-cell,
.assignment-row,
.line-row,
.line-health,
.profile-stack,
.detail-columns,
.tag-row,
.rail-footer,
.section-heading,
.quick-link-grid,
.metric-grid,
.action-row,
.toolbar,
.portal-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
}

.topbar-stats {
    gap: 1.1rem;
    justify-content: center;
}

.topbar-actions {
    justify-content: flex-end;
}

.topbar-stat {
    display: grid;
    gap: 0.1rem;
}

.topbar-stat span,
.profile-chip span,
.panel-link,
.metric-panel span,
.breakdown-row span,
.line-row span,
.detail-columns span,
.rail-footer span,
.snippet-cell em {
    color: var(--muted);
    font-size: 0.76rem;
}

.topbar-stat strong,
.profile-chip strong {
    font-size: 0.9rem;
}

.topbar-search {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.7rem 0.85rem;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: var(--field-bg);
    color: var(--muted);
}

.topbar-search::before {
    content: "⌕";
    color: var(--muted);
    font-size: 0.95rem;
}

.topbar-search span {
    display: none;
}

.topbar-search input {
    width: 210px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text);
}

.profile-chip {
    padding: 0.45rem 0.65rem;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--field-bg);
}

.sidebar-profile-chip {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: nowrap;
    gap: 0.6rem;
    padding: 0.55rem 0.65rem;
    border-radius: 4px;
}

.sidebar-profile-chip .profile-avatar {
    flex: 0 0 auto;
}

.sidebar-profile-text {
    min-width: 0;
    display: grid;
    gap: 0.05rem;
}

.sidebar-profile-text strong,
.sidebar-profile-text span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-avatar,
.profile-avatar.large {
    display: grid;
    place-items: center;
    border-radius: 50%;
    font-weight: 700;
}

.profile-avatar {
    width: 2rem;
    height: 2rem;
    background: var(--panel-alt);
    font-size: 0.9rem;
}

.profile-avatar.large {
    width: 2.5rem;
    height: 2.5rem;
    background: rgba(123, 217, 56, 0.22);
    color: #dff9c7;
}

.menu-button,
.ghost-button,
.primary-button,
.danger-button,
.send-button,
.tab-chip,
.sidebar-utility,
.portal-nav-link,
.theme-toggle,
.status-chip,
.count-pill {
    border-radius: 10px;
    border: 1px solid transparent;
}

.theme-toggle {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.45rem 0.65rem;
    border: 1px solid var(--line);
    background: var(--surface-soft);
    color: var(--control-ink);
    font-size: 0.76rem;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
    border-color: var(--line-strong);
    background: var(--panel-soft);
}

.menu-button,
.primary-button,
.send-button {
    padding: 0.62rem 0.95rem;
    background: linear-gradient(180deg, #3bb0ff, #2690ec);
    color: #081016;
    font-weight: 700;
}

.menu-toggle-compact {
    width: 44px;
    height: 44px;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-soft);
}

.menu-toggle-compact span {
    width: 18px;
    height: 2px;
    margin: 0 auto;
    border-radius: 999px;
    background: var(--control-ink);
}

.ghost-button,
.sidebar-utility,
.portal-nav-link,
.topbar-link,
.mini-button {
    padding: 0.62rem 0.9rem;
    background: var(--surface-soft);
    border-color: var(--line);
    color: var(--control-ink);
}

.topbar-link,
.mini-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.topbar-link.is-active {
    background: rgba(123, 217, 56, 0.14);
    border-color: rgba(123, 217, 56, 0.28);
    color: var(--green-ink);
}

.danger-button {
    padding: 0.65rem 1rem;
    background: var(--red-soft);
    border-color: var(--red);
    color: var(--red-ink);
}

.app-content,
.page-shell,
.ops-main-grid,
.queue-overview-list,
.activity-list,
.assignment-list,
.lines-list,
.breakdown-list,
.thread-list,
.conversation,
.detail-grid {
    display: grid;
    gap: 1rem;
}

.app-content {
    padding-top: 0.9rem;
}

.message-banner {
    padding: 0.7rem 0.9rem;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: rgba(123, 217, 56, 0.12);
    font-size: 0.88rem;
}

.message-banner.error {
    background: rgba(187, 85, 85, 0.12);
}

.message-banner.warning {
    background: rgba(216, 154, 57, 0.12);
}

.message-banner.info {
    background: rgba(54, 163, 255, 0.12);
}

.shell-wrap {
    position: relative;
    z-index: 1;
    width: min(1080px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 1rem 0 4rem;
}

.shell-header,
.page-section,
.panel-card {
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--shell-panel);
    box-shadow: var(--shadow);
}

.shell-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem 1rem;
}

.brand-lockup {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.brand-badge {
    width: 2.35rem;
    height: 2.35rem;
    border-radius: 12px;
    display: grid;
    place-items: center;
    color: #08110d;
    font-weight: 800;
    background: linear-gradient(135deg, var(--green), #5df0a3);
}

.brand-title {
    font-size: 1.35rem;
}

.page-shell,
.page-section,
.panel-card {
    padding: 0.9rem;
}

.page-section,
.page-section > *,
.app-content > * {
    min-width: 0;
    max-width: 100%;
}

.dashboard-split,
.inline-actions,
.list-topline,
.list-meta,
.metric-card,
.form-field-checkbox {
    display: grid;
}

.dashboard-split {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    align-items: start;
}

.inline-actions {
    grid-auto-flow: column;
    gap: 0.65rem;
    justify-content: end;
}

.metric-card {
    gap: 0.25rem;
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--surface-faint);
}

.metric-label,
.meta-pill {
    color: var(--muted);
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.metric-value {
    margin: 0;
    font-size: 1.7rem;
    font-weight: 700;
}

.metric-value-compact {
    font-size: 1.08rem;
    line-height: 1.35;
}

.metric-helper {
    color: var(--muted);
    font-size: 0.84rem;
}

.meta-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.45rem 0.7rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-soft);
}

.list-topline {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 0.55rem;
}

.list-meta {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 0.45rem 0.75rem;
    margin-top: 0.35rem;
    color: var(--muted);
    font-size: 0.84rem;
}

.link-strong {
    font-weight: 700;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    padding: 0.28rem 0.55rem;
    border-radius: 999px;
    font-size: 0.72rem;
    background: var(--slate-soft);
    color: var(--slate-ink);
}

.status-pill.green { background: var(--green-soft); color: var(--green-ink); }
.status-pill.blue { background: var(--blue-soft); color: var(--blue-ink); }
.status-pill.orange { background: var(--orange-soft); color: var(--orange-ink); }
.status-pill.red { background: var(--red-soft); color: var(--red-ink); }
.status-pill.slate { background: var(--slate-soft); color: var(--slate-ink); }

.form-field-checkbox {
    align-content: start;
}

.form-field-checkbox label {
    order: 1;
}

.form-field-checkbox input[type="checkbox"] {
    order: 2;
    width: 18px;
    height: 18px;
    accent-color: var(--green);
}

.form-field-checkbox small,
.form-field-checkbox .field-error {
    order: 3;
}

.page-section h2,
.page-section h3,
.panel-card h3 {
    font-size: 1rem;
}

.page-copy,
.muted,
.list-subtext,
.activity-copy p,
.note-box p,
.thread-preview,
.schedule-note {
    margin: 0;
    color: var(--muted);
}

.metric-grid {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.metric-grid-wide {
    margin-bottom: 1rem;
}

.ops-page-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 304px;
    gap: 0.9rem;
    align-items: start;
}

.ops-main-grid {
    grid-template-columns: repeat(12, minmax(0, 1fr));
}

.live-activity-card {
    grid-column: span 4;
}

.queue-overview-card {
    grid-column: span 4;
}

.launch-desk-card,
.hiring-desk-card,
.franchise-desk-card,
.subscriber-desk-card {
    grid-column: span 4;
}

.metric-cluster {
    grid-column: span 4;
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.metric-panel {
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--panel);
}

.metric-panel strong {
    display: block;
    font-size: 1.75rem;
    margin: 0.25rem 0;
}

.message-inbox-card {
    grid-column: span 7;
}

.assignment-card {
    grid-column: span 5;
}

.lines-card {
    grid-column: span 4;
}

.volume-card {
    grid-column: span 4;
}

.breakdown-card,
.sla-card {
    grid-column: span 2;
}

.activity-row,
.assignment-row,
.line-row,
.breakdown-row,
.thread-item,
.list-row {
    align-items: flex-start;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--line);
}

.activity-row:first-child,
.assignment-row:first-child,
.line-row:first-child,
.breakdown-row:first-child,
.thread-item:first-child,
.list-row:first-child {
    padding-top: 0;
}

.activity-row:last-child,
.assignment-row:last-child,
.line-row:last-child,
.breakdown-row:last-child,
.thread-item:last-child,
.list-row:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.activity-row {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    gap: 0.65rem;
}

.activity-copy {
    min-width: 0;
    overflow: hidden;
}

.email-check-all-form {
    margin-top: 0.75rem;
}

.email-page-actions,
.email-inbox-actions {
    align-items: center;
    gap: 0.5rem;
}

.email-inbox-actions {
    display: flex;
    flex-wrap: wrap;
    margin-top: 0.8rem;
}

.email-action-context,
.email-action-target {
    display: none;
}

.email-inbox-row {
    scroll-margin-top: 1rem;
}

.email-status-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 0.65rem;
    margin-top: 0.75rem;
    padding: 0.72rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-faint);
}

.email-status-strip span,
.email-status-strip small {
    display: block;
    color: var(--muted);
    font-size: 0.76rem;
}

.email-status-strip strong {
    display: block;
    margin-top: 0.18rem;
    color: var(--text);
    font-size: 0.84rem;
    overflow-wrap: anywhere;
}

.email-config-panel summary {
    display: inline-flex;
    width: max-content;
    max-width: 100%;
    cursor: pointer;
    list-style: none;
}

.email-config-panel summary::-webkit-details-marker {
    display: none;
}

.email-config-body {
    margin-top: 1rem;
}

.disabled-button,
.disabled-button:hover,
.disabled-button:focus-visible {
    cursor: not-allowed;
    opacity: 0.62;
    border-color: var(--line);
    color: var(--muted);
    background: transparent;
}

.email-monitor-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.65rem;
    margin-top: 0.7rem;
    padding: 0.72rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-faint);
}

.email-monitor-summary span,
.email-monitor-summary small {
    display: block;
    color: var(--muted);
    font-size: 0.76rem;
}

.email-monitor-summary strong {
    display: block;
    margin-top: 0.18rem;
    color: var(--text);
    font-size: 0.84rem;
    overflow-wrap: anywhere;
}

.email-message-list {
    display: grid;
    gap: 0.45rem;
}

.email-message-row {
    display: grid;
    grid-template-columns: minmax(150px, 0.7fr) minmax(180px, 1.3fr) minmax(150px, auto) minmax(150px, 0.8fr) auto;
    gap: 0.65rem;
    align-items: center;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-faint);
}

.email-message-row:hover,
.email-message-row:focus-visible {
    border-color: rgba(54, 163, 255, 0.38);
    background: var(--surface-soft);
}

.email-message-row.is-unread {
    border-color: rgba(216, 154, 57, 0.34);
}

.email-message-row.is-flagged {
    box-shadow: inset 3px 0 0 rgba(216, 154, 57, 0.72);
}

.email-filter-tabs,
.email-compose-tabs {
    margin: 0.85rem 0 1rem;
}

.email-filter-tabs a.is-active,
.email-compose-tabs a.is-active {
    border-color: rgba(54, 163, 255, 0.48);
    background: var(--surface-soft);
    color: var(--text);
}

.email-row-statuses {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    justify-content: flex-end;
    min-width: 0;
}

.email-message-from,
.email-message-subject,
.email-message-date {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.email-conversation-row .email-row-statuses {
    grid-column: 1 / -1;
    justify-content: flex-start;
}

.email-conversation-preview {
    min-width: 0;
    color: var(--muted);
    font-size: 0.82rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.email-conversation-timeline {
    display: grid;
    gap: 0.55rem;
}

.email-conversation-message {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-faint);
}

.email-conversation-message.is-current {
    border-color: rgba(54, 163, 255, 0.48);
    background: var(--surface-soft);
}

.email-conversation-message > summary {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.55rem 0.8rem;
    padding: 0.8rem 0.9rem;
    cursor: pointer;
    list-style: none;
}

.email-conversation-message > summary::-webkit-details-marker {
    display: none;
}

.email-conversation-message > summary::before {
    content: '›';
    color: var(--muted);
    font-size: 1.15rem;
    line-height: 1;
}

.email-conversation-message[open] > summary::before {
    content: '⌄';
}

.email-conversation-message-sender {
    color: var(--text);
    font-weight: 700;
}

.email-conversation-message-subject,
.email-conversation-recipients {
    color: var(--muted);
    overflow-wrap: anywhere;
}

.email-conversation-message-content {
    padding: 0.2rem 1rem 1rem 2rem;
}

.email-conversation-recipients {
    margin: 0 0 0.65rem;
    font-size: 0.82rem;
}

.email-message-subject {
    color: var(--text);
    font-weight: 700;
}

.email-message-date {
    color: var(--muted);
    font-size: 0.82rem;
}

.email-message-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.65rem;
    margin-bottom: 0.8rem;
}

.email-message-meta span {
    display: block;
    color: var(--muted);
    font-size: 0.76rem;
}

.email-message-meta strong {
    display: block;
    overflow-wrap: anywhere;
}

.email-message-body {
    margin: 0;
    width: 100%;
    max-height: 62vh;
    overflow: auto;
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--field-bg);
    color: var(--text);
    font: inherit;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.email-message-html {
    width: 100%;
    max-height: 62vh;
    overflow: auto;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--field-bg);
    color: var(--text);
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.email-message-html a {
    color: var(--blue);
    overflow-wrap: anywhere;
}

.email-message-html table {
    max-width: 100%;
    border-collapse: collapse;
}

.email-message-html td,
.email-message-html th {
    vertical-align: top;
    padding: 0.25rem;
}

.email-message-plain {
    margin-top: 0.75rem;
}

.email-message-plain summary {
    display: inline-flex;
    cursor: pointer;
    list-style: none;
}

.email-workspace-grid {
    align-items: start;
}

.email-message-reader {
    min-width: 0;
}

.email-compose-panel {
    min-width: 0;
}

.email-compose-panel .email-compose-form {
    max-width: 980px;
}

.email-compose-form .form-grid-stacked {
    grid-template-columns: 1fr;
}

.email-compose-form .email-body-field {
    width: 100%;
    min-height: 260px;
    resize: vertical;
}

.email-compose-form input[type="file"] {
    width: 100%;
    max-width: 100%;
}

.email-control-row {
    align-items: center;
}

@media (max-width: 760px) {
    .email-message-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .email-conversation-row .email-row-statuses {
        grid-column: auto;
    }

    .email-message-from,
    .email-message-subject,
    .email-message-date {
        white-space: normal;
    }

    .email-row-statuses {
        justify-content: flex-start;
    }

    .email-inbox-actions,
    .email-page-actions {
        align-items: stretch;
    }

    .email-inbox-actions {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        padding: 0.72rem;
        border: 1px solid var(--line);
        border-radius: 6px;
        background: var(--surface-faint);
    }

    .email-action-context {
        display: grid;
        gap: 0.12rem;
        padding-bottom: 0.2rem;
        color: var(--muted);
        font-size: 0.76rem;
    }

    .email-action-context strong {
        color: var(--text);
        font-size: 0.92rem;
        overflow-wrap: anywhere;
    }

    .email-action-context small,
    .email-action-target {
        color: var(--muted);
        font-size: 0.74rem;
        line-height: 1.25;
        overflow-wrap: anywhere;
    }

    .email-action-target {
        display: block;
        margin-top: 0.14rem;
        font-weight: 600;
    }

    .email-inbox-actions > *,
    .email-page-actions > * {
        width: 100%;
    }

    .email-inbox-actions .primary-button,
    .email-inbox-actions .ghost-button,
    .email-inbox-actions button {
        justify-content: flex-start;
        text-align: left;
        white-space: normal;
    }
}

.activity-icon {
    width: 18px;
    height: 18px;
    margin-top: 0.15rem;
    border-radius: 50%;
    background: var(--line-strong);
}

.activity-icon.green { background: var(--green); }
.activity-icon.blue { background: var(--blue); }
.activity-icon.orange { background: var(--orange); }
.activity-icon.slate { background: #637282; }

.activity-copy strong,
.assignment-row strong,
.breakdown-row strong,
.profile-stack strong {
    display: block;
}

.activity-copy strong,
.activity-copy p,
.activity-copy span {
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.activity-copy p {
    display: -webkit-box;
    margin-bottom: 0.25rem;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.activity-copy span,
.activity-row time {
    color: var(--muted);
    font-size: 0.82rem;
}

.activity-row time {
    white-space: nowrap;
}

.queue-overview-row {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--line);
}

.queue-overview-row:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.queue-overview-stats {
    justify-content: space-between;
    gap: 1rem;
    margin-top: 0.45rem;
}

.queue-overview-stats b,
.topbar-stat strong,
.panel-card strong,
.breakdown-row strong {
    color: var(--text);
}

.panel-header {
    justify-content: space-between;
    margin-bottom: 0.7rem;
}

.panel-link {
    white-space: nowrap;
}

.gateway-incident-card {
    border-color: rgba(187, 85, 85, 0.62);
    background: linear-gradient(180deg, rgba(187, 85, 85, 0.18), var(--shell-panel));
}

.gateway-incident-card .panel-kicker {
    color: #efc6c6;
}

.gateway-incident-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.55rem;
    margin-bottom: 0.75rem;
}

.gateway-incident-summary span {
    display: block;
    min-width: 0;
    padding: 0.58rem 0.7rem;
    border: 1px solid rgba(187, 85, 85, 0.32);
    border-radius: 4px;
    background: rgba(187, 85, 85, 0.12);
    color: #efc6c6;
    overflow-wrap: anywhere;
}

.gateway-incident-card .list-subtext,
.gateway-incident-card .list-meta,
.gateway-incident-card .list-meta span {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

:root[data-theme="light"] .gateway-incident-card,
:root[data-theme="light"] .gateway-incident-card h1,
:root[data-theme="light"] .gateway-incident-card h2,
:root[data-theme="light"] .gateway-incident-card h3,
:root[data-theme="light"] .gateway-incident-card p,
:root[data-theme="light"] .gateway-incident-card span,
:root[data-theme="light"] .gateway-incident-card strong,
:root[data-theme="light"] .gateway-incident-card a,
:root[data-theme="light"] .gateway-incident-card .panel-kicker,
:root[data-theme="light"] .gateway-incident-card .list-subtext,
:root[data-theme="light"] .gateway-incident-card .list-meta,
:root[data-theme="light"] .gateway-incident-card .list-meta span {
    color: #03120a !important;
}

:root[data-theme="light"] .gateway-incident-summary span {
    border-color: rgba(3, 18, 10, 0.18);
    background: rgba(255, 255, 255, 0.72);
}

.tab-chip {
    padding: 0.35rem 0.65rem;
    background: var(--surface-soft);
    color: var(--muted);
}

.tab-chip.is-active {
    background: rgba(123, 217, 56, 0.12);
    color: var(--green-ink);
}

.table-shell {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--panel-alt);
}

.ops-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.ops-table thead th {
    padding: 0.72rem 0.7rem;
    text-align: left;
    color: var(--muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border-bottom: 1px solid var(--line);
}

.ops-table tbody td {
    padding: 0.78rem 0.7rem;
    border-bottom: 1px solid var(--line);
    vertical-align: top;
}

.ops-table tbody tr:last-child td {
    border-bottom: 0;
}

.ops-table td strong,
.ops-table td span {
    display: block;
}

.status-chip,
.count-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.28rem 0.5rem;
    font-size: 0.72rem;
}

.status-chip.green { background: var(--green-soft); color: var(--green-ink); }
.status-chip.blue { background: var(--blue-soft); color: var(--blue-ink); }
.status-chip.orange { background: var(--orange-soft); color: var(--orange-ink); }
.status-chip.red { background: var(--red-soft); color: var(--red-ink); }
.status-chip.slate { background: var(--slate-soft); color: var(--slate-ink); }

.count-pill {
    min-width: 22px;
    background: rgba(123, 217, 56, 0.16);
    color: #dff9c7;
}

.assignment-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 0.75rem;
}

.line-row {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(160px, 1fr) auto;
    gap: 0.8rem;
}

.line-copy span {
    color: var(--muted);
    display: block;
    font-size: 0.82rem;
}

.progress-track {
    height: 6px;
    flex: 1;
    border-radius: 999px;
    background: var(--slate-soft);
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    border-radius: inherit;
    background: var(--green);
}

.progress-fill.blue { background: var(--blue); }

.volume-chart {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.75rem;
    align-items: end;
    min-height: 170px;
}

.volume-day {
    display: grid;
    gap: 0.5rem;
    justify-items: center;
}

.volume-bars {
    display: flex;
    align-items: flex-end;
    gap: 0.35rem;
    height: 130px;
}

.volume-bar {
    width: 14px;
    border-radius: 8px 8px 0 0;
    background: var(--line);
}

.volume-bar.inbound { background: var(--green); }
.volume-bar.outbound { background: var(--blue); }

.breakdown-row {
    display: grid;
    grid-template-columns: 1fr minmax(120px, 1fr) auto;
    gap: 0.75rem;
}

.breakdown-label {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}

.breakdown-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.breakdown-bar {
    align-self: center;
    height: 7px;
    border-radius: 999px;
    background: var(--slate-soft);
    overflow: hidden;
}

.breakdown-fill {
    height: 100%;
    border-radius: inherit;
    background: var(--green);
}

.breakdown-fill.accent {
    background: linear-gradient(90deg, var(--green), #5ef0a3);
}

.ops-detail-rail {
    position: sticky;
    top: 1rem;
    max-height: calc(100vh - 2rem);
    overflow: auto;
}

.profile-stack {
    justify-content: space-between;
    margin-bottom: 1rem;
}

.detail-columns {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--line);
}

.detail-columns strong {
    display: block;
    margin-top: 0.25rem;
}

.tag-row {
    margin: 1rem 0;
}

.note-box,
.reply-box,
.thread-item,
.table-shell,
.metric-panel,
.breakdown-card,
.sla-card,
.lines-card,
.volume-card,
.message-inbox-card,
.assignment-card,
.ops-detail-rail,
.queue-overview-card,
.launch-desk-card,
.hiring-desk-card,
.franchise-desk-card,
.subscriber-desk-card,
.live-activity-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.015), rgba(255, 255, 255, 0.01));
}

.note-box {
    padding: 0.9rem;
    border-radius: 4px;
    border: 1px solid var(--line);
}

.conversation-stack {
    display: grid;
    gap: 0.75rem;
    margin: 1rem 0;
}

.chat-bubble {
    padding: 0.9rem;
    border-radius: 14px;
    max-width: 92%;
    min-width: 0;
    overflow: hidden;
}

.chat-bubble.inbound {
    background: rgba(123, 217, 56, 0.12);
    margin-left: auto;
}

.chat-bubble.outbound {
    background: var(--surface-soft);
}

.chat-bubble p {
    margin: 0 0 0.4rem;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.snippet-cell,
.snippet-cell span {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.chat-bubble span {
    color: var(--muted);
    font-size: 0.78rem;
}

.reply-box {
    display: grid;
    gap: 0.8rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
}

.reply-box textarea,
.form-field input,
.form-field select,
.form-field textarea,
.topbar-search input {
    color: var(--text);
}

.reply-box textarea,
.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    padding: 0.8rem 0.9rem;
    border-radius: 12px;
    border: 1px solid var(--field-border);
    background: var(--field-bg);
    outline: 0;
}

.password-input-wrap {
    position: relative;
    width: 100%;
}

.form-field .password-input-wrap input {
    padding-right: 3.2rem;
}

.password-eye-button {
    position: absolute;
    top: 50%;
    right: 0.42rem;
    width: 2.2rem;
    height: 2.2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--control-ink);
    transform: translateY(-50%);
}

.password-eye-button:hover,
.password-eye-button:focus-visible {
    background: var(--surface-soft);
    color: var(--text);
}

.password-eye-icon {
    width: 1.18rem;
    height: 1.18rem;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.password-eye-off,
.password-eye-button.is-visible .password-eye-on {
    display: none;
}

.password-eye-button.is-visible .password-eye-off {
    display: block;
}

.send-button {
    justify-self: end;
}

.rail-footer {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
}

.rail-footer strong {
    display: block;
    margin-top: 0.2rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.9rem;
}

.form-grid label {
    min-width: 0;
    max-width: 100%;
}

.form-grid-stacked {
    grid-template-columns: 1fr;
}

.form-field {
    display: grid;
    gap: 0.4rem;
}

.form-field-full {
    grid-column: 1 / -1;
}

.form-field label {
    font-size: 0.86rem;
    color: var(--muted);
}

.choice-stack ul {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.choice-stack label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: var(--text);
}

.choice-stack input[type="radio"] {
    width: auto;
    margin: 0;
}

.compact-heading {
    margin-top: 1.6rem;
}

.field-error {
    margin: 0;
    color: #f0c9c9;
    font-size: 0.8rem;
}

.comms-workspace,
.website-workspace {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr) 300px;
    gap: 1rem;
    align-items: start;
}

.website-workspace {
    grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
    width: 100%;
    max-width: 100%;
}

.workspace-main,
.workspace-rail {
    min-width: 0;
    max-width: 100%;
}

.website-workspace .thread-item,
.website-workspace .detail-card,
.website-workspace .list-card {
    min-width: 0;
    overflow-wrap: anywhere;
}

.website-workspace .workspace-main {
    overflow-x: hidden;
    overflow-y: visible;
}

.thread-list {
    gap: 0.85rem;
}

.thread-item {
    display: grid;
    gap: 0.45rem;
    padding: 0.95rem;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: var(--panel-soft);
}

.thread-item.is-selected {
    border-color: rgba(123, 217, 56, 0.3);
    box-shadow: inset 0 0 0 1px rgba(123, 217, 56, 0.12);
}

.detail-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.detail-card {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--panel-soft);
}

.quick-link-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.quick-link-grid a {
    padding: 0.85rem 0.95rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-faint);
}

.website-control-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    justify-content: flex-end;
    max-width: min(760px, 100%);
}

.published-review-summary {
    margin-bottom: 1rem;
}

.published-review-studio {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
    gap: 1rem;
    align-items: start;
    margin-bottom: 1rem;
}

.published-review-preview,
.published-review-remarks-panel {
    min-width: 0;
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-faint);
}

.published-review-preview {
    display: grid;
    gap: 0.85rem;
}

.published-review-remarks-panel {
    position: sticky;
    top: 1rem;
    display: grid;
    gap: 1rem;
}

.published-review-frame-shell {
    overflow: hidden;
    width: 100%;
    min-height: 620px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #050806;
}

.published-review-frame-shell iframe {
    display: block;
    width: 100%;
    height: min(720px, calc(100vh - 180px));
    min-height: 620px;
    border: 0;
    background: #fff;
}

.published-review-list {
    display: grid;
    gap: 0;
}

.published-review-row {
    display: grid;
    gap: 0.65rem;
}

.published-review-row.is-active-review {
    margin-inline: -0.35rem;
    padding-inline: 0.35rem;
    border-radius: 6px;
    background: rgba(54, 163, 255, 0.08);
}

.published-review-title {
    display: grid;
    gap: 0.22rem;
    min-width: 0;
}

.published-review-title span,
.published-review-url {
    overflow-wrap: anywhere;
}

.published-review-title span {
    color: var(--muted);
    font-size: 0.84rem;
}

.published-review-url {
    margin: 0;
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-faint);
    font-size: 0.86rem;
}

.published-review-note-list {
    max-height: 420px;
    overflow: auto;
}

.zip-dropzone {
    display: grid;
    gap: 0.75rem;
    padding: 1rem;
    border: 2px dashed rgba(92, 245, 159, 0.34);
    border-radius: 8px;
    background: rgba(92, 245, 159, 0.055);
    outline: none;
    transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.zip-deposit-box {
    min-height: 9rem;
    align-content: center;
    border-color: var(--line);
    background: rgba(3, 10, 18, 0.72);
}

.zip-dropzone:focus-visible,
.zip-dropzone.is-dragover,
.zip-dropzone.drop-active {
    border-color: rgba(92, 245, 159, 0.78);
    background: rgba(92, 245, 159, 0.12);
    box-shadow: 0 0 0 3px rgba(92, 245, 159, 0.14);
}

.zip-dropzone.is-invalid {
    border-color: rgba(255, 99, 99, 0.78);
    background: rgba(187, 85, 85, 0.12);
}

.zip-dropzone-label {
    display: grid;
    gap: 0.5rem;
    cursor: pointer;
}

.zip-dropzone-title {
    color: var(--text);
    font-size: 1rem;
    font-weight: 800;
}

.zip-dropzone-copy,
.zip-dropzone-file-list {
    color: var(--muted);
    font-size: 0.86rem;
    line-height: 1.45;
}

.zip-dropzone-button {
    width: fit-content;
    margin-top: 0.2rem;
}

.app-form textarea.zip-dropzone-field {
    min-height: 10rem;
    background: var(--field-bg);
    border: 2px dashed var(--field-border);
    padding: 1rem;
    font: inherit;
    line-height: 1.5;
}

.zip-dropzone-field::placeholder {
    color: var(--muted);
    opacity: 1;
}

.zip-dropzone.drop-active .zip-dropzone-field,
.app-form textarea.zip-dropzone-field:focus-visible {
    border-color: var(--green);
    box-shadow: 0 0 0 3px var(--green-soft);
    outline: none;
}

.zip-publish-feedback:not([hidden]) {
    display: grid;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.zip-dropzone-input[hidden] {
    display: none;
}

.zip-dropzone-input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.zip-dropzone-file-list {
    padding: 0.65rem 0.75rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-faint);
}

.zip-dropzone-file-list ul {
    display: grid;
    gap: 0.25rem;
    margin: 0;
    padding-left: 1.1rem;
}

.zip-dropzone-file-list strong {
    color: var(--text);
}

@media (max-width: 980px) {
    .published-review-studio {
        grid-template-columns: 1fr;
    }

    .published-review-remarks-panel {
        position: static;
    }

    .published-review-frame-shell,
    .published-review-frame-shell iframe {
        min-height: 460px;
    }
}

.time-action-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    margin-bottom: 1rem;
}

.action-form {
    display: block;
}

.action-tile {
    width: 100%;
    justify-content: center;
}

.action-tile-danger {
    background: rgba(187, 85, 85, 0.16);
    border-color: rgba(187, 85, 85, 0.3);
    color: #f0c9c9;
}

.primary-button:disabled,
.ghost-button:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.detail-list {
    margin: 0;
    display: grid;
    gap: 0.7rem;
}

.detail-list div {
    padding-bottom: 0.7rem;
    border-bottom: 1px solid var(--line);
}

.detail-list div:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.detail-list dt {
    color: var(--muted);
    font-size: 0.74rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.22rem;
}

.detail-list dd {
    margin: 0;
}

.list-card {
    display: grid;
}

.field-help,
.credential-note {
    color: var(--muted);
    font-size: 0.78rem;
    line-height: 1.45;
}

.form-errors {
    display: grid;
    gap: 0.4rem;
    margin-bottom: 0.85rem;
    padding: 0.8rem 0.9rem;
    border: 1px solid rgba(187, 85, 85, 0.28);
    border-radius: 4px;
    background: rgba(187, 85, 85, 0.12);
}

.form-errors p {
    margin: 0;
    color: #f0c9c9;
    font-size: 0.82rem;
}

.credential-split {
    align-items: stretch;
}

.credential-panel,
.credential-card,
.credential-empty-state {
    display: grid;
    gap: 1rem;
}

.credential-panel-header,
.credential-card-header,
.credential-section-head {
    display: grid;
    gap: 0.35rem;
}

.credential-panel-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 0.75rem;
}

.credential-form {
    display: grid;
    gap: 1rem;
}

.credential-section {
    display: grid;
    gap: 0.8rem;
    padding: 0.95rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--surface-faint);
}

.credential-section-head h3,
.credential-card h3 {
    margin: 0;
    font-size: 0.95rem;
}

.credential-section-head p,
.credential-card-header p {
    margin: 0;
    color: var(--muted);
    font-size: 0.82rem;
}

.credential-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.9rem;
}

.credential-form-grid .form-field-full {
    grid-column: 1 / -1;
}

.credential-form-grid .form-field,
.credential-form-shell .form-field {
    align-content: start;
}

.credential-form-grid .form-field input,
.credential-form-grid .form-field select,
.credential-form-grid .form-field textarea,
.credential-form-shell .form-field input,
.credential-form-shell .form-field select,
.credential-form-shell .form-field textarea {
    min-height: 46px;
    border-radius: 4px;
}

.credential-form-grid .form-field textarea,
.credential-form-shell .form-field textarea {
    min-height: 120px;
}

.credential-form-grid .form-field-checkbox,
.credential-form-shell .form-field-checkbox {
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 0.4rem 0.75rem;
    align-items: center;
}

.credential-form-grid .form-field-checkbox label,
.credential-form-shell .form-field-checkbox label {
    order: 2;
    margin: 0;
}

.credential-form-grid .form-field-checkbox input[type="checkbox"],
.credential-form-shell .form-field-checkbox input[type="checkbox"] {
    order: 1;
    margin: 0;
}

.credential-form-grid .form-field-checkbox small,
.credential-form-grid .form-field-checkbox .field-error,
.credential-form-shell .form-field-checkbox small,
.credential-form-shell .form-field-checkbox .field-error {
    grid-column: 1 / -1;
    order: 3;
}

.credential-card-grid,
.credential-bundles {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
}

.credential-form-shell {
    display: grid;
    gap: 0.85rem;
    min-width: 0;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--surface-faint);
}

.credential-card,
.credential-card-header,
.credential-card-header > div,
.credential-card .list-topline,
.credential-card .list-meta,
.credential-card .form-grid,
.credential-card .form-field,
.credential-card .password-input-wrap {
    min-width: 0;
    max-width: 100%;
}

.credential-card .link-strong,
.credential-card .list-meta span,
.credential-card .form-field label,
.credential-card .field-error,
.credential-card small {
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.credential-card .list-meta {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 140px), 1fr));
}

.credential-card .credential-form-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}

.credential-card .form-field input,
.credential-card .form-field select,
.credential-card .form-field textarea {
    max-width: 100%;
}

.credential-spacer {
    min-height: 1px;
}

.portal-nav-link.is-active {
    background: rgba(123, 217, 56, 0.16);
    border-color: rgba(123, 217, 56, 0.28);
}

.map-shell {
    position: relative;
    overflow: hidden;
    min-height: 360px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: var(--panel-alt);
}

.map-shell iframe {
    width: 100%;
    height: 360px;
    border: 0;
    filter: grayscale(0.12) brightness(0.9);
}

.map-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(6, 9, 13, 0.1), rgba(6, 9, 13, 0.32));
}

.map-pin {
    position: absolute;
    transform: translate(-50%, -100%);
}

.map-pin-label {
    padding: 0.35rem 0.55rem;
    border-radius: 999px;
    background: var(--shell-panel);
    border: 1px solid rgba(123, 217, 56, 0.25);
    font-size: 0.76rem;
    white-space: nowrap;
}

.map-pin-dot {
    width: 0.9rem;
    height: 0.9rem;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 6px rgba(123, 217, 56, 0.12);
}

.job-tracker-hero,
.job-tracker-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.job-tracker-actions,
.job-tracker-map-tools,
.job-tracker-row-actions,
.job-tracker-filter-actions,
.job-tracker-popup-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.55rem;
}

.job-tracker-summary {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr));
    margin-bottom: 1rem;
}

.job-tracker-stat {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-faint);
}

.job-tracker-stat span,
.job-tracker-filter-card label span,
.job-tracker-map-tools span {
    display: block;
    color: var(--muted);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0;
}

.job-tracker-stat strong {
    display: block;
    margin-top: 0.25rem;
    font-size: clamp(1.45rem, 4vw, 2.1rem);
    line-height: 1;
}

.job-tracker-filters {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: minmax(220px, 2fr) repeat(3, minmax(150px, 1fr)) auto;
    align-items: end;
}

.job-tracker-filters label {
    display: grid;
    gap: 0.35rem;
    min-width: 0;
}

.job-tracker-filters input,
.job-tracker-filters select {
    width: 100%;
    min-width: 0;
}

.job-tracker-workspace {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.85fr);
    align-items: start;
}

.job-tracker-map-panel,
.job-tracker-list-panel {
    min-width: 0;
}

.ops-job-tracker-map {
    width: 100%;
    min-height: min(62vh, 560px);
    height: 520px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--panel-alt);
}

.ops-job-tracker-map .leaflet-popup-content-wrapper,
.ops-job-tracker-map .leaflet-popup-tip {
    background: var(--shell-panel);
    color: var(--text);
    border: 1px solid var(--line);
}

.tracker-div-marker {
    background: transparent;
    border: 0;
}

.tracker-marker-pin {
    position: relative;
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50% 50% 50% 12%;
    background: var(--tracker-marker-color, #2f80ed);
    color: var(--tracker-marker-label-color, #ffffff);
    border: 2px solid rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.32);
    transform: rotate(-45deg);
}

.tracker-marker-pin span {
    display: block;
    color: var(--tracker-marker-label-color, #ffffff);
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1;
    transform: rotate(45deg);
}

.job-tracker-map-empty {
    margin-top: 0.75rem;
    color: var(--muted);
}

.job-tracker-list {
    display: grid;
    gap: 0.75rem;
    max-height: 580px;
    overflow: auto;
    padding-right: 0.25rem;
}

.job-tracker-row {
    display: grid;
    gap: 0.55rem;
    padding: 0.85rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-faint);
    cursor: pointer;
}

.job-tracker-row.is-focused {
    border-color: rgba(42, 168, 255, 0.65);
    box-shadow: 0 0 0 3px rgba(42, 168, 255, 0.14);
}

.job-tracker-row-meta {
    grid-template-columns: 1fr;
}

.job-tracker-row-actions a,
.job-tracker-popup-actions a {
    color: var(--blue);
    font-weight: 700;
    text-decoration: none;
}

.job-tracker-row-actions form,
.job-tracker-popup-actions form {
    margin: 0;
}

.link-button {
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--blue);
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.link-button:hover,
.job-tracker-row-actions a:hover {
    text-decoration: underline;
}

.job-tracker-popup {
    display: grid;
    gap: 0.35rem;
    min-width: 220px;
}

.job-tracker-popup p {
    margin: 0;
}

.job-tracker-map-tools .ghost-button.is-active {
    border-color: rgba(42, 168, 255, 0.65);
    background: rgba(42, 168, 255, 0.14);
}

.job-tracker-fix-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    align-items: start;
}

.job-tracker-pin-form {
    display: grid;
    gap: 0.8rem;
}

.job-tracker-pin-form label,
.job-tracker-coordinate-grid label {
    display: grid;
    gap: 0.35rem;
}

.job-tracker-pin-form label span,
.job-tracker-coordinate-grid label span {
    color: var(--muted);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0;
}

.job-tracker-pin-form input {
    width: 100%;
}

.job-tracker-copy-field {
    display: grid;
    gap: 0.35rem;
    margin: 1rem 0;
}

.job-tracker-copy-field span {
    color: var(--muted);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0;
}

.job-tracker-copy-field input {
    width: 100%;
}

.job-tracker-coordinate-grid {
    display: grid;
    gap: 0.8rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.job-tracker-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.job-tracker-fix-map {
    height: 560px;
}

.job-location-confirm-card {
    max-width: 980px;
    margin-inline: auto;
}

.job-location-context {
    margin: 1rem 0;
}

.job-location-confirm-form {
    display: grid;
    gap: 0.9rem;
}

.job-location-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
}

.job-location-confirm-map {
    height: clamp(440px, 58vh, 680px);
}

.job-tracker-history-grid {
    display: grid;
    gap: 1rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
}

.job-tracker-timeline {
    display: grid;
    gap: 0.75rem;
    margin: 0;
    padding-left: 1.1rem;
}

.job-tracker-timeline li {
    padding: 0.7rem 0;
    border-bottom: 1px solid var(--line);
}

.job-tracker-timeline strong,
.job-tracker-timeline span {
    display: block;
}

.job-tracker-timeline span {
    color: var(--muted);
    font-size: 0.86rem;
}

@media (max-width: 1180px) {
    .job-tracker-workspace,
    .job-tracker-filters,
    .job-tracker-fix-grid,
    .job-tracker-history-grid {
        grid-template-columns: 1fr;
    }

    .job-tracker-filter-actions {
        justify-content: flex-start;
    }
}

@media (max-width: 720px) {
    .job-tracker-hero,
    .job-tracker-panel-head {
        display: grid;
    }

    .ops-job-tracker-map {
        height: 430px;
        min-height: 430px;
    }
}

.schedule-strip {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
}

.day-chip,
.schedule-day {
    padding: 0.85rem;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: var(--surface-faint);
}

.day-chip {
    min-height: 0;
}

.state-toggle {
    width: 100%;
    padding: 0.62rem 0.75rem;
    border: 0;
    border-radius: 10px;
    font-weight: 700;
    color: #08110d;
}

.state-toggle[data-state="off"] { background: #c26a6a; }
.state-toggle[data-state="on"] { background: #7bd938; }
.state-toggle[data-state="on_call"] { background: #36a3ff; }

.schedule-board {
    display: grid;
    gap: 0.55rem;
    min-width: 0;
    max-width: 100%;
    width: 100%;
    overflow-x: visible;
    padding-bottom: 0.3rem;
}

.schedule-row {
    min-width: 0;
    width: 100%;
    display: grid;
    grid-template-columns: minmax(150px, 0.24fr) minmax(0, 1fr);
    align-items: stretch;
    gap: 0.45rem;
    padding: 0.45rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.schedule-row > .list-topline {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-content: center;
    gap: 0.35rem;
    min-width: 0;
    padding: 0 0.2rem;
}

.schedule-row > .list-topline h3,
.schedule-row > .list-topline p {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.schedule-row > .list-topline .mini-button {
    width: fit-content;
    padding: 0.35rem 0.5rem;
    font-size: 0.72rem;
}

.schedule-days {
    display: grid;
    grid-template-columns: repeat(14, minmax(0, 1fr));
    gap: 0.32rem;
}

.schedule-days .schedule-day {
    min-width: 0;
    display: grid;
    align-content: start;
    gap: 0.22rem;
    min-height: 0;
    padding: 0.38rem;
    border-radius: 7px;
}

.schedule-days .schedule-day h4 {
    margin: 0;
    overflow: hidden;
    color: var(--muted);
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.1;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.schedule-days .state-toggle {
    min-height: 1.7rem;
    padding: 0.28rem 0.32rem;
    border-radius: 999px;
    font-size: 0.7rem;
    line-height: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.schedule-days .schedule-note {
    overflow: hidden;
    font-size: 0.62rem;
    line-height: 1.15;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hidden-input {
    display: none;
}

@media (max-width: 1320px) {
    .ops-page-grid {
        grid-template-columns: 1fr;
    }

    .ops-detail-rail {
        position: static;
    }

    .comms-workspace,
    .website-workspace {
        grid-template-columns: 1fr;
    }

    .dashboard-split {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 761px) and (max-width: 1180px) {
    .frame-toggle-row {
        display: none;
    }

    .app-layout,
    .app-layout.sidebar-collapsed {
        grid-template-columns: 78px minmax(0, 1fr);
    }

    .app-layout:not(.sidebar-collapsed) {
        grid-template-columns: minmax(220px, 248px) minmax(0, 1fr);
    }

    .app-sidebar {
        position: sticky;
        top: 0;
        bottom: auto;
        width: auto;
        transform: none;
        transition: none;
        z-index: 1;
    }

    .app-layout.sidebar-open::after {
        content: none;
        display: none;
    }

    .app-layout.sidebar-open .app-sidebar {
        transform: none;
        box-shadow: none;
    }

    .app-layout.sidebar-collapsed .app-sidebar {
        overflow-x: hidden;
        overflow-y: auto;
        padding-inline: 0.6rem;
    }

    .app-layout.sidebar-collapsed .sidebar-brand {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .sidebar-brand-text,
    .app-layout.sidebar-collapsed .sidebar-label,
    .app-layout.sidebar-collapsed .sidebar-link-label,
    .app-layout.sidebar-collapsed .sidebar-collapse-label {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    .app-layout.sidebar-collapsed .sidebar-collapse-toggle,
    .app-layout.sidebar-collapsed .sidebar-link,
    .app-layout.sidebar-collapsed .sidebar-utility {
        justify-content: center;
        padding-inline: 0.45rem;
    }

    .app-layout.sidebar-collapsed .sidebar-link-main {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .nav-alert-badge {
        position: absolute;
        top: 0.1rem;
        right: 0.1rem;
        min-width: 1rem;
        height: 1rem;
        padding: 0 0.22rem;
        font-size: 0.62rem;
    }
}

@media (max-width: 760px) {
    .credential-panel-header,
    .credential-form-grid,
    .credential-card-grid,
    .credential-bundles {
        grid-template-columns: 1fr;
    }

    .credential-spacer {
        display: none;
    }
}

@media (min-width: 1181px) {
    .app-layout.sidebar-collapsed {
        grid-template-columns: 78px minmax(0, 1fr);
    }

    .app-layout.sidebar-collapsed .app-sidebar {
        overflow-x: hidden;
        overflow-y: auto;
        padding-inline: 0.6rem;
    }

    .app-layout.sidebar-collapsed .sidebar-brand {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .sidebar-brand-text,
    .app-layout.sidebar-collapsed .sidebar-label,
    .app-layout.sidebar-collapsed .sidebar-link-label,
    .app-layout.sidebar-collapsed .sidebar-collapse-label {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    .app-layout.sidebar-collapsed .sidebar-collapse-toggle,
    .app-layout.sidebar-collapsed .sidebar-link,
    .app-layout.sidebar-collapsed .sidebar-utility {
        justify-content: center;
        padding-inline: 0.45rem;
    }

    .app-layout.sidebar-collapsed .sidebar-link-main {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .nav-alert-badge {
        position: absolute;
        top: 0.1rem;
        right: 0.1rem;
        min-width: 1rem;
        height: 1rem;
        padding: 0 0.22rem;
        font-size: 0.62rem;
    }
}

@media (min-width: 761px) and (max-width: 1180px) {
    .frame-toggle-row {
        display: none;
    }

    .app-layout,
    .app-layout.sidebar-collapsed {
        grid-template-columns: 78px minmax(0, 1fr);
    }

    .app-layout:not(.sidebar-collapsed) {
        grid-template-columns: minmax(220px, 248px) minmax(0, 1fr);
    }

    .app-sidebar {
        position: sticky;
        top: 0;
        bottom: auto;
        width: auto;
        transform: none;
        transition: none;
        z-index: 1;
    }

    .app-layout.sidebar-open .app-sidebar {
        transform: none;
    }

    .app-layout.sidebar-collapsed .app-sidebar {
        overflow-x: hidden;
        overflow-y: auto;
        padding-inline: 0.6rem;
    }

    .app-layout.sidebar-collapsed .sidebar-brand {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .sidebar-brand-text,
    .app-layout.sidebar-collapsed .sidebar-label,
    .app-layout.sidebar-collapsed .sidebar-link-label,
    .app-layout.sidebar-collapsed .sidebar-collapse-label {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    .app-layout.sidebar-collapsed .sidebar-collapse-toggle,
    .app-layout.sidebar-collapsed .sidebar-link,
    .app-layout.sidebar-collapsed .sidebar-utility {
        justify-content: center;
        padding-inline: 0.45rem;
    }

    .app-layout.sidebar-collapsed .sidebar-link-main {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .nav-alert-badge {
        position: absolute;
        top: 0.1rem;
        right: 0.1rem;
        min-width: 1rem;
        height: 1rem;
        padding: 0 0.22rem;
        font-size: 0.62rem;
    }
}

@media (max-width: 1180px) {
    .frame-toggle-row {
        display: flex;
        justify-content: flex-start;
    }

    .topbar {
        grid-template-columns: 1fr;
    }

    .topbar-stats {
        justify-content: flex-start;
    }

    .app-layout {
        grid-template-columns: 1fr;
    }

    .app-layout.sidebar-collapsed {
        grid-template-columns: 1fr;
    }

    .app-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        width: 270px;
        transform: translateX(-100%);
        transition: transform 180ms ease;
        z-index: 30;
        overflow-y: auto;
    }

    .app-layout.sidebar-open::after {
        content: "";
        position: fixed;
        inset: 0;
        z-index: 20;
        background: rgba(0, 0, 0, 0.38);
    }

    .app-layout.sidebar-open .app-sidebar {
        transform: translateX(0);
        box-shadow: 18px 0 50px rgba(0, 0, 0, 0.32);
    }

    .app-frame {
        padding-left: 0.85rem;
    }

    .live-activity-card,
    .queue-overview-card,
    .launch-desk-card,
    .hiring-desk-card,
    .franchise-desk-card,
    .subscriber-desk-card,
    .metric-cluster,
    .message-inbox-card,
    .assignment-card,
    .lines-card,
    .volume-card,
    .breakdown-card,
    .sla-card {
        grid-column: span 12;
    }
}

@media (min-width: 761px) and (max-width: 1180px) {
    .frame-toggle-row {
        display: none;
    }

    .app-layout,
    .app-layout.sidebar-collapsed {
        grid-template-columns: 78px minmax(0, 1fr);
    }

    .app-layout:not(.sidebar-collapsed) {
        grid-template-columns: minmax(220px, 248px) minmax(0, 1fr);
    }

    .app-sidebar {
        position: sticky;
        top: 0;
        bottom: auto;
        width: auto;
        transform: none;
        transition: none;
        z-index: 1;
    }

    .app-layout.sidebar-open::after {
        content: none;
        display: none;
    }

    .app-layout.sidebar-open .app-sidebar {
        transform: none;
        box-shadow: none;
    }

    .app-frame {
        padding-left: 0.65rem;
    }

    .app-layout.sidebar-collapsed .app-sidebar {
        overflow-x: hidden;
        overflow-y: auto;
        padding-inline: 0.6rem;
    }

    .app-layout.sidebar-collapsed .sidebar-brand {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .sidebar-brand-text,
    .app-layout.sidebar-collapsed .sidebar-label,
    .app-layout.sidebar-collapsed .sidebar-link-label,
    .app-layout.sidebar-collapsed .sidebar-collapse-label {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    .app-layout.sidebar-collapsed .sidebar-collapse-toggle,
    .app-layout.sidebar-collapsed .sidebar-link,
    .app-layout.sidebar-collapsed .sidebar-utility {
        justify-content: center;
        padding-inline: 0.45rem;
    }

    .app-layout.sidebar-collapsed .sidebar-link-main {
        justify-content: center;
    }

    .app-layout.sidebar-collapsed .nav-alert-badge {
        position: absolute;
        top: 0.1rem;
        right: 0.1rem;
        min-width: 1rem;
        height: 1rem;
        padding: 0 0.22rem;
        font-size: 0.62rem;
    }
}

@media (max-width: 760px) {
    .app-frame,
    .shell-wrap {
        padding-inline: 0.75rem;
    }

    .volume-chart {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .rail-footer,
    .detail-columns,
    .metric-cluster {
        grid-template-columns: 1fr;
    }

    .ops-table {
        font-size: 0.84rem;
    }

    .topbar-search input {
        width: 100%;
    }
}

/* Emergency professionalization pass: tighten the inherited Ops UI without changing routes or data. */
.ops-grid,
.ops-glow {
    display: none;
}

.ops-bg {
    background: var(--body-bg);
}

.app-sidebar {
    background: var(--sidebar-bg);
    border-right-color: var(--line);
}

.sidebar-brand {
    gap: 0.65rem;
}

.sidebar-mark,
.brand-badge {
    border-radius: 4px;
    background: #5ad88b;
}

.sidebar-link,
.sidebar-utility,
.portal-nav-link,
.ghost-button,
.primary-button,
.danger-button,
.mini-button,
.theme-toggle,
.status-pill,
.status-chip,
.count-pill {
    border-radius: 4px;
}

.sidebar-link,
.sidebar-utility {
    padding: 0.52rem 0.68rem;
    font-size: 0.84rem;
    line-height: 1.2;
}

.topbar,
.shell-header,
.page-section,
.panel-card,
.metric-card,
.metric-panel,
.credential-section,
.table-shell,
.day-chip,
.schedule-day,
.schedule-row {
    border-color: var(--line);
    background: var(--shell-panel);
    box-shadow: var(--shadow);
}

.topbar {
    padding: 0.65rem 0.8rem;
}

.app-frame {
    padding: 0.65rem;
}

.app-content,
.page-shell,
.ops-main-grid {
    gap: 0.75rem;
}

.page-section,
.panel-card {
    padding: 0.75rem;
}

.section-heading {
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
}

.page-section h2,
.page-section h3,
.panel-card h3 {
    font-size: 0.96rem;
    line-height: 1.25;
}

.page-copy,
.muted,
.list-subtext,
.schedule-note,
.metric-helper,
.field-help,
.credential-note {
    font-size: 0.8rem;
    line-height: 1.35;
}

.metric-grid {
    gap: 0.55rem;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.metric-card,
.metric-panel {
    gap: 0.18rem;
    min-height: 0;
    padding: 0.62rem 0.7rem;
}

.metric-value {
    font-size: 1.34rem;
    line-height: 1.15;
}

.quick-link-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 0.5rem;
}

.quick-link-grid a,
.primary-button,
.ghost-button,
.danger-button,
.mini-button,
.send-button,
.menu-button {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.72rem;
    line-height: 1.2;
}

.primary-button,
.send-button,
.menu-button {
    background: #39a7f4;
    color: #071017;
}

.form-grid,
.credential-form-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.62rem 0.7rem;
    align-items: start;
}

.credential-form-grid {
    grid-template-columns: repeat(2, minmax(240px, 1fr));
}

.form-field {
    gap: 0.26rem;
    align-content: start;
    min-width: 0;
}

.form-field label {
    min-height: 1.05rem;
    overflow: hidden;
    color: var(--muted);
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.1;
    text-overflow: ellipsis;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.reply-box textarea,
.form-field input,
.form-field select,
.form-field textarea,
.topbar-search input,
.credential-form-grid .form-field input,
.credential-form-grid .form-field select,
.credential-form-grid .form-field textarea,
.credential-form-shell .form-field input,
.credential-form-shell .form-field select,
.credential-form-shell .form-field textarea {
    min-height: 40px;
    padding: 0.54rem 0.65rem;
    border-radius: 4px;
    background: var(--field-bg);
    border-color: var(--field-border);
    line-height: 1.25;
}

.form-field textarea,
.credential-form-grid .form-field textarea,
.credential-form-shell .form-field textarea {
    min-height: 92px;
    resize: vertical;
}

.password-eye-button {
    right: 0.25rem;
    width: 2rem;
    height: 2rem;
    border-radius: 4px;
}

.form-field .password-input-wrap input {
    padding-right: 2.65rem;
}

.form-field-checkbox,
.credential-form-grid .form-field-checkbox,
.credential-form-shell .form-field-checkbox {
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 0.25rem 0.55rem;
    min-height: 40px;
    align-items: center;
}

.form-field-checkbox label,
.credential-form-grid .form-field-checkbox label,
.credential-form-shell .form-field-checkbox label {
    min-height: 0;
    order: 2;
    white-space: normal;
}

.form-field-checkbox input[type="checkbox"],
.credential-form-grid .form-field-checkbox input[type="checkbox"],
.credential-form-shell .form-field-checkbox input[type="checkbox"] {
    order: 1;
    margin: 0;
}

.form-field-checkbox small,
.form-field-checkbox .field-error,
.credential-form-grid .form-field-checkbox small,
.credential-form-grid .form-field-checkbox .field-error,
.credential-form-shell .form-field-checkbox small,
.credential-form-shell .form-field-checkbox .field-error {
    grid-column: 1 / -1;
}

.list-card {
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--panel-alt);
}

.list-row {
    padding: 0.58rem 0.65rem;
}

.list-topline {
    align-items: center;
}

.list-meta {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.25rem 0.65rem;
    font-size: 0.76rem;
}

.status-pill,
.status-chip,
.count-pill {
    min-height: 22px;
    padding: 0.22rem 0.45rem;
    font-size: 0.68rem;
    font-weight: 700;
}

.table-shell {
    overflow-x: auto;
}

.ops-table {
    min-width: 780px;
    font-size: 0.82rem;
}

.ops-table thead th {
    padding: 0.52rem 0.56rem;
    white-space: nowrap;
}

.ops-table tbody td {
    padding: 0.56rem;
}

.toolbar {
    align-items: end;
}

.schedule-board {
    gap: 0.42rem;
}

.schedule-row {
    min-width: 0;
    width: 100%;
    grid-template-columns: minmax(132px, 0.22fr) minmax(0, 1fr);
    gap: 0.32rem;
    padding: 0.34rem;
}

.schedule-row > .list-topline {
    padding: 0 0.1rem;
}

.schedule-row > .list-topline h3 {
    font-size: 0.82rem;
}

.schedule-row > .list-topline .mini-button {
    min-height: 28px;
    padding: 0.24rem 0.42rem;
    font-size: 0.66rem;
}

.schedule-days {
    grid-template-columns: repeat(14, minmax(0, 1fr));
    gap: 0.24rem;
}

.schedule-days .schedule-day {
    gap: 0.18rem;
    padding: 0.28rem;
    border-radius: 4px;
}

.schedule-days .schedule-day h4 {
    font-size: 0.62rem;
}

.schedule-days .state-toggle {
    min-height: 1.32rem;
    padding: 0.18rem 0.26rem;
    border-radius: 4px;
    font-size: 0.62rem;
}

.schedule-days .schedule-note {
    font-size: 0.58rem;
}

.schedule-pulse-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.schedule-pulse-grid .metric-value {
    white-space: normal;
}

.schedule-alert-card .metric-value {
    color: var(--orange);
}

.schedule-metric-note {
    margin-top: 0.65rem;
}

.code-block {
    background: rgba(3, 10, 18, 0.72);
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--text);
    font: 0.86rem/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    max-width: 100%;
    overflow-x: auto;
    padding: 1rem;
    white-space: pre-wrap;
    word-break: break-word;
}

.archive-panel {
    border-top: 1px solid var(--line);
    display: grid;
    gap: 1rem;
    margin-top: 1rem;
    padding-top: 1rem;
}

.compact-filter-form {
    padding: 0.8rem;
}

.compact-list {
    gap: 0.55rem;
}

.proposal-row-actions,
.proposal-order-layout {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    align-items: flex-start;
}

.proposal-row-actions {
    margin-top: 0.8rem;
}

.inline-action-form {
    margin: 0;
}

.proposal-order-form {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    align-items: flex-end;
}

.proposal-build-type-label {
    display: grid;
    gap: 0.25rem;
    min-width: 11rem;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.proposal-build-type-label select {
    min-height: 2.45rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--panel);
    color: var(--text);
    font: inherit;
    padding: 0.55rem 0.65rem;
}

.proposal-url-deposit-form {
    margin-bottom: 1rem;
}

.proposal-url-deposit-box {
    min-height: 9rem;
    resize: vertical;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: rgba(3, 10, 18, 0.72);
    color: var(--text);
    font: 0.86rem/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    padding: 0.9rem;
}

.proposal-receipt-list {
    margin-top: 0.8rem;
}

.proposal-receipt-row {
    border-left: 4px solid rgba(92, 245, 159, 0.34);
}

.proposal-order-layout {
    align-items: stretch;
}

.proposal-order-layout > .list-card {
    flex: 1 1 360px;
    min-width: 0;
}

.proposal-order-document-label {
    display: grid;
    flex: 1 1 420px;
    gap: 0.45rem;
    min-width: min(100%, 360px);
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.proposal-order-document {
    min-height: 32rem;
    resize: vertical;
    width: 100%;
    max-width: 100%;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: rgba(3, 10, 18, 0.72);
    color: var(--text);
    font: 0.82rem/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    padding: 0.9rem;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.proposal-order-row {
    border-left: 4px solid rgba(42, 168, 255, 0.48);
}

.proposal-version-list {
    margin-top: 1rem;
}

.proposal-version-row {
    border-left: 4px solid rgba(92, 245, 159, 0.46);
}

.proposal-version-row .app-form {
    margin-top: 0.85rem;
}

.proposal-order-row,
.proposal-order-row .list-topline,
.proposal-order-row .list-subtext,
.proposal-order-row .list-meta,
.proposal-order-row .proposal-row-actions {
    min-width: 0;
    max-width: 100%;
}

.proposal-order-row .link-strong,
.proposal-order-row .list-subtext,
.proposal-order-row .list-meta span,
.list-card .list-meta span,
.proposal-order-row .status-pill {
    overflow-wrap: anywhere;
    white-space: normal;
}

.filter-form select,
.filter-form input,
.filter-form textarea,
.form-grid select,
.form-grid input,
.form-grid textarea {
    min-width: 0;
    max-width: 100%;
    width: 100%;
}

@media (max-width: 1024px) {
    .proposal-order-layout {
        flex-direction: column;
    }

    .proposal-order-layout > .list-card,
    .proposal-order-document-label {
        flex: 1 1 auto;
        width: 100%;
        min-width: 0;
    }
}

.schedule-command .section-heading {
    align-items: flex-start;
}

.schedule-subnav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin-top: 1rem;
}

.schedule-subnav .mini-button.is-active {
    background: var(--text);
    border-color: var(--text);
    color: var(--panel);
}

.schedule-quick-actions a {
    min-height: 3.25rem;
}

.schedule-home-hero {
    position: relative;
    overflow: visible;
}

.schedule-welcome-row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem;
}

.schedule-welcome-row h2 {
    font-size: clamp(1.35rem, 2.4vw, 2.15rem);
}

.schedule-create-wrap {
    position: relative;
    flex: 0 0 auto;
}

.schedule-create-menu {
    position: absolute;
    top: calc(100% + 0.45rem);
    right: 0;
    z-index: 4;
    min-width: 12rem;
    display: grid;
    gap: 0.25rem;
    padding: 0.45rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--panel);
    box-shadow: var(--shadow);
}

.schedule-create-menu[hidden],
.schedule-notification-window[hidden],
.schedule-notification-open[hidden] {
    display: none !important;
}

.schedule-create-menu a {
    padding: 0.55rem 0.65rem;
    border-radius: 4px;
    color: var(--text);
    text-decoration: none;
}

.schedule-create-menu a:hover,
.schedule-create-menu a:focus-visible {
    background: var(--surface-soft);
}

.schedule-pulse-strip {
    display: grid;
    grid-template-columns: minmax(180px, 1.2fr) repeat(3, minmax(120px, 0.8fr)) minmax(130px, 0.8fr);
    align-items: center;
    gap: 0.8rem;
    padding: 0.85rem;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: linear-gradient(135deg, rgba(3, 10, 18, 0.78), rgba(10, 24, 34, 0.9));
    box-shadow: var(--shadow);
}

.schedule-pulse-intro,
.schedule-pulse-metric {
    min-width: 0;
    display: grid;
    gap: 0.15rem;
}

.schedule-pulse-intro {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 0.6rem;
}

.schedule-pulse-mark {
    width: 0.9rem;
    height: 0.9rem;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 6px rgba(92, 245, 159, 0.12);
}

.schedule-pulse-strip small,
.schedule-pulse-strip span {
    color: var(--muted);
    font-size: 0.72rem;
    text-transform: uppercase;
}

.schedule-pulse-strip strong {
    overflow: hidden;
    font-size: 1.05rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.schedule-spark-bars {
    min-height: 4rem;
    display: flex;
    align-items: end;
    justify-content: flex-end;
    gap: 0.25rem;
}

.schedule-spark-bars i {
    width: 0.42rem;
    border-radius: 999px 999px 0 0;
    background: linear-gradient(180deg, var(--green), rgba(42, 168, 255, 0.55));
}

.schedule-home-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(260px, 0.75fr);
    gap: 0.75rem;
}

.schedule-workspace-panel,
.schedule-focus-panel {
    min-width: 0;
}

.schedule-workspace-search {
    min-width: min(100%, 18rem);
    display: flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.55rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--field-bg);
}

.schedule-workspace-search input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text);
}

.schedule-workspace-search kbd {
    min-width: 1.5rem;
    min-height: 1.45rem;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 4px;
    color: var(--muted);
    font: 0.72rem/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.schedule-tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 0.65rem;
}

.schedule-tool-card {
    position: relative;
    min-width: 0;
    min-height: 8.4rem;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.65rem;
    align-items: start;
    padding: 0.85rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--panel-soft);
    color: var(--text);
    text-decoration: none;
    transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
    animation: scheduleCardPulse 14s ease-in-out infinite;
}

.schedule-tool-card:nth-child(2) { animation-delay: 1.75s; }
.schedule-tool-card:nth-child(3) { animation-delay: 3.5s; }
.schedule-tool-card:nth-child(4) { animation-delay: 5.25s; }
.schedule-tool-card:nth-child(5) { animation-delay: 7s; }
.schedule-tool-card:nth-child(6) { animation-delay: 8.75s; }
.schedule-tool-card:nth-child(7) { animation-delay: 10.5s; }
.schedule-tool-card:nth-child(8) { animation-delay: 12.25s; }

.schedule-tool-card:hover,
.schedule-tool-card:focus-visible {
    transform: translateY(-2px);
    border-color: var(--line-strong);
    box-shadow: 0 0 0 1px rgba(92, 245, 159, 0.2), var(--shadow);
}

.schedule-tool-card.is-hidden {
    display: none;
}

.schedule-tool-icon {
    width: 2.2rem;
    height: 2.2rem;
    display: grid;
    place-items: center;
    border-radius: 8px;
    color: #07110c;
    font-weight: 800;
    font-size: 0.76rem;
}

.schedule-tool-icon.coral { background: #ff8a73; }
.schedule-tool-icon.violet { background: #b9a7ff; }
.schedule-tool-icon.blue { background: #65b8ff; }
.schedule-tool-icon.green { background: #7bd938; }
.schedule-tool-icon.amber { background: #f2c94c; }
.schedule-tool-icon.pink { background: #ff9ed0; }
.schedule-tool-icon.slate { background: #d4dee7; }

.schedule-tool-copy {
    min-width: 0;
    display: grid;
    gap: 0.2rem;
}

.schedule-tool-copy strong,
.schedule-tool-copy small,
.schedule-tool-meta {
    overflow: hidden;
    text-overflow: ellipsis;
}

.schedule-tool-copy small,
.schedule-tool-meta {
    color: var(--muted);
    font-size: 0.76rem;
    line-height: 1.3;
}

.schedule-card-arrow {
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
}

.schedule-tool-meta {
    grid-column: 1 / -1;
    align-self: end;
}

.schedule-tool-empty {
    margin-top: 0.8rem;
}

.schedule-focus-list {
    display: grid;
    gap: 0.65rem;
}

.schedule-focus-list a {
    display: grid;
    grid-template-columns: 3.4rem minmax(0, 1fr);
    gap: 0.65rem;
    padding: 0.7rem;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--panel-soft);
    color: var(--text);
    text-decoration: none;
}

.schedule-focus-list small {
    display: block;
    margin-top: 0.18rem;
    color: var(--muted);
    line-height: 1.3;
}

.schedule-focus-time {
    color: var(--green-ink);
    font-weight: 800;
    text-transform: uppercase;
}

.schedule-tip-card {
    margin-top: 0.8rem;
    padding: 0.75rem;
    border: 1px solid rgba(42, 168, 255, 0.28);
    border-radius: 6px;
    background: rgba(42, 168, 255, 0.08);
}

.schedule-tip-card p {
    margin: 0.3rem 0 0;
    color: var(--muted);
}

.schedule-notification-window,
.schedule-notification-open {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 20;
}

.schedule-notification-window {
    width: min(22rem, calc(100vw - 2rem));
    padding: 0.85rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
    box-shadow: var(--shadow);
}

.schedule-notification-window p:last-child {
    margin-bottom: 0;
    color: var(--muted);
}

.schedule-notification-close,
.schedule-notification-open {
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--surface-soft);
    color: var(--text);
    cursor: pointer;
}

.schedule-notification-close {
    float: right;
    width: 1.8rem;
    height: 1.8rem;
}

.schedule-notification-open {
    padding: 0.55rem 0.7rem;
}

.schedule-exact-form {
    margin-top: 0.85rem;
}

.schedule-save-status {
    display: block;
    min-height: 1rem;
    margin-top: 0.35rem;
    color: var(--muted);
    font-size: 0.72rem;
    line-height: 1.2;
}

.schedule-save-status.is-error {
    color: var(--red);
}

.schedule-save-status.is-ok {
    color: var(--green);
}

.schedule-day-blocked {
    border-color: rgba(220, 53, 69, 0.45);
}

.schedule-note-alert {
    color: var(--red);
    font-weight: 700;
}

.compact-row-form {
    width: 100%;
}

.time-context-form {
    margin: 0.8rem 0 1rem;
}

.schedule-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 0.65rem;
    overflow-x: visible;
}

.schedule-calendar-day {
    display: flex;
    min-width: 0;
    min-height: 8rem;
    flex-direction: column;
    gap: 0.4rem;
    padding: 0.75rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
    color: var(--text);
    text-decoration: none;
}

.schedule-calendar-day:hover {
    border-color: var(--blue);
}

.calendar-day-label {
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.calendar-event-chip {
    display: block;
    padding: 0.28rem 0.35rem;
    border-radius: 6px;
    background: var(--panel);
    color: var(--text);
    font-size: 0.78rem;
    font-weight: 700;
}

.calendar-empty {
    color: var(--muted);
    font-size: 0.78rem;
}

.report-section {
    break-inside: avoid;
}

.table-scroll {
    min-width: 0;
    max-width: 100%;
    width: 100%;
    overflow-x: auto;
}

@media (max-width: 760px) {
    .quick-link-grid,
    .form-grid,
    .credential-form-grid,
    .proposal-order-layout,
    .schedule-calendar-grid {
        grid-template-columns: 1fr;
    }

    .proposal-order-document-label {
        min-width: 0;
    }

    .proposal-order-layout {
        flex-direction: column;
    }

    .app-frame,
    .shell-wrap {
        padding-inline: 0.5rem;
    }

    .page-shell,
    .page-section,
    .app-content,
    .metric-grid {
        max-width: 100%;
        min-width: 0;
    }

    .app-content > *,
    .page-section > * {
        min-width: 0;
    }

    .schedule-command {
        overflow: hidden;
    }

    .schedule-command .section-heading {
        display: grid;
        gap: 0.75rem;
    }

    .schedule-command .inline-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }

    .schedule-subnav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
    }

    .schedule-subnav .mini-button,
    .schedule-command .inline-actions .mini-button {
        justify-content: center;
        min-width: 0;
        width: 100%;
        white-space: normal;
        text-align: center;
    }

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

    .schedule-board {
        overflow-x: visible;
        overscroll-behavior-x: contain;
    }

    .schedule-welcome-row,
    .schedule-home-grid,
    .schedule-pulse-strip {
        display: grid;
        grid-template-columns: 1fr;
    }

    .schedule-create-wrap,
    .schedule-create-wrap .primary-button,
    .schedule-workspace-search {
        width: 100%;
    }

    .schedule-create-menu {
        left: 0;
        right: auto;
        width: 100%;
    }

    .schedule-tool-grid {
        grid-template-columns: 1fr;
    }

    .schedule-tool-card {
        min-height: 0;
    }

    .schedule-spark-bars {
        justify-content: flex-start;
    }

    .schedule-row {
        grid-template-columns: 1fr;
    }

    .schedule-row > .list-topline {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 0.4rem;
    }

    .schedule-days {
        grid-template-columns: repeat(auto-fit, minmax(68px, 1fr));
    }

    .schedule-row > .list-topline h3,
    .schedule-row > .list-topline p,
    .schedule-days .schedule-day h4,
    .schedule-days .schedule-note {
        white-space: normal;
    }

    .schedule-command .page-copy,
    .schedule-metric-note {
        overflow-wrap: anywhere;
    }
}

@media (min-width: 761px) {
    .app-layout.sidebar-collapsed .sidebar-profile-chip {
        justify-content: center;
        padding-inline: 0.45rem;
    }

    .app-layout.sidebar-collapsed .sidebar-profile-text {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }
}

@media (min-width: 761px) and (max-width: 1180px) {
    .schedule-row {
        grid-template-columns: 1fr;
    }

    .schedule-row > .list-topline {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 0.45rem;
    }

    .schedule-row > .list-topline h3,
    .schedule-row > .list-topline p {
        white-space: normal;
    }

    .schedule-days {
        grid-template-columns: repeat(7, minmax(0, 1fr));
    }

    .schedule-pulse-strip,
    .schedule-home-grid {
        grid-template-columns: 1fr;
    }

    .schedule-spark-bars {
        justify-content: flex-start;
    }
}

@keyframes scheduleCardPulse {
    0%,
    88%,
    100% {
        border-color: var(--line);
        box-shadow: var(--shadow);
    }
    6%,
    14% {
        border-color: rgba(92, 245, 159, 0.62);
        box-shadow: 0 0 0 1px rgba(92, 245, 159, 0.22), 0 0 18px rgba(92, 245, 159, 0.16);
    }
}

@keyframes opsNavRedFlash {
    0%,
    100% {
        background: rgba(165, 28, 19, 0.42);
        box-shadow: inset 0 0 0 1px rgba(255, 75, 55, 0.35), 0 0 0 rgba(255, 75, 55, 0);
    }
    50% {
        background: rgba(255, 75, 55, 0.82);
        box-shadow: inset 0 0 0 1px rgba(255, 225, 218, 0.65), 0 0 16px rgba(255, 75, 55, 0.56);
        color: #1d0402;
    }
}

@keyframes opsNavYellowFlash {
    0%,
    100% {
        background: rgba(178, 126, 17, 0.36);
        box-shadow: inset 0 0 0 1px rgba(255, 208, 74, 0.34), 0 0 0 rgba(255, 208, 74, 0);
    }
    50% {
        background: rgba(255, 208, 74, 0.86);
        box-shadow: inset 0 0 0 1px rgba(255, 250, 210, 0.78), 0 0 14px rgba(255, 208, 74, 0.5);
        color: #231601;
    }
}

@keyframes opsNavOrangeFlash {
    0%,
    100% {
        background: rgba(173, 75, 15, 0.38);
        box-shadow: inset 0 0 0 1px rgba(255, 143, 55, 0.34), 0 0 0 rgba(255, 143, 55, 0);
    }
    50% {
        background: rgba(255, 143, 55, 0.88);
        box-shadow: inset 0 0 0 1px rgba(255, 235, 210, 0.72), 0 0 14px rgba(255, 143, 55, 0.52);
        color: #260e01;
    }
}

@keyframes opsNavBrandFlash {
    0%,
    100% {
        background: rgba(17, 138, 115, 0.34);
        box-shadow: inset 0 0 0 1px rgba(92, 245, 159, 0.36), 0 0 0 rgba(42, 168, 255, 0);
    }
    50% {
        background: linear-gradient(135deg, rgba(92, 245, 159, 0.88), rgba(42, 168, 255, 0.72));
        box-shadow: inset 0 0 0 1px rgba(234, 255, 245, 0.72), 0 0 16px rgba(42, 168, 255, 0.54);
        color: #02110c;
    }
}

@media (prefers-reduced-motion: reduce) {
    .schedule-tool-card,
    .sidebar-link.nav-alert-red,
    .sidebar-link.nav-alert-yellow,
    .sidebar-link.nav-alert-orange,
    .sidebar-link.nav-alert-brand {
        animation: none;
    }
}


.email-editor-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    padding: 0.55rem;
    margin-bottom: 0.55rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel-soft);
}

.email-editor-toolbar .email-editor-tool {
    min-height: 2rem;
    padding-inline: 0.7rem;
}

.email-compose-form .email-body-field {
    min-height: 15rem;
    line-height: 1.5;
}

.approved-avatar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 0.85rem;
}

.approved-avatar-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.85rem;
    align-items: start;
    padding: 0.9rem;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-faint);
}

.approved-avatar-card.is-default {
    border-color: rgba(92, 245, 159, 0.58);
    box-shadow: 0 0 0 3px rgba(92, 245, 159, 0.1);
}

.approved-avatar-image {
    width: 64px;
    height: 64px;
    border-radius: 999px;
    object-fit: cover;
    object-position: center 34%;
    border: 2px solid rgba(92, 245, 159, 0.65);
    background: rgba(3, 10, 18, 0.72);
}

.approved-avatar-body {
    display: grid;
    gap: 0.4rem;
    min-width: 0;
}

.approved-avatar-body .action-row {
    margin-top: 0.25rem;
}
