/* Shared Direction B. Load after legacy page styles; fact state remains semantic. */
:root {
  --b-sidebar: #15140f;
  --b-canvas: #ecebe7;
  --b-paper: #fff;
  --b-ink: #181713;
  --b-muted: #716d63;
  --b-line: #e2dfd8;
  --b-soft: #f5f4f1;
  --b-selection: #f1eee6;
  --b-gold: #b18c43;
  --b-blue: #1d6fb7;
  --b-red: #d8332c;
  --b-radius: 15px;
  --bg: var(--b-canvas);
  --paper: var(--b-paper);
  --ink: var(--b-ink);
  --muted: var(--b-muted);
  --line: var(--b-line);
  --blue: var(--b-sidebar);
  --blue-tint: var(--b-selection);
  --green: var(--b-blue);
  --amber: #8d7649;
  --radius: var(--b-radius);
  --sans: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", -apple-system, sans-serif;
  font-family: var(--sans);
  color: var(--b-ink);
  background: var(--b-canvas);
  color-scheme: light;
}

body.direction-b { margin: 0; background: var(--b-canvas); color: var(--b-ink); font-family: var(--sans); font-size: 16px; line-height: 1.7; -webkit-font-smoothing: antialiased; }
.direction-b *, .direction-b *::before, .direction-b *::after { box-sizing: border-box; }
.direction-b button, .direction-b input, .direction-b select, .direction-b textarea { font-family: var(--sans); }
.direction-b [hidden] { display: none !important; }
.direction-b :focus-visible { outline: 2px solid #a9853e; outline-offset: 3px; }
.direction-b h2 { font-size: 21px; line-height: 1.5; letter-spacing: -.3px; }
.direction-b h3 { font-size: 17px; line-height: 1.6; }
.direction-b p { line-height: 1.8; }
.direction-b .text-muted, .direction-b .muted { color: var(--b-muted); font-size: 14px; }
.direction-b .app-rail {
  position: fixed; inset: 0 auto 0 0; z-index: 30;
  width: 201px; padding: 28px 16px 23px;
  border: 0; border-radius: 0;
  background: var(--b-sidebar); color: #e7e1d1;
  overflow-y: auto; scrollbar-width: thin;
}
.direction-b .app-rail .brand { gap: 10px; padding: 0 8px; color: #efe9dc; }
.direction-b .brand-mark { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 9px; background: #d6b36d; color: var(--b-sidebar); font-size: 22px; font-weight: 550; line-height: 34px; }
.direction-b .direction-b-brand-copy { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.direction-b .brand strong { font-size: 12px; font-weight: 500; letter-spacing: 1.65px; line-height: 1.5; }
.direction-b .direction-b-brand-caption { color: #a59c87; font-size: 12px; font-weight: 400; letter-spacing: 0; line-height: 1.5; }
.direction-b .rail-project { display: none; }
.direction-b .app-rail nav { display: flex; flex-direction: column; gap: 5px; margin-top: 31px; }
.direction-b .app-rail nav a { display: flex; align-items: center; min-height: 44px; padding: 9px 12px; border-radius: 7px; color: #aaa28f; font-size: 18px; line-height: 1.5; }
.direction-b .app-rail nav a:hover { background: #242218; color: #efe6d2; }
.direction-b .app-rail nav a.active, .direction-b .app-rail nav a[aria-current="page"] { background: #302b1d; color: #eee3cc; font-weight: 600; }
.direction-b .app-rail nav a.active::before { content: ""; width: 6px; height: 6px; flex: 0 0 6px; margin-right: 9px; border-radius: 50%; background: #d6b36d; }
.direction-b .app-rail nav svg { display: none; }
.direction-b .direction-b-nav-group, .direction-b .nav-group-label, .direction-b .nav-section-label { margin: 22px 12px 1px; color: #8e8672; font-size: 12px; font-weight: 400; line-height: 1.5; }
.direction-b .direction-b-nav-group:first-child { margin-top: 0; }
.direction-b .nav-dot { background: #b9ae93; }
.direction-b .rail-foot { gap: 6px; padding: 19px 11px 0; border-top-color: #302c21; color: #9e9580; font-size: 12px; line-height: 1.7; }
.direction-b .rail-foot small { color: #817965; font-size: 11px; line-height: 1.7; }
.direction-b .rail-foot a { padding-left: 0; margin-top: 7px; color: #b7ad97; font-size: 12px; }
.direction-b .rail-foot a:hover { color: #efe1c3; }
.direction-b .live-dot { background: #ad9a71; }
.direction-b .app-body { margin-left: 201px; min-width: 0; min-height: 100dvh; background: var(--b-canvas); }
.direction-b .topbar { height: 76px; min-height: 76px; padding: 0 32px; border: 0; background: var(--b-canvas); color: #28261f; font-size: 14px; }
.direction-b .topbar > div { gap: 15px; }
.direction-b .location, .direction-b .local-tag { color: #756f63; font-size: 13px; }
.direction-b .local-tag { padding: 5px 10px; border-color: var(--b-line); border-radius: 7px; background: transparent; }
.direction-b .app-body > main { width: 100%; max-width: none; min-width: 0; margin: 0; padding: 6px 32px 32px; min-height: calc(100dvh - 76px); }
.direction-b .app-footer { display: none; }
.direction-b .page-heading { align-items: center; gap: 20px; min-height: 44px; margin-bottom: 18px; }
.direction-b .page-heading h1 { display: none; }
.direction-b .page-heading p { margin: 0; color: var(--b-muted); font-size: 14px; line-height: 1.8; }
.direction-b .page-counter { font-size: 14px; }
.direction-b .batch-bar { padding: 18px 24px; margin-bottom: 16px; border: 0; border-radius: var(--b-radius); background: #fff; }
.direction-b .batch-bar strong { font-size: 16px; }
.direction-b .batch-bar span, .direction-b .batch-bar > p { font-size: 13px; }
.direction-b .batch-actions { gap: 10px 15px; }
.direction-b .batch-actions select { font-size: 14px; border-color: var(--b-line); }
.direction-b .button { min-height: 42px; padding: 9px 16px; border-color: #dfdcd4; border-radius: 8px; background: transparent; color: var(--b-ink); font-size: 14px; font-weight: 500; line-height: 1.5; }
.direction-b .button:hover { background: #eae7df; }
.direction-b .button.primary { border-color: var(--b-sidebar); background: var(--b-sidebar); color: #f5e9cf; }
.direction-b .button.primary:hover { border-color: #302c22; background: #302c22; }
.direction-b .text-button { color: var(--b-ink); font-size: 14px; line-height: 1.6; }
.direction-b .field { gap: 7px; font-size: 14px; }
.direction-b .field input, .direction-b .field select, .direction-b .field textarea,
.direction-b input.field, .direction-b select.field { min-height: 40px; padding: 9px 12px; border: 1px solid #dfdcd4; border-radius: 8px; background: #fff; color: var(--b-ink); font-size: 15px; line-height: 1.65; }
.direction-b .field input::placeholder, .direction-b .field textarea::placeholder { color: #958e81; }
.direction-b input[type="checkbox"], .direction-b input[type="radio"] { accent-color: #181713; }
.direction-b .badge { padding: 4px 8px; border-radius: 20px; background: var(--b-soft); color: #706b60; font-size: 12px; }
.direction-b .badge.green { color: var(--b-blue); background: #edf4fb; }
.direction-b .badge.amber { color: #8e733a; background: #f6f0e1; }
.direction-b .badge.gray { color: #726c61; background: #f3f2ef; }
.direction-b .geo-badge-danger { color: var(--b-red); background: #fcebea; }
.direction-b .source-note { padding: 14px 16px; border-left: 2px solid #cec5af; border-radius: 0 8px 8px 0; background: #f5f3ed; color: #6e6655; font-size: 14px; line-height: 1.85; }
.direction-b .source-note strong { color: #3e392e; }
.direction-b .detail-body { color: #353127; font-size: 16px; line-height: 1.95; }
.direction-b .source-metadata { color: var(--b-muted); font-size: 13px; line-height: 1.85; }
.direction-b .source-metadata strong, .direction-b .source-detail-top > span:first-child { font-size: 13px; }
.direction-b .source-link, .direction-b details a { color: #50472f; font-size: 13px; }
.direction-b .empty { color: var(--b-muted); font-size: 15px; }
.direction-b .empty p { font-size: 14px; }
.direction-b .toast { border-radius: 9px; background: var(--b-sidebar); box-shadow: 0 8px 25px #15140f18; font-size: 14px; }

/* Knowledge: directory, broad results, and reading surface share one height. */
.direction-b .workspace-grid.library-grid { grid-template-columns: 164px minmax(310px, .86fr) minmax(0, 1.2fr); gap: 16px; align-items: stretch; height: var(--b-grid-height, calc(100dvh - 215px)); min-height: 300px; }
.direction-b .library-sidebar, .direction-b .result-column, .direction-b .detail-column, .direction-b .library-price-main { min-width: 0; min-height: 0; border: 0; border-radius: var(--b-radius); background: #fff; }
.direction-b .library-sidebar { position: static; height: 100%; padding: 15px 12px; overflow: auto; scrollbar-width: thin; }
.direction-b .library-sidebar-head { padding: 10px 10px 13px; }
.direction-b .library-sidebar-head h2 { font-size: 17px; }
.direction-b .library-sidebar-head p, .direction-b .library-sidebar-note, .direction-b .library-sidebar-note p { font-size: 12px; }
.direction-b .library-sidebar button { min-height: 40px; padding: 10px; color: var(--b-muted); font-size: 14px; }
.direction-b .library-sidebar button:hover { background: var(--b-soft); }
.direction-b .library-sidebar button.active { background: var(--b-selection); color: var(--b-ink); }
.direction-b .result-column { display: flex; flex-direction: column; height: 100%; padding: 0; overflow: hidden; }
.direction-b .result-column > .section-head { flex: none; margin: 0; padding: 22px 22px 13px; }
.direction-b .result-column h2 { font-size: 20px; }
.direction-b .library-search { flex: none; padding: 8px 20px 12px; }
.direction-b .library-category-select, .direction-b .library-categories { flex: none; padding: 0 20px 14px; }
.direction-b .result-column .library-summary { flex: none; padding: 0 20px 12px; font-size: 13px; }
.direction-b .library-result-list, .direction-b .library-results, .direction-b .kb-results, .direction-b .result-list, .direction-b .library-unit-cards { flex: 1; min-height: 0; max-height: none; padding: 0 9px 12px; overflow: auto; scrollbar-width: thin; }
.direction-b .list-item { padding: 14px 12px; margin-bottom: 2px; border: 0; border-radius: 7px; }
.direction-b .list-item:hover { background: var(--b-soft); }
.direction-b .list-item.active { background: var(--b-selection); border-color: transparent; }
.direction-b .list-item-title { color: var(--b-ink); font-size: 15px; line-height: 1.75; }
.direction-b .list-item.active .list-item-title { color: var(--b-ink); }
.direction-b .list-item-meta { font-size: 12px; }
.direction-b .detail-column { height: 100%; padding: 24px; overflow: auto; scrollbar-width: thin; }
.direction-b .kb-detail-head { position: sticky; top: -24px; z-index: 2; margin: -24px -24px 20px; padding: 24px; border-bottom: 1px solid var(--b-line); background: #fff; }
.direction-b .filter-chip { padding: 7px 11px; border-color: var(--b-line); border-radius: 7px; background: transparent; color: #676052; font-size: 13px; }
.direction-b .filter-chip.active, .direction-b .related-choice.active { background: var(--b-selection); color: var(--b-ink); border-color: #dcd4c0; }
.direction-b .library-price-main { display: flex; flex-direction: column; height: 100%; padding: 24px; overflow: hidden; }
.direction-b .library-price-main .table-wrap { flex: 1; min-height: 0; max-height: none; }
.direction-b .library-price-filters { flex: none; }
.direction-b .data-table { font-size: 14px; }
.direction-b .data-table th { background: #f3f2ef; color: #746c60; }
.direction-b .data-table tbody tr:hover { background: #f7f5ef; }
.direction-b .library-price-context, .direction-b .library-table-note, .direction-b .library-source-block { font-size: 13px; }

/* Content and reports keep actions and headings separate from long content. */
.direction-b .content-context { padding: 16px 22px; margin-bottom: 16px; border: 0; border-radius: var(--b-radius); background: #fff; }
.direction-b .content-context > span { font-size: 13px; }
.direction-b .content-context strong { font-size: 17px; }
.direction-b .production-grid { grid-template-columns: minmax(330px, .8fr) minmax(0, 1.2fr); gap: 16px; align-items: stretch; height: var(--b-grid-height, calc(100dvh - 290px)); min-height: 320px; }
.direction-b .production-source, .direction-b .draft-panel { height: 100%; min-height: 0; padding: 24px; border: 0; border-radius: var(--b-radius); background: #fff; }
.direction-b .production-source { overflow: auto; scrollbar-width: thin; }
.direction-b .production-source > .panel-heading { position: sticky; z-index: 1; top: -24px; margin: -24px -24px 20px; padding: 24px 24px 18px; background: #fff; border-bottom: 1px solid var(--b-line); }
.direction-b .draft-panel { display: flex; flex-direction: column; overflow: hidden; }
.direction-b .draft-panel > .panel-heading, .direction-b .draft-toolbar, .direction-b .draft-panel > .text-muted, .direction-b .draft-bottom { flex: none; }
.direction-b .draft-panel > .field { flex: 1; min-height: 0; }
.direction-b .draft-panel textarea { height: 100%; min-height: 180px; resize: none; font-size: 16px; line-height: 1.9; }
.direction-b .draft-bottom { flex-wrap: wrap; gap: 12px; padding-top: 15px; }
.direction-b .report-summary { gap: 0; border: 0; border-radius: var(--b-radius); background: #fff; margin-bottom: 16px; }
.direction-b .report-summary > div { gap: 8px; padding: 20px 24px; background: transparent; border-right: 1px solid var(--b-line); }
.direction-b .report-summary > div:last-child { border-right: 0; }
.direction-b .report-summary strong { font-size: 32px; }
.direction-b .report-summary span { font-size: 13px; }
.direction-b .report-grid { gap: 16px; height: var(--b-grid-height, calc(100dvh - 335px)); min-height: 340px; align-items: stretch; }
.direction-b .retest-form, .direction-b .report-records { height: 100%; min-height: 0; padding: 24px; border: 0; border-radius: var(--b-radius); background: #fff; overflow: auto; scrollbar-width: thin; }
.direction-b .retest-form > .section-head, .direction-b .report-records > .section-head { position: sticky; top: -24px; z-index: 2; margin: -24px -24px 20px; padding: 24px 24px 15px; border-bottom: 1px solid var(--b-line); background: #fff; }
.direction-b .retest-record h3 { font-size: 17px; }
.direction-b .retest-record p { font-size: 14px; }
.direction-b .section-head h2, .direction-b .panel-heading h2 { font-size: 20px; }

/* Execution/workflow: shared bright panels; a colored fact state is never a CTA. */
.direction-b .geo-status { padding: 12px 17px; border: 0; border-radius: 10px; background: #fff; color: #726b5e; font-size: 14px; }
.direction-b .geo-status.is-error, .direction-b .geo-verification.is-error { color: var(--b-red); background: #fff2f1; }
.direction-b .geo-stats { margin: 16px 0; border: 0; border-radius: var(--b-radius); background: #fff; }
.direction-b .geo-stats > div { padding: 19px 24px; }
.direction-b .geo-stats strong { font-size: 32px; }
.direction-b .geo-stats span { font-size: 13px; }
.direction-b .geo-tabs { gap: 26px; margin: 18px 0 16px; }
.direction-b .geo-tabs button { padding: 10px 0 12px; color: #827a6a; font-size: 15px; }
.direction-b .geo-tabs button.active { color: var(--b-ink); border-color: #b79b66; }
.direction-b .geo-grid { grid-template-columns: minmax(340px, .86fr) minmax(0, 1.2fr); gap: 16px; align-items: stretch; height: var(--b-grid-height, calc(100dvh - 380px)); min-height: 340px; }
.direction-b .geo-panel { height: 100%; min-height: 0; padding: 24px; border: 0; border-radius: var(--b-radius); background: #fff; overflow: auto; scrollbar-width: thin; }
.direction-b .geo-panel > .section-head { position: sticky; top: -24px; z-index: 1; margin: -24px -24px 18px; padding: 24px 24px 15px; border-bottom: 1px solid var(--b-line); background: #fff; }
.direction-b .geo-panel .section-head h2 { font-size: 20px; }
.direction-b .geo-note, .direction-b .geo-form .field, .direction-b .geo-check, .direction-b .geo-verification, .direction-b .geo-publish-steps { font-size: 14px; line-height: 1.85; }
.direction-b .geo-workflow .field input, .direction-b .geo-workflow .field textarea, .direction-b .geo-workflow .field select { font-size: 15px; }
.direction-b .geo-record-item { padding: 14px 10px; border-color: transparent; border-bottom-color: var(--b-line); border-radius: 7px; }
.direction-b .geo-record-item:hover { background: var(--b-soft); }
.direction-b .geo-record-item.active { background: var(--b-selection); border-color: #e5decd; }
.direction-b .geo-record-item strong { font-size: 16px; }
.direction-b .geo-record-item > span, .direction-b .geo-record-item small, .direction-b .geo-record-meta, .direction-b .geo-artifacts a, .direction-b .geo-history, .direction-b .geo-link, .direction-b .geo-url, .direction-b .geo-platform-links a { font-size: 13px; }
.direction-b .geo-record-meta strong, .direction-b .geo-decision h3, .direction-b .geo-change-detail h3, .direction-b .geo-import h3 { font-size: 16px; }
.direction-b .geo-record-list, .direction-b .geo-revision-list { max-height: none; overflow: visible; }
.direction-b .geo-saved-text, .direction-b .geo-diff > div, .direction-b .geo-verification { background: var(--b-soft); color: #6e6556; }
.direction-b .geo-saved-text, .direction-b .geo-diff p, .direction-b .geo-publication h3 { font-size: 14px; }
.direction-b .geo-diff > div:last-child { background: #edf4fb; }

/* Assets: all three panels remain on the same full-width work surface. */
body.direction-b.assets-app { --asset-dark: #15140f; --asset-gold: #8f7744; --asset-soft: var(--b-selection); --asset-red: var(--b-red); --asset-green: var(--b-blue); }
.direction-b.assets-app .app-body { display: flex; flex-direction: column; height: 100dvh; min-height: 0; }
.direction-b.assets-app .topbar { flex: none; }
.direction-b.assets-app main { display: flex; flex-direction: column; flex: 1; min-height: 0; min-width: 0; max-width: none; padding: 0 32px 28px; overflow: hidden; }
.direction-b .asset-page-heading { flex: none; min-height: 28px; gap: 20px; margin-bottom: 8px; }
.direction-b .asset-page-heading h1 { display: none; }
.direction-b .asset-page-heading p { margin: 0; font-size: 14px; line-height: 1.7; }
.direction-b .asset-library-count { max-width: none; font-size: 12px; line-height: 1.7; }
.direction-b .knowledge-source-links { flex: none; gap: 16px; margin: 0 0 8px; color: #6e634b; font-size: 12px; }
.direction-b .trial-boundary { flex: none; gap: 12px; margin: 0; padding: 10px 14px; border: 0; border-radius: 9px; background: #e5e1d8; color: #746b58; font-size: 12px; line-height: 1.75; }
.direction-b .trial-boundary strong { color: #5d5036; font-weight: 500; }
.direction-b .trial-boundary span { max-width: none; }
.direction-b .asset-tabs { flex: none; gap: 27px; margin: 10px 0 16px; }
.direction-b .asset-tabs button { min-height: 40px; padding: 7px 0 10px; font-size: 15px; }
.direction-b .asset-tabs button[aria-selected="true"] { border-color: #b79b66; color: var(--b-ink); }
.direction-b .server-message { flex: none; padding: 10px 14px; margin-bottom: 10px; background: #fff3f1; border-color: #f0d0ca; color: var(--b-red); font-size: 13px; }
.direction-b .action-status { flex: none; color: var(--b-blue); font-size: 13px; }
.direction-b #panel-assets { flex: 1; min-width: 0; min-height: 0; }
.direction-b .asset-workspace { grid-template-columns: minmax(280px, .72fr) minmax(0, 1.38fr) minmax(300px, .86fr); gap: 16px; height: 100%; min-height: 0; align-items: stretch; }
.direction-b .asset-list-panel, .direction-b .asset-stage, .direction-b .asset-review { display: flex; flex-direction: column; position: static; grid-column: auto; grid-row: auto; height: 100%; min-width: 0; min-height: 0; padding: 0; border: 0; border-radius: var(--b-radius); background: #fff; overflow: hidden; }
.direction-b .asset-panel-heading { flex: none; min-height: 65px; margin: 0; padding: 20px 20px 13px; }
.direction-b .asset-panel-heading h2 { font-size: 19px; }
.direction-b .asset-filters { flex: none; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 0 20px 8px; }
.direction-b .asset-filters .field:first-child { grid-column: 1 / -1; }
.direction-b .asset-filters .field { font-size: 12px; }
.direction-b .asset-filters input, .direction-b .asset-filters select { min-height: 37px; padding: 7px 9px; border-color: var(--b-line); font-size: 13px; }
.direction-b .asset-result-count { flex: none; margin: 8px 20px 10px; color: var(--b-muted); font-size: 12px; }
.direction-b .asset-results { flex: 1; min-height: 0; max-height: none; padding: 0 8px 12px; overflow: auto; }
.direction-b .asset-choice { grid-template-columns: 65px minmax(0, 1fr); gap: 10px; padding: 12px 10px; border: 0; border-radius: 7px; }
.direction-b .asset-choice:hover { background: var(--b-soft); }
.direction-b .asset-choice.active { background: var(--b-selection); }
.direction-b .asset-choice img { width: 65px; height: 49px; border-radius: 4px; }
.direction-b .asset-choice strong { font-size: 15px; line-height: 1.55; }
.direction-b .asset-choice small, .direction-b .asset-choice .badge { font-size: 11px; }
.direction-b .asset-stage-header { flex: none; align-items: center; margin: 0; padding: 20px 22px 15px; border-bottom: 1px solid var(--b-line); }
.direction-b .asset-stage-header h2 { font-size: 20px; }
.direction-b .asset-stage-header p { font-size: 12px; }
.direction-b .asset-stage > .segment-controls { flex: none; margin: 0; padding: 12px 22px; border-bottom: 1px solid var(--b-line); }
.direction-b .direction-b-panel-scroll { flex: 1; min-height: 0; padding: 20px 22px 24px; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.direction-b .media-frame { border: 0; border-radius: 9px; background: #1b1a16; }
.direction-b .media-frame video, .direction-b .media-frame > .asset-still { max-height: 390px; }
.direction-b .segment-controls .button { font-size: 13px; min-height: 36px; padding: 6px 10px; }
.direction-b .segment-time, .direction-b .segment-controls a { color: #6f654f; font-size: 12px; }
.direction-b .asset-description { margin-top: 16px; padding: 0; border: 0; border-radius: 0; }
.direction-b .asset-description h3 { margin-bottom: 8px; font-size: 16px; }
.direction-b .asset-description p { font-size: 16px; line-height: 1.85; }
.direction-b .asset-elements span { border-color: var(--b-line); color: #797162; font-size: 12px; }
.direction-b .frame-reference { grid-template-columns: 114px minmax(0, 1fr); }
.direction-b .frame-reference img { width: 114px; height: 74px; background: var(--b-soft); }
.direction-b .frame-reference p, .direction-b .frame-reference strong, .direction-b .asset-source-path { color: var(--b-muted); font-size: 12px; }
.direction-b .asset-review > h2 { flex: none; margin: 0; padding: 21px 22px 16px; border-bottom: 1px solid var(--b-line); font-size: 19px; }
.direction-b .review-statuses > div { font-size: 13px; }
.direction-b .review-section { margin-top: 20px; }
.direction-b .review-section h3, .direction-b .review-form h3 { font-size: 16px; }
.direction-b .review-section h4 { margin: 15px 0 7px; font-size: 14px; }
.direction-b .review-section p, .direction-b .review-section li, .direction-b .review-check { font-size: 14px; line-height: 1.85; }
.direction-b .review-metadata > div { grid-template-columns: 80px minmax(0, 1fr); }
.direction-b .review-metadata dt, .direction-b .review-metadata dd { font-size: 13px; }
.direction-b .production-gaps, .direction-b .production-gaps.is-available { border-left-color: #c3b48b; background: #f5f2e9; }
.direction-b .production-gaps.is-available { border-left-color: var(--b-blue); background: #edf4fb; }
.direction-b .production-gaps h3 { color: #635332; }
.direction-b .review-form { margin-top: 20px; padding-top: 20px; border-radius: 0; background: transparent; }
.direction-b .review-form .field { font-size: 13px; }
.direction-b .review-form input, .direction-b .review-form select, .direction-b .review-form textarea { border-color: var(--b-line); background: #fff; font-size: 14px; }
.direction-b .review-save-note, .direction-b .approve-box > p, .direction-b .disable-box summary, .direction-b .date-conflict { font-size: 12px; }
.direction-b .disable-box .button { border-color: #e4d1c9; color: var(--b-red); background: #fff; }
.direction-b .asset-empty, .direction-b .job-empty p { font-size: 14px; }
.direction-b #panel-video { flex: 1; min-height: 0; overflow: auto; padding-right: 4px; }
.direction-b .voice-connection { margin-bottom: 17px; padding: 14px 0 18px; }
.direction-b .voice-connection p, .direction-b .voice-connection-actions, .direction-b .voice-task-note, .direction-b .voice-task-error { font-size: 14px; }
.direction-b .voice-task, .direction-b .job-form, .direction-b .job-diagnostics, .direction-b .shot-row { border: 0; border-radius: var(--b-radius); background: #fff; }
.direction-b .trial-job-heading p, .direction-b .job-form-note, .direction-b .job-summary p, .direction-b .shots-title, .direction-b .shot-label, .direction-b .shot-decision, .direction-b .shot-qualifiers ul { font-size: 13px; }
.direction-b .fact-original { font-size: 16px; line-height: 1.9; }
.direction-b .shot-phrase { font-size: 21px; }
.direction-b .candidate { border-color: var(--b-line); border-radius: 9px; background: #fff; }
.direction-b .candidate-body p { font-size: 14px; }
.direction-b .candidate-verdict, .direction-b .candidate-block, .direction-b .candidate-production, .direction-b .candidate-top > span { font-size: 12px; }
.direction-b .production-panel { display: flex; flex-direction: column; flex: 1; min-height: 0; overflow: hidden; }
.direction-b .production-frame { flex: 1; height: 100% !important; min-height: 0; border: 0; border-radius: var(--b-radius); background: var(--b-canvas); }
.direction-b .production-frame-help { flex: none; margin: 7px 0 0; color: var(--b-muted); font-size: 12px; }
.direction-b .production-frame-help a { color: var(--b-ink); }

/* The original home keeps its controls, with a true dark rail and bright main. */
body.direction-b.home-godly, body.direction-b:has(.shell) { background: var(--b-canvas) !important; color: var(--b-ink); color-scheme: light; }
body.direction-b.home-godly::before, body.direction-b.home-godly::after { display: none !important; }
.direction-b .shell, .direction-b .shell.theme-godly, .direction-b .shell.theme-godly.is-module-view { display: grid !important; grid-template-columns: 201px minmax(0, 1fr) !important; min-height: 100dvh; background: var(--b-canvas) !important; }
.direction-b .shell.theme-godly { --ink: #181713; --muted: #716d63; --faint: #918773; --line: #e2dfd8; --line-strong: #d0c7b4; --panel: #fff; --panel-2: #f5f4f1; --blue: #15140f; --cyan: #15140f; --gold: #b18c43; --green: #1d6fb7; --red: #d8332c; --shadow: none; --cut: none; }
.direction-b .shell .rail { display: flex !important; flex-direction: column; position: sticky; top: 0; width: 201px; height: 100dvh; padding: 28px 16px 22px; gap: 25px; border: 0; border-radius: 0; background: var(--b-sidebar) !important; color: #d8cfba; overflow: auto; }
.direction-b .shell .rail .brand { display: flex; align-items: center; gap: 10px; padding: 0 8px; }
.direction-b .shell .rail .mark { display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 34px; border: 0; border-radius: 9px; clip-path: none; background: #d6b36d; color: #15140f; font-size: 14px; font-weight: 550; }
.direction-b .shell .rail .brand h1 { margin: 0; color: #eee4cd; font-family: var(--sans); font-size: 12px; letter-spacing: 1.5px; line-height: 1.6; }
.direction-b .shell .rail .brand .label { color: #a79c84; font-size: 11px; font-weight: 400; letter-spacing: 0; }
.direction-b .shell .project-ledger { border-top-color: #302c21; padding-top: 16px; }
.direction-b .shell .project-ledger strong { color: #ccc0a4; font-size: 12px; }
.direction-b .shell .project-ledger p { color: #8f856f; font-size: 12px; line-height: 1.8; }
.direction-b .shell .stage-switcher { display: flex; flex-direction: column; gap: 10px; min-height: 0; }
.direction-b .shell .stage-top { display: grid; grid-template-columns: 25px minmax(0, 1fr) 25px; padding: 11px 0; gap: 7px; min-height: 70px; border-color: #302c21; background: transparent !important; }
.direction-b .shell .stage-copy strong { color: #eadfc6; font-size: 14px; }
.direction-b .shell .stage-copy .label, .direction-b .shell .stage-copy small { color: #95886e; font-size: 11px; }
.direction-b .shell .stage-arrow { width: 25px; height: 30px; border-color: #4b4230; border-radius: 5px; clip-path: none; background: transparent; color: #d4c7ab; }
.direction-b .shell .stage-modules { display: grid; gap: 7px; overflow: visible; }
.direction-b .shell .module, .direction-b .shell .module-card { border-color: #352f22; border-radius: 7px; clip-path: none; background: transparent; color: #b8ab8e; box-shadow: none; }
.direction-b .shell .module.is-active, .direction-b .shell .module-card.is-active { background: #302b1d; border-color: #302b1d; color: #efe3c7; }
.direction-b .shell .module strong, .direction-b .shell .module-card strong { color: inherit; font-size: 18px; line-height: 1.5; }
.direction-b .shell .module small, .direction-b .shell .module-card small { color: #978b73; font-size: 11px; }
.direction-b .shell .module-card { display: grid; grid-template-columns: 21px minmax(0, 1fr); gap: 8px; padding: 12px 9px; }
.direction-b .shell .module-card > span:first-child { color: #a99a77; font-size: 11px; }
.direction-b .shell .module-card i { display: none; }
.direction-b .shell .stage-dot { background: #49402c; border-color: #49402c; }
.direction-b .shell .stage-dot.is-active { background: #c4a363; border-color: #c4a363; }
.direction-b .shell .rail-status { margin-top: auto; border-color: #302c21; padding: 16px 0 0; background: transparent; color: #9f947c; font-size: 12px; }
.direction-b .shell .rail-status strong { color: #c1b394; font-size: 12px; }
.direction-b .shell .main { min-width: 0; padding: 0 32px 32px !important; background: var(--b-canvas) !important; }
.direction-b .shell .official-header { width: 100%; max-width: none; margin: 0 0 20px; padding: 20px 0 12px; border: 0; border-radius: 0; background: var(--b-canvas) !important; box-shadow: none !important; backdrop-filter: none; color: var(--b-ink); }
.direction-b .shell .official-topline { grid-template-columns: minmax(200px, 1fr) auto; gap: 15px; }
.direction-b .shell .official-mark, .direction-b .shell #viewTitle, .direction-b .shell .roadshow-value { display: none; }
.direction-b .shell .crumb, .direction-b .shell .crumb b { color: var(--b-ink); font-size: 14px; }
.direction-b .shell .crumb span { color: #aaa08a; }
.direction-b .shell .project-picker summary { margin-top: 5px; color: #7b715d; font-size: 12px; }
.direction-b .shell .cmd { min-height: 40px; padding: 8px 12px; border: 1px solid var(--b-line); border-radius: 8px; clip-path: none; background: transparent; color: var(--b-ink); box-shadow: none; font-size: 13px; font-weight: 450; }
.direction-b .shell .cmd.primary { border-color: var(--b-sidebar); background: var(--b-sidebar); color: #f3e5c7; }
.direction-b .shell .toolbar-status b, .direction-b .shell .toolbar-status span { color: #756b56; font-size: 11px; }
.direction-b .shell .product-nav { padding: 8px 0 0; border-color: var(--b-line); background: transparent; }
.direction-b .shell .product-nav-item { min-height: 39px; padding: 8px 12px; border: 0; border-radius: 7px; background: transparent; color: #837961; }
.direction-b .shell .product-nav-item strong { color: #615742; font-size: 14px; }
.direction-b .shell .product-nav-item span { color: #94866a; font-size: 11px; }
.direction-b .shell .product-nav-item.is-active { background: #e5e0d4; color: var(--b-ink); }
.direction-b .shell .mega-panel, .direction-b .shell .project-menu { border-color: var(--b-line); border-radius: 12px; background: #fff; color: var(--b-ink); box-shadow: 0 15px 40px #15140f1a; }
.direction-b .shell .mega-link, .direction-b .shell .mega-link b, .direction-b .shell .mega-group h3 { color: var(--b-ink); }
.direction-b .shell .mega-link small, .direction-b .shell .mega-link em { color: var(--b-muted); }
.direction-b .shell .workspace { width: 100%; max-width: none; padding: 0 !important; margin: 0 !important; background: transparent !important; }
.direction-b .shell .signal-home { max-width: none; margin: 0; padding: 0; }
.direction-b .shell .signal-hero { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr); gap: 24px; align-items: stretch; min-height: 0 !important; padding: 0 !important; background: transparent !important; }
.direction-b .shell .signal-copy { padding: 28px; border: 0; border-radius: var(--b-radius); background: #fff; color: var(--b-ink); }
.direction-b .shell .signal-kicker { color: #8d8168; font-size: 12px; }
.direction-b .shell .hero-project-name { margin: 12px 0 20px; color: var(--b-ink) !important; font-family: var(--sans); font-size: 35px !important; line-height: 1.3; letter-spacing: -1px; }
.direction-b .shell .hero-project-name span { display: inline !important; color: var(--b-ink) !important; -webkit-text-fill-color: var(--b-ink); font-size: inherit !important; line-height: inherit !important; letter-spacing: inherit; text-shadow: none; }
.direction-b .shell .signal-copy p { color: #756d5e !important; font-size: 15px !important; }
.direction-b .shell .home-audit-eyebrow, .direction-b .shell .workflow-panel-head { color: #817457; font-size: 13px; }
.direction-b .shell .home-audit-focus { padding: 0; border: 0; background: transparent; }
.direction-b .shell .home-audit-action { min-height: 44px; padding: 10px 14px; border: 0; border-radius: 8px; background: var(--b-sidebar); color: #f3e5c7; font-size: 14px; }
.direction-b .shell .workflow-panel { margin-top: 24px; padding: 18px 0 0; border: 0; border-top: 1px solid var(--b-line); border-radius: 0; background: transparent; }
.direction-b .shell .workflow-steps { gap: 7px; }
.direction-b .shell .workflow-step { padding: 10px; border-color: var(--b-line); border-radius: 8px; background: #f7f6f3; color: var(--b-ink); }
.direction-b .shell .workflow-step strong { color: var(--b-ink); font-size: 13px; }
.direction-b .shell .workflow-step small, .direction-b .shell .workflow-step > span { color: #887c64; font-size: 11px; }
.direction-b .shell .command-surface { border: 0; border-radius: var(--b-radius); background: #fff !important; box-shadow: none !important; clip-path: none; }
.direction-b .shell .command-surface::before, .direction-b .shell .command-surface::after { display: none; }
.direction-b .shell .surface-bar { padding: 16px 22px; border-color: var(--b-line); border-radius: var(--b-radius) var(--b-radius) 0 0; background: transparent; color: var(--b-muted); }
.direction-b .shell .surface-title { color: #7a6d54; font-size: 12px; }
.direction-b #dashboard .flow-overview-body { padding: 22px; }
.direction-b #dashboard .flow-overview-heading h4 { color: var(--b-ink); font-size: 24px; }
.direction-b #dashboard .flow-overview-heading > span { color: #b8a575; font-size: 29px; }
.direction-b #dashboard .flow-capability, .direction-b #dashboard .flow-capability.is-dark { min-height: 149px; padding: 17px; border: 1px solid var(--b-line); border-radius: 10px; background: #f7f6f2; color: var(--b-ink); }
.direction-b #dashboard .flow-capability:hover, .direction-b #dashboard .flow-capability.is-dark:hover { border-color: #c0b18e; background: var(--b-selection); }
.direction-b #dashboard .flow-capability > strong, .direction-b #dashboard .flow-capability.is-dark > strong, .direction-b #dashboard .flow-capability-foot b, .direction-b #dashboard .is-dark .flow-capability-foot b { color: var(--b-ink); font-size: 17px; }
.direction-b #dashboard .flow-capability-top, .direction-b #dashboard .flow-capability > small, .direction-b #dashboard .flow-capability-foot, .direction-b #dashboard .is-dark .flow-capability-top, .direction-b #dashboard .is-dark .flow-capability-foot, .direction-b #dashboard .flow-capability.is-dark > small { color: #82745a; font-size: 12px; }
.direction-b #dashboard .flow-capability-foot b { font-size: 24px; }
.direction-b #dashboard .flow-connections { gap: 9px; }
.direction-b #dashboard .flow-connection { border-color: var(--b-line); background: #fff; border-radius: 7px; }
.direction-b #dashboard .flow-connection strong, .direction-b #dashboard .flow-connection-head strong { color: var(--b-ink); font-size: 12px; }
.direction-b #dashboard .flow-connection small, .direction-b #dashboard .flow-connection-state, .direction-b #dashboard .flow-connection-head span { color: #84775d; font-size: 11px; }
.direction-b #dashboard .flow-section, .direction-b #dashboard .flow-workspace, .direction-b #dashboard .flow-draft-aside, .direction-b #dashboard .flow-direct-form, .direction-b #dashboard .flow-paper, .direction-b #dashboard .flow-report-text { border-color: var(--b-line); border-radius: var(--b-radius); background: #fff; box-shadow: none; color: var(--b-ink); }
.direction-b #dashboard .flow-section h3, .direction-b #dashboard .flow-section h4, .direction-b #dashboard .flow-workspace-intro h3, .direction-b #dashboard .flow-section-heading h3, .direction-b #dashboard .flow-draft-aside h4, .direction-b #dashboard .flow-report-panel h4 { color: var(--b-ink); }
.direction-b #dashboard .flow-section p, .direction-b #dashboard .flow-section label, .direction-b #dashboard .flow-meta, .direction-b #dashboard .flow-local-mode, .direction-b #dashboard .flow-local-footer, .direction-b #dashboard .flow-report-panel > p:not(.flow-eyebrow):not(.flow-meta) { color: var(--b-muted); font-size: 14px; }
.direction-b #dashboard .flow-section input, .direction-b #dashboard .flow-section select, .direction-b #dashboard .flow-section textarea { border-color: var(--b-line); border-radius: 8px; background: #fff; color: var(--b-ink); font-size: 15px; }
.direction-b #dashboard .flow-button { border-color: var(--b-line); background: transparent; color: var(--b-ink); font-size: 14px; }
.direction-b #dashboard .flow-button.is-primary { border-color: var(--b-sidebar); background: var(--b-sidebar); color: #f4e4c3; }
.direction-b #dashboard .flow-text-button { color: #6d6044; font-size: 13px; }
.direction-b #dashboard .flow-original-text, .direction-b #dashboard .flow-source-content, .direction-b #dashboard textarea.flow-draft-editor, .direction-b #dashboard .flow-report-text { color: #353127; font-size: 16px; line-height: 1.9; }
.direction-b #dashboard .flow-source-item { border-color: var(--b-line); background: transparent; color: var(--b-ink); }
.direction-b #dashboard .flow-source-item.is-selected { background: var(--b-selection); border-color: #d0c5a9; }
.direction-b #dashboard .flow-source-title, .direction-b #dashboard #flowDraftSources strong { color: var(--b-ink); font-size: 14px; }
.direction-b #dashboard .flow-context { border-left-color: #b9a573; background: #f4f1e8; color: #6d6044; }
.direction-b #dashboard .flow-journey button { border-color: var(--b-line); background: #fff; color: var(--b-ink); }
.direction-b #dashboard .flow-journey button.is-active { background: var(--b-selection); }
.direction-b #dashboard .is-error, .direction-b #dashboard .flow-action-row .is-error { color: var(--b-red); }
.direction-b .cover-project-overview { margin: 24px 0 0; padding: 27px; border: 0; border-radius: var(--b-radius); background: #fff; color: var(--b-ink); font-family: var(--sans); }
.direction-b .cover-overview-heading h3 { font-size: 25px; }
.direction-b .cover-overview-heading > div > span { font-size: 14px; }
.direction-b .cover-project-overview .cover-outline-link { border-color: var(--b-line); background: transparent; color: var(--b-ink); font-size: 14px; }
.direction-b .cover-data-strip, .direction-b .cover-coverage { border-color: var(--b-line); border-radius: 10px; background: #f8f7f4; }
.direction-b .cover-data-strip p, .direction-b .cover-data-strip > div > span, .direction-b .cover-topic p, .direction-b .cover-topic > div > span, .direction-b .cover-project-overview .cover-register-note, .direction-b .cover-unit-heading p, .direction-b .cover-unit-links span { color: #827761; font-size: 12px; }
.direction-b .cover-topic strong, .direction-b .cover-unit-heading h4 { color: var(--b-ink); font-size: 15px; }
.direction-b .cover-current-version { border: 1px solid var(--b-line); border-radius: 10px; background: #f5f3ed; color: var(--b-ink); }
.direction-b .cover-current-version > strong { color: var(--b-ink); font-size: 50px; }
.direction-b .cover-version-label, .direction-b .cover-current-version dt, .direction-b .cover-current-version p { color: #89795b; font-size: 12px; }
.direction-b .cover-current-version dd { color: #453c2b; font-size: 14px; }
.direction-b .cover-current-version a { border-color: var(--b-sidebar); border-radius: 8px; background: var(--b-sidebar); color: #f0e0bd; font-size: 14px; }
.direction-b .cover-registers a, .direction-b .cover-unit-links a, .direction-b .cover-project-overview .cover-batch-note { border-color: var(--b-line); border-radius: 8px; background: #fff; }
.direction-b .cover-registers span, .direction-b .cover-project-overview .cover-batch-note span, .direction-b .cover-project-overview .cover-batch-note p, .direction-b .cover-project-overview .cover-batch-note a { color: #7b705a; font-size: 13px; }
.direction-b .cover-project-overview .cover-batch-note strong { font-size: 14px; }
.direction-b .shell .workbench:not(.dashboard-grid) > .pane { border: 0 !important; border-radius: var(--b-radius) !important; background: #fff !important; box-shadow: none !important; color: var(--b-ink); }
.direction-b .shell .workbench:not(.dashboard-grid) > .pane::before { display: none !important; }
.direction-b .shell .workbench .pane-head { border-color: var(--b-line); background: #fff !important; color: var(--b-ink); }
.direction-b .shell .workbench .pane-head h3, .direction-b .shell .workbench .detail-title, .direction-b .shell .workbench .issue strong { color: var(--b-ink) !important; }
.direction-b .shell .workbench .detail-text, .direction-b .shell .workbench .work-card p, .direction-b .shell .workbench .work-card small { color: var(--b-muted) !important; font-size: 14px; }
.direction-b .shell .workbench .issue, .direction-b .shell .workbench .rail-step, .direction-b .shell .workbench .copy-box, .direction-b .shell .workbench .work-card, .direction-b .shell .workbench .source-row { border-color: var(--b-line) !important; background: #f8f7f3 !important; color: var(--b-ink) !important; }
.direction-b .shell .workbench .issue.is-selected, .direction-b .shell .workbench .rail-step.is-selected { background: var(--b-selection) !important; }

/* Existing demonstration/export view uses the same paper and fact colors. */
.direction-b .delivery-demo-shell { background: var(--b-canvas); color: var(--b-ink); }
.direction-b .delivery-topbar { border-color: var(--b-line); background: var(--b-canvas); backdrop-filter: none; }
.direction-b .delivery-brand-mark { border: 0; background: #d6b36d; color: var(--b-sidebar); font-weight: 550; }
.direction-b .delivery-brand strong, .direction-b .delivery-report-title { color: var(--b-ink); }
.direction-b .delivery-brand small, .direction-b .delivery-section-kicker, .direction-b .delivery-muted { color: var(--b-muted); }
.direction-b .delivery-btn { border-color: var(--b-line); background: transparent; color: var(--b-ink); font-size: 14px; font-weight: 500; }
.direction-b .delivery-btn.is-primary { border-color: var(--b-sidebar); background: var(--b-sidebar); color: #f1e2be; }
.direction-b .delivery-panel, .direction-b .delivery-risk-card, .direction-b .delivery-step, .direction-b .delivery-table-wrap, .direction-b .delivery-task-card, .direction-b .delivery-slide-card, .direction-b .delivery-drawer-panel { border: 0; border-radius: var(--b-radius); background: #fff; color: var(--b-ink); box-shadow: none; }
.direction-b .delivery-panel p, .direction-b .delivery-risk-card p, .direction-b .delivery-step p, .direction-b .delivery-task-card p, .direction-b .delivery-slide-card p { color: var(--b-muted); font-size: 15px; }
.direction-b .delivery-panel strong, .direction-b .delivery-panel h2, .direction-b .delivery-panel h3, .direction-b .delivery-risk-card h3, .direction-b .delivery-step strong, .direction-b .delivery-task-card h3 { color: var(--b-ink); }

@media (max-width: 1250px) {
  .direction-b .app-body > main, .direction-b.assets-app main { padding-inline: 24px; }
  .direction-b .topbar { padding-inline: 24px; }
  .direction-b .asset-workspace { grid-template-columns: minmax(250px, .78fr) minmax(0, 1.14fr) minmax(260px, .88fr); gap: 12px; }
  .direction-b .workspace-grid.library-grid { grid-template-columns: 145px minmax(280px, .9fr) minmax(0, 1.15fr); gap: 12px; }
  .direction-b .shell .main { padding-inline: 24px !important; }
  .direction-b .shell .signal-hero { gap: 16px; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); }
  .direction-b .shell .toolbar { flex-wrap: wrap; gap: 7px; }
  .direction-b .shell .cmd { min-height: 36px; padding: 7px 9px; font-size: 12px; }
}

@media (max-width: 1050px) and (min-width: 761px) {
  .direction-b .app-rail { width: 172px; padding-inline: 12px; }
  .direction-b .app-body { margin-left: 172px; }
  .direction-b .app-body > main, .direction-b.assets-app main { padding-inline: 18px; }
  .direction-b .topbar { padding-inline: 18px; }
  .direction-b .asset-workspace { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) minmax(0, 1fr); gap: 10px; }
  .direction-b .asset-panel-heading { padding-inline: 16px; }
  .direction-b .asset-filters { padding-inline: 16px; }
  .direction-b .asset-stage-header, .direction-b .asset-review > h2, .direction-b .direction-b-panel-scroll { padding-inline: 16px; }
  .direction-b .asset-stage-header, .direction-b .asset-stage > .segment-controls { flex-wrap: wrap; gap: 8px; }
  .direction-b .review-metadata > div { grid-template-columns: 1fr; gap: 2px; }
  .direction-b .asset-filters { grid-template-columns: 1fr; }
  .direction-b .asset-filters .field:first-child { grid-column: auto; }
  .direction-b .frame-reference { grid-template-columns: 1fr; }
  .direction-b .workspace-grid.library-grid { grid-template-columns: 122px minmax(230px, .9fr) minmax(0, 1fr); gap: 10px; }
  .direction-b .production-grid, .direction-b .geo-grid { grid-template-columns: minmax(260px, .85fr) minmax(0, 1.1fr); }
  .direction-b .shell, .direction-b .shell.theme-godly { grid-template-columns: 172px minmax(0, 1fr) !important; }
  .direction-b .shell .rail { width: 172px; padding-inline: 12px; }
  .direction-b .shell .main { padding-inline: 18px !important; }
  .direction-b .shell .official-topline { grid-template-columns: 1fr; }
  .direction-b .shell .signal-hero { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .direction-b .app-rail { position: static; width: 100%; padding: 15px 18px; overflow: visible; }
  .direction-b .app-rail nav { display: flex; flex-direction: row; flex-wrap: wrap; gap: 4px; margin-top: 15px; }
  .direction-b .app-rail nav a { min-height: 44px; padding: 10px 12px; font-size: 14px; }
  .direction-b .direction-b-nav-group, .direction-b .nav-group-label, .direction-b .nav-section-label { display: none; }
  .direction-b .rail-foot { display: none; }
  .direction-b .app-body { margin-left: 0; min-height: auto; }
  .direction-b .topbar { height: auto; min-height: 62px; padding: 14px 18px; gap: 10px; flex-wrap: wrap; }
  .direction-b .topbar > div { gap: 10px; }
  .direction-b .app-body > main, .direction-b.assets-app main { padding: 8px 16px 24px; }
  .direction-b .page-heading { align-items: flex-start; flex-wrap: wrap; gap: 12px; }
  .direction-b .page-heading p { font-size: 14px; }
  .direction-b .button { min-height: 44px; padding: 10px 13px; }
  .direction-b .batch-bar { padding: 17px; }
  .direction-b .workspace-grid.library-grid { display: block; height: auto; min-height: 0; }
  .direction-b .library-sidebar { height: auto; padding: 10px; margin-bottom: 14px; }
  .direction-b .library-sidebar .library-nav { display: flex; overflow: auto; gap: 5px; }
  .direction-b .library-sidebar button { flex: none; width: auto; white-space: nowrap; }
  .direction-b .result-column { height: 540px; }
  .direction-b .detail-column { height: 650px; margin-top: 14px; }
  .direction-b .library-grid.library-detail-open .result-column { display: none; }
  .direction-b .library-grid:not(.library-detail-open):not(.library-grid-price) .detail-column { display: none; }
  .direction-b .library-grid.library-detail-open .detail-column { display: block; }
  .direction-b .library-price-main { height: 700px; padding: 18px; }
  .direction-b .production-grid, .direction-b .report-grid, .direction-b .geo-grid { display: grid; grid-template-columns: 1fr; height: auto; min-height: 0; }
  .direction-b .production-source, .direction-b .draft-panel { height: 620px; }
  .direction-b .report-records, .direction-b .retest-form, .direction-b .geo-panel { height: 650px; }
  .direction-b .report-summary > div { padding: 18px; }
  .direction-b .report-summary strong, .direction-b .geo-stats strong { font-size: 27px; }
  .direction-b .geo-stats > div { padding: 18px; }
  .direction-b.assets-app .app-body { height: auto; }
  .direction-b.assets-app main { overflow: visible; }
  .direction-b .asset-page-heading { align-items: flex-start; flex-direction: column; gap: 6px; }
  .direction-b .asset-library-count { margin-top: 0; text-align: left; }
  .direction-b .trial-boundary { display: block; font-size: 12px; }
  .direction-b .trial-boundary strong { display: inline; margin-right: 8px; }
  .direction-b .asset-workspace { display: grid; grid-template-columns: 1fr; height: auto; }
  .direction-b .asset-list-panel { height: 600px; }
  .direction-b .asset-stage { height: 680px; }
  .direction-b .asset-review { height: 700px; }
  .direction-b .asset-filters .field:last-child { grid-column: auto; }
  .direction-b .asset-choice { grid-template-columns: 65px minmax(0, 1fr); }
  .direction-b #panel-video { overflow: visible; }
  .direction-b .production-panel { height: 880px; flex: none; }
  .direction-b .production-frame { height: 100% !important; }
  .direction-b .shell, .direction-b .shell.theme-godly, .direction-b .shell.theme-godly.is-module-view { display: block !important; }
  .direction-b .shell .rail { position: static; width: 100%; height: auto; padding: 17px; gap: 16px; }
  .direction-b .shell .project-ledger, .direction-b .shell .rail-status { display: none; }
  .direction-b .shell .stage-switcher { display: block; }
  .direction-b .shell .stage-top { min-height: 50px; padding: 7px 0; }
  .direction-b .shell .stage-modules { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .direction-b .shell .main { padding: 0 16px 24px !important; }
  .direction-b .shell .official-topline { grid-template-columns: 1fr; }
  .direction-b .shell .official-header { margin-bottom: 15px; padding-top: 16px; }
  .direction-b .shell .official-header .toolbar { display: flex; flex-wrap: wrap; }
  .direction-b .shell .cmd { min-height: 44px; }
  .direction-b .shell .product-nav { flex-wrap: wrap; }
  .direction-b .shell .signal-hero { grid-template-columns: 1fr; }
  .direction-b .shell .signal-copy { padding: 22px; }
  .direction-b .shell .hero-project-name { font-size: 31px !important; }
  .direction-b #dashboard .flow-capabilities { grid-template-columns: 1fr; }
  .direction-b #dashboard .flow-capability { min-height: 135px; }
  .direction-b .cover-project-overview { padding: 20px; }
  .direction-b .cover-overview-heading { align-items: flex-start; flex-wrap: wrap; }
  .direction-b .cover-topic-grid { grid-template-columns: 1fr; }
}

@media (max-height: 780px) and (min-width: 761px) {
  .direction-b .topbar { height: 64px; min-height: 64px; }
  .direction-b .asset-page-heading, .direction-b .knowledge-source-links { margin-bottom: 6px; }
  .direction-b .trial-boundary { padding-block: 7px; }
  .direction-b .asset-tabs { margin: 7px 0 12px; }
  .direction-b .asset-panel-heading, .direction-b .asset-stage-header, .direction-b .asset-review > h2 { padding-block: 14px; min-height: 55px; }
  .direction-b .asset-filters { gap: 7px; }
  .direction-b .asset-filters input, .direction-b .asset-filters select { min-height: 34px; padding-block: 5px; }
}

@media (prefers-reduced-motion: reduce) {
  .direction-b *, .direction-b *::before, .direction-b *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Keep desktop reading panels bounded to the viewport, including the old detail cap. */
@media (min-width: 1101px) {
  body.direction-b[data-page]:not([data-page="home"]) { overflow: hidden; }
  .direction-b[data-page]:not([data-page="home"]) .app-body { height: 100dvh; min-height: 0; }
  .direction-b[data-page]:not([data-page="home"]) .app-body > main { height: calc(100dvh - 76px); min-height: 0; padding-bottom: 28px; overflow: hidden; }
}
.direction-b .detail-column { max-height: none; }

.direction-b .b-sampling-drawer{margin:16px 0;background:#fff;border-radius:12px;padding:14px 20px;color:#302a20;font-size:14px}
.direction-b .b-sampling-drawer>summary{cursor:pointer;font-weight:500}
.direction-b #geo-sampling-mount{max-height:260px;overflow:auto;padding-top:12px}
.direction-b #geo-sampling-mount .geo-card{border:0;background:transparent;padding:0}
.direction-b #geo-sampling-mount .geo-card h2{font-size:17px;margin:0}
.direction-b #geo-sampling-mount .geo-card p{font-size:13px}
.direction-b .geo-grid{min-height:250px}

.direction-b[data-page="workflow"] .app-body>main:has(.b-sampling-drawer[open]){overflow:auto}

/* Actual legacy home: outrank its ID-scoped console refinement rules. */
.direction-b #appShell > .rail.app-rail {
  position: fixed !important; inset: 0 auto 0 0;
  display: flex !important; flex-direction: column; gap: 0;
  width: 201px; height: 100dvh; padding: 28px 16px 23px;
  border: 0; border-radius: 0; background: #15140f !important;
  overflow-y: auto; scrollbar-width: thin;
}
.direction-b #appShell > .rail > .direction-b-home-legacy { display: none !important; }
.direction-b #appShell > .main { grid-column: 2; }
.direction-b #appShell .cropbrand { display: flex; flex: none; align-items: center; gap: 10px; padding: 0 8px; margin: 0; color: #efe9dc; }
.direction-b #appShell .cropbrand .brand-mark { display: block; width: 34px; height: 34px; flex: 0 0 34px; padding: 0; border: 0; border-radius: 9px; background: transparent; object-fit: contain; }
.direction-b #appShell .cropbrand .b-brand-copy { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.direction-b #appShell .cropbrand strong { font-family: ui-monospace, SFMono-Regular, monospace; color: #efe9dc; font-size: 12px; font-weight: 500; letter-spacing: 1.3px; line-height: 1.3; white-space: nowrap; }
.direction-b #appShell .cropbrand small { color: #b8af9b; font-size: 12px; font-weight: 400; line-height: 1.4; letter-spacing: 0; }
.direction-b #appShell .direction-b-home-nav { display: flex; flex: none; flex-direction: column; gap: 23px; margin: 31px 0 0; padding: 0; }
.direction-b #appShell .direction-b-home-nav .b-nav-group { display: flex; flex-direction: column; gap: 5px; }
.direction-b #appShell .direction-b-home-nav .b-nav-label { display: block; margin: 0 12px 3px; padding: 0; color: #8e8672; font-size: 12px; font-weight: 400; line-height: 1.5; }
.direction-b #appShell .direction-b-home-nav a { display: flex; align-items: center; min-height: 44px; padding: 9px 12px; border: 0; border-radius: 7px; background: transparent; color: #aaa28f; font-size: 18px; font-weight: 400; line-height: 1.5; }
.direction-b #appShell .direction-b-home-nav a:hover { background: #242218; color: #efe6d2; }
.direction-b #appShell .direction-b-home-footer { display: flex; flex-direction: column; gap: 7px; flex: none; margin-top: auto; padding: 20px 11px 0; border-top: 1px solid #302c21; color: #9e9580; font-size: 12px; line-height: 1.7; }
.direction-b #appShell .direction-b-home-footer a { padding: 0; color: #b7ad97; }
.direction-b #appShell .direction-b-home-footer a:hover { color: #efe1c3; }
.direction-b #appShell #dashboard .signal-hero {
  min-height: 0 !important; padding: 0 !important; border: 0 !important;
  border-radius: 0 !important; background: transparent !important;
  box-shadow: none !important; filter: none !important;
  transform: none !important; perspective: none !important;
  isolation: auto; overflow: visible;
}
.direction-b #appShell #dashboard .signal-hero::before,
.direction-b #appShell #dashboard .signal-hero::after,
.direction-b #appShell #dashboard .signal-copy::before,
.direction-b #appShell #dashboard .signal-copy::after { display: none !important; }
.direction-b #appShell #dashboard .signal-hero * {
  box-shadow: none !important; text-shadow: none !important;
  transform: none !important; perspective: none !important; filter: none !important;
}
.direction-b #appShell #dashboard .signal-copy,
.direction-b #appShell #dashboard .command-surface {
  min-width: 0; border: 0 !important; border-radius: 15px !important;
  background: #fff !important; clip-path: none !important;
  transform: none !important; transform-style: flat !important;
  transform-origin: center !important; perspective: none !important;
  box-shadow: none !important; filter: none !important;
}
.direction-b #appShell #dashboard .hero-project-name {
  display: block !important; width: auto; max-width: none; white-space: nowrap;
  margin: 12px 0 20px !important; padding: 0;
  font-family: var(--sans); font-size: 35px !important; font-weight: 600;
  line-height: 1.3 !important; letter-spacing: -1px !important; color: #181713 !important;
}
.direction-b #appShell #dashboard .hero-project-name span {
  display: inline !important; width: auto !important; max-width: none;
  margin: 0 !important; padding: 0;
  font-family: inherit; font-size: inherit !important; line-height: inherit !important;
  letter-spacing: inherit !important; color: #181713 !important;
  -webkit-text-fill-color: #181713 !important; background: transparent !important;
}
.direction-b #appShell #dashboard .signal-kicker::before { background: #b9a578 !important; box-shadow: none !important; }
.direction-b #appShell #dashboard .home-audit-action,
.direction-b #appShell #dashboard .home-audit-action:hover,
.direction-b #appShell #dashboard .flow-button.is-primary,
.direction-b #appShell #dashboard .flow-button.is-primary:hover {
  min-height: 44px; padding: 10px 14px; border: 1px solid #15140f !important;
  border-radius: 8px !important; background: #15140f !important; background-image: none !important;
  color: #f3e5c7 !important; box-shadow: none !important; transform: none !important;
  font-size: 14px; font-weight: 500;
}
.direction-b #appShell #dashboard .home-audit-action:focus-visible { outline: 2px solid #a9853e; outline-offset: 3px; }
.direction-b #appShell .official-header,
.direction-b #appShell .product-nav { border-radius: 0 !important; background: var(--b-canvas) !important; box-shadow: none !important; transform: none !important; perspective: none !important; }
.direction-b #appShell .product-nav { border: 0; border-top: 1px solid #e2dfd8; }
.direction-b #appShell .product-nav-item { border: 0; border-radius: 7px; background: transparent; }
.direction-b #appShell .product-nav-item.is-active { background: #e5e0d4; }
.direction-b #appShell .cover-project-overview { box-shadow: none !important; transform: none !important; perspective: none !important; }

@media (max-width: 1050px) and (min-width: 761px) {
  .direction-b #appShell > .rail.app-rail { width: 172px; padding-inline: 12px; }
  .direction-b #appShell .cropbrand { padding-inline: 5px; }
  .direction-b #appShell .direction-b-home-nav a { padding-inline: 10px; }
}
@media (max-width: 760px) {
  .direction-b #appShell > .rail.app-rail { position: static !important; width: 100%; height: auto; padding: 17px; overflow: visible; }
  .direction-b #appShell > .main { grid-column: auto; }
  .direction-b #appShell .direction-b-home-nav { flex-direction: row; flex-wrap: wrap; gap: 5px 12px; margin-top: 16px; }
  .direction-b #appShell .direction-b-home-nav .b-nav-group { display: contents; }
  .direction-b #appShell .direction-b-home-nav .b-nav-label { display: none; }
  .direction-b #appShell .direction-b-home-nav a { min-height: 44px; padding: 10px 12px; font-size: 14px; }
  .direction-b #appShell .direction-b-home-footer { display: none; }
}

/* Explicit child type styles prevent legacy narrow-screen text shrinking. */
.direction-b .app-rail nav a { font-size:14px; min-height:40px; }
.direction-b .app-rail nav a>span { font:inherit; }
.direction-b .brand strong { display:block; }
.direction-b .b-nav-group { display:flex;flex-direction:column;gap:5px;margin-top:18px; }
.direction-b .b-nav-group:first-child { margin-top:0; }
.direction-b .b-nav-label { margin:0 12px;color:#958b76;font-size:12px;line-height:1.5; }
@media(max-width:760px){
 .direction-b .b-nav-group{display:contents}
 .direction-b .b-nav-label{display:none}
 .direction-b .app-rail nav a{min-height:44px}
}
.direction-b #appShell .direction-b-home-nav a{font-size:14px;text-decoration:none}
.direction-b #appShell .cropbrand,.direction-b #appShell .direction-b-home-footer a{text-decoration:none}
.direction-b #appShell #dashboard .home-audit-eyebrow,
.direction-b #appShell #dashboard .workflow-step small,
.direction-b #appShell #dashboard .workflow-step>span,
.direction-b #appShell #dashboard .workflow-panel-head strong {color:#716d63!important}
.direction-b #appShell #dashboard .workflow-step strong {color:#39342c!important}
