.bp-base44-shell {
  --bp-shell-rail: 256px;
  --bp-shell-bg: #fbfdfc;
  --bp-shell-card: #353d4b;
  --bp-shell-card-line: #242c39;
  --bp-shell-card-text: #eef7f2;
  --bp-shell-card-muted: #bfd0c8;
  --bp-shell-card-faint: #94a69d;
  --bp-shell-ink: #102017;
  --bp-shell-muted: #5f756b;
  --bp-shell-gold: #e3a900;
  --bp-shell-soft-gold: #fff5dc;
  --bp-shell-soft-green: #e9f5f1;
  background: var(--bp-shell-bg) !important;
  color: var(--bp-shell-ink);
}

.bp-base44-shell .bp-b44-rail,
.bp-base44-shell .bp-b44-mobile,
.bp-base44-shell .bp-b44-pagebar {
  font-family: Inter, system-ui, -apple-system, Segoe UI, sans-serif;
}

.bp-b44-rail {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 3000;
  display: flex;
  width: var(--bp-shell-rail);
  flex-direction: column;
  overflow: hidden;
  border-right: 1px solid #dbe6e1;
  background: rgba(250,252,251,.98);
  color: var(--bp-shell-ink);
  box-shadow: none;
}

.bp-b44-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 72px;
  padding: 14px 16px;
  border-bottom: 1px solid #dbe6e1;
  color: inherit;
  text-decoration: none;
}

.bp-b44-brand img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  border-radius: 6px;
  background: white;
}

.bp-b44-brand strong {
  display: block;
  color: var(--bp-shell-ink);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.1;
  text-transform: uppercase;
}

.bp-b44-brand span {
  display: block;
  color: var(--bp-shell-muted);
  font-size: 10px;
  line-height: 1.25;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.bp-b44-nav {
  display: grid;
  gap: 19px;
  flex: 1;
  overflow-y: auto;
  padding: 16px 16px 18px;
}

.bp-b44-group {
  display: grid;
  gap: 4px;
  margin: 0;
}

.bp-b44-group h2 {
  margin: 4px 10px 5px;
  color: #8ba09a;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .13em;
  line-height: 1.2;
  text-transform: uppercase;
}

.bp-b44-nav a {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 45px;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #4f665d;
  text-decoration: none;
  font-size: 13px;
  font-weight: 650;
}

.bp-b44-nav a::before {
  display: none;
  content: none;
}

.bp-b44-nav a:hover,
.bp-b44-nav a.bp-active {
  border-color: #f5df9f;
  background: var(--bp-shell-soft-gold);
  color: #d69a00;
}

.bp-b44-nav a.bp-active::after {
  color: #d69a00;
  content: ">";
  font-size: 18px;
  font-weight: 500;
}

.bp-b44-nav small {
  display: none;
}

.bp-b44-foot {
  display: grid;
  gap: 8px;
  padding: 14px 16px 16px;
  border-top: 1px solid #dbe6e1;
}

.bp-b44-foot a,
.bp-b44-foot div {
  display: block;
  border-radius: 8px;
  padding: 11px 12px;
  text-decoration: none;
}

.bp-b44-foot a {
  border: 1px solid #f0d282;
  background: #fff5dc;
  color: #d69a00;
  font-size: 12px;
  font-weight: 800;
}

.bp-b44-foot span {
  display: block;
  color: #6d8078;
  font-size: 10px;
  font-weight: 500;
}

.bp-b44-foot div {
  background: #eef5f1;
  color: #102017;
}

.bp-b44-foot strong {
  display: block;
  font-size: 12px;
}

.bp-b44-pagebar {
  position: sticky;
  top: 0;
  z-index: 2000;
  display: flex;
  min-height: 56px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 0;
  padding: 10px 24px;
  border-bottom: 1px solid #dbe6e1;
  background: rgba(250,252,251,.97);
  color: var(--bp-shell-ink);
  backdrop-filter: blur(16px);
}

.bp-b44-title {
  min-width: 190px;
}

.bp-b44-pagebar strong {
  display: block;
  font-size: 15px;
  font-weight: 800;
}

.bp-b44-pagebar span {
  display: block;
  color: #6d8078;
  font-size: 11px;
}

.bp-b44-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}

.bp-b44-search {
  position: relative;
  display: flex;
  align-items: center;
  width: min(360px, 32vw);
  min-width: 220px;
  margin: 0;
}

.bp-b44-search > span {
  position: absolute;
  left: 14px;
  width: 16px;
  height: 16px;
  overflow: hidden;
  border: 1.8px solid #5f756b;
  border-radius: 999px;
  color: transparent;
}

.bp-b44-search > span::after {
  position: absolute;
  right: -5px;
  bottom: -3px;
  width: 8px;
  height: 2px;
  border-radius: 999px;
  background: #5f756b;
  content: "";
  transform: rotate(45deg);
}

.bp-b44-search input {
  width: 100%;
  min-height: 44px;
  margin: 0;
  border: 0;
  border-radius: 8px;
  background: #e8f3ef;
  color: #4e6a60;
  font: inherit;
  font-size: 13px;
  padding: 11px 14px 11px 40px;
}

.bp-b44-search-results {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  left: 0;
  z-index: 3200;
  display: none;
  overflow: hidden;
  border: 1px solid #dbe6e1;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 18px 60px rgba(30, 51, 42, .18);
}

.bp-b44-search-results.open {
  display: grid;
}

.bp-b44-search-results a {
  display: grid;
  gap: 2px;
  min-height: auto;
  padding: 10px 12px;
  border-bottom: 1px solid #edf3f0;
  color: #102017;
  text-decoration: none;
}

.bp-b44-search-results a:hover {
  background: #fff5dc;
}

.bp-b44-search-results strong {
  font-size: 13px;
  line-height: 1.2;
}

.bp-b44-search-results span {
  color: #5f756b;
  font-size: 11px;
  line-height: 1.3;
}

.bp-b44-tools a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #4e6a60;
  font-size: 11px;
  font-weight: 800;
  padding: 8px;
  text-align: center;
  text-decoration: none;
}

.bp-b44-tools a:last-child {
  position: relative;
}

.bp-b44-tools a:last-child::after {
  position: absolute;
  top: 6px;
  right: 4px;
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: #e3a900;
  content: "";
}

.bp-b44-mobile {
  display: none;
}

.bp-base44-shell > header.nav,
.bp-headerless-tool .hdr,
.bp-headerless-tool .app-header {
  display: none !important;
}

@media (min-width: 1021px) {
  .bp-base44-shell {
    padding-left: var(--bp-shell-rail);
  }

  .bp-base44-shell .top {
    display: none !important;
  }

  .bp-base44-shell > header.nav,
  .bp-base44-shell .hdr,
  .bp-base44-shell .app-header {
    display: none !important;
  }

  .bp-base44-shell .wrap,
  .bp-base44-shell .shell,
  .bp-base44-shell main {
    max-width: min(1584px, calc(100vw - var(--bp-shell-rail)));
  }

  .bp-base44-shell .wrap {
    padding-top: 24px;
  }
}

.bp-base44-shell .card,
.bp-base44-shell .tool-card,
.bp-base44-shell .status-card,
.bp-base44-shell .panel,
.bp-base44-shell .chart-card,
.bp-base44-shell .metric-card,
.bp-base44-shell .kpi-card,
.bp-base44-shell .action-card,
.bp-base44-shell .module,
.bp-base44-shell .valuation-card {
  border-color: var(--bp-shell-card-line) !important;
  border-radius: 8px !important;
}

.bp-base44-shell .card:not(.hero),
.bp-base44-shell .tool-card,
.bp-base44-shell .status-card,
.bp-base44-shell .panel,
.bp-base44-shell .chart-card,
.bp-base44-shell .metric-card,
.bp-base44-shell .kpi-card,
.bp-base44-shell .action-card,
.bp-base44-shell .module,
.bp-base44-shell .valuation-card {
  background: var(--bp-shell-card) !important;
  color: var(--bp-shell-card-text) !important;
}

.bp-base44-shell .card:not(.hero) h1,
.bp-base44-shell .card:not(.hero) h2,
.bp-base44-shell .card:not(.hero) h3,
.bp-base44-shell .tool-card h1,
.bp-base44-shell .tool-card h2,
.bp-base44-shell .tool-card h3,
.bp-base44-shell .chart-card h1,
.bp-base44-shell .chart-card h2,
.bp-base44-shell .chart-card h3,
.bp-base44-shell .metric-card h1,
.bp-base44-shell .metric-card h2,
.bp-base44-shell .metric-card h3,
.bp-base44-shell .kpi-card h1,
.bp-base44-shell .kpi-card h2,
.bp-base44-shell .kpi-card h3,
.bp-base44-shell .module h1,
.bp-base44-shell .module h2,
.bp-base44-shell .module h3 {
  color: var(--bp-shell-card-text) !important;
}

.bp-base44-shell .card:not(.hero) p,
.bp-base44-shell .status-card p,
.bp-base44-shell .panel p,
.bp-base44-shell .tool-card p,
.bp-base44-shell .chart-card p,
.bp-base44-shell .metric-card p,
.bp-base44-shell .kpi-card p,
.bp-base44-shell .module p,
.bp-base44-shell .fine {
  color: var(--bp-shell-card-muted) !important;
}

.bp-base44-shell .card:not(.hero) .muted,
.bp-base44-shell .card:not(.hero) .fine,
.bp-base44-shell .status-card .muted,
.bp-base44-shell .panel .muted,
.bp-base44-shell .tool-card .muted,
.bp-base44-shell .chart-card .muted,
.bp-base44-shell .metric-card .muted,
.bp-base44-shell .kpi-card .muted,
.bp-base44-shell .module .muted,
.bp-base44-shell .eyebrow,
.bp-base44-shell .label {
  color: var(--bp-shell-card-faint) !important;
}

.bp-base44-shell .table-wrap,
.bp-base44-shell .tablewrap,
.bp-base44-shell .out,
.bp-base44-shell .result-box,
.bp-base44-shell .copybox,
.bp-base44-shell .ai-output {
  border-color: rgba(255,255,255,.72) !important;
  border-radius: 8px !important;
  color: var(--bp-shell-card-muted) !important;
}

.bp-base44-shell .btn.primary,
.bp-base44-shell button.primary {
  background: #e3a900 !important;
  color: #07100b !important;
}

.bp-base44-shell .btn,
.bp-base44-shell button,
.bp-base44-shell a.btn {
  border-radius: 8px !important;
}

.bp-base44-shell input,
.bp-base44-shell textarea,
.bp-base44-shell select {
  border-color: transparent !important;
  background: #deebe7 !important;
  color: #1e332a !important;
}

.bp-base44-shell.bp-investment-studio > header {
  position: sticky !important;
  top: 56px !important;
  z-index: 1900 !important;
  display: flex !important;
  min-height: auto !important;
  padding: 8px 24px !important;
  border-bottom: 1px solid #dbe6e1 !important;
  background: rgba(250,252,251,.96) !important;
  backdrop-filter: blur(14px) !important;
}

.bp-base44-shell.bp-investment-studio > header > .logo,
.bp-base44-shell.bp-investment-studio > header > .nav-hamburger,
.bp-base44-shell.bp-investment-studio > header > .header-right {
  display: none !important;
}

.bp-base44-shell.bp-investment-studio .nav-tabs {
  width: 100% !important;
  gap: 8px !important;
  justify-content: flex-start !important;
  overflow-x: auto !important;
}

.bp-base44-shell.bp-investment-studio .nav-tab {
  min-height: 38px !important;
  border: 1px solid #dbe6e1 !important;
  border-radius: 8px !important;
  background: #f7fbf9 !important;
  color: #536a61 !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  padding: 9px 12px !important;
}

.bp-base44-shell.bp-investment-studio .nav-tab.active {
  border-color: #f0d282 !important;
  background: #fff5dc !important;
  color: #d69a00 !important;
}

.bp-base44-shell.bp-investment-studio .app,
.bp-base44-shell.bp-investment-studio .container {
  max-width: min(1584px, calc(100vw - var(--bp-shell-rail))) !important;
}

@media (max-width: 1020px) {
  .bp-b44-rail {
    width: min(86vw, 318px);
    transform: translateX(-112%);
    transition: transform .18s ease;
    box-shadow: 0 20px 70px rgba(0,0,0,.24);
  }

  .bp-base44-shell.bp-b44-open .bp-b44-rail {
    transform: translateX(0);
  }

  .bp-b44-mobile {
    position: sticky;
    top: 0;
    z-index: 2999;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border-bottom: 1px solid #dbe6e1;
    background: rgba(250,252,251,.97);
    color: var(--bp-shell-ink);
    backdrop-filter: blur(14px);
  }

  .bp-b44-mobile button {
    min-height: 38px;
    border: 1px solid #f0d282;
    border-radius: 8px;
    background: #fff5dc;
    color: #d69a00;
    cursor: pointer;
    font-weight: 900;
    padding: 8px 12px;
  }

  .bp-b44-pagebar {
    top: 59px;
    flex-wrap: wrap;
    padding: 10px 14px;
  }
}
