:root {
  --blue: #2f7df6;
  --blue-dark: #1557c0;
  --green: #13b981;
  --rose: #e54066;
  --amber: #f6a623;
  --ink: #172033;
  --muted: #687083;
  --line: #e7ebf2;
  --paper: #ffffff;
  --wash: #f4f7fb;
  --foundation-navigation-width: 244px;
  --client-ai-rail-width: clamp(330px, 27vw, 400px);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  height: 100vh;
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr);
  overflow: hidden;
  color: var(--ink);
  background: var(--wash);
  font-family: "Alibaba PuHuiTi", "MiSans", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  letter-spacing: 0;
}

button {
  border: 0;
  border-radius: 8px;
  font: inherit;
  letter-spacing: 0;
  cursor: pointer;
}

input,
select,
textarea {
  font-family: inherit;
  letter-spacing: 0;
}

.sidebar {
  position: sticky;
  top: 0;
  width: 244px;
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 20px 14px;
  overflow: hidden;
  background: #ffffff;
  border-right: 1px solid #d6e2f1;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 30px;
}

.foundation-panel-collapse {
  display: none;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  flex: 0 0 auto;
  color: #526078;
  border: 1px solid #cfd8e6;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 5px 14px rgba(18, 32, 51, 0.07);
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
}

html.foundation-bridge .foundation-panel-collapse {
  display: inline-flex;
}

html.foundation-bridge .foundation-panel-collapse:hover,
html.foundation-bridge .foundation-panel-collapse:focus-visible,
html.foundation-layout-pending .foundation-panel-collapse {
  color: var(--blue-dark);
  border-color: #9fb6d2;
  background: #edf6ff;
}

html.foundation-layout-pending .foundation-panel-collapse {
  cursor: wait;
  opacity: 0.72;
}

#foundationNavigationCollapse {
  margin-left: auto;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.brand strong,
.brand small {
  display: block;
}

.brand small,
.eyebrow,
.period-block span,
.tax-block span,
.plan-block span {
  color: var(--muted);
}

.nav {
  min-height: 0;
  flex: 1;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow-y: auto;
  padding: 0;
}

.nav-item {
  position: relative;
  width: 100%;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 12px 0 18px;
  text-align: left;
  color: #111827;
  background: transparent;
  border-radius: 10px;
  font-size: 14.5px;
  font-weight: 550;
  line-height: 1.45;
  white-space: nowrap;
  transition: color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.nav-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  color: #102033;
  background: currentColor;
  mask-position: center;
  mask-repeat: no-repeat;
  mask-size: 18px 18px;
  -webkit-mask-position: center;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-size: 18px 18px;
}

.nav-icon-dashboard {
  mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Crect x='4' y='4' width='6' height='6' rx='1'/%3E%3Crect x='14' y='4' width='6' height='6' rx='1'/%3E%3Crect x='4' y='14' width='6' height='6' rx='1'/%3E%3Crect x='14' y='14' width='6' height='6' rx='1'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Crect x='4' y='4' width='6' height='6' rx='1'/%3E%3Crect x='14' y='4' width='6' height='6' rx='1'/%3E%3Crect x='4' y='14' width='6' height='6' rx='1'/%3E%3Crect x='14' y='14' width='6' height='6' rx='1'/%3E%3C/svg%3E");
}

.nav-icon-company {
  mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 20h16'/%3E%3Cpath d='M6 20V6a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v14'/%3E%3Cpath d='M9 8h2M13 8h2M9 12h2M13 12h2M9 16h2M13 16h2'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 20h16'/%3E%3Cpath d='M6 20V6a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v14'/%3E%3Cpath d='M9 8h2M13 8h2M9 12h2M13 12h2M9 16h2M13 16h2'/%3E%3C/svg%3E");
}

.nav-icon-accounting {
  mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 19h16'/%3E%3Cpath d='M7 16V9M12 16V5M17 16v-4'/%3E%3Crect x='5' y='16' width='4' height='3' rx='1'/%3E%3Crect x='10' y='16' width='4' height='3' rx='1'/%3E%3Crect x='15' y='16' width='4' height='3' rx='1'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 19h16'/%3E%3Cpath d='M7 16V9M12 16V5M17 16v-4'/%3E%3Crect x='5' y='16' width='4' height='3' rx='1'/%3E%3Crect x='10' y='16' width='4' height='3' rx='1'/%3E%3Crect x='15' y='16' width='4' height='3' rx='1'/%3E%3C/svg%3E");
}

.nav-icon-tax {
  mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 3 5 6v5c0 5 3.5 8 7 10 3.5-2 7-5 7-10V6l-7-3Z'/%3E%3Cpath d='m9 12 2 2 4-5'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 3 5 6v5c0 5 3.5 8 7 10 3.5-2 7-5 7-10V6l-7-3Z'/%3E%3Cpath d='m9 12 2 2 4-5'/%3E%3C/svg%3E");
}

.nav-icon-report {
  mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Crect x='4' y='5' width='16' height='14' rx='2'/%3E%3Cpath d='M8 9h8M8 13h3M14 13h2M8 16h8'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Crect x='4' y='5' width='16' height='14' rx='2'/%3E%3Cpath d='M8 9h8M8 13h3M14 13h2M8 16h8'/%3E%3C/svg%3E");
}

.nav-icon-upload {
  mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 16V4'/%3E%3Cpath d='m7 9 5-5 5 5'/%3E%3Cpath d='M5 16v3a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-3'/%3E%3C/svg%3E");
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 16V4'/%3E%3Cpath d='m7 9 5-5 5 5'/%3E%3Cpath d='M5 16v3a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-3'/%3E%3C/svg%3E");
}

.nav-group {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.nav-report-group > .nav-item::after {
  content: "";
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  margin-left: auto;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  transform-origin: 50% 50%;
  transition: transform 0.18s ease;
}

.nav-report-group.is-open > .nav-item::after {
  transform: rotate(45deg);
}

.nav-report-group.is-collapsed .nav-subitems {
  display: none;
}

.nav-subitems {
  position: relative;
  display: grid;
  gap: 4px;
  margin-left: 32px;
  padding-left: 14px;
  padding-right: 0;
}

.nav-subitems::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: #d6e2f1;
}

.nav-subitem {
  position: relative;
  width: 100%;
  min-height: 34px;
  padding: 7px 8px 7px 14px;
  color: #5b6d84;
  background: transparent;
  text-align: left;
  font-size: 12.5px;
  font-weight: 550;
  line-height: 1.45;
}

.nav-subitem::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 50%;
  width: 3px;
  height: 3px;
  border-radius: 999px;
  background: #8aa1bb;
  transform: translateY(-50%);
}

.nav-subitem:hover,
.nav-subitem.active {
  color: #1769e8;
  background: #eef5ff;
}

.nav-subitem:hover::before,
.nav-subitem.active::before {
  background: #1769e8;
}

.nav-item.active,
.nav-item:hover {
  color: #1769e8;
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(22, 75, 134, 0.06);
}

.nav-item.active .nav-icon,
.nav-item:hover .nav-icon {
  color: #1769e8;
}

.nav-item.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 3px;
  border-radius: 999px;
  background: #1769e8;
}

.nav-badge,
.nav-item .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 18px;
  min-width: 18px;
  margin-left: auto;
  padding: 0 5px;
  color: #ffffff;
  background: #ef3434;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
}

.sidebar-more-button {
  width: 100%;
  height: 52px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding: 0 14px;
  color: #102033;
  background: #ffffff;
  border: 1px solid #d6e2f1;
  border-radius: 10px;
  box-shadow: none;
  text-align: left;
  font-size: 14px;
  font-weight: 600;
}

.sidebar-more-button:hover,
.sidebar-more-button:focus-visible {
  color: var(--blue-dark);
  border-color: #9fc1f5;
  background: #eef5ff;
}

.sidebar-more-button span {
  font-weight: 900;
  letter-spacing: 0;
}

.sidebar-more-button strong {
  font-size: 14px;
  font-weight: 600;
}

html.foundation-navigation-hidden body {
  grid-template-columns: minmax(0, 1fr) var(--client-ai-rail-width);
}

html.foundation-navigation-hidden .sidebar {
  display: none;
}

html.foundation-ai-hidden .client-ai-assistant {
  display: none !important;
}

html.foundation-ai-hidden body {
  grid-template-columns: var(--foundation-navigation-width) minmax(0, 1fr);
}

html.foundation-navigation-hidden.foundation-ai-hidden body {
  grid-template-columns: minmax(0, 1fr);
}

.sidebar-settings-modal {
  position: fixed;
  inset: 0;
  z-index: 160;
  display: grid;
  place-items: center;
  padding: 24px;
}

.sidebar-settings-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
  background: rgba(20, 31, 49, 0.48);
}

.sidebar-settings-dialog {
  position: relative;
  width: min(620px, calc(100vw - 32px));
  max-height: min(680px, calc(100vh - 48px));
  overflow: hidden;
  border: 1px solid #dce3ee;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(19, 31, 51, 0.24);
}

.sidebar-settings-dialog > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.sidebar-settings-dialog h2 {
  font-size: 18px;
}

.sidebar-settings-dialog > header button {
  width: 34px;
  height: 34px;
  color: var(--muted);
  background: transparent;
  font-size: 22px;
}

.sidebar-settings-table-wrap {
  max-height: calc(100vh - 160px);
  overflow: auto;
  padding: 0 20px 20px;
}

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

.sidebar-settings-table th,
.sidebar-settings-table td {
  padding: 14px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.sidebar-settings-table th {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.sidebar-settings-table th:first-child,
.sidebar-settings-table td:first-child {
  width: 72px;
  text-align: center;
}

.sidebar-settings-table th:last-child,
.sidebar-settings-table td:last-child {
  width: 150px;
}

.sidebar-visibility-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  color: var(--muted);
  background: transparent;
}

.sidebar-switch-track {
  position: relative;
  width: 38px;
  height: 22px;
  border-radius: 12px;
  background: #cbd5e1;
}

.sidebar-switch-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.22);
  transition: transform 160ms ease;
}

.sidebar-visibility-switch.active {
  color: #087f5b;
}

.sidebar-visibility-switch.active .sidebar-switch-track {
  background: var(--green);
}

.sidebar-visibility-switch.active .sidebar-switch-track::after {
  transform: translateX(16px);
}

.shell {
  min-width: 0;
  height: 100vh;
  padding: 28px;
  overflow-y: auto;
}

.topbar,
.section-title,
.actions,
.upload-zone,
.upload-actions {
  display: flex;
  align-items: center;
}

.topbar,
.section-title,
.upload-zone {
  justify-content: space-between;
  gap: 20px;
}

.topbar {
  margin-bottom: 22px;
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 13px;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: 28px;
}

h2 {
  margin-bottom: 0;
  font-size: 20px;
}

.actions,
.upload-actions {
  gap: 10px;
}

.primary,
.ghost,
.upload-actions button,
.compact {
  padding: 10px 14px;
}

.primary {
  color: #fff;
  background: var(--blue);
}

.ghost,
.upload-actions button {
  color: var(--blue-dark);
  background: #eef5ff;
}

.status-band {
  display: grid;
  grid-template-columns: 1fr 1fr 1.4fr;
  gap: 14px;
  margin-bottom: 24px;
}

.period-block,
.tax-block,
.plan-block {
  min-height: 132px;
  padding: 22px;
  display: grid;
  gap: 12px;
  align-content: space-between;
  border-radius: 8px;
  color: #fff;
}

.period-block {
  background: linear-gradient(135deg, #2478f2, #1db8b3);
}

.tax-block {
  background: linear-gradient(135deg, #12a77c, #37c878);
}

.plan-block {
  background: #26324a;
}

.tax-block[data-workbench-action],
.plan-block[data-workbench-action] {
  cursor: pointer;
}

.tax-block[data-workbench-action]:hover,
.plan-block[data-workbench-action]:hover,
.tax-block[data-workbench-action]:focus-visible,
.plan-block[data-workbench-action]:focus-visible {
  outline: 3px solid rgba(255, 255, 255, 0.72);
  outline-offset: -6px;
}

.period-block-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.period-block-head > span {
  white-space: nowrap;
}

.period-quick-picker {
  display: grid;
  gap: 5px;
  min-width: 136px;
}

.period-quick-picker span {
  text-align: right;
  font-size: 12px;
  font-weight: 800;
}

.period-quick-picker select {
  min-width: 0;
  height: 32px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 8px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  font: inherit;
  font-size: 13px;
  font-weight: 800;
}

.period-quick-picker select:hover,
.period-quick-picker select:focus-visible {
  background: rgba(255, 255, 255, 0.25);
}

.period-block span,
.tax-block span,
.plan-block span,
.period-block small,
.tax-block small,
.plan-block small {
  color: rgba(255, 255, 255, 0.82);
}

.period-block strong,
.tax-block strong,
.plan-block strong {
  font-size: 26px;
}

.metric-section,
.client-home-zone,
.company-profile-zone,
.client-access-zone,
.period-command-zone,
.client-ai-assurance-zone,
.portal-map-zone,
.accounting-flow-zone,
.manual-entry-zone,
.tax-center-zone,
.report-center-zone,
.renewal-zone,
.share-zone,
.buyer-clarity-zone,
.purchase-confidence-zone,
.chanjet-live-zone,
.deal-proof-zone,
.panel,
.upload-zone,
.smart-zone,
.queue-zone,
.service-order-zone,
.ai-audit-zone,
.followup-zone,
.declaration-zone,
.assistant-zone {
  margin-bottom: 22px;
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.company-profile-zone {
  border-color: #d8e1ff;
}

.company-profile-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.client-ai-assurance-zone {
  border-color: #cfe9e7;
  background: #fbfffd;
}

.client-access-zone,
.period-command-zone {
  border-color: #cfe0ff;
  background: #fbfdff;
}

.client-home-zone {
  border-color: #cfe0ff;
  background: #fbfdff;
}

.client-home-zone > .section-title > strong {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 8px;
  color: var(--blue-dark);
  background: #eef5ff;
  font-size: 13px;
  white-space: nowrap;
}

.client-access-grid,
.client-home-grid,
.period-command-grid,
.accounting-flow-grid,
.manual-entry-grid,
.tax-center-grid,
.report-center-grid,
.renewal-grid,
.share-grid {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.client-access-grid {
  grid-template-columns: 1.3fr 1fr 1fr;
}

.period-command-grid,
.client-home-grid,
.tax-center-grid,
.report-center-grid,
.renewal-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

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

.accounting-flow-grid,
.manual-entry-grid,
.share-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.client-access-card,
.client-home-card,
.period-command-card,
.accounting-flow-card,
.manual-entry-card,
.tax-center-card,
.report-center-card,
.renewal-card,
.share-card,
.report-preview article,
.manual-entry-item,
.manual-entry-empty {
  min-width: 0;
  padding: 16px;
  border: 1px solid #dce6f5;
  border-radius: 8px;
  background: #fff;
}

.client-access-card,
.client-home-card,
.period-command-card,
.accounting-flow-card,
.manual-entry-card,
.tax-center-card,
.report-center-card,
.renewal-card,
.share-card {
  display: grid;
  align-content: start;
  gap: 10px;
}

.client-access-card span,
.client-home-card span,
.period-command-card span,
.accounting-flow-card span,
.manual-entry-card span,
.tax-center-card span,
.report-center-card span,
.renewal-card span,
.share-card span,
.report-preview span,
.manual-entry-item span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.client-access-card strong,
.client-home-card strong,
.period-command-card strong,
.accounting-flow-card strong,
.manual-entry-card strong,
.tax-center-card strong,
.report-center-card strong,
.renewal-card strong,
.share-card strong {
  font-size: 19px;
  line-height: 1.28;
}

.client-access-card p,
.client-home-card p,
.period-command-card p,
.accounting-flow-card p,
.manual-entry-card p,
.tax-center-card p,
.report-center-card p,
.renewal-card p,
.share-card p,
.manual-entry-item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.client-tax-center-grid {
  display: block;
  margin-top: 18px;
}

.client-tax-center-shell {
  display: grid;
  gap: 16px;
}

.client-tax-center-card,
.client-tax-progress-card {
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 12px 30px rgba(35, 47, 70, 0.08);
}

.client-tax-center-head,
.client-tax-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.client-tax-center-head strong,
.client-tax-progress-head strong {
  color: #0b1020;
  font-size: 24px;
  font-weight: 900;
  line-height: 1.2;
}

.client-tax-center-head button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  color: var(--blue-dark);
  background: transparent;
  font-weight: 900;
}

.client-tax-center-head button span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-tax-center-head b,
.client-tax-center-action b {
  color: var(--muted);
  font-size: 28px;
  font-weight: 500;
  line-height: 1;
}

.client-tax-center-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 20px 0 16px;
  padding: 12px 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.tax-center-summary-item {
  min-width: 0;
  display: grid;
  gap: 7px;
  align-content: center;
  padding: 0 14px;
  text-align: left;
}

.tax-center-summary-item + .tax-center-summary-item {
  border-left: 1px solid var(--line);
}

.tax-center-summary-item small,
.tax-center-summary-item b {
  display: block;
  color: #0b1020;
  font-size: 15px;
  font-weight: 900;
  line-height: 1.28;
  overflow-wrap: anywhere;
}

.client-tax-center-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.client-tax-center-action {
  min-width: 0;
  min-height: 100px;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 15px 12px;
  color: #0b1020;
  background: #fff;
  text-align: left;
  box-shadow: 0 10px 24px rgba(35, 47, 70, 0.06);
}

.client-tax-center-action img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.client-tax-center-action span {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.client-tax-center-action strong {
  overflow: hidden;
  color: #0b1020;
  font-size: 19px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-tax-center-action small {
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-tax-progress-head span {
  display: none;
}

.client-tax-progress-timeline {
  display: grid;
  gap: 0;
  margin-top: 20px;
}

.client-tax-progress-item {
  position: relative;
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  column-gap: 12px;
}

.client-tax-progress-item:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 23px;
  top: 36px;
  bottom: -9px;
  width: 2px;
  background: var(--blue);
  transform: translateX(-50%);
}

.client-tax-progress-item.last-step::before {
  display: none;
}

.client-tax-progress-dot {
  position: relative;
  z-index: 1;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  justify-self: center;
  margin-top: 6px;
  border-radius: 50%;
  color: #fff;
  background: var(--blue);
  font-size: 16px;
  font-weight: 900;
}

.client-tax-progress-body {
  width: 100%;
  min-height: 76px;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  padding: 8px 0 20px;
  color: inherit;
  background: transparent;
  text-align: left;
}

.client-tax-progress-body i {
  color: var(--blue);
  font-size: 20px;
  font-style: normal;
  font-weight: 900;
  line-height: 1.4;
}

.client-tax-progress-body > span {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.client-tax-progress-body strong {
  color: #0b1020;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
}

.client-tax-progress-body small {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.client-tax-progress-body em {
  padding: 8px 12px;
  border-radius: 8px;
  color: #059669;
  background: #f0fdf4;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.client-tax-progress-item.pending .client-tax-progress-body em {
  color: #0b1020;
  background: #f6f7f9;
}

.client-tax-progress-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
}

.client-tax-progress-chips span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #344054;
  font-size: 13px;
  font-weight: 800;
}

.client-tax-progress-chips i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--green);
}

.client-tax-due-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 4px 0 0 58px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.client-tax-due-grid article {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.client-tax-due-grid strong,
.client-tax-due-grid small {
  display: block;
}

.client-tax-due-grid strong {
  color: #0b1020;
  font-size: 16px;
  font-weight: 900;
}

.client-tax-due-grid small {
  margin-top: 8px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.client-tax-due-grid em {
  display: block;
  margin-top: 5px;
  color: var(--blue-dark);
  font-style: normal;
}

.client-login-form,
.manual-entry-form {
  display: grid;
  gap: 9px;
}

.client-login-form {
  grid-template-columns: minmax(0, 1fr) auto;
}

.client-login-form input,
.manual-entry-form input,
.period-picker select {
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #d7dfeb;
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

.client-login-form button,
.client-access-actions button,
.manual-entry-form button,
.accounting-flow-card button,
.report-preview button {
  min-height: 40px;
  padding: 9px 12px;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.client-access-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.client-access-actions button + button {
  color: var(--blue-dark);
  background: #eef5ff;
}

.client-access-checks {
  display: grid;
  gap: 7px;
}

.client-access-checks span {
  display: grid;
  gap: 3px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f4f7fb;
  color: var(--muted);
  line-height: 1.35;
}

.client-access-checks strong {
  color: var(--ink);
  font-size: 13px;
}

.period-picker {
  display: grid;
  gap: 6px;
  min-width: 220px;
}

.period-picker label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.period-command-card,
.client-home-card,
.report-center-card,
.renewal-card,
.portal-map-card,
.accounting-flow-card {
  cursor: pointer;
}

.period-command-card:hover,
.client-home-card:hover,
.report-center-card:hover,
.renewal-card:hover,
.accounting-flow-card:hover {
  border-color: rgba(47, 125, 246, 0.55);
  box-shadow: 0 12px 28px rgba(36, 76, 132, 0.08);
}

.client-home-card {
  min-height: 176px;
  position: relative;
}

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

.client-home-card small {
  color: var(--blue-dark);
  font-weight: 800;
  line-height: 1.45;
}

.client-home-card button {
  justify-self: start;
  min-height: 36px;
  margin-top: auto;
  padding: 8px 12px;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.client-home-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.client-home-actions button {
  min-height: 38px;
  padding: 9px 12px;
  color: var(--blue-dark);
  background: #eef5ff;
  font-weight: 800;
}

.client-home-actions button:first-child {
  color: #fff;
  background: var(--blue);
}

.accounting-flow-card > span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--blue);
  font-size: 15px;
}

.accounting-flow-card small,
.renewal-card small,
.report-center-card p,
.share-card p {
  color: var(--muted);
  line-height: 1.45;
}

.accounting-flow-card.invoice-card {
  gap: 12px;
}

.accounting-manual-box {
  display: grid;
  gap: 9px;
  margin-top: 2px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.accounting-flow-card .accounting-manual-row {
  min-width: 0;
  min-height: 76px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 5px 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid #d8e6ff;
  border-radius: 8px;
  color: var(--ink);
  background: #f7fbff;
  text-align: left;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.accounting-flow-card .accounting-manual-row:hover,
.accounting-flow-card .accounting-manual-row:focus-visible {
  border-color: rgba(47, 125, 246, 0.72);
  background: #eef5ff;
  outline: 0;
  transform: translateY(-1px);
}

.accounting-flow-card .accounting-manual-row:active {
  transform: translateY(0);
}

.accounting-flow-card .accounting-manual-row span {
  color: var(--blue-dark);
  font-size: 13px;
}

.accounting-flow-card .accounting-manual-row strong {
  color: #101827;
  font-size: 16px;
  line-height: 1.28;
}

.accounting-flow-card .accounting-manual-row small {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 13px;
}

.accounting-flow-card .accounting-manual-row b {
  grid-row: 1 / span 2;
  grid-column: 2;
  color: var(--blue-dark);
  font-size: 13px;
  white-space: nowrap;
}

.manual-entry-card.is-active {
  border-color: rgba(47, 125, 246, 0.86);
  background: #f7fbff;
  box-shadow: 0 12px 28px rgba(36, 76, 132, 0.08);
}

.manual-entry-result,
.report-preview,
.manual-entry-list,
.renewal-services {
  margin-top: 14px;
}

.manual-entry-result {
  min-height: 44px;
  padding: 12px 14px;
  border: 1px solid #d8e8ff;
  border-radius: 8px;
  color: #174077;
  background: #f4f8ff;
  line-height: 1.45;
}

.manual-entry-result:empty {
  display: none;
}

.manual-entry-result.error {
  color: #9f1239;
  border-color: #fecdd3;
  background: #fff1f2;
}

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

.manual-entry-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tax-center-zone {
  border-color: #bdeedb;
  background: #fbfffd;
}

.report-center-zone {
  border-color: #d8e1ff;
}

.report-center-zone .report-center-grid {
  grid-template-columns: 1fr;
}

.report-center-zone .section-title {
  margin-bottom: 2px;
}

.report-center-zone .eyebrow {
  margin-bottom: 0;
  font-size: 15px;
  font-weight: 800;
}

.report-center-card.selected,
.renewal-card.selected {
  border-color: var(--blue);
  background: #f2f7ff;
}

.report-center-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.report-center-main,
.report-center-toolbar,
.report-center-group {
  min-width: 0;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fff;
}

.report-center-toolbar span,
.report-center-group-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.report-center-main {
  display: grid;
  gap: 14px;
  padding: 16px;
  background: #fbfdff;
}

.report-center-toolbar {
  display: grid;
  grid-template-columns: 1.4fr 190px 1fr 1fr;
  gap: 12px;
  padding: 14px;
  background: #f7faff;
}

.report-center-toolbar > div,
.report-center-toolbar label {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 6px;
}

.report-center-toolbar strong {
  min-width: 0;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.report-center-toolbar select {
  min-width: 0;
  height: 38px;
  padding: 0 10px;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
  font-weight: 800;
}

.report-center-groups {
  display: grid;
  gap: 12px;
}

.report-preview-slot {
  min-width: 0;
}

.report-center-group {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.report-center-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.report-center-group-head strong {
  color: var(--ink);
  font-size: 18px;
}

.report-center-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.report-center-card {
  min-height: 88px;
  display: grid;
  place-items: center start;
  padding: 18px;
  text-align: left;
  background: #fbfdff;
  position: relative;
}

.report-center-card::after {
  content: "";
  position: absolute;
  right: 18px;
  width: 9px;
  height: 9px;
  border-right: 2px solid #8aa3c7;
  border-bottom: 2px solid #8aa3c7;
  transform: rotate(-45deg);
}

.report-center-card strong {
  padding-right: 28px;
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: 0;
}

.report-center-card.selected strong {
  color: var(--blue-dark);
}

.report-center-card.selected::after {
  border-color: var(--blue-dark);
}

.report-preview {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.report-preview:empty {
  display: none;
}

.report-inline-card {
  min-width: 0;
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid #cfe0ff;
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 14px 36px rgba(21, 35, 66, 0.12);
}

.report-inline-loading {
  min-height: 160px;
  align-content: start;
}

.report-inline-card .report-modal-head {
  padding-bottom: 12px;
  border-bottom: 1px solid #edf1f7;
}

.report-inline-card .report-modal-body {
  min-height: 0;
}

.report-inline-card .report-modal-table-wrap {
  max-height: 520px;
}

.report-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 24px;
}

.report-modal-backdrop {
  position: absolute;
  inset: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: rgba(15, 23, 42, 0.36);
}

.report-modal-dialog {
  position: relative;
  width: min(1180px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  gap: 14px;
  padding: 18px;
  border: 1px solid #cfe0ff;
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 24px 70px rgba(21, 35, 66, 0.24);
  overflow: hidden;
}

.report-modal-loading {
  grid-template-rows: auto auto;
}

.report-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.report-modal-head > div:first-child {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.report-modal-head span {
  color: var(--blue-dark);
  font-size: 13px;
  font-weight: 800;
}

.report-modal-head strong {
  color: var(--ink);
  font-size: 20px;
}

.report-modal-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.report-modal-head button,
.report-modal-actions button,
.report-side-panel button {
  padding: 9px 12px;
  color: var(--blue-dark);
  background: #eef5ff;
}

.report-modal-actions button:first-child {
  color: #fff;
  background: var(--blue);
}

.report-modal-body {
  min-height: 0;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 14px;
}

.report-settings,
.report-side-panel {
  min-height: 0;
  min-width: 0;
}

.report-settings {
  display: grid;
  align-content: start;
  gap: 10px;
}

.report-panel-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  padding: 4px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #f6f9ff;
}

.report-panel-tabs button {
  padding: 8px 10px;
  color: var(--muted);
  background: transparent;
}

.report-panel-tabs button.selected {
  color: #fff;
  background: var(--blue);
}

.report-side-panel {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fbfdff;
}

.report-side-panel strong {
  color: var(--ink);
  font-size: 16px;
}

.report-side-panel label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.report-side-panel label:has(input[type="checkbox"]) {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
}

.report-side-panel input {
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

.report-side-panel input[type="checkbox"] {
  width: 16px;
  height: 16px;
  padding: 0;
}

.report-side-panel small {
  color: var(--muted);
  line-height: 1.5;
}

.report-modal-table-wrap {
  min-width: 0;
  max-height: min(48vh, 440px);
  overflow: auto;
  border: 1px solid #dce6f5;
  border-radius: 8px;
  background: #fff;
}

.account-balance-scroll {
  max-height: min(50vh, 460px);
}

.account-balance-scroll .report-preview-row {
  min-width: 1120px;
}

.report-document {
  display: grid;
  gap: 14px;
  min-height: 0;
}

.report-document-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.report-document-bar span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid #d8e1ff;
  border-radius: 999px;
  color: var(--blue-dark);
  background: #f2f7ff;
  font-size: 13px;
  font-weight: 800;
}

.report-document-head {
  display: grid;
  gap: 8px;
  text-align: center;
}

.report-document-head strong {
  font-size: 24px;
  letter-spacing: 0;
}

.report-document-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  text-align: left;
}

.report-document-meta span {
  min-width: 0;
}

.report-preview p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.report-preview-table {
  display: grid;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: #fff;
}

.account-balance-scroll .report-preview-table {
  min-width: 1120px;
}

.report-preview-row {
  min-width: 680px;
  display: grid;
  grid-template-columns: var(--report-columns, repeat(4, minmax(150px, 1fr)));
  border-bottom: 1px solid #edf1f7;
}

.report-preview-row:last-child {
  border-bottom: 0;
}

.report-preview-table span {
  padding: 10px 12px;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.report-voucher-link {
  width: 100%;
  min-height: 32px;
  padding: 0;
  color: var(--blue-dark);
  background: transparent;
  text-align: left;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

.report-voucher-link:hover,
.report-voucher-link:focus-visible {
  color: #0f45a5;
  background: #eef5ff;
  outline: none;
}

.report-preview-header span {
  color: #34415c;
  background: #f7faff;
  font-size: 13px;
  font-weight: 800;
}

.report-number-cell {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.report-text-cell {
  text-align: left;
}

.report-preview-empty-row span {
  grid-column: 1 / -1;
  color: var(--muted);
  text-align: center;
}

.report-voucher-modal {
  position: fixed;
  inset: 0;
  z-index: 1400;
  display: none;
  place-items: center;
  padding: 28px;
}

.report-voucher-modal.open {
  display: grid;
}

.report-voucher-backdrop {
  position: absolute;
  inset: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: rgba(15, 23, 42, 0.38);
}

.report-voucher-dialog {
  position: relative;
  width: min(920px, calc(100vw - 56px));
  max-height: calc(100vh - 56px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 16px;
  padding: 20px;
  border: 1px solid #cfe0ff;
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 24px 70px rgba(21, 35, 66, 0.25);
  overflow: hidden;
}

.report-voucher-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #edf1f7;
}

.report-voucher-head h3 {
  margin: 4px 0 0;
  font-size: 24px;
  letter-spacing: 0;
}

.report-voucher-detail {
  min-width: 0;
  min-height: 0;
  display: grid;
  gap: 14px;
  overflow: auto;
}

.report-voucher-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.report-voucher-summary article {
  min-width: 0;
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid #d8e6ff;
  border-radius: 8px;
  background: #f8fbff;
}

.report-voucher-summary span,
.report-voucher-note span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.report-voucher-summary strong {
  min-width: 0;
  color: var(--ink);
  font-size: 17px;
  overflow-wrap: anywhere;
}

.report-voucher-note {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid #edf1f7;
  border-radius: 8px;
  background: #fff;
}

.report-voucher-note strong {
  color: var(--ink);
  line-height: 1.45;
}

.report-voucher-detail-table-wrap {
  min-width: 0;
  overflow: auto;
  border: 1px solid #dce6f5;
  border-radius: 8px;
  background: #fff;
}

.report-voucher-detail-table {
  min-width: 760px;
  display: grid;
}

.report-voucher-detail-row {
  display: grid;
  grid-template-columns: 64px minmax(180px, 1.2fr) minmax(220px, 1.6fr) minmax(120px, 0.8fr) minmax(120px, 0.8fr);
  border-bottom: 1px solid #edf1f7;
}

.report-voucher-detail-row:last-child {
  border-bottom: 0;
}

.report-voucher-detail-row span {
  min-width: 0;
  padding: 10px 12px;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.report-voucher-detail-head span {
  color: #34415c;
  background: #f7faff;
  font-size: 13px;
  font-weight: 800;
}

.renewal-zone {
  border-color: #f2dcad;
  background: #fffdf8;
}

.renewal-card strong {
  display: grid;
  gap: 8px;
}

.renewal-card b {
  color: var(--rose);
  font-size: 26px;
}

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

.renewal-services article,
.share-card {
  padding: 16px;
  border: 1px solid #e8edf5;
  border-radius: 8px;
  background: #fff;
}

.renewal-services strong {
  display: block;
  margin-top: 8px;
  color: var(--ink);
}

.renewal-services p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.renewal-services div,
.share-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.renewal-services b,
.share-steps b {
  padding: 7px 9px;
  border-radius: 999px;
  color: #174077;
  background: #eef5ff;
  font-size: 12px;
}

.renewal-checkout {
  grid-column: 1 / -1;
  display: grid;
  gap: 14px;
}

.renewal-checkout-head,
.renewal-payment-layout,
.renewal-payment-panel,
.renewal-qr-card,
.renewal-transfer-card,
.renewal-payment-summary {
  min-width: 0;
  border: 1px solid #e8edf5;
  border-radius: 8px;
  background: #fff;
}

.renewal-checkout-head {
  display: grid;
  grid-template-columns: auto 1fr 1fr;
  align-items: center;
  gap: 12px;
  padding: 14px;
}

.renewal-checkout-head > div {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.renewal-checkout-head span,
.renewal-payment-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.renewal-checkout-head strong {
  color: var(--ink);
  overflow-wrap: anywhere;
}

.renewal-checkout-head button,
.renewal-payment-actions button:first-child {
  min-height: 38px;
  padding: 9px 12px;
  color: var(--blue-dark);
  background: #eef5ff;
  font-weight: 800;
}

.renewal-payment-layout {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
  background: #fffdfa;
}

.renewal-payment-methods {
  display: grid;
  align-content: start;
  gap: 10px;
}

.renewal-payment-methods button {
  min-height: 70px;
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid #e8edf5;
  color: var(--ink);
  background: #fff;
  text-align: left;
}

.renewal-payment-methods button.selected {
  border-color: var(--blue);
  background: #f2f7ff;
}

.renewal-payment-methods strong {
  font-size: 16px;
}

.renewal-payment-methods span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.renewal-payment-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.renewal-qr-card {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  padding: 16px;
}

.renewal-qr-code {
  width: 180px;
  height: 180px;
  display: block;
  padding: 10px;
  border: 1px solid #dbe6f7;
  border-radius: 8px;
  background: #fff;
}

.renewal-pay-qr-svg {
  width: 100%;
  height: 100%;
  display: block;
}

.renewal-qr-card strong,
.renewal-transfer-card strong {
  color: var(--ink);
  font-size: 22px;
}

.renewal-qr-card p,
.renewal-transfer-card p,
.renewal-payment-summary p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.renewal-qr-card small {
  display: block;
  margin-top: 8px;
  color: var(--blue-dark);
  font-weight: 800;
}

.renewal-transfer-card {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.renewal-payment-notice.error {
  border-color: #ffd3d3;
  background: #fff8f8;
}

.renewal-payment-notice > button {
  justify-self: start;
  min-height: 38px;
  padding: 9px 12px;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.renewal-transfer-card dl {
  display: grid;
  gap: 8px;
  margin: 0;
}

.renewal-transfer-card dl div {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #f7faff;
}

.renewal-transfer-card dt {
  color: var(--muted);
  font-weight: 800;
}

.renewal-transfer-card dd {
  margin: 0;
  color: var(--ink);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.renewal-payment-summary {
  padding: 14px;
  background: #f7faff;
}

.renewal-payment-summary strong {
  display: block;
  margin-top: 4px;
  color: var(--rose);
  font-size: 30px;
}

.renewal-payment-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.renewal-payment-actions button:last-child {
  min-height: 42px;
  padding: 10px 14px;
  color: #fff;
  background: var(--blue);
  font-weight: 800;
}

.share-zone {
  border-color: #dbe6f7;
  background: #fcfdff;
}

.client-ai-assurance-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: start;
}

.client-ai-assurance-head h2 {
  line-height: 1.35;
}

.client-ai-assurance-head strong {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  color: #087d79;
  background: #e8fff7;
  font-size: 13px;
  white-space: nowrap;
}

.client-ai-assurance-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.client-ai-assurance-card {
  min-height: 132px;
  padding: 15px;
  border: 1px solid #d5ece5;
  border-radius: 8px;
  background: #fff;
}

.client-ai-assurance-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.client-ai-assurance-card strong {
  display: block;
  margin: 9px 0;
  color: var(--ink);
  font-size: 19px;
  line-height: 1.3;
}

.client-ai-assurance-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.client-ai-assurance-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.client-ai-assurance-actions button {
  padding: 9px 12px;
  color: var(--blue-dark);
  background: #eef5ff;
}

.client-ai-assurance-actions button:first-child {
  color: #fff;
  background: var(--blue);
}

.portal-map-zone {
  border-color: #d8e1ff;
}

.portal-map-zone > .section-title > strong {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  color: #087d79;
  background: #e8fff7;
  font-size: 13px;
}

.portal-map-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.portal-map-card {
  min-height: 192px;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  color: inherit;
  text-decoration: none;
  background: #f8fbff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.portal-map-card:hover {
  border-color: rgba(47, 125, 246, 0.52);
  box-shadow: 0 14px 34px rgba(47, 125, 246, 0.12);
  transform: translateY(-1px);
}

.portal-map-card span,
.portal-map-card p,
.portal-map-card small {
  color: var(--muted);
  line-height: 1.5;
}

.portal-map-card span {
  font-size: 13px;
  font-weight: 800;
}

.portal-map-card strong {
  color: var(--ink);
  font-size: 20px;
  line-height: 1.25;
}

.portal-map-card p {
  margin: 0;
  font-size: 14px;
}

.portal-map-card small {
  margin-top: auto;
  font-size: 12px;
  font-weight: 900;
}

.portal-map-card.client {
  border-color: #cfe0ff;
  background: #f7fbff;
}

.portal-map-card.mini {
  border-color: #c7f0df;
  background: #f7fffb;
}

.portal-map-card.accountant {
  border-color: #d9d6ff;
  background: #fbfaff;
}

.portal-map-card.admin {
  border-color: #d8e1ff;
  background: #f8fbff;
}

.portal-map-card.agent {
  border-color: #f5dfb8;
  background: #fffaf0;
}

.data-parity-zone {
  border-color: #cfe0ff;
  background: #fbfdff;
}

.data-parity-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.data-parity-actions button {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
}

.data-parity-actions .selected,
.data-parity-overview .selected,
.data-parity-grid .selected {
  color: #fff !important;
  background: var(--blue);
}

.data-parity-actions .selected {
  border-color: var(--blue);
}

.data-parity-overview,
.data-parity-grid {
  display: grid;
  gap: 12px;
  margin-top: 16px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.data-parity-card {
  min-width: 0;
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fff;
}

.data-parity-card span,
.data-parity-empty span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.data-parity-card strong {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--ink);
  font-size: 22px;
  line-height: 1.2;
}

.data-parity-card.aligned strong {
  color: #087d79;
}

.data-parity-card.different strong {
  color: #b4234a;
}

.data-parity-card.pending strong {
  color: #b95f05;
}

.data-parity-card p,
.data-parity-empty p,
.data-parity-empty small,
.data-parity-diff-item p,
.data-parity-diff-item small {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.data-parity-empty {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px dashed #d8e1ff;
  border-radius: 8px;
  background: #f7faff;
}

.data-parity-diff-list {
  margin-top: 16px;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.data-parity-diff-item {
  min-width: 0;
  padding: 14px;
  border: 1px solid #e0e8f7;
  border-left: 4px solid #cfe0ff;
  border-radius: 8px;
  background: #fff;
  display: grid;
  gap: 8px;
}

.data-parity-diff-item.aligned {
  border-left-color: #16a34a;
}

.data-parity-diff-item.different {
  border-left-color: #b4234a;
}

.data-parity-diff-item.pending {
  border-left-color: #f59e0b;
}

.data-parity-diff-item > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
}

.data-parity-diff-item > div strong {
  font-size: 17px;
  line-height: 1.3;
}

.data-parity-diff-item > div span {
  color: #687083;
}

.data-parity-diff-item small {
  color: #687083;
}

.buyer-clarity-zone {
  margin-bottom: 22px;
  padding: 22px;
  background: #fff;
  border: 1px solid #dbe6f7;
  border-radius: 8px;
}

.buyer-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
}

.buyer-hero h2 {
  max-width: 760px;
  font-size: 24px;
}

.buyer-hero p {
  max-width: 820px;
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

.buyer-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.buyer-trust-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.buyer-trust-grid article {
  min-height: 136px;
  padding: 16px;
  border: 1px solid #e0e7f3;
  border-radius: 8px;
  background: #f9fbff;
}

.buyer-trust-grid span {
  color: var(--muted);
  font-size: 13px;
}

.buyer-trust-grid strong {
  display: block;
  margin: 9px 0;
  font-size: 19px;
}

.buyer-trust-grid p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.purchase-confidence-zone {
  margin-bottom: 22px;
  padding: 22px;
  border: 1px solid #d9eadf;
  border-radius: 8px;
  background: #fbfffd;
}

.purchase-confidence-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.purchase-confidence-grid article {
  min-height: 136px;
  padding: 16px;
  border: 1px solid #d7eadf;
  border-radius: 8px;
  background: #fff;
}

.purchase-confidence-grid span {
  color: var(--muted);
  font-size: 13px;
}

.purchase-confidence-grid strong {
  display: block;
  margin: 9px 0;
  font-size: 19px;
}

.purchase-confidence-grid p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.company-profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  margin-top: 34px;
}

.company-profile-card {
  min-height: 304px;
  padding: 32px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fbfdff;
  cursor: pointer;
}

.company-profile-card:hover {
  border-color: rgba(47, 125, 246, 0.48);
  box-shadow: 0 12px 30px rgba(47, 125, 246, 0.09);
}

.company-profile-card span,
.company-profile-card p {
  color: var(--muted);
}

.company-profile-card strong {
  display: block;
  margin: 20px 0;
  color: var(--ink);
  font-size: 31px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.company-profile-card p {
  max-width: 640px;
  min-height: 90px;
  margin-bottom: 28px;
  font-size: 20px;
  font-weight: 800;
  line-height: 1.55;
}

.company-profile-card button {
  min-height: 58px;
  padding: 14px 24px;
  color: #ffffff;
  background: var(--blue);
  font-size: 21px;
  font-weight: 800;
}

.company-profile-card-create {
  border-color: #bcd8ff;
  background: linear-gradient(180deg, #f6fbff 0%, #ffffff 100%);
}

.company-profile-card-manage {
  border-color: #cfe9e7;
  background: linear-gradient(180deg, #f5fffc 0%, #ffffff 100%);
}

.segmented {
  display: flex;
  padding: 4px;
  background: #f0f3f8;
  border-radius: 8px;
}

.segmented button {
  padding: 8px 14px;
  color: var(--muted);
  background: transparent;
}

.segmented .selected {
  color: #fff;
  background: var(--blue);
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(140px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.metric {
  width: 100%;
  min-height: 112px;
  padding: 18px;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.metric:hover,
.metric.selected {
  border-color: rgba(47, 125, 246, 0.5);
  box-shadow: 0 10px 26px rgba(47, 125, 246, 0.12);
  transform: translateY(-1px);
}

.metric span {
  color: var(--muted);
}

.metric strong {
  display: block;
  margin-top: 14px;
  font-size: 26px;
}

.metric small {
  display: block;
  margin-top: 10px;
  color: var(--muted);
}

.detail-launch-zone {
  margin-top: 24px;
}

#detailLaunchBadge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 12px;
  border: 1px solid #b7ecd8;
  border-radius: 999px;
  color: #087d79;
  background: #effbf6;
  font-size: 13px;
}

.detail-launch-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.detail-launch-card {
  min-height: 154px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  text-align: left;
  background: #f8fbff;
}

.detail-launch-card:hover,
.detail-launch-card.selected {
  border-color: #8fb8ff;
  background: #eef5ff;
}

.detail-launch-card span,
.detail-launch-card small,
.detail-launch-card b {
  overflow-wrap: anywhere;
}

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

.detail-launch-card strong {
  color: var(--blue);
  font-size: 28px;
}

.detail-launch-card small {
  color: var(--ink);
  line-height: 1.45;
}

.detail-launch-card b {
  margin-top: auto;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

body.modal-open {
  overflow: hidden;
}

.metric-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  padding: 28px;
}

.manual-entry-modal {
  position: fixed;
  inset: 0;
  z-index: 102;
  display: none;
  padding: 28px;
}

.manual-entry-modal.open {
  display: grid;
  place-items: center;
}

.manual-entry-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
  background: rgba(23, 32, 51, 0.46);
}

.manual-entry-dialog {
  position: relative;
  z-index: 1;
  width: min(640px, 100%);
  max-height: min(720px, calc(100vh - 56px));
  overflow: auto;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 22px 70px rgba(23, 32, 51, 0.28);
}

.manual-entry-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.manual-entry-head h3 {
  margin: 4px 0 0;
  font-size: 22px;
  line-height: 1.25;
}

.manual-entry-dialog-body {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.manual-entry-sheet-copy {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid #d8e6ff;
  border-radius: 8px;
  background: #f7fbff;
}

.manual-entry-sheet-copy strong {
  color: var(--ink);
  font-size: 18px;
  line-height: 1.3;
}

.manual-entry-sheet-copy p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.manual-entry-sheet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.manual-entry-sheet-actions button,
.manual-entry-sheet-actions label {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 12px;
  border-radius: 8px;
  color: var(--blue-dark);
  background: #eef5ff;
  font-weight: 800;
  cursor: pointer;
}

.manual-entry-sheet-actions button.primary {
  color: #fff;
  background: var(--blue);
}

.manual-entry-modal .manual-entry-form {
  gap: 10px;
}

.company-profile-modal {
  position: fixed;
  inset: 0;
  z-index: 101;
  display: none;
  padding: 28px;
}

.company-profile-modal.open {
  display: grid;
  place-items: center;
}

.company-profile-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
  background: rgba(23, 32, 51, 0.46);
}

.company-profile-dialog {
  position: relative;
  z-index: 1;
  width: min(820px, 100%);
  max-height: min(680px, calc(100vh - 56px));
  overflow: auto;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 22px 70px rgba(23, 32, 51, 0.28);
}

.company-profile-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.company-profile-head h3 {
  margin: 4px 0 0;
  font-size: 22px;
}

.company-profile-hero {
  margin-top: 16px;
  padding: 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #f8fbff;
}

.company-profile-hero strong,
.company-profile-hero p,
.company-profile-hero small {
  display: block;
}

.company-profile-hero strong {
  font-size: 22px;
}

.company-profile-hero p,
.company-profile-hero small {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.company-profile-table {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.company-profile-table article {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.company-profile-table span,
.company-profile-table small {
  display: block;
  color: var(--muted);
  line-height: 1.5;
}

.company-profile-table strong {
  display: block;
  margin: 6px 0;
  color: var(--ink);
  font-size: 20px;
  overflow-wrap: anywhere;
}

.company-manage-modal {
  position: fixed;
  inset: 0;
  z-index: 102;
  display: none;
  padding: 28px;
}

.company-manage-modal.open {
  display: grid;
  place-items: center;
}

.company-manage-dialog {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  max-height: min(760px, calc(100vh - 56px));
  overflow: auto;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 22px 70px rgba(23, 32, 51, 0.28);
}

.company-manage-detail {
  margin-top: 14px;
}

.company-editor-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 5px;
  border: 1px solid #d8e8ff;
  border-radius: 8px;
  background: #f2f7ff;
}

.company-editor-tabs button {
  min-height: 40px;
  color: #3f5678;
  background: transparent;
  font-weight: 900;
}

.company-editor-tabs button.active {
  color: #ffffff;
  background: var(--blue);
}

.company-manage-hero {
  margin-top: 14px;
  padding: 18px;
  border: 1px solid #bfd8ff;
  border-radius: 8px;
  color: #ffffff;
  background: linear-gradient(135deg, #1d63d9 0%, #2f86ff 68%, #55bcff 100%);
}

.company-manage-hero span,
.company-manage-hero strong,
.company-manage-hero p {
  display: block;
}

.company-manage-hero span {
  font-weight: 800;
  opacity: 0.86;
}

.company-manage-hero strong {
  margin-top: 8px;
  font-size: clamp(22px, 3vw, 32px);
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.company-manage-hero p {
  max-width: 680px;
  margin: 10px 0 0;
  line-height: 1.65;
  opacity: 0.9;
}

.company-switch-panel {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #d8e8ff;
  border-radius: 8px;
  background: #f8fbff;
}

.company-switch-panel > span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.company-switch-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.company-switch-list button {
  min-height: 70px;
  padding: 12px;
  border: 1px solid #d9e5ff;
  color: var(--ink);
  background: #ffffff;
  text-align: left;
}

.company-switch-list button.active {
  border-color: var(--blue);
  background: #eef5ff;
}

.company-switch-list strong,
.company-switch-list small {
  display: block;
  overflow-wrap: anywhere;
}

.company-switch-list small {
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.4;
}

.company-manage-list-panel {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid #d8e8ff;
  border-radius: 8px;
  background: #f8fbff;
}

.company-manage-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.company-manage-list-head span,
.company-manage-list-item small,
.company-manage-empty {
  color: var(--muted);
}

.company-manage-list-head span {
  display: block;
  font-size: 13px;
  font-weight: 800;
}

.company-manage-list-head strong {
  display: block;
  margin-top: 3px;
  font-size: 20px;
}

.company-manage-list-head button {
  min-height: 38px;
  padding: 0 14px;
  color: var(--blue);
  background: #edf5ff;
  font-weight: 900;
}

.company-manage-list {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.company-manage-list-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 13px;
  border: 1px solid #d9e5ff;
  border-radius: 8px;
  background: #ffffff;
}

.company-manage-list-item.active {
  border-color: var(--blue);
  background: #eef5ff;
}

.company-manage-list-item strong,
.company-manage-list-item small {
  display: block;
  overflow-wrap: anywhere;
}

.company-manage-list-item strong {
  font-size: 18px;
  line-height: 1.35;
}

.company-manage-list-item small {
  margin-top: 5px;
  line-height: 1.45;
}

.company-manage-list-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.company-manage-list-actions button {
  min-height: 36px;
  padding: 0 12px;
  color: #ffffff;
  background: var(--blue);
  font-weight: 900;
}

.company-manage-list-actions button.ghost {
  color: var(--blue);
  background: #edf5ff;
}

.company-manage-list-actions button.danger {
  color: #d93d5c;
  background: #fff0f4;
}

.company-manage-list-actions button:disabled {
  cursor: default;
  color: #5c6f8e;
  background: #dfeeff;
}

.company-manage-empty {
  margin: 12px 0 0;
  line-height: 1.6;
}

.company-manage-form {
  margin-top: 14px;
}

.company-manage-card {
  margin-bottom: 12px;
  padding: 16px;
  border: 1px solid #e0e8f4;
  border-radius: 8px;
  background: #ffffff;
}

.company-manage-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.company-manage-card header strong {
  font-size: 18px;
}

.company-manage-card header span {
  padding: 5px 10px;
  border-radius: 999px;
  color: var(--blue);
  background: #eef5ff;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.company-manage-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.company-manage-field-grid label {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.company-manage-field-grid label.wide,
.company-manage-field-grid .wide {
  grid-column: 1 / -1;
}

.company-manage-field-grid label span {
  color: #4b5d78;
  font-size: 13px;
  font-weight: 900;
}

.company-manage-field-grid input,
.company-manage-field-grid select {
  width: 100%;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid #d5e0ef;
  border-radius: 8px;
  color: var(--ink);
  background: #fbfdff;
  font: inherit;
  font-weight: 800;
}

.company-manage-field-grid input:focus,
.company-manage-field-grid select:focus {
  outline: 2px solid rgba(47, 125, 246, 0.18);
  border-color: var(--blue);
  background: #ffffff;
}

.company-manage-note {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.company-manage-submit {
  width: 100%;
  min-height: 48px;
  font-size: 16px;
  font-weight: 900;
}

.company-manage-feedback {
  margin: 10px 0 0;
  color: var(--muted);
  text-align: center;
}

.metric-detail-modal.open {
  display: grid;
  place-items: center;
}

.metric-detail-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 0;
  background: rgba(23, 32, 51, 0.46);
}

.metric-detail-dialog {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  max-height: min(720px, calc(100vh - 56px));
  overflow: auto;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 22px 70px rgba(23, 32, 51, 0.28);
}

.metric-detail-close {
  padding: 8px 12px;
  color: var(--blue-dark);
  background: #eef5ff;
}

.metric-detail-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #f8fbff;
}

.metric-detail-summary strong {
  color: var(--blue);
  font-size: 26px;
}

.metric-detail-summary span {
  color: var(--muted);
  text-align: right;
  overflow-wrap: anywhere;
}

.metric-detail-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.metric-detail-actions button {
  min-height: 76px;
  padding: 12px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  text-align: left;
  background: #ffffff;
}

.metric-detail-actions button.selected,
.metric-detail-actions button:hover {
  border-color: #8fb8ff;
  background: #eef5ff;
}

.metric-detail-actions span,
.metric-detail-actions strong {
  display: block;
}

.metric-detail-actions span {
  color: var(--muted);
  font-size: 13px;
}

.metric-detail-actions strong {
  margin-top: 6px;
  color: var(--blue);
  font-size: 18px;
  overflow-wrap: anywhere;
}

.metric-interface-checklist {
  margin-top: 16px;
}

.metric-interface-summary {
  padding: 14px 16px;
  border: 1px solid #f4d59c;
  border-radius: 8px;
  background: #fffaf0;
}

.metric-interface-summary strong {
  display: block;
  margin-bottom: 6px;
  color: #9a5b00;
  font-size: 18px;
}

.metric-interface-summary p {
  margin: 0;
  color: #5f4a25;
  line-height: 1.6;
}

.metric-interface-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.metric-interface-item {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
  cursor: pointer;
}

.metric-interface-item.done {
  border-color: #b7ecd8;
  background: #effbf6;
}

.metric-interface-item.partial {
  border-color: #d8e1ff;
  background: #f6f8ff;
}

.metric-interface-item.todo {
  border-color: #f4d59c;
  background: #fff8ed;
}

.metric-interface-item strong,
.metric-interface-item small,
.metric-interface-item p {
  display: block;
}

.metric-interface-item strong {
  font-size: 15px;
}

.metric-interface-item small,
.metric-interface-item p {
  color: var(--muted);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.metric-interface-item small {
  margin-top: 4px;
}

.metric-interface-item span,
.metric-interface-item b {
  align-self: start;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  white-space: nowrap;
}

.metric-interface-item span {
  color: #1557c0;
  background: #e8f0ff;
}

.metric-interface-item.done span {
  color: #087d79;
  background: #dff8ed;
}

.metric-interface-item.todo span {
  color: #9a5b00;
  background: #fff1d6;
}

.metric-interface-item b {
  color: var(--ink);
  background: #ffffff;
  border: 1px solid var(--line);
}

.metric-interface-item p {
  grid-column: 1 / -1;
  margin: 0;
}

.metric-interface-item.selected,
.metric-detail-summary-grid article.selected,
.metric-detail-table tr.selected td {
  outline: 2px solid rgba(47, 125, 246, 0.48);
  outline-offset: -2px;
  background: #eef5ff;
}

.metric-row-open {
  min-width: 56px;
  padding: 8px 12px;
  border-radius: 8px;
  background: #eef5ff;
  color: #1d4ed8;
  font-weight: 800;
}

.metric-row-open:hover {
  background: #dbeafe;
}

.metric-detail-table-wrap {
  margin-top: 16px;
  max-height: 420px;
  overflow-x: auto;
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

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

.metric-detail-summary-grid article {
  min-width: 0;
  padding: 12px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #f8fbff;
}

.metric-detail-summary-grid span,
.metric-detail-summary-grid small {
  display: block;
  color: var(--muted);
  line-height: 1.5;
}

.metric-detail-summary-grid strong {
  display: block;
  margin: 6px 0;
  color: var(--ink);
  font-size: 17px;
  overflow-wrap: anywhere;
}

.metric-detail-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
}

.metric-detail-section-head strong {
  color: var(--ink);
  font-size: 18px;
}

.metric-detail-section-head span {
  color: var(--muted);
  font-size: 13px;
  text-align: right;
}

.metric-detail-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  background: #ffffff;
}

.metric-detail-table th,
.metric-detail-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}

.metric-detail-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: var(--muted);
  background: #f6f8fc;
  font-weight: 700;
}

.metric-detail-table td:nth-child(4) {
  color: var(--blue);
  font-weight: 800;
}

.metric-detail-summary-grid article,
.metric-detail-table tbody tr {
  cursor: pointer;
}

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

.metric-detail-panel {
  margin-top: 16px;
  padding: 18px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #f8fbff;
}

.metric-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.metric-detail-head h3 {
  margin: 4px 0 0;
  font-size: 20px;
}

.metric-detail-head > strong {
  color: var(--blue);
  font-size: 24px;
  white-space: nowrap;
}

.metric-detail-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.metric-detail-grid article {
  min-height: 72px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.metric-detail-grid span {
  color: var(--muted);
}

.metric-detail-grid strong {
  display: block;
  margin-top: 8px;
  font-size: 15px;
  overflow-wrap: anywhere;
}

.metric-detail-note {
  margin: 12px 0 0;
  color: var(--muted);
  line-height: 1.7;
}

.metric-detail-modal.focused-detail .metric-detail-dialog {
  width: min(980px, 100%);
}

.metric-detail-modal.focused-detail .metric-detail-actions,
.metric-detail-modal.focused-detail .metric-detail-summary-grid,
.metric-detail-modal.focused-detail .metric-interface-checklist,
.metric-detail-modal.focused-detail .metric-detail-note {
  display: none;
}

.metric-detail-modal.focused-detail .metric-detail-table-wrap {
  max-height: min(520px, calc(100vh - 240px));
}

.metric.income strong {
  color: var(--blue);
}

.metric.expense strong {
  color: var(--rose);
}

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

.chanjet-live-card {
  min-height: 98px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.chanjet-live-card.ready {
  border-color: #b7ecd8;
  background: #effbf6;
}

.chanjet-live-card.hold {
  border-color: #f0d2aa;
  background: #fff8ed;
}

.chanjet-live-card strong {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.chanjet-live-card strong span {
  color: var(--blue);
  font-size: 12px;
  white-space: nowrap;
}

.chanjet-live-card.hold strong span {
  color: var(--amber);
}

.chanjet-live-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.metric.balance strong {
  color: var(--green);
}

.metric.invoice strong {
  color: #7c54d9;
}

.boss-value-zone {
  margin-top: 22px;
}

.boss-value-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.boss-value-card {
  min-height: 168px;
  padding: 18px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #ffffff;
  cursor: pointer;
}

.boss-value-card:hover {
  border-color: rgba(47, 125, 246, 0.45);
  box-shadow: 0 12px 30px rgba(47, 125, 246, 0.1);
}

.boss-value-card span,
.boss-value-card p {
  color: var(--muted);
}

.boss-value-card strong {
  display: block;
  margin-top: 10px;
  color: var(--ink);
  font-size: 24px;
  overflow-wrap: anywhere;
}

.boss-value-card p {
  min-height: 44px;
  margin: 10px 0 14px;
  line-height: 1.6;
}

.boss-value-card button {
  padding: 8px 12px;
  color: var(--blue);
  background: #eef5ff;
  font-weight: 800;
}

.deal-proof-zone {
  margin-bottom: 22px;
  padding: 22px;
  border: 1px solid #cfe2dc;
  border-radius: 8px;
  background: #fbfffd;
}

.deal-proof-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1.2fr) repeat(3, minmax(180px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.deal-proof-brief,
.deal-proof-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid #dcefe8;
  border-radius: 8px;
  background: #ffffff;
}

.deal-proof-brief {
  display: grid;
  align-content: center;
}

.deal-proof-brief strong,
.deal-proof-card strong {
  display: block;
  color: var(--ink);
}

.deal-proof-brief p,
.deal-proof-card p,
.deal-proof-card span {
  color: var(--muted);
}

.deal-proof-brief p {
  margin: 10px 0 0;
  line-height: 1.7;
}

.deal-proof-card {
  cursor: pointer;
}

.deal-proof-card:hover {
  border-color: rgba(19, 185, 129, 0.45);
  box-shadow: 0 12px 30px rgba(19, 185, 129, 0.1);
}

.deal-proof-card b {
  display: block;
  margin: 12px 0 8px;
  color: #087d79;
  font-size: 22px;
}

.deal-proof-card button {
  margin-top: 8px;
  padding: 8px 12px;
  color: #087d79;
  background: #eaf8f6;
  font-weight: 800;
}

.service-order-zone {
  border-color: #d8e1ff;
  background: #ffffff;
}

.service-order-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 16px;
}

.service-order-card {
  min-height: 160px;
  padding: 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fbfdff;
  cursor: pointer;
}

.service-order-card:hover {
  border-color: rgba(47, 125, 246, 0.48);
  box-shadow: 0 12px 30px rgba(47, 125, 246, 0.09);
}

.service-order-card span,
.service-order-card p {
  color: var(--muted);
}

.service-order-card strong {
  display: block;
  margin: 10px 0;
  color: var(--ink);
  font-size: 21px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.service-order-card p {
  min-height: 42px;
  margin-bottom: 12px;
  line-height: 1.55;
}

.service-order-card button {
  padding: 8px 12px;
  color: var(--blue);
  background: #eef5ff;
  font-weight: 800;
}

.section-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.service-intent-feedback {
  display: none;
  margin-top: 14px;
  padding: 14px 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fbfdff;
  color: var(--muted);
  line-height: 1.55;
}

.service-intent-feedback.active,
.service-intent-feedback.error {
  display: block;
}

.service-intent-feedback.active {
  border-color: #a8efd2;
  background: #f0fff8;
}

.service-intent-feedback.error {
  border-color: #ffd1d1;
  background: #fff7f7;
}

.service-intent-feedback strong {
  display: block;
  margin-bottom: 4px;
  color: var(--ink);
}

.boss-decision-draft {
  margin-top: 14px;
}

.boss-decision-empty,
.boss-decision-card {
  padding: 15px 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fbfdff;
}

.boss-decision-empty strong,
.boss-decision-card strong {
  display: block;
  line-height: 1.35;
}

.boss-decision-empty p,
.boss-decision-card p,
.boss-decision-card small {
  display: block;
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.55;
}

.boss-decision-card {
  border-color: #b8e6d1;
  background: #f0fff8;
  box-shadow: 0 14px 32px rgba(15, 159, 149, 0.1);
}

.boss-decision-card > span {
  display: inline-block;
  margin-bottom: 8px;
  padding: 5px 9px;
  border-radius: 999px;
  color: #087d79;
  background: #dcfbf4;
  font-size: 13px;
  font-weight: 800;
}

.boss-decision-card div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.boss-decision-card button {
  padding: 9px 12px;
  color: #fff;
  background: var(--teal);
}

.declaration-zone {
  border-color: #d8e1ff;
  background: #ffffff;
}

#declarationBadge {
  padding: 10px 14px;
  border-radius: 8px;
  color: #1557c0;
  background: #e8f0ff;
  font-size: 18px;
}

.declaration-summary {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 0.65fr);
  gap: 14px;
  margin-top: 18px;
}

.declaration-summary article {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.declaration-summary article:first-child {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.declaration-summary article.submitted {
  border-color: #bfe9d7;
  background: #f3fcf8;
}

.declaration-summary article.active {
  border-color: #d8e1ff;
  background: #f6f8ff;
}

.declaration-summary article.hold {
  border-color: #f4d59c;
  background: #fffaf0;
}

.declaration-summary strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

.declaration-summary p {
  margin-bottom: 6px;
  color: var(--muted);
}

.declaration-summary small {
  color: #087d79;
  overflow-wrap: anywhere;
}

.declaration-summary span {
  flex: 0 0 220px;
  color: var(--blue-dark);
  font-weight: 700;
  overflow-wrap: anywhere;
}

.declaration-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.declaration-steps article {
  min-width: 0;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.declaration-steps span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #a9b2c3;
  font-weight: 800;
}

.declaration-steps article.done span {
  background: var(--green);
}

.declaration-steps article.active span {
  background: var(--blue);
}

.declaration-steps strong,
.declaration-steps small {
  display: block;
}

.declaration-steps small {
  margin-top: 4px;
  color: var(--muted);
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
  gap: 22px;
}

.toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
}

.task-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.task {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.task strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

.task p {
  margin-bottom: 0;
  color: var(--muted);
}

.task button {
  align-self: center;
  padding: 10px 14px;
  color: #fff;
  background: var(--blue);
}

.steps {
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 14px;
}

.steps li {
  display: grid;
  grid-template-columns: 34px 1fr;
  align-items: center;
  gap: 12px;
}

.steps span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--blue);
  font-weight: 700;
}

.upload-zone {
  background: #fff7e8;
  border-color: #f4d59c;
  flex-wrap: wrap;
}

.smart-zone,
.queue-zone,
.followup-zone {
  margin-bottom: 22px;
  padding: 22px;
  border: 1px solid #b9eadb;
  border-radius: 8px;
  background: #f0fbf8;
}

.queue-zone {
  background: #f6f8ff;
  border-color: #d8e1ff;
}

.followup-zone {
  background: #ffffff;
  border-color: var(--line);
}

.assistant-zone {
  background: #ffffff;
  border-color: #d8e1ff;
}

#readinessScore,
#queueSavedMinutes,
#followupCount,
#assistantStatus {
  padding: 10px 14px;
  border-radius: 8px;
  color: #077858;
  background: #dcf8ee;
  font-size: 18px;
}

#queueSavedMinutes {
  color: #1557c0;
  background: #e8f0ff;
}

#followupCount {
  color: #a05208;
  background: #fff1db;
}

#assistantStatus {
  color: #1557c0;
  background: #e8f0ff;
}

.suggestion-list,
.queue-list,
.followup-list {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.suggestion,
.queue-item,
.followup-item,
.followup-empty {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 14px;
  padding: 16px;
  border: 1px solid #cfeee4;
  border-radius: 8px;
  background: #ffffff;
}

.chanjet-live-card,
.suggestion,
.queue-item,
.followup-item,
.declaration-summary article,
.declaration-steps article,
#steps li {
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.chanjet-live-card:hover,
.suggestion:hover,
.queue-item:hover,
.followup-item:hover,
.declaration-summary article:hover,
.declaration-steps article:hover,
#steps li:hover {
  border-color: rgba(47, 125, 246, 0.42);
  box-shadow: 0 10px 24px rgba(23, 32, 51, 0.08);
  transform: translateY(-1px);
}

.suggestion > span,
.queue-item > span {
  width: 42px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--green);
  font-weight: 700;
}

.queue-item > span {
  background: var(--blue);
}

.followup-item > span {
  width: 42px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--amber);
  font-weight: 700;
}

.suggestion strong,
.queue-item strong,
.followup-item strong,
.followup-empty strong {
  display: block;
  margin-bottom: 6px;
}

.suggestion p,
.queue-item p,
.followup-item p,
.followup-empty p {
  margin-bottom: 6px;
  color: var(--muted);
}

.followup-message {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 8px;
  background: #fff7e8;
  border: 1px solid #f4d59c;
  color: #8a4a07;
}

.followup-empty {
  grid-template-columns: 1fr;
}

.followup-item small {
  color: #087d79;
}

.client-gate {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid #d8e1ff;
  background: #ffffff;
}

.client-gate strong {
  display: block;
  margin-bottom: 6px;
}

.client-gate p {
  margin-bottom: 0;
  color: var(--muted);
}

.assistant-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.assistant-quick button {
  padding: 10px 12px;
  color: var(--blue-dark);
  background: #eef5ff;
}

.assistant-box {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 10px;
  margin-top: 14px;
}

.assistant-box input {
  min-width: 0;
  height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
}

.assistant-box button {
  padding: 0 18px;
  color: #fff;
  background: var(--blue);
}

.assistant-box button:disabled {
  cursor: wait;
  opacity: 0.58;
}

.assistant-box button.handoff {
  color: #8a4a07;
  background: #fff7e8;
  border: 1px solid #f4d59c;
}

.assistant-answer {
  display: none;
  margin-top: 14px;
  padding: 14px 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #f6f8ff;
}

.assistant-answer.active,
.assistant-answer.ticket,
.assistant-answer.error {
  display: block;
}

.assistant-answer.ticket {
  border-color: #f4d59c;
  background: #fffaf0;
}

.assistant-answer.error {
  border-color: #ffd1dc;
  background: #fff4f6;
}

.assistant-answer strong {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.assistant-answer p {
  margin-bottom: 6px;
  color: var(--muted);
}

.assistant-answer small {
  color: #087d79;
  overflow-wrap: anywhere;
}

.assistant-ticket-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.assistant-ticket-head,
.assistant-ticket-item,
.assistant-ticket-empty {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.assistant-ticket-item {
  cursor: pointer;
}

.assistant-ticket-item:hover {
  border-color: rgba(47, 125, 246, 0.42);
  box-shadow: 0 10px 24px rgba(23, 32, 51, 0.08);
}

.assistant-ticket-item p,
.assistant-ticket-empty p {
  margin: 4px 0;
  color: var(--muted);
}

.assistant-ticket-item small {
  color: #087d79;
}

.assistant-ticket-head span,
.assistant-ticket-item > span {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  color: #8a4a07;
  background: #fff7e8;
  border: 1px solid #f4d59c;
  font-weight: 700;
}

.assistant-ticket-detail {
  display: none;
  margin-top: 14px;
}

.assistant-ticket-detail.active {
  display: block;
}

.assistant-ticket-detail article {
  padding: 16px;
  border: 1px solid #f4d59c;
  border-radius: 8px;
  background: #fffaf0;
}

.assistant-ticket-detail strong {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.assistant-ticket-detail strong span {
  color: #8a4a07;
}

.assistant-ticket-detail p {
  margin: 8px 0;
  color: var(--muted);
}

.assistant-ticket-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.assistant-ticket-meta span {
  padding: 6px 10px;
  border-radius: 999px;
  color: #1557c0;
  background: #e8f0ff;
  font-size: 13px;
  font-weight: 700;
}

.assistant-ticket-detail small {
  color: #087d79;
}

.suggestion small {
  color: #087d79;
}

.ingestion-result {
  width: 100%;
  display: none;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #f4d59c;
}

.ingestion-result.active,
.ingestion-result.error {
  display: grid;
  gap: 6px;
}

.ingestion-result strong,
.ingestion-result small {
  display: block;
}

.ingestion-result p {
  margin-bottom: 0;
  color: var(--muted);
}

.ingestion-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ingestion-badges span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eff6ff;
  color: #2463eb;
  font-size: 13px;
  font-weight: 700;
}

.ingestion-result small {
  color: #087d79;
}

.ingestion-result.error {
  border-color: #ffd1dc;
  background: #fff4f6;
}

.ingestion-result.error small {
  color: #b22646;
}

.client-uploaded-files {
  width: 100%;
  display: none;
  gap: 12px;
  margin-top: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.client-uploaded-files.active,
.client-uploaded-files.error {
  display: grid;
}

.client-uploaded-files-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.client-uploaded-files-head div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.client-uploaded-files-head span,
.client-uploaded-file-item span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.client-uploaded-files-head strong {
  color: var(--ink);
  font-size: 18px;
  overflow-wrap: anywhere;
}

.client-uploaded-files-head button,
.client-uploaded-file-item a {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  border-radius: 8px;
  color: var(--blue-dark);
  background: #eef5ff;
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.client-uploaded-files p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.client-uploaded-file-list {
  display: grid;
  gap: 10px;
}

.client-uploaded-file-item {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.client-uploaded-file-item.highlight {
  border-color: #b8d5ff;
  background: #f4f8ff;
}

.client-uploaded-file-item div {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.client-uploaded-file-item strong,
.client-uploaded-file-item small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-uploaded-file-item strong {
  color: var(--ink);
  font-size: 16px;
}

.client-uploaded-file-item small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.client-activity-zone {
  display: grid;
  gap: 18px;
}

.client-activity-list {
  display: grid;
  gap: 12px;
}

.client-activity-empty,
.client-activity-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  border: 1px solid #dce7ff;
  border-radius: 8px;
  background: #f7fbff;
}

.client-activity-empty {
  display: block;
  color: var(--muted);
}

.client-activity-empty strong,
.client-activity-item strong {
  display: block;
  color: var(--text);
}

.client-activity-empty p,
.client-activity-item p {
  margin: 6px 0 0;
  color: var(--muted);
}

.client-activity-item span {
  flex: 0 0 auto;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}

.client-activity-item.error {
  border-color: #ffd1dc;
  background: #fff4f6;
}

.client-activity-item.error strong {
  color: #971b3d;
}

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

.ai-audit-card {
  min-height: 162px;
  padding: 16px;
  border: 1px solid #d8e1ff;
  border-radius: 8px;
  background: #fbfdff;
}

.ai-audit-card span,
.ai-audit-card p {
  color: var(--muted);
}

.ai-audit-card strong {
  display: block;
  margin: 9px 0;
  font-size: 19px;
}

.ai-audit-card p {
  margin: 0;
  line-height: 1.6;
}

.ai-audit-card button {
  margin-top: 14px;
  padding: 9px 12px;
  color: #fff;
  background: var(--blue);
}

.ai-audit-live {
  grid-column: 1 / -1;
  padding: 16px;
  border: 1px solid #cfe0ff;
  border-radius: 8px;
  background: #f7fbff;
}

.ai-audit-live-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.ai-audit-live-head span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.ai-audit-live-head strong {
  display: block;
  margin-top: 4px;
  font-size: 20px;
}

.ai-audit-live-head button {
  padding: 9px 12px;
  color: var(--blue);
  border: 1px solid #bed4ff;
  background: #fff;
  font-weight: 800;
}

.ai-audit-live-list {
  display: grid;
  gap: 10px;
}

.ai-audit-live-item,
.ai-audit-live-empty {
  padding: 13px;
  border: 1px solid #dde8fb;
  border-left: 4px solid var(--blue);
  border-radius: 8px;
  background: #fff;
}

.ai-audit-live-item.medium {
  border-left-color: var(--amber);
}

.ai-audit-live-item.high {
  border-left-color: var(--red);
}

.ai-audit-live-item strong {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
  font-size: 16px;
}

.ai-audit-live-item strong span {
  flex: none;
  padding: 4px 8px;
  border-radius: 999px;
  color: #0d5ca8;
  background: #e8f2ff;
  font-size: 12px;
}

.ai-audit-live-item p,
.ai-audit-live-empty p,
.ai-audit-live-item small {
  display: block;
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.ai-audit-live-item small + small {
  margin-top: 4px;
}

.client-toast {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 80;
  max-width: min(680px, calc(100vw - 32px));
  padding: 12px 16px;
  color: #0f513c;
  background: #e8fff5;
  border: 1px solid #a9efd2;
  border-radius: 8px;
  box-shadow: 0 18px 50px rgba(23, 32, 51, 0.18);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -12px);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.client-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.client-toast.error {
  color: #971b3d;
  background: #fff4f6;
  border-color: #ffd1dc;
}

.client-ai-assistant {
  position: static;
  z-index: 1;
  min-width: 0;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  border-left: 1px solid #d8e2ef;
  background: #ffffff;
}

.client-ai-assistant.interaction-block {
  pointer-events: none;
}

.client-ai-window {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  max-width: none;
  max-height: none;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #fff;
  box-shadow: none;
}

.client-ai-window header {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 12px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #13b981);
  cursor: default;
  user-select: none;
  touch-action: none;
}

html.foundation-bridge .client-ai-window header {
  grid-template-columns: 46px minmax(0, 1fr);
}

#foundationAiCollapse,
#clientAiMinimize,
#clientAiClose,
.client-ai-resize {
  display: none;
}

#foundationAiCollapse {
  color: #526078;
  border-color: #cfd8e6;
  background: #ffffff;
}

.client-ai-window header div {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.client-ai-window header small {
  overflow: hidden;
  color: rgba(255, 255, 255, 0.84);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-ai-cat {
  position: relative;
  width: 40px;
  height: 40px;
  color: #1251b6;
  background: #fff;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 900;
}

.client-ai-cat::before,
.client-ai-cat::after {
  content: "";
  position: absolute;
  top: -4px;
  width: 14px;
  height: 14px;
  background: #fff;
  transform: rotate(45deg);
}

.client-ai-cat::before {
  left: 6px;
}

.client-ai-cat::after {
  right: 6px;
}

.client-ai-cat span::before,
.client-ai-cat span::after {
  content: "";
  position: absolute;
  top: 16px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #172033;
}

.client-ai-cat span::before {
  left: 13px;
}

.client-ai-cat span::after {
  right: 13px;
}

.client-ai-cat strong {
  position: relative;
  z-index: 1;
  display: block;
  padding-top: 20px;
  font-size: 10px;
}

.client-ai-icon {
  width: 32px;
  height: 32px;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  font-size: 18px;
  font-weight: 900;
}

html.foundation-bridge .client-ai-icon.foundation-panel-collapse {
  width: 34px;
  height: 34px;
  color: #526078;
  border: 1px solid #cfd8e6;
  background: #ffffff;
  font-size: 22px;
}

.client-ai-messages {
  display: grid;
  align-content: start;
  gap: 9px;
  overflow: auto;
  padding: 14px;
  background: #f7fbff;
}

.client-ai-msg {
  max-width: 88%;
  padding: 10px 11px;
  border: 1px solid #e4ecf8;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
}

.client-ai-msg.user {
  justify-self: end;
  color: #fff;
  border-color: var(--blue);
  background: var(--blue);
}

.client-ai-msg.audit {
  max-width: 100%;
  color: #075f50;
  background: #e8fff7;
  border-color: #a5efd6;
  white-space: pre-line;
}

.client-ai-msg.guide {
  max-width: 100%;
  color: #173158;
  background: #f2f7ff;
  border-color: #cfe0fb;
  white-space: pre-line;
  font-weight: 700;
}

.client-ai-form {
  display: grid;
  grid-template-columns: 1fr 70px;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--line);
}

.client-ai-consent,
.client-ai-habit {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 8px;
  align-items: center;
  padding: 9px 12px;
  border-top: 1px solid #e7eef9;
  background: #f8fbff;
  color: #21324d;
  font-size: 12px;
}

.client-ai-habit {
  grid-template-columns: minmax(0, 1fr) 128px;
}

.client-ai-consent input {
  width: 16px;
  height: 16px;
  accent-color: var(--blue);
}

.client-ai-consent span,
.client-ai-habit span {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.client-ai-consent strong,
.client-ai-consent small,
.client-ai-habit strong,
.client-ai-habit small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.client-ai-consent small,
.client-ai-habit small {
  color: #67758f;
  font-size: 11px;
}

.client-ai-habit select {
  min-width: 0;
  height: 32px;
  border: 1px solid #d9e3f2;
  border-radius: 8px;
  background: #fff;
  color: #173158;
  font: inherit;
  font-size: 12px;
}

.client-ai-form input {
  min-width: 0;
  height: 40px;
  padding: 0 11px;
  border: 1px solid #d9e3f2;
  border-radius: 8px;
  font: inherit;
}

.client-ai-form button,
.client-ai-confirm {
  min-height: 40px;
  color: #fff;
  background: var(--blue);
  font-weight: 900;
}

.client-ai-form button:disabled {
  opacity: 0.72;
}

.client-ai-status {
  margin: 0 12px 12px;
  padding: 9px 10px;
  border: 1px solid #d8e8ff;
  border-radius: 8px;
  color: #174077;
  background: #f2f7ff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.client-ai-status.done {
  color: #066047;
  border-color: #a5efd6;
  background: #e8fff7;
}

.client-ai-status.error {
  color: #9f1239;
  border-color: #fecdd3;
  background: #fff1f2;
}

.client-ai-progress {
  display: grid;
  gap: 7px;
  margin: 0 12px 12px;
}

.client-ai-progress[hidden] {
  display: none;
}

.client-ai-progress-step {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 8px;
  align-items: center;
  padding: 7px 9px;
  border: 1px solid #d8e8ff;
  border-radius: 8px;
  color: #41536f;
  background: #f8fbff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
}

.client-ai-progress-step::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid #bfd2ef;
  background: #fff;
  box-sizing: border-box;
}

.client-ai-progress-step.active {
  color: #174077;
  border-color: #9bc2ff;
  background: #edf5ff;
}

.client-ai-progress-step.active::before {
  border-color: #2563eb;
  background: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.16);
}

.client-ai-progress-step.done {
  color: #066047;
  border-color: #a5efd6;
  background: #e8fff7;
}

.client-ai-progress-step.done::before {
  border-color: #10b981;
  background: #10b981;
}

.client-ai-progress-step.error {
  color: #9f1239;
  border-color: #fecdd3;
  background: #fff1f2;
}

.client-ai-progress-step.error::before {
  border-color: #e11d48;
  background: #e11d48;
}

.client-ai-confirm {
  margin: 0 12px 12px;
  background: var(--green);
}

.client-ai-resize {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 24px;
  height: 24px;
  cursor: nwse-resize;
  touch-action: none;
}

.client-ai-resize::after {
  content: "";
  position: absolute;
  right: 7px;
  bottom: 7px;
  width: 10px;
  height: 10px;
  border-right: 2px solid #8aa3c7;
  border-bottom: 2px solid #8aa3c7;
}

.client-ai-assistant.minimized .client-ai-window {
  width: 62px !important;
  height: 62px !important;
  min-width: 62px;
  min-height: 62px;
  border-radius: 50%;
  overflow: visible;
}

.client-ai-assistant.minimized .client-ai-window > *:not(header),
.client-ai-assistant.minimized .client-ai-window header div,
.client-ai-assistant.minimized .client-ai-icon {
  display: none;
}

.client-ai-assistant.minimized .client-ai-window header {
  display: block;
  padding: 11px;
  background: transparent;
}

.client-ai-assistant.minimized .client-ai-cat {
  width: 40px;
  height: 40px;
  box-shadow: 0 10px 30px rgba(21, 35, 66, 0.22);
}

html.foundation-bridge .client-ai-assistant.minimized .client-ai-window {
  width: 380px !important;
  height: 460px !important;
  min-width: 300px;
  min-height: 320px;
  border-radius: 8px;
  overflow: hidden;
}

html.foundation-bridge .client-ai-assistant.minimized .client-ai-window > *:not(header) {
  display: initial;
}

html.foundation-bridge .client-ai-assistant.minimized .client-ai-messages,
html.foundation-bridge .client-ai-assistant.minimized .client-ai-consent,
html.foundation-bridge .client-ai-assistant.minimized .client-ai-habit,
html.foundation-bridge .client-ai-assistant.minimized .client-ai-form,
html.foundation-bridge .client-ai-assistant.minimized .client-ai-progress {
  display: grid;
}

html.foundation-bridge .client-ai-assistant.minimized .client-ai-window header {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 34px;
  gap: 9px;
  align-items: center;
  padding: 12px;
  background: linear-gradient(135deg, #2563eb, #13b981);
}

html.foundation-bridge .client-ai-assistant.minimized .client-ai-window header div {
  display: grid;
}

html.foundation-bridge .client-ai-assistant.minimized .client-ai-icon.foundation-panel-collapse {
  display: inline-flex;
}

@media (max-width: 980px) {
  body {
    height: auto;
    grid-template-columns: 1fr;
    overflow: visible;
  }

  .sidebar {
    position: static;
    top: auto;
    width: 100%;
    height: auto;
    min-height: auto;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .shell {
    height: auto;
    overflow: visible;
  }

  .client-ai-assistant {
    height: min(680px, 78dvh);
    border-top: 1px solid #d8e2ef;
    border-left: 0;
  }

  .nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    padding-right: 0;
  }

  .nav-group {
    display: contents;
  }

  .nav-item {
    min-height: 44px;
    justify-content: center;
    gap: 7px;
    padding: 9px 8px;
    font-size: 14px;
  }

  .nav-icon {
    width: 20px;
    height: 20px;
    mask-size: 19px 19px;
    -webkit-mask-size: 19px 19px;
  }

  .nav-item.active::before {
    left: 10px;
    right: 10px;
    top: auto;
    bottom: -4px;
    width: auto;
    height: 3px;
  }

  .nav-subitems {
    grid-column: 1 / -1;
    display: flex;
    gap: 8px;
    overflow-x: auto;
    margin-left: 0;
    padding-left: 0;
    padding-right: 0;
  }

  .nav-subitems::before {
    display: none;
  }

  .nav-subitem {
    width: auto;
    min-width: max-content;
    padding: 8px 12px;
    white-space: nowrap;
  }

  .nav-subitem::before {
    display: none;
  }

  .status-band,
  .metrics,
  .client-access-grid,
  .client-home-grid,
  .period-command-grid,
  .accounting-flow-grid,
  .manual-entry-grid,
  .tax-center-grid,
  .report-center-grid,
  .report-center-shell,
  .report-center-toolbar,
  .report-center-list,
  .renewal-grid,
  .renewal-services,
  .renewal-checkout-head,
  .renewal-payment-layout,
  .share-grid,
  .boss-value-grid,
  .deal-proof-grid,
  .company-profile-grid,
  .company-manage-field-grid,
  .client-ai-assurance-head,
  .client-ai-assurance-grid,
  .portal-map-grid,
  .buyer-hero,
  .buyer-trust-grid,
  .purchase-confidence-grid,
  .ai-audit-grid,
  .service-order-grid,
  .detail-launch-grid,
  .metric-detail-actions,
  .metric-detail-grid,
  .metric-interface-grid,
  .chanjet-live-summary,
  .split-layout,
  .declaration-summary,
  .declaration-steps,
  .data-parity-overview,
  .data-parity-grid,
  .data-parity-diff-list {
    grid-template-columns: 1fr;
  }

  .company-profile-actions {
    width: 100%;
    justify-content: stretch;
  }

  .company-profile-actions button,
  .company-manage-submit {
    flex: 1;
  }

  .company-manage-list-head,
  .company-manage-list-item {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .company-manage-list-head {
    flex-direction: column;
  }

  .company-manage-list-head button,
  .company-manage-list-actions button {
    width: 100%;
  }

  .company-manage-list-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .company-manage-modal {
    padding: 14px;
  }

  .company-manage-dialog {
    max-height: calc(100vh - 28px);
    padding: 18px;
  }

  .company-manage-field-grid label.wide,
  .company-manage-field-grid .wide {
    grid-column: auto;
  }

  .data-parity-actions {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .data-parity-actions button {
    width: 100%;
    min-height: 38px;
  }

  .client-ai-assurance-head strong {
    justify-self: start;
    white-space: normal;
  }

  .report-modal {
    padding: 14px;
  }

  .report-modal-dialog {
    width: calc(100vw - 28px);
    max-height: calc(100vh - 28px);
  }

  .report-modal-body {
    grid-template-columns: 1fr;
    overflow: auto;
  }

  .report-voucher-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .renewal-payment-layout {
    padding: 12px;
  }

  .renewal-qr-card {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .report-settings {
    align-content: stretch;
  }

  .declaration-summary article:first-child {
    flex-direction: column;
  }

  .declaration-summary span {
    flex-basis: auto;
  }
}

@media (max-width: 640px) {
  .shell {
    padding: 18px;
  }

  .manual-entry-modal {
    align-items: end;
    padding: 12px;
  }

  .manual-entry-modal.open {
    place-items: end center;
  }

  .manual-entry-dialog {
    width: 100%;
    max-height: calc(100vh - 24px);
    padding: 18px;
    border-radius: 8px 8px 0 0;
  }

  .report-voucher-modal {
    place-items: end center;
    padding: 12px;
  }

  .report-voucher-dialog {
    width: 100%;
    max-height: calc(100vh - 24px);
    padding: 16px;
    border-radius: 8px 8px 0 0;
  }

  .report-voucher-head {
    flex-direction: column;
  }

  .report-voucher-summary {
    grid-template-columns: 1fr;
  }

  .report-voucher-detail-table {
    min-width: 680px;
  }

  .manual-entry-head {
    align-items: flex-start;
  }

  .manual-entry-sheet-actions {
    flex-direction: column;
  }

  .manual-entry-sheet-actions button,
  .manual-entry-sheet-actions label {
    width: 100%;
  }

  .topbar,
  .section-title,
  .metric-detail-head,
  .buyer-actions,
  .upload-zone {
    align-items: flex-start;
    flex-direction: column;
  }

  .metric-detail-head > strong {
    white-space: normal;
  }

  .actions,
  .upload-actions,
  .segmented,
  .assistant-box,
  .client-home-actions,
  .client-login-form {
    width: 100%;
  }

  .actions button,
  .upload-actions button,
  .client-home-actions button,
  .segmented button,
  .client-login-form button {
    flex: 1;
  }

  .assistant-box,
  .client-login-form {
    grid-template-columns: 1fr;
  }

  .client-uploaded-files-head,
  .client-uploaded-file-item {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .client-uploaded-files-head {
    flex-direction: column;
  }

  .client-uploaded-files-head button,
  .client-uploaded-file-item a {
    width: 100%;
  }

  .report-preview article,
  .manual-entry-item {
    align-items: flex-start;
    flex-direction: column;
  }

  .report-document-meta {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .report-modal-head {
    flex-direction: column;
  }

  .report-modal-actions {
    width: 100%;
    justify-content: stretch;
  }

  .report-modal-actions button,
  .report-modal-head > button {
    flex: 1;
  }

  .report-modal-table-wrap {
    max-height: 360px;
  }

  .report-inline-card {
    padding: 14px;
  }

  .renewal-qr-code {
    width: min(220px, 100%);
    height: auto;
    aspect-ratio: 1;
  }

  .renewal-transfer-card dl div {
    grid-template-columns: 1fr;
  }

  .renewal-payment-actions {
    width: 100%;
    flex-direction: column;
  }

  .renewal-payment-actions button {
    width: 100%;
  }

  .metric-detail-modal {
    padding: 14px;
  }

  .metric-detail-dialog {
    max-height: calc(100vh - 28px);
    padding: 18px;
  }

  .metric-detail-summary {
    align-items: flex-start;
    flex-direction: column;
  }

  .metric-detail-summary span {
    text-align: left;
  }

  .data-parity-overview,
  .data-parity-grid,
  .data-parity-diff-list {
    grid-template-columns: 1fr;
  }

  .data-parity-diff-item > div {
    flex-direction: column;
    align-items: flex-start;
  }
}
