:root {
  --bg: #f7f2ea;
  --panel: #fffdf8;
  --ink: #16171d;
  --muted: #6c6673;
  --line: #e5d9ca;
  --soft: #f8efe4;
  --accent: #1f42ff;
  --accent-2: #006dff;
  --good: #007a55;
  --bad: #c92a2a;
  --warn: #9a5200;
  --accent-soft: #e7ecff;
  --blue-soft: #eaf2ff;
  --green-soft: #e2f7ea;
  --red-soft: #fff0ed;
  --warn-soft: #fff0cb;
  --violet-soft: #f2ecff;
  --peach-soft: #ffe6dc;
  --shadow: 0 22px 54px rgba(44, 34, 20, 0.11);
  --shadow-strong: 0 32px 80px rgba(44, 34, 20, 0.18);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 10% -10%, rgba(255, 210, 113, 0.42), transparent 28%),
    radial-gradient(circle at 94% 8%, rgba(31, 66, 255, 0.15), transparent 30%),
    linear-gradient(180deg, #fff8eb 0%, var(--bg) 45%, #eef7ee 100%);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans TC", sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
}

.shell {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(112, 76, 21, 0.14);
  background: rgba(255, 251, 243, 0.9);
  backdrop-filter: saturate(180%) blur(20px);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
  gap: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, #1f42ff 0%, #06a77d 55%, #ffd166 100%);
  color: #fff;
  font-weight: 800;
  box-shadow: 0 12px 28px rgba(31, 66, 255, 0.24);
}

.brand-mark.small {
  width: 34px;
  height: 34px;
  font-size: 14px;
}

.brand-title {
  display: block;
  font-size: 16px;
  font-weight: 850;
  line-height: 1.1;
}

.brand-subtitle {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.nav-actions {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.customer-menu {
  position: relative;
}

.customer-menu summary,
.history-menu summary {
  display: list-item;
  list-style: none;
  cursor: pointer;
}

.customer-menu summary::-webkit-details-marker,
.history-menu summary::-webkit-details-marker {
  display: none;
}

.history-menu {
  position: relative;
}

.history-hidden-summary {
  position: fixed;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.history-menu summary.history-hidden-summary {
  display: block;
}

.history-backdrop {
  display: none;
}

.history-menu[open] .history-backdrop {
  position: fixed;
  inset: 0;
  z-index: 34;
  display: block;
  background: rgba(29, 29, 31, 0.38);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.customer-menu-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  z-index: 30;
  display: grid;
  gap: 12px;
  width: min(440px, calc(100vw - 32px));
  max-height: min(680px, calc(100vh - 86px));
  overflow: auto;
  padding: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.14);
}

.history-menu-panel {
  position: fixed;
  left: 50%;
  top: 72px;
  transform: translateX(-50%);
  z-index: 35;
  width: min(760px, calc(100vw - 32px));
  max-height: calc(100vh - 104px);
  overflow: auto;
  padding: 18px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.22);
}

.icon-close {
  display: inline-grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #f5f5f7;
  color: var(--muted);
  font-size: 22px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
}

.icon-close:hover {
  background: var(--blue-soft);
  color: var(--accent-2);
}

.customer-menu-panel > a,
.customer-menu-panel details {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fbfbfd;
  text-decoration: none;
}

.customer-menu-panel summary {
  font-weight: 800;
}

.page {
  padding: 34px 0 54px;
}

.page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.06;
  letter-spacing: 0;
  font-weight: 800;
  max-width: 920px;
}

h2 {
  font-size: 24px;
  letter-spacing: 0;
  font-weight: 800;
}

h3 {
  font-size: 16px;
  letter-spacing: 0;
}

.subtle {
  color: var(--muted);
}

.good-text {
  color: var(--good);
}

.bad-text {
  color: var(--bad);
}

.grid {
  display: grid;
  gap: 20px;
}

.grid.two {
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
}

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

.grid.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.panel {
  position: relative;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 22px;
  background: #fffdf8;
  box-shadow: var(--shadow);
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  border-radius: 22px 22px 0 0;
  background: linear-gradient(90deg, var(--accent) 0%, #06a77d 52%, #ffd166 100%);
}

.panel-pad {
  padding: 24px;
}

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

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-grid.one {
  grid-template-columns: 1fr;
}

.split-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.label-before,
.label-after {
  display: inline-block;
  margin-right: 4px;
  font-weight: 850;
}

.label-before {
  color: var(--ink-muted);
}

.label-after {
  color: var(--green);
}

.field {
  display: grid;
  gap: 7px;
}

.field.full {
  grid-column: 1 / -1;
}

label {
  color: #424245;
  font-size: 13px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fffaf1;
  color: var(--ink);
  font: inherit;
  padding: 10px 12px;
  outline: none;
}

textarea {
  min-height: 92px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(31, 66, 255, 0.16);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  gap: 8px;
  border: 1px solid rgba(132, 92, 30, 0.22);
  border-radius: 999px;
  background: #fffdf8;
  color: var(--ink);
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  padding: 8px 16px;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(44, 34, 20, 0.05);
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(44, 34, 20, 0.1);
}

.btn.primary {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 30px rgba(31, 66, 255, 0.28);
}

.btn.blue {
  border-color: #bfd0ff;
  background: var(--blue-soft);
  color: var(--accent-2);
}

.btn.ghost {
  background: transparent;
}

.btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.search {
  flex: 1 1 320px;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  border-bottom: 1px solid rgba(132, 92, 30, 0.14);
  padding: 14px 12px;
  text-align: left;
  vertical-align: middle;
}

.table th {
  color: var(--muted);
  font-size: 13px;
  background: rgba(255, 243, 214, 0.46);
}

.table td.emphasis {
  border-radius: 10px;
  font-weight: 900;
}

.table td.emphasis.good-text {
  background: #e2f7ea;
}

.table td.emphasis.bad-text {
  background: #fff0ed;
}

.table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-gutter: stable;
  overscroll-behavior-x: contain;
}

.table-scroll::-webkit-scrollbar {
  height: 8px;
}

.table-scroll::-webkit-scrollbar-track {
  background: #f5f5f7;
}

.table-scroll::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: #c7c7cc;
}

.scenario-table {
  width: max-content;
  min-width: 1480px;
  table-layout: auto;
}

.scenario-table th,
.scenario-table td {
  min-width: 132px;
  white-space: nowrap;
}

.scenario-table th:nth-child(1),
.scenario-table td:nth-child(1) {
  min-width: 110px;
}

.scenario-table th:nth-child(4),
.scenario-table td:nth-child(4),
.scenario-table th:nth-child(5),
.scenario-table td:nth-child(5),
.scenario-table th:nth-child(6),
.scenario-table td:nth-child(6),
.scenario-table th:nth-child(7),
.scenario-table td:nth-child(7),
.scenario-table th:nth-child(8),
.scenario-table td:nth-child(8) {
  min-width: 190px;
}

.scenario-table td.year-difference,
.scenario-table td.year-difference.good-text,
.scenario-table td.year-difference.bad-text,
.scenario-table td.no-fill,
.scenario-table td.no-fill.good-text,
.scenario-table td.no-fill.bad-text,
.scenario-table td:nth-child(6),
.scenario-table td:nth-child(7),
.scenario-table td:nth-child(8) {
  background: transparent !important;
  background-color: transparent !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  font-weight: 900;
}

.scenario-footnote {
  padding-top: 8px;
}

.empty {
  padding: 34px;
  text-align: center;
  color: var(--muted);
}

.avatar {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 800;
}

.customer-line {
  display: flex;
  align-items: center;
  gap: 12px;
}

.metric {
  display: grid;
  gap: 7px;
  min-height: 118px;
  padding: 20px;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 22px;
  background: #fff7df;
  box-shadow: var(--shadow);
}

.metric strong {
  font-size: 30px;
  line-height: 1.15;
}

.metric.good {
  border-color: #8ddbc1;
  background: #e2f7ea;
}

.metric.bad {
  border-color: #ffb8ae;
  background: var(--red-soft);
}

.highlight-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.highlight-card {
  display: grid;
  gap: 8px;
  min-height: 132px;
  padding: 22px;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 24px;
  background: #fff7df;
  box-shadow: var(--shadow);
}

.result-card-button {
  width: 100%;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.result-card-button:hover,
.result-card-button.active {
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.highlight-card.good {
  border-color: #8ddbc1;
  background: #e2f7ea;
}

.highlight-card.stage-card-grace,
.highlight-card.stage-card-in-grace {
  border-color: #9cc3ff;
  background: #eaf2ff;
}

.highlight-card.stage-card-after {
  border-color: #f2c66d;
  background: #fff0cb;
}

.highlight-card.bad {
  border-color: #ffb8ae;
  background: var(--red-soft);
}

.highlight-card.flat {
  background: #f4f7ff;
}

.highlight-card span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.highlight-card strong {
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.05;
  letter-spacing: 0;
}

.highlight-card small {
  color: var(--muted);
  font-weight: 700;
}

.table td.stage-diff-cell {
  font-size: 18px;
}

.table td.stage-diff-cell.stage-grace {
  background: #e2f7ea;
}

.table td.stage-diff-cell.stage-after {
  background: #fff0cb;
}

.cashflow-stage-row.active {
  outline: 2px solid rgba(0, 113, 227, 0.22);
  outline-offset: -2px;
}

.source-link {
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: 6px 12px;
  background: transparent;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.source-link:hover,
.source-link.active {
  background: var(--blue-soft);
}

.source-link.stage-grace.active {
  background: var(--green-soft);
}

.source-link.stage-after.active {
  background: var(--warn-soft);
}

.source-table th:nth-child(2),
.source-table td:nth-child(2) {
  text-align: right;
}

.source-table th:nth-child(3),
.source-table td:nth-child(3) {
  text-align: right;
}

.stage-head {
  font-weight: 900;
}

.stage-head-grace {
  color: var(--accent-2);
}

.stage-head-after {
  color: #a15c00;
}

.source-table td.active-source-column {
  border-radius: 12px;
}

.source-table td:nth-child(2).active-source-column {
  background: var(--green-soft);
}

.source-table td:nth-child(3).active-source-column {
  background: var(--warn-soft);
}

.source-row td {
  font-size: 16px;
  font-weight: 800;
}

.source-value,
.source-result {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
}

.source-item {
  color: var(--muted);
}

.source-minus,
.source-equals {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  margin-right: 8px;
  color: var(--muted);
  font-weight: 900;
}

.source-total-row td {
  border-top: 1px solid #e8e8ed;
}

.source-result {
  padding: 6px 12px;
  border-radius: 12px;
  background: var(--green-soft);
  font-size: 19px;
  font-weight: 900;
}

.bad-text .source-result {
  background: var(--red-soft);
}

.source-footnote {
  padding: 0 16px 14px;
  color: #a1a1a6;
  font-size: 10px;
  line-height: 1.4;
}

.pill {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 4px 10px;
  background: #f5f5f7;
  color: #44515f;
  font-size: 13px;
  font-weight: 700;
}

.pill.good {
  background: var(--green-soft);
  color: var(--good);
}

.pill.warn {
  background: var(--warn-soft);
  color: var(--warn);
}

.pill.bad {
  background: var(--red-soft);
  color: var(--bad);
}

.pill.blue {
  background: var(--blue-soft);
  color: var(--accent-2);
}

.pill.violet {
  background: var(--violet-soft);
  color: #6a35c9;
}

.pill.stage-grace {
  background: var(--blue-soft);
  color: var(--accent-2);
}

.pill.stage-after {
  background: #fff1d6;
  color: #a15c00;
}

.step-list {
  display: grid;
  gap: 14px;
}

.step-row {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 12px;
  align-items: start;
}

.dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--line);
}

.dot.active {
  background: var(--accent);
}

.split-card {
  min-height: 314px;
}

.calc-box {
  padding: 14px;
  border: 1px solid #bfd0ff;
  border-radius: 14px;
  background: var(--blue-soft);
  color: var(--accent-2);
  font-weight: 800;
}

.stage-box {
  padding: 14px;
  border-radius: 14px;
  font-weight: 850;
}

.stage-box.stage-grace {
  border: 1px solid rgba(0, 122, 85, 0.22);
  background: var(--green-soft);
  color: var(--good);
}

.stage-box.stage-after {
  border: 1px solid rgba(154, 82, 0, 0.24);
  background: var(--warn-soft);
  color: var(--warn);
}

.formula-note {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.detail-disclosure {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fbfbfd;
  overflow: hidden;
}

.detail-disclosure summary {
  padding: 14px 16px;
  cursor: pointer;
  color: var(--accent);
  font-weight: 900;
  list-style: none;
}

.detail-disclosure summary::-webkit-details-marker {
  display: none;
}

.detail-disclosure summary::after {
  content: "＋";
  float: right;
  color: var(--muted);
}

.detail-disclosure[open] summary::after {
  content: "－";
}

.detail-disclosure .formula-note {
  margin: 0;
  padding: 0 16px 12px;
}

.detail-disclosure .table {
  background: #fff;
}

.warn-box {
  padding: 14px;
  border: 1px solid #f2d27a;
  border-radius: 14px;
  background: var(--warn-soft);
  color: #8a5a0a;
}

.summary-box {
  min-height: 118px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f7f1ff;
  line-height: 1.75;
  white-space: pre-wrap;
}

.summary-box.warn {
  border-color: #f2d27a;
  background: var(--warn-soft);
  color: #8a5a0a;
  font-weight: 800;
}

.upload-zone {
  display: grid;
  min-height: 188px;
  place-items: center;
  border: 1px dashed #9aa7b4;
  border-radius: 18px;
  background: #fbfbfd;
  text-align: center;
}

.mic {
  display: grid;
  width: 126px;
  height: 126px;
  place-items: center;
  border: 1px solid #95d7ce;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 42px;
}

.status {
  min-height: 26px;
  color: var(--muted);
  font-size: 14px;
}

.status.error {
  color: var(--bad);
  font-weight: 800;
}

.footer-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.link-list {
  display: grid;
  gap: 10px;
}

.link-list a {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  text-decoration: none;
}

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: var(--bg);
}

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

.account-box {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fbfbfd;
  color: #44515f;
  font-size: 14px;
}

@media (max-width: 900px) {
  .grid.two,
  .grid.three,
  .form-grid,
  .split-grid {
    grid-template-columns: 1fr;
  }

  .page-head,
  .topbar-inner {
    align-items: stretch;
    flex-direction: column;
  }

  .nav-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 560px) {
  .shell {
    width: min(100% - 20px, 1180px);
  }

  .panel-pad {
    padding: 15px;
  }

  .table {
    min-width: 760px;
  }

  .panel.table-wrap {
    overflow-x: auto;
  }

  .highlight-grid {
    grid-template-columns: 1fr;
  }
}

.grid.even-two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.metric {
  min-width: 0;
}

.metric strong {
  overflow-wrap: anywhere;
}

.btn.danger {
  border-color: #f3aaaa;
  background: var(--red-soft);
  color: var(--bad);
}

.step-progress {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 20px;
}

.step-progress a {
  min-height: 48px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.72);
  color: #687684;
  text-decoration: none;
  font-size: 13px;
  font-weight: 800;
}

.step-progress a.done {
  border-color: #b9d9ff;
  background: var(--accent-soft);
  color: var(--accent);
}

.step-progress a.current {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  box-shadow: 0 14px 32px rgba(31, 66, 255, 0.24);
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.check-grid label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fbfbfd;
  font-weight: 700;
}

.check-grid .investment-status-option {
  flex-wrap: wrap;
}

.check-grid .investment-status-option select {
  width: 74px;
  min-height: 32px;
  padding: 4px 8px;
  border-radius: 10px;
  font-size: 14px;
}

.check-grid .investment-status-option select:disabled {
  opacity: 0.45;
}

.check-grid input {
  width: auto;
  min-height: auto;
}

.assist-panel {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  padding: 12px 14px;
}

.assist-panel summary {
  cursor: pointer;
  font-weight: 800;
  color: var(--accent);
}

.assist-panel[open] summary {
  margin-bottom: 12px;
}

.sensitive-panel > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  list-style: none;
}

.sensitive-panel > summary::-webkit-details-marker {
  display: none;
}

.sensitive-panel > summary strong,
.sensitive-panel > summary small {
  display: block;
}

.sensitive-panel > summary small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.sensitive-panel[open] > summary {
  margin-bottom: 16px;
}

.sensitive-panel[open] .drawer-action {
  background: var(--accent);
  color: #fff;
}

.sensitive-panel + .sensitive-panel {
  margin-top: 14px;
}

.selection-drawer {
  padding: 0;
  overflow: hidden;
}

.selection-drawer > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
  padding: 18px 22px;
  cursor: pointer;
  list-style: none;
  background: #fff7df;
}

.selection-drawer > summary::-webkit-details-marker {
  display: none;
}

.selection-drawer > summary strong,
.selection-drawer > summary small {
  display: block;
}

.selection-drawer > summary strong {
  font-size: 18px;
}

.selection-drawer > summary small {
  margin-top: 4px;
  color: var(--muted);
  font-weight: 700;
}

.drawer-action {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 13px;
  background: #fbfbfd;
  color: var(--accent);
  font-weight: 900;
}

.selection-drawer[open] .drawer-action {
  background: var(--accent);
  color: #fff;
}

.selection-drawer[open] .drawer-body,
.selection-drawer[open] > .summary-box {
  border-top: 1px solid var(--line);
}

.drawer-body {
  padding: 20px 22px 22px;
}

.history-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 14px;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 18px;
  background: #fffdf8;
}

.history-summary {
  display: grid;
  flex: 1 1 360px;
  gap: 6px;
  min-width: 260px;
}

.history-time {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.35;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.info-tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 4px 10px;
  border: 1px solid #d9e0ea;
  background: #f4f7fb;
  color: #314256;
  font-size: 12px;
  font-weight: 800;
}

.info-tag.good-text {
  border-color: #9bdcbf;
  background: #dff7e8;
  color: var(--good);
}

.info-tag.difference-tag {
  min-height: 34px;
  padding: 6px 13px;
  border-color: #7fd3aa;
  background: #d8f5e5;
  color: #006b4b;
  font-size: 14px;
  font-weight: 950;
}

.info-tag.bad-text {
  border-color: #f3aaa2;
  background: var(--red-soft);
  color: var(--bad);
}

.info-tag.policy-loan-tag {
  border-color: #b9b8ff;
  background: #efefff;
  color: #4540a8;
}

.info-tag.prepayment-tag {
  border-color: #e6b46c;
  background: #fff1d6;
  color: #8a4b00;
}

.info-tag.favorite-tag {
  border-color: #e0a91f;
  background: #ffe08a;
  color: #7a4400;
}

.favorite-item {
  border-color: #e3c273;
  background: #fffaf0;
}

.favorite-card {
  align-items: stretch;
  gap: 20px;
  padding: 18px 20px;
  border-color: #e4bd5f;
  box-shadow: 0 18px 42px rgba(151, 94, 18, 0.12);
}

.favorite-card .history-summary {
  gap: 9px;
}

.favorite-card .history-summary strong {
  font-size: 20px;
  line-height: 1.25;
}

.favorite-card .toolbar {
  align-self: flex-end;
}

.favorite-card .favorite-tag {
  min-height: 24px;
  padding: 3px 9px;
  font-size: 12px;
  box-shadow: none;
}

.favorite-status {
  font-size: 13px;
  font-weight: 850;
}

.mini-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fbfbfd;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.favorite-card .mini-check {
  align-self: center;
  min-height: 44px;
  padding: 9px 13px;
  color: #4d5662;
}

.mini-check input {
  width: auto;
  min-height: auto;
}

.title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.inline-edit-button {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 6px 14px;
  border: 1px solid rgba(0, 109, 255, 0.22);
  border-radius: 999px;
  background: var(--blue-soft);
  color: var(--accent-2);
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.inline-edit-button:hover {
  transform: translateY(-1px);
  background: var(--accent-2);
  color: #fff;
  box-shadow: 0 12px 28px rgba(0, 109, 255, 0.22);
}

.history-item + .history-item {
  margin-top: 10px;
}

.action-menu {
  position: relative;
}

.action-menu summary {
  list-style: none;
  cursor: pointer;
}

.action-menu summary::-webkit-details-marker {
  display: none;
}

.action-menu > div {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 20;
  display: grid;
  gap: 6px;
  min-width: 190px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.14);
}

.action-menu button {
  width: 100%;
  min-height: 38px;
  border: 0;
  border-radius: 10px;
  background: #fbfbfd;
  color: var(--text);
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.action-menu button:hover {
  background: var(--accent-soft);
  color: var(--accent);
}

.danger-text {
  color: var(--bad) !important;
}

.compact-table {
  min-width: 860px;
}

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

.feature-card {
  display: grid;
  gap: 8px;
  min-height: 118px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fbfbfd;
  color: inherit;
  text-decoration: none;
}

.feature-card strong {
  font-size: 17px;
}

.feature-card span {
  color: var(--muted);
  font-size: 14px;
}

.feature-card.disabled {
  opacity: 0.68;
}

.detail-stack {
  display: grid;
  gap: 12px;
}

.dashboard-panel {
  overflow: hidden;
  background: #fffdf8;
}

.workspace-focus-panel {
  margin-bottom: 18px;
}

.workspace-focus-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.workspace-focus-grid article {
  display: grid;
  gap: 8px;
  min-height: 128px;
  padding: 18px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 18px;
  background: #f8fafc;
}

.workspace-focus-grid span,
.workspace-focus-grid small {
  color: var(--muted);
  font-weight: 780;
}

.workspace-focus-grid strong {
  font-size: 20px;
  line-height: 1.35;
}

.workspace-status-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 18px;
}

.workspace-status-card {
  display: grid;
  width: 100%;
  gap: 8px;
  text-align: left;
  padding: 20px;
  border: 1px solid rgba(29, 29, 31, 0.1);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(29, 29, 31, 0.06);
  cursor: pointer;
}

.workspace-status-card span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 850;
}

.workspace-status-card strong {
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1;
}

.workspace-status-card p {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.65;
}

.workspace-status-card.proposal {
  border-color: rgba(10, 102, 194, 0.22);
  background: #eef6ff;
}

.workspace-status-card.executing {
  border-color: rgba(180, 112, 0, 0.2);
  background: #fff6df;
}

.workspace-status-card.tracking {
  border-color: rgba(0, 128, 82, 0.18);
  background: #edf9f2;
}

.workspace-status-card.active {
  outline: 3px solid rgba(0, 113, 227, 0.2);
  box-shadow: 0 16px 42px rgba(0, 113, 227, 0.12);
}

.case-board-panel {
  margin-bottom: 18px;
}

.case-board {
  display: grid;
  gap: 14px;
}

.case-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.48fr) auto;
  align-items: center;
  gap: 18px;
  padding: 18px;
  border: 1px solid rgba(29, 29, 31, 0.1);
  border-radius: 20px;
  background: #fff;
}

.case-card.proposing {
  border-left: 6px solid var(--accent);
}

.case-card.executing {
  border-left: 6px solid var(--warn);
}

.case-card.servicing {
  border-left: 6px solid var(--good);
}

.case-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.case-card-head small,
.case-card p,
.case-card dt {
  color: var(--muted);
  font-weight: 760;
}

.case-card h3 {
  margin: 0 0 8px;
  font-size: 24px;
}

.case-card p {
  margin: 0;
  line-height: 1.65;
}

.case-card dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.case-card dl div {
  display: grid;
  gap: 4px;
}

.case-card dt,
.case-card dd {
  margin: 0;
}

.case-card dd {
  font-weight: 850;
}

.case-card-actions {
  display: grid;
  gap: 10px;
  justify-items: stretch;
}

.case-compare-panel {
  margin: 0 0 18px;
  border-left: 6px solid var(--accent);
}

.good-tag {
  background: var(--green-soft);
  color: var(--good);
}

.workspace-support-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 18px;
}

.workspace-completion-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0;
}

.workspace-completion-columns div {
  display: grid;
  gap: 8px;
  padding: 14px;
  border-radius: 16px;
  background: #f8fafc;
}

.workspace-completion-columns strong {
  line-height: 1.45;
}

.workspace-note-list {
  display: grid;
  gap: 10px;
}

.workspace-note-item {
  display: grid;
  gap: 6px;
  padding: 14px;
  border: 1px solid rgba(29, 29, 31, 0.08);
  border-radius: 16px;
  background: #fff;
}

.workspace-note-item span,
.workspace-note-item small {
  color: var(--muted);
  font-weight: 720;
  line-height: 1.55;
}

.chart-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.45fr) minmax(0, 1fr);
  gap: 16px;
  margin-top: 18px;
}

.chart-card {
  display: grid;
  gap: 12px;
  min-height: 260px;
  padding: 18px;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 18px;
  background: #f5f8ff;
}

.pie-chart {
  display: grid;
  width: min(190px, 100%);
  aspect-ratio: 1;
  place-items: center;
  justify-self: center;
  border-radius: 50%;
  background: conic-gradient(var(--accent) 0 0%, #d2d2d7 0 100%);
}

.pie-chart span {
  display: grid;
  width: 58%;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  background: #fff;
  font-size: 28px;
  font-weight: 900;
}

.pie-chart small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.bar-chart {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  gap: 14px;
  min-height: 190px;
}

.bar-chart div {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 8px;
  min-height: 190px;
  text-align: center;
}

.bar-chart i {
  align-self: end;
  min-height: 8px;
  border-radius: 12px 12px 4px 4px;
  background: var(--accent);
}

.bar-chart i.good {
  background: var(--good);
}

.bar-chart i.bad {
  background: var(--bad);
}

.bar-chart span,
.bar-chart strong {
  overflow-wrap: anywhere;
  color: var(--muted);
  font-size: 12px;
}

.decision-comparison {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.decision-empty {
  display: grid;
  gap: 6px;
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 18px;
  background: #fff7df;
  color: var(--muted);
}

.decision-empty strong {
  color: var(--text);
  font-size: 17px;
}

.decision-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-top: 2px;
}

.decision-head h3 {
  margin: 0;
  font-size: 22px;
}

.decision-table-wrap {
  overflow-x: auto;
  border: 1px solid #e7c99d;
  border-radius: 22px;
  background: #fffdf8;
  box-shadow: var(--shadow);
}

.decision-table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
}

.decision-table th,
.decision-table td {
  border-bottom: 1px solid #efdfcd;
  border-left: 1px solid #efdfcd;
  padding: 15px 16px;
  text-align: center;
  vertical-align: middle;
}

.decision-table th:first-child,
.decision-table td:first-child {
  border-left: 0;
  text-align: left;
}

.decision-table tr:last-child td {
  border-bottom: 0;
}

.decision-table th {
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
  background: #fff3d7;
}

.decision-table td {
  color: var(--text);
  font-size: 18px;
  font-weight: 850;
}

.decision-table td:first-child {
  color: var(--muted);
  font-size: 14px;
  font-weight: 900;
}

.decision-table .recommended {
  background: #fff0cb;
}

.decision-table td.good-text {
  color: var(--good);
}

.decision-table td.bad-text {
  color: var(--bad);
}

.stage-pair {
  display: inline-grid;
  gap: 4px;
  line-height: 1.35;
}

.stage-pair span {
  white-space: nowrap;
}

.decision-summary {
  display: grid;
  gap: 8px;
  padding: 18px 20px;
  border: 1px solid #f0b56d;
  border-radius: 18px;
  background: #fff0cb;
}

.decision-summary strong {
  color: #8a3f00;
  font-size: 22px;
}

.decision-summary span {
  color: var(--text);
  font-size: 15px;
  line-height: 1.75;
}

.decision-summary small {
  color: var(--muted);
  font-weight: 700;
}

.investment-panel {
  overflow: hidden;
}

.investment-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  min-height: 190px;
  margin-bottom: 16px;
  padding: 26px;
  border-radius: 24px;
  background: #0b87ad;
  color: #fff;
  box-shadow: inset 0 -40px 80px rgba(0, 61, 96, 0.22);
}

.investment-hero .subtle {
  color: rgba(255, 255, 255, 0.78);
}

.investment-hero strong {
  display: block;
  margin: 8px 0;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1;
  letter-spacing: 0;
}

.investment-hero-side {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.investment-summary-grid {
  margin-bottom: 16px;
}

.investment-tabs {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 14px;
}

.investment-card {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 20px;
  background: #fffaf0;
}

.investment-list {
  display: grid;
  gap: 10px;
}

.investment-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border: 1px solid #e5d9ca;
  border-radius: 18px;
  background: #fff;
}

.investment-row.compact-row {
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.investment-row div:first-child {
  display: grid;
  gap: 3px;
}

.investment-row strong {
  font-size: 17px;
}

.investment-row span,
.investment-row small {
  color: var(--muted);
  font-weight: 750;
}

.investment-row small {
  font-size: 12px;
}

.investment-row-value {
  display: grid;
  justify-items: end;
  gap: 4px;
  min-width: 130px;
}

.investment-row-value span {
  display: inline-flex;
  width: fit-content;
  min-height: 28px;
  align-items: center;
  border-radius: 999px;
  padding: 4px 10px;
  background: #d8f5e5;
  font-weight: 900;
}

.summary-box.compact {
  min-height: auto;
}

.property-detail {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fbfbfd;
  padding: 12px 14px;
}

.property-detail summary {
  cursor: pointer;
  font-weight: 800;
}

.property-detail[open] summary {
  margin-bottom: 12px;
}

.empty.compact {
  padding: 18px;
  border: 1px dashed var(--line);
  border-radius: 16px;
}

.crm-overview-panel {
  overflow: hidden;
}

.crm-workbench {
  overflow: hidden;
}

.crm-dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.6fr);
  gap: 18px;
}

.crm-metrics .metric strong {
  font-size: 24px;
}

.crm-completion-card strong {
  font-size: 38px;
  color: var(--accent-2);
}

.completion-bar {
  overflow: hidden;
  height: 12px;
  border-radius: 999px;
  background: #f1e6d6;
}

.completion-bar span {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: #006dff;
  transition: width 0.24s ease;
}

.completion-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.completion-list span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 13px;
  font-weight: 850;
}

.completion-list .complete {
  background: var(--green-soft);
  color: var(--good);
}

.completion-list .missing {
  background: var(--warn-soft);
  color: var(--warn);
}

.crm-advisor-workspace {
  margin-top: 18px;
}

.workspace-card {
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 18px;
  border: 1px solid rgba(132, 92, 30, 0.14);
  border-radius: 18px;
  background: #fff9ed;
}

.workspace-card span,
.workspace-card small {
  color: var(--muted);
  font-weight: 750;
}

.workspace-card strong {
  font-size: 22px;
}

.workspace-card.warn {
  background: var(--warn-soft);
}

.crm-summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.summary-card {
  display: grid;
  gap: 10px;
  min-height: 268px;
  padding: 22px;
  border: 1px solid rgba(132, 92, 30, 0.16);
  border-radius: 22px;
  background: #fffdf8;
  box-shadow: var(--shadow);
}

.summary-card.primary-card {
  background: #eef5ff;
  border-color: #bcd4ff;
}

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

.summary-card h2 {
  font-size: 24px;
}

.summary-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.summary-card > strong {
  font-size: 32px;
  line-height: 1.1;
}

.summary-card p,
.summary-card small {
  color: var(--muted);
}

.summary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-self: end;
  margin-top: 6px;
}

.crm-list-panel {
  margin-top: 18px;
  overflow: hidden;
}

.crm-list-panel::before {
  display: none;
}

.crm-list-head {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(420px, 1.2fr);
  gap: 18px;
  align-items: end;
  padding: 22px;
  border-bottom: 1px solid rgba(132, 92, 30, 0.14);
  background: #fff9ed;
}

.crm-list-head h2 {
  margin-top: 8px;
}

.crm-list-content {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.crm-insight-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.crm-insight-strip > div {
  display: grid;
  gap: 4px;
  padding: 14px;
  border: 1px solid rgba(132, 92, 30, 0.13);
  border-radius: 16px;
  background: #fff9ed;
}

.crm-insight-strip span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.crm-insight-strip strong {
  font-size: 18px;
}

.crm-nav-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.crm-nav-tabs a {
  border: 1px solid rgba(132, 92, 30, 0.18);
  border-radius: 999px;
  background: #fff7df;
  color: var(--ink);
  font-weight: 800;
  padding: 8px 12px;
  text-decoration: none;
}

.crm-data-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 18px;
}

.crm-section-stack {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.crm-section {
  overflow: hidden;
  box-shadow: var(--shadow);
}

.crm-section::before {
  display: none;
}

.crm-section > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 92px;
  padding: 20px 22px;
  cursor: pointer;
  list-style: none;
}

.crm-section > summary::-webkit-details-marker {
  display: none;
}

.crm-section > summary span:first-child {
  display: grid;
  gap: 5px;
}

.crm-section > summary b {
  font-size: 24px;
}

.crm-section > summary small {
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.crm-section[open] > summary {
  border-bottom: 1px solid rgba(132, 92, 30, 0.14);
  background: #fff9ed;
}

.crm-section-body {
  display: grid;
  gap: 10px;
  padding: 18px;
}

.crm-data-card {
  display: grid;
  align-content: start;
  gap: 16px;
}

.compact-form {
  gap: 10px;
  padding: 14px;
  border: 1px solid rgba(132, 92, 30, 0.12);
  border-radius: 18px;
  background: #fff9ed;
}

.crm-item-list {
  display: grid;
  gap: 10px;
}

.crm-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(132, 92, 30, 0.14);
  border-radius: 18px;
  background: #fffdf8;
}

.crm-item > div:first-child,
.crm-item-value {
  display: grid;
  gap: 4px;
}

.crm-item span,
.crm-item small,
.crm-item-value span {
  color: var(--muted);
}

.crm-item small {
  font-size: 12px;
}

.crm-item-value {
  justify-items: end;
  min-width: 132px;
}

.crm-item-value strong {
  font-size: 18px;
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 36;
  background: rgba(29, 29, 31, 0.34);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.side-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 37;
  display: grid;
  grid-template-rows: auto 1fr;
  width: min(520px, 100vw);
  height: 100vh;
  background: #fffdf8;
  box-shadow: -30px 0 70px rgba(29, 29, 31, 0.18);
  transform: translateX(104%);
  transition: transform 0.22s ease;
}

.side-drawer.open {
  transform: translateX(0);
}

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

.side-drawer-head h2 {
  margin-top: 10px;
}

.side-drawer-body {
  align-content: start;
  overflow: auto;
  padding: 24px;
}

@media (max-width: 900px) {
  .grid.even-two,
  .grid.four,
  .step-progress,
  .check-grid,
  .feature-grid,
  .chart-grid,
  .investment-tabs,
  .crm-data-grid {
    grid-template-columns: 1fr;
  }

  .crm-dashboard-hero,
  .crm-summary-grid,
  .workspace-status-grid,
  .workspace-focus-grid,
  .workspace-support-grid,
  .crm-list-head {
    grid-template-columns: 1fr;
  }

  .case-card {
    grid-template-columns: 1fr;
  }

  .workspace-completion-columns {
    grid-template-columns: 1fr;
  }

  .crm-insight-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .investment-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .investment-row,
  .investment-row.compact-row {
    grid-template-columns: 1fr;
  }

  .investment-row-value {
    justify-items: start;
  }

  .customer-menu-panel {
    left: 0;
    right: auto;
  }

  .crm-item {
    grid-template-columns: 1fr;
  }

  .crm-item-value {
    justify-items: start;
  }

  .crm-section > summary {
    align-items: flex-start;
    flex-direction: column;
  }
}
