:root {
    color-scheme: light;
    --bg: #f4f8ff;
    --bg-soft: #eef4fc;
    --bg-panel: rgba(255, 255, 255, 0.78);
    --bg-panel-strong: rgba(255, 255, 255, 0.92);
    --bg-tint: rgba(232, 241, 255, 0.74);
    --navy: #10233f;
    --navy-soft: #2e466b;
    --text: #12233d;
    --text-soft: #627692;
    --line: rgba(91, 121, 170, 0.16);
    --line-strong: rgba(79, 113, 170, 0.24);
    --accent: #24a5ff;
    --accent-strong: #1170e6;
    --accent-soft: #d8ecff;
    --teal: #18b2b0;
    --good: #1a9f70;
    --warn: #c38922;
    --danger: #d85b72;
    --shadow-xl: 0 30px 70px rgba(25, 54, 97, 0.14);
    --shadow-lg: 0 18px 42px rgba(28, 54, 96, 0.12);
    --shadow-md: 0 12px 28px rgba(28, 54, 96, 0.1);
    --radius-xl: 1rem;
    --radius-lg: 0.7rem;
    --radius-md: 0.45rem;
}

html {
    scrollbar-gutter: stable;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: Aptos, "Segoe UI Variable Text", "Segoe UI", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(36, 165, 255, 0.18), transparent 28%),
        radial-gradient(circle at top right, rgba(17, 112, 230, 0.14), transparent 24%),
        radial-gradient(circle at bottom left, rgba(24, 178, 176, 0.08), transparent 24%),
        linear-gradient(180deg, #f8fbff 0%, var(--bg) 100%);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(rgba(17, 112, 230, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(17, 112, 230, 0.05) 1px, transparent 1px);
    background-size: 32px 32px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.3), transparent 74%);
}

.app-loading-overlay {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: grid;
    place-items: center;
    padding: 1.5rem;
    background:
        radial-gradient(circle at top left, rgba(36, 165, 255, 0.18), transparent 28%),
        radial-gradient(circle at top right, rgba(17, 112, 230, 0.14), transparent 24%),
        radial-gradient(circle at bottom left, rgba(24, 178, 176, 0.08), transparent 24%),
        linear-gradient(180deg, #f8fbff 0%, var(--bg) 100%);
    transition: opacity 220ms ease, visibility 220ms ease;
}

.app-loading-overlay-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.app-loading-shell {
    display: grid;
    place-items: center;
    gap: 1.25rem;
}

.app-loading-logo-stack {
    position: relative;
    width: min(28vw, 220px);
    aspect-ratio: 1;
}

.app-loading-rotating,
.app-loading-static {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.app-loading-rotating {
    animation: app-loading-spin 3.1s linear infinite;
    transform-origin: center;
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.app-loading-label {
    margin: 0;
    color: var(--navy);
    font-size: clamp(1rem, 1.2vw, 1.18rem);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
    opacity: 0.9;
}

.search-results-stack {
    display: grid;
    gap: 1.5rem;
}

.search-result-card {
    display: grid;
    gap: 1rem;
}

.review-comment-thread {
    position: relative;
    display: inline-flex;
}

.review-comment-trigger {
    position: relative;
    min-width: 2.75rem;
    min-height: 2.75rem;
    padding: 0.55rem 0.7rem;
    border-radius: var(--radius-md);
    justify-content: center;
    align-items: center;
}

.review-comment-trigger-open {
    background: linear-gradient(180deg, rgba(216, 236, 255, 0.98), rgba(236, 245, 255, 0.94));
    border-color: rgba(36, 165, 255, 0.3);
}

.review-comment-trigger-icon {
    font-size: 1rem;
    line-height: 1;
}

.review-comment-trigger-count {
    position: absolute;
    top: -0.3rem;
    right: -0.2rem;
    min-width: 1.3rem;
    height: 1.3rem;
    padding: 0 0.24rem;
    border-radius: 0;
    background: linear-gradient(180deg, var(--accent-strong), var(--accent));
    color: white;
    font-size: 0.72rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 24px rgba(17, 112, 230, 0.24);
}

.review-comment-panel {
    display: grid;
    gap: 0.9rem;
    padding: 1rem;
    box-sizing: border-box;
    overflow: hidden;
    overscroll-behavior: contain;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(242, 247, 255, 0.96));
    box-shadow: var(--shadow-xl);
}

.review-comment-overlay {
    position: fixed;
    inset: 0;
    z-index: 1449;
    background: rgba(12, 24, 46, 0.24);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.review-comment-modal-shell {
    position: fixed;
    inset: 0;
    display: grid;
    align-items: center;
    justify-items: center;
    place-items: center;
    overflow: auto;
    overscroll-behavior: contain;
    z-index: 1450;
    padding: 1.5rem;
}

.review-comment-modal-card {
    width: min(32rem, calc(100vw - 3rem));
    max-width: calc(100vw - 3rem);
    max-height: min(calc(100vh - 3rem), 42rem);
    margin: auto;
    align-self: center;
    justify-self: center;
    border: 1px solid rgba(91, 121, 170, 0.18);
    box-shadow: 0 24px 64px rgba(18, 35, 61, 0.22);
}

.review-comment-panel-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
}

.review-comment-panel-header h3,
.review-comment-panel-header span {
    display: block;
}

.review-comment-panel-header h3 {
    margin: 0;
    font-size: 1.1rem;
}

.review-comment-panel-header span {
    margin-top: 0.2rem;
    color: var(--text-soft);
    font-size: 0.92rem;
}

.review-comment-close {
    white-space: nowrap;
}

.review-comment-panel-body {
    display: grid;
    gap: 0.9rem;
    max-height: 18rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-right: 0.2rem;
}

.review-comment-empty {
    margin: 0;
}

.review-comment-entry {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.8rem;
    align-items: start;
}

.review-comment-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 0;
    background: linear-gradient(180deg, rgba(36, 165, 255, 0.16), rgba(17, 112, 230, 0.22));
    color: var(--navy);
    font-size: 0.76rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.review-comment-copy {
    display: grid;
    gap: 0.45rem;
    padding: 0.75rem 0.85rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    border-radius: 0;
    background: rgba(248, 251, 255, 0.92);
}

.review-comment-copy p {
    margin: 0;
    line-height: 1.5;
    white-space: pre-wrap;
}

.review-comment-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem 0.6rem;
    color: var(--text-soft);
    font-size: 0.82rem;
}

.review-comment-panel-footer {
    display: grid;
    gap: 0.75rem;
}

.review-comment-actions {
    justify-content: flex-end;
}

.review-comment-feedback {
    margin: 0;
}

.search-results-table td,
.search-results-table th {
    vertical-align: middle;
}

.search-results-table td {
    word-break: break-word;
}

@keyframes app-loading-spin {
    from {
        transform: translateZ(0) rotate(0deg);
    }

    to {
        transform: translateZ(0) rotate(1turn);
    }
}

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

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

code {
    padding: 0.14rem 0.38rem;
    border-radius: 0;
    background: rgba(17, 112, 230, 0.08);
    color: var(--navy-soft);
}

.page {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    min-height: 100vh;
    transition: grid-template-columns 180ms ease;
}

.page.page-sidebar-closed {
    grid-template-columns: 0 minmax(0, 1fr);
}

.sidebar {
    position: sticky;
    top: 0;
    align-self: start;
    min-height: 100vh;
    width: 290px;
    padding: 1.25rem;
    border-right: 1px solid rgba(255, 255, 255, 0.38);
    background:
        linear-gradient(180deg, rgba(246, 250, 255, 0.88), rgba(231, 240, 252, 0.9)),
        var(--bg-soft);
    backdrop-filter: blur(18px);
    box-shadow: inset -1px 0 0 rgba(91, 121, 170, 0.08);
    overflow: hidden;
    transition: transform 180ms ease, opacity 180ms ease, box-shadow 180ms ease;
    z-index: 240;
}

.sidebar.sidebar-closed {
    transform: translateX(calc(-100% - 1.5rem));
    opacity: 0;
    pointer-events: none;
}

.sidebar-toggle-button {
    position: fixed;
    bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
    left: 1rem;
    z-index: 280;
    width: 3rem;
    height: 3rem;
    border: 1px solid rgba(90, 120, 170, 0.18);
    border-radius: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(237, 244, 255, 0.92));
    color: var(--navy);
    box-shadow: var(--shadow-lg);
    font-size: 1.4rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.sidebar-toggle-button > i {
    line-height: 1;
}

.sidebar-toggle-button:hover {
    transform: translateY(-1px);
}

.sidebar-toggle-button-open {
    background: linear-gradient(180deg, rgba(232, 241, 255, 0.98), rgba(219, 233, 255, 0.92));
}

.sidebar-backdrop {
    display: none;
}

.brand-shell {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin-bottom: 1rem;
    padding: 0.2rem 0.3rem 1rem;
}

.brand-shell::after {
    content: "";
    position: absolute;
    left: 0.35rem;
    right: 0.35rem;
    bottom: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(91, 121, 170, 0.16), transparent);
}

.brand-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0.2rem 0;
}

.brand-logo,
.topbar-logo,
.entry-logo {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

.brand-logo {
    max-width: 214px;
    padding: 0;
    border-radius: 0;
    background: none;
    border: 0;
    box-shadow: none;
    opacity: 0.94;
    filter: saturate(0.96) brightness(0.99);
}

.menu-stack,
.menu-group,
.page-shell,
.schedule-stack,
.checkpoint-stack,
.faq-stack,
.diagnostic-list,
.event-list li,
.drawing-route-panel,
.public-portal-card,
.scanner-status-panel,
.inline-entry-panel,
.entry-frame {
    display: grid;
}

.menu-stack {
    gap: 1rem;
}

.menu-group {
    gap: 0.35rem;
}

.menu-role-group,
.glass-card,
.topbar,
.entry-header,
.entry-role-card,
.entry-stat-card,
.faq-item,
.module-card,
.module-matrix .glass-card {
    border: 1px solid rgba(90, 120, 170, 0.14);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(241, 247, 255, 0.82));
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(16px);
}

.menu-role-group {
    padding: 1rem;
    border-radius: 0;
}

.menu-role-card {
    display: grid;
    gap: 0.8rem;
}

.menu-role-heading {
    display: flex;
    align-items: center;
    gap: 0.85rem;
}

.menu-role-icon,
.entry-role-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: white;
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    box-shadow: 0 12px 24px rgba(17, 112, 230, 0.22);
}

.menu-role-icon {
    width: 52px;
    height: 52px;
    font-size: 0.9rem;
}

.entry-role-badge {
    width: 46px;
    height: 46px;
    margin-bottom: 0.8rem;
    font-size: 1.02rem;
    letter-spacing: 0;
}

.menu-role-icon > i,
.entry-role-badge > i,
.menu-link-icon > i,
.topbar-search-icon > i,
.topbar-bell-glyph > i,
.review-comment-trigger-icon > i,
.feedback-icon > i,
.scanner-success-icon > i,
.resource-type-icon > i,
.resource-inline-icon > i,
.drawer-edit-icon-button > i,
.status-pill-arrows > i,
.status-pill-gear > i {
    line-height: 1;
}

.entry-role-badge-executive {
    background: linear-gradient(135deg, #1170e6, #18b2b0);
}

.entry-role-badge-administrator {
    background: linear-gradient(135deg, #1d87ff, #6b9cff);
}

.entry-role-badge-technologist {
    background: linear-gradient(135deg, #3b77dd, #2fb6d0);
}

.entry-role-badge-production {
    background: linear-gradient(135deg, #1c9ca1, #4c8ced);
}

.entry-role-badge-machinist {
    background: linear-gradient(135deg, #178c75, #24a5ff);
}

.menu-label,
.topbar-label,
.module-role,
.faq-kicker,
.entry-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    color: var(--text-soft);
    font-size: 0.73rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.menu-role-card strong,
.topbar-card strong,
.entry-role-head h2,
.kpi-card strong,
h1,
h2,
h3 {
    color: var(--navy);
    letter-spacing: -0.04em;
}

.menu-role-summary,
.menu-role-card p,
.muted,
.lede,
.entry-role-summary,
.topbar-card p,
.field-label,
.entry-stat-card span,
.operation-meta,
.order-kicker,
.recommendation-kicker {
    color: var(--text-soft);
}

.menu-role-summary {
    margin: 0;
    font-weight: 700;
    line-height: 1.55;
    font-variant-numeric: tabular-nums;
}

.menu-role-action {
    width: 100%;
}

.menu-role-search {
    width: 100%;
}

.menu-role-personnel-field {
    gap: 0.45rem;
}

.menu-role-personnel-field span {
    color: var(--navy);
    font-size: 0.82rem;
    font-weight: 700;
}

.menu-role-personnel-hint {
    margin: -0.2rem 0 0;
    font-size: 0.82rem;
}

.menu-label {
    padding: 0.45rem 0.25rem 0.2rem;
}

.menu-role-inline-label {
    padding: 0;
}

.menu-link {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.78rem;
    padding: 0.92rem 1rem;
    border-radius: 0;
    color: var(--navy-soft);
    font-weight: 700;
    transition: transform 140ms ease, box-shadow 140ms ease, background-color 140ms ease, color 140ms ease;
}

.menu-link::before {
    content: none;
}

.menu-link-icon {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    background: linear-gradient(135deg, rgba(17, 112, 230, 0.16), rgba(24, 178, 176, 0.18));
    color: var(--accent-strong);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
    font-size: 0.86rem;
    font-weight: 800;
    transition: transform 140ms ease, box-shadow 140ms ease, color 140ms ease, background-color 140ms ease;
}

.menu-link.active,
.menu-link:hover {
    color: var(--navy);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(232, 242, 255, 0.86));
    box-shadow: var(--shadow-md);
    transform: translateX(4px);
}

.menu-link.active .menu-link-icon,
.menu-link:hover .menu-link-icon {
    color: white;
    background: linear-gradient(135deg, var(--accent-strong), var(--teal));
    box-shadow: 0 10px 20px rgba(17, 112, 230, 0.22);
    transform: scale(1.04);
}

main {
    min-width: 0;
    overflow-x: clip;
    padding: 1.25rem;
    position: relative;
}

.topbar {
    display: grid;
    gap: 0.9rem;
    margin-bottom: 1.4rem;
    padding: 0.85rem;
    border-radius: 0;
    position: relative;
    z-index: 5;
    overflow: visible;
}

.topbar-utility,
.page-header,
.section-title-row,
.button-row,
.header-actions,
.list-card,
.operation-card,
.mini-card,
.recommendation-top,
.recommendation-footer,
.manual-entry,
.metrics-pair {
    display: flex;
    gap: 1rem;
}

.topbar-utility {
    align-items: center;
    justify-content: space-between;
}

.topbar-search {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    flex: 1 1 auto;
    min-width: 0;
    padding: 0.85rem 1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(238, 245, 255, 0.86));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.topbar-search-icon {
    width: 1rem;
    height: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    color: rgba(17, 112, 230, 0.6);
    font-size: 0.9rem;
}

.topbar-search-icon::after {
    content: none;
}

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

.topbar-search-input::placeholder {
    color: var(--text-soft);
}

.topbar-bell-button-inline {
    display: flex;
    width: 100%;
    max-width: 100%;
    height: auto;
    min-width: 0;
    min-height: 3rem;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    padding-right: 2.9rem;
    border-radius: 0;
    font-weight: 700;
    color: var(--navy-soft);
    box-sizing: border-box;
    overflow: hidden;
}

.topbar-bell-shell-inline {
    display: block;
    width: 100%;
    max-width: 100%;
    position: static;
    z-index: auto;
    overflow: hidden;
}

.topbar-bell-label {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    text-align: left;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.topbar-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.9rem;
}

.topbar-card {
    position: relative;
    padding: 1rem 1.08rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(237, 244, 255, 0.88));
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.topbar-card::after {
    content: "";
    position: absolute;
    inset: auto 1rem 0.8rem;
    height: 4px;
    border-radius: 0;
    background: linear-gradient(90deg, rgba(36, 165, 255, 0.86), rgba(24, 178, 176, 0.62), transparent 88%);
    opacity: 0.34;
}

.topbar-card strong {
    display: block;
    margin: 0.1rem 0 0;
    font-size: 1.16rem;
}

.topbar-card p {
    margin: 0.35rem 0 0;
    line-height: 1.5;
}

.topbar-card-emphasis {
    background:
        radial-gradient(circle at top right, rgba(36, 165, 255, 0.16), transparent 40%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(233, 243, 255, 0.92));
}

.topbar-label {
    margin-bottom: 0.55rem;
    padding: 0.34rem 0.62rem;
    border-radius: 0;
    background: rgba(17, 112, 230, 0.08);
    color: var(--navy-soft);
}

.notification-card {
    display: grid;
    grid-template-columns: 0.95rem minmax(0, 1fr);
    gap: 0.9rem;
}

.notification-icon {
    width: 0.95rem;
    height: 0.95rem;
    margin-top: 0.5rem;
    border-radius: 0;
    background: linear-gradient(180deg, var(--accent), var(--accent-strong));
    box-shadow:
        0 0 0 0.4rem rgba(36, 165, 255, 0.12),
        0 10px 18px rgba(17, 112, 230, 0.22);
}

.content-shell {
    min-width: 0;
    position: relative;
    overflow-x: clip;
}

.app-shell {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(16, 35, 63, 0.98) 0 5.4rem, rgba(200, 235, 255, 0.18) 5.4rem 12rem, rgba(245, 249, 255, 0.96) 12rem 100%);
}

.app-shell-header {
    position: sticky;
    top: 0;
    z-index: 220;
}

.app-shell-main {
    min-width: 0;
}

.app-nav-shell {
    background:
        linear-gradient(180deg, rgba(13, 28, 52, 0.98), rgba(18, 43, 79, 0.97)),
        radial-gradient(circle at top left, rgba(36, 165, 255, 0.12), transparent 22%),
        radial-gradient(circle at top right, rgba(24, 178, 176, 0.1), transparent 18%);
    color: #fff;
    box-shadow: 0 16px 30px rgba(16, 35, 63, 0.18);
    border-bottom: 1px solid rgba(168, 196, 238, 0.14);
}

.app-nav-surface {
    position: relative;
    width: 100%;
    margin: 0;
    padding: 0.45rem 1rem;
}

.app-nav-topbar-inner {
    min-height: 4.6rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0;
}

.app-nav-mobile-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 0 1 35rem;
    min-width: 0;
}

.app-nav-mobile-panel {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
}

.app-nav-mobile-toggle {
    display: none;
    width: 3rem;
    height: 3rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(168, 196, 238, 0.18);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
    color: #fff;
    box-shadow: 0 12px 24px rgba(7, 16, 31, 0.16);
}

.app-nav-mobile-toggle:hover,
.app-nav-mobile-toggle:focus-visible {
    border-color: rgba(122, 185, 255, 0.36);
    background: linear-gradient(180deg, rgba(44, 121, 243, 0.24), rgba(24, 178, 176, 0.16));
}

.app-nav-brand,
.app-nav-brand-link {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    min-width: 0;
    flex: 0 0 auto;
}

.app-nav-brand-logo {
    width: auto;
    height: 2.35rem;
    object-fit: contain;
    filter: drop-shadow(0 8px 18px rgba(10, 19, 35, 0.24));
}

.app-nav-brand-logo-primary {
    height: 3.1rem;
    max-width: min(100%, 18rem);
}

.app-nav-brand-copy {
    display: grid;
    gap: 0.08rem;
    min-width: 0;
}

.app-nav-brand-copy strong {
    color: #fff;
    font-size: 1.22rem;
    letter-spacing: 0.02em;
}

.app-nav-brand-copy span {
    color: rgba(232, 240, 255, 0.72);
    font-size: 0.8rem;
}

.app-nav-role-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    min-height: 3rem;
    padding: 0.55rem 0.9rem;
    border: 1px solid rgba(168, 196, 238, 0.18);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
    backdrop-filter: blur(12px);
    box-shadow: 0 12px 24px rgba(7, 16, 31, 0.16);
}

.app-nav-role-icon {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(36, 165, 255, 0.92), rgba(24, 178, 176, 0.84));
    color: #fff;
    font-size: 0.9rem;
    box-shadow: 0 10px 20px rgba(17, 112, 230, 0.22);
}

.app-nav-role-copy {
    display: grid;
    gap: 0.05rem;
    min-width: 0;
}

.app-nav-role-copy strong {
    color: #fff;
    font-size: 0.9rem;
    letter-spacing: 0;
}

.app-nav-role-copy span {
    color: rgba(255, 255, 255, 0.76);
    font-size: 0.76rem;
}

.app-nav-search {
    flex: 1 1 18rem;
    min-width: 14rem;
    max-width: 26rem;
    margin: 0;
    border-color: rgba(109, 150, 214, 0.22);
    background: linear-gradient(180deg, rgba(232, 239, 250, 0.98), rgba(221, 231, 246, 0.94));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.9),
        0 10px 24px rgba(7, 16, 31, 0.1);
}

.app-nav-search:focus-within {
    border-color: rgba(70, 155, 255, 0.46);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.92),
        0 0 0 4px rgba(36, 165, 255, 0.12),
        0 12px 28px rgba(7, 16, 31, 0.14);
}

.app-nav-search .topbar-search-icon {
    color: rgba(17, 112, 230, 0.82);
}

.app-nav-search .topbar-search-input {
    font-size: 0.94rem;
    color: var(--navy);
    font-weight: 600;
}

.app-nav-search .topbar-search-input::placeholder {
    color: rgba(46, 70, 107, 0.68);
}

.app-nav-header-search {
    min-width: 0;
    max-width: none;
}

.app-nav-notification-button {
    flex: 0 0 auto;
    min-width: 10.75rem;
    min-height: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(102, 157, 232, 0.28);
    background: linear-gradient(135deg, rgba(30, 77, 136, 0.92), rgba(22, 58, 106, 0.96));
    color: rgba(248, 251, 255, 0.98);
    font-weight: 700;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 12px 24px rgba(7, 16, 31, 0.16);
    white-space: nowrap;
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background-color 140ms ease;
}

.app-nav-notification-button .topbar-bell-label {
    color: inherit;
    white-space: nowrap;
}

.app-nav-notification-button .topbar-bell-glyph {
    width: 1.55rem;
    height: 1.55rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(36, 165, 255, 0.26), rgba(24, 178, 176, 0.24));
    color: #b8e1ff;
}

.app-nav-notification-button:hover,
.app-nav-notification-button:focus-visible {
    transform: translateY(-1px);
    border-color: rgba(122, 185, 255, 0.36);
    background: linear-gradient(135deg, rgba(36, 93, 164, 0.94), rgba(24, 67, 124, 0.98));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 14px 28px rgba(7, 16, 31, 0.2);
}

.app-nav-switch-view {
    min-height: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    border: 0;
    color: #fff;
    background: linear-gradient(135deg, var(--accent-strong), var(--accent));
    box-shadow: 0 16px 28px rgba(17, 112, 230, 0.22);
}

.app-nav-switch-view:hover,
.app-nav-switch-view:focus-visible {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.app-nav-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.45rem;
    flex: 1 1 auto;
    min-width: 0;
}

.app-nav-links .menu-link {
    min-height: 2.9rem;
    padding: 0.7rem 0.8rem;
    border: 1px solid rgba(168, 196, 238, 0.1);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025));
    color: rgba(240, 246, 255, 0.92);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 8px 18px rgba(7, 16, 31, 0.08);
    white-space: nowrap;
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background-color 140ms ease, color 140ms ease;
}

.app-nav-links .menu-link .menu-link-icon {
    width: 1.42rem;
    height: 1.42rem;
    background: linear-gradient(135deg, rgba(36, 165, 255, 0.16), rgba(24, 178, 176, 0.14));
    color: #8ecbff;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.app-nav-links .menu-link.active,
.app-nav-links .menu-link:hover {
    transform: translateY(-1px);
    color: #fff;
    border-color: rgba(96, 169, 255, 0.24);
    background: linear-gradient(135deg, rgba(44, 121, 243, 0.28), rgba(24, 178, 176, 0.18));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 14px 26px rgba(7, 16, 31, 0.16);
}

.app-nav-links .menu-link.active .menu-link-icon,
.app-nav-links .menu-link:hover .menu-link-icon {
    color: #fff;
    background: linear-gradient(135deg, rgba(17, 112, 230, 0.92), rgba(24, 178, 176, 0.84));
    box-shadow: 0 10px 18px rgba(17, 112, 230, 0.2);
}

.app-nav-links .menu-link > span:last-child {
    white-space: nowrap;
}

.app-nav-profile-menu {
    position: relative;
    flex: 0 0 auto;
}

.app-nav-role-summary {
    list-style: none;
    cursor: pointer;
    user-select: none;
    min-width: 14rem;
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease, background-color 140ms ease;
}

.app-nav-role-summary::-webkit-details-marker {
    display: none;
}

.app-nav-role-summary:hover,
.app-nav-profile-menu[open] .app-nav-role-summary {
    transform: translateY(-1px);
    border-color: rgba(116, 176, 255, 0.24);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.06));
    box-shadow: 0 14px 28px rgba(7, 16, 31, 0.18);
}

.app-nav-role-caret {
    margin-left: auto;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.8rem;
    transition: transform 0.2s ease;
}

.app-nav-profile-menu[open] .app-nav-role-caret {
    transform: rotate(180deg);
}

.app-nav-profile-dropdown {
    position: absolute;
    top: calc(100% + 0.55rem);
    right: 0;
    z-index: 240;
    width: min(21rem, calc(100vw - 1rem));
    display: grid;
    gap: 0.9rem;
    padding: 1rem;
    border: 1px solid rgba(168, 196, 238, 0.16);
    background:
        linear-gradient(180deg, rgba(16, 35, 63, 0.99), rgba(12, 28, 52, 0.99)),
        radial-gradient(circle at top right, rgba(36, 165, 255, 0.1), transparent 28%);
    box-shadow: 0 24px 40px rgba(10, 19, 35, 0.34);
}

.app-nav-dropdown-control {
    margin: 0;
}

.app-nav-dropdown-control span {
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

/*
   Keep the application header to a single, predictable control row on compact
   desktop devices as well as tablets. Navigation remains available from the
   hamburger panel instead of wrapping links into a second header row.
*/
@media (max-width: 1440px) {
    .app-nav-surface {
        padding-inline: 0.85rem;
    }

    .app-nav-topbar-inner {
        display: block;
        min-height: 0;
        padding: 0;
    }

    .app-nav-mobile-header {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        width: 100%;
        min-height: 4.25rem;
    }

    .app-nav-mobile-toggle {
        display: inline-flex;
        flex: 0 0 auto;
    }

    .app-nav-mobile-panel {
        display: none;
        position: absolute;
        inset: 100% 0 auto;
        width: 100%;
        max-height: calc(100dvh - 4.25rem);
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
        overflow-y: auto;
        overscroll-behavior: contain;
        padding: 0.75rem 0.85rem;
        background: linear-gradient(180deg, #122b4f, #0d1c34);
        box-shadow: var(--shadow-lg);
    }

    .app-nav-mobile-panel.app-nav-mobile-panel-open {
        display: flex;
    }

    .app-nav-mobile-panel > * {
        flex: 0 0 auto;
    }

    .app-nav-links {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        flex-wrap: nowrap;
        gap: 0.55rem;
    }

    .app-nav-notification-button,
    .app-nav-profile-menu {
        width: 100%;
        flex: 1 1 100%;
        min-width: 0;
        max-width: none;
    }

    .app-nav-role-summary,
    .app-nav-profile-dropdown {
        width: 100%;
    }

    .app-nav-profile-dropdown {
        position: static;
        margin-top: 0.55rem;
    }
}

@media (max-width: 640px) {
    .app-shell {
        background:
            linear-gradient(180deg, rgba(16, 35, 63, 0.98) 0 5rem, rgba(200, 235, 255, 0.18) 5rem 12rem, rgba(245, 249, 255, 0.96) 12rem 100%);
    }

    .app-nav-topbar-inner {
        gap: 0.6rem;
    }

    .app-nav-mobile-header {
        gap: 0.55rem;
    }

    .app-nav-brand-logo {
        height: 2.05rem;
    }

    .app-nav-brand-copy strong {
        font-size: 1.08rem;
    }

    .app-nav-brand-copy span {
        font-size: 0.76rem;
    }

    .app-nav-search {
        min-width: 0;
    }

    .app-nav-role-pill {
        width: 100%;
    }

    .app-nav-links .menu-link {
        width: 100%;
    }

    .app-nav-profile-dropdown {
        position: static;
        width: 100%;
        margin-top: 0.55rem;
    }
}

.entry-shell {
    position: relative;
    min-height: 100vh;
    padding: 1.4rem;
    overflow: hidden;
}

.entry-backdrop {
    position: absolute;
    border-radius: 0;
    pointer-events: none;
    filter: blur(28px);
}

.entry-backdrop-left {
    top: 1rem;
    left: -8rem;
    width: 22rem;
    height: 22rem;
    background: radial-gradient(circle, rgba(36, 165, 255, 0.22), transparent 64%);
}

.entry-backdrop-right {
    right: -8rem;
    bottom: 1rem;
    width: 24rem;
    height: 24rem;
    background: radial-gradient(circle, rgba(24, 178, 176, 0.18), transparent 68%);
}

.entry-frame {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 1.3rem;
    max-width: 1080px;
    margin: 0 auto;
}

.entry-header {
    display: grid;
    gap: 1.15rem;
    padding: 1.1rem;
    border-radius: 0;
}

.entry-brand-block,
.entry-meta-row,
.entry-role-grid,
.content-grid,
.scanner-grid,
.drawing-preview-grid,
.module-grid,
.module-matrix,
.help-grid,
.warehouse-summary-grid,
.operations-secondary-grid,
.public-summary-grid,
.photo-grid,
.form-grid,
.kpi-grid,
.kpi-grid-wide {
    display: grid;
    gap: 1rem;
}

.entry-brand-block {
    grid-template-columns: minmax(220px, 330px) minmax(0, 1fr);
    align-items: center;
    gap: 1.35rem;
}

.entry-hero-main {
    display: grid;
    grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
    gap: 1.05rem;
    align-items: stretch;
}

.entry-logo-shell {
    display: grid;
    align-items: center;
    min-height: 108px;
    padding: 0;
    border-radius: 0;
    background: none;
    border: 0;
    box-shadow: none;
}

.entry-hero-copy {
    display: grid;
    align-content: center;
    gap: 0.45rem;
    padding: 0.15rem 0.2rem;
}

.entry-kicker {
    margin: 0;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-soft);
}

.entry-hero-copy h1 {
    font-size: clamp(2rem, 3vw, 2.65rem);
    line-height: 1.02;
}

.entry-hero-copy .lede {
    max-width: 64ch;
    margin-top: 0.15rem;
    font-size: 1rem;
    line-height: 1.58;
}

.entry-meta-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem;
}

.entry-stat-card {
    display: grid;
    grid-template-rows: auto auto minmax(0, 1fr);
    gap: 0.35rem;
    min-height: 4.7rem;
    padding: 0.9rem 1rem;
    border-radius: 0;
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(242, 247, 255, 0.84));
    border: 1px solid rgba(91, 121, 170, 0.12);
}

.entry-stat-sparkline {
    position: relative;
    grid-row: 3;
    align-self: end;
    z-index: 0;
    width: 100%;
    height: 1.15rem;
    overflow: visible;
    pointer-events: none;
}

.entry-stat-sparkline polyline {
    fill: none;
    stroke: rgba(47, 133, 240, 0.35);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    vector-effect: non-scaling-stroke;
}

.entry-stat-card > :not(.entry-stat-sparkline) {
    position: relative;
    z-index: 1;
}

.entry-stat-head {
    display: flex;
    grid-row: 1;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.entry-stat-card strong {
    display: block;
    grid-row: 2;
    font-size: 1.95rem;
    line-height: 1.05;
    color: var(--navy);
}

.entry-stat-card span {
    color: var(--text-soft);
    font-size: 0.95rem;
}

.entry-role-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.95rem;
}

.entry-role-card {
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 1rem;
    min-width: 0;
    min-height: 21rem;
    padding: 1.15rem;
    justify-items: center;
    text-align: center;
    border-radius: 0;
}

.entry-role-card-active {
    border-color: rgba(17, 112, 230, 0.24);
    box-shadow:
        0 24px 54px rgba(17, 112, 230, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.entry-role-head,
.entry-role-heading,
.entry-role-heading-copy,
.entry-role-body {
    display: grid;
    gap: 0.75rem;
}

.entry-role-heading {
    min-width: 0;
    justify-items: center;
}

.entry-role-heading-copy {
    gap: 0.5rem;
    justify-items: center;
}

.entry-role-head h2 {
    margin: 0;
    font-size: clamp(1.2rem, 1.45vw, 1.7rem);
    line-height: 1.12;
}

.entry-role-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0;
    font-size: 1rem;
    font-weight: 900;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.58);
}

.entry-role-badge-executive,
.entry-role-badge-administrator,
.entry-role-badge-technologist,
.entry-role-badge-production,
.entry-role-badge-machinist {
    color: #fff;
}

.entry-role-badge-executive {
    background: linear-gradient(135deg, #2e8ef7, #49b6cf);
}

.entry-role-badge-administrator {
    background: linear-gradient(135deg, #4a80f0, #5ca0ff);
}

.entry-role-badge-technologist {
    background: linear-gradient(135deg, #3479d8, #4bb5c8);
}

.entry-role-badge-production {
    background: linear-gradient(135deg, #4e87da, #3fa3d2);
}

.entry-role-badge-machinist {
    background: linear-gradient(135deg, #4a9dc3, #32b7a5);
}

.entry-role-body {
    align-content: start;
    justify-items: center;
}

.entry-role-summary,
.entry-role-outcome {
    margin: 0;
    line-height: 1.58;
}

.entry-role-summary {
    color: var(--navy);
}

.entry-role-outcome {
    font-size: 0.95rem;
}

.entry-role-actions {
    margin-top: auto;
    width: 100%;
    justify-content: center;
}

.entry-role-actions .action-button {
    width: 100%;
    justify-content: center;
    min-height: 3.4rem;
    border-radius: 0;
    font-size: 0.98rem;
}

.page-shell {
    gap: 1.35rem;
}

.page-header {
    align-items: flex-end;
    justify-content: space-between;
}

.page-header > div,
.section-title-row > div,
.list-card > div,
.operation-card > div,
.mini-card > div,
.recommendation-top > div,
.manual-entry > *,
.header-actions {
    min-width: 0;
}

.lede {
    max-width: 76ch;
    margin: 0.75rem 0 0;
    line-height: 1.72;
}

.glass-card {
    min-width: 0;
    padding: 1.35rem;
    border-radius: 0;
}

.access-card {
    max-width: 760px;
}

.kpi-grid,
.kpi-grid-wide {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
}

.kpi-card {
    position: relative;
    display: grid;
    gap: 0.85rem;
    min-width: 0;
    overflow: hidden;
    container-type: inline-size;
}

.kpi-card::after {
    content: none;
}

.kpi-card span {
    font-size: 0.92rem;
}

.kpi-card strong {
    font-size: clamp(1.85rem, 2.4vw, 2.6rem);
}

.dashboard-metric-shell,
.dashboard-section-heading,
.dashboard-filter-group,
.dashboard-card-head,
.dashboard-card-value-row,
.kpi-chart,
.kpi-chart-column,
.dashboard-table-card,
.dashboard-table-toolbar {
    display: grid;
}

.dashboard-metric-shell,
.dashboard-table-card {
    gap: 1rem;
}

.dashboard-filter-group {
    gap: 0.7rem;
}

.dashboard-filter-group-inline {
    justify-items: end;
}

.dashboard-filter-group-inline .filter-bar {
    justify-content: flex-end;
}

.dashboard-summary-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.85rem;
    flex-wrap: nowrap;
}

.dashboard-select-filter {
    display: grid;
    gap: 0.45rem;
    min-width: 10.5rem;
}

.dashboard-select-filter .field-input {
    min-width: 0;
}

.dashboard-summary-toggle {
    display: none;
    white-space: nowrap;
}

.dashboard-filter-label,
.dashboard-card-label,
.dashboard-card-range {
    color: var(--text-soft);
}

.dashboard-filter-label {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.dashboard-section-heading {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 1rem;
}

.dashboard-card-head {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 0.2rem;
    min-width: 0;
}

.dashboard-card-value-row {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    gap: 0.8rem;
    min-width: 0;
}

.dashboard-card-label {
    display: block;
    margin-bottom: 0.2rem;
    font-size: 0.94rem;
}

.dashboard-card-range {
    margin: 0;
    font-size: 0.78rem;
}

.dashboard-trend {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.9rem;
    min-height: 1.9rem;
    padding: 0.2rem 0.45rem;
    border-radius: 0;
    font-size: 0.95rem;
    font-weight: 800;
    line-height: 1;
}

.dashboard-trend-up {
    color: var(--good);
    background: rgba(26, 159, 112, 0.12);
}

.dashboard-trend-down {
    color: var(--danger);
    background: rgba(216, 91, 114, 0.12);
}

.kpi-chart {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    align-items: end;
    gap: clamp(0.2rem, 0.4vw, 0.45rem);
    min-height: 6.8rem;
    width: 100%;
    min-width: 0;
}

.kpi-chart-column {
    grid-template-rows: minmax(3.6rem, 1fr) minmax(1.15rem, auto);
    gap: 0.35rem;
    align-items: end;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.kpi-chart-bar {
    width: 100%;
    max-width: 100%;
    height: var(--bar-height);
    min-height: 1rem;
    border-radius: 0;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
    align-self: end;
}

.kpi-chart-label {
    color: var(--text-soft);
    width: 100%;
    font-size: clamp(0.54rem, 0.62vw, 0.66rem);
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1.15;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.kpi-chart-decorative {
    min-height: 4.4rem;
    margin-top: auto;
    pointer-events: none;
}

.kpi-chart-decorative .kpi-chart-column {
    grid-template-rows: minmax(3.8rem, 1fr);
}

.kpi-chart-decorative .kpi-chart-label {
    display: none;
}

.kpi-chart-decorative-labeled {
    min-height: 5.75rem;
    gap: clamp(0.2rem, 0.38vw, 0.4rem);
}

.kpi-chart-decorative-labeled .kpi-chart-column {
    grid-template-rows: minmax(3.45rem, 1fr) minmax(1.55rem, auto);
}

.kpi-chart-decorative-labeled .kpi-chart-label {
    display: block;
}

.crm-kpi-chart {
    --crm-kpi-columns: 6;
    grid-template-columns: repeat(var(--crm-kpi-columns), minmax(0, 1fr));
}

.crm-kpi-chart .kpi-chart-column:nth-child(n + 7) {
    display: none;
}

.crm-kpi-chart .kpi-chart-label {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: normal;
    hyphens: none;
}

@container (max-width: 25rem) {
    .crm-kpi-chart {
        --crm-kpi-columns: 5;
    }

    .crm-kpi-chart .kpi-chart-column:nth-child(n + 6) {
        display: none;
    }
}

@container (max-width: 21rem) {
    .crm-kpi-chart {
        --crm-kpi-columns: 4;
    }

    .crm-kpi-chart .kpi-chart-column:nth-child(n + 5) {
        display: none;
    }
}

@container (max-width: 17rem) {
    .crm-kpi-chart {
        --crm-kpi-columns: 3;
    }

    .crm-kpi-chart .kpi-chart-column:nth-child(n + 4) {
        display: none;
    }
}

.chart-bar-primary .kpi-chart-bar {
    background: linear-gradient(180deg, rgba(17, 112, 230, 0.92), rgba(116, 156, 238, 0.88));
}

.chart-bar-secondary .kpi-chart-bar {
    background: linear-gradient(180deg, rgba(36, 165, 255, 0.9), rgba(142, 200, 255, 0.88));
}

.chart-bar-accent .kpi-chart-bar {
    background: linear-gradient(180deg, rgba(24, 178, 176, 0.9), rgba(157, 218, 216, 0.86));
}

.dashboard-table-toolbar {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 1rem;
}

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

.dashboard-data-table th,
.dashboard-data-table td {
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.dashboard-data-table td code {
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.table-inline-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.55rem;
    overflow-x: auto;
    scrollbar-width: thin;
}

.table-inline-actions .ghost-button,
.table-inline-actions .action-button,
.table-inline-actions a {
    flex: 0 0 auto;
    min-height: 2.2rem;
    padding: 0.5rem 0.8rem;
    white-space: nowrap;
}

.dashboard-row-current td {
    background: rgba(118, 196, 255, 0.16);
}

.dashboard-row-completed td {
    background: rgba(148, 162, 184, 0.12);
    color: rgba(59, 82, 120, 0.82);
}

.workflow-accent-card {
    gap: 1rem;
}

.workflow-accent-card-warning {
    border-color: rgba(233, 179, 41, 0.26);
    background: linear-gradient(180deg, rgba(255, 251, 237, 0.96), rgba(255, 246, 214, 0.9));
    box-shadow: 0 18px 36px rgba(219, 171, 44, 0.12);
}

.workflow-accent-card-info {
    border-color: rgba(36, 165, 255, 0.28);
    background: linear-gradient(180deg, rgba(240, 248, 255, 0.98), rgba(220, 238, 255, 0.92));
    box-shadow: 0 18px 36px rgba(36, 165, 255, 0.14);
}

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

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

.module-matrix-wide {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.warehouse-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

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

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

.section-title-row {
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.module-card,
.module-matrix .glass-card {
    padding: 1.2rem;
    border-radius: 0;
}

.module-card-link {
    display: block;
    height: 100%;
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.module-card-link:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(17, 112, 230, 0.22);
}

.module-card span {
    display: inline-block;
    margin-top: 0.7rem;
    color: var(--navy);
    font-weight: 700;
}

.action-button,
.ghost-button,
.filter-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.9rem;
    padding: 0.8rem 1.2rem;
    border-radius: 0;
    cursor: pointer;
    transition: transform 140ms ease, box-shadow 140ms ease, background-color 140ms ease, border-color 140ms ease;
    white-space: normal;
    text-align: center;
    line-height: 1.3;
}

.action-button {
    border: 0;
    color: white;
    background: linear-gradient(135deg, var(--accent-strong), var(--accent));
    box-shadow: 0 16px 28px rgba(17, 112, 230, 0.22);
}

.ghost-button,
.filter-pill {
    border: 1px solid rgba(91, 121, 170, 0.18);
    background: rgba(255, 255, 255, 0.82);
    color: var(--navy-soft);
}

.action-button:hover,
.ghost-button:hover,
.filter-pill:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.action-button:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.button-busy {
    pointer-events: none;
}

html:has(.review-modal-shell, .review-comment-modal-shell, .notification-modal-shell),
body:has(.review-modal-shell, .review-comment-modal-shell, .notification-modal-shell) {
    overflow: hidden;
    overscroll-behavior: none;
}

.app-connection-status {
    position: fixed;
    inset: auto 1rem 1rem auto;
    z-index: 300;
    margin: 0;
    padding: 0.65rem 1rem;
    border: 1px solid var(--line);
    background: var(--bg-panel-strong);
    box-shadow: var(--shadow-md);
}

button[data-action-completion],
button[data-loading-submit='true'] {
    position: relative;
}

.button-action-content {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: inherit;
    visibility: visible;
    opacity: 1;
    transition:
        opacity 0s linear 140ms,
        visibility 0s linear 140ms;
}

button[data-action-completion] > .button-inline-spinner,
button[data-loading-submit='true'] > .button-inline-spinner {
    position: absolute;
    inset: 0;
    margin: auto;
    visibility: hidden;
    opacity: 0;
    animation-play-state: paused;
    transition:
        opacity 0s linear 140ms,
        visibility 0s linear 140ms;
}

button:is([data-action-completion], [data-loading-submit='true']):is([aria-busy='true'], [data-client-pending='true']) > .button-action-content {
    visibility: hidden;
    opacity: 0;
}

button:is([data-action-completion], [data-loading-submit='true']):is([aria-busy='true'], [data-client-pending='true']) > .button-inline-spinner {
    visibility: visible;
    opacity: 1;
    animation-play-state: running;
}

button[data-client-pending='true'] {
    pointer-events: none;
    cursor: wait;
}

.button-inline-spinner {
    width: 0.95rem;
    height: 0.95rem;
    margin-right: 0.55rem;
    border: 0.16rem solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: button-inline-spin 0.7s linear infinite;
}

@keyframes button-inline-spin {
    to {
        transform: rotate(360deg);
    }
}

.icon-button {
    min-width: 2.9rem;
    padding-inline: 0;
    font-size: 1.4rem;
}

.icon-button-guided {
    border-color: rgba(36, 165, 255, 0.42);
    background:
        linear-gradient(110deg, rgba(255, 255, 255, 0.9) 0%, rgba(219, 236, 255, 0.95) 26%, rgba(96, 194, 255, 0.68) 48%, rgba(219, 236, 255, 0.95) 72%, rgba(255, 255, 255, 0.9) 100%);
    background-size: 220% 100%;
    box-shadow:
        0 0 0 0.18rem rgba(36, 165, 255, 0.14),
        var(--shadow-md);
    animation: icon-button-guided-sweep 2.2s ease;
}

@keyframes icon-button-guided-sweep {
    0% {
        background-position: 140% 0;
        transform: translateY(0) scale(1);
    }

    30% {
        background-position: 68% 0;
        transform: translateY(-1px) scale(1.03);
    }

    100% {
        background-position: -40% 0;
        transform: translateY(0) scale(1);
    }
}

.title-with-help {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.title-with-help h1,
.title-with-help h2 {
    margin: 0;
}

.help-trigger-button {
    min-width: 2.35rem;
    min-height: 2.35rem;
    padding: 0;
    font-size: 1rem;
    font-weight: 800;
    line-height: 1;
    border-radius: 0;
    flex: 0 0 auto;
}

.help-inline-box {
    margin-top: 0.65rem;
    padding: 0.85rem 1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(246, 250, 255, 0.96), rgba(232, 241, 255, 0.88));
    color: var(--navy-soft);
    line-height: 1.6;
    max-width: 72ch;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
}

.filter-pill-active {
    color: white;
    border-color: transparent;
    background: linear-gradient(135deg, var(--accent-strong), var(--teal));
    box-shadow: 0 16px 26px rgba(17, 112, 230, 0.2);
}

.split-order-action {
    margin-block: 6px;
}

.inline-entry-panel {
    gap: 1rem;
    margin-bottom: 1rem;
    padding: 1rem;
    border-radius: 0;
    background: rgba(239, 246, 255, 0.74);
    border: 1px solid rgba(91, 121, 170, 0.14);
}

.feedback-banner {
    display: grid;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border-radius: 0;
    border: 1px solid transparent;
}

.feedback-cluster {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    gap: 0.9rem;
    min-width: 0;
}

.feedback-copy {
    display: grid;
    flex: 1 1 auto;
    min-width: 0;
    gap: 0.18rem;
}

.feedback-copy strong,
.feedback-copy span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.feedback-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.3rem;
    height: 2.3rem;
    flex: 0 0 auto;
    border-radius: 0;
    font-weight: 800;
    background: rgba(255, 255, 255, 0.84);
    color: var(--navy);
    font-size: 1rem;
}

.feedback-good {
    background: rgba(26, 159, 112, 0.12);
    border-color: rgba(26, 159, 112, 0.22);
}

.feedback-warn {
    background: rgba(216, 91, 114, 0.1);
    border-color: rgba(216, 91, 114, 0.18);
}

.app-toast-stack {
    position: fixed;
    right: 1.2rem;
    bottom: 1.2rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    width: min(26rem, calc(100vw - 2rem));
}

.app-toast {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.85rem;
    align-items: start;
    padding: 1rem 1.05rem;
    border: 1px solid rgba(91, 121, 170, 0.18);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 40px rgba(26, 43, 74, 0.18);
    backdrop-filter: blur(18px);
}

.app-toast-success {
    border-color: rgba(36, 170, 106, 0.22);
}

.app-toast-warning {
    border-color: rgba(195, 137, 34, 0.28);
}

.app-toast-error {
    border-color: rgba(220, 74, 74, 0.22);
}

.app-toast-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    background: rgba(17, 112, 230, 0.08);
    color: var(--accent-strong);
}

.app-toast-error .app-toast-icon {
    background: rgba(220, 74, 74, 0.08);
    color: #cc3c3c;
}

.app-toast-warning .app-toast-icon {
    background: rgba(195, 137, 34, 0.1);
    color: #a56d0d;
}

.app-toast-success .app-toast-icon {
    background: rgba(36, 170, 106, 0.1);
    color: #208858;
}

.app-toast-copy {
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    min-width: 0;
}

.app-toast-copy strong {
    color: var(--navy);
}

.app-toast-copy span {
    color: var(--navy-soft);
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.app-toast-close {
    border: 0;
    background: transparent;
    color: var(--navy-soft);
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

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

.order-card,
.recommendation-card,
.scanner-card,
.public-request-card,
.public-inquiry-form-card {
    position: relative;
}

.order-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
}

.metrics-pair {
    flex-wrap: wrap;
    margin: 1rem 0;
}

.metrics-pair div {
    min-width: 120px;
}

.metrics-pair dt {
    margin-bottom: 0.22rem;
    color: var(--text-soft);
    font-size: 0.8rem;
}

.metrics-pair dd {
    margin: 0;
    font-weight: 700;
    color: var(--navy);
}

.table-shell {
    min-width: 0;
    overflow-x: auto;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.54);
}

.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
}

.data-table thead th {
    padding: 1rem 0.9rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(232, 241, 255, 0.74);
    color: var(--text-soft);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-align: left;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
}

.data-table tbody td {
    padding: 0.95rem 0.9rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.1);
    vertical-align: top;
    min-width: 0;
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
}

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

.data-table tbody tr {
    transition: background-color 140ms ease;
}

.data-table tbody tr:hover {
    background: rgba(36, 165, 255, 0.06);
}

.workflow-table-row-selected td {
    background: rgba(36, 165, 255, 0.08);
}

.workflow-table-row-current td {
    background: rgba(118, 196, 255, 0.16);
}

.workflow-table-row-completed td {
    background: rgba(148, 162, 184, 0.12);
    color: rgba(59, 82, 120, 0.82);
}

.schedule-stack {
    gap: 1rem;
}

.list-card,
.operation-card,
.mini-card {
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-top: 1px solid rgba(91, 121, 170, 0.12);
}

.list-card:first-of-type,
.operation-card:first-of-type {
    border-top: 0;
    padding-top: 0;
}

.recommendation-top,
.recommendation-footer {
    align-items: center;
    justify-content: space-between;
}

.score-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-height: 3.3rem;
    padding: 0.55rem 0.85rem;
    border-radius: 0;
    background: linear-gradient(135deg, rgba(17, 112, 230, 0.14), rgba(24, 178, 176, 0.22));
    color: var(--navy);
    border: 1px solid rgba(109, 155, 225, 0.16);
    font-weight: 800;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.88);
    cursor: pointer;
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.score-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(28, 54, 96, 0.1);
}

.score-badge-arrow {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.92rem;
    line-height: 1;
}

.score-badge-value {
    font-size: 1.05rem;
    line-height: 1;
}

.score-badge-up .score-badge-arrow {
    color: #138a63;
    background: rgba(19, 138, 99, 0.14);
}

.score-badge-down .score-badge-arrow {
    color: #d45a74;
    background: rgba(212, 90, 116, 0.14);
}

.score-reason-box {
    margin-top: 0.85rem;
    padding: 0.8rem 0.95rem;
    border-radius: 0;
    border: 1px solid rgba(109, 155, 225, 0.16);
    background: linear-gradient(180deg, rgba(248, 251, 255, 0.96), rgba(236, 244, 255, 0.88));
    color: var(--navy-soft);
}

.score-reason-box strong {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--navy);
}

.score-reason-list {
    display: grid;
    gap: 0.55rem;
}

.score-reason-item {
    display: grid;
    grid-template-columns: minmax(8.5rem, 10rem) minmax(0, 1fr);
    gap: 0.7rem;
    align-items: start;
    padding: 0.45rem 0;
    border-top: 1px solid rgba(109, 155, 225, 0.12);
}

.score-reason-item:first-child {
    border-top: 0;
}

.score-reason-label {
    color: var(--text-soft);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.score-reason-value {
    color: var(--navy);
    font-weight: 600;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.score-reason-summary {
    margin: 0.7rem 0 0;
    padding-top: 0.7rem;
    border-top: 1px solid rgba(109, 155, 225, 0.16);
    color: var(--navy-soft);
    font-weight: 600;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.score-reason-box p {
    margin: 0;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.scheduling-recommendations-card .section-title-row {
    margin-bottom: 1rem;
}

.scheduling-recommendations-card .section-title-row .muted {
    max-width: 70ch;
    margin: 0.3rem 0 0;
}

.schedule-recommendation-list {
    display: grid;
    gap: 0.75rem;
}

.schedule-recommendation-card {
    min-width: 0;
    overflow: hidden;
    border: 1px solid rgba(82, 112, 127, 0.14);
    border-radius: 1rem;
    background: rgba(247, 249, 248, 0.82);
    box-shadow:
        0 3px 10px rgba(35, 62, 76, 0.07),
        inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.schedule-recommendation-card-open {
    border-color: rgba(39, 95, 200, 0.22);
}

.schedule-recommendation-summary {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 0.9rem;
    align-items: center;
    padding: 0.9rem 1rem;
}

.schedule-recommendation-rank {
    display: inline-grid;
    place-items: center;
    width: 2.15rem;
    height: 2.15rem;
    border: 1px solid rgba(39, 95, 200, 0.16);
    border-radius: 0.7rem;
    background: rgba(39, 95, 200, 0.08);
    color: var(--navy);
    font-size: 0.84rem;
    font-weight: 800;
}

.schedule-recommendation-identity {
    min-width: 0;
}

.schedule-recommendation-identity .order-kicker {
    margin: 0 0 0.25rem;
}

.schedule-recommendation-identity h3 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.schedule-recommendation-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem 0.9rem;
    margin-top: 0.45rem;
    color: var(--text-soft);
    font-size: 0.82rem;
}

.schedule-recommendation-meta span + span {
    position: relative;
    padding-left: 0.9rem;
}

.schedule-recommendation-meta span + span::before {
    position: absolute;
    top: 50%;
    left: 0;
    width: 0.25rem;
    height: 0.25rem;
    border-radius: 50%;
    background: rgba(55, 83, 98, 0.46);
    content: "";
    transform: translateY(-50%);
}

.schedule-recommendation-score {
    display: grid;
    grid-template-columns: auto auto;
    gap: 0.15rem 0.5rem;
    min-width: 6.75rem;
    min-height: 3.65rem;
    padding: 0.5rem 0.7rem;
    border-radius: 0.75rem;
}

.schedule-recommendation-score-label {
    grid-column: 1 / -1;
    color: var(--text-soft);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    line-height: 1;
    text-transform: uppercase;
}

.schedule-recommendation-score-value {
    grid-column: 1 / -1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.schedule-recommendation-reason {
    width: auto;
    margin: 0;
    padding: 1rem;
    border-width: 1px 0 0;
    border-radius: 0;
}

.schedule-reason-heading {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.85rem;
}

.schedule-reason-heading strong {
    margin: 0.18rem 0 0;
    font-size: 1rem;
}

.schedule-reason-eyebrow {
    display: block;
    color: var(--text-soft);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.09em;
    text-transform: uppercase;
}

.schedule-reason-total {
    flex: 0 0 auto;
    padding: 0.38rem 0.65rem;
    border: 1px solid rgba(39, 95, 200, 0.15);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.52);
    color: var(--navy);
    font-size: 0.82rem;
    font-weight: 800;
}

.schedule-reason-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 13.5rem), 1fr));
    gap: 0.55rem;
    margin: 0;
}

.schedule-reason-grid .score-reason-item {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.3rem;
    min-width: 0;
    padding: 0.7rem 0.8rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    border-radius: 0.7rem;
    background: rgba(255, 255, 255, 0.48);
}

.schedule-reason-grid .score-reason-item:first-child {
    border-top: 1px solid rgba(91, 121, 170, 0.12);
}

.schedule-reason-grid .score-reason-value {
    margin: 0;
    line-height: 1.4;
}

.schedule-recommendation-reason .score-reason-summary {
    margin-top: 0.85rem;
    padding: 0.75rem 0.85rem 0;
}

.scheduling-recommendations-empty {
    display: grid;
    gap: 0.25rem;
    min-height: auto;
    padding: 1.2rem;
    text-align: left;
}

@media (max-width: 640px) {
    .schedule-recommendation-summary {
        grid-template-columns: auto minmax(0, 1fr);
        gap: 0.75rem;
    }

    .schedule-recommendation-score {
        grid-column: 1 / -1;
        grid-template-columns: auto auto;
        justify-content: center;
        width: 100%;
        min-height: 2.85rem;
    }

    .schedule-recommendation-score-label,
    .schedule-recommendation-score-value {
        grid-column: auto;
    }

    .schedule-recommendation-meta span {
        flex-basis: 100%;
    }

    .schedule-recommendation-meta span + span {
        padding-left: 0;
    }

    .schedule-recommendation-meta span + span::before {
        display: none;
    }

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

.progress-track {
    height: 0.76rem;
    margin: 1rem 0 0.9rem;
    border-radius: 0;
    background: rgba(91, 121, 170, 0.12);
    overflow: hidden;
}

.progress-track span {
    display: block;
    height: 100%;
    border-radius: 0;
    background: linear-gradient(90deg, var(--accent), var(--teal));
}

.scanner-grid {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.45fr);
    align-items: start;
}

.worksheet-scanner-grid {
    grid-template-columns: minmax(0, 44rem);
    justify-content: center;
    width: 100%;
}

.worksheet-scanner-card {
    width: 100%;
    max-width: 44rem;
    min-width: 0;
    justify-self: center;
}

.drawing-detail-card,
.drawing-preview-card {
    min-width: 0;
}

.drawing-kpi-chart {
    grid-template-columns: repeat(var(--drawing-card-columns, 4), minmax(0, 1fr));
    width: 100%;
    max-width: 100%;
    justify-self: stretch;
    gap: 0.45rem;
}

.drawing-kpi-chart .kpi-chart-column {
    grid-template-rows: minmax(3.8rem, 1fr) auto;
    align-items: stretch;
    overflow: visible;
}

.drawing-kpi-chart .kpi-chart-label {
    min-height: 2.35rem;
    font-size: clamp(0.66rem, 0.76vw, 0.78rem);
    line-height: 1.2;
    white-space: normal;
    overflow: hidden;
    text-overflow: clip;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.drawing-preview-card {
    display: grid;
    align-content: start;
    gap: 1rem;
}

.drawings-detail-modal-card {
    width: min(82rem, calc(100vw - 3rem));
}

.drawings-detail-modal-body {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
    overflow-x: hidden;
}

.drawings-detail-modal-body > *,
.drawing-detail-card,
.drawing-route-panel {
    min-width: 0;
}

.drawings-detail-modal-body code {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    white-space: nowrap;
    overflow-wrap: normal;
    word-break: normal;
}

.drawing-detail-overview-card {
    display: grid;
    gap: 1rem;
    min-width: 0;
    padding: clamp(1rem, 1.8vw, 1.35rem);
}

.drawing-detail-heading {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 1rem;
}

.drawing-detail-heading h2,
.drawing-detail-heading p,
.drawing-detail-context-card h3,
.drawing-detail-context-card p,
.drawing-detail-document-card h3,
.drawing-detail-document-card p,
.drawing-detail-qr-card h3,
.drawing-detail-qr-card p {
    margin: 0;
}

.drawing-detail-metadata {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.7rem;
    margin: 0;
}

.drawing-detail-metadata > div {
    min-width: 0;
    padding: 0.75rem 0.8rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.58);
}

.drawing-detail-metadata dd {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.drawing-detail-context-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
}

.drawing-detail-context-card {
    display: grid;
    align-content: start;
    gap: 0.45rem;
    min-width: 0;
    padding: 0.95rem 1rem;
}

.drawing-detail-context-card p,
.drawing-detail-document-card p {
    overflow-wrap: break-word;
    word-break: normal;
}

.drawing-detail-workflow-panel,
.drawing-detail-qr-panel,
.drawing-detail-documents {
    display: grid;
    gap: 0.75rem;
    min-width: 0;
    margin: 0;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.52);
}

.drawing-detail-actions {
    justify-content: flex-end;
    flex-wrap: wrap;
}

.drawing-detail-qr-card,
.drawing-detail-document-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 1rem;
    min-width: 0;
}

.drawing-detail-empty-state {
    margin: 0;
    padding: 0.9rem 1rem;
    border: 1px dashed rgba(91, 121, 170, 0.2);
    border-radius: var(--radius-md);
    background: rgba(238, 245, 255, 0.42);
}

.scanner-stage,
.drawing-preview-frame,
.drawing-preview-image {
    width: 100%;
    min-height: clamp(26rem, 58vh, 46rem);
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(236, 244, 255, 0.88));
}

.scanner-stage {
    overflow: hidden;
    position: relative;
}

.scanner-wait-placeholder {
    position: absolute;
    inset: clamp(0.75rem, 2vw, 1rem);
    z-index: 1;
    display: grid;
    place-items: center;
    padding: clamp(0.75rem, 2vw, 1.5rem);
    pointer-events: none;
}

.scanner-wait-image {
    width: min(100%, 22rem);
    max-width: 100%;
    max-height: 100%;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 18px 32px rgba(31, 76, 153, 0.18));
}

.scanner-stage-large {
    min-height: 360px;
}

.scanner-stage-compact {
    min-height: 220px;
}

.scanner-stage-compact .scanner-wait-image {
    width: min(100%, 12rem);
}

.scanner-stage-inner {
    width: 100%;
    min-height: inherit;
    height: 100%;
}

.scanner-stage::before {
    content: "";
    position: absolute;
    inset: 1rem;
    border-radius: 0;
    border: 1px dashed rgba(17, 112, 230, 0.24);
    pointer-events: none;
}

.scanner-stage video,
.drawing-preview-image {
    object-fit: contain;
}

.scanner-status-panel,
.drawing-route-panel {
    gap: 0.35rem;
    margin-top: 1rem;
    padding: 1rem 1.05rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.72);
}

.scanner-status-live {
    background:
        radial-gradient(circle at top right, rgba(26, 159, 112, 0.12), transparent 38%),
        rgba(255, 255, 255, 0.84);
    border-color: rgba(26, 159, 112, 0.2);
}

.scanner-status-idle {
    background:
        radial-gradient(circle at top right, rgba(36, 165, 255, 0.1), transparent 38%),
        rgba(255, 255, 255, 0.84);
}

.scanner-success-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: grid;
    place-items: center;
    gap: 0.75rem;
    color: #fff;
    text-align: center;
    background: linear-gradient(180deg, rgba(38, 119, 226, 0.78), rgba(36, 165, 255, 0.82));
    backdrop-filter: blur(4px);
}

.scanner-success-icon {
    display: inline-grid;
    place-items: center;
    width: 4.5rem;
    height: 4.5rem;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.18);
    border: 2px solid rgba(255, 255, 255, 0.88);
    font-size: 2rem;
    font-weight: 800;
}

.manual-entry {
    align-items: center;
    flex-wrap: wrap;
}

.scanner-control-row {
    margin-top: 1rem;
}

.scanner-camera-field {
    margin-top: 0.85rem;
}

.scanner-camera-hint,
.scanner-diagnostic {
    display: block;
}

.active-operations,
.checklist-stack,
.batch-list,
.document-stack {
    display: grid;
    gap: 0.75rem;
}

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

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

.field-label {
    gap: 0.45rem;
    font-weight: 600;
}

.field-input {
    width: 100%;
    min-height: 2.9rem;
    padding: 0.74rem 0.9rem;
    border: 1px solid rgba(91, 121, 170, 0.18);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.92);
    color: var(--text);
    box-sizing: border-box;
}

.field-input:focus {
    outline: 0;
    border-color: rgba(17, 112, 230, 0.38);
    box-shadow: 0 0 0 4px rgba(36, 165, 255, 0.12);
}

.specification-stack {
    display: grid;
    gap: 0.65rem;
}

.specification-row {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(140px, 0.7fr) auto;
    gap: 0.65rem;
    align-items: center;
}

.specification-add-button {
    justify-self: start;
}

.specification-remove-button {
    min-height: 2.9rem;
    white-space: nowrap;
}

.admin-quote-card-actions {
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.quote-line-editor-stack {
    display: grid;
    gap: 1rem;
    width: 100%;
}

.attachment-link-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 0.75rem;
}

.attachment-link-button {
    text-decoration: none;
}

.attachment-action-button {
    position: absolute;
    top: 0.9rem;
    z-index: 3;
    min-height: 2.35rem;
    padding: 0.55rem 0.9rem;
    right: 0.9rem;
    line-height: 1;
    pointer-events: auto;
}

.attachment-action-button-download {
    font-size: 0;
}

.attachment-action-button-download::after {
    content: "Letöltés";
    font-size: 0.94rem;
}

.attachment-static-label {
    display: inline-flex;
    align-items: center;
    min-height: 2.9rem;
    padding: 0.7rem 1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.18);
    background: rgba(255, 255, 255, 0.82);
    color: var(--navy-soft);
    font-weight: 600;
}

.attachment-action-button-download::after {
    content: "Let\00f6lt\00e9s";
}

.attachment-action-button-delete {
    right: 7.4rem;
}

.attachment-action-button-delete::after {
    content: "T\00f6rl\00e9s";
    font-size: 0.94rem;
}

.table-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin: 1rem 0 1.25rem;
}

.admin-workflow-toolbar {
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.admin-workflow-all-panel {
    margin-top: -0.25rem;
}

.admin-workflow-header-actions {
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.table-filter-field {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    min-width: 0;
    font-weight: 600;
    color: var(--text-soft);
}

.segmented-selector,
.table-row-count-selector {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 0.35rem;
    padding: 0.35rem;
    border: 1px solid rgba(91, 121, 170, 0.18);
    border-radius: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(236, 243, 255, 0.88));
    box-shadow: 0 10px 22px rgba(18, 35, 61, 0.06);
}

.segmented-selector-compact,
.table-row-count-selector {
    flex-wrap: nowrap;
}

.segmented-selector-button,
.table-row-count-button {
    appearance: none;
    min-width: 3rem;
    min-height: 2.4rem;
    padding: 0.55rem 0.9rem;
    border: 1px solid rgba(91, 121, 170, 0.16);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.84);
    color: var(--navy-soft);
    font: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition:
        transform 140ms ease,
        box-shadow 140ms ease,
        background-color 140ms ease,
        border-color 140ms ease,
        color 140ms ease;
}

.segmented-selector-button,
.table-row-count-button {
    white-space: nowrap;
}

.segmented-selector-button:hover,
.table-row-count-button:hover {
    transform: translateY(-1px);
    border-color: rgba(17, 112, 230, 0.22);
    background: rgba(245, 250, 255, 0.96);
    box-shadow: var(--shadow-md);
}

.segmented-selector-button:focus-visible,
.table-row-count-button:focus-visible {
    outline: 2px solid rgba(17, 112, 230, 0.22);
    outline-offset: 0;
    position: relative;
    z-index: 1;
}

.segmented-selector-button-active,
.table-row-count-button-active {
    border-color: rgba(17, 112, 230, 0.28);
    background: linear-gradient(135deg, rgba(17, 112, 230, 0.96), rgba(36, 165, 255, 0.94));
    color: #ffffff;
    font-weight: 700;
    box-shadow: 0 12px 22px rgba(17, 112, 230, 0.22);
}

.segmented-selector-button-active:hover,
.table-row-count-button-active:hover {
    border-color: rgba(17, 112, 230, 0.34);
    background: linear-gradient(135deg, rgba(15, 101, 208, 0.98), rgba(31, 154, 255, 0.96));
    color: #ffffff;
}

.dashboard-segmented-filter {
    justify-content: flex-end;
    max-width: min(100%, 36rem);
}

.table-range-stack {
    display: flex;
    align-items: center;
    gap: 1rem;
    min-height: 2.9rem;
}

.table-range-stack-compact {
    align-items: center;
    gap: 0.7rem;
    flex-wrap: nowrap;
}

.table-range-stack-compact > .table-range-input,
.table-range-stack-compact > .table-range-bound {
    align-self: center;
}

.table-range-input {
    width: 100%;
    flex: 1 1 14rem;
    min-width: 10rem;
    accent-color: var(--accent);
}

.table-range-bound {
    display: grid;
    gap: 0.35rem;
    min-width: 8.5rem;
    align-content: center;
}

.table-range-bound-inline {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
}

.table-range-number {
    min-width: 0;
    font-variant-numeric: tabular-nums;
    width: 100%;
}

.table-range-inline-label {
    color: var(--text-soft);
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.table-filter-field-range {
    min-width: min(100%, 36rem);
    align-self: end;
}

.related-quote-filter-grid .table-filter-field-range {
    min-width: 0;
    align-self: stretch;
}

.related-quote-range-stack {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 1fr);
    align-items: center;
    gap: 0.75rem;
}

.related-quote-range-stack > .table-range-input,
.related-quote-range-stack > .table-range-bound {
    min-width: 0;
    width: 100%;
}

.table-empty-state {
    padding: 1rem;
    text-align: center;
    color: var(--text-soft);
    font-weight: 600;
}

.text-area {
    min-height: 120px;
    resize: vertical;
}

.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;
}

.upload-dropzone {
    position: relative;
    display: grid;
    gap: 0.55rem;
    padding: 1rem 1.05rem;
    border-radius: 0;
    border: 1px dashed rgba(17, 112, 230, 0.34);
    background:
        radial-gradient(circle at top right, rgba(36, 165, 255, 0.1), transparent 36%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(237, 244, 255, 0.9));
    color: var(--navy);
}

.recommendation-card-expandable {
    cursor: pointer;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.recommendation-card-expandable:hover {
    transform: translateY(-2px);
    border-color: rgba(36, 165, 255, 0.18);
}

.recommendation-card-open {
    border-color: rgba(36, 165, 255, 0.24);
    box-shadow: 0 20px 48px rgba(37, 64, 107, 0.14);
}

.recommendation-detail-shell,
.recommendation-detail-layout,
.recommendation-tree,
.recommendation-side-stack,
.recommendation-node-copy {
    display: grid;
    gap: 1rem;
}

.recommendation-detail-shell {
    margin-top: 1.2rem;
    padding-top: 1.2rem;
    border-top: 1px solid rgba(91, 121, 170, 0.12);
}

.recommendation-detail-layout {
    grid-template-columns: 1fr;
    align-items: start;
}

.recommendation-tree {
    position: relative;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(10.75rem, 1fr));
    overflow: visible;
    align-items: stretch;
    gap: 1.4rem 1.2rem;
    padding: 0.4rem 0 0.75rem;
}

.recommendation-tree-checkpoints {
    grid-template-columns: repeat(auto-fit, minmax(10.75rem, 1fr));
    gap: 1.4rem 1.2rem;
    align-items: start;
}

.recommendation-tree::before {
    content: none;
}

.recommendation-tree-node {
    position: relative;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.8rem;
    align-items: start;
    min-height: 100%;
    padding: 1rem 1.1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.72);
}

.recommendation-checkpoint-node {
    position: relative;
    gap: 0.75rem;
    justify-items: center;
    padding: 0.15rem 0.15rem 0.25rem;
    border: 0;
    background: transparent;
    box-shadow: none;
    text-align: center;
}

.recommendation-checkpoint-node::before {
    content: "";
    position: absolute;
    top: 2.35rem;
    left: -0.7rem;
    right: -0.7rem;
    height: 2px;
    background: linear-gradient(90deg, rgba(87, 150, 255, 0.2), rgba(36, 165, 255, 0.35), rgba(24, 178, 176, 0.2));
    z-index: 0;
}

.recommendation-checkpoint-node:first-child::before {
    left: 50%;
}

.recommendation-checkpoint-node:last-child::before {
    right: 50%;
}

.recommendation-checkpoint-circle {
    position: relative;
    z-index: 1;
    width: 4.75rem;
    height: 4.75rem;
    border-radius: 0;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    box-shadow: 0 16px 28px rgba(28, 54, 96, 0.16);
}

.recommendation-checkpoint-node .recommendation-node-copy {
    display: grid;
    justify-items: center;
    text-align: center;
    gap: 0.65rem;
    min-height: 10.75rem;
    width: 100%;
    padding: 0.85rem 0.8rem 0.95rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(243, 248, 255, 0.9));
    box-shadow: 0 12px 24px rgba(28, 54, 96, 0.08);
}

.recommendation-checkpoint-node .section-title-row {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
    gap: 0.55rem;
}

.recommendation-checkpoint-node .checkpoint-marker {
    display: none;
}

.recommendation-checkpoint-node.checkpoint-pending .recommendation-checkpoint-circle {
    background: linear-gradient(180deg, rgba(36, 165, 255, 0.96), rgba(17, 112, 230, 0.88));
}

.recommendation-checkpoint-node.checkpoint-complete .recommendation-checkpoint-circle {
    background: linear-gradient(180deg, rgba(26, 159, 112, 0.96), rgba(15, 121, 85, 0.9));
}

.recommendation-checkpoint-node.checkpoint-neutral .recommendation-checkpoint-circle {
    background: linear-gradient(180deg, rgba(125, 143, 173, 0.94), rgba(91, 121, 170, 0.84));
}

.recommendation-tree-node .checkpoint-marker {
    width: 1.05rem;
    height: 1.05rem;
    border-radius: 0;
    margin: 0 0 0.1rem 0.15rem;
    background: rgba(118, 196, 255, 0.44);
    border: 3px solid rgba(255, 255, 255, 0.96);
    box-shadow: 0 0 0 1px rgba(87, 150, 255, 0.18);
    position: relative;
    z-index: 1;
}

.recommendation-checkpoint-node h3 {
    margin: 0;
    font-size: 0.98rem;
    line-height: 1.2;
    text-wrap: balance;
}

.recommendation-checkpoint-node .operation-meta,
.recommendation-checkpoint-node .muted {
    margin: 0;
}

.recommendation-checkpoint-node .muted {
    max-width: 20ch;
    font-size: 0.82rem;
    line-height: 1.45;
    text-wrap: pretty;
}

.recommendation-checkpoint-node .operation-meta {
    font-size: 0.74rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.recommendation-highlight-row {
    flex-wrap: wrap;
    justify-content: center;
}

.recommendation-checkpoint-node .detail-chip {
    justify-content: center;
    text-align: center;
}

.recommendation-checkpoint-node.checkpoint-complete,
.recommendation-checkpoint-node.checkpoint-pending,
.recommendation-checkpoint-node.checkpoint-neutral {
    background: transparent;
    box-shadow: none;
}

.recommendation-checkpoint-node.checkpoint-complete .recommendation-node-copy,
.recommendation-checkpoint-node.checkpoint-complete .muted,
.recommendation-checkpoint-node.checkpoint-complete .operation-meta,
.recommendation-checkpoint-node.checkpoint-complete h3,
.recommendation-checkpoint-node.checkpoint-complete .detail-chip {
    color: var(--text);
}

.recommendation-checkpoint-node.checkpoint-complete .recommendation-node-copy {
    border-color: rgba(26, 159, 112, 0.16);
    background: linear-gradient(180deg, rgba(240, 251, 246, 0.98), rgba(228, 247, 238, 0.92));
}

.recommendation-checkpoint-node.checkpoint-pending .recommendation-node-copy {
    border-color: rgba(36, 165, 255, 0.18);
    background: linear-gradient(180deg, rgba(239, 248, 255, 0.98), rgba(227, 240, 255, 0.92));
}

.recommendation-checkpoint-node.checkpoint-neutral .recommendation-node-copy {
    background: linear-gradient(180deg, rgba(252, 254, 255, 0.98), rgba(242, 247, 255, 0.92));
}

.checkpoint-complete {
    background: rgba(240, 251, 246, 0.92);
    border-color: rgba(26, 159, 112, 0.18);
}

.checkpoint-complete .checkpoint-marker {
    background: rgba(26, 159, 112, 0.78);
}

.checkpoint-pending {
    background: rgba(233, 246, 255, 0.96);
    border-color: rgba(36, 165, 255, 0.2);
}

.checkpoint-pending .checkpoint-marker {
    background: rgba(36, 165, 255, 0.84);
}

.checkpoint-neutral {
    background: rgba(250, 252, 255, 0.9);
}

.recommendation-highlight-row {
    flex-wrap: wrap;
}

.recommendation-side-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
}

.recommendation-side-stack > .glass-card {
    gap: 1rem;
}

.upload-dropzone strong {
    color: var(--navy);
}

.upload-dropzone span {
    color: var(--text-soft);
}

.upload-dropzone input[type="file"] {
    padding: 0.55rem 0.7rem;
}

.photo-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    margin-top: 1rem;
}

.photo-card {
    display: grid;
    gap: 0.65rem;
    padding: 0.8rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.76);
}

.photo-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 0;
    object-fit: cover;
    background: rgba(220, 230, 245, 0.55);
}

.photo-card {
    position: relative;
    overflow: hidden;
    padding: 0;
    min-height: 220px;
}

.photo-card > img,
.photo-card > .photo-card-pdf-preview,
.photo-card > .photo-card-file-fallback,
.photo-card > .photo-card-media {
    grid-area: 1 / 1;
}

.photo-card > img,
.photo-card > .photo-card-pdf-preview,
.photo-card > .photo-card-file-fallback {
    width: 100%;
    height: 100%;
    min-height: 220px;
    border-radius: 0;
}

.photo-card-file-fallback {
    display: grid;
    place-items: center;
    background:
        linear-gradient(145deg, rgba(16, 35, 63, 0.88), rgba(46, 70, 107, 0.82)),
        linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
    color: #fff;
    font-size: 1.5rem;
    letter-spacing: 0.16em;
}

.photo-card-pdf-preview {
    border: 0;
    background: #fff;
}

.photo-card-media {
    position: relative;
    display: grid;
    align-content: end;
    gap: 0.22rem;
    min-height: 220px;
    padding: 1rem;
    background: linear-gradient(180deg, rgba(7, 17, 31, 0.04) 14%, rgba(7, 17, 31, 0.78) 100%);
    pointer-events: none;
}

.photo-card-media > strong,
.photo-card-media > span {
    max-width: calc(100% - 10rem);
    color: #fff;
    text-shadow: 0 2px 10px rgba(7, 17, 31, 0.45);
}

.photo-card-media > strong {
    font-size: 0.96rem;
    font-weight: 800;
}

.photo-card-media > span {
    font-size: 0.84rem;
    color: rgba(255, 255, 255, 0.84);
}

.photo-card .attachment-action-button {
    pointer-events: auto;
}

.photo-card-loading {
    min-height: 220px;
}

.photo-card-media-loading {
    align-content: center;
    justify-items: center;
    gap: 0.85rem;
    background:
        linear-gradient(135deg, rgba(229, 238, 252, 0.96), rgba(242, 248, 255, 0.96)),
        linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.62) 50%, rgba(255, 255, 255, 0) 100%);
    background-size: auto, 220% 100%;
    animation: photo-card-loading-sweep 1.8s ease-in-out infinite;
}

.photo-card-loading-shell {
    display: grid;
    justify-items: center;
    gap: 0.7rem;
}

.photo-card-loading-spinner {
    width: 2.5rem;
    height: 2.5rem;
    border: 3px solid rgba(17, 112, 230, 0.16);
    border-top-color: rgba(17, 112, 230, 0.82);
    border-radius: 0;
    animation: photo-card-spin 0.9s linear infinite;
}

.photo-card-loading-text {
    color: var(--navy-soft);
    font-weight: 700;
}

.photo-card-loading .photo-card-meta,
.photo-card-loading .photo-card-meta strong,
.photo-card-loading .photo-card-meta span {
    color: var(--navy);
    text-shadow: none;
}

@keyframes photo-card-loading-sweep {
    0% {
        background-position: 0 0, 120% 0;
    }

    100% {
        background-position: 0 0, -120% 0;
    }
}

@keyframes photo-card-spin {
    to {
        transform: rotate(360deg);
    }
}

.workflow-accent-card-success {
    border-color: rgba(26, 159, 112, 0.24);
    background: linear-gradient(180deg, rgba(243, 255, 249, 0.96), rgba(224, 248, 237, 0.92));
    box-shadow: 0 18px 36px rgba(26, 159, 112, 0.12);
}

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

.public-request-card {
    margin-top: 1rem;
}

.public-item-card-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1rem;
}

.public-item-card {
    cursor: default;
    min-height: 0;
    grid-template-rows: auto auto auto;
    align-content: start;
}

.public-item-card:hover {
    transform: none;
    box-shadow: var(--shadow-sm);
}

.public-item-card-head,
.public-item-card-meta-row {
    width: 100%;
}

.public-item-card-meta-row {
    flex-wrap: wrap;
    row-gap: 0.55rem;
}

.public-item-card-body,
.public-item-file-stack,
.public-item-deficiency-panel {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
}

.public-item-metrics {
    grid-template-columns: 1fr;
}

.public-item-metrics dt,
.public-item-metrics dd,
.public-item-spec-card strong,
.public-item-spec-card span,
.public-item-deficiency-callout span,
.public-item-deficiency-callout strong {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.public-item-spec-list {
    display: grid;
    gap: 0.65rem;
}

.public-item-spec-card {
    display: grid;
    gap: 0.2rem;
    padding: 0.8rem 0.9rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.76);
}

.public-item-spec-label {
    color: var(--text-soft);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.public-item-deficiency-callout {
    gap: 0.45rem;
    padding: 0.95rem 1rem;
}

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

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

.checkpoint-marker {
    width: 14px;
    height: 14px;
    margin-top: 0.58rem;
    border-radius: 0;
    background: rgba(91, 121, 170, 0.18);
    box-shadow: inset 0 0 0 1px rgba(91, 121, 170, 0.18);
}

.checkpoint-complete {
    background: linear-gradient(180deg, rgba(26, 159, 112, 0.95), rgba(15, 121, 85, 0.92));
    box-shadow: 0 0 0 5px rgba(26, 159, 112, 0.12);
}

.recommendation-tree-node.checkpoint-complete,
.recommendation-tree-node.checkpoint-complete h3,
.recommendation-tree-node.checkpoint-complete .muted,
.recommendation-tree-node.checkpoint-complete .operation-meta,
.recommendation-tree-node.checkpoint-complete .detail-chip {
    color: #fff;
}

.recommendation-tree-node.checkpoint-complete .detail-chip {
    border-color: rgba(255, 255, 255, 0.28);
    background: rgba(255, 255, 255, 0.14);
}

.recommendation-tree-node.checkpoint-complete .status-pill.status-good,
.recommendation-tree-node.checkpoint-complete .status-pill.status-good::before {
    color: #fff;
}

.recommendation-tree-node.checkpoint-complete .status-pill.status-good {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.22);
}

.checkpoint-pending {
    background: linear-gradient(180deg, rgba(104, 128, 166, 0.48), rgba(91, 121, 170, 0.24));
}

.recommendation-checkpoint-node.checkpoint-complete,
.recommendation-checkpoint-node.checkpoint-pending,
.recommendation-checkpoint-node.checkpoint-neutral {
    background: transparent;
    border-color: transparent;
    box-shadow: none;
}

.recommendation-checkpoint-node.checkpoint-complete h3,
.recommendation-checkpoint-node.checkpoint-complete .muted,
.recommendation-checkpoint-node.checkpoint-complete .operation-meta,
.recommendation-checkpoint-node.checkpoint-complete .detail-chip {
    color: var(--text);
}

.drawing-preview-frame {
    height: clamp(26rem, 58vh, 46rem);
    overflow: hidden;
}

.drawing-preview-image {
    height: clamp(26rem, 58vh, 46rem);
    padding: 0.4rem;
}

.mini-card {
    padding: 0.95rem 1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.74);
}

.role-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-top: 1rem;
}

.worksheet-scan-shell,
.worksheet-active-shell,
.worksheet-active-grid,
.worksheet-route-stack,
.event-filter-bar {
    display: grid;
    gap: 1rem;
}

.worksheet-active-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
    align-items: start;
}

.worksheet-drawing-frame,
.worksheet-drawing-image {
    width: 100%;
    min-height: 420px;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(236, 244, 255, 0.88));
}

.worksheet-drawing-image {
    object-fit: contain;
    padding: 0.4rem;
}

.worksheet-stopwatch {
    display: grid;
    justify-items: end;
    gap: 0.2rem;
}

.worksheet-stopwatch span {
    color: var(--text-soft);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.worksheet-stopwatch strong {
    font-size: clamp(1.8rem, 4vw, 3rem);
    color: var(--navy);
    line-height: 1;
}

.worksheet-route-card,
.checklist-card {
    padding: 1rem 1.1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.74);
}

.worksheet-route-current {
    background: rgba(118, 196, 255, 0.18);
    border-color: rgba(36, 165, 255, 0.22);
}

.worksheet-route-ready {
    background: rgba(236, 246, 255, 0.92);
}

.worksheet-route-completed {
    background: rgba(148, 162, 184, 0.14);
    color: rgba(59, 82, 120, 0.82);
}

.worksheet-route-planned {
    background: rgba(251, 253, 255, 0.88);
}

.worksheet-operation-scan-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.worksheet-operation-hint {
    flex: 1 0 100%;
    max-width: 52ch;
    margin: 0;
}

.worksheet-operation-qr-modal {
    width: min(44rem, calc(100vw - 3rem));
    max-height: calc(100dvh - 3rem);
}

.worksheet-operation-qr-modal-body {
    max-height: calc(100dvh - 10rem);
}

.worksheet-operation-qr-target {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem 1rem;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: rgba(238, 245, 255, 0.58);
}

.worksheet-operation-qr-target > div {
    display: grid;
    gap: 0.2rem;
    min-width: 0;
}

.worksheet-operation-qr-target > p {
    grid-column: 1 / -1;
    margin: 0;
}

.scanner-stage-operation {
    min-height: clamp(15rem, 38vh, 24rem);
}

.checklist-card-complete {
    background: rgba(231, 248, 239, 0.92);
    border-color: rgba(26, 159, 112, 0.22);
}

.worksheet-finish-row {
    margin-top: 0.75rem;
    justify-content: flex-end;
}

.worksheet-finish-button {
    min-width: 14rem;
}

.event-filter-bar {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.event-list-scroll {
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 0.35rem;
}

.event-list,
.plain-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.event-list li {
    gap: 0.24rem;
    padding: 1rem 0;
    border-top: 1px solid rgba(91, 121, 170, 0.12);
}

.event-list li:first-child {
    padding-top: 0;
    border-top: 0;
}

.faq-item {
    overflow: hidden;
    border-radius: 0;
}

.faq-item summary {
    cursor: pointer;
    list-style: none;
    padding: 1rem 1.15rem;
    font-weight: 700;
    color: var(--navy);
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item[open] summary {
    background: rgba(232, 241, 255, 0.5);
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
}

.faq-body {
    padding: 1rem 1.15rem 1.15rem;
}

.faq-list {
    display: grid;
    gap: 0.42rem;
}

.faq-list li {
    position: relative;
    padding-left: 1rem;
}

.faq-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.66rem;
    width: 0.36rem;
    height: 0.36rem;
    border-radius: 0;
    background: var(--accent);
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    padding: 0.44rem 0.78rem;
    border-radius: 0;
    font-size: 0.8rem;
    font-weight: 700;
    border: 1px solid transparent;
}

.status-pill::before {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 0.9rem;
    height: 0.9rem;
    font: var(--fa-font-solid);
    font-size: 0.72rem;
    line-height: 1;
    color: currentColor;
    opacity: 0.92;
}

.status-neutral {
    color: var(--navy-soft);
    background: rgba(91, 121, 170, 0.12);
}

.status-neutral::before {
    content: none;
}

.request-asset-collection {
    display: grid;
    gap: 0.75rem;
    min-width: 0;
    padding: 0.9rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: rgba(242, 247, 249, 0.74);
}

.request-asset-collection-header,
.request-asset-row,
.planning-duration-input {
    display: grid;
    min-width: 0;
}

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

.request-asset-collection-header :is(h4, p) {
    margin: 0;
}

.request-asset-collection-header p {
    margin-top: 0.2rem;
}

.request-asset-list {
    display: grid;
    gap: 0.55rem;
}

.request-asset-row {
    grid-template-columns: 3.4rem minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.8rem;
    padding: 0.7rem 0.8rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    background: rgba(255, 255, 255, 0.72);
}

.request-asset-type {
    display: grid;
    place-items: center;
    min-height: 2.6rem;
    color: var(--navy);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    border-right: 1px solid rgba(91, 121, 170, 0.18);
}

.request-asset-details {
    display: grid;
    gap: 0.2rem;
    min-width: 0;
}

.request-asset-details > strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.request-asset-details > span:not(.status-pill) {
    color: var(--text-soft);
    font-size: 0.82rem;
    overflow-wrap: anywhere;
}

.request-asset-details .status-pill {
    width: max-content;
}

.request-asset-actions {
    flex-wrap: nowrap;
    justify-content: flex-end;
}

.request-asset-action {
    white-space: nowrap;
    text-decoration: none;
}

.request-asset-empty {
    margin: 0;
    padding: 0.75rem;
    color: var(--text-soft);
    border: 1px dashed rgba(91, 121, 170, 0.2);
}

.executive-review-line-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.6rem 1rem;
    margin: 0;
    padding: 0.75rem 0.85rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    background: rgba(255, 255, 255, 0.54);
}

.executive-review-line-facts > div {
    display: grid;
    gap: 0.18rem;
    min-width: 0;
}

.executive-review-line-facts dt {
    color: var(--text-soft);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.executive-review-line-facts dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.executive-review-line-fact-wide {
    grid-column: 1 / -1;
}

.planning-duration-input {
    grid-template-columns: minmax(0, 1fr) minmax(5.5rem, 0.42fr);
    gap: 0.45rem;
}

.planning-duration-unit {
    min-width: 0;
}

.planning-duration-output {
    display: flex;
    align-items: center;
    min-height: 2.8rem;
}

.status-sent::before {
    content: "\f1d8";
}

.status-progress {
    color: var(--accent-strong);
    background: rgba(36, 165, 255, 0.14);
}

.status-progress::before {
    content: "\f017";
}

.status-ready,
.status-running {
    gap: 0.5rem;
}

.status-ready::before,
.status-running::before {
    content: none;
    display: none;
}

.status-ready {
    color: #0f73d8;
    background: linear-gradient(180deg, rgba(223, 240, 255, 0.98), rgba(203, 230, 255, 0.92));
    border-color: rgba(36, 165, 255, 0.28);
}

.status-running {
    color: var(--accent-strong);
    background: rgba(36, 165, 255, 0.14);
}

.status-pill-arrows {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 0.95rem;
    height: 0.95rem;
    font-size: 0.82rem;
}

.status-pill-arrows > i {
    display: inline-block;
    opacity: 0.9;
    animation: status-ready-arrow 1.1s ease-in-out infinite;
}

.status-pill-gear {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 0.95rem;
    height: 0.95rem;
    animation: status-pill-gear-spin 1.35s linear infinite;
    transform-origin: center;
}

.status-good {
    color: var(--good);
    background: rgba(26, 159, 112, 0.14);
}

.status-good::before {
    content: "\f164";
}

.status-warn {
    color: var(--warn);
    background: rgba(195, 137, 34, 0.16);
}

.status-warn::before {
    content: "\f071";
}

.status-info {
    color: var(--accent-strong);
    background: rgba(17, 112, 230, 0.12);
}

@keyframes status-ready-arrow {
    0%,
    100% {
        opacity: 0.25;
        transform: translateX(-0.08rem);
    }

    50% {
        opacity: 1;
        transform: translateX(0.08rem);
    }
}

@keyframes status-pill-gear-spin {
    to {
        transform: rotate(360deg);
    }
}

.status-info::before {
    content: "\f059";
}

.status-danger {
    color: var(--danger);
    background: rgba(216, 91, 114, 0.14);
}

.status-danger::before {
    content: "\f0f3";
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 0;
    font-size: clamp(2rem, 2.8vw, 2.8rem);
}

h2 {
    margin-bottom: 0.22rem;
    font-size: clamp(1.34rem, 2vw, 1.7rem);
}

h3 {
    margin-bottom: 0.2rem;
    font-size: 1.02rem;
}

.blazor-error-boundary {
    display: none;
}

#blazor-error-ui {
    display: none;
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 1000;
    padding: 1rem 1.2rem;
    border-radius: 0;
    background: rgba(142, 28, 49, 0.94);
    color: white;
}

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

    .page.page-sidebar-closed,
    .page.page-sidebar-open {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        width: min(20rem, calc(100vw - 1.5rem));
        height: 100vh;
        min-height: 100vh;
        border-right: 1px solid rgba(91, 121, 170, 0.12);
        border-bottom: 0;
        box-shadow: 0 24px 48px rgba(28, 54, 96, 0.18);
    }

    .sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        border: 0;
        background: rgba(16, 35, 63, 0.18);
        backdrop-filter: blur(2px);
        z-index: 230;
    }

    .topbar-utility {
        flex-direction: column;
        align-items: stretch;
    }

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

    .notification-card {
        grid-column: span 2;
    }

    .content-grid,
    .scanner-grid,
    .warehouse-summary-grid,
    .operations-secondary-grid,
    .help-grid,
    .module-grid,
    .module-matrix,
    .module-matrix-wide,
    .page-header,
    .dashboard-section-heading,
    .dashboard-table-toolbar,
    .form-grid {
        grid-template-columns: 1fr;
    }

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

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

    .entry-role-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .dashboard-filter-group-inline {
        justify-items: start;
    }

    .dashboard-filter-group-inline .filter-bar {
        justify-content: flex-start;
    }

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

    .quote-line-card {
        border-left: 6px solid rgba(17, 112, 230, 0.78);
        padding-left: 1rem;
    }

    .related-quote-range-stack {
        grid-template-columns: 1fr;
    }

    .related-quote-range-stack .table-range-bound-inline {
        justify-content: space-between;
    }

    .dashboard-summary-toggle {
        display: inline-flex;
    }

    .dashboard-section-heading {
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: start;
        gap: 0.85rem;
    }

    .dashboard-summary-actions {
        justify-content: flex-end;
        align-items: center;
        flex-wrap: nowrap;
    }

    .dashboard-summary-actions .dashboard-select-filter {
        min-width: min(100%, 10.5rem);
    }

    .table-shell {
        overflow: visible;
        border: 0;
        background: transparent;
    }

    .data-table {
        display: block;
        table-layout: auto;
    }

    .data-table thead {
        display: none;
    }

    .data-table tbody {
        display: grid;
        gap: 0.85rem;
    }

    .data-table tbody tr {
        display: grid;
        gap: 0;
        border: 1px solid rgba(91, 121, 170, 0.12);
        border-left: 4px solid rgba(142, 196, 255, 0.78);
        border-radius: 0;
        background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(237, 244, 255, 0.88));
        box-shadow: var(--shadow-md);
        overflow: hidden;
    }

    .data-table tbody tr.dashboard-row-current,
    .data-table tbody tr.data-row-clickable,
    .data-table tbody tr.workflow-table-row-selected,
    .data-table tbody tr.workflow-table-row-completed {
        border-left-color: rgba(106, 174, 247, 0.96);
    }

    .data-table tbody td {
        display: grid;
        grid-template-columns: minmax(8rem, 38%) minmax(0, 1fr);
        gap: 0.8rem;
        align-items: start;
        min-width: 0;
        padding: 0.7rem 1rem;
        border-bottom: 1px solid rgba(91, 121, 170, 0.1);
        overflow-wrap: anywhere;
    }

    .data-table tbody td::before {
        content: attr(data-label);
        color: var(--text-soft);
        font-size: 0.74rem;
        font-weight: 800;
        letter-spacing: 0.08em;
        text-transform: uppercase;
    }

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

    .data-table tbody td[colspan] {
        grid-template-columns: 1fr;
    }

    .data-table tbody td[colspan]::before,
    .data-table tbody td[data-label=""]::before {
        content: none;
    }
}

@media (max-width: 900px) {
    .entry-brand-block,
    .entry-hero-main,
    .entry-role-grid {
        grid-template-columns: 1fr;
    }

    .help-grid,
    .order-grid {
        grid-template-columns: 1fr;
    }

    .entry-logo-shell {
        min-height: 92px;
    }

    .section-title-row,
    .page-header,
    .button-row,
    .header-actions,
    .manual-entry,
    .recommendation-footer,
    .list-card,
    .operation-card,
    .mini-card {
        flex-direction: column;
        align-items: stretch;
    }

    .dashboard-card-value-row {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .table-range-stack-compact {
        flex-direction: column;
        align-items: stretch;
        flex-wrap: wrap;
    }

    .table-range-bound {
        min-width: 100%;
    }

    .table-range-bound-inline {
        justify-content: space-between;
    }

    .related-quote-range-stack {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .related-quote-range-stack .table-range-input {
        order: 3;
    }

    .drawer-order-detail-header,
    .drawer-order-part-header,
    .drawer-order-step-row {
        flex-direction: column;
        align-items: stretch;
    }

    .drawer-order-detail-header > .button-row,
    .drawer-order-part-header > .status-pill,
    .drawer-order-step-row > .status-pill,
    .drawer-status-trigger {
        align-self: flex-start;
    }

    .review-comment-modal-card {
        width: min(calc(100vw - 2rem), 32rem);
        max-width: calc(100vw - 2rem);
        max-height: calc(100vh - 2rem - env(safe-area-inset-top, 0px));
    }

    .review-comment-panel-body {
        max-height: calc(100vh - 20rem);
    }

    .worksheet-operation-qr-modal-body {
        max-height: calc(100dvh - 11rem);
    }

    .worksheet-operation-qr-target {
        grid-template-columns: 1fr;
    }

    .worksheet-operation-qr-target > p {
        grid-column: auto;
    }

    .drawer-order-part-card,
    .checkpoint-card {
        gap: 0.75rem;
    }

}

.mini-card.scheduler-event-card,
.mini-card.scheduler-project-comment-card {
    position: relative;
    overflow: hidden;
    border-width: 1px;
    border-style: solid;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

.mini-card.scheduler-event-card::before,
.mini-card.scheduler-project-comment-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 0.35rem;
    border-radius: 0;
}

.mini-card.scheduler-event-card {
    background: linear-gradient(180deg, rgba(223, 255, 228, 0.98), rgba(209, 249, 216, 0.95));
    border-color: rgba(91, 190, 108, 0.4);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.62),
        0 10px 22px rgba(118, 196, 127, 0.12);
}

.mini-card.scheduler-event-card::before {
    background: linear-gradient(180deg, rgba(78, 171, 98, 0.96), rgba(124, 207, 139, 0.96));
}

.mini-card.scheduler-project-comment-card {
    background: linear-gradient(180deg, rgba(255, 251, 197, 0.99), rgba(255, 245, 166, 0.96));
    border-color: rgba(225, 196, 74, 0.42);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.62),
        0 10px 22px rgba(219, 193, 91, 0.12);
}

.mini-card.scheduler-project-comment-card::before {
    background: linear-gradient(180deg, rgba(231, 201, 58, 0.96), rgba(248, 221, 89, 0.96));
}

@media (max-width: 720px) {
    main,
    .entry-shell {
        padding: 0.85rem;
    }

    .sidebar {
        padding: 0.9rem;
    }

    .sidebar-toggle-button {
        bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
        left: 0.85rem;
        width: 2.8rem;
        height: 2.8rem;
    }

    .glass-card,
    .topbar,
    .entry-header,
    .entry-role-card {
        padding: 1rem;
    }

    .kpi-card {
        padding: 1rem;
    }

    .kpi-card strong {
        font-size: clamp(1.55rem, 7vw, 2.1rem);
    }

    .data-table tbody td {
        grid-template-columns: 1fr;
        gap: 0.35rem;
        padding: 0.75rem 0.9rem;
    }

    .entry-role-card {
        min-height: auto;
    }

    .brand-logo {
        max-width: 100%;
    }

    .topbar-grid,
    .notification-card {
        grid-template-columns: 1fr;
        grid-column: span 1;
    }

    .metrics-pair div {
        min-width: calc(50% - 0.5rem);
    }

    .dashboard-section-heading {
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: start;
    }

    .dashboard-summary-actions {
        gap: 0.55rem;
        flex-wrap: nowrap;
        justify-content: flex-end;
        align-items: center;
    }

    .dashboard-summary-actions .dashboard-select-filter {
        min-width: min(100%, 8.5rem);
    }
}

@media (max-width: 520px) {
    .kpi-grid,
    .kpi-grid-wide {
        grid-template-columns: 1fr;
    }

    .kpi-chart {
        gap: 0.25rem;
    }

    .kpi-chart-column {
        grid-template-rows: minmax(3.4rem, 1fr) minmax(1.8rem, auto);
    }

    .kpi-chart-label {
        font-size: 0.58rem;
        line-height: 1.1;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        word-break: break-word;
    }

    .menu-role-icon {
        min-width: 0;
    }

    .metrics-pair div {
        min-width: 100%;
    }

    .field-input,
    .action-button,
    .ghost-button,
    .filter-pill {
        min-height: 2.8rem;
    }
}

.topbar-grid-compact {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.topbar-bell-shell {
    position: relative;
    display: flex;
    justify-content: flex-end;
    flex: 0 0 auto;
    z-index: 90;
}

.topbar-bell-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border: 1px solid rgba(91, 121, 170, 0.16);
    border-radius: 0;
    background: rgba(255, 255, 255, 0.86);
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

.topbar-bell-shell.topbar-bell-shell-inline {
    display: block;
    width: 100%;
    max-width: 100%;
    position: static;
    z-index: auto;
    overflow: hidden;
}

.topbar-bell-button.topbar-bell-button-inline {
    display: flex;
    width: 100%;
    max-width: 100%;
    height: auto;
    min-width: 0;
    min-height: 3rem;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    padding-right: 2.9rem;
    border-radius: 0;
    font-weight: 700;
    color: var(--navy-soft);
    box-sizing: border-box;
    overflow: hidden;
}

.topbar-bell-button.topbar-bell-button-inline .topbar-bell-label {
    display: block;
    flex: 1 1 auto;
    min-width: 0;
    text-align: left;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.topbar-bell-glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.2rem;
    min-width: 1.2rem;
    height: 1.2rem;
    line-height: 1;
    flex: 0 0 auto;
    font-size: 1rem;
    color: var(--accent-strong);
}

.topbar-bell-count {
    position: absolute;
    top: 8px;
    right: 8px;
    min-width: 1.25rem;
    height: 1.25rem;
    padding: 0 0.22rem;
    border-radius: 0;
    background: linear-gradient(135deg, #f0627a, #d84b65);
    color: white;
    font-size: 0.72rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.notification-drawer {
    z-index: 230;
    width: min(48rem, calc(100vw - 1rem));
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
}

.notification-drawer .notification-popover-header,
.notification-drawer .notification-popover-section {
    min-width: 0;
}

.topbar-bell-button.topbar-bell-button-inline .topbar-bell-count {
    top: 50%;
    right: 0.9rem;
    transform: translateY(-50%);
}

/* Navbar-specific overrides must live after the generic topbar/button rules. */
.app-nav-shell .topbar-search.app-nav-search {
    border-color: rgba(109, 150, 214, 0.22);
    background: linear-gradient(180deg, rgba(232, 239, 250, 0.98), rgba(221, 231, 246, 0.94));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.9),
        0 10px 24px rgba(7, 16, 31, 0.1);
}

.app-nav-shell .topbar-search.app-nav-search:focus-within {
    border-color: rgba(70, 155, 255, 0.46);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.92),
        0 0 0 4px rgba(36, 165, 255, 0.12),
        0 12px 28px rgba(7, 16, 31, 0.14);
}

.app-nav-shell .topbar-search.app-nav-search .topbar-search-icon {
    color: rgba(17, 112, 230, 0.82);
}

.app-nav-shell .topbar-search.app-nav-search .topbar-search-input {
    color: var(--navy);
    font-weight: 600;
}

.app-nav-shell .topbar-search.app-nav-search .topbar-search-input::placeholder {
    color: rgba(46, 70, 107, 0.68);
}

.app-nav-shell .topbar-bell-button.app-nav-notification-button {
    width: auto;
    height: auto;
    min-width: 10.75rem;
    min-height: 3rem;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-color: rgba(102, 157, 232, 0.28);
    background: linear-gradient(135deg, rgba(30, 77, 136, 0.92), rgba(22, 58, 106, 0.96));
    color: rgba(248, 251, 255, 0.98);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 12px 24px rgba(7, 16, 31, 0.16);
}

.app-nav-shell .topbar-bell-button.app-nav-notification-button .topbar-bell-glyph {
    width: 1.55rem;
    min-width: 1.55rem;
    height: 1.55rem;
    background: linear-gradient(135deg, rgba(36, 165, 255, 0.26), rgba(24, 178, 176, 0.24));
    color: #b8e1ff;
}

.app-nav-shell .topbar-bell-button.app-nav-notification-button:hover,
.app-nav-shell .topbar-bell-button.app-nav-notification-button:focus-visible {
    transform: translateY(-1px);
    border-color: rgba(122, 185, 255, 0.36);
    background: linear-gradient(135deg, rgba(36, 93, 164, 0.94), rgba(24, 67, 124, 0.98));
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 14px 28px rgba(7, 16, 31, 0.2);
}

.app-nav-profile-dropdown .app-nav-switch-view.ghost-button {
    border: 0;
    color: #fff;
    background: linear-gradient(135deg, var(--accent-strong), var(--accent));
    box-shadow: 0 16px 28px rgba(17, 112, 230, 0.22);
}

.app-nav-profile-dropdown .app-nav-switch-view.ghost-button:hover,
.app-nav-profile-dropdown .app-nav-switch-view.ghost-button:focus-visible {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.notification-popover-header,
.drawer-section-header,
.notification-feed-meta {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.notification-popover-header h2,
.notification-popover-section h3 {
    margin: 0;
}

.notification-compose-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.85rem;
    margin-bottom: 0.9rem;
}

.notification-popover-section {
    padding-top: 1rem;
    margin-top: 1rem;
    border-top: 1px solid rgba(91, 121, 170, 0.12);
}

.notification-feed,
.drawer-stack,
.side-drawer-body {
    display: grid;
    gap: 0.9rem;
}

.notification-feed-item {
    display: grid;
    grid-template-columns: 2.75rem minmax(0, 1fr);
    gap: 0.85rem;
    padding: 0.9rem;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(91, 121, 170, 0.12);
    min-width: 0;
    overflow: hidden;
}

.notification-workflow-card {
    display: grid;
    gap: 0.65rem;
    padding: 0.9rem;
    border: 1px solid rgba(91, 121, 170, 0.16);
    background: rgba(247, 251, 253, 0.92);
    min-width: 0;
}

.notification-workflow-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.4rem 0.75rem;
}

.notification-workflow-heading strong {
    color: var(--navy);
    font-size: 0.96rem;
    line-height: 1.3;
}

.notification-workflow-type {
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    color: var(--accent-strong);
    background: rgba(91, 145, 211, 0.12);
    font-size: 0.72rem;
    font-weight: 700;
    white-space: nowrap;
}

.notification-workflow-instruction {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.4;
}

.notification-workflow-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.55rem 1rem;
    margin: 0;
}

.notification-workflow-facts > div {
    display: grid;
    gap: 0.1rem;
    min-width: 0;
}

.notification-workflow-facts dt {
    color: var(--text-soft);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.notification-workflow-facts dd {
    margin: 0;
    color: var(--navy);
    font-size: 0.84rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.notification-workflow-card > .notification-action-button {
    justify-self: start;
}

.notification-feed-item-important {
    border-color: rgba(216, 91, 114, 0.22);
    background: rgba(255, 244, 247, 0.9);
}

.notification-feed-item-question {
    border-color: rgba(17, 112, 230, 0.16);
    background: rgba(243, 248, 255, 0.92);
}

.notification-feed-item-incident {
    border-color: rgba(216, 91, 114, 0.28);
    background: rgba(255, 239, 242, 0.94);
}

.notification-feed-item-read {
    border-color: rgba(91, 121, 170, 0.1);
    background: rgba(241, 245, 251, 0.92);
    opacity: 0.78;
}

.notification-feed-avatar {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: white;
    background: linear-gradient(135deg, var(--accent-strong), var(--teal));
}

.notification-feed-body {
    min-width: 0;
    display: grid;
    gap: 0.3rem;
}

.notification-feed-meta strong,
.notification-feed-meta span,
.notification-feed-context,
.notification-feed-message {
    color: var(--text-soft);
    overflow-wrap: anywhere;
    word-break: break-word;
}

.notification-feed-meta strong {
    color: var(--navy);
}

.notification-feed-meta-actions {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
    min-width: 0;
}

.notification-feed-meta span,
.notification-feed-context {
    font-size: 0.85rem;
}

.notification-feed-message {
    margin: 0;
    line-height: 1.55;
    color: var(--navy);
}

.notification-feed-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.2rem;
}

.notification-action-button {
    min-height: 2.3rem;
    padding: 0.55rem 0.95rem;
}

.notification-dismiss-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.2rem;
    min-width: 2.2rem;
    min-height: 2.2rem;
    padding: 0;
    color: #c9364b;
    border-color: rgba(201, 54, 75, 0.32);
    background: rgba(255, 244, 246, 0.9);
}

.notification-dismiss-button:hover,
.notification-dismiss-button:focus-visible {
    color: #a61e35;
    border-color: rgba(166, 30, 53, 0.5);
    background: rgba(255, 229, 234, 0.95);
}

.notification-summary-actions {
    margin-top: 0.9rem;
    justify-content: flex-start;
}

.notification-sent-strip {
    display: grid;
    grid-template-columns: 2.2rem minmax(0, 1fr);
    align-items: start;
    gap: 0.75rem;
    margin-top: 0.75rem;
    padding: 0.75rem 0.95rem;
    border-radius: 0;
    border: 1px solid rgba(134, 183, 255, 0.2);
    background: linear-gradient(180deg, rgba(233, 243, 255, 0.98), rgba(220, 236, 255, 0.9));
}

.notification-sent-strip-avatar {
    width: 2.2rem;
    height: 2.2rem;
    border-radius: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.76rem;
    font-weight: 800;
    color: white;
    background: linear-gradient(135deg, var(--accent-strong), var(--teal));
}

.notification-sent-strip-body {
    min-width: 0;
    display: grid;
    gap: 0.3rem;
}

.notification-sent-strip-modal {
    margin-top: 0;
    margin-bottom: 0.9rem;
}

.notification-sent-strip-head,
.notification-sent-strip-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.notification-sent-strip-head {
    align-items: flex-start;
}

.notification-sent-strip-title,
.notification-sent-strip-side {
    display: grid;
    gap: 0.2rem;
}

.notification-sent-strip-side {
    justify-items: end;
}

.notification-sent-dismiss-button {
    margin-top: 0.15rem;
}

.notification-sent-strip-head strong {
    color: var(--navy);
    font-size: 0.88rem;
}

.notification-sent-strip-head span,
.notification-sent-strip-meta {
    color: var(--text-soft);
    font-size: 0.8rem;
}

.notification-sent-strip-meta span {
    position: relative;
}

.notification-sent-strip-meta span:not(:last-child)::after {
    content: "•";
    margin-left: 0.45rem;
    color: rgba(91, 121, 170, 0.48);
}

.notification-sent-strip-message {
    margin: 0;
    color: var(--navy);
    font-size: 0.88rem;
    line-height: 1.45;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.notification-sent-strip-empty {
    grid-column: 1 / -1;
    margin: 0;
    color: var(--text-soft);
    font-size: 0.84rem;
    line-height: 1.45;
}

.notification-compose-row {
    display: grid;
    grid-template-columns: minmax(0, 0.55fr) minmax(0, 1fr);
    gap: 0.85rem;
    align-items: end;
}

.notification-activity-field,
.notification-category-field {
    min-width: 0;
}

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

.notification-filter-grid {
    margin-bottom: 0.85rem;
}

.notification-history-list {
    display: grid;
    gap: 0.9rem;
    max-height: min(24rem, 48vh);
    overflow: auto;
    padding-right: 0.25rem;
}

.notification-history-list-modal {
    max-height: min(calc(100vh - 15rem), 42rem);
    padding-right: 0.5rem;
}

.notification-history-table-shell {
    max-height: min(calc(100vh - 15rem), 42rem);
    overflow: auto;
}

.quote-line-card-processing {
    opacity: 0.72;
    pointer-events: none;
}

.quote-line-operation-progress {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-bottom: 0.85rem;
    padding: 0.55rem 0.7rem;
    border-left: 3px solid var(--accent-strong);
    background: var(--accent-soft);
    color: var(--navy);
    font-size: 0.84rem;
    font-weight: 700;
}

.quote-line-removal-hint {
    max-width: 16rem;
    color: var(--text-soft);
    font-size: 0.78rem;
    line-height: 1.35;
}

.notification-history-table {
    min-width: 74rem;
    table-layout: auto;
}

.notification-history-table th:nth-child(1),
.notification-history-table td:nth-child(1) { min-width: 7.5rem; }

.notification-history-table th:nth-child(2),
.notification-history-table td:nth-child(2) { min-width: 7.5rem; }

.notification-history-table th:nth-child(3),
.notification-history-table td:nth-child(3) { min-width: 6.5rem; }

.notification-history-table th:nth-child(4),
.notification-history-table td:nth-child(4) { min-width: 9rem; }

.notification-history-table th:nth-child(5),
.notification-history-table td:nth-child(5) { min-width: 13rem; }

.notification-history-table th:nth-child(6),
.notification-history-table td:nth-child(6) { min-width: 6.5rem; }

.notification-history-table th:nth-child(7),
.notification-history-table td:nth-child(7) { min-width: 7rem; }

.notification-history-table th:nth-child(8),
.notification-history-table td:nth-child(8) { min-width: 8.5rem; }

.notification-history-table th:nth-child(9),
.notification-history-table td:nth-child(9) { min-width: 10rem; }

.notification-history-table th,
.notification-history-table td {
    overflow-wrap: break-word;
    word-break: normal;
}

.notification-history-table th:nth-child(6),
.notification-history-table th:nth-child(7),
.notification-history-table th:nth-child(8),
.notification-history-table th:nth-child(9),
.notification-history-table td:nth-child(6),
.notification-history-table td:nth-child(7),
.notification-history-table td:nth-child(8),
.notification-history-table td:nth-child(9) {
    white-space: nowrap;
}

.notification-history-message {
    line-height: 1.45;
}

.notification-history-actions {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.45rem;
}

.notification-history-icon-button {
    display: inline-grid;
    place-items: center;
    width: 2.35rem;
    min-width: 2.35rem;
    min-height: 2.35rem;
    padding: 0;
}

@media (max-width: 1180px) {
    .notification-history-table-shell {
        max-height: min(calc(100vh - 13rem), 42rem);
        overflow: auto;
    }

    .notification-history-table {
        min-width: 0;
    }

    .notification-history-table td {
        white-space: normal;
    }

}

.notification-modal-shell {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 1.5rem;
    z-index: 260;
}

.notification-modal-card {
    position: relative;
    z-index: 261;
    width: min(72rem, calc(100vw - 3rem));
    max-height: calc(100dvh - 3rem);
    display: grid;
    gap: 1rem;
    overflow: hidden;
    padding: 1.2rem;
}

.notification-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.notification-reply-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.85rem;
    padding: 0.85rem 1rem;
    margin-bottom: 0.9rem;
    border: 1px solid rgba(109, 155, 225, 0.22);
    border-radius: 0;
    background: linear-gradient(180deg, rgba(246, 250, 255, 0.96), rgba(232, 241, 255, 0.88));
}

.notification-reply-banner .muted {
    margin: 0.2rem 0 0;
}

.notification-important-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 0.9rem;
    color: var(--navy);
    font-weight: 700;
}

.notification-category-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.9rem;
}

.notification-category-option {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-height: 2.8rem;
    padding: 0.72rem 0.95rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: rgba(255, 255, 255, 0.76);
    color: var(--navy-soft);
    font-weight: 700;
    cursor: pointer;
    transition: border-color 140ms ease, background-color 140ms ease, box-shadow 140ms ease, color 140ms ease;
}

.notification-category-option input {
    margin: 0;
    accent-color: var(--accent-strong);
}

.notification-category-option > span {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.notification-category-field .notification-category-group {
    margin-top: 0;
    justify-content: flex-start;
}

.notification-category-field .notification-category-option {
    min-height: 2.55rem;
    padding: 0.62rem 0.82rem;
}

.notification-category-option-selected {
    color: var(--navy);
    border-color: rgba(17, 112, 230, 0.22);
    background: linear-gradient(180deg, rgba(246, 250, 255, 0.96), rgba(232, 241, 255, 0.9));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.notification-close-button {
    min-height: 2.4rem;
}

.data-row-clickable {
    cursor: pointer;
}

.customer-card-panel {
    transition: transform 140ms ease, box-shadow 140ms ease;
}

.customer-card-panel:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.company-registry-filter-grid {
    grid-template-columns: minmax(16rem, 1.4fr) minmax(12rem, 0.8fr);
}

.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(16, 35, 63, 0.18);
    backdrop-filter: blur(4px);
    z-index: 220;
}

.side-drawer {
    position: fixed;
    top: 0;
    right: 0;
    width: min(72rem, calc(100vw - 0.5rem));
    height: 100vh;
    padding: 1.2rem;
    background:
        linear-gradient(180deg, rgba(249, 252, 255, 0.98), rgba(237, 244, 255, 0.96));
    border-left: 1px solid rgba(91, 121, 170, 0.14);
    box-shadow: -18px 0 44px rgba(28, 54, 96, 0.16);
    z-index: 221;
    overflow: auto;
}

.review-task-list,
.review-modal-body,
.review-route-list,
.review-modal-column {
    display: grid;
    gap: 1rem;
}

.review-task-card {
    justify-content: space-between;
    align-items: center;
}

.review-modal-shell {
    position: fixed;
    inset: 0;
    display: grid;
    place-items: center;
    min-height: 100dvh;
    padding: clamp(0.75rem, 2vw, 1.5rem);
    z-index: 1450;
    background: linear-gradient(180deg, rgba(18, 35, 61, 0.14), rgba(18, 35, 61, 0.26));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.review-modal-card {
    width: min(76rem, calc(100vw - 3rem));
    max-height: calc(100dvh - clamp(1.5rem, 4vw, 3rem));
    overflow: hidden;
    display: grid;
    gap: 1rem;
    padding: 1.2rem;
}

.review-modal-card-wide {
    width: min(88rem, calc(100vw - 3rem));
}

.review-modal-layout {
    width: min(110rem, calc(100vw - 3rem));
    max-height: calc(100dvh - 3rem);
    display: grid;
    grid-template-columns: minmax(0, 1fr) clamp(20rem, 22vw, 24rem);
    gap: 1.25rem;
    align-items: start;
}

.review-modal-layout > .review-modal-card,
.review-modal-layout > .review-modal-card.review-modal-card-wide,
.review-modal-layout > .review-modal-card.review-quote-modal-card {
    width: 100%;
    max-width: none;
    min-width: 0;
}

.review-modal-sidecard {
    max-height: calc(100dvh - 3rem);
    overflow: auto;
    display: grid;
    gap: 1rem;
    padding: 1rem;
    align-self: start;
    min-width: 0;
    overflow-x: hidden;
}

.review-modal-header,
.review-modal-section {
    display: grid;
    gap: 0.9rem;
}

.review-modal-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
}

.review-modal-body {
    min-height: 0;
    overflow: auto;
    padding-right: 0.35rem;
}

.review-modal-body:not(.review-modal-body-two-column) {
    display: flex;
    flex-direction: column;
}

.review-quote-modal-card {
    width: min(78rem, calc(100vw - 3rem));
}

.crm-company-modal-card {
    width: min(88rem, calc(100vw - 3rem));
}

.crm-company-modal-body {
    display: grid;
    gap: 1rem;
}

.crm-company-order-toolbar {
    display: flex;
    align-items: end;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.crm-company-page-size-picker {
    display: grid;
    gap: 0.45rem;
    justify-items: end;
}

.crm-company-page-size-label {
    color: var(--text-soft);
    font-size: 0.88rem;
    font-weight: 700;
}

.crm-company-page-size-picker .segmented-selector-compact {
    width: auto;
}

.crm-company-order-table-shell {
    margin-top: 0.4rem;
}

.crm-company-order-actions {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.crm-company-order-row-active {
    background: rgba(231, 241, 255, 0.84);
}

.review-quote-modal-body {
    min-height: 0;
}

.review-quote-main-sections {
    min-height: 0;
    overflow: auto;
    padding-right: 0.35rem;
    display: grid;
    gap: 1rem;
}

.review-executive-decision-panel {
    min-width: 0;
    align-self: start;
    border: 1px solid rgba(91, 121, 170, 0.16);
    border-top: 4px solid #e1c44e;
    padding: 1rem;
    background:
        linear-gradient(180deg, rgba(252, 254, 255, 0.98), rgba(241, 246, 255, 0.98));
    box-shadow: 0 18px 36px rgba(37, 64, 107, 0.1);
}

.review-modal-sidecard .review-executive-decision-panel,
.review-modal-sidecard .review-side-decision-panel {
    width: 100%;
    min-width: 0;
    overflow-x: hidden;
}

.review-modal-sidecard .drawer-section-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 0.75rem;
}

.review-modal-sidecard .field-label,
.review-modal-sidecard .field-input,
.review-modal-sidecard .text-area {
    min-width: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.review-modal-sidecard .button-row {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
    gap: 0.75rem;
}

.review-modal-sidecard .button-row > * {
    width: 100%;
    min-width: 0;
    text-align: center;
    justify-content: center;
    white-space: normal;
}

.review-modal-body-two-column {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    align-items: start;
    min-height: 0;
    overflow: hidden;
    gap: 1rem;
}

.review-modal-column-scroll,
.review-modal-column-fixed {
    min-height: 0;
}

.review-modal-column-scroll {
    overflow: auto;
    padding-right: 0.35rem;
}

.review-modal-column-fixed {
    align-self: start;
    position: sticky;
    top: 0;
    overflow: auto;
    max-height: 100%;
    padding-right: 0.2rem;
}

.review-side-decision-panel {
    border: 1px solid rgba(91, 121, 170, 0.16);
    border-top: 4px solid #e1c44e;
    padding: 1rem;
    background:
        linear-gradient(180deg, rgba(252, 254, 255, 0.98), rgba(241, 246, 255, 0.98));
    box-shadow: 0 18px 36px rgba(37, 64, 107, 0.1);
}

.review-route-card,
.review-modal-section .mini-card,
.review-modal-section .public-request-card {
    min-width: 0;
}

.review-drawing-frame,
.review-drawing-image {
    min-height: 32rem;
}

.side-drawer-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.side-drawer-body {
    display: grid;
    gap: 1rem;
}

.drawer-section {
    min-width: 0;
    padding: 1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.72);
}

.drawer-section-header-wrap {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    column-gap: 1rem;
    row-gap: 0.75rem;
}

.drawer-section-header-wrap > h3 {
    margin: 0;
    min-width: 0;
}

.drawer-action-header {
    margin-bottom: 0.9rem;
}

.drawer-section-heading {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
}

.drawer-section-heading h3 {
    margin: 0;
}

.drawer-status-shell {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
    min-width: 0;
    width: 100%;
}

.drawer-status-trigger {
    border: 0;
    cursor: pointer;
    position: relative;
    z-index: 1;
    flex: 0 0 auto;
    padding: 0.38rem 0.72rem;
    font-size: 0.74rem;
    line-height: 1.15;
}

.drawer-status-menu {
    display: flex;
    align-items: stretch;
    justify-content: flex-end;
    flex-wrap: nowrap;
    gap: 0.35rem;
    flex: 1 1 auto;
    min-width: 0;
    max-width: 0;
    padding: 0;
    opacity: 0;
    overflow: hidden;
    pointer-events: none;
    transform: translateX(0.55rem) scaleX(0.98);
    transform-origin: right center;
    transition:
        max-width 220ms ease,
        opacity 180ms ease,
        transform 220ms ease,
        padding 220ms ease,
        margin 220ms ease;
    white-space: nowrap;
}

.drawer-status-menu-open {
    max-width: 100%;
    padding: 0.32rem;
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0) scaleX(1);
}

.drawer-status-option {
    width: auto;
    min-width: 0;
    min-height: 2.15rem;
    padding: 0.38rem 0.68rem;
    flex: 1 1 0;
    justify-content: center;
    font-size: 0.74rem;
    line-height: 1.15;
    word-break: keep-all;
}

.drawer-status-option-active {
    border-color: rgba(17, 112, 230, 0.2);
    color: var(--accent-strong);
}

@media (max-width: 900px) {
    .company-registry-filter-grid {
        grid-template-columns: 1fr;
    }

    .drawer-section-header-wrap {
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: start;
    }

    .drawer-status-shell {
        width: auto;
        justify-content: flex-end;
    }

    .drawer-status-menu-open {
        max-width: 100%;
    }
}

.drawer-description-block {
    margin-top: 1rem;
    display: grid;
    gap: 0.85rem;
}

.drawer-inline-title-row {
    align-items: flex-start;
}

.drawer-inline-form {
    display: grid;
    gap: 0.85rem;
    margin-bottom: 1rem;
    padding: 0.95rem;
    border-radius: 0;
    border: 1px solid rgba(109, 155, 225, 0.14);
    background: linear-gradient(180deg, rgba(248, 251, 255, 0.94), rgba(239, 246, 255, 0.88));
}

.drawer-edit-panel {
    display: grid;
    gap: 0.85rem;
    margin-top: 0.9rem;
    padding: 0.95rem;
    border-radius: 0;
    border: 1px solid rgba(109, 155, 225, 0.16);
    background: linear-gradient(180deg, rgba(250, 253, 255, 0.98), rgba(242, 248, 255, 0.9));
}

.drawer-edit-icon-button {
    min-width: 2rem;
    min-height: 2rem;
    padding: 0;
    border-radius: 0;
    font-size: 0.95rem;
    font-weight: 800;
    line-height: 1;
    flex: 0 0 auto;
}

.drawer-edit-meta {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.75rem;
}

.drawer-edit-meta div {
    display: grid;
    gap: 0.2rem;
}

.drawer-edit-meta dt {
    color: var(--text-soft);
    font-size: 0.78rem;
}

.drawer-edit-meta dd {
    margin: 0;
    color: var(--navy);
    font-weight: 700;
}

.drawer-form-grid {
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.drawer-checkbox-row {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--navy);
    font-weight: 700;
}

.drawer-checkbox-row input {
    margin: 0;
}

.drawer-metrics {
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.8rem;
}

.drawer-metrics div {
    display: grid;
    gap: 0.2rem;
}

.drawer-metrics dt {
    color: var(--text-soft);
    font-size: 0.8rem;
}

.drawer-metrics dd {
    margin: 0;
    color: var(--navy);
    font-weight: 700;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.drawer-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.9rem;
}

.drawer-summary-card {
    align-content: start;
    min-width: 0;
}

.drawer-summary-card strong {
    font-size: clamp(1.35rem, 1.65vw, 1.95rem);
    line-height: 1.12;
    white-space: nowrap;
    overflow-wrap: normal;
    font-variant-numeric: tabular-nums;
}

.side-drawer .mini-card,
.side-drawer .drawer-section-header,
.side-drawer .drawer-stack article,
.side-drawer .drawer-summary-grid article {
    min-width: 0;
}

.side-drawer .mini-card {
    flex-wrap: wrap;
    align-items: flex-start;
}

.side-drawer .drawer-stack {
    grid-template-columns: 1fr;
}

.contact-card {
    position: relative;
    justify-content: space-between;
    gap: 0.85rem;
    padding-right: 3.25rem;
}

.contact-card-main {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    min-width: 0;
    flex: 1 1 auto;
}

.contact-avatar {
    width: 3rem;
    height: 3rem;
    border-radius: 0;
    object-fit: cover;
    flex: 0 0 auto;
    border: 1px solid rgba(109, 155, 225, 0.22);
    box-shadow: 0 8px 18px rgba(25, 73, 141, 0.12);
}

.contact-card-copy {
    min-width: 0;
    flex: 1 1 auto;
}

.contact-card-copy h3 {
    margin-bottom: 0.18rem;
}

.contact-card-copy p:last-child {
    margin-bottom: 0;
}

.contact-edit-button {
    position: absolute;
    top: 0.95rem;
    right: 0.95rem;
    z-index: 1;
}

.contact-pill {
    margin-top: 0.7rem;
    padding: 0.34rem 0.64rem;
    font-size: 0.72rem;
    white-space: nowrap;
}

.order-detail-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 1rem;
    width: 100%;
    box-sizing: border-box;
    cursor: pointer;
    transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.order-detail-card-main {
    min-width: 0;
    flex: 1 1 auto;
}

.order-detail-card-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.65rem;
    flex-wrap: wrap;
    justify-self: end;
    align-self: start;
    margin-left: 0;
    flex: 0 0 auto;
}

.order-detail-card:hover {
    border-color: rgba(17, 112, 230, 0.18);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.order-detail-card-active {
    border-color: rgba(17, 112, 230, 0.24);
    box-shadow: 0 18px 32px rgba(20, 78, 156, 0.12);
}

.order-detail-card-highlighted {
    border-color: rgba(111, 191, 115, 0.55);
    animation: order-card-highlight-pulse 3s ease-in-out infinite;
}

.order-detail-card-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.9rem;
    width: 100%;
    box-sizing: border-box;
}

.order-detail-card-shell-active {
    border-color: rgba(17, 112, 230, 0.24);
    box-shadow: 0 18px 32px rgba(20, 78, 156, 0.12);
}

.order-detail-card-shell > .order-detail-card {
    min-width: 0;
    align-self: stretch;
    width: 100%;
}

.cockpit-detail-row td {
    padding: 0;
    background: transparent;
}

.cockpit-detail-cell {
    padding: 0 0 1rem;
}

.cockpit-detail-card,
.cockpit-detail-grid,
.cockpit-detail-header,
.cockpit-detail-facts {
    display: grid;
    gap: 1rem;
}

.cockpit-detail-card {
    margin-top: 0.35rem;
    padding: 1.1rem;
}

.cockpit-detail-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
}

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

.cockpit-detail-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem 1rem;
}

.cockpit-detail-facts span {
    display: block;
    margin-bottom: 0.2rem;
    color: var(--text-soft);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cockpit-detail-facts strong {
    color: var(--navy);
    overflow-wrap: anywhere;
}

.drawer-order-detail {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
    padding-top: 0.15rem;
    border-top: 1px solid rgba(91, 121, 170, 0.12);
}

.crm-order-finance-modal-card {
    width: min(64rem, calc(100vw - 3rem));
}

.crm-order-finance-modal-card .review-modal-body {
    overflow-x: hidden;
}

.crm-order-finance-panel {
    display: grid;
    gap: 1rem;
    min-width: 0;
}

.crm-order-finance-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 1rem;
    align-items: start;
}

.crm-order-finance-summary,
.crm-order-finance-form {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
}

.drawer-order-finance-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem 1rem;
}

.drawer-order-finance-meta > * {
    min-width: 0;
    overflow-wrap: anywhere;
}

.crm-order-delay-meta {
    align-content: start;
}

.drawer-order-detail-header,
.drawer-order-part-stack {
    display: grid;
    gap: 0.85rem;
}

.drawer-order-part-card {
    display: grid;
    gap: 0.9rem;
    cursor: pointer;
    transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.drawer-order-part-card:hover {
    border-color: rgba(17, 112, 230, 0.18);
    box-shadow: var(--shadow-md);
    transform: translateY(-1px);
}

.drawer-order-part-card-active {
    border-color: rgba(17, 112, 230, 0.24);
    box-shadow: 0 16px 28px rgba(20, 78, 156, 0.12);
}

.cockpit-detail-split-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(17rem, 0.9fr);
    align-items: start;
    gap: 1rem;
}

.cockpit-preview-panel {
    display: grid;
    gap: 0.75rem;
    min-width: 0;
}

.cockpit-preview-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.cockpit-preview-panel-header span {
    color: var(--text-soft);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.cockpit-preview-panel-header strong {
    color: var(--navy);
    font-size: 0.95rem;
}

.cockpit-preview-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.cockpit-preview-card {
    display: grid;
    gap: 0.55rem;
    min-width: 0;
}

.cockpit-preview-frame,
.cockpit-preview-image {
    width: 100%;
    height: 9.5rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    border-radius: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(236, 244, 255, 0.88));
}

.cockpit-preview-frame {
    overflow: hidden;
}

.cockpit-preview-image {
    object-fit: cover;
    padding: 0.35rem;
}

.cockpit-preview-image-placeholder {
    object-fit: contain;
    padding: 1rem;
    background:
        radial-gradient(circle at top, rgba(36, 165, 255, 0.12), transparent 55%),
        linear-gradient(180deg, rgba(246, 251, 255, 0.98), rgba(232, 241, 252, 0.92));
}

.cockpit-preview-meta {
    display: grid;
    gap: 0.18rem;
}

.cockpit-preview-meta strong,
.cockpit-preview-meta span {
    overflow-wrap: anywhere;
}

.cockpit-preview-meta strong {
    color: var(--navy);
    font-size: 0.84rem;
}

.cockpit-preview-meta span {
    color: var(--text-soft);
    font-size: 0.78rem;
}

.cockpit-preview-empty {
    margin: 0;
}

.drawer-order-part-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.8rem;
}

.drawer-order-detail-header > .button-row,
.drawer-order-part-header > .status-pill,
.drawer-order-step-row > .status-pill {
    flex: 0 0 auto;
    align-self: flex-start;
    max-width: 100%;
}

.drawer-order-part-header > .status-pill,
.drawer-order-step-row > .status-pill,
.drawer-status-trigger {
    flex-wrap: wrap;
    white-space: normal;
    text-align: center;
    justify-content: center;
}

.drawer-order-checkpoints {
    gap: 0.7rem;
}

.drawer-order-step-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
}

.drawer-order-step-row h3 {
    margin: 0;
}

.related-quote-range-stack .table-range-bound {
    min-width: 0;
}

.side-drawer h2,
.side-drawer h3,
.side-drawer p,
.side-drawer span,
.side-drawer dd,
.side-drawer dt {
    overflow-wrap: anywhere;
}

@media (max-width: 1180px) {
    .side-drawer {
        width: min(58rem, calc(100vw - 0.5rem));
    }

    .cockpit-detail-split-card {
        grid-template-columns: 1fr;
    }

    .cockpit-preview-grid {
        grid-template-columns: 1fr;
    }

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

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

    .notification-drawer {
        width: min(40rem, calc(100vw - 1rem));
        padding: 0.85rem;
        gap: 0.55rem;
    }

    .notification-popover-header {
        gap: 0.75rem;
        align-items: center;
    }

    .notification-popover-section {
        margin-top: 0.65rem;
        padding-top: 0.65rem;
    }

    .notification-drawer .form-grid {
        grid-template-columns: 1fr;
        gap: 0.85rem;
    }

    .notification-compose-row {
        grid-template-columns: 1fr;
        gap: 0.7rem;
    }

    .notification-category-group {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 0.6rem;
    }

    .notification-category-field .notification-category-option {
        justify-content: center;
    }

    .review-modal-body-two-column {
        grid-template-columns: 1fr;
    }

    .cockpit-detail-grid,
    .recommendation-side-stack {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .order-detail-card {
        grid-template-columns: 1fr;
    }

    .order-detail-card-actions {
        justify-self: stretch;
        justify-content: flex-start;
    }

    .crm-order-finance-layout {
        grid-template-columns: 1fr;
    }

    .contact-card {
        padding-right: 1rem;
    }

    .contact-edit-button {
        top: 0.8rem;
        right: 0.8rem;
    }

    .drawer-order-part-header,
    .drawer-order-step-row {
        flex-direction: column;
        align-items: stretch;
    }

    .drawer-order-detail {
        padding: 0.85rem;
    }

    .drawer-order-detail-header > .button-row,
    .drawer-order-part-header > .status-pill,
    .drawer-order-step-row > .status-pill {
        width: 100%;
    }

    .notification-drawer {
        width: calc(100vw - 1rem);
        padding: 0.95rem;
    }

    .notification-drawer .form-grid,
    .notification-drawer .notification-popover-header,
    .notification-drawer .notification-feed-meta {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: stretch;
    }

    .notification-compose-row,
    .notification-sent-strip-head {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: stretch;
    }

    .notification-sent-strip-side {
        justify-items: start;
    }

    .notification-feed-actions,
    .notification-reply-banner {
        align-items: stretch;
        flex-direction: column;
    }

    .notification-modal-shell {
        padding: 0.85rem;
    }

    .notification-modal-card {
        width: 100%;
        max-height: calc(100dvh - 1.7rem);
        padding: 1rem;
    }

    .notification-modal-header {
        flex-direction: column;
        align-items: stretch;
    }

    .review-task-card,
    .review-modal-header {
        grid-template-columns: 1fr;
    }

    .review-modal-shell {
        padding: 0.85rem;
    }

    .review-modal-card,
    .review-modal-card-wide {
        width: 100%;
        max-height: calc(100dvh - 1.7rem);
        padding: 1rem;
    }

    .review-drawing-frame,
    .review-drawing-image {
        min-height: 18rem;
    }

    .crm-company-order-toolbar {
        width: 100%;
        align-items: stretch;
        justify-content: flex-start;
        flex-direction: column;
    }

    .crm-company-page-size-picker {
        width: 100%;
        justify-items: start;
    }

    .crm-company-page-size-picker .segmented-selector-compact {
        width: 100%;
    }

    .drawer-summary-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    .notification-feed-item {
        grid-template-columns: 1fr;
    }

    .notification-workflow-facts {
        grid-template-columns: 1fr;
    }

    .notification-feed-avatar {
        width: 2.4rem;
        height: 2.4rem;
    }
}

.review-modal-shell {
    place-items: center;
    overflow: auto;
    overscroll-behavior: contain;
}

.review-modal-card,
.review-modal-card-wide {
    grid-template-rows: auto minmax(0, 1fr);
    align-self: center;
    margin: auto;
}

.review-modal-body {
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-bottom: 0.35rem;
}

.review-modal-sticky-footer {
    position: sticky;
    bottom: 0;
    z-index: 2;
    margin-top: auto;
    flex-shrink: 0;
    padding: 1rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    border-radius: 0;
    background:
        linear-gradient(180deg, rgba(252, 254, 255, 0.98), rgba(241, 246, 255, 0.98));
    box-shadow: 0 -12px 28px rgba(37, 64, 107, 0.08);
}

.technology-rules-grid,
.technology-quote-lines,
.technology-step-stack,
.technology-step-grid,
.technology-library,
.technology-library-group,
.technology-line-summary,
.technology-request-meta {
    display: grid;
    gap: 1rem;
}

.technology-rules-grid {
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
}

.technology-plan-card,
.technology-line-card {
    display: grid;
    gap: 1.15rem;
    align-items: stretch;
    justify-content: stretch;
}

.technology-plan-modal-shell {
    padding: clamp(0.65rem, 2vw, 1.5rem);
    overflow: hidden;
}

.technology-plan-modal-card {
    width: min(100rem, calc(100vw - 2rem));
    height: calc(100dvh - clamp(1.3rem, 4vw, 3rem));
    max-height: calc(100dvh - clamp(1.3rem, 4vw, 3rem));
    gap: 0;
    padding: 0;
}

.technology-plan-modal-header {
    padding: 1.2rem 1.35rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.14);
}

.technology-plan-modal-header :is(h2, p) {
    margin-block: 0;
}

.technology-plan-modal-header .muted {
    margin-top: 0.35rem;
}

.review-modal-body.technology-plan-modal-body {
    display: grid;
    gap: 1.25rem;
    overflow-x: hidden;
    padding: 1.25rem 1.35rem 0;
}

.technology-plan-editor {
    min-width: 0;
}

.technology-plan-context-bar {
    margin: 0;
    padding: 1rem 1.1rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    background: rgba(244, 248, 249, 0.78);
}

.technology-plan-context-bar :is(h3, p) {
    margin-block: 0;
}

.technology-plan-context-bar .muted {
    margin-top: 0.3rem;
}

.technology-plan-overview-grid {
    grid-template-columns: minmax(0, 1.35fr) repeat(2, minmax(12rem, 0.8fr));
}

.technology-plan-overview-grid > .mini-card {
    min-width: 0;
    align-content: start;
}

.technology-plan-note {
    padding: 1rem 1.1rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    background: rgba(244, 248, 249, 0.68);
}

.technology-plan-note .text-area {
    min-height: 7rem;
}

.technology-plan-modal-body .technology-quote-lines {
    gap: 1.5rem;
}

.technology-plan-modal-body .technology-line-card {
    min-width: 0;
    padding: 1.15rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: rgba(249, 251, 250, 0.76);
}

.technology-plan-modal-body .technology-line-body {
    grid-template-columns: minmax(0, 1.7fr) minmax(18rem, 0.72fr);
}

.technology-plan-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-inline: -1.35rem;
    padding: 1rem 1.35rem;
}

.technology-line-body {
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(18rem, 0.9fr);
    gap: 1rem;
    align-items: start;
    min-width: 0;
}

.technology-line-summary {
    justify-items: end;
}

.technology-request-meta {
    grid-template-columns: repeat(auto-fit, minmax(10rem, max-content));
    gap: 0.5rem;
    margin: 0.25rem 0 0.35rem;
}

.technology-upload-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1.25rem;
    align-items: center;
    padding: 1rem 1.1rem;
}

.technology-upload-card-copy {
    min-width: 0;
    display: grid;
    gap: 0.45rem;
}

.technology-upload-card-copy h3,
.technology-upload-card-copy .operation-meta,
.technology-upload-card-copy .muted {
    margin: 0;
}

.technology-upload-card .technology-request-meta .status-pill {
    white-space: nowrap;
}

.technology-upload-card-footer {
    margin-top: 0.2rem;
}

.technology-upload-card-actions {
    align-self: center;
    justify-content: flex-end;
    flex-wrap: nowrap;
}

.technology-library {
    position: sticky;
    top: 1rem;
    padding: 1rem;
    border-radius: 0;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(247, 250, 255, 0.72);
    min-width: 0;
}

.technology-library-group .button-row {
    align-items: flex-start;
}

.technology-step-card {
    gap: 1rem;
    min-width: 0;
    width: 100%;
    justify-content: stretch;
}

.technology-step-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: start;
}

.technology-step-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.technology-step-stack {
    min-width: 0;
    align-content: start;
}

.field-span-2 {
    grid-column: span 2;
}

.text-area-compact {
    min-height: 6.5rem;
}

@media (max-width: 1080px) {
    .technology-line-body {
        grid-template-columns: 1fr;
    }

    .technology-plan-modal-body .technology-line-body {
        grid-template-columns: minmax(0, 1fr);
    }

    .technology-library {
        position: static;
    }

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

    .recommendation-tree,
    .recommendation-tree-checkpoints {
        grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr));
        gap: 1.2rem 0.9rem;
    }

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

    .technology-plan-overview-grid {
        grid-template-columns: 1fr;
    }

    .worksheet-active-grid,
    .event-filter-bar {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .technology-plan-modal-shell {
        padding: 0.5rem;
    }

    .technology-plan-modal-card {
        width: 100%;
        height: calc(100dvh - 1rem);
        max-height: calc(100dvh - 1rem);
    }

    .technology-plan-modal-header,
    .review-modal-body.technology-plan-modal-body {
        padding-inline: 0.85rem;
    }

    .technology-plan-modal-actions {
        align-items: stretch;
        margin-inline: -0.85rem;
        padding-inline: 0.85rem;
    }

    .technology-plan-modal-actions > * {
        width: 100%;
    }

    .technology-step-header,
    .technology-step-grid {
        grid-template-columns: 1fr;
    }

    .recommendation-tree,
    .recommendation-tree-checkpoints {
        grid-template-columns: repeat(auto-fit, minmax(8.75rem, 1fr));
        gap: 1rem 0.75rem;
    }

    .recommendation-checkpoint-node::before {
        left: -0.4rem;
        right: -0.4rem;
    }

    .recommendation-checkpoint-circle {
        width: 4.2rem;
        height: 4.2rem;
        font-size: 1.1rem;
    }

    .recommendation-checkpoint-node .recommendation-node-copy {
        min-height: 9.8rem;
        padding: 0.75rem 0.65rem 0.85rem;
    }

    .recommendation-checkpoint-node .muted {
        max-width: 18ch;
        font-size: 0.78rem;
    }

    .technology-upload-card {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .technology-upload-card-actions {
        justify-content: flex-start;
    }

    .field-span-2 {
        grid-column: auto;
    }

    .technology-line-summary {
        justify-items: start;
    }

    .review-modal-sticky-footer {
        position: static;
    }
}

@media (max-width: 1120px) {
    .review-modal-layout {
        width: min(calc(100vw - 1.5rem), 100%);
        max-height: none;
        grid-template-columns: 1fr;
    }

    .review-modal-sidecard {
        max-height: none;
        overflow: visible;
    }

    .review-quote-modal-body,
    .review-modal-body-two-column {
        grid-template-columns: 1fr;
    }

    .review-modal-column-scroll,
    .review-modal-column-fixed,
    .review-executive-decision-panel {
        position: static;
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}
/* Resources */
.resources-workspace-stack,
.resource-rule-stack,
.resource-contact-list,
.resource-card-grid,
.resource-form-stack {
    display: grid;
    gap: 1rem;
}

.resources-workspace-stack {
    grid-template-columns: 1fr;
}

.resource-page-header {
    align-items: flex-start;
    justify-content: space-between;
}

.resource-page-toolbar,
.resource-summary-card {
    display: grid;
    gap: 1.15rem;
}

.resource-page-header,
.resource-summary-toggle-row {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    align-items: center;
}

.resource-page-header {
    flex-wrap: wrap;
    align-items: flex-start;
}

.resource-summary-toggle-row {
    flex-wrap: wrap;
    padding-top: 0.25rem;
    border-top: 1px solid rgba(91, 121, 170, 0.14);
}

.resource-summary-toggle-title {
    margin: 0;
}

.resource-summary-toggle-actions {
    margin-left: auto;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.resource-summary-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
    margin: 0;
}

.resource-summary-stats .kpi-card {
    min-height: 8.8rem;
    min-width: 0;
    width: 100%;
}

.resource-summary-stats .dashboard-card-value-row {
    grid-template-columns: minmax(0, 1fr);
}

.resource-kpi-chart {
    grid-template-columns: repeat(var(--resource-card-columns, 4), minmax(0, 1fr));
    width: 100%;
    max-width: 100%;
    justify-self: stretch;
    gap: 0.45rem;
}

.resource-kpi-chart .kpi-chart-column {
    grid-template-rows: minmax(3.8rem, 1fr) auto;
    align-items: stretch;
    overflow: visible;
}

.resource-kpi-chart .kpi-chart-label {
    min-height: 2.4rem;
    font-size: clamp(0.66rem, 0.76vw, 0.78rem);
    line-height: 1.2;
    white-space: normal;
    overflow: hidden;
    text-overflow: clip;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.resource-summary-filters {
    padding-top: 0.15rem;
    border-top: 1px solid rgba(91, 121, 170, 0.14);
}

.resource-filter-grid {
    margin: 0;
}

.resource-page-actions {
    justify-content: flex-end;
    flex-wrap: wrap;
}

.resource-card-grid-free {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: start;
}

.resource-workspace-panel {
    border-top: 4px solid var(--workspace-accent, #21457a);
    display: grid;
    gap: 1.2rem;
}

.resource-workspace-header,
.resource-workspace-side,
.resource-card-head,
.resource-card-meta-row,
.resource-card-title {
    display: flex;
    gap: 1rem;
}

.resource-workspace-header,
.resource-card-head,
.resource-card-meta-row {
    justify-content: space-between;
    align-items: flex-start;
}

.resource-card-head {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    width: 100%;
    min-width: 0;
    gap: 0.9rem;
}

.resource-card-title {
    align-items: flex-start;
    flex-wrap: nowrap;
    min-width: 0;
    flex: 1 1 auto;
    width: 100%;
}

.resource-card-title-copy {
    min-width: 0;
    flex: 1 1 auto;
    width: 100%;
}

.resource-card-load-stack {
    display: grid;
    justify-items: end;
    gap: 0.2rem;
    margin-left: auto;
    min-width: 0;
}

.resource-card-load-label {
    color: var(--text-soft);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: right;
}

.resource-workspace-side {
    flex-direction: column;
    align-items: flex-end;
}

.resource-workspace-copy {
    min-width: 0;
}

.resource-workspace-copy h2,
.resource-workspace-copy p {
    margin-bottom: 0.28rem;
}

.resource-workspace-badges,
.resource-workspace-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
}

.resource-workspace-meta {
    margin-top: -0.15rem;
}

.resource-contact-list,
.resource-card-grid {
    grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
}

.resource-contact-card,
.resource-rule-card,
.resource-form-card {
    display: grid;
    gap: 0.45rem;
    padding: 0.9rem 1rem;
    border-radius: 0;
    border: 1px solid rgba(24, 38, 61, 0.08);
    background: rgba(255, 255, 255, 0.58);
}

.resource-contact-card span,
.resource-rule-card p {
    margin: 0;
    color: var(--text-soft);
    font-size: 0.88rem;
}

.resource-card {
    position: relative;
    display: grid;
    grid-template-rows: repeat(4, auto);
    gap: 0.75rem;
    align-content: start;
    min-height: 0;
    width: 100%;
    max-width: none;
    min-width: 0;
    padding: 1.05rem 1rem;
    border-top: 0;
    box-sizing: border-box;
    align-items: stretch;
    justify-content: stretch;
    cursor: pointer;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.mini-card.resource-card {
    width: 100%;
    max-width: none;
    min-width: 0;
    align-items: stretch;
    justify-content: stretch;
}

.mini-card.resource-card > div {
    width: 100%;
    max-width: none;
    min-width: 0;
}

.resource-card:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.resource-card-expanded {
    border-color: rgba(17, 112, 230, 0.22);
    box-shadow: 0 18px 38px rgba(25, 74, 141, 0.14);
}

.resource-card-activity {
    display: grid;
    align-content: start;
    gap: 0.35rem;
    width: 100%;
    min-width: 0;
}

.resource-card-activity-label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    color: var(--text-soft);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.resource-card-kicker,
.resource-card-current {
    margin: 0;
}

.resource-card-kicker {
    color: var(--text-soft);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.resource-card-head h3 {
    margin: 0.2rem 0 0;
}

.resource-card-title-copy :is(.resource-card-kicker, h3),
.resource-inline-indicator > span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.resource-type-icon {
    width: 2.55rem;
    height: 2.55rem;
    border-radius: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    background: linear-gradient(135deg, rgba(17, 112, 230, 0.14), rgba(24, 178, 176, 0.16));
    color: var(--accent-strong);
    font-size: 1.15rem;
    font-weight: 800;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.resource-card-load {
    color: var(--navy);
    font-size: clamp(1.25rem, 1.75vw, 1.75rem);
    line-height: 1;
    white-space: nowrap;
}

.resource-card-tools {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    column-gap: 0.7rem;
    row-gap: 0.5rem;
    align-items: center;
    justify-content: flex-end;
    margin-top: 0.15rem;
    align-self: start;
    justify-self: stretch;
    width: 100%;
}

.resource-card-tools .ghost-button {
    flex: 0 0 auto;
    justify-self: end;
}

.resource-edit-button,
.resource-delete-button {
    min-width: 2.8rem;
    width: 2.8rem;
    height: 2.8rem;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.resource-edit-button {
    font-size: 1rem;
}

.resource-edit-button > i,
.resource-delete-button > i {
    font-size: 0.98rem;
}

.resource-card-tools-label {
    color: var(--text-soft);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    min-width: 0;
}

.resource-inline-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.42rem;
    min-width: 0;
    max-width: 100%;
}

.resource-inline-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1rem;
    flex: 0 0 auto;
    font-size: 0.9rem;
    line-height: 1;
}

.resource-delete-button {
    color: var(--danger);
    border-color: rgba(216, 91, 114, 0.18);
}

.resource-delete-button:hover {
    color: #b43b53;
    border-color: rgba(216, 91, 114, 0.28);
}

.resource-card-meta-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.8rem;
    color: var(--text-soft);
    font-size: 0.92rem;
    font-weight: 700;
    width: 100%;
    min-width: 0;
}

.resource-card-current {
    color: var(--navy);
    font-weight: 700;
    min-height: 0;
    line-height: 1.4;
    width: 100%;
    overflow: hidden;
    overflow-wrap: break-word;
    word-break: normal;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.resource-card h3,
.resource-card-kicker,
.resource-inline-indicator span:last-child,
.resource-card-activity-label,
.resource-card-load-label {
    overflow-wrap: normal;
    word-break: normal;
}

.resource-card h3,
.resource-card-kicker,
.resource-card-load,
.resource-card-current,
.resource-card-tools-label,
.resource-inline-indicator span:last-child {
    max-width: 100%;
}

.resource-card-current-empty {
    color: var(--text-soft);
    font-weight: 600;
}

.resource-status-good {
    color: var(--good);
}

.resource-status-busy {
    color: var(--warn);
}

.resource-status-inactive {
    color: var(--danger);
}

.resource-card-details {
    display: grid;
    gap: 1rem;
    margin-top: 0.2rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(91, 121, 170, 0.14);
}

.resource-card-details .resource-card-tools {
    justify-content: flex-end;
}

.resource-detail-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-auto-rows: max-content;
    column-gap: 1.25rem;
    row-gap: 0;
    align-items: start;
    align-content: start;
}

.resource-detail-grid > div {
    display: grid;
    align-content: start;
    gap: 0.25rem;
    min-width: 0;
    padding: 0.7rem 0;
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
}

.resource-detail-grid dt {
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.resource-detail-grid dd {
    min-width: 0;
    line-height: 1.35;
    overflow-wrap: break-word;
    word-break: normal;
}

.resource-detail-grid > .field-span-2,
.resource-detail-grid > .resource-detail-grid-wide {
    grid-column: 1 / -1;
}

.resource-detail-section {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    align-self: start;
    padding: 1rem 1.1rem;
}

.resource-work-table tbody td {
    vertical-align: top;
}

.resource-modal-card {
    width: min(74rem, calc(100vw - 1.8rem));
}

.resource-modal-card .review-modal-body {
    padding-bottom: 0.35rem;
}

.resource-modal-card .review-modal-body > .resource-maintenance-section {
    margin-top: 0.25rem;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.resource-modal-card .resource-maintenance-section .resource-form-card {
    background: rgba(255, 255, 255, 0.96);
}

.resource-modal-header-actions {
    justify-content: flex-end;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.65rem;
}

.drawing-upload-modal-card {
    width: min(58rem, calc(100vw - 3rem));
}

.admin-workflow-modal-card {
    width: min(86rem, calc(100vw - 3rem));
    max-height: calc(100vh - 3rem);
    overflow: auto;
    box-shadow: 0 28px 64px rgba(18, 35, 61, 0.24);
}

.admin-quote-comment-modal {
    width: min(86rem, calc(100vw - 3rem));
    max-width: calc(100vw - 3rem);
    max-height: calc(100vh - 3rem);
}

.admin-quote-comment-modal-body {
    max-height: calc(100vh - 11rem);
}

.quote-without-email-hint {
    margin: 0;
    padding: 0.75rem 0.9rem;
    border: 1px solid rgba(195, 137, 34, 0.24);
    border-radius: var(--radius-md);
    background: rgba(255, 241, 195, 0.46);
    color: var(--navy-soft);
}

.quote-finalization-actions {
    flex-wrap: wrap;
    align-items: center;
}

.admin-demand-comment-modal {
    width: min(88rem, calc(100vw - 3rem));
    max-width: calc(100vw - 3rem);
    max-height: calc(100vh - 3rem);
}

.admin-demand-comment-modal-body {
    max-height: calc(100vh - 11rem);
}

.company-autocomplete-field {
    position: relative;
}

.company-autocomplete-shell {
    position: relative;
}

.company-suggestion-panel {
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 0;
    right: 0;
    z-index: 16;
    display: grid;
    gap: 0.35rem;
    padding: 0.5rem;
    border: 1px solid rgba(91, 121, 170, 0.18);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 18px 40px rgba(18, 35, 61, 0.18);
}

.company-suggestion-option {
    display: grid;
    gap: 0.15rem;
    justify-items: start;
    width: 100%;
    padding: 0.7rem 0.85rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: rgba(238, 246, 255, 0.72);
    color: var(--text-strong);
    text-align: left;
}

.company-suggestion-option:hover,
.company-suggestion-option:focus-visible {
    border-color: rgba(67, 123, 255, 0.35);
    background: rgba(223, 236, 255, 0.92);
    outline: none;
}

.company-suggestion-option span {
    color: var(--text-muted);
    font-size: 0.82rem;
}

.company-autocomplete-feedback {
    margin-top: 0.75rem;
}

.resource-detail-modal-shell {
    background: linear-gradient(180deg, rgba(18, 35, 61, 0.16), rgba(18, 35, 61, 0.28));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.resource-detail-modal-card {
    width: min(76rem, calc(100vw - 1.6rem));
    max-height: calc(100vh - 1.6rem);
}

.resource-detail-modal-body {
    display: grid;
    gap: 1rem;
}

.resource-detail-modal-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
}

.resource-detail-modal-title {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    min-width: 0;
}

.resource-type-icon-large {
    width: 3.2rem;
    height: 3.2rem;
    border-radius: 999px;
    font-size: 1.35rem;
}

.resource-detail-overview {
    padding: 0 0 1rem;
    border-bottom: 1px solid var(--line);
}

.resource-detail-badge-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.resource-detail-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: nowrap;
    gap: 1rem;
    margin: 0;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.14);
}

.resource-detail-card-header > div:first-child {
    min-width: 0;
}

.resource-detail-card-header h3,
.resource-detail-card-header h4,
.resource-detail-card-header p {
    margin: 0;
}

.resource-detail-card-header .muted {
    margin-top: 0.35rem;
}

.resource-detail-section-kicker {
    color: var(--text-soft);
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    line-height: 1.3;
    text-transform: uppercase;
}

.resource-detail-card-actions {
    flex: 0 0 auto;
    margin-left: auto;
    align-items: flex-start;
    justify-content: flex-end;
}

.resource-detail-subsection {
    display: grid;
    gap: 0.65rem;
    padding-top: 0.15rem;
}

.resource-detail-subsection h4 {
    margin: 0;
    color: var(--navy);
    font-size: 0.86rem;
}

.resource-detail-content-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
        "machine"
        "workspace"
        "rules"
        "orders";
    grid-auto-rows: max-content;
    gap: 0.85rem;
    align-items: start;
    align-content: start;
}

.resource-detail-content-grid .resource-rule-stack {
    grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
    align-items: stretch;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: resource-rule;
}

.resource-detail-content-grid .resource-rule-card {
    counter-increment: resource-rule;
    display: grid;
    grid-template-columns: 2rem minmax(0, 1fr);
    align-content: start;
    gap: 0.35rem 0.75rem;
    min-width: 0;
    padding: 0.9rem;
    border: 1px solid rgba(195, 137, 34, 0.24);
    border-radius: var(--radius-md);
    background: linear-gradient(145deg, rgba(255, 250, 230, 0.98), rgba(248, 235, 193, 0.82));
    box-shadow: 0 8px 18px rgba(142, 105, 37, 0.08);
}

.resource-detail-content-grid .resource-rule-card::before {
    content: counter(resource-rule, decimal-leading-zero);
    grid-column: 1;
    grid-row: 1;
    color: var(--warn);
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.06em;
    line-height: 1.45;
}

.resource-detail-content-grid .resource-rule-card > div {
    display: grid;
    grid-column: 2;
    gap: 0.35rem;
    min-width: 0;
}

.resource-detail-content-grid .resource-rule-card strong {
    line-height: 1.35;
    overflow-wrap: break-word;
    word-break: normal;
}

.resource-detail-content-grid > .review-modal-section {
    margin: 0;
    min-width: 0;
}

.resource-detail-machine-panel {
    grid-area: machine;
}

.resource-detail-workspace-panel {
    grid-area: workspace;
}

.resource-detail-rules-panel {
    grid-area: rules;
}

.resource-detail-orders-panel {
    grid-area: orders;
}

.resource-form-card .button-row {
    justify-content: flex-end;
}

@media (max-width: 900px) {
    .drawing-detail-metadata {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .drawing-detail-context-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .drawing-detail-qr-card,
    .drawing-detail-document-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .drawing-detail-actions {
        justify-content: flex-start;
    }

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

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

    .resource-page-header,
    .resource-workspace-header,
    .resource-detail-modal-title {
        flex-direction: column;
    }

    .resource-page-actions,
    .resource-workspace-side {
        justify-content: flex-start;
        align-items: stretch;
    }

    .resource-page-actions,
    .resource-summary-toggle-row,
    .resource-summary-toggle-actions {
        flex-direction: row;
        flex-wrap: nowrap;
    }

    .resource-summary-toggle-row {
        justify-content: space-between;
        align-items: center;
    }

    .resource-page-actions .ghost-button,
    .resource-page-actions .action-button,
    .resource-summary-toggle-actions .ghost-button {
        white-space: nowrap;
    }

    .resource-summary-toggle-row {
        gap: 0.7rem;
    }

    .resource-summary-toggle-actions {
        gap: 0.55rem;
    }

    .resource-summary-stats .kpi-card {
        width: min(100%, 22rem);
    }

    .resource-contact-list,
    .resource-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .resource-detail-modal-header {
        grid-template-columns: 1fr;
    }

    .resource-modal-header-actions {
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .resource-detail-modal-card {
        width: min(100%, calc(100vw - 1rem));
        max-height: calc(100vh - 1rem);
        padding: 1rem;
    }

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

    .resource-detail-content-grid {
        grid-template-columns: 1fr;
        grid-template-areas:
            "machine"
            "workspace"
            "rules"
            "orders";
    }
}

@media (max-width: 720px) {
    .resource-summary-stats {
        grid-template-columns: 1fr;
    }

    .resource-page-actions,
    .resource-summary-toggle-row,
    .resource-summary-toggle-actions {
        flex-direction: row;
        gap: 0.45rem;
    }

    .resource-page-actions .ghost-button,
    .resource-page-actions .action-button,
    .resource-summary-toggle-actions .ghost-button {
        padding: 0.62rem 0.72rem;
        font-size: 0.74rem;
    }

    .resource-summary-toggle-title {
        font-size: 0.94rem;
        white-space: nowrap;
    }

    .resource-summary-stats .kpi-card,
    .resource-kpi-chart {
        width: 100%;
    }

    .resource-card-grid-free,
    .resource-contact-list,
    .resource-card-grid,
    .resource-detail-grid {
        grid-template-columns: 1fr;
    }

    .resource-detail-badge-row {
        flex-direction: column;
        align-items: stretch;
    }

    .resource-card-head,
    .resource-card-meta-row {
        grid-template-columns: 1fr;
    }

    .resource-card {
        grid-template-rows: repeat(4, auto);
        min-height: 0;
        padding: 1rem 0.95rem;
    }

    .resource-card-meta-row {
        gap: 0.55rem;
    }

    .resource-inline-indicator {
        width: 100%;
        justify-content: flex-start;
    }

    .resource-card-tools {
        grid-template-columns: 1fr auto auto;
    }

    .resource-card-load {
        font-size: 1.35rem;
    }

    .resource-card-load-stack {
        justify-items: start;
    }

    .resource-card-load-label {
        text-align: left;
    }

    .resource-type-icon,
    .resource-type-icon-large {
        width: 2.8rem;
        height: 2.8rem;
    }

    .resource-detail-modal-shell,
    .review-modal-shell {
        padding: 0.65rem;
    }

    .resource-detail-modal-card,
    .resource-modal-card {
        width: 100%;
        max-height: calc(100vh - 1.3rem);
        padding: 0.95rem;
    }

    .resource-card-details {
        padding-top: 0.85rem;
    }
}

@media (max-width: 520px) {
    .drawing-detail-heading,
    .drawing-detail-metadata {
        grid-template-columns: minmax(0, 1fr);
    }

    .drawing-detail-heading .status-pill {
        justify-self: start;
    }
}

@keyframes order-card-highlight-pulse {
    0%,
    100% {
        background: rgba(255, 255, 255, 0.74);
        box-shadow: 0 0 0 rgba(122, 214, 126, 0), 0 0 0 rgba(122, 214, 126, 0);
    }

    20% {
        background: rgba(229, 249, 229, 0.94);
        box-shadow: 0 0 0 1px rgba(122, 214, 126, 0.24), 0 0 28px rgba(122, 214, 126, 0.18);
    }

    45% {
        background: rgba(240, 252, 240, 0.86);
        box-shadow: 0 0 0 1px rgba(122, 214, 126, 0.12), 0 0 14px rgba(122, 214, 126, 0.1);
    }
}

.public-tracking-page {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(16, 35, 63, 0.98) 0 4rem, rgba(200, 235, 255, 0.88) 4rem 27rem, rgba(247, 250, 255, 0.95) 27rem 100%);
}

.public-tracking-topbar {
    background: var(--navy);
    color: #fff;
}

.public-tracking-topbar-inner,
.public-tracking-content,
.public-tracking-feedback-shell,
.public-tracking-hero-inner {
    width: min(1120px, calc(100vw - 2rem));
    margin: 0 auto;
}

.public-tracking-topbar-inner {
    min-height: 4rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.public-tracking-brand {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.public-tracking-brand-logo {
    height: 2.9rem;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 8px 18px rgba(10, 19, 35, 0.24));
}

.public-tracking-brand-copy {
    display: grid;
    gap: 0.12rem;
}

.public-tracking-brand-copy strong {
    font-size: 1.4rem;
    letter-spacing: 0.04em;
}

.public-tracking-brand-copy span {
    color: rgba(255, 255, 255, 0.76);
    font-size: 0.9rem;
}

.public-tracking-topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.public-tracking-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2rem;
    padding: 0.35rem 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 700;
}

.public-tracking-chip-strong {
    border-color: rgba(36, 165, 255, 0.45);
    background: rgba(36, 165, 255, 0.18);
}

.public-tracking-hero {
    padding: 2.25rem 0 2rem;
}

.public-tracking-hero-inner {
    display: block;
}

.public-tracking-hero-steps {
    --public-progress-width: 0%;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1.4rem;
    align-items: start;
    position: relative;
}

.public-tracking-hero-steps::after {
    content: "";
    position: absolute;
    top: 1.95rem;
    left: 10%;
    width: var(--public-progress-width);
    height: 4px;
    background: linear-gradient(90deg, var(--accent-strong), var(--teal));
    transform: translateY(-50%);
    box-shadow: 0 0 0.85rem rgba(17, 112, 230, 0.18);
    border-radius: 999px;
}

.public-tracking-step {
    display: grid;
    gap: 0.6rem;
    text-align: center;
    position: relative;
    z-index: 1;
}

.public-tracking-step-icon-shell {
    position: relative;
    min-height: 4rem;
    display: grid;
    place-items: center;
}

.public-tracking-step-icon {
    position: relative;
    z-index: 1;
    width: 3.75rem;
    height: 3.75rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 2px solid rgba(17, 112, 230, 0.2);
    color: var(--accent-strong);
    box-shadow: 0 10px 24px rgba(16, 35, 63, 0.08);
    font-size: 1.25rem;
}

.public-tracking-step strong {
    color: var(--navy);
    font-size: 0.96rem;
}

.public-tracking-step span {
    color: var(--navy-soft);
    font-size: 0.82rem;
    line-height: 1.45;
}

.public-tracking-step-complete .public-tracking-step-icon {
    background: linear-gradient(180deg, rgba(17, 112, 230, 0.1), rgba(24, 178, 176, 0.12));
    border-color: rgba(17, 112, 230, 0.45);
    color: var(--accent-strong);
}

.public-tracking-step-current .public-tracking-step-icon {
    background: linear-gradient(180deg, rgba(17, 112, 230, 0.92), rgba(24, 178, 176, 0.84));
    border-color: transparent;
    color: #fff;
}

.public-tracking-step-upcoming .public-tracking-step-icon {
    background: rgba(255, 255, 255, 0.74);
    color: rgba(16, 35, 63, 0.5);
    border-color: rgba(91, 121, 170, 0.14);
}

.public-tracking-hero-copy-shell {
    width: min(1120px, calc(100vw - 2rem));
    margin: 0 auto;
    padding: 1.6rem 0 0.4rem;
}

.public-tracking-hero-copy {
    width: min(920px, 100%);
    margin: 0 auto;
    padding-inline: 0.35rem;
    text-align: left;
}

.public-tracking-hero-copy h1 {
    margin: 0;
    color: var(--navy);
    font-size: clamp(2rem, 3vw, 3rem);
    line-height: 1.05;
    outline: none;
    border: 0;
    box-shadow: none;
    max-width: 18ch;
}

.public-tracking-hero-copy p:last-child {
    margin: 1rem 0 0;
    color: var(--navy);
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.65;
    max-width: 72ch;
}

.public-tracking-content {
    display: grid;
    gap: 1.5rem;
    padding-bottom: 3rem;
}

.public-tracking-panel {
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(91, 121, 170, 0.12);
    box-shadow: 0 20px 48px rgba(16, 35, 63, 0.08);
}

.public-tracking-panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.15rem 1.25rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
}

.public-tracking-panel-header h2 {
    margin: 0;
    color: var(--navy);
    font-size: 1.35rem;
}

.public-tracking-panel-header p {
    margin: 0.4rem 0 0;
    color: var(--navy-soft);
    line-height: 1.55;
}

.public-tracking-toggle {
    width: 2.1rem;
    height: 2.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: var(--accent-strong);
    color: #fff;
    font-size: 0.85rem;
    flex-shrink: 0;
}

.public-tracking-section-state {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: 0.35rem 0.85rem;
    background: rgba(17, 112, 230, 0.08);
    color: var(--accent-strong);
    font-size: 0.84rem;
    font-weight: 700;
}

.public-tracking-info-grid,
.public-tracking-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    padding: 1.25rem;
}

.public-tracking-info-card {
    display: grid;
    gap: 0.8rem;
    padding: 1.15rem 1.15rem 1.05rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(248, 251, 255, 0.94);
}

.public-tracking-info-card-wide {
    grid-column: 1 / -1;
}

.public-tracking-info-card h3 {
    margin: 0;
    color: var(--navy);
    font-size: 1.02rem;
}

.public-tracking-info-card dl {
    display: grid;
    gap: 0.6rem;
    margin: 0;
}

.public-tracking-info-card dl div {
    display: grid;
    grid-template-columns: minmax(120px, 0.7fr) minmax(0, 1fr);
    gap: 0.85rem;
}

.public-tracking-info-card dt {
    color: var(--text-soft);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.public-tracking-info-card dd,
.public-tracking-info-note {
    margin: 0;
    color: var(--navy);
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.public-tracking-tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.public-tracking-tag {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: 0.3rem 0.8rem;
    background: rgba(17, 112, 230, 0.08);
    color: var(--accent-strong);
    font-size: 0.82rem;
    font-weight: 700;
}

.public-tracking-subsection {
    display: grid;
    gap: 1rem;
    padding: 0 1.25rem 1.25rem;
}

.public-tracking-subsection-header h3 {
    margin: 0;
    color: var(--navy);
    font-size: 1.08rem;
}

.public-tracking-subsection-header p {
    margin: 0.45rem 0 0;
    color: var(--navy-soft);
    line-height: 1.55;
}

.public-tracking-submit-row {
    padding: 0 1.25rem 1.4rem;
}

.public-tracking-line-list {
    display: grid;
    gap: 0.8rem;
    padding: 0 1.25rem 1.25rem;
}

.public-tracking-line-card {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1rem 0.95rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(248, 251, 255, 0.94);
}

.public-tracking-decision-shell {
    display: grid;
    gap: 1rem;
    padding: 0 1.25rem 1.25rem;
}

.public-tracking-timeline {
    display: grid;
    gap: 0;
    padding: 0 1.25rem 1.5rem;
}

.public-tracking-timeline-item {
    display: grid;
    grid-template-columns: 2rem minmax(0, 1fr);
    gap: 1rem;
    min-height: 5.8rem;
}

.public-tracking-timeline-marker {
    position: relative;
}

.public-tracking-timeline-marker::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: -1rem;
    left: 50%;
    width: 3px;
    transform: translateX(-50%);
    background: rgba(17, 112, 230, 0.18);
}

.public-tracking-timeline-item:last-child .public-tracking-timeline-marker::before {
    bottom: 1.2rem;
}

.public-tracking-timeline-dot {
    position: absolute;
    top: 1rem;
    left: 50%;
    width: 0.95rem;
    height: 0.95rem;
    transform: translateX(-50%);
    background: #f5c323;
    box-shadow: 0 0 0 6px rgba(245, 195, 35, 0.16);
}

.public-tracking-timeline-card {
    display: grid;
    gap: 0.55rem;
    padding: 1rem 1rem 1rem 1.1rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
}

.public-tracking-timeline-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.public-tracking-timeline-meta strong {
    color: var(--navy);
}

.public-tracking-timeline-meta span,
.public-tracking-timeline-card p {
    color: var(--navy-soft);
    line-height: 1.55;
    margin: 0;
}

.public-tracking-timeline-item-complete .public-tracking-timeline-marker::before {
    background: linear-gradient(180deg, var(--accent-strong), rgba(245, 195, 35, 0.8));
}

.public-tracking-timeline-item-pending .public-tracking-timeline-dot {
    background: rgba(91, 121, 170, 0.3);
    box-shadow: 0 0 0 6px rgba(91, 121, 170, 0.08);
}

.public-tracking-empty-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem;
}

.public-tracking-empty-card {
    width: min(700px, 100%);
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 1rem;
    padding: 1.5rem;
    border: 1px solid rgba(91, 121, 170, 0.12);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 20px 48px rgba(16, 35, 63, 0.08);
}

.public-tracking-empty-icon {
    width: 3.4rem;
    height: 3.4rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(17, 112, 230, 0.08);
    color: var(--accent-strong);
    font-size: 1.2rem;
}

@media (max-width: 1024px) {
    .public-tracking-hero {
        padding: 2rem 0 2.85rem;
    }

    .public-tracking-hero-copy-shell {
        width: min(1120px, calc(100vw - 2rem));
        padding-top: 1.35rem;
    }

    .public-tracking-hero-copy {
        width: 100%;
        padding-inline: 0;
    }

    .public-tracking-hero-copy h1 {
        max-width: 100%;
        font-size: clamp(2rem, 4.4vw, 2.7rem);
    }

    .public-tracking-hero-copy p:last-child {
        max-width: 60ch;
        font-size: 0.96rem;
    }
}

@media (max-width: 1200px) {
    .public-tracking-hero-steps {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .public-tracking-panel-header,
    .public-tracking-timeline-meta,
    .public-tracking-line-card,
    .public-tracking-empty-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .public-tracking-topbar-inner,
    .public-tracking-content,
    .public-tracking-feedback-shell,
    .public-tracking-hero-inner,
    .public-tracking-hero-copy-shell {
        width: min(100vw - 1rem, 1120px);
    }

    .public-tracking-hero-steps {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1rem;
    }

    .public-tracking-hero-steps::after {
        display: none;
    }

    .public-tracking-hero {
        padding: 1.8rem 0 2.4rem;
    }

    .public-tracking-hero-copy-shell {
        padding-top: 1.1rem;
    }

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

    .public-tracking-brand-logo {
        height: 2.4rem;
    }

    .public-tracking-brand-copy strong {
        font-size: 1.2rem;
    }

    .public-tracking-brand-copy span {
        font-size: 0.84rem;
    }

    .public-tracking-hero-copy h1 {
        font-size: clamp(1.9rem, 5vw, 2.45rem);
        line-height: 1.08;
    }

    .public-tracking-hero-copy p:last-child {
        margin-top: 0.8rem;
        font-size: 0.95rem;
        line-height: 1.6;
        max-width: 100%;
    }

    .public-tracking-info-grid,
    .public-tracking-form-grid {
        grid-template-columns: 1fr;
    }

    .public-tracking-info-card dl div {
        grid-template-columns: 1fr;
        gap: 0.2rem;
    }

    .public-tracking-timeline-item {
        grid-template-columns: 1.4rem minmax(0, 1fr);
        gap: 0.75rem;
    }
}

@media (max-width: 560px) {
    .public-tracking-page {
        background:
            linear-gradient(180deg, rgba(16, 35, 63, 0.98) 0 4.15rem, rgba(200, 235, 255, 0.88) 4.15rem 19rem, rgba(247, 250, 255, 0.95) 19rem 100%);
    }

    .public-tracking-hero {
        padding: 1.25rem 0 1.5rem;
    }

    .public-tracking-hero-steps {
        display: none;
    }

    .public-tracking-hero-copy-shell {
        width: min(100vw - 1rem, 1120px);
        padding-top: 1rem;
    }

    .public-tracking-topbar-inner {
        min-height: auto;
        padding: 0.7rem 0;
        flex-direction: column;
        align-items: flex-start;
    }

    .public-tracking-topbar-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .public-tracking-brand {
        gap: 0.7rem;
        flex-direction: row;
        align-items: center;
    }

    .public-tracking-brand-logo {
        height: 2rem;
    }

    .public-tracking-brand-copy strong {
        font-size: 1.05rem;
    }

    .public-tracking-brand-copy span {
        font-size: 0.78rem;
    }

    .public-tracking-chip {
        min-height: 1.85rem;
        padding: 0.3rem 0.72rem;
        font-size: 0.76rem;
    }

    .public-tracking-hero-copy h1 {
        font-size: clamp(1.7rem, 8vw, 2.15rem);
    }

.public-tracking-hero-copy p:last-child {
        font-size: 0.92rem;
    }
}

/* Role selector page refresh: align the entry page with the shared app shell. */
.entry-shell-app {
    min-height: 100vh;
    padding: 0 0 2rem;
    background:
        linear-gradient(180deg, rgba(16, 35, 63, 0.98) 0 5.4rem, rgba(200, 235, 255, 0.18) 5.4rem 12rem, rgba(245, 249, 255, 0.96) 12rem 100%);
}

.entry-shell-app .entry-backdrop {
    filter: blur(34px);
}

.entry-shell-app .entry-backdrop-left {
    top: 7rem;
    left: -8rem;
    width: 28rem;
    height: 28rem;
    background: radial-gradient(circle, rgba(36, 165, 255, 0.2), transparent 66%);
}

.entry-shell-app .entry-backdrop-right {
    right: -10rem;
    bottom: 2rem;
    width: 30rem;
    height: 30rem;
    background: radial-gradient(circle, rgba(24, 178, 176, 0.16), transparent 70%);
}

.entry-nav-shell {
    position: sticky;
    top: 0;
    z-index: 220;
}

.entry-nav-surface {
    padding: 0.45rem 1rem;
}

.entry-nav-row {
    max-width: 1380px;
    min-height: 4.6rem;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.entry-nav-brand {
    text-decoration: none;
}

.entry-nav-chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.7rem;
}

.entry-shell-app .entry-frame {
    max-width: 1380px;
    margin: 0 auto;
    padding: 1.5rem 1rem 0;
    gap: 1.25rem;
}

.entry-hero-card,
.entry-role-section {
    padding: 1.5rem;
}

.entry-page-header {
    grid-template-columns: minmax(0, 1.3fr) minmax(22rem, 0.95fr);
    align-items: center;
    gap: 1.5rem;
}

.entry-shell-app .entry-hero-copy {
    gap: 0.65rem;
    padding: 0;
}

.entry-shell-app .entry-hero-copy h1 {
    font-size: clamp(2.5rem, 4vw, 4rem);
    line-height: 0.98;
}

.entry-shell-app .entry-hero-copy .lede {
    max-width: 62ch;
    margin: 0;
}

.entry-hero-side {
    display: grid;
    grid-template-columns: minmax(12rem, 16rem) minmax(0, 1fr);
    align-items: center;
    gap: 1.2rem;
    min-width: 0;
    padding: 1rem 1.15rem;
    border-left: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(244, 248, 255, 0.8), rgba(234, 244, 255, 0.62));
}

.entry-hero-side-copy {
    display: grid;
    gap: 0.7rem;
    align-content: center;
}

.entry-shell-app .entry-logo-shell {
    min-height: 0;
}

.entry-shell-app .entry-logo {
    width: 100%;
    max-width: 15rem;
}

.entry-shell-app .entry-meta-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1rem;
}

.entry-shell-app .entry-stat-card {
    min-height: 7rem;
    padding: 1.15rem 1.2rem;
    border-left: 4px solid rgba(106, 174, 247, 0.74);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(238, 245, 255, 0.88));
    box-shadow: 0 20px 40px rgba(16, 35, 63, 0.08);
}

.entry-shell-app .entry-stat-head span:first-child {
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.entry-shell-app .entry-stat-card strong {
    font-size: clamp(2rem, 2.3vw, 2.65rem);
}

.entry-role-section {
    display: grid;
    gap: 1rem;
}

.entry-shell-app .entry-role-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1rem;
}

.entry-shell-app .entry-role-card {
    min-height: 22rem;
    padding: 1.25rem;
    justify-items: stretch;
    text-align: left;
    border-left: 4px solid transparent;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(240, 246, 255, 0.9));
    box-shadow: 0 18px 34px rgba(16, 35, 63, 0.08);
    transition:
        transform 160ms ease,
        box-shadow 160ms ease,
        border-color 160ms ease;
}

.entry-shell-app .entry-role-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 44px rgba(16, 35, 63, 0.12);
}

.entry-shell-app .entry-role-card-active {
    border-left-color: rgba(17, 112, 230, 0.88);
}

.entry-shell-app .entry-role-head,
.entry-shell-app .entry-role-body {
    gap: 0.85rem;
}

.entry-shell-app .entry-role-heading {
    grid-template-columns: auto minmax(0, 1fr);
    gap: 0.95rem;
    justify-items: start;
    align-items: start;
}

.entry-shell-app .entry-role-heading-copy {
    gap: 0.45rem;
    justify-items: start;
}

.entry-role-title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.55rem;
}

.entry-role-kicker {
    margin: 0;
}

.entry-shell-app .entry-role-badge {
    width: 3rem;
    height: 3rem;
    font-size: 1.05rem;
    flex-shrink: 0;
}

.entry-shell-app .entry-role-head h2 {
    font-size: clamp(1.25rem, 1.5vw, 1.7rem);
}

.entry-shell-app .entry-role-body {
    justify-items: start;
    align-content: start;
}

.entry-shell-app .entry-role-summary,
.entry-shell-app .entry-role-outcome {
    max-width: none;
}

.entry-shell-app .entry-role-actions {
    width: 100%;
    justify-content: flex-start;
}

.entry-shell-app .entry-role-actions .action-button {
    width: 100%;
    justify-content: center;
}

@media (max-width: 1200px) {
    .entry-shell-app .entry-role-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .entry-page-header {
        grid-template-columns: minmax(0, 1fr);
    }

    .entry-hero-side {
        grid-template-columns: minmax(12rem, 15rem) minmax(0, 1fr);
        border-left: 0;
        border-top: 1px solid rgba(91, 121, 170, 0.14);
    }
}

@media (max-width: 900px) {
    .entry-nav-row,
    .entry-nav-chips {
        justify-content: flex-start;
    }

    .entry-nav-row {
        flex-direction: column;
        align-items: stretch;
        min-height: 0;
    }

    .entry-nav-chips {
        gap: 0.55rem;
    }

    .entry-shell-app .entry-meta-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .entry-shell-app .entry-role-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .entry-hero-side {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .entry-shell-app {
        padding-bottom: 1rem;
    }

    .entry-nav-surface,
    .entry-shell-app .entry-frame {
        padding-left: 0.85rem;
        padding-right: 0.85rem;
    }

    .entry-nav-chips {
        width: 100%;
    }

    .entry-nav-chips .public-tracking-chip {
        width: 100%;
        justify-content: center;
    }

    .entry-hero-card,
    .entry-role-section {
        padding: 1rem;
    }

    .entry-shell-app .entry-meta-row,
    .entry-shell-app .entry-role-grid {
        grid-template-columns: 1fr;
    }

    .entry-shell-app .entry-role-card {
        min-height: auto;
    }

    .entry-shell-app .entry-hero-copy h1 {
        font-size: clamp(2rem, 10vw, 2.7rem);
    }
}

/* Role selector auth layout */
.entry-shell-auth {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding: 0;
    background:
        linear-gradient(180deg, rgba(16, 35, 63, 0.98) 0 4.2rem, rgba(229, 241, 255, 0.82) 4.2rem 100%);
}

/* Account auth and superadmin */
.entry-login-form {
    display: grid;
    gap: 0.9rem;
}

.entry-login-submit {
    width: 100%;
    justify-content: center;
}

.entry-form-error {
    margin: 0;
    padding: 0.85rem 1rem;
    border: 1px solid rgba(173, 56, 56, 0.2);
    border-radius: 1rem;
    background: rgba(255, 240, 240, 0.92);
    color: #8d2424;
    font-weight: 700;
}

.entry-login-hints {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
}

.entry-hint-card {
    display: grid;
    gap: 0.25rem;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(240, 246, 255, 0.9));
    box-shadow: 0 16px 28px rgba(16, 35, 63, 0.06);
}

.entry-hint-card strong {
    color: var(--navy);
}

.entry-hint-card span {
    color: var(--text-soft);
    word-break: break-word;
}

.superadmin-shell {
    min-height: 100vh;
    background:
        linear-gradient(180deg, rgba(13, 28, 52, 0.96), rgba(20, 47, 84, 0.94) 5.5rem, #eef4fc 5.5rem 100%);
}

.superadmin-topbar {
    position: sticky;
    top: 0;
    z-index: 250;
    border-bottom: 1px solid rgba(168, 196, 238, 0.16);
    background:
        linear-gradient(180deg, rgba(13, 28, 52, 0.98), rgba(18, 43, 79, 0.97)),
        radial-gradient(circle at top left, rgba(36, 165, 255, 0.12), transparent 22%),
        radial-gradient(circle at top right, rgba(24, 178, 176, 0.1), transparent 18%);
    box-shadow: 0 16px 30px rgba(16, 35, 63, 0.16);
}

.superadmin-topbar-inner {
    position: relative;
    width: 100%;
    min-height: 4.4rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0 clamp(1rem, 2vw, 1.75rem);
    box-sizing: border-box;
}

.superadmin-mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
}

.superadmin-mobile-panel {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex: 1 1 auto;
    min-width: 0;
}

.superadmin-mobile-toggle {
    display: none;
    width: 3rem;
    height: 3rem;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(168, 196, 238, 0.18);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
    color: #fff;
    box-shadow: 0 12px 24px rgba(7, 16, 31, 0.16);
}

.superadmin-mobile-toggle:hover,
.superadmin-mobile-toggle:focus-visible {
    border-color: rgba(122, 185, 255, 0.36);
    background: linear-gradient(180deg, rgba(44, 121, 243, 0.24), rgba(24, 178, 176, 0.16));
}

.superadmin-nav {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1 1 auto;
}

.superadmin-nav .menu-link {
    display: inline-flex;
    align-items: center;
    min-height: 2.8rem;
}

.superadmin-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.superadmin-actions .ghost-button {
    font-weight: 700;
}

.superadmin-main {
    width: 100%;
    margin: 0;
    padding: 1.5rem clamp(1rem, 2vw, 1.75rem) 2rem;
    box-sizing: border-box;
}

.superadmin-page {
    gap: 1.25rem;
}

.superadmin-kpi-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.superadmin-summary-card,
.superadmin-form-card,
.superadmin-table-card {
    padding: 1.35rem;
}

.superadmin-summary-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
}

.superadmin-summary-head h2 {
    margin: 0 0 0.25rem;
}

.superadmin-customer-form {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.superadmin-customer-form-wide {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.superadmin-customer-form > .action-button {
    align-self: end;
}

.superadmin-activity-chart {
    display: grid;
    grid-template-columns: 3.5rem minmax(0, 1fr);
    gap: 0.75rem;
    margin-top: 1.25rem;
    padding: 1rem 1rem 0.85rem;
    border: 1px solid rgba(84, 112, 135, 0.16);
    border-radius: 1rem;
    background: rgba(241, 245, 244, 0.78);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.superadmin-chart-axis {
    height: 16.1rem;
    margin-top: 1.5rem;
    padding: 0.1rem 0 0.15rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
    color: #607386;
    font-size: 0.76rem;
    font-variant-numeric: tabular-nums;
}

.superadmin-chart-scroll {
    min-width: 0;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: thin;
}

.superadmin-chart-scroll:focus-visible {
    outline: 3px solid rgba(39, 95, 200, 0.28);
    outline-offset: 4px;
}

.superadmin-chart-plot {
    min-width: max(100%, calc(var(--chart-series-count) * 7.75rem));
}

.superadmin-chart-bars,
.superadmin-chart-labels {
    display: grid;
    grid-template-columns: repeat(var(--chart-series-count), minmax(6.25rem, 1fr));
    gap: clamp(0.65rem, 2vw, 1.5rem);
}

.superadmin-chart-bars {
    position: relative;
    height: 17.6rem;
    align-items: stretch;
    padding: 1.5rem 0.8rem 0;
}

.superadmin-chart-bars::before {
    content: "";
    position: absolute;
    inset: 1.5rem 0 0;
    border-left: 1px solid rgba(66, 92, 112, 0.26);
    border-bottom: 1px solid rgba(66, 92, 112, 0.26);
    background: repeating-linear-gradient(
        to bottom,
        rgba(77, 106, 129, 0.11) 0,
        rgba(77, 106, 129, 0.11) 1px,
        transparent 1px,
        transparent 20%);
    pointer-events: none;
}

.superadmin-chart-column {
    position: relative;
    z-index: 1;
    min-width: 0;
    height: 100%;
}

.superadmin-chart-value {
    position: absolute;
    right: 0;
    bottom: min(calc(var(--bar-height) + 0.3rem), calc(100% - 1.2rem));
    left: 0;
    color: #183d62;
    font-size: 0.82rem;
    font-weight: 750;
    font-variant-numeric: tabular-nums;
    text-align: center;
}

.superadmin-chart-bar-track {
    height: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}

.superadmin-chart-bar {
    display: block;
    width: min(72%, 3.6rem);
    height: var(--bar-height);
    min-height: 0;
    border-radius: 0.7rem 0.7rem 0.18rem 0.18rem;
    background:
        linear-gradient(180deg, #34c5ba 0%, #2774c8 100%);
    box-shadow:
        0 8px 16px rgba(39, 116, 200, 0.18),
        inset 1px 1px 0 rgba(255, 255, 255, 0.34);
}

.superadmin-chart-labels {
    padding: 0.75rem 0.8rem 0;
}

.superadmin-chart-label {
    min-width: 0;
    display: grid;
    align-content: start;
    gap: 0.25rem;
    text-align: center;
}

.superadmin-chart-label strong,
.superadmin-chart-label span {
    overflow-wrap: anywhere;
}

.superadmin-chart-label strong {
    color: #183d62;
    font-size: 0.88rem;
    line-height: 1.3;
}

.superadmin-chart-label span {
    color: #607386;
    font-size: 0.76rem;
    line-height: 1.35;
}

.superadmin-security-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.superadmin-security-mode {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.superadmin-security-mode-button-active {
    border-color: rgba(31, 157, 255, 0.55);
    background: linear-gradient(180deg, rgba(31, 157, 255, 0.16), rgba(31, 157, 255, 0.08));
    color: var(--navy);
}

.upload-dropzone-compact {
    display: grid;
    align-items: start;
    gap: 0.45rem;
}

.upload-dropzone-compact > strong:not(.upload-action-button) {
    display: none;
}

.upload-dropzone-compact > span:last-of-type {
    display: none;
}

.upload-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.6rem;
    padding: 0.7rem 1rem;
    border: 1px solid rgba(17, 112, 230, 0.24);
    background: linear-gradient(180deg, rgba(66, 135, 245, 0.96), rgba(36, 115, 230, 0.92));
    color: #fff !important;
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.upload-dropzone-dragover {
    border-color: rgba(17, 112, 230, 0.68);
    box-shadow: inset 0 0 0 1px rgba(17, 112, 230, 0.14), 0 16px 32px rgba(36, 115, 230, 0.08);
    background:
        radial-gradient(circle at top right, rgba(36, 165, 255, 0.14), transparent 38%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(231, 241, 255, 0.94));
}

.upload-dropzone-dragover .upload-action-button {
    color: #fff !important;
    background: linear-gradient(180deg, rgba(55, 125, 235, 0.98), rgba(24, 101, 220, 0.95));
}

.upload-dropzone-busy,
.upload-dropzone-busy .upload-action-button {
    cursor: progress;
}

.upload-dropzone-busy {
    opacity: 0.78;
}

.upload-action-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem 0.8rem;
    align-items: center;
}

.upload-action-meta strong,
.upload-action-meta span {
    color: var(--text-soft);
    font-size: 0.9rem;
}

.upload-action-meta strong {
    color: var(--navy);
    font-weight: 700;
}

.secondary-notification-toggle > span:not(.secondary-notification-toggle-label) {
    display: none;
}

.secondary-notification-toggle-label {
    color: var(--text);
}

@media (max-width: 960px) {
    .entry-login-hints,
    .superadmin-kpi-grid,
    .superadmin-security-summary,
    .superadmin-customer-form,
    .superadmin-customer-form-wide {
        grid-template-columns: 1fr;
    }

    .superadmin-summary-head {
        flex-direction: column;
        align-items: stretch;
    }

    .superadmin-activity-chart {
        grid-template-columns: 2.75rem minmax(0, 1fr);
        gap: 0.5rem;
        padding-inline: 0.7rem;
    }
}

/* Match the compact application navigation breakpoint for the superadmin shell. */
@media (max-width: 1440px) {
    .superadmin-topbar-inner {
        display: block;
        min-height: 0;
        padding-block: 0;
    }

    .superadmin-mobile-header {
        min-height: 4.25rem;
        width: 100%;
    }

    .superadmin-mobile-toggle {
        display: inline-flex;
        flex: 0 0 auto;
    }

    .superadmin-mobile-panel {
        display: none;
        position: absolute;
        inset: 100% 0 auto;
        width: 100%;
        max-height: calc(100dvh - 4.25rem);
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
        overflow-y: auto;
        overscroll-behavior: contain;
        padding: 0.75rem 0.85rem;
        background: linear-gradient(180deg, #122b4f, #0d1c34);
        box-shadow: var(--shadow-lg);
    }

    .superadmin-mobile-panel.superadmin-mobile-panel-open {
        display: flex;
    }

    .superadmin-mobile-panel > * {
        flex: 0 0 auto;
    }

    .superadmin-nav {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 0.55rem;
    }

    .superadmin-nav .menu-link,
    .superadmin-actions,
    .superadmin-actions .ghost-button {
        width: 100%;
    }

    .superadmin-actions {
        flex-direction: column;
        align-items: stretch;
    }
}

.entry-shell-auth .entry-backdrop-left {
    top: 9rem;
    left: -10rem;
    width: 34rem;
    height: 34rem;
    background: radial-gradient(circle, rgba(36, 165, 255, 0.14), transparent 68%);
}

.entry-shell-auth .entry-backdrop-right {
    right: -8rem;
    bottom: 5rem;
    width: 28rem;
    height: 28rem;
    background: radial-gradient(circle, rgba(24, 178, 176, 0.12), transparent 70%);
}

.entry-utility-bar {
    position: sticky;
    top: 0;
    z-index: 220;
    border-bottom: 1px solid rgba(168, 196, 238, 0.14);
    background:
        linear-gradient(180deg, rgba(13, 28, 52, 0.98), rgba(18, 43, 79, 0.97)),
        radial-gradient(circle at top left, rgba(36, 165, 255, 0.12), transparent 22%),
        radial-gradient(circle at top right, rgba(24, 178, 176, 0.1), transparent 18%);
    box-shadow: 0 16px 30px rgba(16, 35, 63, 0.18);
}

.entry-utility-inner {
    width: min(1180px, calc(100vw - 2rem));
    min-height: 4.2rem;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.entry-utility-copy {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    min-width: 0;
}

.entry-utility-copy {
    flex-wrap: wrap;
}

.entry-utility-brand {
    margin-right: 0.2rem;
    text-decoration: none;
}

.entry-auth-frame {
    flex: 1 0 auto;
    width: min(1180px, calc(100vw - 2rem));
    margin: 0 auto;
    padding-top: 1.7rem;
    padding-bottom: 1.5rem;
    gap: 1.5rem;
}

.entry-auth-layout {
    display: grid;
    grid-template-columns: minmax(19rem, 23rem) minmax(0, 1fr);
    gap: 1.5rem;
    align-items: start;
    padding: 1.5rem;
}

.entry-auth-card,
.entry-benefit-shell {
    display: grid;
    gap: 1.2rem;
}

.entry-auth-card {
    align-content: start;
    padding: 1.35rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(239, 245, 255, 0.9));
    box-shadow: 0 18px 34px rgba(16, 35, 63, 0.08);
}

.entry-auth-card-copy {
    display: grid;
    gap: 0.55rem;
}

.entry-auth-card-copy h2,
.entry-secondary-shell h3 {
    margin: 0;
}

.entry-auth-card-copy p,
.entry-benefit-copy p,
.entry-secondary-shell p,
.entry-footer-brand span,
.entry-footer-contact a {
    margin: 0;
}

.entry-auth-role-list {
    display: grid;
    gap: 0.7rem;
}

.entry-role-option {
    width: 100%;
    justify-content: flex-start;
    align-items: center;
    gap: 0.8rem;
    padding: 0.85rem 0.95rem;
    background: rgba(255, 255, 255, 0.86);
}

.entry-role-option:hover,
.entry-role-option:focus-visible {
    background: rgba(232, 241, 255, 0.98);
}

.entry-role-option-active {
    border-color: rgba(17, 112, 230, 0.4);
    box-shadow: 0 0 0 3px rgba(36, 165, 255, 0.1);
}

.entry-role-option-icon {
    width: 2.7rem;
    height: 2.7rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.96rem;
    flex-shrink: 0;
    box-shadow: 0 10px 20px rgba(17, 112, 230, 0.22);
}

.entry-role-option-copy {
    display: grid;
    gap: 0.18rem;
    text-align: left;
}

.entry-role-option-copy strong {
    color: var(--navy);
    font-size: 0.94rem;
}

.entry-role-option-copy span {
    color: var(--text-soft);
    font-size: 0.8rem;
}

.entry-benefit-shell {
    align-content: start;
    gap: 1.5rem;
}

.entry-benefit-copy {
    display: grid;
    gap: 0.75rem;
    max-width: 60ch;
}

.entry-benefit-copy h1 {
    font-size: clamp(2rem, 3vw, 2.8rem);
    line-height: 1.06;
}

.entry-secondary-shell {
    display: grid;
    gap: 0.9rem;
    padding: 1.2rem 1.25rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(240, 246, 255, 0.86));
}

.entry-meta-row-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.entry-shell-auth .entry-stat-card {
    min-height: 6.2rem;
    padding: 0.95rem 1rem;
    border-left: 4px solid rgba(106, 174, 247, 0.74);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(238, 245, 255, 0.88));
    box-shadow: 0 14px 28px rgba(16, 35, 63, 0.06);
}

.entry-shell-auth .entry-stat-sparkline polyline {
    stroke: rgba(37, 112, 220, 0.28);
    stroke-width: 3;
}

.entry-shell-auth .entry-stat-head span:first-child {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.entry-shell-auth .entry-stat-card strong {
    font-size: clamp(1.7rem, 2vw, 2.3rem);
}

.entry-site-footer {
    margin-top: auto;
    padding: 1.1rem 0 calc(1.6rem + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid rgba(168, 196, 238, 0.14);
    background:
        linear-gradient(180deg, rgba(13, 28, 52, 0.98), rgba(18, 43, 79, 0.97)),
        radial-gradient(circle at top left, rgba(36, 165, 255, 0.12), transparent 22%),
        radial-gradient(circle at top right, rgba(24, 178, 176, 0.1), transparent 18%);
    box-shadow: 0 -16px 30px rgba(16, 35, 63, 0.08);
}

.entry-site-footer-inner {
    width: min(1180px, calc(100vw - 2rem));
    margin: 0 auto;
    display: grid;
    gap: 1rem;
}

.entry-footer-links {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.8rem 1rem;
    margin: 0;
    padding: 0 0.25rem;
    list-style: none;
    color: rgba(232, 240, 255, 0.78);
    font-size: 0.84rem;
    font-weight: 700;
}

.entry-footer-link-item {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    min-width: 0;
}

.entry-footer-link-item i {
    color: rgba(130, 196, 255, 0.98);
    font-size: 0.9rem;
    flex-shrink: 0;
}

.entry-footer-link-item span {
    min-width: 0;
}

.entry-footer-band {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: center;
    padding: 1.25rem 0.25rem 0;
    border-top: 1px solid rgba(168, 196, 238, 0.14);
}

.entry-footer-brand,
.entry-footer-contact,
.entry-footer-developer {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.entry-footer-brand div,
.entry-footer-contact,
.entry-footer-developer div {
    display: grid;
    gap: 0.2rem;
}

.entry-footer-meta {
    display: grid;
    gap: 0.9rem;
    justify-items: end;
}

.entry-footer-developer {
    justify-content: flex-end;
    min-width: 0;
}

.entry-footer-brand strong,
.entry-footer-contact strong,
.entry-footer-developer strong {
    color: #fff;
}

.entry-footer-contact a {
    color: rgba(130, 196, 255, 0.98);
    font-weight: 700;
    text-decoration: none;
}

.entry-footer-contact a:hover,
.entry-footer-contact a:focus-visible {
    text-decoration: underline;
}

.entry-footer-brand span {
    color: rgba(232, 240, 255, 0.78);
}

.entry-footer-developer span {
    color: rgba(232, 240, 255, 0.72);
}

.entry-footer-logo {
    width: auto;
    height: 3rem;
    object-fit: contain;
    flex-shrink: 0;
}

.entry-footer-logo-primary {
    height: 2.4rem;
    max-width: min(100%, 12rem);
}

.entry-footer-developer-logo {
    display: block;
    width: 5.25rem;
    max-width: 100%;
    max-height: 1.1rem;
    height: auto;
    object-fit: contain;
    flex-shrink: 0;
}

@media (max-width: 1024px) {
    .entry-auth-layout {
        grid-template-columns: 1fr;
    }

    .entry-benefit-copy {
        max-width: none;
    }

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

    .entry-footer-meta {
        justify-items: start;
    }
}

@media (max-width: 900px) {
    .entry-utility-inner,
    .entry-utility-copy,
    .entry-footer-band {
        align-items: flex-start;
    }

    .entry-utility-inner,
    .entry-footer-band {
        grid-template-columns: 1fr;
    }

    .entry-utility-inner {
        width: min(100vw - 1.7rem, 1180px);
        min-height: 0;
        padding: 0.8rem 0;
        flex-direction: column;
    }

    .entry-auth-frame {
        width: min(100vw - 1.5rem, 1180px);
        padding-top: 1.2rem;
        padding-bottom: 1.2rem;
    }

    .entry-auth-layout {
        gap: 1.15rem;
        padding: 1.15rem;
    }

    .entry-auth-card,
    .entry-secondary-shell {
        padding: 1.1rem;
    }

    .entry-meta-row-compact {
        grid-template-columns: 1fr 1fr;
    }

    .entry-footer-band {
        display: grid;
    }

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

@media (max-width: 720px) {
    .entry-shell-auth {
        min-height: 100dvh;
    }

    .entry-auth-frame {
        width: min(100vw - 1rem, 1180px);
        padding-top: 1rem;
        padding-bottom: 1rem;
    }

    .entry-auth-layout,
    .entry-secondary-shell,
    .entry-footer-band {
        padding: 1rem;
    }

    .entry-auth-card,
    .entry-auth-layout {
        padding: 1rem;
    }

    .entry-benefit-copy h1 {
        font-size: clamp(1.7rem, 8vw, 2.2rem);
    }

    .entry-meta-row-compact {
        grid-template-columns: 1fr;
    }

    .entry-footer-links {
        grid-template-columns: 1fr;
        gap: 0.7rem;
    }

    .entry-footer-brand,
    .entry-footer-contact,
    .entry-footer-developer {
        align-items: flex-start;
    }

    .entry-footer-band {
        grid-template-columns: 1fr;
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }

    .entry-footer-logo {
        height: 2.5rem;
    }
}

@media (max-width: 560px) {
    .entry-utility-inner {
        width: min(100vw - 1rem, 1180px);
    }

    .entry-role-option {
        padding: 0.8rem;
    }

    .entry-role-option-copy strong {
        font-size: 0.9rem;
    }

    .entry-role-option-copy span,
    .entry-footer-links,
    .entry-footer-brand span,
    .entry-footer-contact a {
        font-size: 0.78rem;
    }

    .entry-footer-brand {
        gap: 0.75rem;
    }
}

.app-nav-profile-avatar-image,
.profile-avatar-image {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(114, 154, 220, 0.35);
    background: #dce8fb;
}

.app-nav-profile-avatar-fallback,
.profile-avatar-fallback {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2a5a97 0%, #6bb4ff 100%);
    color: #fff;
    font-weight: 800;
}

.profile-page-shell {
    gap: 1.5rem;
}

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

.profile-card {
    display: grid;
    align-content: start;
    gap: 1.25rem;
    min-width: 0;
}

.profile-hero {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.profile-hero-copy {
    display: grid;
    gap: 0.2rem;
}

.profile-data-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 1.25rem;
}

.profile-data-grid > div {
    display: grid;
    gap: 0.35rem;
}

.profile-data-grid strong {
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #5d7193;
}

.profile-company-communication {
    display: grid;
    gap: 0.7rem;
    min-width: 0;
}

.profile-company-communication-toggle {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    gap: 0.65rem;
    width: auto;
    max-width: 100%;
    min-height: 2.75rem;
    padding: 0.65rem 0.9rem;
    line-height: 1.35;
    cursor: pointer;
}

.profile-company-communication-toggle input {
    flex: 0 0 auto;
    width: 1rem;
    height: 1rem;
    margin: 0;
}

.profile-company-communication-toggle span {
    min-width: 0;
}

.profile-company-communication-description {
    margin: 0;
    max-width: 72ch;
}

.coworker-modal-card {
    max-width: 1024px;
}

.coworker-modal-body {
    display: grid;
    gap: 1rem;
}

.coworker-permission-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
}

.coworker-permission-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    border: 1px solid rgba(115, 141, 180, 0.28);
    background: rgba(242, 247, 255, 0.78);
}

.coworker-permission-option-selected {
    border-color: rgba(41, 117, 214, 0.6);
    background: rgba(217, 234, 255, 0.82);
}

@media (max-width: 980px) {
    .profile-page-grid,
    .profile-data-grid,
    .coworker-permission-grid {
        grid-template-columns: 1fr;
    }
}

.scheduler-page-header,
.scheduler-page-actions,
.scheduler-control-row,
.scheduler-control-group,
.scheduler-kpi-strip,
.scheduler-kpi-card,
.scheduler-workspace-grid,
.scheduler-sidebar,
.scheduler-sidebar-header,
.scheduler-sidebar-stack,
.scheduler-sidebar-card,
.scheduler-date-badge,
.scheduler-board-stack,
.scheduler-day-shell,
.scheduler-day-header,
.scheduler-board,
.scheduler-board-body,
.scheduler-board-lane-label,
.scheduler-board-track,
.scheduler-board-footer,
.scheduler-footer-panel,
.scheduler-utilization-stack,
.scheduler-utilization-row,
.scheduler-risk-grid,
.scheduler-risk-card,
.scheduler-drag-ghost {
    display: grid;
}

.scheduler-page-header {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 1rem;
}

.scheduler-page-actions {
    grid-auto-flow: column;
    align-items: center;
    gap: 0.65rem;
}

.scheduler-date-badge {
    gap: 0.16rem;
    min-width: 12rem;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(91, 121, 170, 0.16);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(235, 244, 255, 0.9));
    box-shadow: var(--shadow-md);
}

.scheduler-date-badge strong {
    color: var(--navy);
    font-size: 1rem;
}

.scheduler-date-badge span,
.scheduler-control-label {
    color: var(--text-soft);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.scheduler-control-card {
    padding: 1rem 1.1rem;
}

.scheduler-control-row {
    grid-template-columns: auto auto;
    gap: 1rem;
    align-items: end;
}

.scheduler-control-group {
    gap: 0.5rem;
    align-content: start;
}

.scheduler-segmented {
    justify-self: start;
}

.scheduler-kpi-strip {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
}

.scheduler-summary-card {
    display: grid;
    gap: 1rem;
}

.scheduler-kpi-card {
    gap: 0.2rem;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(91, 121, 170, 0.16);
    background:
        linear-gradient(135deg, rgba(16, 35, 63, 0.96), rgba(22, 60, 110, 0.94)),
        linear-gradient(180deg, rgba(255, 255, 255, 0.2), transparent);
    box-shadow: 0 14px 28px rgba(16, 35, 63, 0.18);
}

.scheduler-kpi-card span {
    color: rgba(222, 235, 255, 0.72);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.scheduler-kpi-card strong {
    color: #fff;
    font-size: clamp(1.45rem, 1.8vw, 2rem);
    line-height: 1;
}

.scheduler-kpi-card-warn {
    background:
        linear-gradient(135deg, rgba(126, 62, 18, 0.98), rgba(187, 113, 39, 0.94)),
        linear-gradient(180deg, rgba(255, 255, 255, 0.14), transparent);
}

.scheduler-workspace-grid {
    grid-template-columns: minmax(18rem, 20rem) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
}

.scheduler-sidebar {
    gap: 1rem;
    padding: 1.05rem;
    position: sticky;
    top: 1rem;
}

.scheduler-sidebar-header {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.85rem;
    align-items: start;
}

.scheduler-sidebar-header h2 {
    margin: 0.2rem 0 0;
    color: var(--navy);
    font-size: 1.9rem;
}

.scheduler-sidebar-stack {
    gap: 0.75rem;
}

.scheduler-sidebar-section {
    display: grid;
    gap: 0.7rem;
}

.scheduler-sidebar-section-title {
    margin: 0;
    color: var(--text-soft);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.scheduler-sidebar-card {
    gap: 0.45rem;
    padding: 0.9rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(238, 245, 255, 0.92));
    box-shadow: 0 10px 24px rgba(18, 35, 61, 0.08);
    cursor: pointer;
    user-select: none;
    touch-action: none;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.scheduler-sidebar-card:hover,
.scheduler-sidebar-card:focus-visible {
    transform: translateY(-1px);
    border-color: rgba(17, 112, 230, 0.24);
    box-shadow: var(--shadow-md);
}

.scheduler-sidebar-card-risk {
    border-color: rgba(216, 91, 114, 0.28);
}

.scheduler-sidebar-card-scheduled {
    border-style: dashed;
}

.scheduler-sidebar-card-locked {
    cursor: default;
    opacity: 0.88;
}

.scheduler-sidebar-card-completed {
    border-color: rgba(138, 151, 171, 0.34);
    background: linear-gradient(180deg, rgba(247, 249, 252, 0.98), rgba(232, 236, 242, 0.94));
}

.scheduler-sidebar-card strong,
.scheduler-sidebar-card p,
.scheduler-risk-card strong,
.scheduler-risk-card p,
.scheduler-risk-card span {
    margin: 0;
}

.scheduler-sidebar-card p {
    color: var(--navy);
    font-weight: 700;
}

.scheduler-sidebar-card-top,
.scheduler-sidebar-card-meta,
.scheduler-utilization-copy {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
}

.scheduler-sidebar-card-top span,
.scheduler-sidebar-card-meta span {
    color: var(--text-soft);
    font-size: 0.78rem;
}

.scheduler-board-stack {
    gap: 1rem;
}

.scheduler-day-shell {
    gap: 1rem;
    padding: 1rem;
}

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

.scheduler-day-header h2 {
    margin: 0.2rem 0 0;
}

.scheduler-board {
    gap: 0;
    overflow-x: auto;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(246, 250, 255, 0.96), rgba(237, 244, 255, 0.9));
}

.scheduler-board-header {
    display: grid;
    grid-template-columns: minmax(12.5rem, 14rem) minmax(52rem, 1fr);
    border-bottom: 1px solid rgba(91, 121, 170, 0.14);
}

.scheduler-board-lane-spacer,
.scheduler-board-lane-label {
    padding: 0.95rem 1rem;
    border-right: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(240, 246, 255, 0.9));
}

.scheduler-board-lane-spacer {
    color: var(--text-soft);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.scheduler-board-time-header,
.scheduler-board-slot-grid,
.scheduler-board-block-layer {
    display: grid;
    grid-template-columns: repeat(var(--slot-count), minmax(2.35rem, 1fr));
}

.scheduler-board-time-cell {
    padding: 0.85rem 0.2rem;
    border-right: 1px solid rgba(91, 121, 170, 0.1);
    text-align: center;
    color: var(--text-soft);
    font-size: 0.74rem;
    font-weight: 700;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(234, 243, 255, 0.88));
}

.scheduler-board-time-cell-now {
    color: var(--accent-strong);
    background: linear-gradient(180deg, rgba(216, 236, 255, 0.92), rgba(232, 244, 255, 0.96));
}

.scheduler-board-body {
    gap: 0;
}

.scheduler-board-row {
    display: grid;
    grid-template-columns: minmax(12.5rem, 14rem) minmax(52rem, 1fr);
    min-height: 5.9rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.14);
}

.scheduler-workspace-dragging .scheduler-board-block {
    pointer-events: none;
}

.scheduler-drag-source {
    opacity: 0.28;
}

.scheduler-drop-pending {
    cursor: wait;
    pointer-events: none;
}

.scheduler-board-lane-label {
    align-content: center;
    gap: 0.22rem;
}

.scheduler-board-lane-label span {
    color: var(--text-soft);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.scheduler-board-lane-label strong {
    color: var(--navy);
    font-size: 0.98rem;
}

.scheduler-board-track {
    position: relative;
    min-height: 5.9rem;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.84), rgba(237, 244, 255, 0.74)),
        linear-gradient(90deg, rgba(36, 165, 255, 0.03), transparent);
}

.scheduler-board-slot-grid,
.scheduler-board-block-layer {
    position: absolute;
    inset: 0;
}

.scheduler-board-slot-grid {
    z-index: 1;
}

.scheduler-board-block-layer {
    z-index: 2;
    pointer-events: none;
    padding: 0.45rem 0;
}

.scheduler-board-drop-slot {
    border-right: 1px solid rgba(91, 121, 170, 0.1);
}

.scheduler-board-drop-slot:hover {
    background: rgba(36, 165, 255, 0.05);
}

.scheduler-board-drop-slot-hover {
    background: rgba(36, 165, 255, 0.14);
    box-shadow: inset 0 0 0 1px rgba(17, 112, 230, 0.2);
}

.scheduler-board-drop-slot-disabled {
    background: rgba(138, 151, 171, 0.08);
    box-shadow: inset 0 0 0 1px rgba(138, 151, 171, 0.12);
}

.scheduler-board-block {
    pointer-events: auto;
    align-self: stretch;
    justify-self: stretch;
    margin: 0 0.15rem;
    padding: 0.6rem 0.7rem;
    border: 1px solid color-mix(in srgb, var(--block-accent) 58%, white);
    background:
        linear-gradient(135deg, color-mix(in srgb, var(--block-accent) 18%, white), color-mix(in srgb, var(--block-accent) 5%, white)),
        linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(244, 249, 255, 0.82));
    border-left: 4px solid var(--block-accent);
    box-shadow: 0 10px 22px rgba(18, 35, 61, 0.1);
    cursor: grab;
    user-select: none;
    touch-action: none;
    text-align: left;
    transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.scheduler-board-block:hover,
.scheduler-board-block:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 14px 24px rgba(18, 35, 61, 0.14);
}

.scheduler-board-block:active {
    cursor: grabbing;
}

.scheduler-board-block-blocked {
    border-color: rgba(216, 91, 114, 0.5);
    border-left-color: var(--danger);
}

.scheduler-board-block-risk {
    box-shadow: 0 14px 26px rgba(195, 137, 34, 0.14);
}

.scheduler-board-block-locked {
    cursor: default;
    opacity: 0.94;
}

.scheduler-board-block-completed {
    border-color: rgba(138, 151, 171, 0.46);
    border-left-color: #8a97ab;
    background:
        linear-gradient(135deg, rgba(219, 224, 232, 0.98), rgba(238, 241, 246, 0.94)),
        linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(241, 244, 248, 0.88));
}

.scheduler-board-block-dragging {
    opacity: 0.28;
}

.scheduler-board-block-title,
.scheduler-board-block-copy {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.scheduler-board-block-title {
    color: var(--navy);
    font-size: 0.82rem;
    font-weight: 800;
}

.scheduler-board-block-copy {
    color: var(--navy-soft);
    font-size: 0.76rem;
}

.scheduler-board-footer {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 1rem;
}

.scheduler-footer-panel {
    gap: 0.85rem;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(240, 246, 255, 0.92));
}

.scheduler-utilization-stack,
.scheduler-risk-grid {
    gap: 0.8rem;
}

.scheduler-utilization-row {
    gap: 0.35rem;
}

.scheduler-utilization-copy strong {
    color: var(--navy);
    font-size: 0.84rem;
}

.scheduler-utilization-copy span {
    color: var(--text-soft);
    font-size: 0.76rem;
    font-weight: 700;
}

.scheduler-utilization-bar {
    height: 0.5rem;
    background: rgba(36, 165, 255, 0.1);
    overflow: hidden;
}

.scheduler-utilization-bar span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--accent), var(--teal));
}

.scheduler-risk-grid {
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
}

.scheduler-risk-card {
    gap: 0.3rem;
    padding: 0.9rem;
    border: 1px solid rgba(195, 137, 34, 0.2);
    background: linear-gradient(180deg, rgba(255, 252, 245, 0.98), rgba(255, 245, 228, 0.92));
}

.scheduler-risk-card-critical {
    border-color: rgba(216, 91, 114, 0.28);
    background: linear-gradient(180deg, rgba(255, 246, 248, 0.98), rgba(255, 233, 238, 0.94));
}

.scheduler-risk-card strong {
    color: var(--navy);
}

.scheduler-risk-card span {
    color: var(--navy-soft);
    font-size: 0.82rem;
    font-weight: 700;
}

.scheduler-risk-card p {
    color: var(--text-soft);
    font-size: 0.78rem;
}

.scheduler-drag-ghost {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 80;
    display: grid;
    min-width: 15rem;
    max-width: 20rem;
    gap: 0.28rem;
    padding: 0.8rem 0.9rem;
    border: 1px solid rgba(17, 112, 230, 0.28);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(235, 244, 255, 0.96));
    box-shadow: 0 18px 34px rgba(18, 35, 61, 0.2);
    pointer-events: none;
}

.scheduler-drag-ghost strong,
.scheduler-drag-ghost span {
    margin: 0;
}

.scheduler-drag-ghost strong {
    color: var(--navy);
    font-size: 0.9rem;
}

.scheduler-drag-ghost span {
    color: var(--navy-soft);
    font-size: 0.78rem;
}

@media (max-width: 1320px) {
    .scheduler-control-row,
    .scheduler-page-header,
    .scheduler-workspace-grid,
    .scheduler-board-footer {
        grid-template-columns: 1fr;
    }

    .scheduler-page-actions {
        justify-self: start;
    }

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

    .scheduler-sidebar {
        position: static;
    }
}

@media (max-width: 820px) {
    .scheduler-page-actions {
        grid-auto-flow: row;
        justify-items: start;
    }

    .scheduler-kpi-strip {
        grid-template-columns: 1fr;
    }

    .scheduler-board-header,
    .scheduler-board-row {
        grid-template-columns: 10rem minmax(42rem, 1fr);
    }
}

/* Shared interaction geometry keeps dialogs and primary controls visually consistent. */
.action-button,
.ghost-button,
.filter-pill,
.review-comment-trigger,
.upload-dropzone {
    border-radius: var(--radius-md);
}

.review-modal-card,
.review-modal-card-wide,
.review-modal-sidecard,
.review-comment-modal-card,
.notification-modal-card,
.resource-modal-card,
.drawing-upload-modal-card,
.admin-workflow-modal-card,
.resource-detail-modal-card,
.coworker-modal-card {
    border-radius: var(--radius-lg);
}

/* Quote review cards use a stable visual language: context, request, and editable items. */
.review-quote-modal-card .mini-card {
    border-color: rgba(17, 112, 230, 0.58);
}

.review-quote-modal-card .mini-card.public-request-card {
    border-color: rgba(100, 116, 139, 0.58);
}

.review-quote-modal-card .checklist-stack > .quote-line-card {
    border: 1px solid rgba(26, 159, 112, 0.68);
    box-shadow: inset 0 0 0 1px rgba(26, 159, 112, 0.05);
}

/* Executive quote review keeps context, routing and the decision in one workspace. */
.executive-review-modal-card {
    width: min(96rem, calc(100vw - 2rem));
    height: calc(100dvh - 2rem);
    max-height: calc(100dvh - 2rem);
    gap: 0;
    padding: 0;
    grid-template-rows: auto minmax(0, 1fr);
}

.review-modal-shell:has(.executive-review-modal-card) {
    box-sizing: border-box;
    overflow-x: hidden;
}

.executive-review-modal-card > .review-modal-header {
    gap: 1rem;
    padding: 1.15rem 1.25rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.14);
}

.executive-review-modal-card > .review-modal-header :is(h2, p) {
    margin-block: 0;
}

.executive-review-modal-card > .review-modal-header .muted {
    max-width: 74rem;
    margin-top: 0.35rem;
}

.review-modal-body.executive-review-modal-body {
    display: block;
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    padding: 1rem 1.25rem 1.25rem;
}

.executive-review-workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(20rem, 22rem);
    gap: 1rem;
    align-items: start;
    min-width: 0;
}

.executive-review-workspace > *,
.executive-review-modal-body .review-quote-main-sections {
    min-width: 0;
}

.executive-review-modal-body .review-quote-main-sections {
    overflow: visible;
    gap: 1rem;
    padding-right: 0;
}

.executive-review-section {
    gap: 0.85rem;
    padding: 1rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    border-radius: var(--radius-lg);
    background: rgba(249, 251, 250, 0.76);
}

.executive-review-section > .drawer-section-header {
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.13);
}

.executive-review-section > .drawer-section-header h3,
.executive-review-summary-card :is(h3, p),
.executive-review-technology-summary :is(h3, p),
.executive-review-route-card :is(h3, p),
.executive-review-step-card :is(h3, p) {
    margin: 0;
}

.executive-review-summary-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 0.75rem;
    align-items: start;
}

.executive-review-summary-contact {
    grid-column: span 4;
}

.executive-review-summary-request {
    grid-column: span 5;
}

.executive-review-summary-company {
    grid-column: span 3;
}

.executive-review-email-card {
    grid-column: 1 / -1;
}

.review-quote-modal-card .executive-review-summary-card {
    display: grid;
    justify-content: stretch;
    align-items: start;
    align-content: start;
    min-width: 0;
    padding: 0.9rem;
    border-color: rgba(91, 121, 170, 0.16);
    background: rgba(244, 248, 249, 0.82);
}

.executive-review-summary-card > div {
    display: grid;
    gap: 0.48rem;
    width: 100%;
    min-width: 0;
}

.executive-review-email-card {
    gap: 0.85rem;
}

.executive-review-email-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.13);
}

.executive-review-email-header > div {
    display: grid;
    gap: 0.22rem;
    min-width: 0;
}

.executive-review-email-header :is(h3, p) {
    margin: 0;
}

.executive-review-email-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.7rem;
    margin: 0;
}

.executive-review-email-meta > div,
.structured-message-field {
    display: grid;
    grid-template-columns: minmax(8.5rem, 0.35fr) minmax(0, 1fr);
    align-items: baseline;
    gap: 0.35rem 0.9rem;
    min-width: 0;
}

.executive-review-email-meta dt,
.structured-message-field > span {
    color: var(--text-soft);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.executive-review-email-meta dd,
.structured-message-field p {
    min-width: 0;
    margin: 0;
    color: var(--navy);
    line-height: 1.48;
    overflow-wrap: anywhere;
}

.structured-message-content {
    display: grid;
    gap: 0.65rem;
    min-width: 0;
    padding: 0.85rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    background: rgba(255, 255, 255, 0.52);
}

.structured-message-section {
    margin: 0.25rem 0 0;
    padding-bottom: 0.35rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
    color: var(--navy);
    font-size: 0.82rem;
}

.structured-message-paragraph,
.structured-message-list-item p {
    min-width: 0;
    margin: 0;
    color: var(--text-soft);
    line-height: 1.58;
    overflow-wrap: anywhere;
}

.structured-message-list-item {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
    gap: 0.7rem;
    padding: 0.65rem 0.75rem;
    border-left: 3px solid rgba(214, 166, 48, 0.62);
    background: rgba(248, 239, 202, 0.38);
}

.structured-message-list-item > span {
    color: #986300;
    font-size: 0.78rem;
    font-weight: 850;
    white-space: nowrap;
}

.executive-review-structured-note {
    margin-top: 0.55rem;
}

.executive-review-fact-list {
    display: grid;
    gap: 0.65rem;
    min-width: 0;
    margin: 0;
}

.executive-review-request-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem 1rem;
}

.executive-review-fact-row {
    display: grid;
    gap: 0.18rem;
    min-width: 0;
}

.executive-review-fact-wide {
    grid-column: 1 / -1;
}

.executive-review-fact-row dt {
    color: var(--text-soft);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    line-height: 1.3;
    text-transform: uppercase;
}

.executive-review-fact-row dd {
    min-width: 0;
    margin: 0;
    color: var(--navy);
    font-size: 0.9rem;
    font-weight: 650;
    line-height: 1.42;
    overflow-wrap: anywhere;
}

.executive-review-summary-card .muted,
.executive-review-technology-summary .muted,
.executive-review-route-card .muted {
    line-height: 1.48;
    overflow-wrap: anywhere;
}

.review-quote-modal-card .executive-review-technology-summary {
    display: block;
    padding: 0.9rem 1rem;
    border-color: rgba(91, 121, 170, 0.16);
    border-left: 3px solid rgba(45, 103, 177, 0.54);
    background: rgba(237, 244, 248, 0.72);
}

.executive-review-technology-summary h3 {
    margin-bottom: 0.35rem;
    font-size: 0.88rem;
}

.executive-review-plan-section .review-route-list {
    gap: 0.85rem;
}

.executive-review-route-card {
    display: grid;
    gap: 0.8rem;
    min-width: 0;
    padding: 0.95rem;
    border: 1px solid rgba(91, 121, 170, 0.14);
    background: rgba(248, 250, 249, 0.82);
    box-shadow: 0 8px 18px rgba(37, 64, 107, 0.06);
}

.executive-review-route-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    gap: 0.75rem;
    margin: 0;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(91, 121, 170, 0.12);
}

.executive-review-route-header > div:first-child {
    display: grid;
    gap: 0.28rem;
    min-width: 0;
}

.executive-review-route-header > .button-row {
    flex-wrap: nowrap;
    justify-content: flex-end;
}

.executive-review-step-list {
    gap: 0.55rem;
}

.review-quote-modal-card .executive-review-step-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    justify-content: stretch;
    gap: 0.75rem;
    min-width: 0;
    padding: 0.75rem 0.85rem;
    border: 1px solid rgba(91, 121, 170, 0.13);
    background: rgba(255, 255, 255, 0.54);
}

.executive-review-step-card > div:first-child {
    display: grid;
    gap: 0.25rem;
    min-width: 0;
}

.executive-review-step-card > .button-row {
    flex-wrap: nowrap;
    justify-content: flex-end;
}

.review-quote-modal-card .executive-review-step-sequence {
    color: #a56c00;
    font-weight: 850;
}

.executive-review-decision-column {
    position: sticky;
    top: 0;
    min-width: 0;
}

.executive-review-decision-panel {
    gap: 1rem;
    min-width: 0;
    margin: 0;
    padding: 1rem;
}

.executive-review-decision-panel > .drawer-section-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(163, 117, 31, 0.18);
}

.executive-review-decision-panel > .drawer-section-header h3 {
    margin: 0;
}

.executive-review-decision-panel .field-label,
.executive-review-decision-panel .field-input,
.executive-review-decision-panel .text-area {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

.executive-review-decision-panel .text-area {
    min-height: 8rem;
    resize: vertical;
}

.executive-review-deficiency-list {
    gap: 0.5rem;
    margin-top: 0.35rem;
}

.executive-review-deficiency-list .toggle-chip {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 0.6rem;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0.62rem 0.7rem;
    border: 1px solid rgba(163, 117, 31, 0.14);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.48);
    box-shadow: none;
}

.executive-review-deficiency-list .toggle-chip input {
    width: 1rem;
    height: 1rem;
    margin: 0;
}

.executive-review-deficiency-list .toggle-chip span {
    min-width: 0;
    line-height: 1.35;
    overflow-wrap: anywhere;
}

.executive-review-actions {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.65rem;
    width: 100%;
}

.executive-review-actions > * {
    width: 100%;
    min-width: 0;
    justify-content: center;
    text-align: center;
    white-space: normal;
}

@media (max-width: 1280px) {
    .executive-review-summary-contact,
    .executive-review-summary-company {
        grid-column: span 6;
    }

    .executive-review-summary-request {
        grid-column: 1 / -1;
        grid-row: 2;
    }
}

@media (max-width: 1120px) {
    .executive-review-modal-card {
        width: min(76rem, calc(100vw - 1.5rem));
        height: auto;
        min-height: 0;
        max-height: calc(100dvh - 1.5rem);
    }

    .executive-review-workspace {
        grid-template-columns: minmax(0, 1fr);
    }

    .executive-review-decision-column {
        position: static;
    }
}

@media (max-width: 720px) {
    .executive-review-modal-card {
        width: 100%;
        max-height: calc(100dvh - 1rem);
    }

    .executive-review-modal-card > .review-modal-header,
    .review-modal-body.executive-review-modal-body {
        padding-inline: 0.85rem;
    }

    .executive-review-summary-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .executive-review-summary-contact,
    .executive-review-summary-request,
    .executive-review-summary-company {
        grid-column: auto;
        grid-row: auto;
    }

    .executive-review-request-facts {
        grid-template-columns: minmax(0, 1fr);
    }

    .executive-review-fact-wide {
        grid-column: auto;
    }

    .executive-review-email-header,
    .executive-review-email-meta,
    .structured-message-field {
        grid-template-columns: minmax(0, 1fr);
    }

    .executive-review-email-header {
        display: grid;
    }

    .executive-review-route-header,
    .review-quote-modal-card .executive-review-step-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .executive-review-route-header > .button-row,
    .executive-review-step-card > .button-row {
        justify-content: flex-start;
    }

    .request-asset-collection-header,
    .request-asset-row,
    .executive-review-line-facts {
        grid-template-columns: minmax(0, 1fr);
    }

    .executive-review-line-fact-wide {
        grid-column: auto;
    }

    .request-asset-type {
        justify-content: start;
        min-height: 0;
        padding-bottom: 0.4rem;
        border-right: 0;
        border-bottom: 1px solid rgba(91, 121, 170, 0.18);
    }

    .request-asset-actions {
        flex-wrap: wrap;
        justify-content: flex-start;
    }

    .planning-duration-input {
        grid-template-columns: minmax(0, 1fr) minmax(5rem, 0.55fr);
    }
}

.inbound-email-summary {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1rem;
}

.inbound-email-summary-content {
    display: grid;
    gap: 0.9rem;
    min-width: 0;
}

.inbound-email-summary-item {
    display: grid;
    gap: 0.3rem;
    min-width: 0;
}

.inbound-email-summary-item h4,
.inbound-email-summary-item p {
    margin: 0;
}

.inbound-email-summary-item h4 {
    color: var(--navy);
    font-size: 0.86rem;
}

.inbound-email-summary-item p {
    color: var(--text-soft);
    overflow-wrap: anywhere;
}

.inbound-email-body {
    white-space: pre-wrap;
}

.inbound-email-attachment-list {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.55rem 0.85rem;
}

.inbound-email-attachment-name {
    font-weight: 700;
}

@media (max-width: 640px) {
    .inbound-email-summary,
    .inbound-email-attachment-list {
        grid-template-columns: 1fr;
    }

    .inbound-email-summary > .review-comment-thread {
        justify-self: start;
    }
}
