/* Bridge/Notion hybrid frontend refresh.
   Loaded after the feature styles so it can normalize visual treatment without
   changing markup, routes, API calls, or data behavior. */

:root {
    --bridge-ui-ink: #101114;
    --bridge-ui-ink-soft: #24272d;
    --bridge-ui-muted: #667085;
    --bridge-ui-faint: #8a8f98;
    --bridge-ui-canvas: #f7f7f5;
    --bridge-ui-canvas-soft: #fbfbfa;
    --bridge-ui-surface: #ffffff;
    --bridge-ui-surface-subtle: #f3f3f1;
    --bridge-ui-surface-muted: #ececea;
    --bridge-ui-line: #e2e2df;
    --bridge-ui-line-strong: #cfcfca;
    --bridge-ui-blue: #0075de;
    --bridge-ui-blue-hover: #0067c5;
    --bridge-ui-blue-soft: #e6f3fe;
    --bridge-ui-blue-line: #b7dcff;
    --bridge-ui-green: #10b981;
    --bridge-ui-green-dark: #047857;
    --bridge-ui-green-soft: #ecfdf5;
    --bridge-ui-green-line: #b7ebd1;
    --bridge-ui-warning: #b45309;
    --bridge-ui-warning-soft: #fff7ed;
    --bridge-ui-danger: #b42318;
    --bridge-ui-danger-soft: #fff1f0;
    --bridge-ui-radius: 8px;
    --bridge-ui-radius-sm: 6px;
    --bridge-ui-radius-xs: 4px;
    --bridge-ui-shadow: 0 1px 2px rgba(16, 17, 20, 0.04), 0 8px 24px rgba(16, 17, 20, 0.06);
    --bridge-ui-shadow-float: 0 18px 48px rgba(16, 17, 20, 0.12);
    --bridge-ui-focus: 0 0 0 3px rgba(0, 117, 222, 0.18);
    --bridge-ui-control-h: 38px;
}

html {
    background: var(--bridge-ui-canvas);
}

body {
    background: var(--bridge-ui-canvas);
    color: var(--bridge-ui-ink-soft);
    font-family: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 15px;
    line-height: 1.55;
    letter-spacing: 0;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body::before {
    display: none !important;
}

html.bridge-protected-route-boot .main-header,
html.bridge-auth-restore-boot .main-header {
    display: none !important;
}

html.bridge-protected-route-boot body::before,
html.bridge-auth-restore-boot body::before {
    content: "";
    position: fixed;
    top: 50%;
    left: 50%;
    display: block !important;
    width: 34px;
    height: 34px;
    border: 3px solid rgba(16, 17, 20, 0.12);
    border-top-color: var(--bridge-ui-blue);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: bridgeBootSpin 0.75s linear infinite;
    z-index: 10000;
}

body :where(button, a, input, textarea, select, summary, [role="button"], [tabindex]) {
    transition:
        background-color 180ms ease,
        border-color 180ms ease,
        box-shadow 180ms ease,
        color 180ms ease,
        opacity 180ms ease,
        transform 180ms ease;
}

body :where(button, a, input, textarea, select, summary, [role="button"], [tabindex]):focus-visible {
    outline: none;
    box-shadow: var(--bridge-ui-focus) !important;
}

body :where(h1, h2, h3, h4, h5, h6) {
    color: var(--bridge-ui-ink);
    font-family: "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-weight: 700;
    letter-spacing: 0 !important;
}

.material-symbols-outlined {
    font-variation-settings: "FILL" 0, "wght" 520, "GRAD" 0, "opsz" 24;
}

/* Shared controls */
body :where(.btn-primary, .btn-secondary, .btn-outline, .login-btn, .nav-dash-btn,
.dashboard-main-btn, .workspace-start-btn, .submit-btn, .sms-send-btn,
.sourcing-action-pill, .sourcing-project-board-cta, .sourcing-chat-send-btn,
.sourcing-chat-icon-btn, .sourcing-chat-mode-btn, .project-quick-action-btn,
.order-detail-action-btn, .order-execution-back-btn, .order-execution-create-invoice-btn,
.checklist-context-action-btn, .spec-ai-chat-action-btn, .qc-folder-btn,
.signoff-final-btn, .user-guide-toggle, .sidebar-utility-btn, .sidebar-logout-btn) {
    min-height: var(--bridge-ui-control-h);
    border-radius: var(--bridge-ui-radius) !important;
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-weight: 600;
    letter-spacing: 0 !important;
    text-transform: none !important;
    box-shadow: none;
}

body :where(.btn-primary, .login-btn, .nav-dash-btn, .workspace-start-btn,
.dashboard-main-btn.active, .submit-btn, .sourcing-project-board-cta,
.sourcing-chat-send-btn, .sourcing-action-pill.primary,
.order-execution-create-invoice-btn, .signoff-final-btn:not(:disabled)) {
    background: var(--bridge-ui-blue) !important;
    border: 1px solid var(--bridge-ui-blue) !important;
    color: #ffffff !important;
}

body :where(.btn-primary, .login-btn, .nav-dash-btn, .workspace-start-btn,
.submit-btn, .sourcing-project-board-cta, .sourcing-chat-send-btn,
.sourcing-action-pill.primary, .order-execution-create-invoice-btn,
.signoff-final-btn:not(:disabled)):hover {
    background: var(--bridge-ui-blue-hover) !important;
    border-color: var(--bridge-ui-blue-hover) !important;
    color: #ffffff !important;
    transform: translateY(-1px);
}

body :where(.btn-secondary, .btn-outline, .dashboard-main-btn, .sourcing-action-pill.secondary,
.sourcing-chat-icon-btn, .sourcing-chat-mode-btn, .project-quick-action-btn,
.order-detail-action-btn, .order-execution-back-btn, .checklist-context-action-btn,
.spec-ai-chat-action-btn, .qc-folder-btn, .user-guide-toggle, .sidebar-utility-btn,
.sidebar-logout-btn, .sms-send-btn.secondary-submit-btn, .submit-btn.secondary-submit-btn) {
    background: var(--bridge-ui-surface) !important;
    border: 1px solid var(--bridge-ui-line) !important;
    color: var(--bridge-ui-ink-soft) !important;
}

body :where(.btn-secondary, .btn-outline, .dashboard-main-btn, .sourcing-action-pill.secondary,
.sourcing-chat-icon-btn, .sourcing-chat-mode-btn, .project-quick-action-btn,
.order-detail-action-btn, .order-execution-back-btn, .checklist-context-action-btn,
.spec-ai-chat-action-btn, .qc-folder-btn, .user-guide-toggle, .sidebar-utility-btn,
.sidebar-logout-btn, .sms-send-btn.secondary-submit-btn, .submit-btn.secondary-submit-btn):hover {
    background: var(--bridge-ui-surface-subtle) !important;
    border-color: var(--bridge-ui-line-strong) !important;
    color: var(--bridge-ui-ink) !important;
}

body :where(button:disabled, .btn-primary:disabled, .submit-btn:disabled, .is-disabled) {
    cursor: not-allowed !important;
    opacity: 0.56;
    transform: none !important;
}

body .qc-decision-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.5rem;
}

body .qc-decision-btn,
body .qc-state-action-btn {
    min-width: 104px;
}

body .qc-decision-btn.qc-decision-btn--approve,
body .qc-state-action-btn.qc-state-action-btn--shipment {
    background: var(--bridge-ui-green) !important;
    border-color: var(--bridge-ui-green) !important;
    color: #ffffff !important;
}

body .qc-decision-btn.qc-decision-btn--approve:hover,
body .qc-state-action-btn.qc-state-action-btn--shipment:hover {
    background: #059669 !important;
    border-color: #059669 !important;
    color: #ffffff !important;
}

body .qc-decision-btn.qc-decision-btn--reject {
    background: #991b1b !important;
    border-color: #991b1b !important;
    color: #ffffff !important;
}

body .qc-decision-btn.qc-decision-btn--reject:hover {
    background: #7f1d1d !important;
    border-color: #7f1d1d !important;
    color: #ffffff !important;
}

body .qc-decision-btn.qc-decision-btn--rework {
    background: #ef4444 !important;
    border-color: #ef4444 !important;
    color: #ffffff !important;
}

body .qc-decision-btn.qc-decision-btn--rework:hover {
    background: #dc2626 !important;
    border-color: #dc2626 !important;
    color: #ffffff !important;
}

body .qc-decision-btn.qc-decision-btn--reinspection,
body .qc-state-action-btn.qc-state-action-btn--rework,
body .qc-state-action-btn.qc-state-action-btn--reinspection {
    background: #f59e0b !important;
    border-color: #f59e0b !important;
    color: #1f2937 !important;
}

body .qc-decision-btn.qc-decision-btn--reinspection:hover,
body .qc-state-action-btn.qc-state-action-btn--rework:hover,
body .qc-state-action-btn.qc-state-action-btn--reinspection:hover {
    background: #d97706 !important;
    border-color: #d97706 !important;
    color: #111827 !important;
}

body :where(input, textarea, select, .req-select, .req-textarea,
.price-payment-input, .sourcing-questionnaire-field,
.merged-checklist-answer-input, .spec-conversation-proxy-field input) {
    border: 1px solid var(--bridge-ui-line) !important;
    border-radius: var(--bridge-ui-radius-sm) !important;
    background: var(--bridge-ui-surface) !important;
    color: var(--bridge-ui-ink) !important;
    box-shadow: inset 0 1px 0 rgba(16, 17, 20, 0.02);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
}

body :where(input, textarea, select, .req-select, .req-textarea,
.price-payment-input, .sourcing-questionnaire-field,
.merged-checklist-answer-input, .spec-conversation-proxy-field input):focus {
    border-color: var(--bridge-ui-blue) !important;
    box-shadow: var(--bridge-ui-focus) !important;
}

/* Nested text controls use their surrounding shell, composer, or cell as the visible boundary. */
body :where(
.sourcing-savings-search-bar input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-project-board-search input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-project-board-sort select,
.sourcing-chat-input-shell :where(input, textarea):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.chat-input-area .input-wrapper textarea,
.input-wrapper.telegram-input :where(input, textarea):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-questionnaire-answer :where(.sourcing-questionnaire-field, .merged-checklist-answer-input),
.sourcing-questionnaire-cell :where(input, textarea, select, .sourcing-questionnaire-field, .merged-checklist-answer-input):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.req-select-wrapper :where(.req-select, .req-textarea),
.checklist-table td :where(.req-select, .req-textarea, .merged-checklist-answer-input),
.price-payment-table td .price-payment-input,
.price-payment-installment-table td .price-payment-input,
.price-payment-summary-table td .price-payment-input
) {
    border-color: transparent !important;
    background: transparent !important;
    box-shadow: none !important;
    outline: none;
}

body :where(
.sourcing-savings-search-bar input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-project-board-search input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-project-board-sort select,
.sourcing-chat-input-shell :where(input, textarea):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.chat-input-area .input-wrapper textarea,
.input-wrapper.telegram-input :where(input, textarea):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-questionnaire-answer :where(.sourcing-questionnaire-field, .merged-checklist-answer-input),
.sourcing-questionnaire-cell :where(input, textarea, select, .sourcing-questionnaire-field, .merged-checklist-answer-input):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.req-select-wrapper :where(.req-select, .req-textarea),
.checklist-table td :where(.req-select, .req-textarea, .merged-checklist-answer-input),
.price-payment-table td .price-payment-input,
.price-payment-installment-table td .price-payment-input,
.price-payment-summary-table td .price-payment-input
):focus {
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none;
}

body :where(.sourcing-savings-search-bar, .sourcing-chat-input-shell,
.sourcing-project-board-search, .sourcing-project-board-sort,
.chat-input-area .input-wrapper, .input-wrapper.telegram-input):focus-within {
    border-color: var(--bridge-ui-blue) !important;
    box-shadow: var(--bridge-ui-focus) !important;
}

body.workspace-shell-active :where(.sourcing-questionnaire-answer,
.sourcing-questionnaire-cell, .checklist-table td, .price-payment-table td,
.price-payment-installment-table td, .price-payment-summary-table td):focus-within {
    box-shadow: inset 0 0 0 1px var(--bridge-ui-blue-line);
}

body :where(.role-badge-mini, .role-badge-small, .workspace-stage-badge,
.workspace-status-badge, .sourcing-project-chip, .sourcing-project-status-pill,
.sourcing-status-chip, .sourcing-project-row-pill, .sourcing-workflow-file-chip,
.sourcing-workflow-pending-chip, .sourcing-evidence-status, .status-badge,
.qc-filter-tag, .qc-data-pill, .qc-tech-status-pill, .qc-detail-status-pill,
.requirements-overview-status-pill, .price-payment-pill, .order-execution-hero-badge,
.order-execution-metadata-pill, .order-execution-project-order-status,
.order-execution-invoice-status, .tab-badge, .notification-count-badge,
.translation-badge, .auth-brand-kicker) {
    border-radius: 999px !important;
    border: 1px solid var(--bridge-ui-line);
    background: var(--bridge-ui-surface-subtle);
    color: var(--bridge-ui-muted);
    font-weight: 600;
    letter-spacing: 0 !important;
    text-transform: none;
}

body :where(.status-badge.success, .status-badge.completed, .status-badge.approved,
.workspace-status-badge.success, .sourcing-project-card-stage.is-live,
.order-execution-step.complete, .order-execution-project-order-status--delivered,
.order-execution-invoice-status--paid) {
    background: var(--bridge-ui-green-soft) !important;
    border-color: var(--bridge-ui-green-line) !important;
    color: var(--bridge-ui-green-dark) !important;
}

body :where(.status-badge.warning, .status-badge.pending, .qc-tech-status-pill.pending,
.price-payment-pill.warning) {
    background: var(--bridge-ui-warning-soft) !important;
    border-color: #fed7aa !important;
    color: var(--bridge-ui-warning) !important;
}

body :where(.status-badge.danger, .status-badge.rejected, .price-payment-pill.danger) {
    background: var(--bridge-ui-danger-soft) !important;
    border-color: #ffd0cc !important;
    color: var(--bridge-ui-danger) !important;
}

/* Public shell */
.main-header {
    height: 72px;
    padding: 0 clamp(1rem, 2.5vw, 2rem);
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid var(--bridge-ui-line);
    box-shadow: none;
    backdrop-filter: blur(14px);
}

.main-header::after {
    display: none;
}

.main-header .logo img {
    max-height: 56px;
    transform: none;
}

.main-header nav {
    gap: clamp(0.75rem, 1.6vw, 1.5rem);
    margin-left: clamp(1rem, 2vw, 2.25rem);
}

.nav-main-links,
.nav-action-group {
    gap: 0.35rem;
}

.nav-btn,
.lang-btn {
    min-height: 34px;
    padding: 0.35rem 0.62rem;
    border-radius: var(--bridge-ui-radius-xs);
    color: var(--bridge-ui-ink-soft);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-size: 0.92rem;
    font-weight: 500;
    letter-spacing: 0 !important;
    text-transform: none;
}

.nav-btn::after {
    display: none;
}

.nav-btn:hover,
.nav-btn.active,
.lang-btn:hover,
.lang-btn.active {
    background: var(--bridge-ui-surface-subtle);
    color: var(--bridge-ui-ink);
}

.lang-switcher {
    gap: 0.05rem;
    padding: 0.12rem;
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius);
    background: var(--bridge-ui-surface);
}

.lang-switcher .divider {
    display: none;
}

#home-view.public-landing-shell {
    background: var(--bridge-ui-canvas-soft);
}

#home-view.public-landing-shell .hero.reworked {
    min-height: min(760px, calc(100vh - 72px));
    padding: clamp(4rem, 8vw, 7.5rem) clamp(1.25rem, 4vw, 4.5rem) clamp(3rem, 6vw, 5rem);
    background: #111827;
}

#home-view.public-landing-shell .public-landing-hero-media {
    filter: saturate(0.92) contrast(0.95);
    opacity: 0.9;
}

#home-view.public-landing-shell .public-landing-hero-scrim {
    background:
        linear-gradient(90deg, rgba(8, 12, 20, 0.84) 0%, rgba(8, 12, 20, 0.62) 42%, rgba(8, 12, 20, 0.22) 100%),
        rgba(8, 12, 20, 0.16);
}

#home-view.public-landing-shell .hero-content-wrapper {
    max-width: 1180px;
    gap: 1rem;
}

#home-view.public-landing-shell .public-eyebrow {
    width: fit-content;
    padding: 0.38rem 0.62rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.86);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0 !important;
    text-transform: none;
}

#home-view.public-landing-shell .public-eyebrow::before {
    background: var(--bridge-ui-green);
    box-shadow: none;
}

#home-view.public-landing-shell .hero-title.large-left {
    max-width: 13ch;
    color: #ffffff;
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-size: clamp(3rem, 8vw, 6.25rem);
    font-weight: 700;
    line-height: 0.98;
    letter-spacing: 0 !important;
    text-shadow: none;
}

#home-view.public-landing-shell .hero-title .highlight {
    color: #ffffff;
    background: none;
    -webkit-text-fill-color: currentColor;
}

#home-view.public-landing-shell .public-landing-hero-subtitle {
    max-width: 680px;
    color: rgba(255, 255, 255, 0.78);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-size: clamp(1rem, 1.5vw, 1.18rem);
    line-height: 1.55;
}

#home-view.public-landing-shell .public-landing-hero-proof {
    gap: 0;
    width: fit-content;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--bridge-ui-radius);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: none;
}

#home-view.public-landing-shell .public-landing-hero-proof div {
    padding: 0.75rem 1rem;
}

#home-view.public-landing-shell .public-landing-hero-proof strong {
    color: #ffffff;
    font-weight: 700;
}

#home-view.public-landing-shell .public-landing-hero-proof span {
    color: rgba(255, 255, 255, 0.7);
}

#home-view.public-landing-shell :where(.hero-tabs, .problem-grid, .solution-grid, .contact-grid) {
    gap: 0.8rem;
}

#home-view.public-landing-shell .hero-tabs {
    margin-top: clamp(1.25rem, 3vw, 2rem);
}

#home-view.public-landing-shell :where(.hero-tab, .problem-card, .value-card,
.contact-form, .sourcing-savings-search-bar, .sourcing-savings-result,
.public-section, .section-container) {
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius) !important;
    background: var(--bridge-ui-surface);
    box-shadow: var(--bridge-ui-shadow);
}

#home-view.public-landing-shell .public-section,
#home-view.public-landing-shell .section-container {
    box-shadow: none;
}

#home-view.public-landing-shell .section-container.public-section {
    box-sizing: border-box;
    width: min(1320px, calc(100% - clamp(2rem, 5vw, 4.5rem)));
    max-width: 1320px;
    margin-inline: auto;
    padding: clamp(4rem, 6vw, 6rem) clamp(2rem, 4.75vw, 4.5rem);
}

#home-view.public-landing-shell .hero-tab {
    padding: 1rem;
    transform: none;
}

#home-view.public-landing-shell .hero-tabs:hover .hero-tab:not(:hover):not(:focus-within) {
    opacity: 1;
    transform: none;
}

#home-view.public-landing-shell .hero-tab:hover,
#home-view.public-landing-shell .hero-tab:focus-within,
#home-view.public-landing-shell .problem-card:hover,
#home-view.public-landing-shell .value-card:hover {
    border-color: var(--bridge-ui-line-strong);
    box-shadow: var(--bridge-ui-shadow);
    transform: translateY(-1px);
}

#home-view.public-landing-shell .hero-tab-art,
#home-view.public-landing-shell .problem-card i,
#home-view.public-landing-shell .contact-item i {
    border-radius: var(--bridge-ui-radius);
    background: var(--bridge-ui-blue-soft);
    color: var(--bridge-ui-blue);
    box-shadow: none;
}

#home-view.public-landing-shell .hero-tab--service .hero-tab-art {
    background: var(--bridge-ui-green-soft);
    color: var(--bridge-ui-green-dark);
}

#home-view.public-landing-shell .value-card-graph .value-graph-track {
    background: #e5e7eb;
}

#home-view.public-landing-shell .value-card-graph .value-graph-bar.is-bridge {
    background: linear-gradient(90deg, #28d189 0%, #10b981 56%, #0075de 100%);
    box-shadow: 0 0 0 1px rgba(4, 120, 87, 0.14), 0 2px 8px rgba(16, 185, 129, 0.22);
}

#home-view.public-landing-shell .value-card-graph .value-graph-bar.is-conventional {
    background: #9ca3af;
}

#home-view.public-landing-shell :where(.section-title, .sourcing-savings-copy h2) {
    color: var(--bridge-ui-ink);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-size: clamp(2rem, 4vw, 3.35rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: 0 !important;
}

#home-view.public-landing-shell :where(.section-description, .sourcing-savings-copy p,
.problem-card p, .value-card p, .contact-info p) {
    color: var(--bridge-ui-muted);
}

#home-view.public-landing-shell .contact-form::after,
#home-view.public-landing-shell .problem-card::before {
    display: none;
}

/* Auth and shared modals */
#auth-modal {
    --auth-primary: var(--bridge-ui-ink);
    --auth-text: var(--bridge-ui-ink);
    --auth-muted: var(--bridge-ui-muted);
    --auth-soft: var(--bridge-ui-surface-subtle);
    --auth-line: var(--bridge-ui-line);
    --auth-line-strong: var(--bridge-ui-line-strong);
    --auth-accent: var(--bridge-ui-green);
    --auth-accent-2: var(--bridge-ui-blue);
}

#auth-modal.modal,
.modal {
    background: rgba(16, 17, 20, 0.42);
    backdrop-filter: blur(10px);
}

#auth-modal .modal-content.auth-modal-shell,
.modal-content {
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius) !important;
    background: var(--bridge-ui-surface);
    box-shadow: var(--bridge-ui-shadow-float);
}

#auth-modal .auth-brand-panel {
    background: #111827;
    color: #ffffff;
}

#auth-modal .auth-brand-panel::before {
    display: none;
}

#auth-modal .auth-brand-kicker {
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.78);
}

#auth-modal .auth-brand-copy h3 {
    color: #ffffff;
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-weight: 700;
}

#auth-modal .auth-brand-copy p,
#auth-modal .auth-proof-item {
    color: rgba(255, 255, 255, 0.76);
}

#auth-modal .auth-proof-item {
    border-color: rgba(255, 255, 255, 0.16);
    border-radius: var(--bridge-ui-radius);
    background: rgba(255, 255, 255, 0.06);
}

#auth-modal .auth-proof-icon {
    border-radius: var(--bridge-ui-radius-sm);
    background: rgba(0, 117, 222, 0.18);
    color: #9fd4ff;
}

#auth-modal .auth-brand-signal span {
    border-radius: var(--bridge-ui-radius-sm);
    background: linear-gradient(180deg, var(--bridge-ui-blue), var(--bridge-ui-green));
    box-shadow: none;
}

#auth-modal .auth-form-panel {
    border-left: 1px solid var(--bridge-ui-line);
    background: var(--bridge-ui-surface);
}

#auth-modal .modal-header h2,
.modal-header h2 {
    color: var(--bridge-ui-ink);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    font-weight: 700;
}

#auth-modal :where(.tab-btn, .auth-method-btn, .password-id-btn) {
    border-radius: var(--bridge-ui-radius-sm) !important;
    color: var(--bridge-ui-muted);
    font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
    letter-spacing: 0 !important;
}

#auth-modal :where(.tab-btn.active, .auth-method-btn.active, .password-id-btn.active) {
    background: var(--bridge-ui-blue-soft);
    border-color: var(--bridge-ui-blue-line);
    color: var(--bridge-ui-blue);
    box-shadow: none;
}

#auth-modal .tab-btn::after {
    display: none;
}

#auth-modal :where(.forgot-password-panel, .password-recovery-panel, .status-msg, .error-msg) {
    border-radius: var(--bridge-ui-radius);
    box-shadow: none;
}

.modal-actions {
    gap: 0.6rem;
}

.close-btn,
#auth-modal .close-btn.auth-close-btn,
.outreach-modal-close {
    border-radius: var(--bridge-ui-radius) !important;
}

/* Workspace shell */
body.workspace-shell-active {
    --bridge-enterprise-ink: var(--bridge-ui-ink);
    --bridge-enterprise-ink-soft: var(--bridge-ui-ink-soft);
    --bridge-enterprise-muted: var(--bridge-ui-muted);
    --bridge-enterprise-line: var(--bridge-ui-line);
    --bridge-enterprise-line-strong: var(--bridge-ui-line-strong);
    --bridge-enterprise-canvas: var(--bridge-ui-canvas);
    --bridge-enterprise-surface: var(--bridge-ui-surface);
    --bridge-enterprise-subtle: var(--bridge-ui-surface-subtle);
    --bridge-enterprise-accent: var(--bridge-ui-green);
    --bridge-enterprise-accent-2: var(--bridge-ui-blue);
    --bridge-enterprise-radius: var(--bridge-ui-radius);
    --bridge-enterprise-shadow: var(--bridge-ui-shadow);
    --bridge-enterprise-shadow-hover: var(--bridge-ui-shadow);
    --bridge-enterprise-focus: var(--bridge-ui-focus);
    background: var(--bridge-ui-canvas);
    color: var(--bridge-ui-ink-soft);
}

body.workspace-shell-active .main-header,
body.dashboard-shell-scroll-lock .main-header,
body.spec-workspace-scroll-lock .main-header,
body:has(#dashboard-view.active) .main-header,
body:has(#spec-alignment-view.active) .main-header,
body:has(#messaging-view.active) .main-header {
    display: none !important;
}

body.workspace-shell-active :where(.dashboard-main-panel, #dashboard-view, #spec-alignment-view,
#messaging-view, .panel-content) {
    background: var(--bridge-ui-canvas);
    color: var(--bridge-ui-ink-soft);
}

body.workspace-shell-active .dashboard-main-panel {
    padding: clamp(0.9rem, 2vw, 1.65rem) clamp(0.9rem, 2.4vw, 2rem) 2rem;
    background: var(--bridge-ui-canvas);
}

body.workspace-shell-active .panel-content {
    gap: 1rem;
}

body.workspace-shell-active :where(.dashboard-section, .settings-card, .workspace-card,
.workspace-metric-card, .workspace-table-wrap, .workspace-hero, .sourcing-overview-hero,
.sourcing-projects-board, .sourcing-project-card, .sourcing-project-hero,
.sourcing-project-row, .sourcing-project-board-search, .sourcing-project-board-sort,
.sourcing-project-board-loader, .sourcing-project-empty-state,
.sourcing-workflow-topbar, .sourcing-workflow-stagebar, .sourcing-chat-shell,
.sourcing-chat-window, .sourcing-chat-window-header, .sourcing-chat-composer,
.sourcing-chat-input-shell, .sourcing-chat-assistant-note, .sourcing-chat-inline-note,
.sourcing-questionnaire-card, .sourcing-evidence-card, .sourcing-status-card,
.sourcing-status-metric, .table-container, .qc-filter-shell, .qc-dashboard-toolbar,
.qc-status-multiselect-menu, .qc-report-card, .qc-detail-hero, .qc-report-comment-box,
.evidence-item, .doc-pane, .chat-pane, .spec-supplier-sidebar-shell, .spec-files-sidebar,
.sidebar-tabs-horizontal, .sidebar-content, .checklist-table-scroll, .checklist-section,
.checklist-management-card, .price-payment-card, .price-payment-summary-field,
.price-payment-summary-metric, .price-payment-empty-state, .price-payment-loading,
.order-execution-hero, .order-execution-overview-card, .order-execution-order-card,
.order-execution-commercial-section, .order-execution-project-row,
.order-execution-project-order-card, .order-execution-invoice-card,
.order-execution-detail-card, .order-execution-status-card, .order-execution-status-panel,
.order-execution-note-card, .order-execution-inline-banner, .conversation-card,
.conversation-project-card, .conversation-row, .friends-column, .active-chat,
.invitation-card, .file-group-card) {
    border-radius: var(--bridge-ui-radius) !important;
}

body.workspace-shell-active :where(.workspace-card, .workspace-metric-card, .workspace-table-wrap,
.workspace-hero, .sourcing-overview-hero, .sourcing-projects-board, .sourcing-project-card,
.sourcing-project-hero, .sourcing-project-row, .sourcing-workflow-topbar,
.sourcing-workflow-stagebar, .sourcing-chat-shell, .sourcing-chat-window,
.sourcing-questionnaire-card, .sourcing-evidence-card, .sourcing-status-card,
.table-container, .qc-filter-shell, .qc-dashboard-toolbar, .qc-report-card,
.qc-detail-hero, .doc-pane, .chat-pane, .checklist-section, .price-payment-card,
.order-execution-hero, .order-execution-overview-card, .order-execution-order-card,
.order-execution-commercial-section, .order-execution-project-row,
.order-execution-project-order-card, .order-execution-invoice-card,
.order-execution-detail-card, .order-execution-status-card, .order-execution-status-panel,
.order-execution-note-card, .conversation-card, .conversation-project-card,
.conversation-row, .friends-column, .active-chat, .file-group-card, .invitation-card) {
    background: var(--bridge-ui-surface) !important;
    border: 1px solid var(--bridge-ui-line) !important;
    box-shadow: var(--bridge-ui-shadow);
    backdrop-filter: none;
}

body.workspace-shell-active :where(.sourcing-project-card, .sourcing-project-row,
.workspace-card, .order-execution-order-card, .order-execution-project-row,
.order-execution-project-order-card, .order-execution-invoice-card,
.conversation-row, .project-workspace-contact-row, .contact-panel-item,
.file-item-row):hover {
    border-color: var(--bridge-ui-line-strong) !important;
    box-shadow: var(--bridge-ui-shadow);
    transform: translateY(-1px);
}

/* Workspace navigation */
body.workspace-shell-active .dashboard-sidebar,
body.workspace-shell-active .dashboard-topbar {
    background: rgba(255, 255, 255, 0.96);
    border-color: var(--bridge-ui-line);
    box-shadow: none;
    backdrop-filter: blur(12px);
}

body.workspace-shell-active .sidebar-header {
    padding: 1rem 0.9rem 0.7rem;
    margin-bottom: 0.4rem;
}

body.workspace-shell-active .workspace-sidebar-brand {
    width: 100%;
    min-height: 48px;
    padding: 0.35rem 0.45rem;
    border: 1px solid transparent;
    border-radius: var(--bridge-ui-radius);
    background: transparent;
}

body.workspace-shell-active .workspace-sidebar-brand-mark {
    display: flex !important;
    align-items: center;
    justify-content: flex-start;
    width: 100%;
    height: auto;
    background: transparent;
    border: 0;
    box-shadow: none;
}

body.workspace-shell-active .workspace-sidebar-brand-mark img {
    max-width: 150px;
    max-height: 42px;
    object-fit: contain;
}

body.workspace-shell-active .workspace-sidebar-scroll {
    padding: 0 0.75rem 0.75rem;
    gap: 1rem;
}

body.workspace-shell-active .sidebar-nav,
body.workspace-shell-active .workflow-steps-group {
    gap: 0.25rem;
}

body.workspace-shell-active .sidebar-btn {
    min-height: 40px;
    padding: 0.55rem 0.65rem;
    border: 1px solid transparent;
    border-radius: var(--bridge-ui-radius-sm);
    background: transparent;
    color: var(--bridge-ui-muted);
    font-size: 0.95rem;
    font-weight: 500;
}

body.workspace-shell-active .sidebar-btn:hover {
    background: var(--bridge-ui-surface-subtle);
    border-color: var(--bridge-ui-line);
    color: var(--bridge-ui-ink);
}

body.workspace-shell-active .sidebar-btn.active {
    background: var(--bridge-ui-blue-soft);
    border-color: var(--bridge-ui-blue-line);
    color: var(--bridge-ui-blue);
    box-shadow: none;
}

body.workspace-shell-active .sidebar-step-index {
    width: 24px;
    height: 24px;
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius-xs);
    background: var(--bridge-ui-surface);
    color: var(--bridge-ui-muted);
}

body.workspace-shell-active .sidebar-btn.active .sidebar-step-index {
    border-color: var(--bridge-ui-blue-line);
    background: #ffffff;
    color: var(--bridge-ui-blue);
}

body.workspace-shell-active .sidebar-footer {
    border-top: 1px solid var(--bridge-ui-line);
    padding: 0.75rem;
    gap: 0.55rem;
}

body.workspace-shell-active :where(.workspace-sidebar-language, .workspace-sidebar-user-card) {
    min-height: 40px;
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius);
    background: var(--bridge-ui-surface);
    box-shadow: none;
}

body.workspace-shell-active .workspace-sidebar-avatar,
body.workspace-shell-active .contact-panel-avatar,
body.workspace-shell-active .project-workspace-contact-avatar,
body.workspace-shell-active .order-execution-invoice-icon,
body.workspace-shell-active .sourcing-project-row-icon,
body.workspace-shell-active .sourcing-project-empty-icon,
body.workspace-shell-active .order-execution-empty-icon {
    border-radius: var(--bridge-ui-radius) !important;
    background: var(--bridge-ui-blue-soft);
    color: var(--bridge-ui-blue);
    box-shadow: none;
}

/* Dashboard, sourcing list, tables */
body.workspace-shell-active :where(.workspace-home-shell, .sourcing-overview-shell,
.sourcing-project-board-shell, .order-execution-shell, .qc-dashboard-shell) {
    max-width: 1280px;
    margin-inline: auto;
}

body.workspace-shell-active :where(.workspace-hero, .sourcing-overview-hero,
.sourcing-project-hero, .order-execution-hero) {
    padding: clamp(1rem, 2vw, 1.45rem);
    background: var(--bridge-ui-surface) !important;
}

body.workspace-shell-active :where(.workspace-hero, .sourcing-overview-hero,
.order-execution-hero) {
    border-left: 4px solid var(--bridge-ui-blue) !important;
}

body.workspace-shell-active :where(.workspace-hero h1, .sourcing-overview-copy h2,
.sourcing-project-title, .order-execution-hero h2,
.qc-dashboard-shell > .section-header h2) {
    font-size: clamp(1.75rem, 3vw, 2.7rem);
    line-height: 1.05;
}

body.workspace-shell-active :where(.workspace-hero p, .workspace-card p,
.sourcing-overview-copy p, .sourcing-project-summary,
.sourcing-project-card-summary, .order-execution-hero p, .qc-dashboard-shell p,
.order-execution-note-card p) {
    color: var(--bridge-ui-muted);
}

body.workspace-shell-active :where(.workspace-hero-kicker, .sourcing-overview-kicker,
.sourcing-project-kicker, .workspace-card-kicker, .order-execution-overline,
.sourcing-board-kicker, .qc-toolbar-field label, .workspace-metric-label,
.order-execution-overview-label) {
    color: var(--bridge-ui-blue);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0 !important;
    text-transform: none;
}

body.workspace-shell-active .workspace-metrics,
body.workspace-shell-active .order-execution-overview-grid {
    gap: 0.75rem;
}

body.workspace-shell-active .workspace-metric-card,
body.workspace-shell-active .order-execution-overview-card {
    padding: 1rem;
    border-top: 3px solid var(--bridge-ui-green) !important;
}

body.workspace-shell-active .workspace-metric-card strong,
body.workspace-shell-active .order-execution-overview-card strong {
    color: var(--bridge-ui-ink);
    font-size: clamp(1.65rem, 2.6vw, 2.25rem);
    font-weight: 700;
}

body.workspace-shell-active .workspace-card,
body.workspace-shell-active .sourcing-project-card {
    padding: 1rem;
}

body.workspace-shell-active .workspace-card-count,
body.workspace-shell-active .sourcing-board-count {
    border-radius: var(--bridge-ui-radius-sm) !important;
    border: 1px solid var(--bridge-ui-line);
    background: var(--bridge-ui-surface-subtle);
    color: var(--bridge-ui-ink);
    font-weight: 700;
}

body.workspace-shell-active :where(.workspace-table, .qc-table, .checklist-table,
.sourcing-questionnaire-table, .price-payment-table, .price-payment-summary-table,
.price-payment-installment-table) {
    border-collapse: separate;
    border-spacing: 0;
}

body.workspace-shell-active :where(.workspace-table thead th, .qc-table th,
.checklist-table th, .sourcing-questionnaire-table th, .price-payment-table th,
.price-payment-summary-table th, .price-payment-installment-table th) {
    background: var(--bridge-ui-surface-subtle) !important;
    border-bottom: 1px solid var(--bridge-ui-line);
    color: var(--bridge-ui-ink);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0 !important;
    text-transform: none;
}

body.workspace-shell-active :where(.workspace-table tbody td, .qc-table td,
.checklist-table td, .sourcing-questionnaire-cell, .price-payment-table td,
.price-payment-summary-table td, .price-payment-installment-table td) {
    border-bottom: 1px solid var(--bridge-ui-line);
    color: var(--bridge-ui-ink-soft);
}

body.workspace-shell-active :where(.workspace-table tbody tr:hover, .qc-table tr:hover,
.checklist-table tr:hover, .price-payment-table tr:hover) {
    background: var(--bridge-ui-canvas-soft);
}

body.workspace-shell-active .sourcing-project-card::after,
body.workspace-shell-active .dashboard-section::before {
    display: none;
}

body.workspace-shell-active .sourcing-project-card-stage,
body.workspace-shell-active .sourcing-project-card-stage.is-live {
    background: var(--bridge-ui-green-soft);
    border: 1px solid var(--bridge-ui-green-line);
    color: var(--bridge-ui-green-dark);
}

body.workspace-shell-active .sourcing-project-board-search,
body.workspace-shell-active .sourcing-project-board-sort {
    min-height: 42px;
    border-color: var(--bridge-ui-line) !important;
    background: var(--bridge-ui-surface) !important;
    box-shadow: none;
}

body.workspace-shell-active .sourcing-project-row {
    grid-template-columns: 48px minmax(0, 1fr) auto;
    gap: 0.9rem;
    padding: 0.9rem 1rem;
}

body.workspace-shell-active .sourcing-project-row-icon {
    width: 48px;
    height: 48px;
}

body.workspace-shell-active .delete-project-btn,
body.workspace-shell-active .sourcing-project-row-delete {
    border-color: #ffd0cc;
    background: var(--bridge-ui-surface);
    color: var(--bridge-ui-danger);
}

/* Sourcing workflow, chat, and project workspace */
body.workspace-shell-active .sourcing-workflow-topbar {
    gap: 0.85rem;
    background: var(--bridge-ui-surface) !important;
}

body.workspace-shell-active .sourcing-workflow-view-toggle,
body.workspace-shell-active .spec-chat-tabs,
body.workspace-shell-active .sidebar-tabs-horizontal,
body.workspace-shell-active .qc-folder-switch {
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius);
    background: var(--bridge-ui-surface-subtle);
    padding: 0.22rem;
}

body.workspace-shell-active :where(.sourcing-workflow-view-btn.active, .spec-chat-tab.active,
.sidebar-htab.active, .qc-folder-btn.active, .checklist-table-switch-btn.active) {
    background: var(--bridge-ui-surface) !important;
    border-color: var(--bridge-ui-line-strong) !important;
    color: var(--bridge-ui-ink) !important;
    box-shadow: 0 1px 2px rgba(16, 17, 20, 0.05);
}

body.workspace-shell-active .spec-left-sidebar .sidebar-tabs-horizontal .sidebar-htab {
    color: var(--bridge-ui-ink-soft) !important;
    background: transparent !important;
    opacity: 1;
}

body.workspace-shell-active .spec-left-sidebar .sidebar-tabs-horizontal .sidebar-htab :where(i, span) {
    color: inherit !important;
}

body.workspace-shell-active .spec-left-sidebar .sidebar-tabs-horizontal .sidebar-htab:not(.active):hover {
    color: var(--bridge-ui-blue) !important;
    background: var(--bridge-ui-blue-soft) !important;
}

body.workspace-shell-active .spec-left-sidebar .sidebar-tabs-horizontal .sidebar-htab.active {
    background: var(--bridge-ui-blue) !important;
    border-color: var(--bridge-ui-blue) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 10px rgba(0, 113, 227, 0.18);
}

body.workspace-shell-active .qc-folder-switch .qc-folder-btn.active {
    background: var(--bridge-ui-blue) !important;
    border-color: var(--bridge-ui-blue) !important;
    color: #ffffff !important;
    box-shadow: 0 6px 14px rgba(0, 113, 227, 0.22);
}

body.workspace-shell-active .qc-folder-switch .qc-folder-btn:not(.active):hover {
    border-color: var(--bridge-ui-blue-line) !important;
    color: var(--bridge-ui-blue) !important;
}

body.workspace-shell-active .sourcing-workflow-stagebar {
    display: grid;
    gap: 0.5rem;
}

body.workspace-shell-active .sourcing-workflow-stage,
body.workspace-shell-active .order-execution-step {
    clip-path: none !important;
    min-height: 62px;
    padding: 0.72rem;
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius) !important;
    background: var(--bridge-ui-surface-subtle);
    color: var(--bridge-ui-muted);
    box-shadow: none;
}

body.workspace-shell-active .sourcing-workflow-stage.active,
body.workspace-shell-active .order-execution-step.current {
    background: var(--bridge-ui-blue) !important;
    border-color: var(--bridge-ui-blue) !important;
    color: #ffffff !important;
}

body.workspace-shell-active .sourcing-workflow-stage.done,
body.workspace-shell-active .order-execution-step.complete {
    background: var(--bridge-ui-green-soft) !important;
    border-color: var(--bridge-ui-green-line) !important;
    color: var(--bridge-ui-green-dark) !important;
}

body.workspace-shell-active .sourcing-chat-window,
body.workspace-shell-active #spec-chat-region.chat-pane.telegram-style,
body.workspace-shell-active #spec-chat-region .project-workspace-ai-thread .sourcing-chat-thread {
    background: var(--bridge-ui-surface) !important;
}

body.workspace-shell-active .sourcing-chat-window-header,
body.workspace-shell-active :where(.spec-supplier-sidebar-header, .spec-files-sidebar-header,
#spec-chat-region .pane-header, #spec-chat-region .input-container,
.panel-header, .file-group-head) {
    border-color: var(--bridge-ui-line);
    background: var(--bridge-ui-surface);
}

body.workspace-shell-active .sourcing-chat-bubble,
body.workspace-shell-active #spec-chat-region :where(.telegram-message-bubble, .message-bubble) {
    border-radius: 14px !important;
    border: 1px solid var(--bridge-ui-line);
    box-shadow: none;
}

body.workspace-shell-active .sourcing-chat-bubble.buyer,
body.workspace-shell-active #spec-chat-region :where(.telegram-message.sent .telegram-message-bubble,
.message-bubble.sent) {
    background: var(--bridge-ui-blue) !important;
    border-color: var(--bridge-ui-blue) !important;
    color: #ffffff !important;
}

body.workspace-shell-active .sourcing-chat-bubble.assistant,
body.workspace-shell-active #spec-chat-region :where(.telegram-message.received .telegram-message-bubble,
.message-bubble.received) {
    background: var(--bridge-ui-surface-subtle) !important;
    color: var(--bridge-ui-ink-soft) !important;
}

body.workspace-shell-active #spec-chat-region :where(.telegram-message.bridge-ai .telegram-message-bubble,
.spec-ai-agent.received .telegram-message-bubble) {
    background: var(--bridge-ui-blue-soft) !important;
    border-color: var(--bridge-ui-blue-line) !important;
    color: var(--bridge-ui-ink) !important;
}

body.workspace-shell-active :where(.sourcing-chat-composer, .sourcing-chat-input-shell,
#spec-chat-region .input-container) {
    border-color: var(--bridge-ui-line) !important;
    background: var(--bridge-ui-surface) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active #spec-chat-region .input-container {
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-active:not(.project-workspace-ai-active) #spec-chat-region .input-container {
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active #project-workspace-composer-slot {
    display: block;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active .project-workspace-ai-composer {
    gap: 0.45rem;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active .project-workspace-ai-composer .sourcing-chat-input-shell {
    margin: 0;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-active,
body.workspace-shell-active .spec-three-pane-layout {
    background: var(--bridge-ui-canvas);
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-active :where(#spec-supplier-sidebar,
#spec-files-sidebar, #spec-left-sidebar, #spec-chat-region),
body.workspace-shell-active :where(#spec-supplier-sidebar, #spec-files-sidebar,
#spec-left-sidebar, #spec-chat-region) {
    border-color: var(--bridge-ui-line);
    background: var(--bridge-ui-surface);
    box-shadow: none;
}

body.workspace-shell-active .project-workspace-contact-list {
    gap: 0.35rem;
}

body.workspace-shell-active .project-workspace-contact-row,
body.workspace-shell-active .contact-panel-item,
body.workspace-shell-active .invitation-card {
    border: 1px solid transparent;
    border-radius: var(--bridge-ui-radius);
    background: transparent;
}

body.workspace-shell-active .project-workspace-contact-row.active,
body.workspace-shell-active .contact-panel-item.active,
body.workspace-shell-active .project-workspace-contact-row.is-ai.active,
body.workspace-shell-active .project-workspace-contact-row.is-supplier.active {
    background: var(--bridge-ui-blue-soft) !important;
    border-color: var(--bridge-ui-blue-line) !important;
    color: var(--bridge-ui-ink);
    box-shadow: none;
}

body.workspace-shell-active .project-workspace-contact-avatar.is-ai {
    background: var(--bridge-ui-blue-soft);
    color: var(--bridge-ui-blue);
}

body.workspace-shell-active .project-workspace-contact-avatar.is-supplier {
    background: var(--bridge-ui-green-soft);
    color: var(--bridge-ui-green-dark);
}

body.workspace-shell-active .project-workspace-contact-kind,
body.workspace-shell-active .project-workspace-contact-count {
    border: 1px solid var(--bridge-ui-line);
    border-radius: 999px;
    background: var(--bridge-ui-surface);
    color: var(--bridge-ui-muted);
}

body.workspace-shell-active #spec-files-sidebar .file-item-row:hover,
body.workspace-shell-active .project-workspace-questionnaire-card,
body.workspace-shell-active .merged-questionnaire-checklist.sourcing-questionnaire-card {
    background: var(--bridge-ui-canvas-soft);
}

body.workspace-shell-active .sourcing-questionnaire-section-title-row,
body.workspace-shell-active .sourcing-questionnaire-section-title-row td {
    background: var(--bridge-ui-surface-muted) !important;
    border-color: var(--bridge-ui-line) !important;
    color: var(--bridge-ui-ink) !important;
}

body.workspace-shell-active .sourcing-questionnaire-subsection-title-row,
body.workspace-shell-active .sourcing-questionnaire-subsection-title-row td {
    background: var(--bridge-ui-surface-subtle) !important;
    border-color: var(--bridge-ui-line) !important;
    color: var(--bridge-ui-ink-soft) !important;
}

body.workspace-shell-active .sourcing-questionnaire-priority {
    border-radius: 999px;
    box-shadow: none;
}

body.workspace-shell-active .sourcing-questionnaire-priority.is-must_have {
    background: var(--bridge-ui-danger-soft);
    border-color: #ffd0cc;
    color: var(--bridge-ui-danger);
}

body.workspace-shell-active .sourcing-questionnaire-priority.is-should_have {
    background: var(--bridge-ui-warning-soft);
    border-color: #fed7aa;
    color: var(--bridge-ui-warning);
}

body.workspace-shell-active .sourcing-questionnaire-priority.is-nice_to_have {
    background: var(--bridge-ui-blue-soft);
    border-color: var(--bridge-ui-blue-line);
    color: var(--bridge-ui-blue);
}

/* QC and order execution */
body.workspace-shell-active .qc-dashboard-shell {
    gap: 1rem;
}

body.workspace-shell-active .qc-dashboard-shell > .section-header {
    margin-bottom: 0 !important;
    padding: 1rem 1.2rem;
    border: 1px solid var(--bridge-ui-line);
    border-radius: var(--bridge-ui-radius);
    background: var(--bridge-ui-surface);
    box-shadow: var(--bridge-ui-shadow);
}

body.workspace-shell-active .qc-filter-shell,
body.workspace-shell-active .qc-dashboard-toolbar,
body.workspace-shell-active .order-execution-commercial-section {
    padding: 1rem;
}

body.workspace-shell-active .qc-table-shell {
    overflow-x: hidden;
}

body.workspace-shell-active .qc-table {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}

body.workspace-shell-active .qc-col-status {
    width: 13%;
}

body.workspace-shell-active .qc-col-order {
    width: 23%;
}

body.workspace-shell-active .qc-col-people {
    width: 20%;
}

body.workspace-shell-active .qc-col-schedule {
    width: 22%;
}

body.workspace-shell-active .qc-col-actions {
    width: 22%;
}

body.workspace-shell-active .qc-table th,
body.workspace-shell-active .qc-table td {
    min-width: 0;
    padding: 0.58rem 0.68rem;
    font-size: 0.88rem;
    line-height: 1.3;
    vertical-align: middle;
}

body.workspace-shell-active .qc-table th {
    white-space: normal;
    overflow-wrap: anywhere;
}

body.workspace-shell-active .qc-table tbody td {
    height: auto;
}

body.workspace-shell-active .qc-table :where(.status-badge, .qc-data-pill, .qc-tech-status-pill) {
    padding: 0.28rem 0.58rem;
    font-size: 0.72rem;
    line-height: 1.1;
}

body.workspace-shell-active .qc-header-subline {
    display: block;
    margin-top: 0.15rem;
    color: var(--bridge-ui-muted);
    font-size: 0.72rem;
    font-weight: 600;
    line-height: 1.15;
}

body.workspace-shell-active .qc-sort-stack {
    display: grid;
    gap: 0.25rem;
}

body.workspace-shell-active .qc-sort-stack .qc-sort-header {
    min-height: auto;
    white-space: normal;
}

body.workspace-shell-active .qc-primary-line,
body.workspace-shell-active .qc-compact-line > span,
body.workspace-shell-active .qc-compact-line .qc-data-pill,
body.workspace-shell-active .qc-table .unassigned {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.workspace-shell-active .qc-primary-line {
    font-weight: 700;
    color: var(--bridge-ui-ink);
}

body.workspace-shell-active .qc-compact-line {
    display: flex;
    align-items: center;
    min-width: 0;
    max-width: 100%;
    gap: 0.36rem;
    color: var(--bridge-ui-ink-soft);
}

body.workspace-shell-active .qc-compact-line + .qc-compact-line,
body.workspace-shell-active .qc-order-secondary + .qc-compact-line {
    margin-top: 0.32rem;
}

body.workspace-shell-active .qc-compact-line i {
    width: 14px;
    flex: 0 0 14px;
    color: var(--bridge-ui-green);
    text-align: center;
}

body.workspace-shell-active .qc-table .deadline-cell,
body.workspace-shell-active .qc-table .date-cell,
body.workspace-shell-active .qc-table .shipment-cell,
body.workspace-shell-active .qc-table .supplier-cell,
body.workspace-shell-active .qc-table .inspector-cell {
    min-width: 0;
    white-space: nowrap;
}

body.workspace-shell-active .qc-order-secondary {
    margin-top: 0.32rem;
    max-width: 100%;
}

body.workspace-shell-active .qc-tech-status-pill {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.workspace-shell-active .qc-actions-cell {
    width: auto;
    min-width: 0;
    white-space: normal;
}

body.workspace-shell-active .qc-actions-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    align-content: center;
    gap: 0.32rem;
    flex-wrap: wrap;
}

body.workspace-shell-active .qc-actions-toolbar :where(.btn-outline, .qc-row-action-btn, .qc-file-preview-action) {
    min-height: 32px;
    height: 32px;
    max-width: 100%;
    padding: 0.28rem 0.5rem !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1;
}

body.workspace-shell-active .qc-actions-toolbar .qc-file-preview-action {
    min-width: 54px;
}

body.workspace-shell-active .qc-row-action-btn--collaborators {
    max-width: 128px;
}

body.workspace-shell-active .qc-row-action-btn--collaborators {
    overflow: hidden;
    text-overflow: ellipsis;
}

body.workspace-shell-active .qc-row-action-btn--danger {
    width: 32px;
    min-width: 32px;
    padding-inline: 0 !important;
    border-color: #ffd0cc !important;
    color: var(--bridge-ui-danger) !important;
}

body.workspace-shell-active .qc-row-action-btn--danger:hover {
    background: var(--bridge-ui-danger-soft) !important;
    border-color: #ffb4ad !important;
    color: var(--bridge-ui-danger) !important;
}

body.workspace-shell-active .qc-payment-checkbox,
body.workspace-shell-active .qc-payment-times {
    min-height: 32px;
    white-space: nowrap;
}

body.workspace-shell-active .qc-detail-hero {
    min-height: 240px;
    padding: clamp(1.1rem, 2.2vw, 1.65rem);
    gap: clamp(1rem, 2vw, 1.8rem);
}

body.workspace-shell-active .order-execution-hero {
    border-left-color: var(--bridge-ui-green) !important;
}

body.workspace-shell-active .order-execution-status-track {
    gap: 0.5rem;
}

body.workspace-shell-active .order-execution-project-shell.is-expanded .order-execution-project-row {
    border-color: var(--bridge-ui-blue) !important;
}

body.workspace-shell-active .order-execution-invoice-icon {
    background: var(--bridge-ui-green-soft);
    color: var(--bridge-ui-green-dark);
}

/* Messaging overview */
body.workspace-shell-active #messaging-view,
body.workspace-shell-active .conversations-shell,
body.workspace-shell-active .conversation-dashboard-shell {
    background: var(--bridge-ui-canvas);
}

body.workspace-shell-active :where(.conversation-card, .conversation-project-card,
.conversation-row) {
    padding: 0.9rem 1rem;
}

body.workspace-shell-active :where(.conversation-card h2, .conversation-project-card h3,
.conversation-row strong) {
    color: var(--bridge-ui-ink);
}

/* Responsive guardrails */
@media (max-width: 1100px) {
    body.workspace-shell-active .workspace-metrics,
    body.workspace-shell-active .order-execution-overview-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body.workspace-shell-active :where(.workspace-hero, .sourcing-overview-hero,
    .sourcing-project-hero, .order-execution-hero) {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 980px) {
    .main-header {
        height: 66px;
        padding-inline: 0.85rem;
    }

    .main-header nav {
        margin-left: 0.75rem;
    }

    .nav-main-links {
        gap: 0.12rem;
    }

    body.workspace-shell-active .dashboard-main-panel {
        padding: 0.85rem;
    }

    body.workspace-shell-active .sourcing-workflow-topbar {
        grid-template-columns: 1fr;
    }

    body.workspace-shell-active .order-execution-status-track {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .main-header {
        min-height: 62px;
    }

    .nav-main-links {
        display: none;
    }

    #home-view.public-landing-shell .hero.reworked {
        min-height: auto;
        padding: 5rem 1rem 2rem;
    }

    #home-view.public-landing-shell .public-landing-hero-proof {
        width: 100%;
        flex-wrap: wrap;
    }

    #home-view.public-landing-shell .section-container.public-section {
        width: min(100%, calc(100vw - 1.25rem));
        padding: clamp(2.25rem, 8vw, 3.25rem) 1rem;
    }

    #home-view.public-landing-shell :where(.hero-tabs, .public-section--split,
    .contact-grid) {
        grid-template-columns: 1fr;
    }

    #auth-modal .modal-content.auth-modal-shell,
    #auth-modal.auth-register-mode .modal-content.auth-modal-shell {
        grid-template-columns: 1fr;
    }

    #auth-modal .auth-brand-panel {
        min-height: auto;
        padding: 1.25rem;
    }

    #auth-modal .auth-form-panel {
        border-left: 0;
        border-top: 1px solid var(--bridge-ui-line);
        padding: 1.25rem;
    }
}

@media (max-width: 640px) {
    body.workspace-shell-active .workspace-metrics,
    body.workspace-shell-active .order-execution-overview-grid,
    body.workspace-shell-active .order-execution-status-track {
        grid-template-columns: 1fr;
    }

    body.workspace-shell-active :where(.workspace-hero, .workspace-card,
    .sourcing-overview-hero, .sourcing-projects-board, .sourcing-project-hero,
    .order-execution-hero, .qc-dashboard-shell > .section-header) {
        padding: 0.9rem;
    }

    body.workspace-shell-active .sourcing-project-row {
        grid-template-columns: 42px minmax(0, 1fr);
        gap: 0.7rem;
    }

    body.workspace-shell-active .sourcing-project-row-icon {
        width: 42px;
        height: 42px;
    }

    body.workspace-shell-active :where(.sourcing-project-row-status,
    .sourcing-project-row-summary, .sourcing-project-row-action) {
        grid-column: 1 / -1;
    }
}

@media (prefers-reduced-motion: reduce) {
    body :where(*, *::before, *::after) {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

/* Bauhaus workspace layer.
   Scoped to authenticated workspace surfaces so the public landing page keeps
   its existing styling while dashboard, sourcing, order, QC, chat, and settings
   share one flat enterprise system. */
body.workspace-shell-active {
    --bridge-canvas: #f4f4ef;
    --bridge-surface: #ffffff;
    --bridge-surface-muted: #eeeeea;
    --bridge-ink: #111111;
    --bridge-ink-soft: #555852;
    --bridge-line: #c7c8c1;
    --bridge-line-strong: #181818;
    --bridge-yellow: #f4cb50;
    --bridge-lilac: #dfa9e4;
    --bridge-mint: #87e3a0;
    --bridge-cyan: #a9e5ea;
    --bridge-periwinkle: #9b98e4;
    --bridge-orange: #ff9238;
    --bridge-success: #71d79a;
    --bridge-warning: #f4cb50;
    --bridge-danger: #d9433f;
    --bridge-info: #a9e5ea;
    --radius-control: 8px;
    --radius-card: 10px;
    --radius-pill: 999px;
    --radius-arch: 36px;
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 24px;
    --space-6: 32px;
    --space-7: 48px;
    --bridge-ui-ink: var(--bridge-ink);
    --bridge-ui-ink-soft: var(--bridge-ink-soft);
    --bridge-ui-muted: #666961;
    --bridge-ui-faint: #7c7f76;
    --bridge-ui-canvas: var(--bridge-canvas);
    --bridge-ui-canvas-soft: #f8f8f3;
    --bridge-ui-surface: var(--bridge-surface);
    --bridge-ui-surface-subtle: var(--bridge-surface-muted);
    --bridge-ui-surface-muted: #e5e5df;
    --bridge-ui-line: var(--bridge-line);
    --bridge-ui-line-strong: var(--bridge-line-strong);
    --bridge-ui-blue: var(--bridge-ink);
    --bridge-ui-blue-hover: #2a2a2a;
    --bridge-ui-blue-soft: #eefafa;
    --bridge-ui-blue-line: #77cdd5;
    --bridge-ui-green: var(--bridge-success);
    --bridge-ui-green-dark: #1f6c3d;
    --bridge-ui-green-soft: #e9f8ec;
    --bridge-ui-green-line: #94dba8;
    --bridge-ui-warning: #79521a;
    --bridge-ui-warning-soft: #fff5d8;
    --bridge-ui-danger: var(--bridge-danger);
    --bridge-ui-danger-soft: #fdecea;
    --bridge-ui-radius: var(--radius-control);
    --bridge-ui-radius-sm: var(--radius-control);
    --bridge-ui-radius-xs: 4px;
    --bridge-ui-shadow: none;
    --bridge-ui-shadow-float: 0 8px 24px rgba(17, 17, 17, 0.05);
    --bridge-ui-focus: 0 0 0 3px rgba(169, 229, 234, 0.82);
    --bridge-ui-control-h: 44px;
    --bridge-enterprise-ink: var(--bridge-ink);
    --bridge-enterprise-ink-soft: var(--bridge-ink-soft);
    --bridge-enterprise-muted: #666961;
    --bridge-enterprise-line: var(--bridge-line);
    --bridge-enterprise-line-strong: var(--bridge-line-strong);
    --bridge-enterprise-canvas: var(--bridge-canvas);
    --bridge-enterprise-surface: var(--bridge-surface);
    --bridge-enterprise-subtle: var(--bridge-surface-muted);
    --bridge-enterprise-accent: var(--bridge-mint);
    --bridge-enterprise-accent-2: var(--bridge-cyan);
    --bridge-enterprise-radius: var(--radius-control);
    --bridge-enterprise-shadow: none;
    --bridge-enterprise-shadow-hover: none;
    --bridge-enterprise-focus: var(--bridge-ui-focus);
    background: var(--bridge-canvas) !important;
    color: var(--bridge-ink-soft);
    font-family: "Inter", "Avenir Next", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

body.workspace-shell-active :where(*):not(.material-symbols-outlined):not(.material-symbols-rounded):not(.material-icons):not(.fa):not(.fas):not(.far):not(.fab):not(.fa-solid):not(.fa-regular):not(.fa-brands):not([class^="fa-"]):not([class*=" fa-"]):not(svg):not(path):not(canvas):not(video):not(audio):not(img):not(code):not(pre):not(kbd):not(samp) {
    font-family: "Inter", "Avenir Next", "Helvetica Neue", Helvetica, Arial, sans-serif !important;
}

body.workspace-shell-active :where(h1, h2, h3, h4, h5, h6) {
    color: var(--bridge-ink) !important;
    font-weight: 600 !important;
    line-height: 1.08;
}

body.workspace-shell-active :where(.workspace-hero h1, .workspace-dashboard-header h1) {
    font-size: clamp(2.25rem, 3.4vw, 2.75rem) !important;
    font-weight: 560 !important;
    letter-spacing: -0.02em !important;
}

body.workspace-shell-active :where(.sourcing-overview-copy h2, .sourcing-project-title,
.order-execution-hero h2, .qc-dashboard-shell > .section-header h2,
.order-detail-meta-project) {
    font-size: clamp(1.85rem, 2.8vw, 2.35rem) !important;
    font-weight: 600 !important;
    letter-spacing: -0.015em !important;
}

body.workspace-shell-active :where(.workspace-dashboard-section-head h2, .workspace-card h3,
.sourcing-projects-board-head h3, .qc-report-card h3, .order-detail-card h3,
.settings-card h3) {
    color: var(--bridge-ink) !important;
    font-size: clamp(1rem, 1.1vw, 1.16rem) !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

body.workspace-shell-active :where(.workspace-hero-kicker, .sourcing-overview-kicker,
.sourcing-project-kicker, .workspace-card-kicker, .order-execution-overline,
.sourcing-board-kicker, .qc-toolbar-field label, .workspace-metric-label,
.order-execution-overview-label, .workspace-dashboard-task-copy p,
.workspace-dashboard-commercial-label, .order-detail-meta-kicker) {
    color: var(--bridge-ink-soft) !important;
    font-size: 0.72rem !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

body.workspace-shell-active :where(.dashboard-main-panel, #dashboard-view, #spec-alignment-view,
#messaging-view, .panel-content, .workspace-dashboard-layout) {
    background: var(--bridge-canvas) !important;
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active .dashboard-main-panel {
    padding: clamp(0.85rem, 2vw, 1.5rem) clamp(0.85rem, 2.2vw, 1.75rem) 1.75rem !important;
}

body.workspace-shell-active :where(.workspace-home-shell, .sourcing-overview-shell,
.sourcing-project-board-shell, .order-execution-shell, .qc-dashboard-shell,
.conversation-dashboard-shell, .conversations-shell) {
    max-width: min(1500px, calc(100vw - 2rem)) !important;
    margin-inline: auto !important;
}

body.workspace-shell-active :where(.workspace-card, .workspace-metric-card, .workspace-table-wrap,
.workspace-hero, .workspace-dashboard-task-card, .workspace-dashboard-table-shell,
.workspace-dashboard-invoice-card, .workspace-dashboard-empty, .sourcing-overview-hero,
.sourcing-projects-board, .sourcing-project-card, .sourcing-project-hero,
.sourcing-project-row, .sourcing-project-board-loader, .sourcing-project-empty-state,
.sourcing-workflow-topbar, .sourcing-workflow-stagebar, .sourcing-chat-shell,
.sourcing-chat-window, .sourcing-chat-window-header, .sourcing-chat-composer,
.sourcing-chat-input-shell, .sourcing-chat-assistant-note, .sourcing-chat-inline-note,
.sourcing-questionnaire-card, .sourcing-evidence-card, .sourcing-status-card,
.sourcing-status-metric, .table-container, .qc-filter-shell, .qc-dashboard-toolbar,
.qc-status-multiselect-menu, .qc-report-card, .qc-detail-hero, .qc-report-comment-box,
.qc-comment-feed-card, .qc-comment-entry, .evidence-item, .doc-pane, .chat-pane,
.spec-supplier-sidebar-shell, .spec-files-sidebar, .sidebar-tabs-horizontal,
.sidebar-content, .checklist-table-scroll, .checklist-section,
.checklist-management-card, .price-payment-card, .price-payment-summary-field,
.price-payment-summary-metric, .price-payment-empty-state, .price-payment-loading,
.order-execution-hero, .order-execution-overview-card, .order-execution-order-card,
.order-execution-commercial-section, .order-execution-project-row,
.order-execution-project-order-card, .order-execution-invoice-card,
.order-execution-detail-card, .order-execution-status-card, .order-execution-status-panel,
.order-execution-note-card, .order-execution-inline-banner, .order-detail-meta-row,
.order-detail-table-card, .order-detail-card, .conversation-card,
.conversation-project-card, .conversation-row, .friends-column, .active-chat,
.invitation-card, .file-group-card, .business-card-preview) {
    background: var(--bridge-surface) !important;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-card) !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
}

body.workspace-shell-active :where(.workspace-card, .workspace-metric-card, .workspace-dashboard-task-card,
.workspace-dashboard-invoice-card, .sourcing-project-card, .sourcing-project-row,
.order-execution-order-card, .order-execution-project-row,
.order-execution-project-order-card, .order-execution-invoice-card,
.conversation-row, .project-workspace-contact-row, .contact-panel-item,
.file-item-row):hover {
    background: #f8f8f3 !important;
    border-color: var(--bridge-line-strong) !important;
    box-shadow: none !important;
    transform: translateY(-1px);
}

body.workspace-shell-active :where(.workspace-dashboard-hero-cta, .workspace-dashboard-task-card,
.workspace-dashboard-invoice-card, .workspace-dashboard-table-shell, .table-container,
.qc-filter-shell, .qc-dashboard-toolbar, .qc-dashboard-shell > .section-header,
.qc-detail-hero, .qc-report-card, .qc-comment-feed-card, .order-detail-meta-row,
.order-detail-table-card, .order-detail-card, .order-execution-hero,
.sourcing-projects-board, .sourcing-project-row, .sourcing-questionnaire-card) {
    position: relative;
}

body.workspace-shell-active :where(.workspace-dashboard-task-card, .workspace-dashboard-invoice-card,
.sourcing-project-row, .order-execution-project-row, .conversation-row) {
    min-height: 64px;
}

/* Buttons and controls */
body.workspace-shell-active :where(.btn-primary, .login-btn, .nav-dash-btn,
.workspace-start-btn, .dashboard-main-btn.active, .submit-btn,
.sourcing-project-board-cta, .sourcing-chat-send-btn, .sourcing-action-pill.primary,
.order-execution-create-invoice-btn, .workspace-dashboard-create-invoice-btn,
.signoff-final-btn:not(:disabled), .price-payment-details-btn,
.price-payment-details-btn:not(:disabled), .qc-inspection-report-submit-btn) {
    min-height: 44px !important;
    padding: 0.68rem 1.22rem !important;
    border: 1px solid var(--bridge-ink) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-ink) !important;
    color: #ffffff !important;
    box-shadow: none !important;
    font-size: 0.86rem !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
}

body.workspace-shell-active :where(.btn-primary, .login-btn, .nav-dash-btn,
.workspace-start-btn, .dashboard-main-btn.active, .submit-btn,
.sourcing-project-board-cta, .sourcing-chat-send-btn, .sourcing-action-pill.primary,
.order-execution-create-invoice-btn, .workspace-dashboard-create-invoice-btn,
.signoff-final-btn:not(:disabled), .price-payment-details-btn,
.qc-inspection-report-submit-btn):hover {
    border-color: var(--bridge-ink) !important;
    background: #2a2a2a !important;
    color: #ffffff !important;
    box-shadow: none !important;
    transform: translateY(-1px);
}

body.workspace-shell-active :where(.btn-primary, .submit-btn, .sourcing-chat-send-btn,
.workspace-dashboard-create-invoice-btn):active {
    transform: translateY(0);
}

body.workspace-shell-active :where(.btn-secondary, .btn-outline, .dashboard-main-btn,
.sourcing-action-pill.secondary, .sourcing-chat-mode-btn,
.project-quick-action-btn, .order-detail-action-btn, .order-execution-back-btn,
.checklist-context-action-btn, .spec-ai-chat-action-btn, .qc-folder-btn,
.user-guide-toggle, .sidebar-utility-btn, .sidebar-logout-btn,
.sms-send-btn.secondary-submit-btn, .submit-btn.secondary-submit-btn,
.workspace-dashboard-link-btn, .workspace-dashboard-icon-btn,
.qc-row-action-btn, .qc-file-preview-action, .price-payment-add-installment-btn) {
    min-height: 40px !important;
    border: 1px solid var(--bridge-line-strong) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
}

body.workspace-shell-active :where(.sourcing-chat-icon-btn, .workspace-dashboard-icon-btn,
.project-workspace-files-rail-btn, .project-workspace-chat-rail-btn,
.project-workspace-supplier-rail-btn, .project-workspace-files-fold-btn,
.project-workspace-chat-fold-btn, .mobile-checklist-toggle, .telegram-more-btn,
.telegram-translate-btn, .telegram-quote-btn, .telegram-react-btn,
.qc-row-action-btn--danger) {
    width: 40px !important;
    min-width: 40px !important;
    height: 40px !important;
    min-height: 40px !important;
    padding: 0 !important;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-control) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.btn-secondary, .btn-outline, .dashboard-main-btn,
.sourcing-action-pill.secondary, .sourcing-chat-icon-btn, .sourcing-chat-mode-btn,
.project-quick-action-btn, .order-detail-action-btn, .order-execution-back-btn,
.checklist-context-action-btn, .spec-ai-chat-action-btn, .qc-folder-btn,
.user-guide-toggle, .sidebar-utility-btn, .sidebar-logout-btn,
.workspace-dashboard-link-btn, .workspace-dashboard-icon-btn,
.qc-row-action-btn, .qc-file-preview-action):hover {
    background: var(--bridge-surface-muted) !important;
    border-color: var(--bridge-line-strong) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
    transform: translateY(-1px);
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn {
    border-width: 1.5px !important;
    box-shadow: 0 8px 18px -16px rgba(15, 23, 42, 0.4) !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-back-to-project {
    background: #ecfdf3 !important;
    border-color: #86efac !important;
    color: #166534 !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-product-spec {
    background: #fff7ed !important;
    border-color: #fdba74 !important;
    color: #9a3412 !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-magic-link {
    background: #eff6ff !important;
    border-color: #93c5fd !important;
    color: #1d4ed8 !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-speculator-mode {
    background: #f5f3ff !important;
    border-color: #c4b5fd !important;
    color: #6d28d9 !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-supplier-fold {
    background: #f8fafc !important;
    border-color: #cbd5e1 !important;
    color: #334155 !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn:hover,
body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn:focus-visible {
    box-shadow: 0 14px 26px -18px rgba(15, 23, 42, 0.48) !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-back-to-project:hover,
body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-back-to-project:focus-visible {
    background: #dcfce7 !important;
    border-color: #4ade80 !important;
    color: #14532d !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-product-spec:hover,
body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-product-spec:focus-visible {
    background: #ffedd5 !important;
    border-color: #fb923c !important;
    color: #7c2d12 !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-magic-link:hover,
body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-magic-link:focus-visible {
    background: #dbeafe !important;
    border-color: #60a5fa !important;
    color: #1e40af !important;
}

body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-speculator-mode:hover,
body.workspace-shell-active .project-quick-actions--sidebar .project-quick-action-btn.is-speculator-mode:focus-visible {
    background: #ede9fe !important;
    border-color: #a78bfa !important;
    color: #5b21b6 !important;
}

body.workspace-shell-active :where(button:disabled, .btn-primary:disabled,
.submit-btn:disabled, .is-disabled) {
    background: #e2e2dc !important;
    border-color: var(--bridge-line) !important;
    color: #85887f !important;
    cursor: not-allowed !important;
    opacity: 1 !important;
    transform: none !important;
}

body.workspace-shell-active :where(.btn-primary[style*="b42318"],
.btn-primary[style*="#b42318"], .btn-primary[style*="ef4444"],
.btn-primary[style*="#ef4444"], .btn-primary[style*="dc2626"],
.qc-row-action-btn--danger, .delete-project-btn,
.sourcing-project-row-delete) {
    border-color: #b93632 !important;
    background: var(--bridge-danger) !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-decision-btn.qc-decision-btn--approve,
body.workspace-shell-active .qc-state-action-btn.qc-state-action-btn--shipment {
    background: var(--bridge-mint) !important;
    border-color: #3f9b5b !important;
    color: #123d24 !important;
}

body.workspace-shell-active .qc-decision-btn.qc-decision-btn--reject {
    background: #b93632 !important;
    border-color: #8d211e !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-decision-btn.qc-decision-btn--rework {
    background: #ff6f61 !important;
    border-color: #c94338 !important;
    color: #111111 !important;
}

body.workspace-shell-active .qc-decision-btn.qc-decision-btn--reinspection,
body.workspace-shell-active .qc-state-action-btn.qc-state-action-btn--rework,
body.workspace-shell-active .qc-state-action-btn.qc-state-action-btn--reinspection {
    background: var(--bridge-yellow) !important;
    border-color: #9d7420 !important;
    color: #1f1c12 !important;
}

body.workspace-shell-active :where(input, textarea, select, .req-select, .req-textarea,
.price-payment-input, .sourcing-questionnaire-field,
.merged-checklist-answer-input, .spec-conversation-proxy-field input,
.qc-toolbar-field input, .qc-toolbar-field select) {
    min-height: 42px;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-control) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(input, textarea, select, .req-select, .req-textarea,
.price-payment-input, .sourcing-questionnaire-field,
.merged-checklist-answer-input, .spec-conversation-proxy-field input,
.qc-toolbar-field input, .qc-toolbar-field select):focus {
    border-color: var(--bridge-line-strong) !important;
    box-shadow: var(--bridge-ui-focus) !important;
}

body.workspace-shell-active :where(input::placeholder, textarea::placeholder) {
    color: #85887f !important;
}

body.workspace-shell-active :where(input:disabled, textarea:disabled, select:disabled) {
    background: var(--bridge-surface-muted) !important;
    color: #787b72 !important;
    cursor: not-allowed;
}

/* Workspace navigation */
body.workspace-shell-active .dashboard-sidebar.dashboard-topbar,
body.workspace-shell-active .dashboard-sidebar {
    background: var(--bridge-surface) !important;
    border-color: var(--bridge-line-strong) !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workspace-sidebar-shell {
    border-bottom: 1px solid var(--bridge-line-strong);
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workspace-sidebar-brand {
    border: 1px solid transparent !important;
    border-radius: var(--radius-pill) !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workflow-steps-group {
    gap: 0 !important;
    border: 1px solid var(--bridge-line-strong);
    border-radius: var(--radius-control);
    background: var(--bridge-surface);
    overflow: hidden;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .sidebar-btn.workflow-step {
    min-height: 48px !important;
    height: 48px !important;
    margin-left: 0 !important;
    padding: 0 1.12rem !important;
    clip-path: none !important;
    border: 0 !important;
    border-left: 1px solid var(--bridge-line) !important;
    border-radius: 0 !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
    transform: none !important;
    font-size: 0.86rem !important;
    font-weight: 650 !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workflow-steps-group .sidebar-btn.workflow-step.is-visible-first {
    border-left: 0 !important;
    border-radius: 0 !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workflow-steps-group .sidebar-btn.workflow-step.is-visible-last,
body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workflow-steps-group .sidebar-btn.workflow-step.is-visible-first.is-visible-last {
    border-radius: 0 !important;
    padding-right: 1.12rem !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-main {
    min-height: 48px !important;
    height: 48px !important;
    border: 1px solid var(--bridge-line-strong) !important;
    border-radius: var(--radius-control) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-main.active {
    background: var(--bridge-ink) !important;
    border-color: var(--bridge-ink) !important;
    color: #ffffff !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-sourcing.active {
    background: var(--bridge-mint) !important;
    color: #102817 !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-order.active {
    background: var(--bridge-periwinkle) !important;
    color: #111111 !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-qc.active {
    background: var(--bridge-orange) !important;
    color: #111111 !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .sidebar-btn.workflow-step.active {
    border-color: var(--bridge-line-strong) !important;
    box-shadow: inset 0 -3px 0 var(--bridge-ink) !important;
    transform: none !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .sidebar-btn.workflow-step:hover,
body.workspace-shell-active .dashboard-sidebar.dashboard-topbar #btn-dash-main:hover {
    background: var(--bridge-surface-muted) !important;
    color: var(--bridge-ink) !important;
    box-shadow: inset 0 -2px 0 var(--bridge-ink) !important;
}

body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .sidebar-footer .sidebar-utility-btn,
body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .sidebar-footer .sidebar-logout-btn,
body.workspace-shell-active .workspace-sidebar-language,
body.workspace-shell-active .workspace-sidebar-user-card {
    min-height: 40px !important;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .workspace-sidebar-avatar,
body.workspace-shell-active .contact-panel-avatar,
body.workspace-shell-active .project-workspace-contact-avatar,
body.workspace-shell-active .order-execution-invoice-icon,
body.workspace-shell-active .sourcing-project-row-icon,
body.workspace-shell-active .sourcing-project-empty-icon,
body.workspace-shell-active .order-execution-empty-icon {
    border-radius: var(--radius-control) !important;
    background: var(--bridge-cyan) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .sourcing-project-row-icon--live,
body.workspace-shell-active .project-workspace-contact-avatar.is-supplier,
body.workspace-shell-active .workspace-dashboard-task-card--qc .workspace-dashboard-task-icon-wrap {
    background: var(--bridge-mint) !important;
    color: #143a22 !important;
}

body.workspace-shell-active .sourcing-project-row-icon--brief,
body.workspace-shell-active .project-workspace-contact-avatar.is-ai,
body.workspace-shell-active .workspace-dashboard-task-card--conversation .workspace-dashboard-task-icon-wrap {
    background: var(--bridge-cyan) !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .sourcing-project-row-icon--idle,
body.workspace-shell-active .workspace-dashboard-invoice-icon {
    background: var(--bridge-lilac) !important;
    color: #3f2144 !important;
}

/* Tables, badges, and data density */
body.workspace-shell-active :where(.workspace-table, .workspace-dashboard-table, .qc-table,
.checklist-table, .sourcing-questionnaire-table, .price-payment-table,
.price-payment-summary-table, .price-payment-installment-table,
.order-detail-table) {
    width: 100%;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active :where(.workspace-table-wrap, .workspace-dashboard-table-shell,
.table-container, .qc-table-shell, .checklist-table-scroll,
.order-detail-table-card) {
    overflow-x: auto !important;
    overflow-y: hidden;
}

body.workspace-shell-active :where(.workspace-table thead th, .workspace-dashboard-table thead th,
.qc-table th, .checklist-table th, .sourcing-questionnaire-table th,
.price-payment-table th, .price-payment-summary-table th,
.price-payment-installment-table th, .order-detail-table th) {
    background: var(--bridge-surface-muted) !important;
    border-bottom: 1px solid var(--bridge-line-strong) !important;
    color: var(--bridge-ink) !important;
    font-size: 0.78rem !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.workspace-table td, .workspace-dashboard-table td,
.qc-table td, .checklist-table td, .sourcing-questionnaire-cell,
.price-payment-table td, .price-payment-summary-table td,
.price-payment-installment-table td, .order-detail-table td) {
    min-height: 48px;
    border-bottom: 1px solid var(--bridge-line) !important;
    color: var(--bridge-ink-soft) !important;
    font-size: 0.86rem !important;
    line-height: 1.35 !important;
}

body.workspace-shell-active :where(.workspace-table tbody tr:hover, .workspace-dashboard-table tr:hover,
.qc-table tr:hover, .checklist-table tr:hover, .price-payment-table tr:hover,
.order-detail-table tbody tr:hover) {
    background: #f8f8f3 !important;
}

body.workspace-shell-active :where(.workspace-table tbody tr.is-selected,
.qc-table tr.is-selected, .checklist-table tr.is-selected,
.sourcing-questionnaire-row--generated-focus) {
    background: #eefafa !important;
    box-shadow: inset 4px 0 0 var(--bridge-ink) !important;
}

body.workspace-shell-active .sourcing-questionnaire-section-title-row,
body.workspace-shell-active .sourcing-questionnaire-section-title-row td {
    background: #e9e9e3 !important;
    border-color: var(--bridge-line) !important;
    color: var(--bridge-ink) !important;
    font-weight: 650 !important;
}

body.workspace-shell-active .sourcing-questionnaire-subsection-title-row,
body.workspace-shell-active .sourcing-questionnaire-subsection-title-row td {
    background: #f2f2ed !important;
    border-color: var(--bridge-line) !important;
    color: var(--bridge-ink) !important;
    font-weight: 650 !important;
}

body.workspace-shell-active .sourcing-questionnaire-subsection-toggle {
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active :where(.role-badge-mini, .role-badge-small,
.workspace-stage-badge, .workspace-status-badge, .workspace-dashboard-status,
.workspace-dashboard-task-chip, .workspace-dashboard-hero-badge,
.sourcing-project-chip, .sourcing-project-status-pill, .sourcing-status-chip,
.sourcing-project-row-pill, .sourcing-workflow-file-chip,
.sourcing-workflow-pending-chip, .sourcing-evidence-status, .status-badge,
.qc-filter-tag, .qc-data-pill, .qc-tech-status-pill, .qc-detail-status-pill,
.requirements-overview-status-pill, .price-payment-pill,
.order-execution-hero-badge, .order-execution-metadata-pill,
.order-execution-project-order-status, .order-execution-invoice-status,
.tab-badge, .notification-count-badge, .translation-badge,
.sourcing-questionnaire-priority, .order-detail-incoterms,
.order-detail-reference-badge, .invoice-detail-status) {
    min-height: 24px;
    display: inline-flex;
    align-items: center;
    gap: 0.32rem;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-surface-muted) !important;
    color: var(--bridge-ink-soft) !important;
    box-shadow: none !important;
    font-size: 0.72rem !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

body.workspace-shell-active :where(.status-badge.success, .status-badge.completed,
.status-badge.approved, .workspace-status-badge.success,
.workspace-dashboard-status--delivered, .sourcing-project-card-stage.is-live,
.sourcing-project-row-pill--live, .order-execution-step.complete,
.order-execution-project-order-status--delivered,
.order-execution-invoice-status--paid, .price-payment-pill.success) {
    background: #dcf6e2 !important;
    border-color: #91dca8 !important;
    color: #17572d !important;
}

body.workspace-shell-active :where(.status-badge.warning, .status-badge.pending,
.workspace-dashboard-status--pending, .sourcing-project-row-pill--brief,
.sourcing-questionnaire-priority.is-should_have, .qc-tech-status-pill.pending,
.price-payment-pill.warning) {
    background: #fff4ce !important;
    border-color: #e7bd42 !important;
    color: #6e4b11 !important;
}

body.workspace-shell-active :where(.status-badge.info, .status-badge.in_progress,
.workspace-dashboard-status--processing, .workspace-dashboard-status--in_transit,
.sourcing-questionnaire-priority.is-nice_to_have, .qc-detail-status-pill,
.order-execution-project-order-status--in_transit) {
    background: #e8fbfc !important;
    border-color: #86d5dc !important;
    color: #205a60 !important;
}

body.workspace-shell-active :where(.status-badge.danger, .status-badge.rejected,
.status-badge.failed, .sourcing-questionnaire-priority.is-must_have,
.price-payment-pill.danger) {
    background: #fde4df !important;
    border-color: #f2a094 !important;
    color: #9f2723 !important;
}

body.workspace-shell-active :where(.status-badge.report, .status-badge.submitted,
.qc-detail-status-pill[style], .invoice-detail-status--issued) {
    background: #f7e5f8 !important;
    border-color: #d593db !important;
    color: #68336e !important;
}

body.workspace-shell-active .qc-table .status-badge.status-draft {
    background: #f1f5f9 !important;
    border-color: #cbd5e1 !important;
    color: #475569 !important;
}

body.workspace-shell-active .qc-table .status-badge.status-ready_to_assign {
    background: #fef3c7 !important;
    border-color: #f2c94c !important;
    color: #92400e !important;
}

body.workspace-shell-active .qc-table .status-badge.status-assigned {
    background: #e0f2fe !important;
    border-color: #7dd3fc !important;
    color: #075985 !important;
}

body.workspace-shell-active .qc-table .status-badge.status-goods_received {
    background: #ccfbf1 !important;
    border-color: #5eead4 !important;
    color: #0f766e !important;
}

body.workspace-shell-active .qc-table .status-badge.status-scheduled {
    background: #dcfce7 !important;
    border-color: #86efac !important;
    color: #166534 !important;
}

body.workspace-shell-active .qc-table .status-badge.status-in_progress {
    background: #fae8ff !important;
    border-color: #e879f9 !important;
    color: #86198f !important;
}

body.workspace-shell-active .qc-table .status-badge.status-report_submitted {
    background: #ede9fe !important;
    border-color: #c4b5fd !important;
    color: #6d28d9 !important;
}

body.workspace-shell-active .qc-table .status-badge.status-approved {
    background: #10b981 !important;
    border-color: #059669 !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-table .status-badge.status-in_transit {
    background: #0f766e !important;
    border-color: #115e59 !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-table .status-badge.status-rejected {
    background: #991b1b !important;
    border-color: #7f1d1d !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-table .status-badge.status-needs_rework {
    background: #ef4444 !important;
    border-color: #dc2626 !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-table .status-badge.status-re_inspection {
    background: #fff7ed !important;
    border-color: #fdba74 !important;
    color: #c2410c !important;
}

body.workspace-shell-active .qc-table .status-badge.status-closed {
    background: #1e293b !important;
    border-color: #0f172a !important;
    color: #ffffff !important;
}

body.workspace-shell-active .qc-table .status-badge.status-pending_payment {
    background: #fff7ed !important;
    border-color: #fdba74 !important;
    color: #c2410c !important;
}

body.workspace-shell-active .qc-table .status-badge.status-paid {
    background: #dcfce7 !important;
    border-color: #86efac !important;
    color: #166534 !important;
}

body.workspace-shell-active .qc-table .qc-tech-status-pill--missing_files {
    background: #fef3c7 !important;
    border-color: #f2c94c !important;
    color: #92400e !important;
}

body.workspace-shell-active .qc-table .qc-tech-status-pill--no {
    background: #fee2e2 !important;
    border-color: #fca5a5 !important;
    color: #991b1b !important;
}

body.workspace-shell-active .qc-table .qc-tech-status-pill--all_yes {
    background: #dcfce7 !important;
    border-color: #86efac !important;
    color: #166534 !important;
}

body.workspace-shell-active .qc-table .qc-tech-status-pill--visual_check_only {
    background: #dbeafe !important;
    border-color: #93c5fd !important;
    color: #1d4ed8 !important;
}

body.workspace-shell-active .qc-table .qc-tech-status-pill--unavailable {
    background: #e2e8f0 !important;
    border-color: #cbd5e1 !important;
    color: #475569 !important;
}

/* Tabs and filters */
body.workspace-shell-active :where(.sourcing-workflow-view-toggle, .spec-chat-tabs,
.sidebar-tabs-horizontal, .qc-folder-switch, .checklist-table-switch,
.dashboard-role-switch) {
    gap: 0.2rem;
    border: 1px solid var(--bridge-line-strong) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-surface) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.sourcing-workflow-view-btn, .spec-chat-tab,
.sidebar-htab, .qc-folder-btn, .checklist-table-switch-btn,
.dashboard-role-btn) {
    border-radius: var(--radius-pill) !important;
    color: var(--bridge-ink) !important;
    font-weight: 650 !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.sourcing-workflow-view-btn.active,
.spec-chat-tab.active, .sidebar-htab.active, .qc-folder-btn.active,
.checklist-table-switch-btn.active, .dashboard-role-btn.active) {
    background: var(--bridge-ink) !important;
    border-color: var(--bridge-ink) !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

body.workspace-shell-active .spec-chat-tabs {
    border-width: 0 0 1px !important;
    border-radius: 0 !important;
    padding: 0 var(--space-4) !important;
}

body.workspace-shell-active .spec-chat-tab {
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active .spec-chat-tab.active {
    background: transparent !important;
    color: var(--bridge-ink) !important;
    box-shadow: inset 0 -3px 0 var(--bridge-ink) !important;
}

body.workspace-shell-active :where(.qc-filter-shell, .qc-dashboard-toolbar,
.sourcing-project-board-toolbar, .sourcing-workflow-topbar) {
    background: var(--bridge-surface) !important;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-card) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.qc-filter-grid, .qc-dashboard-toolbar) {
    gap: var(--space-4) !important;
}

/* Chat and collaboration surfaces */
body.workspace-shell-active :where(#spec-chat-region.chat-pane.telegram-style,
.sourcing-chat-window, .sourcing-chat-thread, .messages-area.telegram-messages,
#ai-messages-area, #supplier-messages-area) {
    background: var(--bridge-surface) !important;
    background-image: none !important;
}

body.workspace-shell-active :where(.sourcing-chat-window-header,
.spec-supplier-sidebar-header, .spec-files-sidebar-header,
#spec-chat-region .pane-header, #spec-chat-region .input-container,
.panel-header, .file-group-head) {
    border-color: var(--bridge-line) !important;
    background: var(--bridge-surface) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .spec-ai-agent-avatar,
body.workspace-shell-active .spec-chat-header-name::before {
    background: var(--bridge-cyan) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.sourcing-chat-bubble,
#spec-chat-region .telegram-message-bubble, .message-bubble) {
    max-width: min(720px, 100%);
    padding: 0.78rem 1rem !important;
    border: 1px solid var(--bridge-line) !important;
    border-radius: 4px 18px 18px 18px !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.sourcing-chat-bubble.buyer,
#spec-chat-region .telegram-message.sent .telegram-message-bubble,
.message-bubble.sent) {
    border-color: var(--bridge-ink) !important;
    border-radius: 18px 18px 4px 18px !important;
    background: var(--bridge-ink) !important;
    color: #ffffff !important;
}

body.workspace-shell-active :where(.sourcing-chat-bubble.assistant,
#spec-chat-region .telegram-message.received .telegram-message-bubble,
.message-bubble.received) {
    background: var(--bridge-surface) !important;
    border-color: var(--bridge-line-strong) !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active #spec-chat-region :where(.telegram-message.bridge-ai .telegram-message-bubble,
.spec-ai-agent.received .telegram-message-bubble,
.message-bubble.bridge-ai) {
    background: #eefafa !important;
    border-color: #74cfd8 !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active :where(.system-msg .telegram-message-bubble,
.sourcing-chat-inline-note, .sourcing-chat-assistant-note,
.signoff-instructions, .spec-ai-chat-actions) {
    background: #fff4ce !important;
    border: 1px solid #e7bd42 !important;
    border-radius: var(--radius-control) var(--radius-arch) var(--radius-control) var(--radius-control) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.chat-file-message-card, .sourcing-workflow-file-chip,
.sourcing-workflow-pending-chip, .attachment-card, .file-item-row) {
    border: 1px solid #8f8ad8 !important;
    border-radius: var(--radius-pill) !important;
    background: #eeedff !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active #spec-files-sidebar .file-item-row {
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body.workspace-shell-active #spec-files-sidebar .file-item-row:hover,
body.workspace-shell-active #spec-files-sidebar .file-item-row:focus-within {
    background: transparent !important;
}

body.workspace-shell-active :where(.chat-file-message-name, .sourcing-workflow-file-chip span,
.file-item-name) {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active :where(
#spec-chat-region .sourcing-chat-assistant-note,
#spec-chat-region .sourcing-chat-bubble.assistant,
.project-workspace-ai-thread .sourcing-chat-assistant-note,
.project-workspace-ai-thread .sourcing-chat-bubble.assistant
) {
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active :where(
#spec-chat-region .sourcing-chat-assistant-note > :first-child,
#spec-chat-region .sourcing-chat-bubble.assistant > :first-child,
.project-workspace-ai-thread .sourcing-chat-assistant-note > :first-child,
.project-workspace-ai-thread .sourcing-chat-bubble.assistant > :first-child
) {
    margin-top: 0 !important;
}

body.workspace-shell-active .spec-three-pane-layout.project-workspace-ai-active :where(
#spec-chat-region .sourcing-chat-assistant-note > :last-child,
#spec-chat-region .sourcing-chat-bubble.assistant > :last-child,
.project-workspace-ai-thread .sourcing-chat-assistant-note > :last-child,
.project-workspace-ai-thread .sourcing-chat-bubble.assistant > :last-child
) {
    margin-bottom: 0 !important;
}

body.workspace-shell-active :where(.sourcing-chat-composer, .sourcing-chat-input-shell,
#spec-chat-region .input-container, .input-wrapper.telegram-input) {
    border: 1px solid var(--bridge-line-strong) !important;
    border-radius: 12px !important;
    background: var(--bridge-surface) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .sourcing-chat-send-btn,
body.workspace-shell-active .input-wrapper.telegram-input .send-btn {
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-ink) !important;
    color: #ffffff !important;
}

body.workspace-shell-active :where(.project-workspace-contact-row,
.contact-panel-item, .invitation-card) {
    border: 0 !important;
    border-bottom: 1px solid var(--bridge-line) !important;
    border-radius: 0 !important;
    background: var(--bridge-surface) !important;
    box-shadow: none !important;
}

body.workspace-shell-active :where(.project-workspace-contact-row.active,
.contact-panel-item.active, .project-workspace-contact-row.is-ai.active,
.project-workspace-contact-row.is-supplier.active) {
    background: #eefafa !important;
    border-bottom-color: var(--bridge-line) !important;
    box-shadow: inset 4px 0 0 var(--bridge-ink) !important;
    color: var(--bridge-ink) !important;
}

/* Dashboard */
body.workspace-shell-active .workspace-dashboard-shell {
    gap: var(--space-5) !important;
}

body.workspace-shell-active .workspace-dashboard-header h1 {
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .workspace-dashboard-hero-cta {
    min-height: clamp(12rem, 24vh, 15rem) !important;
    display: grid !important;
    align-items: stretch;
    padding: clamp(1.4rem, 3vw, 2rem) !important;
    overflow: hidden;
    border: 1px solid var(--bridge-line-strong) !important;
    border-radius: var(--radius-card) var(--radius-arch) var(--radius-card) var(--radius-card) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .workspace-dashboard-hero-cta-backdrop {
    inset: clamp(1rem, 2.4vw, 1.6rem) clamp(1rem, 2.4vw, 1.6rem) clamp(1rem, 2.4vw, 1.6rem) auto !important;
    width: min(34%, 360px);
    min-width: 260px;
    border: 1px solid var(--bridge-line-strong);
    background:
        linear-gradient(var(--bridge-yellow) 0 0) 0 0 / 50% 45% no-repeat,
        linear-gradient(var(--bridge-lilac) 0 0) 50% 0 / 50% 45% no-repeat,
        repeating-linear-gradient(45deg, transparent 0 10px, #747b86 10px 16px) 0 45% / 50% 55% no-repeat,
        linear-gradient(var(--bridge-mint) 0 0) 50% 45% / 50% 55% no-repeat,
        var(--bridge-surface);
    opacity: 1;
}

body.workspace-shell-active .workspace-dashboard-hero-cta-backdrop::before {
    content: "";
    position: absolute;
    right: 10%;
    bottom: 10%;
    width: 34%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: var(--bridge-periwinkle);
}

body.workspace-shell-active .workspace-dashboard-hero-cta-backdrop::after {
    content: "";
    position: absolute;
    left: 48%;
    bottom: 0;
    width: 28%;
    aspect-ratio: 1;
    border-radius: var(--radius-pill) var(--radius-pill) 0 0;
    background: var(--bridge-cyan);
}

body.workspace-shell-active .workspace-dashboard-hero-cta-content {
    width: min(60%, 760px);
    height: auto !important;
    align-items: flex-start !important;
    justify-content: center !important;
    gap: var(--space-3) !important;
    text-align: left !important;
}

body.workspace-shell-active .workspace-dashboard-hero-icon {
    width: 42px !important;
    height: 42px !important;
    border-radius: var(--radius-control) var(--radius-arch) var(--radius-control) var(--radius-control) !important;
    background: var(--bridge-mint) !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .workspace-dashboard-hero-title {
    color: var(--bridge-ink) !important;
    font-size: clamp(2.05rem, 4vw, 3.2rem) !important;
    font-weight: 560 !important;
    letter-spacing: -0.02em !important;
}

body.workspace-shell-active .workspace-dashboard-hero-badge {
    margin-top: var(--space-2) !important;
    background: #fff4ce !important;
    border-color: #e7bd42 !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .workspace-dashboard-task-card {
    padding: 1rem !important;
}

body.workspace-shell-active .workspace-dashboard-task-icon-wrap {
    width: 42px !important;
    height: 42px !important;
    border-radius: var(--radius-control) !important;
    background: var(--bridge-yellow) !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .workspace-dashboard-task-copy h4,
body.workspace-shell-active .workspace-dashboard-order-reference,
body.workspace-shell-active .workspace-dashboard-invoice-copy strong,
body.workspace-shell-active .workspace-dashboard-invoice-total {
    color: var(--bridge-ink) !important;
    font-weight: 650 !important;
}

body.workspace-shell-active :where(.workspace-dashboard-task-copy p,
.workspace-dashboard-task-meta, .workspace-dashboard-order-supplier,
.workspace-dashboard-invoice-copy span, .workspace-dashboard-invoice-meta) {
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active .workspace-dashboard-progress {
    background: var(--bridge-surface-muted) !important;
}

body.workspace-shell-active .workspace-dashboard-progress span {
    background: var(--bridge-mint) !important;
}

/* Sourcing and questionnaire workspace */
body.workspace-shell-active :where(.sourcing-overview-hero, .sourcing-project-hero,
.order-execution-hero) {
    border-left: 0 !important;
    border-top: 4px solid var(--bridge-ink) !important;
}

body.workspace-shell-active .sourcing-overview-hero {
    border-top-color: var(--bridge-mint) !important;
}

body.workspace-shell-active .order-execution-hero {
    border-top-color: var(--bridge-periwinkle) !important;
}

body.workspace-shell-active .qc-dashboard-shell > .section-header {
    border-top: 4px solid var(--bridge-orange) !important;
}

body.workspace-shell-active .sourcing-project-board-search,
body.workspace-shell-active .sourcing-project-board-sort {
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-control) !important;
    background: var(--bridge-surface) !important;
    box-shadow: none !important;
}

body.workspace-shell-active .sourcing-project-row {
    grid-template-columns: 48px minmax(0, 1fr) auto !important;
}

body.workspace-shell-active .sourcing-project-row-title,
body.workspace-shell-active .sourcing-project-card-title {
    color: var(--bridge-ink) !important;
    font-weight: 650 !important;
}

body.workspace-shell-active :where(.project-workspace-questionnaire-card,
.merged-questionnaire-checklist.sourcing-questionnaire-card) {
    background: var(--bridge-surface) !important;
}

body.workspace-shell-active .checklist-context-button-group {
    gap: var(--space-2) !important;
}

/* QC list and detail */
body.workspace-shell-active .qc-dashboard-shell {
    gap: var(--space-4) !important;
}

body.workspace-shell-active .qc-dashboard-shell > .section-header {
    margin-bottom: 0 !important;
    padding: clamp(1rem, 2vw, 1.4rem) !important;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
}

body.workspace-shell-active .qc-dashboard-shell > .section-header h2 {
    display: inline-flex;
    align-items: center;
    gap: var(--space-3);
}

body.workspace-shell-active .qc-dashboard-shell > .section-header h2 i {
    width: 42px;
    height: 42px;
    display: inline-grid;
    place-items: center;
    border-radius: var(--radius-control) var(--radius-arch) var(--radius-control) var(--radius-control);
    background: var(--bridge-mint);
    color: var(--bridge-ink);
}

body.workspace-shell-active .qc-table-shell {
    overflow-x: auto !important;
}

body.workspace-shell-active .qc-table th,
body.workspace-shell-active .qc-table td {
    padding: 0.72rem 0.78rem !important;
}

body.workspace-shell-active .qc-sort-header:hover,
body.workspace-shell-active .qc-sort-header:focus-visible,
body.workspace-shell-active .qc-sort-icons i.active,
body.workspace-shell-active .qc-sort-header.active {
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .qc-compact-line i,
body.workspace-shell-active :where(.inspector-cell i, .date-cell i, .deadline-cell i) {
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active .qc-detail-hero {
    min-height: 0 !important;
    grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.85fr) !important;
    align-items: stretch !important;
    margin-bottom: var(--space-5) !important;
    border-top: 4px solid var(--bridge-lilac) !important;
}

body.workspace-shell-active .qc-detail-hero-side {
    justify-content: space-between;
    padding-left: var(--space-4);
    border-left: 1px solid var(--bridge-line);
}

body.workspace-shell-active .qc-detail-meta-row {
    border-top: 1px solid var(--bridge-line);
    padding-top: var(--space-3);
}

body.workspace-shell-active .qc-report-card {
    border-top: 4px solid var(--bridge-mint) !important;
    background: #f1fbf3 !important;
}

body.workspace-shell-active .qc-report-card-title-row::before {
    content: "";
    width: 22px;
    height: 22px;
    border-radius: 50% 50% 0 50%;
    background: var(--bridge-mint);
    flex: 0 0 auto;
}

body.workspace-shell-active .qc-report-result {
    color: #17572d !important;
    font-weight: 700 !important;
}

body.workspace-shell-active .qc-report-comment-box,
body.workspace-shell-active .qc-comment-entry {
    background: var(--bridge-surface) !important;
    border-color: var(--bridge-line) !important;
    border-radius: var(--radius-control) !important;
}

body.workspace-shell-active .audit-trail-container {
    margin-top: var(--space-3) !important;
    padding: var(--space-4) var(--space-2) !important;
    overflow-x: hidden !important;
    overflow-y: visible !important;
}

body.workspace-shell-active .audit-trail-horizontal {
    flex-wrap: wrap !important;
    gap: 1.35rem 0 !important;
    min-width: 0 !important;
    overflow: visible !important;
    padding: 0.2rem 0 0 !important;
}

body.workspace-shell-active .audit-trail-horizontal::before {
    display: none !important;
}

body.workspace-shell-active .audit-trail-item {
    flex: 1 1 9.25rem !important;
    min-width: 7.75rem !important;
    max-width: 10.75rem !important;
    padding: 0 0.35rem 1rem !important;
}

body.workspace-shell-active .audit-trail-item::before {
    content: '' !important;
    position: absolute !important;
    top: 10px !important;
    left: 0 !important;
    right: 0 !important;
    height: 2px !important;
    background: var(--bridge-ink) !important;
    z-index: 0 !important;
}

body.workspace-shell-active .audit-trail-vertical .audit-trail-item::before {
    display: none !important;
}

body.workspace-shell-active .audit-trail-dot {
    width: 20px !important;
    height: 20px !important;
    border: 2px solid var(--bridge-surface) !important;
    border-radius: 50% !important;
    background: var(--bridge-surface-muted) !important;
    box-shadow: 0 0 0 1px var(--bridge-line-strong) !important;
}

body.workspace-shell-active .audit-trail-item.finished .audit-trail-dot {
    background: var(--bridge-mint) !important;
}

body.workspace-shell-active .audit-trail-item.current .audit-trail-dot {
    background: var(--bridge-ink) !important;
    box-shadow: 0 0 0 4px rgba(255, 146, 56, 0.32) !important;
    transform: none !important;
}

body.workspace-shell-active .audit-trail-horizontal .audit-trail-item strong {
    height: auto !important;
    color: var(--bridge-ink) !important;
    font-size: 0.76rem !important;
    font-weight: 650 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

body.workspace-shell-active .audit-trail-timestamp,
body.workspace-shell-active .audit-trail-scheduled {
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active .audit-trail-note {
    background: #fff4ce !important;
    border: 1px solid #e7bd42 !important;
    border-radius: var(--radius-control) !important;
    color: var(--bridge-ink) !important;
    font-style: normal !important;
}

body.workspace-shell-active .audit-trail-item:hover .audit-trail-note,
body.workspace-shell-active .audit-trail-info-box:hover .audit-trail-note {
    background: #fffaf0 !important;
    box-shadow: var(--bridge-ui-shadow-float) !important;
}

/* Order execution */
body.workspace-shell-active .order-execution-status-track {
    gap: 0 !important;
    border: 1px solid var(--bridge-line-strong);
    border-radius: var(--radius-control);
    overflow: hidden;
    background: var(--bridge-surface);
}

body.workspace-shell-active .order-execution-step {
    min-height: 64px !important;
    border: 0 !important;
    border-right: 1px solid var(--bridge-line) !important;
    border-radius: 0 !important;
    background: var(--bridge-surface-muted) !important;
    color: var(--bridge-ink-soft) !important;
}

body.workspace-shell-active .order-execution-step.current {
    background: var(--bridge-periwinkle) !important;
    color: var(--bridge-ink) !important;
}

body.workspace-shell-active .order-execution-step.complete {
    background: var(--bridge-mint) !important;
    color: #173f26 !important;
}

body.workspace-shell-active .order-detail-shell {
    color: var(--bridge-ink-soft);
}

body.workspace-shell-active .order-detail-meta-row {
    padding: clamp(1rem, 2vw, 1.5rem) !important;
    border-top: 4px solid var(--bridge-periwinkle) !important;
}

body.workspace-shell-active .order-detail-grand-total {
    color: var(--bridge-ink) !important;
    font-weight: 650 !important;
}

body.workspace-shell-active .order-detail-progress-segment.is-complete {
    background: var(--bridge-mint) !important;
}

body.workspace-shell-active .order-detail-progress-segment.is-current {
    background: var(--bridge-periwinkle) !important;
}

body.workspace-shell-active .order-detail-progress-segment.is-pending {
    background: var(--bridge-surface-muted) !important;
}

body.workspace-shell-active .order-detail-payment-btn {
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-control) !important;
    box-shadow: none !important;
}

/* Authenticated settings page, which uses the public header rather than the workspace shell. */
#settings-view {
    --bridge-canvas: #f4f4ef;
    --bridge-surface: #ffffff;
    --bridge-surface-muted: #eeeeea;
    --bridge-ink: #111111;
    --bridge-ink-soft: #555852;
    --bridge-line: #c7c8c1;
    --bridge-line-strong: #181818;
    --bridge-cyan: #a9e5ea;
    --bridge-mint: #87e3a0;
    --bridge-yellow: #f4cb50;
    --bridge-lilac: #dfa9e4;
    --bridge-danger: #d9433f;
    --radius-control: 8px;
    --radius-card: 10px;
    --radius-pill: 999px;
    background: var(--bridge-canvas);
    color: var(--bridge-ink-soft);
}

#settings-view .settings-section {
    background: var(--bridge-canvas);
}

#settings-view :where(.section-title, .settings-card h3, .settings-item-title) {
    color: var(--bridge-ink) !important;
    font-weight: 600 !important;
    letter-spacing: 0 !important;
}

#settings-view .section-description,
#settings-view :where(.settings-item-desc, .settings-role-helper, .form-hint) {
    color: var(--bridge-ink-soft) !important;
}

#settings-view :where(.settings-card, .settings-item, .business-card-preview,
.greeting-preview-bubble, .settings-rollout-note) {
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-card) !important;
    background: var(--bridge-surface) !important;
    box-shadow: none !important;
}

#settings-view :where(.btn-primary, .submit-btn) {
    min-height: 44px !important;
    border: 1px solid var(--bridge-ink) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-ink) !important;
    color: #ffffff !important;
    box-shadow: none !important;
    font-weight: 650 !important;
}

#settings-view :where(.btn-outline, .btn-secondary, .dashboard-role-btn) {
    min-height: 40px !important;
    border: 1px solid var(--bridge-line-strong) !important;
    border-radius: var(--radius-pill) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
    font-weight: 650 !important;
}

#settings-view .dashboard-role-btn.active {
    background: var(--bridge-ink) !important;
    border-color: var(--bridge-ink) !important;
    color: #ffffff !important;
}

#settings-view :where(input, textarea, select) {
    min-height: 42px;
    border: 1px solid var(--bridge-line) !important;
    border-radius: var(--radius-control) !important;
    background: var(--bridge-surface) !important;
    color: var(--bridge-ink) !important;
    box-shadow: none !important;
}

#settings-view :where(input, textarea, select):focus {
    border-color: var(--bridge-line-strong) !important;
    box-shadow: 0 0 0 3px rgba(169, 229, 234, 0.82) !important;
}

/* Responsive guardrails for the Bauhaus layer */
@media (max-width: 1100px) {
    body.workspace-shell-active .workspace-dashboard-hero-cta-content {
        width: min(68%, 720px);
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta-backdrop {
        width: min(30%, 300px);
        min-width: 220px;
    }

    body.workspace-shell-active .qc-detail-hero {
        grid-template-columns: 1fr !important;
    }

    body.workspace-shell-active .qc-detail-hero-side {
        padding-left: 0;
        border-left: 0;
        border-top: 1px solid var(--bridge-line);
        padding-top: var(--space-4);
    }
}

@media (max-width: 900px) {
    body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .workflow-steps-group {
        border-radius: var(--radius-control);
        overflow-x: auto;
        max-width: 100%;
    }

    body.workspace-shell-active .dashboard-sidebar.dashboard-topbar .sidebar-btn.workflow-step {
        min-width: max-content;
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta {
        min-height: 13rem !important;
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta-content {
        width: 100%;
        padding-right: min(34vw, 220px);
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta-backdrop {
        width: min(30vw, 210px);
        min-width: 170px;
    }
}

@media (max-width: 720px) {
    body.workspace-shell-active :where(.workspace-home-shell, .sourcing-overview-shell,
    .sourcing-project-board-shell, .order-execution-shell, .qc-dashboard-shell,
    .conversation-dashboard-shell, .conversations-shell) {
        max-width: 100% !important;
    }

    body.workspace-shell-active .dashboard-main-panel {
        padding: 1rem !important;
    }

    body.workspace-shell-active :where(.workspace-hero, .workspace-card,
    .sourcing-overview-hero, .sourcing-projects-board, .sourcing-project-hero,
    .order-execution-hero, .qc-dashboard-shell > .section-header,
    .qc-filter-shell, .qc-dashboard-toolbar) {
        padding: 1rem !important;
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta {
        min-height: 0 !important;
        padding: 1.2rem !important;
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta-content {
        width: 100%;
        padding-right: 0;
    }

    body.workspace-shell-active .workspace-dashboard-hero-cta-backdrop {
        position: relative !important;
        inset: auto !important;
        order: 2;
        width: 100%;
        min-width: 0;
        height: 120px;
        margin-top: 1rem;
    }

    body.workspace-shell-active .workspace-dashboard-hero-title {
        font-size: clamp(1.75rem, 9vw, 2.35rem) !important;
    }

    body.workspace-shell-active .sourcing-project-row {
        grid-template-columns: 42px minmax(0, 1fr) !important;
    }

    body.workspace-shell-active :where(.sourcing-project-row-status,
    .sourcing-project-row-summary, .sourcing-project-row-action) {
        grid-column: 1 / -1;
    }

    body.workspace-shell-active .qc-dashboard-shell > .section-header {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* Landing-page polish: keep the public header readable, constrain auth controls,
   and make the savings benchmark section less cramped without touching authenticated workspace UI. */
body:not(.workspace-shell-active) .main-header {
    --bridge-public-header-gap: clamp(0.5rem, 1.15vw, 1.1rem);
    --bridge-public-user-profile-max: clamp(10.75rem, 19vw, 15.5rem);
    --bridge-public-user-name-max: clamp(4.8rem, 9.5vw, 8.25rem);
}

body:not(.workspace-shell-active) .main-header nav,
body:not(.workspace-shell-active) .nav-main-links,
body:not(.workspace-shell-active) .nav-action-group,
body:not(.workspace-shell-active) #auth-controls,
body:not(.workspace-shell-active) .user-profile,
body:not(.workspace-shell-active) .user-info-text {
    min-width: 0;
    flex-wrap: nowrap;
    white-space: nowrap;
}

body:not(.workspace-shell-active) .main-header nav {
    flex: 1 1 auto;
}

body:not(.workspace-shell-active) .nav-main-links {
    flex: 0 1 auto;
}

body:not(.workspace-shell-active) .nav-action-group {
    flex: 1 1 auto;
    justify-content: flex-end;
}

body:not(.workspace-shell-active) .nav-main-links,
body:not(.workspace-shell-active) .nav-action-group {
    gap: var(--bridge-public-header-gap);
}

body:not(.workspace-shell-active) .nav-btn,
body:not(.workspace-shell-active) .lang-btn,
body:not(.workspace-shell-active) .nav-dash-btn,
body:not(.workspace-shell-active) .login-btn {
    white-space: nowrap;
    word-break: keep-all;
    overflow-wrap: normal;
    flex: 0 0 auto;
}

body:not(.workspace-shell-active) #auth-controls {
    display: flex;
    flex: 0 1 var(--bridge-public-user-profile-max);
    justify-content: flex-end;
    min-width: 0;
}

body:not(.workspace-shell-active) .user-profile {
    flex: 0 1 var(--bridge-public-user-profile-max);
    max-width: var(--bridge-public-user-profile-max);
    min-height: 44px;
    gap: clamp(0.42rem, 0.7vw, 0.58rem);
    overflow: hidden;
    padding: 0.28rem 0.52rem 0.28rem 0.72rem;
}

body:not(.workspace-shell-active) .user-info-text {
    align-items: flex-end;
    flex: 1 1 var(--bridge-public-user-name-max);
    gap: 0.08rem;
    max-width: var(--bridge-public-user-name-max);
    margin-right: 0;
}

body:not(.workspace-shell-active) .role-badge-small,
body:not(.workspace-shell-active) #username-display,
body:not(.workspace-shell-active) #role-display {
    white-space: nowrap;
    word-break: keep-all;
    overflow-wrap: normal;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

body:not(.workspace-shell-active) #username-display {
    display: block;
    width: 100%;
    line-height: 1.08;
    text-align: right;
}

body:not(.workspace-shell-active) #role-display {
    display: block;
    min-height: 18px;
    padding: 0.08rem 0.34rem;
    font-size: 0.62rem;
    line-height: 1;
    text-align: center;
}

body:not(.workspace-shell-active) .user-profile img {
    flex: 0 0 38px;
    width: 38px;
    height: 38px;
}

body:not(.workspace-shell-active) .logout-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 28px;
    width: 28px;
    padding: 0;
}

body:not(.workspace-shell-active) .lang-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-width: 38px;
}

body:not(.workspace-shell-active) .lang-btn[data-lang="zh"] {
    min-width: 54px;
}

body:not(.workspace-shell-active) .nav-dash-btn {
    padding-inline: clamp(1rem, 1.6vw, 1.35rem);
}

body:not(.workspace-shell-active) .lang-switcher {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-width: max-content;
    overflow: visible;
}

#home-view.public-landing-shell .sourcing-savings-section {
    grid-template-columns: minmax(520px, 1fr) minmax(420px, 1fr);
    gap: clamp(2rem, 5vw, 5.25rem);
    align-items: center;
}

#home-view.public-landing-shell .sourcing-savings-copy {
    max-width: 680px;
}

#home-view.public-landing-shell .sourcing-savings-copy h2 {
    max-width: 15ch;
    font-size: clamp(2.6rem, 4.2vw, 3.85rem);
    line-height: 1.02;
}

#home-view.public-landing-shell .sourcing-savings-copy p {
    max-width: 46ch;
    margin-bottom: 0;
}

#home-view.public-landing-shell .sourcing-savings-search {
    width: min(100%, 660px);
    justify-self: end;
}

html[lang="de"] body:not(.workspace-shell-active) .main-header {
    --bridge-public-header-gap: clamp(0.35rem, 0.75vw, 0.68rem);
    --bridge-public-user-profile-max: clamp(10rem, 16vw, 13.2rem);
    --bridge-public-user-name-max: clamp(4.6rem, 7vw, 6.25rem);
    padding-inline: clamp(0.9rem, 1.8vw, 1.55rem);
}

html[lang="de"] body:not(.workspace-shell-active) .main-header nav {
    gap: clamp(0.45rem, 0.9vw, 0.8rem);
    margin-left: clamp(0.85rem, 1.45vw, 1.35rem);
}

html[lang="de"] body:not(.workspace-shell-active) .nav-main-links,
html[lang="de"] body:not(.workspace-shell-active) .nav-action-group {
    gap: clamp(0.35rem, 0.75vw, 0.68rem);
}

html[lang="de"] body:not(.workspace-shell-active) .nav-btn {
    padding-inline: clamp(0.38rem, 0.65vw, 0.55rem);
    font-size: clamp(0.7rem, 0.82vw, 0.76rem);
}

html[lang="de"] body:not(.workspace-shell-active) .nav-dash-btn,
html[lang="de"] body:not(.workspace-shell-active) .login-btn {
    padding-inline: clamp(0.8rem, 1.2vw, 1.05rem);
    font-size: clamp(0.7rem, 0.82vw, 0.76rem);
}

html[lang="de"] body:not(.workspace-shell-active) .lang-switcher {
    flex: 0 0 auto;
}

html[lang="de"] body:not(.workspace-shell-active) .lang-btn {
    min-width: 32px;
    padding-inline: 0.38rem;
}

html[lang="de"] body:not(.workspace-shell-active) .lang-btn[data-lang="zh"] {
    min-width: 50px;
}

html[lang="de"] #home-view.public-landing-shell .hero-title.large-left {
    max-width: 15.2ch;
    font-size: clamp(3rem, 6.7vw, 5.55rem);
    line-height: 1.02;
    overflow-wrap: normal;
    word-break: keep-all;
    hyphens: none;
}

html[lang="de"] #home-view.public-landing-shell .public-landing-hero-subtitle {
    max-width: 54ch;
}

@media (max-width: 1160px) {
    body:not(.workspace-shell-active) .main-header {
        padding-inline: clamp(0.85rem, 2vw, 1.5rem);
    }

    body:not(.workspace-shell-active) .main-header nav {
        margin-left: clamp(0.75rem, 1.6vw, 1.5rem);
    }

    body:not(.workspace-shell-active) .nav-btn,
    body:not(.workspace-shell-active) .nav-dash-btn,
    body:not(.workspace-shell-active) .login-btn {
        font-size: 0.74rem;
    }

    #home-view.public-landing-shell .sourcing-savings-section {
        grid-template-columns: minmax(420px, 0.95fr) minmax(360px, 1.05fr);
        gap: clamp(1.5rem, 4vw, 3.5rem);
    }
}

@media (max-width: 860px) {
    #home-view.public-landing-shell .sourcing-savings-section {
        grid-template-columns: 1fr;
    }

    #home-view.public-landing-shell .sourcing-savings-copy,
    #home-view.public-landing-shell .sourcing-savings-copy h2,
    #home-view.public-landing-shell .sourcing-savings-search {
        max-width: none;
        width: 100%;
        justify-self: stretch;
    }
}

/* Nested controls: the parent shell, table cell, or composer owns the visible
   border. Inputs/selects inside those containers stay boundaryless. */
body.workspace-shell-active :where(
.sourcing-project-board-search input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-project-board-sort select,
.sourcing-chat-input-shell :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.chat-input-area .input-wrapper :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.input-wrapper.telegram-input :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.spec-conversation-proxy-field :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-questionnaire-answer :where(input, textarea, select, .sourcing-questionnaire-field, .merged-checklist-answer-input):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-questionnaire-cell :where(input, textarea, select, .sourcing-questionnaire-field, .merged-checklist-answer-input):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.req-select-wrapper :where(.req-select, .req-textarea, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.checklist-table td :where(.req-select, .req-textarea, .merged-checklist-answer-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.price-payment-table td :where(.price-payment-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.price-payment-installment-table td :where(.price-payment-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.price-payment-summary-table td :where(.price-payment-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"])
) {
    border-color: transparent !important;
    background: transparent !important;
    box-shadow: none !important;
    outline: none !important;
}

body.workspace-shell-active :where(
.sourcing-project-board-search input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-project-board-sort select,
.sourcing-chat-input-shell :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.chat-input-area .input-wrapper :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.input-wrapper.telegram-input :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.spec-conversation-proxy-field :where(input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-questionnaire-answer :where(input, textarea, select, .sourcing-questionnaire-field, .merged-checklist-answer-input):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.sourcing-questionnaire-cell :where(input, textarea, select, .sourcing-questionnaire-field, .merged-checklist-answer-input):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.req-select-wrapper :where(.req-select, .req-textarea, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.checklist-table td :where(.req-select, .req-textarea, .merged-checklist-answer-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.price-payment-table td :where(.price-payment-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.price-payment-installment-table td :where(.price-payment-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"]),
.price-payment-summary-table td :where(.price-payment-input, input, textarea, select):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="hidden"])
):focus {
    border-color: transparent !important;
    box-shadow: none !important;
    outline: none !important;
}

body.workspace-shell-active :where(.sourcing-project-board-search, .sourcing-project-board-sort,
.sourcing-chat-input-shell, .chat-input-area .input-wrapper, .input-wrapper.telegram-input,
.spec-conversation-proxy-field, .req-select-wrapper):focus-within {
    border-color: var(--bridge-line-strong) !important;
    box-shadow: var(--bridge-ui-focus) !important;
}

body.workspace-shell-active :where(.sourcing-questionnaire-answer, .sourcing-questionnaire-cell,
.checklist-table td, .price-payment-table td, .price-payment-installment-table td,
.price-payment-summary-table td):focus-within {
    box-shadow: inset 0 0 0 2px rgba(169, 229, 234, 0.82) !important;
}

body.workspace-shell-active .qc-table .qc-col-actions {
    width: 22% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings.qc-table--has-actions .qc-col-status {
    width: 11% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings.qc-table--has-actions .qc-col-order {
    width: 19% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings.qc-table--has-actions .qc-col-people {
    width: 17% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings.qc-table--has-actions .qc-col-schedule {
    width: 18% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings.qc-table--has-actions .qc-col-actions {
    width: 22% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings.qc-table--has-actions .qc-col-earnings {
    width: 13% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings:not(.qc-table--has-actions) .qc-col-status {
    width: 13% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings:not(.qc-table--has-actions) .qc-col-order {
    width: 24% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings:not(.qc-table--has-actions) .qc-col-people {
    width: 22% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings:not(.qc-table--has-actions) .qc-col-schedule {
    width: 25% !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings:not(.qc-table--has-actions) .qc-col-earnings {
    width: 16% !important;
}

body.workspace-shell-active .qc-table-shell {
    overflow-x: hidden !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings th,
body.workspace-shell-active .qc-table.qc-table--has-earnings td {
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
}

body.workspace-shell-active .qc-table.qc-table--has-earnings .qc-earnings-cell {
    padding-left: 0.34rem !important;
    padding-right: 0.34rem !important;
}

body.workspace-shell-active .qc-table .qc-actions-cell {
    min-width: 0 !important;
    padding-right: 0.42rem !important;
    padding-left: 0.42rem !important;
    white-space: nowrap !important;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    flex-wrap: nowrap !important;
    justify-content: flex-end;
    gap: 0.22rem !important;
    overflow: hidden;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar > * {
    flex: 0 1 auto !important;
    min-width: 0 !important;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar :where(.btn-outline,
.qc-row-action-btn, .qc-file-preview-action) {
    min-height: 30px !important;
    height: 30px !important;
    padding: 0.2rem 0.36rem !important;
    font-size: 0.72rem !important;
    gap: 0.24rem !important;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar .qc-file-preview-action {
    min-width: 46px !important;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar .qc-row-action-btn--collaborators {
    max-width: 128px !important;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar .qc-row-action-btn:not(.qc-row-action-btn--collaborators):not(.qc-row-action-btn--danger) {
    max-width: 76px !important;
}

body.workspace-shell-active .qc-table .qc-actions-toolbar .qc-row-action-btn--danger {
    flex: 0 0 30px !important;
    width: 30px !important;
    min-width: 30px !important;
    height: 30px !important;
    min-height: 30px !important;
    border-radius: 8px !important;
}

body.workspace-shell-active .qc-table .qc-earnings-editor {
    grid-template-columns: minmax(0, 1fr) 3.35rem;
    gap: 0.22rem;
    max-width: 100%;
}

body.workspace-shell-active .qc-table .qc-earnings-editor input,
body.workspace-shell-active .qc-table .qc-earnings-editor select {
    height: 30px;
    border-radius: 7px;
    font-size: 0.72rem;
}

body.workspace-shell-active .qc-table .qc-earnings-editor input {
    padding: 0.18rem 0.3rem;
}

body.workspace-shell-active .qc-table .qc-earnings-editor select {
    padding: 0.18rem 0.12rem;
}

body.workspace-shell-active .qc-table .qc-earnings-readonly {
    font-size: 0.8rem;
}

body.workspace-shell-active .qc-table .qc-earnings-readonly span {
    font-size: 0.7rem;
}
