/* Shared screen layout: preserve print layouts and existing visual theme. */
@media screen {
  .page-shell, .page-shell.admin-wide-main {width:auto;max-width:1460px;margin:0 auto 70px;padding-inline:clamp(12px,2vw,32px)}
  .page-shell.admin-wide-main,.admin-surface .page-shell {max-width:none}
  .topbar {position:relative;flex-wrap:wrap;height:auto;gap:12px 24px;padding:12px clamp(12px,3vw,56px)}
  .topbar-left {flex:1 1 600px;flex-wrap:wrap;gap:10px 16px;min-width:0}
  .topbar .brand {flex:1 1 340px;min-width:0;max-width:100%;flex-wrap:wrap}
  .brand-logo {flex:0 1 210px;max-width:100%;height:auto;max-height:58px;object-fit:contain}
  .brand-portal-name {flex:1 1 180px;min-width:0;white-space:normal}
  .topbar .brand strong,.portal-title-heading {white-space:normal;overflow-wrap:anywhere}
  .nav-links {position:static;display:flex;flex:0 1 auto;flex-wrap:wrap;gap:8px;max-width:100%;margin-left:auto}
  .nav-links a,.topbar .link-button {min-height:44px;display:inline-flex;align-items:center;justify-content:center;white-space:normal;text-align:center}
  .preview-banner,.investor-context-bar,.holdings-heading,.investor-frame-heading,.panel-heading,.page-header,.admin-workspace-title-row {flex-wrap:wrap;min-width:0;gap:12px}
  .page-header > *, .panel-heading > *, .holdings-heading > *, .investor-frame-heading > * {min-width:0;max-width:100%}
  .page-header h1,h2,h3,h4,.holdings-as-of,.dashboard-investor-identity,.investor-context-bar strong {white-space:normal;overflow-wrap:anywhere}
  .page-header > div:has(> h1) {display:flex;flex-wrap:wrap;gap:8px 24px}
  .holdings-as-of {min-width:0;flex:1 1 220px}
  .admin-workspace-title-row {position:static;left:auto;width:100%;margin-left:0}
  .admin-workspace-indicator {display:flex;flex-wrap:wrap;justify-content:center;padding:10px 16px;gap:10px 24px}
  .admin-workspace-indicator strong {min-width:0;overflow-wrap:anywhere}
  .admin-workspace-indicator > span {display:none}
  .admin-workspace-nav,.admin-input-nav-left,.admin-input-nav-right,.admin-review-workspace-nav,.subnav {min-width:0;max-width:100%;flex-wrap:wrap}
  .admin-workspace-nav a,.admin-review-workspace-nav a,.admin-review-mode-tabs a,.investor-section-tab,.subnav a {white-space:normal;overflow-wrap:anywhere;min-width:0;min-height:44px}
  .button,button,summary.button {white-space:normal;max-width:100%;overflow-wrap:anywhere}
  .button-row,.filter-bar {min-width:0;max-width:100%}
  .button-row > *, .inline-form {max-width:100%;min-width:0}
  .page-shell :is(section,article,aside,form,fieldset,label),.page-shell [class*="grid"] > *, .document-preview-workspace > * {min-width:0}
  input,select,textarea {min-width:0;max-width:100%}
  img,iframe,video,canvas {max-width:100%}
  .auth-card {width:100%;max-width:520px;padding:clamp(18px,4vw,34px)}
  .auth-card-wide {max-width:820px}
  .qr-panel {max-width:100%}
  .table-wrap,.admin-compact-document-workspace .table-wrap {width:100%;max-width:100%;min-width:0;overflow-x:auto}
  .table-wrap:focus-visible {outline:2px solid var(--blue);outline-offset:2px}
  .table-wrap > table {min-width:100%}
  .nav-aggregate-table {min-width:1200px}
  .document-preview-workspace,.admin-wide-preview-workspace,.admin-review-investor-preview-workspace {min-width:0;max-width:100%}
  .document-list-panel,.admin-review-preview-workspace .document-list-panel {min-width:0;overflow:visible}
  .document-preview-pane,.admin-review-investor-preview-pane {min-width:0;max-width:100%;position:static}
  .document-preview-frame,.admin-review-investor-preview-pane iframe {width:100%;max-width:100%;min-width:0;height:65vh;min-height:260px}
  .position-projection {min-width:0;max-width:100%;flex:1 1 500px}
  .positions-title-row {flex-wrap:wrap;min-width:0}
  .position-projection table {min-width:470px}
  .position-target-controls {max-width:100%}
  .positions-total-notional {display:flex;flex-wrap:wrap;justify-content:space-between;gap:12px}
  .positions-overall-pl {float:none;margin-left:0}
  .holding-metric {min-width:0;flex-wrap:wrap;gap:8px}
  .holding-metric strong {max-width:100%;white-space:normal;overflow-wrap:anywhere}
  .compact-nav-form > label {grid-template-rows:auto 36px auto}
  .workspace-number,.portal-menu-icon {position:static;float:right;margin:0 0 8px 12px}
}
@media screen and (max-width:1199px) {
  .document-preview-workspace.preview-active,.admin-wide-preview-workspace.preview-active,.admin-review-investor-preview-workspace.preview-active {grid-template-columns:minmax(0,1fr)}
  .admin-wide-preview-workspace > .document-preview-pane {grid-column:1}
  .investor-detail-grid,.investors-layout,.two-column {grid-template-columns:minmax(0,1fr)}
  .holdings-dashboard-grid {grid-template-columns:minmax(0,1fr)}
  .review-latest-dashboard {grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media screen and (max-width:991px) {
  .topbar-left {flex-basis:100%}
  .nav-links {width:100%;margin:0}
  .admin-workspace-nav,.admin-review-document-columns,.actions-email-grid,.portal-data-preparation-grid,.fund-live-comparison {grid-template-columns:minmax(0,1fr)}
  .admin-input-nav-right {border-left:0;padding-left:0}
  .fund-review-mode-tabs {grid-template-columns:repeat(2,minmax(0,1fr))}
  .fund-review-mode-tabs .fund-mode-positions,.fund-review-mode-tabs .fund-mode-investor-details {grid-column:auto}
  .history-controls-summary {grid-template-columns:minmax(0,1fr)}
  .filter-bar,.bulk-upload-settings,.profile-summary-grid,.form-grid {grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media screen and (max-width:767px) {
  .page-header,.panel-heading {flex-direction:column;align-items:stretch}
  .topbar-left {flex-direction:row;align-items:center}
  .topbar .brand {order:-1;flex-basis:100%}
  .nav-links > a,.nav-links > form {flex:1 1 auto}
  .topbar .brand strong {font-size:18px}
  .admin-workspace-nav a,.button,.link-button,select,input:not([type=checkbox]):not([type=radio]) {min-height:44px}
  .panel {padding:16px}
  .investor-frame-heading,.holdings-heading {flex-direction:column;align-items:stretch}
  .holdings-as-of {flex-basis:auto;text-align:left}
  .admin-review-mode-tabs,.fund-review-mode-tabs {display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  .admin-review-workspace-nav,.admin-input-nav-left,.admin-input-nav-right {display:flex;flex-wrap:wrap;flex-direction:row}
  .admin-review-workspace-nav a,.admin-input-nav-left a,.admin-input-nav-right a {flex:1 1 150px}
  .mfa-grid,.activation-grid,.nav-management-actions,.nav-capital-tables,.portal-menu-grid,.scan-date-range {grid-template-columns:minmax(0,1fr)}
  .rename-form {min-width:0;grid-template-columns:minmax(0,1fr)}
  .nav-presentation-buttons .button {min-width:0;flex:1 1 180px}
  .monthly-high-box {width:100%}
  .investor-data-actions > .button {flex:1 1 160px;width:auto}
  .position-leak-box table,.position-fees-box table {min-width:470px}
}
@media screen and (max-width:575px) {
  .brand-logo {flex-basis:160px;max-width:160px}
  .brand-portal-name {flex-basis:100%}
  .filter-bar,.form-grid,.profile-summary-grid,.data-source-summary,.email-envelope,.email-summary-grid,.bulk-upload-settings,.capital-activity-grid,.investor-document-filter-bar,.portal-data-diff-grid {grid-template-columns:minmax(0,1fr)}
  .fund-performance-metrics,.holdings-metrics,.review-latest-dashboard {grid-template-columns:repeat(2,minmax(0,1fr))}
  .holding-metric {flex-direction:column;align-items:flex-start}
  .holding-metric strong {text-align:left;font-size:18px}
  .investor-context-bar {align-items:flex-start}
  .monthly-high-row,.monthly-high-row + .monthly-high-row {grid-template-columns:repeat(2,minmax(0,1fr))}
  .admin-workspace-indicator a {width:100%;justify-content:center}
  .bulk-drop-zone {padding:16px}
}
@media screen {
  .actions-attachment-row > * {min-width:0;overflow-wrap:anywhere}
  .actions-attachment-row > :nth-child(n+3) {grid-column:2}
}
@media screen and (max-width:991px) {
  .admin-compact-document-workspace table {min-width:760px;table-layout:auto}
}
/* Investor dashboard: transfer ten percent of the fund panel to holdings. */
@media screen {
  .holdings-dashboard-grid {grid-template-columns:minmax(0,1.82fr) minmax(0,1.08fr)}
  .fund-performance-frame > .fund-performance-metrics {grid-auto-rows:1fr}
  .fund-performance-frame > .fund-performance-metrics > .holding-metric {flex-direction:column;align-items:center;text-align:center;justify-content:center;gap:8px}
  .fund-performance-frame > .fund-performance-metrics strong {text-align:center;white-space:normal}
  .investor-section-tab,.theme-ocean-trust .investor-section-tab {background:#075f8d;color:#fff;border-color:#075f8d}
  .investor-section-tab:hover,.investor-section-tab.active {background:#064b70;color:#fff}
}
@media screen and (max-width:1199px) {
  .holdings-dashboard-grid {grid-template-columns:minmax(0,1fr)}
}
@media screen {
 .theme-ocean-trust .investor-section-tabs .investor-section-tab {background:#075f8d !important;color:white !important;border-color:#075f8d !important}
 .theme-ocean-trust .investor-section-tabs .investor-section-tab:hover {background:#064b70 !important}
}
@media screen {
 .fund-performance-frame > .fund-performance-metrics > .holding-metric {flex-direction:row;align-items:center;justify-content:space-between;text-align:left;gap:10px;padding:8px 10px;min-height:76px}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric span {text-align:left}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric strong {text-align:right}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric:last-child strong {font-weight:400;font-size:18px}
}
@media screen {
 .fund-performance-frame > .fund-performance-metrics > .holding-metric > span {flex:1 1 45%;min-width:0}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric > strong {flex:1 1 55%;min-width:0;line-height:1.05}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric:last-child > span {flex-basis:35%}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric:last-child > strong {flex-basis:65%}
}
@media screen {
 .fund-performance-frame > .fund-performance-metrics {grid-template-rows:repeat(3,minmax(76px,auto));grid-auto-rows:auto;align-content:start}
}
@media screen and (min-width:1200px) {
 .fund-performance-frame > .fund-performance-metrics {grid-template-rows:repeat(3,76px)}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric {height:76px;min-height:0}
}
/* Equal holdings cells and top-aligned fund labels/values. */
@media screen {
 .investor-metrics-frame > .holdings-metrics {grid-auto-rows:1fr}
 .investor-metrics-frame > .holdings-metrics > .holding-metric {height:100%;box-sizing:border-box}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric {align-items:flex-start}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric > span,
 .fund-performance-frame > .fund-performance-metrics > .holding-metric > strong {margin-top:0;line-height:1.25}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric:last-child > strong {font-weight:700;font-size:16px}
}
@media screen {
 .fund-performance-frame > .fund-performance-metrics > .holding-metric {display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-content:start;align-items:start}
 .fund-performance-frame > .fund-performance-metrics > .holding-metric:last-child {grid-template-columns:minmax(0,.7fr) minmax(0,1.3fr)}
}
@media screen {
 .fund-metrics-exited > .exited-nav-metric {grid-column:1;grid-row:1}
 .fund-metrics-exited > .exited-nav-metric + article {grid-column:1;grid-row:2}
 .fund-performance-frame > .fund-metrics-exited {grid-template-rows:repeat(4,minmax(76px,auto))}
}
@media screen and (min-width:1200px) {
 .fund-performance-frame > .fund-metrics-exited {grid-template-rows:repeat(4,76px)}
}
@media screen {
 .fund-metrics-exited > article:nth-child(3) {grid-column:2;grid-row:2}
 .fund-metrics-exited > article:nth-child(4) {grid-column:1;grid-row:3}
 .fund-metrics-exited > article:nth-child(5) {grid-column:2;grid-row:3}
 .fund-metrics-exited > article:nth-child(6) {grid-column:1;grid-row:4}
 .fund-metrics-exited > article:nth-child(7) {grid-column:2;grid-row:4}
}
@media screen {
 .nav-instructions-heading {display:grid;grid-template-columns:minmax(0,2fr) minmax(0,1fr);align-items:center;gap:16px}
 .theme-ocean-trust .nav-instructions-heading .instructions-launch-button {justify-self:center;background:#f6bdd2 !important;border-color:#d985a5 !important;color:#5d2440 !important;font-size:18.2px;padding:13px 23.4px;min-height:57px;text-align:center;white-space:normal}
 .theme-ocean-trust .nav-instructions-heading .instructions-launch-button:hover {background:#efa9c3 !important}
}
@media screen and (max-width:767px) {
 .nav-instructions-heading {grid-template-columns:minmax(0,1fr)}
 .nav-instructions-heading .instructions-launch-button {justify-self:end}
}
.nav-price-total-inputs {display:grid;gap:12px;min-width:0;align-content:start}

.nav-instructions-heading {grid-template-columns:minmax(0,1fr) auto}
.nav-heading-actions {display:flex;align-items:stretch;justify-content:flex-end;gap:12px;flex-wrap:wrap}
.theme-ocean-trust .nav-heading-actions .nav-test-launch-button {background:#b91c1c !important;border-color:#991b1b !important;color:#fff !important;font-size:18.2px;padding:13px 23.4px;min-height:57px;display:inline-flex;align-items:center;justify-content:center;text-align:center}
.theme-ocean-trust .nav-heading-actions .nav-test-launch-button:hover {background:#991b1b !important}
@media(max-width:900px) {.nav-instructions-heading {grid-template-columns:minmax(0,1fr)} .nav-heading-actions {justify-content:flex-start}}
