/* Skat desktop completion. Presentation only: no hidden/inert, permission,
   annotation-color, print, public landing or source-content overrides. */
@media screen {
  /* Dark reader header only; keep the original mark on light auth surfaces. */
  .skat-reader-design .topbar .brand-mark-logo img {
    content: url("/assets/retskilden-mark.png?v=20260927-2");
    mix-blend-mode: screen;
  }
  /* Non-reader views must not inherit the reader's fixed-width grid tracks. */
  .skat-reader-design:has(> :is(.profiles-view, .admin-view, .deadlines-view, .companies-view)[aria-hidden="false"]) { grid-template-columns: minmax(0, 1fr); }
  .skat-reader-design :is(.profiles-view, .admin-view) {
    --font-ui: var(--reader-ui-font);
    --ink: var(--reader-ink);
    --muted: var(--reader-muted);
    --line: var(--reader-line-color);
    --surface-tint: var(--reader-side);
    font-family: var(--reader-ui-font);
    color: var(--reader-ink);
    background: var(--reader-side);
  }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(button, input, textarea, select) {
    font-family: var(--reader-ui-font);
    font-size: 14px;
    line-height: 1.5;
    border-radius: 6px;
    box-shadow: none;
  }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(input:not([type="radio"]):not([type="checkbox"]), select, textarea) {
    min-width: 0;
    max-width: 100%;
    padding: 9px 11px;
    border: 1px solid var(--reader-line-color);
    color: var(--reader-ink);
    background: #fff;
  }
  .skat-reader-design :is(.profiles-view, .admin-view) textarea { resize: vertical; }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(.quiet-button, .primary-button, .icon-button) {
    min-height: 38px;
    font-weight: 500;
    background-image: none;
    transform: none;
    text-shadow: none;
  }
  .skat-reader-design :is(.profiles-view, .admin-view) .primary-button {
    color: #fff;
    border-color: var(--reader-blue);
    background: var(--reader-blue);
  }
  .skat-reader-design :is(.profiles-view, .admin-view) .primary-button::after { content: none; }
  .skat-reader-design :is(.profiles-view, .admin-view) .quiet-button { background-color: #fff; }
  .skat-reader-design :is(.profiles-view, .admin-view) .quiet-button:hover:not(:disabled) { background-color: #edf4fe; }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(button, a, input, textarea, select, summary):focus-visible,
  .skat-reader-design .account-menu :is(a, button):focus-visible {
    outline: 2px solid var(--reader-blue);
    outline-offset: 3px;
  }
  .skat-reader-design :is(.profiles-view, .admin-view) [aria-invalid="true"] { border-color: #b44b3f; }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(button, input, select, textarea):disabled {
    opacity: .65;
    cursor: not-allowed;
  }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(.doc-kicker, .section-title, .pane-heading, .mini-heading) {
    font-family: var(--reader-ui-font);
    font-weight: 500;
    letter-spacing: 0;
    text-transform: none;
  }
  .skat-reader-design :is(.profiles-view, .admin-view) :is(.empty-state, .empty-card, .admin-operations-empty) {
    padding: 24px 16px;
    border-radius: 6px;
    background-image: none;
    box-shadow: none;
    color: var(--reader-muted);
    font-size: 14px;
    line-height: 1.65;
  }

  /* Analyse: fluid header actions, readable material and explicit modes. */
  .skat-reader-design .profiles-layout { grid-template-columns: 280px minmax(0, 1fr); }
  .skat-reader-design .profiles-sidebar { padding: 24px 18px; background: var(--reader-side); }
  .skat-reader-design .profiles-view .profile-main { min-width: 0; background: #fff; }
  .skat-reader-design .profiles-view .profile-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 20px;
    padding: 24px 28px;
    background: #fff;
    border-bottom: 1px solid var(--reader-line-color);
    box-shadow: none;
  }
  .skat-reader-design .profile-header::after { content: none; }
  .skat-reader-design .profile-header > div:first-child { flex: 1 1 260px; }
  .skat-reader-design .profile-header .doc-kicker { font-size: 12px; line-height: 1.5; color: var(--reader-muted); }
  .skat-reader-design :is(.profile-header, .admin-header) h1 {
    margin: 6px 0 0;
    font: 600 26px/1.35 var(--reader-ui-font);
    letter-spacing: -.5px;
    overflow-wrap: anywhere;
  }
  .skat-reader-design .profile-actions { flex: 1 1 390px; flex-wrap: wrap; gap: 8px; justify-content: flex-start; }
  .skat-reader-design .profile-actions :is(select, .entity-case-link) { max-width: 100%; min-width: 0; }
  .skat-reader-design .profile-mode-tabs {
    margin: 0;
    padding: 0 28px;
    gap: 24px;
    border: 0;
    border-bottom: 1px solid var(--reader-line-color);
    border-radius: 0;
    background: #fff;
    box-shadow: none;
    flex-wrap: wrap;
  }
  .skat-reader-design .profile-mode-tabs button {
    min-width: 0;
    min-height: 64px;
    padding: 12px 2px;
    border: 0;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    background: none;
    color: var(--reader-muted);
    box-shadow: none;
    transform: none;
  }
  .skat-reader-design .profile-mode-tabs button span { font-size: 14px; font-weight: 500; }
  .skat-reader-design .profile-mode-tabs button small { font-size: 12px; font-weight: 400; line-height: 1.5; }
  .skat-reader-design .profile-mode-tabs button.active { color: var(--reader-blue); border-bottom-color: var(--reader-blue); background: none; box-shadow: none; }
  .skat-reader-design .profile-mode-tabs button.active :is(span, small) { color: inherit; }
  .skat-reader-design .profile-mode-tabs button:hover { background: var(--reader-side); }
  .skat-reader-design .profile-workspace {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 20px;
    padding: 24px 28px;
    background: var(--reader-side);
    overflow: auto;
    align-content: start;
    grid-template-rows: max-content;
    grid-auto-rows: max-content;
    align-items: start;
  }
  .skat-reader-design .profile-workspace:is([data-profile-mode="sources"], [data-profile-mode="contributions"], [data-profile-mode="report"]) {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  }
  .skat-reader-design .profile-panel { min-width: 0; padding: 20px; border: 1px solid var(--reader-line-color); border-radius: 8px; background: #fff; box-shadow: none; overflow: visible; }
  .skat-reader-design .profile-card-title { display: flex; flex-wrap: wrap; gap: 6px; }
  .skat-reader-design .profile-card-title strong { flex: 1 1 100%; }
  .skat-reader-design .profiles-view .issue-insight { grid-template-columns: minmax(0, 1fr); }
  .skat-reader-design .profiles-view :is(.issue-insight-title strong, .profile-doc-item strong, .profile-source-group > header strong) { font-size: 14px; font-weight: 500; line-height: 1.5; }
  .skat-reader-design .profiles-view .profile-doc-item { border-radius: 6px; background-image: none; box-shadow: none; }
  .skat-reader-design .profiles-view :is(.profile-create-shell, .profile-insight-composer, .profile-collaboration) {
    border: 1px solid var(--reader-line-color);
    border-radius: 6px;
    background: #fff;
    box-shadow: none;
  }
  .skat-reader-design .profile-create-shell > summary { flex-direction: column; gap: 5px; padding: 14px; }
  .skat-reader-design :is(.profile-create-shell, .profile-insight-composer) > summary :is(strong, span, small) { font-weight: 400; line-height: 1.5; }
  .skat-reader-design :is(.profile-create-shell, .profile-insight-composer) > summary strong { font-size: 14px; font-weight: 500; }
  .skat-reader-design :is(.profile-create-shell, .profile-insight-composer) > summary :is(span, small) { color: var(--reader-muted); font-size: 12px; }
  .skat-reader-design .profile-scope-field { grid-template-columns: minmax(0, 1fr); }
  .skat-reader-design .profile-scope-field label { padding: 0; border-radius: 5px; box-shadow: none; background-image: none; }
  .skat-reader-design .profile-scope-field label > span { min-width: 0; border-radius: 5px; background: #fff; box-shadow: none; }
  .skat-reader-design .profile-scope-field input:checked + span { border-color: var(--reader-blue); background: #edf4fe; box-shadow: none; }
  .skat-reader-design .profile-scope-field input:focus-visible + span { outline: 2px solid var(--reader-blue); outline-offset: 3px; }
  .skat-reader-design .profile-scope-field :is(strong, small) { white-space: normal; overflow: visible; text-overflow: clip; line-height: 1.5; }
  .skat-reader-design .profile-scope-field strong { font-size: 14px; font-weight: 500; }
  .skat-reader-design .profile-scope-field small { color: var(--reader-muted); font-size: 12px; font-weight: 400; }
  .skat-reader-design .profiles-view :is(.profile-list-item, .profile-item, .profile-doc, .issue-card, .issue-insight, .insight-item, .annotation-item, .activity-item, .insight-source-preview) {
    min-width: 0;
    border-radius: 6px;
    background-image: none;
    box-shadow: none;
    transform: none;
  }
  .skat-reader-design .profiles-view :is(.profile-issue-board, .profile-doc-list, .profile-annotation-list) article { border-radius: 6px; box-shadow: none; background-image: none; }
  .skat-reader-design .profiles-view :is(.issue-card header strong, .insight-item strong, .annotation-item strong, .profile-list-item strong) { font-size: 14px; font-weight: 500; line-height: 1.5; }
  .skat-reader-design .profiles-view :is(.issue-insight-main p, .issue-insight blockquote, .insight-item p, .annotation-item p) { font-size: 14px; line-height: 1.7; overflow-wrap: anywhere; }
  .skat-reader-design .profiles-view :is(.profile-scope-badge, .issue-status-select, .profile-filter-context) { border-radius: 4px; font-weight: 500; box-shadow: none; }
  .skat-reader-design .profiles-view :is(.annotation-manager-summary, .profile-filter-context) { border-radius: 6px; background: var(--reader-side); box-shadow: none; }
  .skat-reader-design .profiles-view .annotation-manager-summary article strong { font-size: 22px; font-weight: 600; }
  .skat-reader-design .profiles-view .annotation-manager-summary article span { font-size: 12px; font-weight: 400; line-height: 1.5; }

  /* Administration uses page scrolling, not three clipped narrow columns. */
  .skat-reader-design .admin-layout { grid-template-columns: 260px minmax(0, 1fr); background: var(--reader-side); }
  .skat-reader-design .admin-sidebar { padding: 24px 18px; background: var(--reader-side); }
  .skat-reader-design .admin-main { display: block; min-width: 0; overflow-y: auto; overflow-x: hidden; background: var(--reader-side); }
  .skat-reader-design .admin-header { padding: 24px 28px; flex-wrap: wrap; align-items: flex-start; background: #fff; }
  .skat-reader-design .admin-dashboard { margin: 0; padding: 20px 28px; gap: 16px; grid-template-columns: minmax(0, 1fr); background: var(--reader-side); }
  .skat-reader-design .admin-dashboard-metrics { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .skat-reader-design .admin-grid { margin: 0; padding: 0 28px 24px; gap: 20px; grid-template-columns: repeat(2, minmax(0, 1fr)); background: none; overflow: visible; }
  .skat-reader-design .admin-panel { padding: 20px; overflow: visible; border: 1px solid var(--reader-line-color); border-radius: 8px; background: #fff; box-shadow: none; }
  .skat-reader-design .admin-audit-panel { grid-column: 1 / -1; min-height: 0; }
  .skat-reader-design .admin-view :is(.admin-metric-card, .admin-health-card, .admin-quality-metric, .admin-quality-item, .admin-audit-item, .admin-principle-card, .admin-warning, .user-list-item, .access-item) { border-radius: 6px; background-image: none; box-shadow: none; }
  .skat-reader-design .admin-metric-card { padding: 14px; background: #fff; }
  .skat-reader-design .admin-metric-card strong { font-size: 24px; font-weight: 600; }
  .skat-reader-design .admin-metric-card :is(span, small) { font-weight: 400; }
  .skat-reader-design .admin-view :is(.admin-metric-card span, .admin-metric-card small, .admin-principle-card span, .user-list-item small) { color: var(--reader-muted); font-size: 12px; line-height: 1.6; }
  .skat-reader-design .admin-security-pill { border-radius: 4px; font-weight: 500; }
  .skat-reader-design .team-create { padding-block: 16px; gap: 12px; }
  .skat-reader-design .team-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .skat-reader-design .admin-view :is(.user-list-item, .admin-audit-item, .profile-access-list) { overflow-wrap: anywhere; }
  .skat-reader-design .admin-technical-details { margin: 0 28px 24px; border: 1px solid var(--reader-line-color); border-radius: 8px; background: #fff; box-shadow: none; }
  .skat-reader-design .admin-technical-details > summary { padding: 18px 20px; border-radius: 8px; background: #fff; box-shadow: none; }
  .skat-reader-design .admin-technical-details > summary strong { font-size: 14px; font-weight: 500; }
  .skat-reader-design .admin-technical-details > summary :is(span, small) { font-size: 12px; font-weight: 400; line-height: 1.6; }
  .skat-reader-design .admin-technical-body { padding: 0 20px 20px; }
  .skat-reader-design .admin-view :is(.admin-quality-head, .admin-quality-summary, .admin-operations-head) { border-radius: 6px; background-image: none; box-shadow: none; }

  /* Secondary workspaces retain all graph, status and business-state rules. */
  .skat-reader-design :is(.cases-view, .companies-view, .deadlines-view) :is(.case-room-panel, .case-room-hero-main, .case-link-panel, .case-overview-item, .case-activity-item, .company-relation-item, .company-report-item, .company-network-expand, .company-network-node, .company-network-edge, .company-financial-card, .company-source-card, .deadline-case-item) {
    border-radius: 6px;
    background-image: none;
    box-shadow: none;
  }
  .skat-reader-design .case-room-tabs { gap: 20px; border-radius: 0; border-bottom: 1px solid var(--reader-line-color); background: #fff; box-shadow: none; flex-wrap: wrap; }
  .skat-reader-design .case-room-tabs button { min-height: 44px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; padding: 10px 2px; color: var(--reader-muted); font: 500 14px/1.5 var(--reader-ui-font); background: none; box-shadow: none; transform: none; }
  .skat-reader-design .case-room-tabs button.active { border-bottom-color: var(--reader-blue); color: var(--reader-blue); background: none; }
  .skat-reader-design .case-room-tabs button.active :is(span, small) { color: inherit; }
  .skat-reader-design .case-room-tabs button:focus-visible { outline: 2px solid var(--reader-blue); outline-offset: 3px; }
  .skat-reader-design .companies-view :is(.company-graph-shell, .company-corporate-tree, .company-relation-workbench-shell, .company-brief-actions, .company-graph .empty-state) { border-radius: 6px; background-image: none; box-shadow: none; }
  .skat-reader-design .company-graph-mode { border-radius: 5px; background: var(--reader-side); box-shadow: none; }
  .skat-reader-design .company-graph-mode button { min-height: 36px; border-radius: 4px; font: 500 13px/1.5 var(--reader-ui-font); background: none; box-shadow: none; }
  .skat-reader-design .company-graph-mode button.active { color: #0756ba; background: #e3edfc; box-shadow: none; }
  .skat-reader-design .companies-view .company-accounts-empty { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 16px; padding: 16px; border-radius: 6px; background-image: none; box-shadow: none; }
  .skat-reader-design .company-accounts-empty > div { display: grid; flex: 1 1 300px; min-width: 0; gap: 6px; }
  .skat-reader-design .company-accounts-empty strong { font-size: 14px; font-weight: 500; line-height: 1.5; }
  .skat-reader-design .company-accounts-empty span { font-size: 14px; font-weight: 400; line-height: 1.6; color: var(--reader-muted); }
  .skat-reader-design .companies-view .company-inline-action { min-height: 38px; flex-shrink: 0; border-radius: 5px; padding: 8px 12px; font: 500 13px/1.5 var(--reader-ui-font); box-shadow: none; background-image: none; }

  /* CVR desktop: retain source facts and controls; remove redundant framing. */
  @media (min-width: 1121px) {
    .skat-reader-design #companyPanelNetwork .company-graph-shell { padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; }
    .skat-reader-design #companyGraph[data-company-graph-state="ready"] { min-width: 0; min-height: 0; border: 0; border-radius: 0; background: var(--surface, #fff); box-shadow: none; }
    .skat-reader-design #companyGraph .company-cytoscape-frame { display: flex; flex-direction: column; width: 100%; max-width: 100%; height: clamp(480px, 70vh, 760px); min-height: 0; box-sizing: border-box; overflow: auto; }
    .skat-reader-design #companyGraph .company-cytoscape-frame > :not(.company-cytoscape-body) { flex-shrink: 0; }
    .skat-reader-design #companyGraph .company-cytoscape-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(210px, 240px); flex: 1 1 auto; min-width: 0; min-height: 320px; }
    .skat-reader-design #companyGraph .company-cytoscape-canvas { width: 100%; height: 100%; min-width: 0; min-height: 320px; }
    .skat-reader-design #companyGraph .company-cytoscape-inspector { min-width: 0; min-height: 0; max-height: 100%; overflow: auto; padding: 12px; box-sizing: border-box; }
    .skat-reader-design #companyGraph .company-cytoscape-inspector > strong { display: block; max-width: 100%; white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; -webkit-line-clamp: unset; font-size: 15px; line-height: 1.45; }
    .skat-reader-design #companyGraph[data-company-graph-state="empty"] { height: auto; min-height: 0; padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; }
    .skat-reader-design #companyGraph[data-company-graph-state="empty"] > .empty-state { height: auto; min-height: 0; max-width: 80ch; margin: 0; padding: 12px 0; border: 0; border-radius: 0; background: none; box-shadow: none; text-align: left; }
    .skat-reader-design #companyGraph[data-company-graph-state="empty"] > .empty-state p { margin-block: 6px; }
    .skat-reader-design #companyGraph:fullscreen { width: 100vw; height: 100dvh; max-width: none; max-height: none; min-height: 0; margin: 0; padding: 16px; box-sizing: border-box; border: 0; border-radius: 0; background: var(--surface, #fff); overflow: auto; }
    .skat-reader-design #companyGraph:fullscreen .company-cytoscape-frame { height: 100%; min-height: 0; max-height: none; }
    .skat-reader-design #companyGraph:fullscreen .company-cytoscape-body { grid-template-columns: minmax(0, 1fr) minmax(240px, 300px); }
    /* The persistent company header remains primary; passport facts stay visible. */
    .skat-reader-design #companyProfileBrief .company-pass { padding: 12px 0 12px 14px; border: 0; border-left: 3px solid var(--reader-line-color); border-radius: 0; background: none; box-shadow: none; }
    .skat-reader-design #companyProfileBrief .company-pass.red { border-left-color: #982f24; }
    .skat-reader-design #companyProfileBrief .company-pass-rail { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 8px 16px; width: auto; padding: 0 0 10px; border: 0; border-bottom: 1px solid var(--reader-line-color); background: none; }
    .skat-reader-design #companyProfileBrief .company-pass-rail-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; min-width: 0; }
    .skat-reader-design #companyProfileBrief .company-pass-rail-meta small { min-width: 0; overflow-wrap: anywhere; }
    .skat-reader-design #companyProfileBrief .company-pass-body { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 16px; padding: 12px 0 0; }
    .skat-reader-design #companyProfileBrief .company-pass-identity { min-width: 0; padding: 0; }
    .skat-reader-design #companyProfileBrief .company-pass-identity > strong { display: block; margin-block: 6px; font-size: 16px; line-height: 1.4; letter-spacing: 0; overflow-wrap: anywhere; }
    .skat-reader-design #companyProfileBrief .company-pass-identity > p { margin: 6px 0 10px; max-width: 65ch; font-size: 13px; line-height: 1.6; }
    .skat-reader-design #companyProfileBrief .company-pass-facts { display: flex; flex-wrap: wrap; gap: 6px 14px; }
    .skat-reader-design #companyProfileBrief .company-pass-facts > span { min-width: 0; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
    .skat-reader-design #companyProfileBrief .company-pass-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
    .skat-reader-design #companyProfileBrief .company-pass-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 14px; min-width: 0; padding: 0; }
    .skat-reader-design #companyProfileBrief .company-pass-metric { min-width: 0; padding: 8px 0; border: 0; border-top: 1px solid var(--reader-line-color); border-radius: 0; background: none; box-shadow: none; }
    .skat-reader-design #companyProfileBrief .company-pass-change { grid-column: 1 / -1; grid-row: 1; }
    .skat-reader-design #companyProfileBrief .company-pass-metric > strong { font-size: 14px; line-height: 1.45; overflow-wrap: anywhere; }
    .skat-reader-design #companyProfileBrief .company-pass-metric > small { font-size: 12px; line-height: 1.55; white-space: normal; overflow-wrap: anywhere; }
  }

  .skat-reader-design .account-menu { padding: 8px; border-color: var(--reader-line-color); border-radius: 8px; background: #fff; box-shadow: 0 8px 28px #1028401f; }
  .skat-reader-design .account-menu-item { min-height: 44px; border-radius: 5px; font: 400 14px/1.5 var(--reader-ui-font); }
  .skat-reader-design a.account-menu-item { display: flex; text-decoration: none; }
  .skat-reader-design .account-menu-item strong { font-size: 14px; font-weight: 500; }
  .skat-reader-design .account-menu-item small { font-size: 12px; line-height: 1.5; }
  .skat-reader-design .account-menu-item svg { color: var(--reader-blue); }
  .skat-reader-design .account-password-panel { border: 1px solid var(--reader-line-color); border-radius: 5px; background: var(--reader-side); box-shadow: none; font: 400 14px/1.5 var(--reader-ui-font); }
  .skat-reader-design .account-password-panel summary { background: none; box-shadow: none; }
  .skat-reader-design .account-password-panel strong { font-size: 14px; font-weight: 500; }
  .skat-reader-design .account-password-panel small { font-size: 12px; font-weight: 400; color: var(--reader-muted); }
  .skat-reader-design .account-password-panel :is(input, button) { min-width: 0; max-width: 100%; border-radius: 5px; font-family: var(--reader-ui-font); font-size: 14px; }
  .skat-reader-design .account-password-panel :is(input, button, summary):focus-visible { outline: 2px solid var(--reader-blue); outline-offset: 3px; }

  /* These two UI surfaces live outside appShell. The public page is untouched. */
  #commandPalette { font-family: "Skat Inter", "Segoe UI", sans-serif; }
  #commandPalette .command-panel { border-radius: 8px; background: #fff; border-color: #dce4ee; }
  #commandPalette .command-search { background: #fff; border-bottom-color: #dce4ee; }
  #commandPalette .command-search input { font: 400 16px/1.5 "Skat Inter", "Segoe UI", sans-serif; }
  #commandPalette .command-item { min-height: 52px; border-radius: 5px; background-image: none; box-shadow: none; }
  #commandPalette .command-item-copy strong { font-size: 14px; font-weight: 500; }
  #commandPalette .command-item-copy span { font-size: 12px; line-height: 1.5; }
  #commandPalette .command-item:is(:hover, .is-active) { color: #0756ba; background: #edf4fe; }
  #commandPalette :is(button, input):focus-visible { outline: 2px solid #0965d8; outline-offset: 2px; }
  #authGate.rk-home #loginPanel { font-family: "Skat Inter", "Segoe UI", sans-serif; border: 1px solid #dce4ee; border-radius: 8px; background: #fff; box-shadow: 0 16px 64px #10284026; }
  #authGate.rk-home #loginPanel .auth-note { padding: 16px 0; border: 0; border-radius: 0; background: none; box-shadow: none; }
  #authGate.rk-home #loginPanel .auth-note strong { font-size: 18px; font-weight: 600; line-height: 1.5; }
  #authGate.rk-home #loginPanel .auth-note span { color: #526784; font-size: 14px; line-height: 1.65; }
  #authGate.rk-home #loginPanel :is(input, button) { font-family: "Skat Inter", "Segoe UI", sans-serif; border-radius: 6px; }
  #authGate.rk-home #loginPanel .auth-link-button { min-height: 38px; font-size: 14px; font-weight: 500; }
  #authGate.rk-home #loginPanel .auth-error:not(:empty) { margin-top: 16px; padding: 12px; border-left: 3px solid #b44b3f; border-radius: 4px; color: #842f26; background: #fff3f0; font-size: 14px; line-height: 1.6; }
  #authGate.rk-home #loginPanel .auth-error.success:not(:empty) { border-color: #217452; color: #18583f; background: #eef8f3; }
  #authGate.rk-home #loginPanel .auth-error.muted:not(:empty) { border-color: #8a9bb2; color: #526784; background: #f6f8fb; }

  @media (max-width: 1250px) {
    .skat-reader-design .profiles-layout { grid-template-columns: 244px minmax(0, 1fr); }
    .skat-reader-design .admin-layout { grid-template-columns: 220px minmax(0, 1fr); }
    .skat-reader-design .profile-header { padding-inline: 20px; }
    .skat-reader-design .profile-header > div:first-child,
    .skat-reader-design .profile-actions { flex-basis: auto; width: 100%; }
    .skat-reader-design .profile-workspace,
    .skat-reader-design .profile-workspace:is([data-profile-mode="sources"], [data-profile-mode="contributions"], [data-profile-mode="report"]) { grid-template-columns: minmax(0, 1fr); padding-inline: 20px; }
    .skat-reader-design .admin-dashboard-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  }
  @media (max-width: 1000px) {
    .skat-reader-design .admin-grid { grid-template-columns: minmax(0, 1fr); }
    .skat-reader-design .admin-header { padding-inline: 20px; }
    .skat-reader-design .admin-dashboard { padding-inline: 20px; }
    .skat-reader-design .admin-grid { padding-inline: 20px; }
  }
}

/* CVR finish: scoped desktop layout; no global navigation/theme changes. */
@media screen and (min-width: 1121px) {
  #companiesView .companies-sidebar,
  #companiesView .company-main,
  #companiesView .company-result-list,
  #companiesView .company-result-item,
  #companiesView .company-result-top,
  #companiesView .company-search-form .field { min-width: 0; max-width: 100%; box-sizing: border-box; }
  #companiesView .companies-sidebar { overflow-x: hidden; }
  #companiesView .company-search-form :is(input, select),
  #companiesView .company-result-controls select { width: 100%; min-width: 0; box-sizing: border-box; }
  #companiesView .company-result-item :is(strong, span) { white-space: normal; overflow-wrap: anywhere; text-overflow: clip; min-width: 0; }
  #companiesView .company-result-top { flex-wrap: wrap; }
  #companiesView .company-result-top strong { flex: 1 1 160px; line-height: 1.45; }
  #companiesView .company-result-status { flex: 0 0 auto; max-width: 100%; }
  #companiesView .company-result-controls { display: grid; gap: 6px; margin: 12px 0; }
  #companiesView #companyResultSummary { margin: 0; font-size: 12px; line-height: 1.5; color: var(--muted); }
  #companiesView :is(.company-result-item, .company-tab, select, .company-inline-action):focus-visible { outline: 2px solid #0756ba; outline-offset: 3px; }

  /* Browse the bounded result pool in the main space before choosing a profile. */
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .companies-layout { display: block; overflow-y: auto; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .companies-sidebar { width: 100%; padding: 24px 32px; border-right: 0; overflow: visible; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .company-search-form { grid-template-columns: minmax(260px, 2fr) minmax(160px, 1fr) auto; align-items: end; max-width: 1100px; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .company-result-controls { grid-template-columns: minmax(180px, 260px) 1fr; align-items: end; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .company-result-list { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .company-result-item { min-height: 88px; padding: 16px; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .company-main { overflow: visible; }
  #companiesView:not(.company-profile-open):not([data-company-search-type="person"]) .company-header { padding-block: 12px; }
  #companiesView.company-profile-open .companies-layout { grid-template-columns: clamp(260px, 21vw, 320px) minmax(0, 1fr); }
  #companiesView.company-profile-open .company-result-list .company-result-item:not(.active) { display: grid; }
  #companiesView.company-profile-open .company-result-item { padding: 10px; border-radius: 6px; box-shadow: none; }
  #companiesView.company-profile-open .company-result-item.active { border-left: 3px solid #0756ba; }
  #companiesView .company-header { gap: 12px; padding: 18px 24px; }
  #companiesView .company-header h1 { margin-block: 4px; overflow-wrap: anywhere; }
  #companiesView .company-actions { flex-wrap: wrap; gap: 6px; }
  #companiesView .company-workspace { padding: 16px 24px; }
  #companiesView .company-panel { padding: 16px; min-width: 0; }
  #companiesView .company-summary-grid { gap: 10px; margin-block: 10px; }
  #companiesView .company-pass-facts { gap: 8px 16px; }
  #companiesView .company-pass-facts > span { white-space: normal; overflow-wrap: anywhere; }

  /* Keep real source caveats and all controls; compress framing, enlarge canvas. */
  .skat-reader-design #companiesView #companyPanelNetwork .company-graph-shell-head { gap: 8px; padding: 8px 0; margin-bottom: 8px; }
  .skat-reader-design #companiesView #companyGraphSummary { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 8px 0; }
  .skat-reader-design #companiesView .company-graph-summary-card { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; padding: 6px 0; border: 0; background: none; box-shadow: none; }
  .skat-reader-design #companiesView .company-graph-summary-card strong { font-size: 14px; }
  .skat-reader-design #companiesView #companyGraph .company-cytoscape-frame { height: clamp(560px, 74vh, 860px); }
  .skat-reader-design #companiesView #companyGraph .company-cytoscape-body { grid-template-columns: minmax(0, 1fr) minmax(200px, 24%); min-height: 380px; }
  .skat-reader-design #companiesView #companyGraph .company-cytoscape-canvas { min-height: 380px; }
  #companiesView .company-cytoscape-toolbar { display: flex; flex-wrap: wrap; gap: 8px 12px; padding: 10px; align-items: center; }
  #companiesView .company-cytoscape-toolbar > div:first-child { flex: 1 1 210px; }
  #companiesView .company-cytoscape-toolbar .company-graph-layerbar { flex: 1 1 350px; border-radius: 6px; padding: 3px; }
  #companiesView .company-cytoscape-toolbar > div:last-child { display: flex; flex-wrap: wrap; gap: 4px; }
  #companiesView .company-graph-selection { display: grid; gap: 3px; flex: 1 1 220px; min-width: 0; max-width: 320px; }
  #companiesView .company-graph-selection select { width: 100%; min-width: 0; min-height: 34px; }
  #companiesView .company-cytoscape-inspector :is(strong, small, span) { white-space: normal; overflow-wrap: anywhere; }
  #companiesView .company-cytoscape-keyhint { padding: 5px 10px; }
  #companiesView .company-graph-legend { gap: 8px 16px; padding-block: 6px; }
  .skat-reader-design #companiesView #companyGraph:fullscreen .company-cytoscape-frame { height: 100%; }
}

/* Integrated CVR facts and report periods: readable labels, no fact chips. */
@media screen and (min-width: 1121px) {
  #companiesView #companyProfileBrief .company-overview-facts .company-pass-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 24px; }
  #companiesView #companyProfileBrief .company-overview-facts .company-pass-facts > span { display: block; min-height: 0; padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; color: var(--ink); font-size: 14px; font-weight: 400; line-height: 1.5; }
  #companiesView #companyProfileBrief .company-overview-facts .company-pass-facts > span > b { display: block; margin-bottom: 4px; color: var(--muted); font-size: 12px; font-weight: 500; line-height: 1.4; text-transform: none; letter-spacing: normal; }
  #companiesView .company-accounts-head > div { min-width: 0; }
  #companiesView .company-accounts-head > div > :is(span, strong, small) { display: block; margin: 0; white-space: normal; overflow-wrap: anywhere; line-height: 1.5; }
  #companiesView .company-accounts-head > div > :is(span, strong, small) + :is(span, strong, small) { margin-top: 6px; }
  #companiesView .company-accounts-head > div > strong { font-size: 16px; }
  #companiesView .company-accounts-head > div > small { font-size: 13px; }
}
@media screen and (min-width: 1400px) {
  #companiesView #companyProfileBrief .company-overview-facts .company-pass-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Extended CVR: one desktop relation workspace; existing tools/details retained. */
@media screen and (min-width: 1121px) {
  #companiesView #companyPanelAccounts .company-document-source-item { display: grid; gap: 10px; min-width: 0; padding-block: 10px; }
  #companiesView #companyPanelAccounts .company-document-source-item > div:first-child { display: grid; gap: 5px; min-width: 0; }
  #companiesView #companyPanelAccounts .company-document-source-item > div:first-child > :is(strong, span, small) { display: block; margin: 0; line-height: 1.5; white-space: normal; overflow-wrap: anywhere; }
  #companiesView #companyPanelAccounts .company-document-source-item small:empty { display: none; }
  #companiesView #companyPanelAccounts .company-report-main > :is(strong, span, small) { display: block; margin: 0 0 5px; line-height: 1.5; white-space: normal; overflow-wrap: anywhere; }
  #companiesView #companyPanelAccounts .company-report-actions { flex-wrap: wrap; gap: 8px 12px; }
  #companiesView #companyEmptyState > ul > li { margin-block: 12px; }
  #companiesView #companyEmptyState > ul > li > :is(strong, span, small) { display: block; margin-block: 0 5px; line-height: 1.5; overflow-wrap: anywhere; }
}

@media screen and (min-width: 1121px) {
  #companiesView [data-company-timeline-form] { display: flex; flex-wrap: wrap; align-items: end; gap: 10px 14px; margin-block: 12px; }
  #companiesView [data-company-timeline-form] label { display: flex; flex: 1 1 150px; min-width: 0; flex-direction: column; gap: 5px; }
  #companiesView [data-company-timeline-form] :is(input, select) { width: 100%; min-width: 0; box-sizing: border-box; }
  #companiesView [data-company-timeline-form] button { flex: 0 1 auto; white-space: normal; }
  #companiesView .company-relation-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; margin-bottom: 8px; }
  #companiesView .company-relation-toolbar label { font-weight: 600; }
  #companiesView #companyRelationFilter { display: block; position: static; width: min(100%, 360px); height: auto; min-height: 40px; opacity: 1; clip-path: none; }
  #companiesView :is(select, button, a, summary):focus-visible { outline: 3px solid #1466a5; outline-offset: 3px; }
  #companiesView .company-relation-scope { margin: 4px 0 10px; font-size: 13px; line-height: 1.5; color: #42566a; }
  .skat-reader-design #companiesView #companyPanelNetwork .company-graph-shell-head { padding: 0; margin: 0 0 8px; }
  .skat-reader-design #companiesView #companyGraph .company-cytoscape-frame { height: auto; min-height: 0; overflow: visible; }
  .skat-reader-design #companiesView #companyGraph .company-cytoscape-body { height: clamp(380px, 49vh, 560px); min-height: 0; grid-template-columns: minmax(0, 1fr) minmax(210px, 25%); }
  .skat-reader-design #companiesView #companyGraph .company-cytoscape-canvas { height: 100%; min-height: 0; }
  #companiesView .company-cytoscape-inspector { overflow-y: auto; min-height: 0; }
  #companiesView .company-cytoscape-toolbar { gap: 6px 12px; padding: 8px; }
  #companiesView .company-cytoscape-toolbar > div:first-child { flex: 1 1 180px; }
  #companiesView .company-relation-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; }
  #companiesView .company-relation-main { min-width: 0; }
  #companiesView .company-relation-main > span { display: block; line-height: 1.5; }
  #companiesView .company-relation-source { margin: 8px 0; font-size: 13px; line-height: 1.5; }
  #companiesView .company-relation-source > div { display: grid; grid-template-columns: minmax(110px, 30%) minmax(0, 1fr); gap: 12px; margin-block: 6px; }
  #companiesView .company-relation-source dt { color: #42566a; }
  #companiesView .company-relation-source dd { margin: 0; overflow-wrap: anywhere; }
  #companiesView .company-cytoscape-inspector .company-relation-source > div { display: block; }
  #companiesView .company-structure-details { border-top: 1px solid #dce4eb; padding-block: 14px; margin-top: 16px; }
  #companiesView .company-structure-details > summary { cursor: pointer; font-weight: 600; padding: 8px 0; }
  #companiesView .company-ownership-facts > p { line-height: 1.5; max-width: 85ch; }
  #companiesView .company-ownership-facts .ownership-row { display: block; padding-block: 12px; border-bottom: 1px solid #dce4eb; }
  #companiesView .company-ownership-facts .ownership-row > :is(strong, span) { display: block; }
  .skat-reader-design #companiesView #companyGraph:fullscreen .company-cytoscape-frame { display: flex; height: 100%; overflow: hidden; }
  .skat-reader-design #companiesView #companyGraph:fullscreen .company-cytoscape-body { flex: 1 1 auto; height: auto; min-height: 0; }
}
