@charset "UTF-8";

html {
    user-select: none;
}

input[type="text"]:focus {
    outline: none;
    box-shadow: none;
    border-color: transparent;
}

input::placeholder {
    opacity: 0.5;
}

:root {
    --navy: #0a2540;
    --navy-dark: #061a2e;
    --navy-deep: #04101f;
    --navy-light: #163a5f;
    --teal: #14b8a6;
    --teal-light: #5eead4;
    --coral: #f97066;
    --gold: #f59e0b;
    --green: #10b981;
    --purple: #a78bfa;
    --text: #f1f5f9;
    --text-2: #cbd5e1;
    --text-3: #94a3b8;
    --text-4: #64748b;
    --border: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.14);
    --body: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --display: Georgia, "Times New Roman", serif;
    --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    color-scheme: dark;
    font-family: var(--body);
    background: var(--navy-dark);
}

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

body {
    min-width: 1120px;
    background: var(--navy-dark);
    color: var(--text);
    font-family: var(--body);
    font-size: 14px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(440px, 0.9fr) minmax(560px, 1.1fr);
    overflow: hidden;
    perspective: 1200px;
    background:
        linear-gradient(145deg, rgba(20, 184, 166, 0.09), transparent 38%),
        linear-gradient(320deg, rgba(249, 112, 102, 0.07), transparent 42%),
        var(--navy-deep);
}

.login-shell--exit {
    pointer-events: none;
    transform-origin: left center;
    animation: loginShellFoldExit 680ms cubic-bezier(0.65, 0, 0.35, 1) forwards;
}

.login-shell--exit .login-brand-panel {
    transform-origin: left center;
    backface-visibility: hidden;
    animation: loginBrandFoldExit 680ms cubic-bezier(0.65, 0, 0.35, 1) forwards;
}

.login-shell--exit .login-form-panel {
    animation: loginFormSlideExit 520ms cubic-bezier(0.65, 0, 0.35, 1) forwards;
}

.login-shell--exit .brand-mark,
.login-shell--exit .login-copy,
.login-shell--exit .login-booost-logo,
.login-shell--exit .login-card {
    animation: loginElementFadeExit 360ms ease forwards;
}

@keyframes loginShellFoldExit {
    0% {
        opacity: 1;
        clip-path: inset(0 0 0 0);
        transform: translateX(0) scaleX(1);
    }
    58% {
        opacity: 0.8;
    }
    100% {
        opacity: 0;
        clip-path: inset(0 100% 0 0);
        transform: translateX(-28px) scaleX(0.92);
    }
}

@keyframes loginBrandFoldExit {
    0% {
        opacity: 1;
        transform: rotateY(0deg) scaleX(1);
    }
    100% {
        opacity: 0.18;
        transform: rotateY(72deg) scaleX(0.72);
    }
}

@keyframes loginFormSlideExit {
    0% {
        opacity: 1;
        transform: translateX(0);
    }
    100% {
        opacity: 0;
        transform: translateX(-44px);
    }
}

@keyframes loginElementFadeExit {
    0% {
        opacity: 1;
        transform: translateY(0);
    }
    100% {
        opacity: 0;
        transform: translateY(-8px);
    }
}

.login-brand-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 42px;
    border-right: 1px solid var(--border);
    background: linear-gradient(180deg, rgba(4, 16, 31, 0.95), rgba(6, 26, 46, 0.82));
}

.brand-mark {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo {
    width: 34px;
    height: 34px;
    display: block;
    object-fit: contain;
}

.brand-name {
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.2px;
}

.brand-sub {
    margin-top: 4px;
    color: var(--teal);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1.6px;
    text-transform: uppercase;
}

.booost-logo {
    display: block;
    width: 80px;
    height: auto;
    object-fit: contain;
}

.login-booost-logo {
    position: absolute;
    left: 42px;
    bottom: 42px;
}

.login-copy {
    margin: auto 0;
    max-width: 440px;
}

.login-eyebrow {
    color: var(--teal);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 2.3px;
    text-transform: uppercase;
}

.login-title {
    margin-top: 14px;
    color: #fff;
    font-family: var(--display);
    font-size: 44px;
    font-weight: 500;
    letter-spacing: 0;
    line-height: 1.08;
}

.login-title em {
    color: var(--teal-light);
    font-style: italic;
    font-weight: 400;
}

.login-text {
    margin-top: 16px;
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.75;
}

.login-form-panel {
    display: grid;
    align-items: center;
    padding: 42px min(8vw, 96px);
}

.login-card {
    width: min(100%, 440px);
}

.login-card h1 {
    color: #fff;
    font-family: var(--display);
    font-size: 26px;
    font-weight: 500;
}

.login-card p {
    margin-top: 8px;
    color: var(--text-3);
    font-size: 13px;
    line-height: 1.65;
}

.login-form {
    display: grid;
    gap: 16px;
    margin-top: 26px;
}

.message {
    min-height: 22px;
    color: var(--coral);
    font-size: 12px;
    line-height: 1.5;
}

.message.info {
    color: var(--gold);
}

vaadin-text-field,
vaadin-password-field {
    width: 100%;
    --vaadin-input-field-background: rgba(255, 255, 255, 0.035);
    --vaadin-input-field-border-width: 1px;
    --vaadin-input-field-border-color: var(--border);
    --vaadin-input-field-hover-highlight: rgba(20, 184, 166, 0.14);
    --vaadin-input-field-value-color: var(--text);
    --vaadin-input-field-label-color: var(--text-3);
    --vaadin-input-field-helper-color: var(--text-4);
    --vaadin-focus-ring-color: var(--teal);
    --lumo-primary-text-color: var(--teal-light);
    --lumo-body-text-color: var(--text);
    --lumo-secondary-text-color: var(--text-3);
    --lumo-tertiary-text-color: var(--text-4);
}

vaadin-text-field::part(input-field),
vaadin-password-field::part(input-field) {
    --vaadin-input-field-placeholder-color: rgba(255, 255, 255, 0.5);
}

/*
 * Edgeではprefixスロットのvaadin-iconがLumo既定の暗いグレーで描画され視認性が悪い。
 * Chromeと同様にプレースホルダーと同じ色になるよう明示的に指定する。
 */
vaadin-text-field > vaadin-icon[slot="prefix"],
vaadin-password-field > vaadin-icon[slot="prefix"] {
    color: rgba(255, 255, 255, 0.5);
}

vaadin-button {
    --lumo-primary-color: var(--teal);
    --lumo-primary-contrast-color: var(--navy-deep);
    --lumo-body-text-color: var(--text-2);
    cursor: pointer;
    font-family: var(--body);
}

.app-shell {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    min-height: 100vh;
    background:
        linear-gradient(145deg, rgba(20, 184, 166, 0.05), transparent 34%),
        linear-gradient(320deg, rgba(249, 112, 102, 0.04), transparent 40%),
        var(--navy-dark);
}

.app-shell--enter {
    overflow: hidden;
}

.app-shell--enter .sidebar {
    overflow: hidden;
    transform-origin: left center;
    animation: sidebarExpandIn 620ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.app-shell--enter .sidebar .brand,
.app-shell--enter .nav-section,
.app-shell--enter .sidebar-booost-logo,
.app-shell--enter .topbar,
.app-shell--enter .page-head,
.app-shell--enter .executive-dashboard,
.app-shell--enter .sensing-grid,
.app-shell--enter .sct-shell,
.app-shell--enter .content-placeholder {
    opacity: 0;
    animation: mainElementFadeIn 560ms ease forwards;
}

.app-shell--enter .sidebar .brand {
    animation-delay: 180ms;
}

.app-shell--enter .nav-section:nth-of-type(2) {
    animation-delay: 260ms;
}

.app-shell--enter .nav-section:nth-of-type(3) {
    animation-delay: 340ms;
}

.app-shell--enter .sidebar-booost-logo {
    animation-delay: 420ms;
}

.app-shell--enter .topbar {
    animation-delay: 300ms;
}

.app-shell--enter .page-head {
    animation-delay: 400ms;
}

.app-shell--enter .executive-dashboard,
.app-shell--enter .sensing-grid,
.app-shell--enter .sct-shell,
.app-shell--enter .content-placeholder {
    animation-delay: 500ms;
}

@keyframes sidebarExpandIn {
    0% {
        opacity: 0.72;
        transform: scaleX(0);
    }
    100% {
        opacity: 1;
        transform: scaleX(1);
    }
}

@keyframes mainElementFadeIn {
    0% {
        opacity: 0;
        transform: translateX(-12px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

.sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 22px 0;
    border-right: 1px solid var(--border);
    background: linear-gradient(180deg, #04101f 0%, #061a2e 100%);
}

.sidebar .brand {
    margin-bottom: 18px;
    padding: 0 20px 28px;
    border-bottom: 1px solid var(--border);
}

.nav-section {
    padding: 0 12px 18px;
}

.nav-label {
    padding: 0 10px 8px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 1.8px;
    text-transform: uppercase;
}

vaadin-button.nav-item {
    --lumo-button-size: 36px;
    --lumo-primary-text-color: var(--text-2);
    --vaadin-button-background: transparent;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 11px;
    min-height: 36px;
    margin-bottom: 2px;
    padding: 9px 10px;
    border-radius: 6px;
    background: transparent;
    background-color: transparent;
    color: var(--text-2);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    position: relative;
    transition: background-color 0.15s ease, color 0.15s ease;
}

vaadin-button.nav-item::part(label) {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 11px;
}

vaadin-button.nav-item:hover {
    --vaadin-button-background: transparent;
    background: transparent;
    background-color: transparent;
    color: #fff;
}

vaadin-button.nav-item.active {
    --vaadin-button-background: linear-gradient(90deg, rgba(20, 184, 166, 0.12), rgba(20, 184, 166, 0.02));
    background: linear-gradient(90deg, rgba(20, 184, 166, 0.12), rgba(20, 184, 166, 0.02));
    color: #fff;
}

vaadin-button.nav-item.active::before {
    content: "";
    position: absolute;
    left: -12px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    border-radius: 0 2px 2px 0;
    background: var(--teal);
}

.nav-icon {
    width: 16px;
    height: 16px;
    display: grid;
    place-items: center;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 11px;
    flex: 0 0 auto;
}

vaadin-button.nav-item.active .nav-icon {
    color: var(--teal);
}

.nav-badge {
    margin-left: auto;
    padding: 1px 6px;
    border-radius: 8px;
    background: var(--coral);
    color: #fff;
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
}

.sidebar-booost-logo {
    margin: auto 20px 0;
}

.main {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 16px;
    min-height: 62px;
    padding: 14px 28px;
    border-bottom: 1px solid var(--border);
    background: rgba(6, 26, 46, 0.82);
    backdrop-filter: blur(20px);
}

.ai-field {
    width: 100%;
}

.topbar-spacer {
    flex: 1;
}

.exchange-rate-badge {
    flex: 0 0 auto;
    padding: 6px 9px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.035);
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

vaadin-button.avatar-button {
    --lumo-button-size: 36px;
    --lumo-primary-text-color: #fff;
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0d9488, var(--coral));
    color: #fff;
    display: grid;
    place-items: center;
    font-family: var(--display);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    cursor: pointer;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1);
}

vaadin-button.avatar-button::part(label) {
    display: grid;
    place-items: center;
}

.content {
    flex: 1;
    min-height: 0;
    padding: 26px 28px 32px;
}

.page-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border);
}

.eyebrow {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    color: var(--teal);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 2.4px;
    text-transform: uppercase;
}

.eyebrow::before {
    content: "";
    width: 16px;
    height: 1px;
    background: var(--teal);
}

.page-title {
    color: #fff;
    font-family: var(--display);
    font-size: 28px;
    font-weight: 500;
    line-height: 1.2;
}

.page-title em {
    color: var(--teal-light);
    font-style: italic;
    font-weight: 400;
}

.page-sub {
    margin-top: 6px;
    color: var(--text-3);
    font-size: 13px;
    line-height: 1.7;
}

.page-head-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

.live-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 12px;
    background: rgba(16, 185, 129, 0.08);
    color: var(--green);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
}

.live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--green);
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(1.3); }
}

.content-placeholder {
    min-height: calc(100vh - 178px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 14px;
}

.executive-dashboard {
    display: grid;
    gap: 14px;
}

.executive-dashboard-body {
    min-height: calc(100vh - 178px);
}

.executive-perspective-switcher {
    display: flex;
    align-items: center;
    justify-content: end;
}

.executive-perspective-switcher:empty {
    display: none;
}

.executive-switcher-label {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.executive-switcher-controls {
    display: flex;
    align-items: center;
    gap: 4px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255,255,255,0.03);
}

.executive-switcher-button {
    min-width: 36px;
    padding: 4px 0;
    border-radius: 6px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 800;
    text-align: center;
}

.executive-switcher-button.active {
    color: var(--navy);
    background-color: var(--teal);
}

.executive-dashboard-body > .stub-grid {
    margin-top: 0;
}

.kpi-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.kpi {
    min-height: 172px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.34), rgba(22, 58, 95, 0.15));
    overflow: hidden;
}

.kpi.coral {
    border-color: rgba(249, 112, 102, 0.22);
}

.kpi.gold {
    border-color: rgba(245, 158, 11, 0.22);
}

.kpi.teal {
    border-color: rgba(20, 184, 166, 0.22);
}

.kpi.purple {
    border-color: rgba(167, 139, 250, 0.22);
}

.kpi-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.kpi-value-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
}

.kpi-value {
    color: #fff;
    font-family: var(--display);
    font-size: 31px;
    font-weight: 500;
    line-height: 1;
}

.kpi-unit {
    margin-left: 2px;
    color: var(--text-3);
    font-size: 14px;
    font-family: var(--display);
    font-style: normal;
}

/* Shared KPI unit suffix: smaller than the value and semi-transparent, sized
   relative to the host value so it works across every screen's metric font. */
.metric-unit {
    margin-left: 2px;
    color: var(--text-3);
    font-size: 0.5em;
    font-weight: 400;
    font-style: normal;
    opacity: 0.75;
}

.kpi-delta {
    flex: 0 0 auto;
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.kpi-delta.down {
    color: var(--coral);
}

.kpi-delta.up {
    color: var(--green);
}

@keyframes chartRevealLR {
    from {
        clip-path: inset(0 100% 0 0);
    }
    to {
        clip-path: inset(0 0 0 0);
    }
}

.kpi-spark {
    display: block;
    width: 100%;
    height: 36px;
    margin-top: 14px;
    animation: chartRevealLR 0.9s ease-out both;
}

.kpi-spark-line {
    fill: none;
    stroke-width: 1.8;
}

.kpi-spark-fill {
    stroke: none;
    opacity: 0.18;
}

.kpi-spark-line.coral {
    stroke: var(--coral);
}

.kpi-spark-fill.coral {
    fill: var(--coral);
}

.kpi-spark-line.gold {
    stroke: var(--gold);
}

.kpi-spark-fill.gold {
    fill: var(--gold);
}

.kpi-spark-line.teal {
    stroke: var(--teal);
}

.kpi-spark-fill.teal {
    fill: var(--teal);
}

.kpi-spark-line.purple {
    stroke: var(--purple);
}

.kpi-spark-fill.purple {
    fill: var(--purple);
}

.kpi-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-top: 10px;
    color: var(--text-4);
    font-size: 10px;
}

.executive-module-grid {
    margin-top: 14px;
}

.executive-insight-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
    margin-top: 14px;
}

.insight-panel {
    min-height: 300px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.3), rgba(22, 58, 95, 0.12));
    overflow: hidden;
}

.insight-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.insight-title {
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 500;
    line-height: 1.2;
}

.insight-meta {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    white-space: nowrap;
}

.geo-heatmap {
    display: grid;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 2px;
}

.geo-cell {
    min-width: 34px;
    min-height: 32px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 7px 5px;
    border: 0;
    border-radius: 6px;
    color: var(--text);
    font-family: var(--mono);
    box-shadow: inset 0 0 0 1px rgba(4, 16, 31, 0.16);
}

.geo-corner,
.geo-axis {
    min-height: 28px;
    display: flex;
    align-items: center;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.geo-corner {
    justify-content: flex-start;
    text-transform: uppercase;
}

.geo-axis-country {
    justify-content: center;
    color: var(--text-3);
}

.geo-axis-country.home {
    color: var(--teal-light);
}

.geo-axis-risk {
    min-width: 96px;
    overflow: hidden;
    color: var(--text-2);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.geo-score {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
}

.impact-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.impact-summary-item {
    min-height: 56px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.impact-summary-label {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    text-transform: uppercase;
}

.impact-summary-value {
    margin-top: 6px;
    color: #fff;
    font-family: var(--display);
    font-size: 22px;
    line-height: 1;
}

.impact-chart {
    display: block;
    width: 100%;
    height: 200px;
    margin-top: 8px;
    animation: chartRevealLR 1.1s ease-out both;
}

.impact-axis-line {
    stroke: rgba(255, 255, 255, 0.05);
    stroke-width: 1;
}

.impact-axis-line.baseline {
    stroke: rgba(255, 255, 255, 0.16);
}

.impact-axis-label {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
}

.impact-axis-label.y {
    text-anchor: end;
}

.impact-axis-label.x {
    text-anchor: middle;
}

.impact-line {
    fill: none;
    stroke-width: 2;
    stroke-linejoin: round;
    stroke-linecap: round;
}

.impact-line.coral {
    stroke: var(--coral);
}

.impact-line.gold {
    stroke: var(--gold);
}

.impact-line.teal {
    stroke: var(--teal);
}

.impact-line.purple {
    stroke: var(--purple);
}

.impact-line.total {
    stroke: var(--coral);
    stroke-width: 2.6;
}

.impact-end-dot {
    fill: var(--coral);
}

.impact-end-label {
    fill: var(--coral);
    font-family: var(--display);
    font-size: 12px;
    font-style: italic;
    text-anchor: end;
}

.impact-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    margin-top: 12px;
}

.impact-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-3);
    font-size: 11px;
}

.impact-legend-dot {
    width: 14px;
    height: 3px;
    border-radius: 2px;
    background: var(--text-4);
}

.impact-legend-dot.coral {
    background: var(--coral);
}

.impact-legend-dot.gold {
    background: var(--gold);
}

.impact-legend-dot.teal {
    background: var(--teal);
}

.impact-legend-dot.purple {
    background: var(--purple);
}

.impact-legend-dot.total {
    height: 4px;
    background: var(--coral);
}

.impact-breakdown {
    display: grid;
    gap: 7px;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--border);
}

.impact-breakdown-head {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.impact-breakdown-row {
    display: grid;
    grid-template-columns: 8px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    color: var(--text-3);
    font-size: 11px;
}

.breakdown-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-4);
}

.breakdown-dot.coral {
    background: var(--coral);
}

.breakdown-dot.gold {
    background: var(--gold);
}

.breakdown-dot.teal {
    background: var(--teal);
}

.breakdown-dot.purple {
    background: var(--purple);
}

.breakdown-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.breakdown-value {
    color: #fff;
    font-family: var(--mono);
    font-size: 10px;
}

.risk-stream-list,
.supplier-risk-list {
    display: grid;
    gap: 9px;
}

.risk-stream-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 72px;
    gap: 5px 10px;
    align-items: center;
    min-height: 62px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.risk-stream-item:last-child,
.supplier-risk-item:last-child {
    border-bottom: 0;
}

.stream-headline {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
    display: -webkit-box;
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
    -webkit-box-orient: vertical;
    line-clamp: 2;
}

.stream-meta {
    grid-column: 1;
    grid-row: 2;
    color: var(--text-4);
    font-size: 11px;
    line-height: 1.35;
}

.stream-impact {
    grid-column: 2;
    grid-row: 1 / span 2;
    display: grid;
    justify-items: end;
    align-content: center;
    gap: 3px;
    padding: 0;
    text-align: right;
}

.stream-impact-value {
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

.stream-impact-date {
    font-family: var(--mono);
    font-size: 8px;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    color: var(--text-4);
}

.supplier-risk-item {
    position: relative;
    display: grid;
    gap: 7px;
    min-height: 62px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.supplier-row-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
}

.supplier-name {
    overflow: hidden;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.supplier-score {
    color: var(--coral);
    font-family: var(--display);
    font-size: 20px;
    line-height: 1;
}

.supplier-meta {
    overflow: hidden;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.supplier-score-bar {
    height: 5px;
    overflow: hidden;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.08);
}

.supplier-score-fill {
    height: 100%;
    border-radius: 6px;
    background: var(--coral);
}

.cfo-insight {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.cfo-insight-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(330px, 0.85fr);
    gap: 12px;
}

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

.cfo-panel--wide {
    grid-column: span 2;
}

.cfo-cascade-panel {
    min-height: 394px;
}

.cfo-cascade-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.cfo-waterfall {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 720 / 300;
    margin-top: 4px;
    border-bottom: 1px solid var(--border);
}

.cfo-waterfall-grid {
    stroke: rgba(148, 163, 184, 0.12);
    stroke-width: 1;
}

.cfo-waterfall-baseline {
    stroke: rgba(148, 163, 184, 0.18);
    stroke-width: 1;
}

.cfo-waterfall-connector {
    stroke: rgba(148, 163, 184, 0.32);
    stroke-width: 1;
    stroke-dasharray: 2 4;
}

.cfo-waterfall-bar {
    filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.18));
}

.cfo-waterfall-bar.teal {
    fill: rgba(94, 234, 212, 0.78);
}

.cfo-waterfall-bar.coral {
    fill: rgba(249, 112, 102, 0.92);
}

.cfo-waterfall-bar.gold {
    fill: rgba(245, 158, 11, 0.9);
}

.cfo-waterfall-bar.purple {
    fill: rgba(167, 139, 250, 0.9);
}

.cfo-waterfall-bar.green {
    fill: rgba(16, 185, 129, 0.84);
}

.cfo-waterfall-value {
    fill: #fff;
    font-family: var(--display);
    font-size: 11px;
    font-style: italic;
    font-weight: 700;
}

.cfo-waterfall-value.negative {
    fill: var(--coral);
}

.cfo-waterfall-value.positive {
    fill: var(--green);
}

.cfo-waterfall-label {
    fill: var(--text-2);
    font-size: 10px;
    font-weight: 800;
}

.cfo-waterfall-sub,
.cfo-waterfall-axis {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 8px;
    font-weight: 800;
}

.cfo-disclosure-list,
.cfo-consensus-list {
    display: grid;
    gap: 10px;
}

.cfo-disclosure-row,
.cfo-consensus-row {
    display: grid;
    gap: 8px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.cfo-disclosure-row:last-child,
.cfo-consensus-row:last-child {
    border-bottom: 0;
}

.cfo-row-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.cfo-row-title {
    min-width: 0;
    overflow: hidden;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cfo-row-value,
.cfo-consensus-delta,
.cfo-protection {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
}

.cfo-row-value.coral,
.cfo-consensus-delta.coral,
.cfo-protection.negative,
.cfo-status.coral {
    color: var(--coral);
}

.cfo-row-value.gold,
.cfo-consensus-delta.gold,
.cfo-status.gold {
    color: var(--gold);
}

.cfo-row-value.teal,
.cfo-row-value.green,
.cfo-consensus-delta.teal,
.cfo-consensus-delta.green,
.cfo-protection.positive,
.cfo-status.teal,
.cfo-status.green {
    color: var(--green);
}

.cfo-row-value.purple,
.cfo-consensus-delta.purple,
.cfo-status.purple {
    color: var(--purple);
}

.cfo-row-meta {
    min-width: 0;
    overflow: hidden;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cfo-progress {
    height: 5px;
    overflow: hidden;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
}

.cfo-progress-fill {
    height: 100%;
    border-radius: 8px;
}

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

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

.cfo-progress-fill.teal,
.cfo-progress-fill.green {
    background: var(--green);
}

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

.cfo-kpi-row {
    display: grid;
    gap: 4px;
    padding: 12px 14px;
    border-radius: 8px;
    border-left: 2px solid var(--teal);
    background: rgba(20, 184, 166, 0.04);
}

.cfo-kpi-row.gold {
    border-left-color: var(--gold);
    background: rgba(245, 158, 11, 0.04);
}

.cfo-kpi-row.coral {
    border-left-color: var(--coral);
    background: rgba(249, 112, 102, 0.04);
}

.cfo-kpi-row.purple {
    border-left-color: var(--purple);
    background: rgba(167, 139, 250, 0.04);
}

.cfo-kpi-row.green {
    border-left-color: var(--green);
    background: rgba(16, 185, 129, 0.04);
}

.cfo-kpi-title {
    color: #fff;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.3;
}

.cfo-kpi-value {
    font-family: var(--display, var(--mono));
    font-size: 16px;
    font-style: italic;
    font-weight: 500;
    white-space: nowrap;
}

.cfo-kpi-value.teal,
.cfo-kpi-value.green {
    color: var(--teal);
}

.cfo-kpi-value.gold {
    color: var(--gold);
}

.cfo-kpi-value.coral {
    color: var(--coral);
}

.cfo-kpi-value.purple {
    color: var(--purple);
}

.cfo-kpi-desc {
    color: var(--text-3);
    font-size: 10.5px;
    line-height: 1.4;
}

.cfo-hedging-panel {
    min-height: 304px;
}

.cfo-hedge-table {
    display: grid;
    overflow-x: auto;
}

.cfo-hedge-row {
    min-width: 860px;
    display: grid;
    grid-template-columns: minmax(250px, 1.35fr) 112px 118px 136px 150px 108px;
    gap: 12px;
    align-items: center;
    min-height: 54px;
    padding: 9px 0;
    border-bottom: 1px solid var(--border);
}

.cfo-hedge-row:last-child {
    border-bottom: 0;
}

.cfo-hedge-head {
    min-height: 32px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.cfo-hedge-title {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.cfo-status {
    width: fit-content;
    max-width: 100%;
    padding: 4px 8px;
    border: 1px solid currentColor;
    border-radius: 999px;
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
    white-space: nowrap;
}

.cfo-maturity {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cfo-hedge-empty {
    min-width: 0;
    padding: 12px 0;
}

.cpo-insight {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.cpo-insight-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(330px, 0.9fr);
    gap: 12px;
}

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

.cpo-panel--wide {
    grid-column: span 2;
}

.cpo-map-panel {
    min-height: 430px;
}

.cpo-category-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 10px;
}

.cpo-category-chart {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 720 / 280;
    margin-top: 6px;
    border-bottom: 1px solid var(--border);
}

.cpo-chart-grid {
    stroke: rgba(148, 163, 184, 0.12);
    stroke-width: 1;
}

.cpo-chart-axis-line {
    stroke: rgba(148, 163, 184, 0.18);
    stroke-width: 1;
}

.cpo-chart-axis,
.cpo-chart-title {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
}

.cpo-empty-text {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 800;
}

.cpo-bubble {
    stroke-width: 1.5;
    filter: drop-shadow(0 10px 16px rgba(0, 0, 0, 0.2));
}

.cpo-bubble.coral {
    fill: rgba(249, 112, 102, 0.76);
    stroke: rgba(249, 112, 102, 0.95);
}

.cpo-bubble.gold {
    fill: rgba(245, 158, 11, 0.72);
    stroke: rgba(245, 158, 11, 0.92);
}

.cpo-bubble.teal,
.cpo-bubble.green {
    fill: rgba(20, 184, 166, 0.7);
    stroke: rgba(94, 234, 212, 0.95);
}

.cpo-bubble.purple {
    fill: rgba(167, 139, 250, 0.7);
    stroke: rgba(167, 139, 250, 0.95);
}

.cpo-bubble-label {
    fill: #fff;
    font-size: 10px;
    font-weight: 800;
}

.cpo-category-legend {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
    margin-top: 12px;
}

.cpo-category-legend-row {
    min-width: 0;
    display: grid;
    grid-template-columns: 8px minmax(0, 1fr);
    gap: 7px;
    align-items: center;
}

.cpo-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-4);
}

.cpo-dot.coral {
    background: var(--coral);
}

.cpo-dot.gold {
    background: var(--gold);
}

.cpo-dot.teal,
.cpo-dot.green {
    background: var(--teal);
}

.cpo-dot.purple {
    background: var(--purple);
}

.cpo-legend-name,
.cpo-legend-meta {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cpo-legend-name {
    color: var(--text-2);
    font-size: 11px;
    font-weight: 800;
}

.cpo-legend-meta {
    grid-column: 2;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
}

.cpo-hhi-list,
.cpo-sku-list {
    display: grid;
    gap: 10px;
}

.cpo-hhi-row,
.cpo-sku-row {
    display: grid;
    gap: 8px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}

.cpo-hhi-row:last-child,
.cpo-sku-row:last-child {
    border-bottom: 0;
}

.cpo-row-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.cpo-row-title {
    min-width: 0;
    overflow: hidden;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cpo-row-value {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
}

.cpo-row-value.coral {
    color: var(--coral);
}

.cpo-row-value.gold {
    color: var(--gold);
}

.cpo-row-value.teal,
.cpo-row-value.green {
    color: var(--green);
}

.cpo-row-value.purple {
    color: var(--purple);
}

.cpo-row-meta {
    min-width: 0;
    overflow: hidden;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cpo-progress {
    height: 5px;
    overflow: hidden;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
}

.cpo-progress-fill {
    height: 100%;
    border-radius: 8px;
}

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

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

.cpo-progress-fill.teal,
.cpo-progress-fill.green {
    background: var(--green);
}

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

.cpo-actions-panel {
    min-height: 326px;
}

.cpo-action-table {
    display: grid;
    overflow-x: auto;
}

.cpo-action-row {
    min-width: 860px;
    display: grid;
    grid-template-columns: minmax(280px, 1.4fr) minmax(210px, 0.9fr) 128px 78px 94px;
    gap: 12px;
    align-items: center;
    min-height: 54px;
    padding: 9px 0;
    border-bottom: 1px solid var(--border);
}

.cpo-action-row:last-child {
    border-bottom: 0;
}

.cpo-action-head {
    min-height: 32px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.cpo-action-title {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.cpo-target {
    color: var(--text-3);
}

.cpo-table-empty {
    min-width: 0;
    padding: 12px 0;
}

.bu-insight-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(330px, 0.85fr);
    gap: 12px;
    margin-top: 14px;
}

.bu-pnl-panel,
.bu-warning-panel,
.bu-cascade-panel,
.bu-orderbook-panel {
    min-height: 336px;
}

.bu-pnl-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.bu-waterfall {
    height: auto;
    aspect-ratio: 720 / 300;
}

.bu-warning-list,
.bu-orderbook-list {
    display: grid;
    gap: 10px;
}

.bu-warning-row {
    display: grid;
    gap: 7px;
    padding: 12px 14px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.bu-warning-row.coral {
    border-color: rgba(249, 112, 102, 0.28);
    background: rgba(249, 112, 102, 0.065);
}

.bu-warning-row.gold {
    border-color: rgba(245, 158, 11, 0.26);
    background: rgba(245, 158, 11, 0.06);
}

.bu-warning-row.teal,
.bu-warning-row.green {
    border-color: rgba(20, 184, 166, 0.24);
    background: rgba(20, 184, 166, 0.045);
}

.bu-warning-top,
.bu-orderbook-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}

.bu-warning-badge {
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 1.1px;
    text-transform: uppercase;
}

.bu-warning-badge.coral,
.bu-warning-impact.coral,
.bu-orderbook-risk.coral {
    color: var(--coral);
}

.bu-warning-badge.gold,
.bu-warning-impact.gold,
.bu-orderbook-risk.gold {
    color: var(--gold);
}

.bu-warning-badge.teal,
.bu-warning-badge.green,
.bu-warning-impact.teal,
.bu-warning-impact.green,
.bu-orderbook-risk.teal,
.bu-orderbook-risk.green {
    color: var(--green);
}

.bu-warning-headline {
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.35;
}

.bu-warning-meta,
.bu-orderbook-meta {
    min-width: 0;
    overflow: hidden;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bu-warning-impact {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 900;
}

.bu-cascade-chart {
    display: block;
    width: 100%;
    height: auto;
    margin-top: 6px;
    border-bottom: 1px solid var(--border);
}

.bu-cascade-header {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 0.12em;
}

.bu-cascade-edge {
    fill: none;
    stroke-width: 2;
    stroke-dasharray: 3 4;
}

.bu-cascade-edge.coral {
    stroke: rgba(249, 112, 102, 0.48);
}

.bu-cascade-edge.gold {
    stroke: rgba(245, 158, 11, 0.48);
}

.bu-cascade-edge.teal,
.bu-cascade-edge.green {
    stroke: rgba(20, 184, 166, 0.44);
}

.bu-cascade-node {
    fill: rgba(255, 255, 255, 0.035);
    stroke: rgba(255, 255, 255, 0.15);
    stroke-width: 1;
}

.bu-cascade-node.source.coral,
.bu-cascade-node.sku.coral {
    fill: rgba(249, 112, 102, 0.12);
    stroke: rgba(249, 112, 102, 0.72);
}

.bu-cascade-node.source.gold,
.bu-cascade-node.sku.gold {
    fill: rgba(245, 158, 11, 0.1);
    stroke: rgba(245, 158, 11, 0.68);
}

.bu-cascade-node.source.teal,
.bu-cascade-node.source.green,
.bu-cascade-node.sku.teal,
.bu-cascade-node.sku.green {
    fill: rgba(20, 184, 166, 0.09);
    stroke: rgba(20, 184, 166, 0.62);
}

.bu-cascade-node.supplier {
    fill: rgba(255, 255, 255, 0.04);
    stroke: rgba(148, 163, 184, 0.26);
}

.bu-cascade-title {
    fill: #fff;
    font-size: 10px;
    font-weight: 800;
}

.bu-cascade-meta {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 8px;
    font-weight: 800;
}

.bu-orderbook-row {
    display: grid;
    gap: 8px;
    padding: 11px 0;
    border-bottom: 1px solid var(--border);
}

.bu-orderbook-row:last-child {
    border-bottom: 0;
}

.bu-orderbook-name {
    min-width: 0;
    overflow: hidden;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bu-orderbook-risk {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
}

.bu-orderbook-bar {
    height: 5px;
    overflow: hidden;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
}

.bu-orderbook-fill {
    height: 100%;
    border-radius: 8px;
}

.bu-orderbook-fill.coral {
    background: var(--coral);
}

.bu-orderbook-fill.gold {
    background: var(--gold);
}

.bu-orderbook-fill.teal,
.bu-orderbook-fill.green {
    background: var(--teal);
}

.financial-impact-shell {
    flex: 1;
    min-height: calc(100vh - 178px);
    display: grid;
    grid-template-columns: minmax(620px, 1.45fr) minmax(360px, 0.95fr);
    gap: 14px;
}

.fi-panel {
    min-width: 0;
    padding: 20px 22px;
    border: 1px solid rgba(64, 104, 148, 0.38);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(20, 47, 78, 0.86), rgba(9, 31, 55, 0.96));
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.fi-cascade-panel {
    min-height: calc(100vh - 178px);
}

.fi-category-panel {
    min-height: calc(100vh - 178px);
}

.fi-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.fi-panel-title {
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 500;
    line-height: 1.2;
}

.fi-panel-sub {
    margin-top: 8px;
    color: var(--text-3);
    font-size: 12px;
    line-height: 1.4;
}

.fi-decompose {
    margin-top: 18px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2.6px;
    white-space: nowrap;
}

.fi-waterfall {
    display: block;
    width: 100%;
    height: min(48vh, 430px);
    min-height: 330px;
    margin-top: 34px;
}

.fi-waterfall-grid {
    stroke: rgba(148, 163, 184, 0.12);
    stroke-width: 1;
}

.fi-waterfall-baseline {
    stroke: rgba(148, 163, 184, 0.18);
    stroke-width: 1;
}

.fi-waterfall-connector {
    stroke: rgba(148, 163, 184, 0.34);
    stroke-width: 1;
    stroke-dasharray: 2 4;
}

.fi-waterfall-bar {
    filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.18));
}

.fi-waterfall-bar.teal {
    fill: rgba(94, 234, 212, 0.72);
}

.fi-waterfall-bar.coral {
    fill: rgba(249, 112, 102, 0.92);
}

.fi-waterfall-bar.gold {
    fill: rgba(245, 158, 11, 0.9);
}

.fi-waterfall-bar.purple {
    fill: rgba(167, 139, 250, 0.9);
}

.fi-waterfall-bar.green {
    fill: rgba(16, 185, 129, 0.82);
}

.fi-waterfall-value {
    fill: #fff;
    font-family: var(--display);
    font-size: 14px;
    font-style: italic;
    font-weight: 700;
}

.fi-waterfall-value.negative {
    fill: var(--coral);
}

.fi-waterfall-value.positive {
    fill: var(--green);
}

.fi-waterfall-value.neutral,
.fi-waterfall-bar.base + .fi-waterfall-value {
    fill: #fff;
}

.fi-waterfall-label {
    fill: var(--text-3);
    font-family: var(--body);
    font-size: 12px;
    font-weight: 700;
}

.fi-waterfall-sub {
    fill: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.fi-waterfall-axis {
    fill: rgba(148, 163, 184, 0.48);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.fi-var-line {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 2px;
    padding-right: 26px;
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 800;
}

.fi-var-label {
    color: var(--coral);
}

.fi-var-value.negative {
    color: var(--coral);
}

.fi-var-value.positive {
    color: var(--green);
}

.fi-category-list {
    display: grid;
    gap: 14px;
    margin-top: 26px;
}

.fi-category-row {
    min-width: 0;
    padding: 16px 18px;
    border: 1px solid rgba(64, 104, 148, 0.36);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.fi-category-row-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.fi-category-name {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
    color: var(--text);
    font-size: 14px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.fi-category-dot {
    width: 8px;
    height: 8px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--text-4);
}

.fi-category-dot.coral,
.fi-category-fill.coral {
    background: var(--coral);
}

.fi-category-dot.gold,
.fi-category-fill.gold {
    background: var(--gold);
}

.fi-category-dot.green,
.fi-category-fill.green {
    background: var(--green);
}

.fi-category-value {
    flex: 0 0 auto;
    font-family: var(--display);
    font-size: 21px;
    font-style: italic;
    line-height: 1;
}

.fi-category-value.negative {
    color: var(--coral);
}

.fi-category-value.positive {
    color: var(--green);
}

.fi-category-bar {
    height: 5px;
    overflow: hidden;
    margin-top: 16px;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.13);
}

.fi-category-fill {
    height: 100%;
    border-radius: 999px;
}

.fi-category-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 11px;
    color: var(--text-3);
    font-size: 11px;
}

.fi-category-meta .mono {
    overflow: hidden;
    text-align: right;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.compliance-cockpit {
    flex: 1;
    min-height: calc(100vh - 178px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 14px;
}

.cc-hero {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.cc-metric {
    min-height: 138px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.34), rgba(22, 58, 95, 0.15));
}

.cc-metric.teal {
    border-color: rgba(20, 184, 166, 0.25);
}

.cc-metric.green {
    border-color: rgba(16, 185, 129, 0.25);
}

.cc-metric.gold {
    border-color: rgba(245, 158, 11, 0.25);
}

.cc-metric.coral {
    border-color: rgba(249, 112, 102, 0.25);
}

.cc-metric-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.cc-metric-value {
    margin-top: 18px;
    color: #fff;
    font-family: var(--display);
    font-size: 32px;
    font-weight: 500;
    line-height: 1;
}

.cc-metric.teal .cc-metric-value {
    color: var(--teal-light);
}

.cc-metric.green .cc-metric-value {
    color: var(--green);
}

.cc-metric.gold .cc-metric-value {
    color: var(--gold);
}

.cc-metric.coral .cc-metric-value {
    color: var(--coral);
}

.cc-metric-note {
    margin-top: 14px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
}

.cc-framework-section {
    min-height: 0;
    padding: 18px;
    border: 1px solid rgba(64, 104, 148, 0.38);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(20, 47, 78, 0.76), rgba(9, 31, 55, 0.94));
}

.cc-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.cc-section-title {
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 500;
}

.cc-section-meta {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.cc-framework-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.cc-framework-tile {
    min-width: 0;
    min-height: 244px;
    display: flex;
    flex-direction: column;
    padding: 15px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.cc-framework-tile.coral {
    border-color: rgba(249, 112, 102, 0.22);
}

.cc-framework-tile.gold {
    border-color: rgba(245, 158, 11, 0.22);
}

.cc-framework-tile.green {
    border-color: rgba(16, 185, 129, 0.22);
}

.cc-framework-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
}

.cc-framework-short {
    color: #fff;
    font-family: var(--display);
    font-size: 23px;
    font-weight: 600;
    line-height: 1;
}

.cc-framework-name {
    display: -webkit-box;
    overflow: hidden;
    margin-top: 8px;
    color: var(--text-3);
    font-size: 11px;
    line-height: 1.4;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.cc-status {
    flex: 0 0 auto;
    padding: 4px 7px;
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.cc-status.coral {
    background: rgba(249, 112, 102, 0.12);
    color: var(--coral);
}

.cc-status.gold {
    background: rgba(245, 158, 11, 0.12);
    color: var(--gold);
}

.cc-status.green {
    background: rgba(16, 185, 129, 0.12);
    color: var(--green);
}

.cc-progress {
    height: 6px;
    overflow: hidden;
    margin-top: 16px;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.12);
}

.cc-progress-fill {
    height: 100%;
    border-radius: 999px;
}

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

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

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

.cc-framework-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px;
    margin-top: 14px;
}

.cc-framework-metric {
    min-width: 0;
    padding: 9px 8px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.025);
}

.cc-framework-metric-label {
    overflow: hidden;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 8px;
    font-weight: 800;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.cc-framework-metric-value {
    margin-top: 5px;
    overflow: hidden;
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cc-framework-description {
    /* display: -webkit-box; */
    height: 8em;
    overflow: scroll;
    scrollbar-width: none;
    margin-top: 13px;
    color: var(--text-3);
    font-size: 11px;
    line-height: 1.55;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    line-clamp: 4;
}

.cc-framework-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    padding-top: 13px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
}

.cc-framework-meta span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.action-workbench {
    flex: 1;
    min-height: calc(100vh - 178px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 14px;
}

.aw-metric-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.aw-metric {
    min-height: 138px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.34), rgba(22, 58, 95, 0.15));
}

.aw-metric.teal {
    border-color: rgba(20, 184, 166, 0.25);
}

.aw-metric.green {
    border-color: rgba(16, 185, 129, 0.25);
}

.aw-metric.gold {
    border-color: rgba(245, 158, 11, 0.25);
}

.aw-metric.coral {
    border-color: rgba(249, 112, 102, 0.25);
}

.aw-metric-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.aw-metric-value {
    margin-top: 18px;
    color: #fff;
    font-family: var(--display);
    font-size: 32px;
    font-weight: 500;
    line-height: 1;
}

.aw-metric.teal .aw-metric-value {
    color: var(--teal-light);
}

.aw-metric.green .aw-metric-value {
    color: var(--green);
}

.aw-metric.gold .aw-metric-value {
    color: var(--gold);
}

.aw-metric.coral .aw-metric-value {
    color: var(--coral);
}

.aw-metric-note {
    margin-top: 14px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
}

.aw-workspace {
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(520px, 1.15fr) minmax(380px, 0.85fr);
    gap: 14px;
}

.aw-panel {
    min-width: 0;
    min-height: 0;
    padding: 18px;
    border: 1px solid rgba(64, 104, 148, 0.38);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(20, 47, 78, 0.76), rgba(9, 31, 55, 0.94));
}

.aw-list-panel,
.aw-detail-panel {
    display: flex;
    flex-direction: column;
}

.aw-panel-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.aw-panel-title {
    color: #fff;
    font-family: var(--display);
    font-size: 19px;
    font-weight: 500;
}

.aw-panel-sub {
    margin-top: 6px;
    color: var(--text-3);
    font-size: 12px;
}

.aw-action-list {
    min-height: 0;
    /* Show 4.5 records (76px rows + 10px gaps), then scroll within the element. */
    max-height: 382px;
    display: grid;
    gap: 10px;
    overflow: auto;
    padding-right: 2px;
}

.aw-action-row {
    min-width: 0;
    min-height: 76px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 13px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
    cursor: pointer;
}

.aw-action-row:hover,
.aw-action-row:focus-visible {
    border-color: rgba(20, 184, 166, 0.28);
    background: rgba(20, 184, 166, 0.06);
    outline: none;
}

.aw-action-row.selected {
    border-color: rgba(20, 184, 166, 0.5);
    background: rgba(20, 184, 166, 0.1);
    box-shadow: inset 3px 0 0 var(--teal);
}

.aw-action-main {
    min-width: 0;
}

.aw-action-title {
    overflow: hidden;
    color: var(--text);
    font-size: 14px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.aw-action-meta {
    overflow: hidden;
    margin-top: 6px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.aw-action-values {
    min-width: 92px;
    text-align: right;
}

.aw-action-risk {
    color: var(--green);
    font-family: var(--display);
    font-size: 20px;
    font-style: italic;
    line-height: 1;
}

.aw-action-roi {
    margin-top: 7px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
}

.aw-detail-panel {
    gap: 16px;
}

.aw-detail-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.aw-detail-eyebrow {
    color: var(--teal-light);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.6px;
}

.aw-detail-title {
    display: -webkit-box;
    overflow: hidden;
    margin-top: 8px;
    color: #fff;
    font-family: var(--display);
    font-size: 24px;
    font-weight: 600;
    line-height: 1.18;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.aw-detail-target {
    overflow: hidden;
    margin-top: 8px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.aw-detail-roi {
    flex: 0 0 auto;
    color: var(--gold);
    font-family: var(--display);
    font-size: 30px;
    font-style: italic;
    line-height: 1;
}

.aw-detail-metrics {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.aw-detail-metric {
    min-width: 0;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.aw-detail-metric.green {
    border-color: rgba(16, 185, 129, 0.18);
}

.aw-detail-metric.coral {
    border-color: rgba(249, 112, 102, 0.18);
}

.aw-detail-metric.gold {
    border-color: rgba(245, 158, 11, 0.18);
}

.aw-detail-metric.teal {
    border-color: rgba(20, 184, 166, 0.18);
}

.aw-detail-metric-label,
.aw-section-label {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.aw-detail-metric-value {
    overflow: hidden;
    margin-top: 8px;
    color: #fff;
    font-family: var(--display);
    font-size: 22px;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.aw-detail-metric.green .aw-detail-metric-value {
    color: var(--green);
}

.aw-detail-metric.coral .aw-detail-metric-value {
    color: var(--coral);
}

.aw-detail-metric.gold .aw-detail-metric-value {
    color: var(--gold);
}

.aw-detail-metric.teal .aw-detail-metric-value {
    color: var(--teal-light);
}

.aw-target-card {
    min-width: 0;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.aw-detail-copy {
    margin-top: 11px;
    color: var(--text-2);
    font-size: 12px;
    line-height: 1.7;
}

.aw-org-section {
    min-height: 0;
    margin-top: auto;
}

.aw-org-list {
    min-height: 0;
    max-height: 260px;
    display: grid;
    gap: 8px;
    overflow: auto;
    margin-top: 11px;
}

.aw-org-item {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 11px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.aw-country-badge {
    width: 34px;
    height: 28px;
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    border: 1px solid rgba(20, 184, 166, 0.18);
    border-radius: 6px;
    background: rgba(20, 184, 166, 0.08);
    color: var(--teal-light);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
}

.aw-org-main {
    min-width: 0;
}

.aw-org-name {
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.aw-org-meta {
    overflow: hidden;
    margin-top: 4px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.supplier-portal {
    flex: 1;
    min-height: calc(100vh - 178px);
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    gap: 14px;
}

.sp-metric-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.sp-metric {
    min-height: 138px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.34), rgba(22, 58, 95, 0.15));
}

.sp-metric.teal {
    border-color: rgba(20, 184, 166, 0.25);
}

.sp-metric.green {
    border-color: rgba(16, 185, 129, 0.25);
}

.sp-metric.gold {
    border-color: rgba(245, 158, 11, 0.25);
}

.sp-metric-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.sp-metric-value {
    margin-top: 18px;
    color: #fff;
    font-family: var(--display);
    font-size: 32px;
    font-weight: 500;
    line-height: 1;
}

.sp-metric.teal .sp-metric-value {
    color: var(--teal-light);
}

.sp-metric.green .sp-metric-value {
    color: var(--green);
}

.sp-metric.gold .sp-metric-value {
    color: var(--gold);
}

.sp-metric-note {
    margin-top: 14px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
}

.sp-workspace {
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(680px, 1fr) 340px;
    gap: 14px;
}

.sp-panel {
    min-width: 0;
    min-height: 0;
    padding: 18px;
    border: 1px solid rgba(64, 104, 148, 0.38);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(20, 47, 78, 0.76), rgba(9, 31, 55, 0.94));
}

.sp-panel-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.sp-panel-title {
    color: #fff;
    font-family: var(--display);
    font-size: 19px;
    font-weight: 500;
}

.sp-panel-sub {
    margin-top: 6px;
    color: var(--text-3);
    font-size: 12px;
}

.sp-supplier-table {
    min-height: 0;
    display: grid;
    gap: 9px;
    overflow: auto;
}

.sp-table-row {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(220px, 1.25fr) 140px minmax(150px, 0.8fr) 108px 126px;
    align-items: center;
    gap: 14px;
}

.sp-table-head {
    padding: 0 12px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.1px;
    text-transform: uppercase;
}

.sp-supplier-row {
    min-height: 74px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.sp-supplier-cell {
    min-width: 0;
}

.sp-supplier-name {
    overflow: hidden;
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sp-supplier-meta,
.sp-date-cell,
.sp-pcf-count {
    overflow: hidden;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sp-supplier-meta {
    margin-top: 5px;
    color: var(--text-4);
}

.sp-coverage-cell {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(70px, 1fr) 44px;
    align-items: center;
    gap: 10px;
}

.sp-progress {
    height: 6px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.12);
}

.sp-progress-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--gold), var(--teal-light));
}

.sp-coverage-value {
    color: var(--text-2);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    text-align: right;
}

.sp-pcf-cell {
    min-width: 0;
}

.sp-pcf-status {
    width: fit-content;
    padding: 3px 7px;
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
}

.sp-pcf-status.enabled {
    background: rgba(16, 185, 129, 0.12);
    color: var(--green);
}

.sp-pcf-status.pending {
    background: rgba(245, 158, 11, 0.12);
    color: var(--gold);
}

.sp-pcf-count {
    margin-top: 6px;
}

.sp-status {
    width: fit-content;
    max-width: 100%;
    overflow: hidden;
    padding: 5px 8px;
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sp-status.sync {
    background: rgba(20, 184, 166, 0.13);
    color: var(--teal-light);
}

.sp-status.progress {
    background: rgba(245, 158, 11, 0.12);
    color: var(--gold);
}

.sp-interop-panel {
    display: flex;
    flex-direction: column;
}

.sp-interop-list {
    min-height: 0;
    display: grid;
    gap: 10px;
    overflow: auto;
}

.sp-interop-item {
    min-width: 0;
    padding: 13px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.sp-interop-item-head {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.sp-interop-name {
    min-width: 0;
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sp-standard-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}

.sp-standard-chip {
    padding: 3px 7px;
    border-radius: 4px;
    background: rgba(20, 184, 166, 0.1);
    color: var(--teal-light);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
}

.sp-standard-chip.muted {
    background: rgba(148, 163, 184, 0.08);
    color: var(--text-4);
}

.scenario-studio {
    flex: 1;
    min-height: calc(100vh - 178px);
}

.ss-shell {
    min-height: calc(100vh - 178px);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* Top boxes: executed scenario overview */
.ss-banner {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.ss-scenario-card {
    appearance: none;
    position: relative;
    min-width: 0;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(22, 58, 95, 0.2);
    color: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.ss-scenario-card:hover {
    background: rgba(22, 58, 95, 0.35);
}

.ss-scenario-card.active {
    border-color: var(--coral);
    background: rgba(249, 112, 102, 0.06);
}

.ss-scenario-card.active::after {
    content: "✓";
    position: absolute;
    top: 12px;
    right: 12px;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--coral);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
}

.ss-scenario-tag {
    margin-bottom: 8px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.ss-scenario-title {
    overflow: hidden;
    margin-bottom: 4px;
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 500;
    letter-spacing: -0.2px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ss-scenario-sub {
    min-height: 30px;
    margin-bottom: 14px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.ss-scenario-impact {
    font-family: var(--display);
    font-style: italic;
    font-size: 22px;
    font-weight: 500;
    letter-spacing: -0.3px;
}

.ss-scenario-impact.coral {
    color: var(--coral);
}

.ss-scenario-impact.gold {
    color: var(--gold);
}

.ss-scenario-impact.purple {
    color: var(--purple);
}

.ss-scenario-impact.teal {
    color: var(--teal-light);
}

.ss-scenario-impact-label {
    margin-top: 3px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.ss-loss-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.ss-loss-card {
    min-height: 138px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.34), rgba(22, 58, 95, 0.15));
}

.ss-loss-card.coral {
    border-color: rgba(249, 112, 102, 0.25);
}

.ss-loss-card.gold {
    border-color: rgba(245, 158, 11, 0.25);
}

.ss-loss-card.purple {
    border-color: rgba(167, 139, 250, 0.25);
}

.ss-loss-card.teal {
    border-color: rgba(20, 184, 166, 0.25);
}

.ss-loss-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.ss-loss-value {
    margin-top: 18px;
    overflow: hidden;
    color: #fff;
    font-family: var(--display);
    font-size: 32px;
    font-weight: 500;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ss-loss-card.coral .ss-loss-value {
    color: var(--coral);
}

.ss-loss-card.gold .ss-loss-value {
    color: var(--gold);
}

.ss-loss-card.purple .ss-loss-value {
    color: var(--purple);
}

.ss-loss-card.teal .ss-loss-value {
    color: var(--teal-light);
}

.ss-loss-note {
    margin-top: 14px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
}

.ss-grid {
    min-height: 0;
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    align-items: start;
    gap: 14px;
}

.ss-panel {
    min-width: 0;
    min-height: 0;
    padding: 18px;
    border: 1px solid rgba(64, 104, 148, 0.38);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(20, 47, 78, 0.76), rgba(9, 31, 55, 0.94));
}

.ss-outcome-panel,
.ss-drivers-panel,
.ss-comparison-panel {
    display: flex;
    flex-direction: column;
}

.ss-panel-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.ss-panel-title {
    color: #fff;
    font-family: var(--display);
    font-size: 19px;
    font-weight: 500;
}

.ss-panel-sub {
    display: -webkit-box;
    overflow: hidden;
    margin-top: 6px;
    color: var(--text-3);
    font-size: 12px;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.ss-scenario-list {
    min-height: 0;
    max-height: 560px;
    display: grid;
    gap: 10px;
    overflow: auto;
    padding-right: 2px;
}

.ss-scenario-item {
    appearance: none;
    min-width: 0;
    display: grid;
    gap: 7px;
    padding: 13px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.ss-scenario-item:hover,
.ss-scenario-item:focus-visible {
    border-color: rgba(20, 184, 166, 0.28);
    background: rgba(20, 184, 166, 0.06);
    outline: none;
}

.ss-scenario-item.selected {
    border-color: rgba(20, 184, 166, 0.5);
    background: rgba(20, 184, 166, 0.1);
    box-shadow: inset 3px 0 0 var(--teal);
}

.ss-scenario-category {
    width: fit-content;
    padding: 3px 7px;
    border-radius: 4px;
    background: rgba(167, 139, 250, 0.12);
    color: var(--purple);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
}

.ss-scenario-headline {
    display: -webkit-box;
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    font-weight: 700;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.ss-scenario-meta {
    overflow: hidden;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ss-distribution-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
}

.ss-meta-item {
    min-width: 78px;
    padding: 8px 10px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.025);
    text-align: right;
}

.ss-meta-label {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 8px;
    font-weight: 800;
    text-transform: uppercase;
}

.ss-meta-value {
    margin-top: 4px;
    color: var(--text);
    font-family: var(--display);
    font-size: 15px;
    line-height: 1;
}

.ss-outcome-body {
    min-height: 0;
    display: block;
}

.ss-chart {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 6px 4px 2px 0;
}

.ss-chart-row {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 12px;
}

.ss-y-axis {
    height: 220px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
    line-height: 1;
    text-align: right;
}

.ss-chart-plot {
    position: relative;
    height: 220px;
    border-left: 1px solid rgba(148, 163, 184, 0.18);
    border-bottom: 1px solid rgba(148, 163, 184, 0.28);
}

.ss-chart-plot::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(to bottom, rgba(148, 163, 184, 0.08) 1px, transparent 1px) 0 0 / 100% 50%;
}

.ss-bars {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: flex;
    align-items: flex-end;
    gap: 4px;
    padding: 0 8px;
}

.ss-bar {
    flex: 1 1 0;
    min-width: 4px;
    border-radius: 3px 3px 0 0;
    background: linear-gradient(180deg, var(--coral), var(--gold));
    opacity: 0;
    transform: scaleY(0);
    transform-origin: bottom;
    animation: ssBarRise 520ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes ssBarRise {
    from {
        opacity: 0;
        transform: scaleY(0);
    }
    to {
        opacity: 0.9;
        transform: scaleY(1);
    }
}

.ss-x-axis {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-left: 64px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
}

/* Outcome Distribution stats — rendered below the chart (mock layout) */
.ss-outcome-footer {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.ss-outcome-stat {
    min-width: 0;
}

.ss-outcome-stat-label {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.ss-outcome-stat-value {
    overflow: hidden;
    margin-top: 4px;
    font-family: var(--display);
    font-style: italic;
    font-size: 20px;
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ss-outcome-stat-value.white {
    color: #fff;
}

.ss-outcome-stat-value.coral {
    color: var(--coral);
}

.ss-outcome-stat-value.coral-dark {
    color: #dc2626;
}

.ss-driver-base {
    margin-top: 6px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
    text-align: right;
}

/* Cross-Scenario Comparison table */
.ss-cmp-table {
    display: grid;
    gap: 9px;
}

.ss-cmp-row {
    min-width: 0;
    display: grid;
    grid-template-columns: minmax(200px, 1.5fr) 120px 120px 120px minmax(140px, 1fr) 110px;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.ss-cmp-head {
    padding: 0 12px;
    border: 0;
    background: none;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1.1px;
    text-transform: uppercase;
}

.ss-cmp-combined {
    border-color: rgba(249, 112, 102, 0.3);
    background: rgba(249, 112, 102, 0.06);
}

.ss-cmp-cell {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ss-cmp-name {
    overflow: hidden;
    color: var(--text);
    font-size: 13px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ss-cmp-combined .ss-cmp-name {
    color: var(--coral);
}

.ss-cmp-sub {
    margin-top: 4px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.ss-cmp-impact {
    font-family: var(--display);
    font-style: italic;
    font-size: 15px;
    font-weight: 500;
    color: var(--text);
}

.ss-cmp-impact.coral {
    color: var(--coral);
}

.ss-cmp-impact.coral-dark {
    color: #dc2626;
}

.ss-cmp-driver {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.ss-cmp-tag {
    width: fit-content;
    padding: 3px 8px;
    border-radius: 4px;
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.ss-cmp-tag.live {
    background: rgba(20, 184, 166, 0.15);
    color: var(--teal-light);
}

.ss-cmp-tag.muted {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-4);
}

.ss-cmp-tag.combined {
    background: rgba(249, 112, 102, 0.15);
    color: var(--coral);
}

.ss-run-controls {
    display: grid;
    gap: 10px;
    margin-bottom: 14px;
    grid-template-columns: auto 128px 128px;
}

.ss-driver-list {
    min-height: 0;
    max-height: 460px;
    display: grid;
    gap: 10px;
    overflow: auto;
    padding-right: 2px;
}

.ss-driver-control {
    min-width: 0;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.ss-driver-control.compact {
    padding: 10px 12px;
}

.ss-driver-label-row {
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.ss-driver-name {
    min-width: 0;
    overflow: hidden;
    color: var(--text);
    font-size: 11px;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ss-driver-value {
    flex: 0 0 auto;
    color: var(--teal-light);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
}

.ss-driver-control input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    margin: 12px 0 2px;
    border-radius: 2px;
    background:
        linear-gradient(90deg, var(--teal), var(--coral)) left center / var(--ss-range-fill, 50%) 100% no-repeat,
        rgba(255, 255, 255, 0.12);
    cursor: pointer;
}

.ss-driver-control input[type="range"]::-webkit-slider-runnable-track {
    height: 4px;
    border-radius: 2px;
    background: transparent;
}

.ss-driver-control input[type="range"]::-moz-range-track {
    height: 4px;
    border-radius: 2px;
    background: transparent;
}

.ss-driver-control input[type="range"]::-moz-range-progress {
    height: 4px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--teal), var(--coral));
}

.ss-driver-control input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    margin-top: -5px;
    border: 2px solid var(--teal);
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
}

.ss-driver-control input[type="range"]::-moz-range-thumb {
    width: 14px;
    height: 14px;
    border: 2px solid var(--teal);
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
}

.ss-driver-input-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 82px;
    align-items: center;
    gap: 10px;
}

.ss-number-input {
    width: 100%;
    min-width: 0;
    padding: 7px 8px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: rgba(4, 16, 31, 0.55);
    color: var(--text);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
}

.ss-run-button {
    font-size: 11px;
    align-self: center;
}

.ss-run-button:disabled {
    cursor: default;
    opacity: 0.55;
}

.ss-run-button:not(:disabled):hover {
    background: rgba(20, 184, 166, 0.2);
}

.sct-shell {
    flex: 1;
    min-height: calc(100vh - 178px);
    display: grid;
    grid-template-columns: minmax(760px, 1fr) 340px;
    gap: 14px;
}

.sct-graph {
    min-width: 0;
}

.sct-stage {
    position: relative;
    min-height: calc(100vh - 178px);
    overflow: hidden;
    padding: 16px;
    border: 1px solid rgba(26, 75, 112, 0.5);
    border-radius: 8px;
    background: #06243a;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.sct-svg,
.sct-tier-layer,
.sct-node-layer {
    position: absolute;
}

.sct-tier-layer,
.sct-node-layer {
    inset: 16px;
}

.sct-svg {
    left: 16px;
    top: 16px;
    width: calc(100% - 32px);
    height: calc(100% - 32px);
    pointer-events: none;
}

.sct-tier-separator {
    stroke: rgba(28, 79, 118, 0.42);
    stroke-width: 1;
    stroke-dasharray: 5 9;
}

.sct-edge {
    fill: none;
    stroke: rgba(20, 184, 166, 0.18);
    stroke-width: 1.4;
}

.sct-edge.highlight {
    stroke: rgba(255, 107, 99, 0.78);
    stroke-width: 1.8;
}

.sct-tier-heading {
    position: absolute;
    top: 8px;
    transform: translateX(-22px);
    color: rgba(203, 213, 225, 0.66);
    font-family: var(--mono);
    pointer-events: none;
    text-transform: uppercase;
}

.sct-tier-title {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 6px;
    line-height: 1;
}

.sct-tier-suppliers {
    margin-top: 6px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    line-height: 1;
    white-space: nowrap;
}

.sct-graph-node {
    position: absolute;
    appearance: none;
    display: flex;
    align-items: center;
    min-width: 16px;
    min-height: 16px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--text);
    font: inherit;
    text-align: left;
    transform: translateY(-50%);
    cursor: pointer;
    --sct-name-width: 144px;
}

.sct-graph-node.dot-only {
    width: 28px;
    height: 28px;
    justify-content: center;
    transform: translate(-50%, -50%);
}

.sct-graph-node.labelled {
    width: calc(var(--sct-name-width) + 46px);
    min-width: 0;
    gap: 8px;
}

.sct-graph-node.tier-1 {
    --sct-name-width: 160px;
}

.sct-graph-node.tier-2 {
    --sct-name-width: 150px;
}

.sct-graph-node.tier-3 {
    --sct-name-width: 150px;
}

.sct-graph-node.tier-4 {
    --sct-name-width: 120px;
}

.sct-graph-node.tier-5 {
    --sct-name-width: 112px;
}

.sct-graph-node.tier-4,
.sct-graph-node.tier-5 {
    opacity: 0.92;
}

.sct-graph-dot {
    position: relative;
    width: 16px;
    height: 16px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--teal);
    box-shadow: 0 0 0 1px rgba(6, 36, 58, 0.88);
    transform: translateX(-50%);
}

.sct-graph-node.dot-only .sct-graph-dot {
    transform: none;
}

.sct-graph-node.tier-1 .sct-graph-dot {
    width: 22px;
    height: 22px;
}

.sct-graph-node.tier-1.critical .sct-graph-dot,
.sct-graph-node.tier-1.selected-tier1 .sct-graph-dot {
    width: 28px;
    height: 28px;
}

.sct-graph-node.tier-1.critical .sct-graph-dot::before,
.sct-graph-node.tier-1.selected-tier1 .sct-graph-dot::before {
    content: "";
    position: absolute;
    inset: -10px;
    border-radius: 50%;
    background: rgba(255, 107, 99, 0.18);
    z-index: -1;
}

.sct-graph-node.tier-1.critical .sct-graph-dot::after,
.sct-graph-node.tier-1.selected-tier1 .sct-graph-dot::after {
    content: "";
    position: absolute;
    inset: 2px;
    border: 1px solid rgba(255, 255, 255, 0.62);
    border-radius: 50%;
}

.sct-graph-node.tier-3 .sct-graph-dot {
    width: 13px;
    height: 13px;
}

.sct-graph-node.tier-4 .sct-graph-dot,
.sct-graph-node.tier-5 .sct-graph-dot {
    width: 9px;
    height: 9px;
}

.sct-graph-node.critical .sct-graph-dot,
.sct-legend-dot.critical {
    background: #ff6b63;
}

.sct-graph-node.high .sct-graph-dot,
.sct-legend-dot.high {
    background: #f59e0b;
}

.sct-graph-node.healthy .sct-graph-dot,
.sct-legend-dot.healthy {
    background: #20c7b8;
}

.sct-graph-node.inferred .sct-graph-dot,
.sct-legend-dot.inferred {
    background: #4d647d;
}

.sct-graph-node.selected .sct-graph-dot {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.24), 0 0 0 8px rgba(20, 184, 166, 0.12);
}

/* Supply Chain Twin reveal animation: tier nodes, then the edges feeding the
   next tier, build up left to right, ending with the selected node glowing. */
.sct-stage--animate .sct-graph-node,
.sct-stage--animate .sct-tier-heading {
    opacity: 0;
    animation: sctRevealIn 0.42s ease forwards;
    animation-delay: var(--sct-delay, 0s);
}

.sct-stage--animate .sct-edge {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    animation: sctEdgeDraw 0.5s ease forwards;
    animation-delay: var(--sct-delay, 0s);
}

@keyframes sctRevealIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes sctEdgeDraw {
    to {
        stroke-dashoffset: 0;
    }
}

.sct-graph-node.selected .sct-graph-dot {
    animation: sctNodeGlow 1.8s ease-in-out infinite;
    animation-delay: var(--sct-glow-delay, 0s);
}

@keyframes sctNodeGlow {
    0%,
    100% {
        box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.24), 0 0 0 8px rgba(20, 184, 166, 0.12);
    }
    50% {
        box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.45), 0 0 16px 7px rgba(20, 184, 166, 0.5);
    }
}

@media (prefers-reduced-motion: reduce) {
    .sct-stage--animate .sct-graph-node,
    .sct-stage--animate .sct-tier-heading,
    .sct-stage--animate .sct-edge,
    .sct-graph-node.selected .sct-graph-dot {
        animation: none;
        opacity: 1;
        stroke-dashoffset: 0;
    }
}

.sct-graph-label {
    width: var(--sct-name-width);
    min-width: 0;
    display: grid;
    gap: 2px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.26);
}

.sct-graph-name {
    display: block;
    width: var(--sct-name-width);
    overflow: hidden;
    max-width: var(--sct-name-width);
    color: #fff;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.15;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sct-graph-meta {
    width: var(--sct-name-width);
    overflow: hidden;
    color: rgba(203, 213, 225, 0.58);
    font-family: var(--mono);
    font-size: 8px;
    font-weight: 700;
    line-height: 1;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sct-legend {
    position: absolute;
    left: 16px;
    bottom: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    color: rgba(226, 232, 240, 0.86);
    font-size: 12px;
}

.sct-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sct-legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.sct-detail {
    min-width: 0;
    padding: 16px;
    overflow: hidden;
    border: 1px solid rgba(26, 75, 112, 0.5);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(8, 38, 60, 0.96), rgba(7, 32, 52, 0.92));
}

.sct-detail-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.sct-detail-identity {
    min-width: 0;
    display: flex;
    align-items: flex-start;
    gap: 11px;
}

.sct-detail-flag {
    width: 34px;
    height: 24px;
    flex: 0 0 auto;
    border-radius: 3px;
    object-fit: cover;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14);
}

.sct-detail-title-block {
    min-width: 0;
}

.sct-detail-name {
    color: #fff;
    font-family: var(--display);
    font-size: 19px;
    font-weight: 500;
    line-height: 1.18;
}

.sct-detail-location {
    margin-top: 5px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.sct-detail-score {
    flex: 0 0 auto;
    text-align: right;
}

.sct-detail-score-value {
    font-family: var(--display);
    font-size: 36px;
    line-height: 1;
}

.sct-detail-score-label {
    margin-top: 2px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.sct-section {
    padding-top: 15px;
}

.sct-section-title {
    margin-bottom: 9px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.3px;
    text-transform: uppercase;
}

.sct-risk-list,
.sct-action-list {
    display: grid;
    gap: 9px;
}

.sct-risk-item,
.sct-action-item {
    padding: 11px 0;
    border-bottom: 1px solid var(--border);
}

.sct-risk-item:first-child,
.sct-action-item:first-child {
    padding-top: 0;
}

.sct-risk-item:last-child,
.sct-action-item:last-child {
    border-bottom: 0;
}

.sct-risk-headline {
    display: -webkit-box;
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.42;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.sct-risk-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 5px;
    margin-top: 7px;
}

.sct-risk-chip {
    padding: 2px 6px;
    border-radius: 3px;
    background: rgba(20, 184, 166, 0.12);
    color: var(--teal-light);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
}

.sct-risk-date {
    margin-left: auto;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    white-space: nowrap;
}

.sct-action-title {
    color: #fff;
    font-size: 12.5px;
    font-weight: 700;
    line-height: 1.35;
}

.sct-action-detail {
    margin-top: 5px;
    display: -webkit-box;
    overflow: hidden;
    color: var(--text-3);
    font-size: 11px;
    line-height: 1.55;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.sct-empty {
    padding: 12px 0;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
}

.mock-panel {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.32), rgba(22, 58, 95, 0.14));
    padding: 18px;
}

.panel-title {
    color: #fff;
    font-family: var(--display);
    font-size: 16px;
    font-weight: 500;
}

.panel-sub {
    margin-top: 4px;
    color: var(--text-3);
    font-size: 12px;
    line-height: 1.6;
}

.stub-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.stub-card {
    min-height: 116px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.stub-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.stub-value {
    margin-top: 13px;
    color: #fff;
    font-family: var(--display);
    font-size: 28px;
    font-weight: 500;
}

.stub-note {
    margin-top: 8px;
    color: var(--text-4);
    font-size: 11px;
}

.rail-list {
    display: grid;
    gap: 10px;
    margin-top: 16px;
}

.rail-item {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.rail-item-title {
    color: var(--text);
    font-size: 13px;
    font-weight: 600;
}

.rail-item-meta {
    margin-top: 3px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
}

.dialog-body {
    min-width: 320px;
    display: grid;
    gap: 14px;
    padding: 2px;
    color: var(--text);
}

.dialog-head {
    display: flex;
    align-items: center;
    gap: 12px;
}

.dialog-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0d9488, var(--coral));
    display: grid;
    place-items: center;
    color: #fff;
    font-family: var(--display);
    font-weight: 700;
}

.dialog-name {
    color: #fff;
    font-weight: 700;
}

.dialog-email {
    color: var(--text-3);
    font-size: 12px;
}

.profile-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding-top: 10px;
    border-top: 1px solid var(--border);
    font-size: 13px;
}

.profile-label {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.profile-value {
    color: var(--text-2);
    text-align: right;
}

vaadin-dialog-overlay::part(overlay) {
    border: 1px solid var(--border-strong);
    background: #082037;
    color: var(--text);
}

vaadin-dialog-overlay::part(header) {
    color: #fff;
}

.content--full {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.3), rgba(22, 58, 95, 0.15));
    padding: 18px;
    min-width: 0;
}

.card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.card-head.compact {
    align-items: center;
    margin-bottom: 8px;
}

.card-title {
    color: #fff;
    font-family: var(--display);
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0;
}

.compact-title {
    font-size: 13px;
}

.card-sub {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 11px;
}

.card-action {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
}

vaadin-button.btn {
    --lumo-button-size: 32px;
    --lumo-primary-text-color: var(--text-2);
    min-width: 0;
    padding: 0 12px;
    border: 1px solid var(--border-strong);
    border-radius: 6px;
    color: var(--text-2);
    font-size: 12px;
    font-weight: 500;
}

vaadin-button.btn:hover {
    background: rgba(255, 255, 255, 0.04);
    color: #fff;
}

vaadin-button.btn-small {
    --lumo-button-size: 26px;
    padding: 0 10px;
    font-size: 11px;
}

.sensing-grid {
    flex: 1;
    /* Bound the grid to the client area so the Risk Signal Stream fills the
       viewport and scrolls inside .timeline-wrap instead of growing the page. */
    height: calc(100vh - 178px);
    min-height: 0;
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr) 280px;
    gap: 14px;
}

.sensing-card,
.timeline-card,
.impact-side {
    min-height: 0;
}

.timeline-card {
    display: flex;
    flex-direction: column;
}

.pillar-list {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.pillar-row {
    width: 100%;
    appearance: none;
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 38px;
    padding: 10px 12px;
    border: 1px solid transparent;
    border-radius: 6px;
    background: transparent;
    color: var(--text-2);
    cursor: pointer;
    font: inherit;
    text-align: left;
}

.pillar-row:hover {
    background: rgba(255, 255, 255, 0.02);
}

.pillar-row.active {
    background: rgba(20, 184, 166, 0.06);
}

.pillar-row.selected {
    border-color: rgba(20, 184, 166, 0.62);
    background: rgba(20, 184, 166, 0.08);
    color: #fff;
}

.pillar-num {
    width: 22px;
    color: var(--coral);
    font-family: var(--display);
    font-size: 13px;
    font-style: italic;
    font-weight: 600;
}

.pillar-name {
    flex: 1;
    color: #fff;
    font-size: 12.5px;
    font-weight: 500;
}

.pillar-count {
    min-width: 28px;
    padding: 1px 7px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-2);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    text-align: center;
}

.pillar-count.hot {
    background: rgba(249, 112, 102, 0.15);
    color: var(--coral);
}

.timeline-wrap {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 2px;
}

.timeline-event {
    display: grid;
    grid-template-columns: 80px 20px minmax(0, 1fr);
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
    position: relative;
}

.timeline-event:last-child {
    border-bottom: 0;
}

.te-time {
    padding-top: 1px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 11px;
    line-height: 1.35;
}

.te-time-rel {
    margin-top: 2px;
    color: var(--text-4);
    font-size: 10px;
}

.te-dot-col {
    position: relative;
    display: flex;
    justify-content: center;
}

.te-dot {
    width: 10px;
    height: 10px;
    margin-top: 3px;
    border: 2px solid var(--navy-dark);
    border-radius: 50%;
    background: var(--teal);
    z-index: 2;
}

.te-dot.critical {
    background: var(--coral);
}

.te-dot.high {
    background: var(--gold);
}

.te-dot.med {
    background: var(--teal);
}

.te-line {
    position: absolute;
    top: 14px;
    bottom: -14px;
    left: 50%;
    width: 1px;
    background: var(--border-strong);
    transform: translateX(-50%);
}

.te-body {
    min-width: 0;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
}

.te-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 6px;
}

.te-tag {
    padding: 2px 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-2);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.te-tag.critical { background: rgba(249, 112, 102, 0.15); color: var(--coral); }
.te-tag.high { background: rgba(245, 158, 11, 0.15); color: var(--gold); }
.te-tag.med { background: rgba(20, 184, 166, 0.15); color: var(--teal); }
.te-tag.geo, .te-tag.human { background: rgba(167, 139, 250, 0.15); color: var(--purple); }
.te-tag.trade, .te-tag.commodity { background: rgba(245, 158, 11, 0.15); color: var(--gold); }
.te-tag.supply, .te-tag.climate, .te-tag.nature { background: rgba(20, 184, 166, 0.15); color: var(--teal); }
.te-tag.fx, .te-tag.counterparty, .te-tag.cyber { background: rgba(249, 112, 102, 0.12); color: var(--coral); }

.te-title {
    margin-bottom: 4px;
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
}

.te-source {
    color: var(--text-3);
    font-size: 11px;
    line-height: 1.45;
}

.te-indicators {
    margin-top: 7px;
    color: var(--gold);
    font-family: var(--mono);
    font-size: 10.5px;
    line-height: 1.5;
}

.te-actions {
    display: flex;
    gap: 6px;
    margin-top: 8px;
}

.impact-side {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.metric-big {
    padding: 18px;
    border: 1px solid rgba(249, 112, 102, 0.24);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(249, 112, 102, 0.1), rgba(22, 58, 95, 0.18));
}

.metric-big-label {
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.metric-big-line {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.metric-big-value {
    color: var(--coral);
    font-family: var(--display);
    font-size: 38px;
    font-style: italic;
    font-weight: 500;
    line-height: 1;
}

.metric-big-unit {
    color: var(--text-3);
    font-family: var(--display);
    font-size: 14px;
    font-style: italic;
}

.metric-big-meta {
    margin-top: 10px;
    color: var(--text-3);
    font-size: 11px;
    line-height: 1.55;
}

.source-title {
    margin-bottom: 12px;
}

.source-list {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.source-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--text-2);
    font-size: 12px;
}

.muted {
    color: var(--text-3);
}

.mono {
    font-family: var(--mono);
}

.source-count {
    color: #fff;
    font-size: 11px;
    white-space: nowrap;
}

.rs-screen {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 248px minmax(0, 1fr) 300px;
    gap: 14px;
}

.rs-card {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: linear-gradient(180deg, rgba(22, 58, 95, 0.32), rgba(22, 58, 95, 0.14));
    padding: 16px;
}

.rs-card-title {
    color: #fff;
    font-family: var(--display);
    font-size: 15px;
    font-weight: 500;
}

.rs-card-sub {
    margin-top: 3px;
    color: var(--text-3);
    font-size: 11.5px;
}

.rs-pillars,
.rs-impact {
    overflow-y: auto;
}

.rs-pillar-list {
    display: grid;
    gap: 11px;
    margin-top: 14px;
}

.rs-pillar-row {
    display: grid;
    gap: 6px;
}

.rs-pillar-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.rs-pillar-name {
    color: var(--text-2);
    font-size: 12.5px;
}

.rs-pillar-count {
    color: var(--teal-light);
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 700;
}

.rs-pillar-track {
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

.rs-pillar-bar {
    height: 100%;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--teal), var(--teal-light));
}

.rs-stream {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.rs-card-head {
    margin-bottom: 12px;
}

vaadin-grid.rs-grid {
    flex: 1;
    min-height: 0;
    --lumo-base-color: transparent;
    --lumo-contrast-5pct: rgba(255, 255, 255, 0.03);
    --lumo-contrast-10pct: var(--border);
    --lumo-body-text-color: var(--text-2);
    --lumo-secondary-text-color: var(--text-3);
    --lumo-header-text-color: var(--text-3);
    --lumo-font-family: var(--body);
    color: var(--text-2);
}

.rs-source-link {
    color: var(--teal-light);
    text-decoration: none;
}

.rs-source-link:hover {
    text-decoration: underline;
}

.rs-impact-body {
    margin-top: 14px;
}

.rs-metric-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.rs-metric {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
}

.rs-metric-value {
    color: #fff;
    font-family: var(--display);
    font-size: 26px;
    font-weight: 500;
}

.rs-metric-label {
    margin-top: 4px;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9.5px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.rs-subhead {
    margin: 18px 0 10px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.rs-indicator-list {
    display: grid;
    gap: 8px;
}

.rs-indicator-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 9px 11px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.025);
}

.rs-indicator-name {
    color: var(--text-2);
    font-size: 12px;
}

.rs-indicator-value {
    color: var(--gold);
    font-family: var(--mono);
    font-size: 12px;
    font-weight: 700;
}

.rs-loading,
.rs-empty {
    margin-top: 14px;
    color: var(--text-3);
    font-size: 12.5px;
}

.rs-error {
    margin-top: 14px;
    color: var(--coral);
    font-size: 12.5px;
    line-height: 1.6;
}

.strategy-content {
    position: relative;
    overflow: hidden;
    padding: 0;
}

.strategy-session-screen {
    position: relative;
    min-height: calc(100vh - 62px);
    overflow: hidden;
    background:
        linear-gradient(180deg, rgba(4, 16, 31, 0.26), rgba(6, 26, 46, 0.72)),
        var(--navy-dark);
}

.strategy-top-actions {
    position: absolute;
    z-index: 10;
    top: 18px;
    right: 24px;
}

vaadin-button.strategy-history-button {
    --lumo-button-size: 38px;
    --lumo-primary-text-color: var(--text-2);
    width: 38px;
    height: 38px;
    min-width: 38px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.035);
    color: var(--text-2);
}

vaadin-button.strategy-history-button.active,
vaadin-button.strategy-history-button:hover {
    border-color: rgba(20, 184, 166, 0.34);
    background: rgba(20, 184, 166, 0.1);
    color: var(--teal-light);
}

.strategy-messages {
    position: absolute;
    inset: 0 0 110px;
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: auto;
    padding: 78px min(8vw, 112px) 34px;
    scroll-behavior: smooth;
}

.strategy-session-screen--empty .strategy-messages {
    display: none;
}

.strategy-message-row {
    display: flex;
    width: 100%;
}

.strategy-message-row.user {
    justify-content: flex-end;
}

.strategy-message-row.assistant {
    justify-content: flex-start;
}

.strategy-bubble {
    max-width: min(780px, 74%);
    min-width: 0;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-2);
    font-size: 13px;
    line-height: 1.65;
    box-shadow: 0 20px 56px rgba(0, 0, 0, 0.16);
    animation: strategyBubbleIn 220ms ease both;
}

.strategy-bubble.user {
    border-color: rgba(20, 184, 166, 0.28);
    background: rgba(20, 184, 166, 0.15);
    color: #fff;
}

.strategy-bubble.assistant {
    background: rgba(255, 255, 255, 0.035);
}

.strategy-bubble-text {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

@keyframes strategyBubbleIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.strategy-typing {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 48px;
    min-height: 22px;
}

.strategy-typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--teal-light);
    opacity: 0.42;
    animation: strategyTypingPulse 960ms ease-in-out infinite;
}

.strategy-typing span:nth-child(2) {
    animation-delay: 140ms;
}

.strategy-typing span:nth-child(3) {
    animation-delay: 280ms;
}

@keyframes strategyTypingPulse {
    0%, 100% {
        opacity: 0.32;
        transform: translateY(0);
    }
    45% {
        opacity: 1;
        transform: translateY(-3px);
    }
}

.strategy-composer {
    position: absolute;
    z-index: 7;
    left: 50%;
    bottom: calc(50% - 31px);
    width: min(760px, calc(100% - 96px));
    min-height: 62px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 42px;
    align-items: end;
    gap: 10px;
    padding: 10px;
    border: 1px solid rgba(64, 104, 148, 0.48);
    border-radius: 8px;
    background: rgba(4, 16, 31, 0.86);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
    transform: translateX(-50%);
    transition:
        bottom 460ms cubic-bezier(0.22, 1, 0.36, 1),
        width 460ms cubic-bezier(0.22, 1, 0.36, 1),
        transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
}

.strategy-session-screen--chatting .strategy-composer {
    bottom: 26px;
    width: min(860px, calc(100% - 128px));
    transform: translateX(-50%);
}

.strategy-prompt-input {
    width: 100%;
    min-height: 40px;
    max-height: 148px;
    resize: none;
    overflow: auto;
    padding: 10px 12px;
    border: 0;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.035);
    color: var(--text);
    font-family: var(--body);
    font-size: 14px;
    line-height: 1.45;
}

.strategy-prompt-input:focus {
    outline: 1px solid rgba(20, 184, 166, 0.34);
}

.strategy-send-button {
    appearance: none;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(20, 184, 166, 0.32);
    border-radius: 8px;
    background: rgba(20, 184, 166, 0.16);
    color: var(--teal-light);
    cursor: pointer;
}

.strategy-send-button:hover {
    background: rgba(20, 184, 166, 0.24);
}

.strategy-result {
    min-width: 0;
}

.strategy-result-summary {
    display: grid;
    gap: 8px;
    margin: 0;
    padding-left: 18px;
}

.strategy-result-summary li {
    overflow-wrap: anywhere;
}

vaadin-grid.strategy-result-grid {
    width: min(720px, 68vw);
    max-width: 100%;
    --lumo-base-color: transparent;
    --lumo-contrast-5pct: rgba(255, 255, 255, 0.03);
    --lumo-contrast-10pct: var(--border);
    --lumo-body-text-color: var(--text-2);
    --lumo-secondary-text-color: var(--text-3);
    --lumo-header-text-color: var(--text-3);
    --lumo-font-family: var(--body);
    color: var(--text-2);
}

.strategy-result-chart {
    min-width: min(640px, 62vw);
}

.strategy-chart-caption {
    margin: 0 0 6px;
    color: var(--text-3);
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.strategy-chart-body {
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.strategy-chart-yaxis {
    height: 250px;
    box-sizing: border-box;
    padding: 18px 4px 8px 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: flex-end;
    min-width: 36px;
    text-align: right;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
    white-space: nowrap;
}

.strategy-chart-main {
    flex: 1 1 auto;
    min-width: 0;
}

.strategy-chart-plot {
    height: 250px;
    display: flex;
    align-items: flex-end;
    gap: 10px;
    padding: 18px 12px 8px;
    border-left: 1px solid rgba(148, 163, 184, 0.14);
    border-bottom: 1px solid rgba(148, 163, 184, 0.14);
    background:
        linear-gradient(to bottom, rgba(148, 163, 184, 0.08) 1px, transparent 1px) 0 0 / 100% 33.33%;
}

.strategy-chart-bar {
    min-width: 28px;
    flex: 1 1 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 7px;
    align-items: center;
}

.strategy-chart-fill {
    width: 100%;
    min-height: 4px;
    border-radius: 4px 4px 0 0;
    background: linear-gradient(180deg, var(--teal-light), var(--teal));
    animation: strategyChartRise 520ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.strategy-chart-axis {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(28px, 1fr);
    gap: 10px;
    padding: 8px 12px 0;
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
}

.strategy-chart-axis span {
    min-width: 0;
    overflow: hidden;
    text-align: center;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@keyframes strategyChartRise {
    from {
        opacity: 0;
        transform: scaleY(0);
        transform-origin: bottom;
    }
    to {
        opacity: 1;
        transform: scaleY(1);
        transform-origin: bottom;
    }
}

.strategy-history-pane {
    position: absolute;
    z-index: 9;
    top: 0;
    right: 0;
    width: 344px;
    max-width: calc(100% - 24px);
    height: 100%;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr);
    border-left: 1px solid var(--border);
    background: rgba(4, 16, 31, 0.96);
    box-shadow: -24px 0 70px rgba(0, 0, 0, 0.22);
    transform: translateX(102%);
    transition: transform 260ms ease;
}

.strategy-history-pane.open {
    transform: translateX(0);
}

.strategy-history-head {
    min-height: 70px;
    display: flex;
    align-items: center;
    padding: 0 18px;
    border-bottom: 1px solid var(--border);
}

.strategy-history-title {
    color: #fff;
    font-family: var(--display);
    font-size: 20px;
    font-weight: 500;
}

.strategy-history-list {
    min-height: 0;
    display: grid;
    align-content: start;
    gap: 8px;
    overflow: auto;
    padding: 14px;
}

.strategy-history-empty {
    padding: 12px;
    color: var(--text-3);
    font-size: 12px;
}

.strategy-history-item {
    appearance: none;
    display: grid;
    gap: 7px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.025);
    color: inherit;
    text-align: left;
    cursor: pointer;
}

.strategy-history-item:hover,
.strategy-history-item.selected {
    border-color: rgba(20, 184, 166, 0.34);
    background: rgba(20, 184, 166, 0.08);
}

.strategy-history-item-title {
    display: -webkit-box;
    overflow: hidden;
    color: var(--text);
    font-size: 12px;
    font-weight: 800;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.strategy-history-item-date {
    color: var(--text-4);
    font-family: var(--mono);
    font-size: 9px;
    font-weight: 800;
}

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

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

    .aw-workspace {
        grid-template-columns: 1fr;
    }

    .sp-workspace {
        grid-template-columns: 1fr;
    }

    .sp-table-row {
        grid-template-columns: minmax(220px, 1.2fr) 130px minmax(130px, 0.8fr) 96px 118px;
    }

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

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

    .ss-chart-plot {
        min-height: 330px;
    }

    .timeline-card {
        min-height: 520px;
    }

    .rs-screen {
        grid-template-columns: 1fr;
    }

    .executive-insight-grid,
    .cfo-insight-grid,
    .cpo-insight-grid,
    .bu-insight-grid {
        grid-template-columns: 1fr;
    }

    .cfo-panel--wide,
    .cpo-panel--wide {
        grid-column: span 1;
    }

    vaadin-grid.rs-grid {
        min-height: 420px;
    }

    .strategy-bubble {
        max-width: 84%;
    }

    .strategy-session-screen--chatting .strategy-composer {
        width: min(760px, calc(100% - 64px));
    }

    .strategy-result-chart {
        min-width: min(560px, 72vw);
    }
}

@media (max-width: 900px) {
    body {
        min-width: 0;
    }

    .login-shell {
        grid-template-columns: 1fr;
    }

    .login-brand-panel {
        min-height: 42vh;
    }

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

    .topbar {
        gap: 10px;
        padding-inline: 12px;
    }

    .exchange-rate-badge {
        padding: 5px 7px;
        font-size: 9px;
    }

    .sidebar {
        position: static;
        height: auto;
    }

    .content-placeholder,
    .aw-metric-row,
    .sp-metric-row,
    .ss-loss-row,
    .cfo-cascade-summary,
    .cpo-category-summary,
    .bu-pnl-summary,
    .cpo-category-legend,
    .stub-grid {
        grid-template-columns: 1fr;
    }

    .executive-perspective-switcher {
        align-items: flex-start;
    }

    .ss-panel-head {
        display: grid;
    }

    .ss-distribution-meta {
        justify-content: stretch;
    }

    .ss-meta-item {
        flex: 1;
    }

    .sp-table-head {
        display: none;
    }

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

    .sp-coverage-cell {
        grid-template-columns: minmax(0, 1fr) 44px;
    }

    .strategy-messages {
        padding: 72px 18px 118px;
    }

    .strategy-bubble {
        max-width: 92%;
    }

    .strategy-composer,
    .strategy-session-screen--chatting .strategy-composer {
        width: calc(100% - 28px);
    }

    .strategy-history-pane {
        width: min(344px, calc(100% - 12px));
    }

    vaadin-grid.strategy-result-grid,
    .strategy-result-chart {
        width: 100%;
        min-width: 0;
    }
}
