/* TradeLead AI UI V3 */
.ui-v3 {
  --v3-bg: #f4f6f7;
  --v3-surface: #ffffff;
  --v3-surface-soft: #f8f9fa;
  --v3-surface-strong: #eef1f2;
  --v3-line: #e0e5e7;
  --v3-line-strong: #cbd3d7;
  --v3-text: #17201d;
  --v3-text-soft: #42504b;
  --v3-muted: #74807b;
  --v3-sidebar: #1b2022;
  --v3-sidebar-hover: #292f31;
  --v3-sidebar-active: #303a38;
  --v3-teal: #087c67;
  --v3-teal-dark: #05604f;
  --v3-teal-soft: #e5f4ef;
  --v3-blue: #2f6fce;
  --v3-blue-soft: #eaf1fc;
  --v3-amber: #b66d11;
  --v3-amber-soft: #fff4df;
  --v3-red: #b8404c;
  --v3-red-soft: #fff0f1;
  --v3-shadow: 0 12px 30px rgba(22, 32, 29, 0.08);
  color: var(--v3-text);
  background: var(--v3-bg);
  font-family: Inter, "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  letter-spacing: 0;
}

.ui-v3 *,
.ui-v3 *::before,
.ui-v3 *::after {
  box-sizing: border-box;
  letter-spacing: 0;
}

.ui-v3 ::selection {
  color: #fff;
  background: var(--v3-teal);
}

.ui-v3 :focus-visible {
  outline: 2px solid rgba(8, 124, 103, 0.34);
  outline-offset: 2px;
}

.ui-v3 #appShell {
  grid-template-columns: 236px minmax(0, 1fr);
  grid-template-rows: 72px minmax(0, 1fr);
  min-height: 100dvh;
  background: var(--v3-bg);
}

.ui-v3 header {
  grid-column: 2;
  grid-row: 1;
  z-index: 20;
  min-width: 0;
  min-height: 72px;
  padding: 0 30px;
  border-bottom: 1px solid var(--v3-line);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: none;
}

.ui-v3 header > div:first-child {
  min-width: 0;
}

.ui-v3 header h1 {
  margin: 0;
  color: var(--v3-text);
  font-size: 19px;
  font-weight: 760;
  line-height: 1.25;
}

.ui-v3 header #status {
  max-width: 680px;
  margin-top: 3px;
  overflow: hidden;
  color: var(--v3-muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ui-v3 header .toolbar {
  margin-left: auto;
  flex-wrap: nowrap;
}

.ui-v3 header .quota {
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--v3-line);
  border-radius: 6px;
  background: var(--v3-surface-soft);
  color: var(--v3-text-soft);
  font-size: 10px;
}

.ui-v3 header #logoutBtn {
  color: var(--v3-text-soft);
  background: #fff;
}

.ui-v3 .app-nav {
  grid-column: 1;
  grid-row: 1 / 3;
  width: 236px;
  height: 100dvh;
  padding: 16px 12px 14px;
  overflow-x: hidden;
  overflow-y: auto;
  border: 0;
  background: var(--v3-sidebar);
  scrollbar-width: thin;
  scrollbar-color: #41494b transparent;
}

.ui-v3 .brand-lockup {
  min-height: 56px;
  gap: 11px;
  margin: 0 2px 14px;
  padding: 4px 8px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

.ui-v3 .brand-lockup .brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}

.ui-v3 .brand-lockup .brand-copy strong {
  color: #f7f9f8;
  font-size: 14px;
  font-weight: 780;
}

.ui-v3 .brand-lockup .brand-copy span {
  color: #97a19e;
  font-size: 10px;
}

.ui-v3 .nav-label {
  padding: 13px 11px 7px;
  color: #727d7a;
  font-size: 9px;
  font-weight: 760;
  text-transform: none;
}

.ui-v3 .nav-item,
.ui-v3 .nav-card-button,
.ui-v3 .nav-more-toggle {
  position: relative;
  width: 100%;
  min-height: 42px;
  justify-content: flex-start;
  gap: 10px;
  padding: 9px 11px;
  border: 1px solid transparent;
  border-radius: 6px;
  color: #b8c0be;
  background: transparent;
  font-size: 12px;
  font-weight: 620;
}

.ui-v3 .nav-item svg,
.ui-v3 .nav-card-button svg,
.ui-v3 .nav-more-toggle svg {
  width: 17px;
  height: 17px;
  color: #8e9996;
}

.ui-v3 .nav-item:hover,
.ui-v3 .nav-card-button:hover,
.ui-v3 .nav-more-toggle:hover {
  color: #fff;
  border-color: transparent;
  background: var(--v3-sidebar-hover);
}

.ui-v3 .nav-item.active,
.ui-v3 .nav-card-button.active {
  color: #fff;
  border-color: rgba(104, 204, 174, 0.15);
  background: var(--v3-sidebar-active);
  box-shadow: inset 3px 0 0 #45b798;
}

.ui-v3 .nav-item.active svg,
.ui-v3 .nav-card-button.active svg {
  color: #75d0b5;
}

.ui-v3 .nav-secondary {
  gap: 2px;
  padding-left: 8px;
}

.ui-v3 .nav-secondary .nav-item {
  min-height: 38px;
  font-size: 11px;
}

.ui-v3 .nav-card-state {
  min-height: 18px;
  margin-left: auto;
  padding: 1px 6px;
  border-radius: 4px;
  background: #65491f;
  color: #ffe1a0;
  font-size: 9px;
}

.ui-v3 .nav-card-state.ready {
  background: #205a4a;
  color: #c5eee0;
}

.ui-v3 .nav-account {
  grid-template-columns: 36px minmax(0, 1fr) 16px;
  min-height: 64px;
  margin-top: auto;
  padding: 12px 8px 2px;
  border: 0;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 0;
  background: transparent;
}

.ui-v3 .nav-account:hover,
.ui-v3 .nav-account.active {
  background: transparent;
}

.ui-v3 .nav-account-avatar {
  width: 34px;
  height: 34px;
  border-radius: 7px;
  color: #0b5d4d;
  background: #dff1eb;
}

.ui-v3 .nav-account-copy strong {
  color: #edf1ef;
  font-size: 11px;
}

.ui-v3 .nav-account-copy span {
  color: #8e9996;
  font-size: 9px;
}

.ui-v3 main {
  grid-column: 2;
  grid-row: 2;
  width: 100%;
  max-width: 1580px;
  min-width: 0;
  margin: 0 auto;
  padding: 24px 30px 40px;
  gap: 16px;
}

.ui-v3 main > .top,
.ui-v3 main > .bottom,
.ui-v3 main > .page-view,
.ui-v3 main .page-view > section {
  min-width: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.ui-v3 main > .bottom.page-split {
  display: block;
}

.ui-v3 .page-view > .head,
.ui-v3 [data-page="leads"] > section:not(.lead-detail-drawer) > .head {
  min-height: 0;
  justify-content: flex-end;
  padding: 0 0 12px;
  border: 0;
  background: transparent;
}

.ui-v3 .page-view > .head .page-title,
.ui-v3 [data-page="leads"] > section:not(.lead-detail-drawer) > .head .page-title {
  display: none;
}

.ui-v3 .page-view > .head:not(:has(button)):not(:has(.toolbar)),
.ui-v3 [data-page="leads"] > section:not(.lead-detail-drawer) > .head:not(:has(button)):not(:has(.toolbar)) {
  display: none;
}

/* The global header already owns refresh for these data pages. Removing the
   legacy one-button rows keeps the first useful content in the first viewport. */
.ui-v3 [data-page="acquisition"] > .head,
.ui-v3 [data-page="history"] > .head,
.ui-v3 [data-page="tasks"] > .head,
.ui-v3 [data-page="account"] > .head,
.ui-v3 [data-page="billing"] > .head {
  display: none;
}

.ui-v3 .page-view > .content,
.ui-v3 [data-page="leads"] > section > .content {
  min-width: 0;
  border: 1px solid var(--v3-line);
  border-radius: 8px;
  background: var(--v3-surface);
  box-shadow: 0 1px 2px rgba(23, 32, 29, 0.02);
}

.ui-v3 h2,
.ui-v3 h3,
.ui-v3 p {
  letter-spacing: 0;
}

.ui-v3 button,
.ui-v3 input,
.ui-v3 select,
.ui-v3 textarea {
  min-height: 40px;
  border-radius: 6px;
  border-color: var(--v3-line-strong);
  font-family: inherit;
  letter-spacing: 0;
}

.ui-v3 input,
.ui-v3 select,
.ui-v3 textarea {
  color: var(--v3-text);
  background: #fff;
}

.ui-v3 input::placeholder,
.ui-v3 textarea::placeholder {
  color: #9aa4a0;
}

.ui-v3 button {
  color: var(--v3-text-soft);
  border-color: var(--v3-line-strong);
  background: #fff;
  box-shadow: none;
  font-size: 12px;
  font-weight: 680;
}

.ui-v3 button:hover {
  border-color: #9facb1;
  background: var(--v3-surface-soft);
  transform: none;
}

.ui-v3 button.primary {
  color: #fff;
  border-color: var(--v3-teal);
  background: var(--v3-teal);
  box-shadow: none;
}

.ui-v3 button.primary:hover {
  border-color: var(--v3-teal-dark);
  background: var(--v3-teal-dark);
  box-shadow: 0 6px 16px rgba(8, 124, 103, 0.16);
}

.ui-v3 button.danger {
  color: var(--v3-red) !important;
  border-color: #edcbd0 !important;
  background: #fff !important;
}

.ui-v3 button.icon-button {
  width: 40px;
  min-width: 40px;
  padding: 0;
}

.ui-v3 label {
  color: var(--v3-text-soft);
  font-size: 11px;
  font-weight: 650;
}

.ui-v3 .badge,
.ui-v3 .history-status,
.ui-v3 .status-badge,
.ui-v3 .owner-chip,
.ui-v3 .channel-chip,
.ui-v3 .source-chip {
  border-radius: 4px;
}

.ui-v3 .empty-state,
.ui-v3 .history-empty {
  color: var(--v3-muted);
}

.ui-v3 .table-wrap {
  border-color: var(--v3-line);
  border-radius: 0;
  background: #fff;
  scrollbar-gutter: stable;
}

.ui-v3 table {
  color: var(--v3-text-soft);
  font-size: 11px;
}

.ui-v3 th {
  position: sticky;
  top: 0;
  z-index: 2;
  height: 42px;
  padding: 0 13px;
  border-bottom: 1px solid var(--v3-line-strong);
  color: #65716c;
  background: #f7f9fa;
  font-size: 10px;
  font-weight: 760;
  white-space: nowrap;
}

.ui-v3 td {
  padding: 11px 13px;
  border-bottom-color: #edf0f1;
}

.ui-v3 tbody tr:hover td {
  background: #f8faf9;
}

/* Home */
.ui-v3 [data-page="home"]:not(.hidden) {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(310px, 0.55fr);
  gap: 16px;
}

.ui-v3 [data-page="home"] > .head,
.ui-v3 [data-page="home"] > .home-identity-strip {
  grid-column: 1 / -1;
}

.ui-v3 [data-page="home"] > .home-actions {
  grid-column: 1;
  grid-row: 3;
}

.ui-v3 [data-page="home"] > .home-metrics {
  grid-column: 2;
  grid-row: 3;
}

.ui-v3 .home-identity-strip {
  min-height: 76px;
  padding: 15px 18px;
  border: 1px solid #d9e7e2;
  border-radius: 8px;
  background: #f4faf7;
}

.ui-v3 .home-identity-icon {
  width: 42px;
  height: 42px;
  border-radius: 7px;
  color: var(--v3-amber);
  background: var(--v3-amber-soft);
}

.ui-v3 .home-identity-strip.complete .home-identity-icon {
  color: var(--v3-teal);
  background: var(--v3-teal-soft);
}

.ui-v3 .home-identity-copy strong {
  color: var(--v3-text);
  font-size: 13px;
}

.ui-v3 .home-identity-copy span {
  color: var(--v3-muted);
  font-size: 10px;
}

.ui-v3 .home-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-content: stretch;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.ui-v3 .home-metrics .metric {
  min-height: 116px;
  padding: 17px;
  border: 0;
  border-right: 1px solid var(--v3-line);
  border-bottom: 1px solid var(--v3-line);
  border-radius: 0;
  background: #fff;
}

.ui-v3 .home-metrics .metric:nth-child(2n) {
  border-right: 0;
}

.ui-v3 .home-metrics .metric:nth-child(n + 3) {
  border-bottom: 0;
}

.ui-v3 .home-metrics .metric::after {
  display: none;
}

.ui-v3 .home-metrics .metric span,
.ui-v3 .home-metrics .metric small {
  display: block;
  color: var(--v3-muted);
  font-size: 10px;
}

.ui-v3 .home-metrics .metric strong {
  display: block;
  margin: 9px 0 3px;
  color: var(--v3-text);
  font-size: 28px;
  line-height: 1;
}

.ui-v3 .home-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.ui-v3 .home-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 15px 18px;
  border-bottom: 1px solid var(--v3-line);
}

.ui-v3 .home-section-heading span,
.ui-v3 .home-section-heading strong {
  display: block;
}

.ui-v3 .home-section-heading span {
  color: var(--v3-muted);
  font-size: 9px;
  font-weight: 720;
}

.ui-v3 .home-section-heading strong {
  margin-top: 2px;
  color: var(--v3-text);
  font-size: 15px;
}

.ui-v3 .home-section-heading > svg {
  width: 18px;
  height: 18px;
  color: var(--v3-teal);
}

.ui-v3 .home-actions .quick-card {
  display: grid;
  grid-template-columns: 42px minmax(150px, 0.7fr) minmax(190px, 1fr) 22px;
  gap: 13px;
  align-items: center;
  min-height: 80px;
  padding: 13px 18px !important;
  border: 0 !important;
  border-bottom: 1px solid var(--v3-line) !important;
  border-radius: 0 !important;
  background: #fff !important;
  text-align: left;
}

.ui-v3 .home-actions .quick-card:last-child {
  border-bottom: 0 !important;
}

.ui-v3 .home-actions .quick-card:hover {
  background: #f7faf9 !important;
  transform: none;
}

.ui-v3 .quick-index {
  display: grid !important;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 7px;
  color: var(--v3-teal) !important;
  background: var(--v3-teal-soft);
  font-size: 10px !important;
  font-weight: 800;
}

.ui-v3 .home-actions .quick-card strong {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--v3-text);
  font-size: 12px;
}

.ui-v3 .home-actions .quick-card strong svg {
  width: 16px;
  height: 16px;
  color: var(--v3-teal);
}

.ui-v3 .home-actions .quick-card > span:not(.quick-index) {
  color: var(--v3-muted);
  font-size: 10px;
}

.ui-v3 .quick-arrow {
  width: 16px;
  height: 16px;
  color: #8f9995;
}

/* Lead library */
.ui-v3 [data-page="leads"] > section > .content {
  padding: 0;
  overflow: hidden;
}

.ui-v3 .lead-workbench {
  padding: 0;
  border: 0;
  background: #fff;
}

.ui-v3 .lead-stages {
  display: grid;
  grid-template-columns: repeat(6, minmax(104px, 1fr));
  gap: 0;
  border-bottom: 1px solid var(--v3-line);
  background: #f8f9fa;
}

.ui-v3 .lead-stage {
  min-height: 60px;
  padding: 9px 12px;
  border: 0 !important;
  border-right: 1px solid var(--v3-line) !important;
  border-radius: 0 !important;
  background: transparent !important;
}

.ui-v3 .lead-stage:last-child {
  border-right: 0 !important;
}

.ui-v3 .lead-stage strong {
  color: var(--v3-text);
  font-size: 18px;
}

.ui-v3 .lead-stage span {
  color: var(--v3-muted);
  font-size: 9px;
}

.ui-v3 .lead-stage.active {
  color: var(--v3-teal);
  background: #fff !important;
  box-shadow: inset 0 -3px 0 var(--v3-teal);
}

.ui-v3 .lead-tools {
  grid-template-columns: minmax(280px, 1fr) auto auto auto;
  gap: 8px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--v3-line);
}

.ui-v3 .lead-tools .search-input input {
  background: var(--v3-surface-soft);
}

.ui-v3 .lead-advanced-filters {
  padding: 10px 14px 13px;
  border-bottom: 1px solid var(--v3-line);
  background: #fafbfb;
}

.ui-v3 .selection-bar {
  margin: 0;
  padding: 10px 14px;
  border: 0;
  border-bottom: 1px solid #bddbd1;
  border-radius: 0;
  background: #edf7f3;
}

.ui-v3 [data-page="leads"] .table-wrap {
  max-height: calc(100dvh - 338px);
  min-height: 380px;
  overflow: auto;
  border: 0;
}

.ui-v3 #leadTable {
  min-width: 900px;
  table-layout: fixed;
}

.ui-v3 #leadTable th:nth-child(1) { width: 42px; }
.ui-v3 #leadTable th:nth-child(2) { width: 31%; }
.ui-v3 #leadTable th:nth-child(3) { width: 23%; }
.ui-v3 #leadTable th:nth-child(4) { width: 21%; }
.ui-v3 #leadTable th:nth-child(5) { width: 25%; }

.ui-v3 #leadTable .lead-row {
  height: 76px;
}

.ui-v3 #leadTable .lead-row.selected td {
  background: #edf7f3;
}

.ui-v3 #leadTable .lead-row.selected td:first-child {
  box-shadow: inset 3px 0 0 var(--v3-teal);
}

.ui-v3 .company-avatar {
  width: 36px;
  height: 36px;
  border-radius: 7px;
  color: #235a80;
  background: var(--v3-blue-soft);
}

.ui-v3 .lead-cell-main {
  color: var(--v3-text);
  font-size: 11px;
}

.ui-v3 .lead-cell-sub {
  max-width: 100%;
  overflow: hidden;
  color: var(--v3-muted);
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ui-v3 .lead-pagination {
  min-height: 52px;
  padding: 8px 14px;
  border-top: 1px solid var(--v3-line);
  background: #fafbfb;
}

.ui-v3 .lead-detail-drawer {
  top: 12px;
  right: 12px;
  bottom: 12px;
  width: min(620px, calc(100vw - 28px));
  border: 1px solid var(--v3-line-strong);
  border-radius: 8px;
  background: #fff;
  box-shadow: -18px 0 54px rgba(20, 30, 27, 0.18);
}

.ui-v3 .lead-detail-drawer > .head {
  padding: 14px 16px;
  border-bottom: 1px solid var(--v3-line);
  background: #fff;
}

.ui-v3 .lead-detail-drawer > .head .page-title {
  display: block;
}

.ui-v3 .lead-detail-drawer > .content {
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

/* Search and acquisition */
.ui-v3 [data-page="search"] > .content,
.ui-v3 [data-page="acquisition"] > .content {
  padding: 0;
  overflow: hidden;
}

.ui-v3 .search-workspace,
.ui-v3 .acquisition-workspace {
  grid-template-columns: 390px minmax(0, 1fr);
  min-height: 560px;
  border: 0;
  border-radius: 0;
}

.ui-v3 .search-builder,
.ui-v3 .acquisition-builder {
  padding: 18px 20px;
  border-right: 1px solid var(--v3-line);
  background: #fafbfb;
}

.ui-v3 .search-builder-head,
.ui-v3 .search-output-head,
.ui-v3 .acquisition-output-head {
  padding-bottom: 13px;
}

.ui-v3 .search-builder-head h3,
.ui-v3 .search-output-head h3,
.ui-v3 .recent-search-head h3,
.ui-v3 .acquisition-builder h3,
.ui-v3 .acquisition-output h3 {
  color: var(--v3-text);
  font-size: 14px;
}

.ui-v3 .search-form-section {
  padding: 12px 0;
  border-bottom-color: var(--v3-line);
}

.ui-v3 .search-section-title span {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  color: var(--v3-teal);
  background: var(--v3-teal-soft);
}

.ui-v3 .search-quota,
.ui-v3 .source-pill {
  border-radius: 4px;
}

.ui-v3 .market-preview {
  padding: 8px 10px;
  border-color: #cfe3dc;
  border-radius: 6px;
  color: #315c50;
  background: #f1f8f5;
}

.ui-v3 .search-submit {
  min-height: 46px;
  margin-top: 12px;
}

.ui-v3 .search-builder .quality-rules {
  gap: 5px;
}

.ui-v3 .search-builder .search-form-section:has(.quality-rules) {
  display: none;
}

.ui-v3 .search-builder .quality-rule {
  gap: 7px;
  font-size: 10px;
}

.ui-v3 .search-builder .quality-rule svg {
  width: 14px;
  height: 14px;
}

.ui-v3 .search-output {
  background: #fff;
}

.ui-v3 .search-output-head {
  padding: 20px 22px;
}

.ui-v3 .search-progress {
  padding: 14px 22px;
  background: #f8f9fa;
}

.ui-v3 .progress-step span {
  border-radius: 5px;
}

.ui-v3 .search-results {
  padding: 22px;
}

.ui-v3 .search-empty {
  min-height: 350px;
}

.ui-v3 .recent-searches {
  margin: 0;
  border: 0;
  border-top: 1px solid var(--v3-line);
  border-radius: 0;
}

.ui-v3 .recent-search-head {
  min-height: 66px;
  padding: 14px 18px;
}

.ui-v3 .recent-search-row {
  min-height: 52px;
}

.ui-v3 .acquisition-channels {
  overflow: hidden;
  border: 1px solid var(--v3-line);
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
}

.ui-v3 .acquisition-channel {
  min-height: 72px;
}

/* Communication */
.ui-v3 [data-page="email"] {
  border: 1px solid var(--v3-line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.ui-v3 [data-page="email"] > .content {
  padding: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.ui-v3 .module-tabs {
  min-height: 56px;
  gap: 26px;
  padding: 0 18px;
  border-bottom: 1px solid var(--v3-line);
}

.ui-v3 .module-tab {
  min-height: 56px;
  color: var(--v3-muted) !important;
  font-size: 11px;
}

.ui-v3 .module-tab.active {
  color: var(--v3-text) !important;
  border-bottom-color: var(--v3-teal) !important;
}

.ui-v3 .channel-head-status {
  color: var(--v3-muted);
  font-size: 9px;
}

.ui-v3 .comms-workspace {
  grid-template-columns: 330px minmax(0, 1fr);
  height: calc(100dvh - 185px);
  min-height: 590px;
  max-height: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.ui-v3 .comms-inbox {
  border-right-color: var(--v3-line);
  background: #fbfcfc;
}

.ui-v3 .comms-inbox-head {
  min-height: 70px;
  padding: 14px 15px 11px;
}

.ui-v3 .comms-inbox-tools {
  padding: 0 13px 11px;
}

.ui-v3 .comms-inbox-tools .conversation-search input {
  background: #f5f7f7;
}

.ui-v3 .comms-inbox-tools .conversation-filters {
  border-radius: 6px;
}

.ui-v3 .comms-inbox .mail-item {
  min-height: 82px;
  padding: 13px;
}

.ui-v3 .comms-inbox .mail-item.active {
  background: #eaf6f1;
  box-shadow: inset 3px 0 0 var(--v3-teal);
}

.ui-v3 .comms-workspace .mail-reader,
.ui-v3 .comms-workspace .mail-reader-content {
  background: #f3f5f5;
}

.ui-v3 .comms-workspace .conversation-header {
  min-height: 70px;
  padding: 10px 17px;
}

.ui-v3 .comms-workspace .message-card {
  max-width: min(74%, 720px);
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(23, 32, 29, 0.04);
}

.ui-v3 .comms-workspace .chat-message-row.outbound .message-card {
  border-color: #c5ded5;
  background: #e6f3ee;
}

.ui-v3 .comms-workspace .mail-compose-reply {
  padding: 11px 17px 13px;
}

.ui-v3 .comms-workspace .chat-compose-box {
  border-radius: 7px;
  background: #fff;
}

.ui-v3 .comms-context {
  width: 310px;
  box-shadow: -14px 0 36px rgba(23, 32, 29, 0.12);
}

/* Team, reports, account, billing */
.ui-v3 [data-page="team"] > .content,
.ui-v3 [data-page="account"] > .content,
.ui-v3 [data-page="billing"] > .content,
.ui-v3 [data-page="history"] > .content,
.ui-v3 [data-page="tasks"] > .content,
.ui-v3 [data-page="reports"] > .content,
.ui-v3 [data-page="admin"] > .content {
  padding: 18px;
}

.ui-v3 .team-identity,
.ui-v3 .account-identity {
  border-radius: 7px;
  background: #f7f9f8;
}

.ui-v3 .team-identity-icon,
.ui-v3 .account-avatar {
  border-radius: 7px;
  color: var(--v3-teal);
  background: var(--v3-teal-soft);
}

.ui-v3 .team-summary,
.ui-v3 .account-metrics,
.ui-v3 .history-overview {
  border: 1px solid var(--v3-line);
  border-radius: 7px;
  background: #fff;
  overflow: hidden;
}

.ui-v3 .team-stat,
.ui-v3 .account-metric,
.ui-v3 .history-stat {
  border-radius: 0;
  background: #fff;
}

.ui-v3 .team-panel,
.ui-v3 .account-panel,
.ui-v3 .field-group {
  border-color: var(--v3-line);
  border-radius: 7px;
  box-shadow: none;
}

.ui-v3 .team-panel-head,
.ui-v3 .account-panel-head {
  min-height: 58px;
  padding: 14px 16px;
}

.ui-v3 .team-panel-head h3,
.ui-v3 .account-panel-head h3 {
  color: var(--v3-text);
  font-size: 13px;
}

.ui-v3 .team-panel-head span,
.ui-v3 .account-panel-head p {
  color: var(--v3-muted);
  font-size: 9px;
}

.ui-v3 .team-leader-tools {
  border-radius: 7px;
}

.ui-v3 .billing-plans {
  border-color: var(--v3-line);
  border-radius: 7px;
}

.ui-v3 .billing-plan {
  position: relative;
  min-height: 260px;
  padding: 20px;
  border-color: var(--v3-line);
}

.ui-v3 .billing-plan:nth-child(2) {
  background: #f5faf8;
  box-shadow: inset 0 3px 0 var(--v3-teal);
}

.ui-v3 .billing-plan-price {
  color: var(--v3-text);
  font-size: 26px;
}

.ui-v3 .account-row {
  min-height: 46px;
}

.ui-v3 .account-actions button {
  justify-content: flex-start;
}

.ui-v3 .readiness-check {
  border-radius: 6px;
}

/* Authentication and overlays */
.ui-v3 .login-screen {
  height: 100dvh;
  min-height: 100dvh;
  overflow: hidden;
  padding: 0;
  background: #13231f;
}

.ui-v3 .auth-shell {
  width: 100%;
  max-width: none;
  height: 100dvh;
  min-height: 100dvh;
  grid-template-columns: minmax(560px, 1.15fr) minmax(500px, 0.85fr);
  overflow: hidden;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.ui-v3 .auth-aside {
  height: 100dvh;
  min-height: 0;
  padding: 32px 36px 28px;
  background-color: #13231f;
}

.ui-v3 .auth-aside::before {
  background-position: 46% bottom;
  transform: none;
}

.ui-v3 .auth-aside::after {
  background: rgba(7, 22, 20, 0.58);
}

.ui-v3 .auth-aside-brand {
  gap: 12px;
}

.ui-v3 .auth-aside .brand-mark {
  width: 48px;
  height: 48px;
}

.ui-v3 .auth-brand-copy strong {
  font-size: 19px;
  letter-spacing: 0;
}

.ui-v3 .auth-brand-copy span {
  margin-top: 5px;
  color: #d1dcda;
  font-size: 11px;
}

.ui-v3 .auth-aside-copy {
  max-width: 470px;
  margin-top: 48px;
  text-shadow: none;
}

.ui-v3 .auth-aside-kicker {
  margin-bottom: 14px;
  color: #83dbc0;
  letter-spacing: 0;
}

.ui-v3 .auth-aside-copy h1 {
  max-width: 450px;
  font-size: 38px;
  line-height: 1.25;
  letter-spacing: 0;
}

.ui-v3 .auth-aside-copy p {
  max-width: 430px;
  margin-top: 14px;
  color: #d6e0dd;
  font-size: 13px;
  line-height: 1.75;
}

.ui-v3 .auth-hero-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 20px;
}

.ui-v3 .auth-start-free {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 14px;
  border-color: #70d2b3;
  border-radius: 6px;
  color: #103b30;
  background: #82dfc1;
  box-shadow: 0 10px 24px rgba(5, 20, 17, 0.2);
}

.ui-v3 .auth-start-free:hover {
  border-color: #9ae8cf;
  color: #0b2f27;
  background: #9ae8cf;
}

.ui-v3 .auth-start-free svg {
  width: 16px;
  height: 16px;
}

.ui-v3 .auth-hero-actions > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #d2dfdb;
  font-size: 10px;
  white-space: nowrap;
}

.ui-v3 .auth-hero-actions > span svg {
  width: 14px;
  height: 14px;
  color: #71d5b5;
}

.ui-v3 .auth-ops-board {
  margin-top: 28px;
  overflow: hidden;
  border: 1px solid rgba(218, 236, 230, 0.24);
  border-radius: 8px;
  background: rgba(9, 28, 25, 0.78);
  box-shadow: 0 18px 44px rgba(4, 14, 13, 0.24);
  backdrop-filter: blur(10px);
}

.ui-v3 .auth-ops-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 15px 17px;
  border-bottom: 1px solid rgba(218, 236, 230, 0.16);
}

.ui-v3 .auth-ops-head > div {
  display: grid;
  gap: 3px;
}

.ui-v3 .auth-ops-eyebrow {
  color: #9fb3ad;
  font-size: 9px;
}

.ui-v3 .auth-ops-head strong {
  color: #fff;
  font-size: 13px;
}

.ui-v3 .auth-live-state {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #cae4dc;
  font-size: 10px;
  white-space: nowrap;
}

.ui-v3 .auth-live-state i,
.ui-v3 .auth-secure-state i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #45c59c;
  box-shadow: 0 0 0 4px rgba(69, 197, 156, 0.12);
}

.ui-v3 .auth-ops-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 17px;
}

.ui-v3 .auth-ops-step {
  position: relative;
  min-width: 0;
  display: grid;
  justify-items: start;
  gap: 5px;
  padding-right: 14px;
}

.ui-v3 .auth-ops-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 17px;
  right: 10px;
  width: calc(100% - 48px);
  height: 1px;
  background: rgba(203, 225, 218, 0.25);
  transform: translateX(50%);
}

.ui-v3 .auth-ops-step > span {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(208, 228, 221, 0.25);
  border-radius: 7px;
  color: #c8d8d3;
  background: #18342e;
}

.ui-v3 .auth-ops-step.active > span {
  border-color: rgba(98, 214, 177, 0.42);
  color: #7ee0c1;
  background: #17483b;
}

.ui-v3 .auth-ops-step svg {
  width: 16px;
  height: 16px;
}

.ui-v3 .auth-ops-step strong {
  margin-top: 4px;
  overflow: hidden;
  color: #f2f7f5;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ui-v3 .auth-ops-step small {
  overflow: hidden;
  color: #9fb2ac;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ui-v3 .auth-ops-signals {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 17px;
  border-top: 1px solid rgba(218, 236, 230, 0.16);
  color: #b9cbc5;
  font-size: 9px;
}

.ui-v3 .auth-ops-signals span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.ui-v3 .auth-ops-signals strong {
  color: #eff8f5;
  font-size: 10px;
}

.ui-v3 .auth-ops-signals svg {
  width: 13px;
  height: 13px;
  color: #65cdae;
}

.ui-v3 .auth-aside-foot {
  color: #c2d0cc;
  letter-spacing: 0;
}

.ui-v3 .auth-trade-route {
  letter-spacing: 0;
}

.ui-v3 .login-box {
  height: 100dvh;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  padding: 42px 62px;
  background: #fff;
}

.ui-v3 .auth-card {
  width: min(430px, 100%);
  max-width: 430px;
  grid-column: auto;
  grid-row: auto;
  display: block;
  align-content: initial;
  padding: 0;
  gap: 0;
}

.ui-v3 .auth-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  color: #64716c;
  font-size: 10px;
}

.ui-v3 .auth-card-meta > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.ui-v3 .auth-card-meta svg {
  width: 14px;
  height: 14px;
  color: var(--v3-teal);
}

.ui-v3 .auth-secure-state {
  color: #3d685b;
}

.ui-v3 .auth-tabs {
  gap: 4px;
  margin-bottom: 28px;
  padding: 4px;
  border: 1px solid var(--v3-line);
  border-radius: 7px;
  background: #f2f5f4;
}

.ui-v3 .auth-tabs .auth-tab {
  min-height: 40px !important;
  border: 0 !important;
  border-radius: 5px !important;
  background: transparent !important;
  color: #6b7772 !important;
  box-shadow: none;
}

.ui-v3 .auth-tabs .auth-tab:hover {
  background: #e9eeec !important;
  color: var(--v3-text) !important;
}

.ui-v3 .auth-tabs .auth-tab.active {
  background: #fff !important;
  color: var(--v3-teal) !important;
  box-shadow: 0 1px 4px rgba(24, 43, 37, 0.1);
}

.ui-v3 .auth-heading {
  margin-bottom: 24px;
}

.ui-v3 .auth-heading > span {
  display: block;
  margin-bottom: 6px;
  color: var(--v3-teal);
  font-size: 10px;
  font-weight: 750;
}

.ui-v3 .auth-heading h2 {
  color: #17201d;
  font-size: 28px;
  line-height: 1.25;
  letter-spacing: 0;
}

.ui-v3 .auth-heading p {
  margin-top: 8px;
  color: #74807b;
  font-size: 12px;
}

.ui-v3 .auth-pane {
  gap: 14px;
}

.ui-v3 .auth-field {
  gap: 7px;
  color: #3e4a46;
  font-size: 11px;
  font-weight: 680;
}

.ui-v3 .auth-input-shell {
  position: relative;
  display: flex;
  align-items: center;
}

.ui-v3 .auth-input-shell > svg {
  position: absolute;
  left: 14px;
  z-index: 1;
  width: 16px;
  height: 16px;
  color: #87938e;
  pointer-events: none;
}

.ui-v3 .auth-input-shell:focus-within > svg {
  color: var(--v3-teal);
}

.ui-v3 .auth-field input {
  min-height: 48px;
  border-color: #cfd8d4;
  border-radius: 6px;
  background: #fbfcfc;
}

.ui-v3 .auth-input-shell > input {
  padding-left: 42px;
}

.ui-v3 .auth-input-shell.password-control > input {
  padding-right: 46px;
}

.ui-v3 .auth-field input:focus {
  background: #fff;
}

.ui-v3 .auth-secondary-row {
  min-height: 22px;
  margin-top: -4px;
}

.ui-v3 .auth-primary {
  min-height: 48px;
  justify-content: space-between;
  padding-right: 17px;
  padding-left: 17px;
  border-radius: 6px;
  box-shadow: 0 10px 22px rgba(13, 128, 103, 0.16);
}

.ui-v3 .auth-primary svg {
  width: 17px;
  height: 17px;
}

.ui-v3 .auth-status {
  min-height: 36px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid #e1e7e4;
  border-radius: 6px;
  color: #6e7a75;
  background: #f8faf9;
  font-size: 10px;
}

.ui-v3 .auth-status:empty {
  display: none;
}

.ui-v3 .auth-status svg {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}

.ui-v3 .auth-status[data-tone="error"] {
  border-color: #efcfd3;
  background: #fff7f8;
}

.ui-v3 .auth-status[data-tone="success"] {
  border-color: #cae3d9;
  background: #f3faf7;
}

.ui-v3 .auth-register-offer {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr);
  gap: 11px;
  align-items: center;
  padding: 11px 12px;
  border: 1px solid #cfe2da;
  border-radius: 6px;
  color: #315348;
  background: #f2f8f5;
}

.ui-v3 .auth-register-offer > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 6px;
  color: var(--v3-teal);
  background: #dcefe7;
}

.ui-v3 .auth-register-offer svg {
  width: 16px;
  height: 16px;
}

.ui-v3 .auth-register-offer strong {
  display: block;
  font-size: 11px;
}

.ui-v3 .auth-register-offer p {
  margin: 3px 0 0;
  color: #6b7a74;
  font-size: 9px;
  line-height: 1.45;
}

.ui-v3 .auth-security-note {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 20px;
  color: #7f8a86;
  font-size: 9px;
}

.ui-v3 .auth-security-note > span {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  white-space: nowrap;
}

.ui-v3 .auth-security-note svg {
  width: 12px;
  height: 12px;
  color: #5f8b7c;
}

.ui-v3 .modal-layer {
  background: rgba(20, 27, 25, 0.54);
  backdrop-filter: blur(2px);
}

.ui-v3 .modal-dialog {
  border: 1px solid var(--v3-line-strong);
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(20, 29, 26, 0.22);
}

.ui-v3 .modal-head,
.ui-v3 .modal-foot {
  background: #fff;
}

.ui-v3 .modal-body {
  background: #fbfcfc;
}

.ui-v3 .onboarding-step {
  background: #fff;
}

/* Responsive */
@media (min-width: 1680px) {
  .ui-v3 #appShell {
    grid-template-columns: 248px minmax(0, 1fr);
  }

  .ui-v3 .app-nav {
    width: 248px;
  }

  .ui-v3 main {
    padding-right: 36px;
    padding-left: 36px;
  }

  .ui-v3 .search-workspace,
  .ui-v3 .acquisition-workspace {
    grid-template-columns: 420px minmax(0, 1fr);
  }

  .ui-v3 .comms-workspace {
    grid-template-columns: 350px minmax(0, 1fr);
  }
}

@media (max-width: 1240px) {
  .ui-v3 #appShell {
    grid-template-columns: 212px minmax(0, 1fr);
  }

  .ui-v3 .app-nav {
    width: 212px;
  }

  .ui-v3 main,
  .ui-v3 header {
    padding-right: 22px;
    padding-left: 22px;
  }

  .ui-v3 [data-page="home"]:not(.hidden) {
    grid-template-columns: minmax(0, 1.25fr) minmax(290px, 0.75fr);
  }

  .ui-v3 .home-actions .quick-card {
    grid-template-columns: 40px minmax(140px, 0.8fr) minmax(150px, 1fr) 18px;
  }

  .ui-v3 .search-workspace,
  .ui-v3 .acquisition-workspace {
    grid-template-columns: 360px minmax(0, 1fr);
  }

  .ui-v3 .comms-workspace {
    grid-template-columns: 300px minmax(0, 1fr);
  }
}

@media (max-width: 1060px) {
  .ui-v3 [data-page="home"]:not(.hidden) {
    grid-template-columns: 1fr;
  }

  .ui-v3 [data-page="home"] > .home-actions,
  .ui-v3 [data-page="home"] > .home-metrics {
    grid-column: 1;
    grid-row: auto;
  }

  .ui-v3 .search-workspace,
  .ui-v3 .acquisition-workspace,
  .ui-v3 .billing-grid,
  .ui-v3 .account-grid {
    grid-template-columns: 1fr;
  }

  .ui-v3 .search-builder,
  .ui-v3 .acquisition-builder {
    border-right: 0;
    border-bottom: 1px solid var(--v3-line);
  }
}

@media (max-width: 920px) {
  .ui-v3 #appShell {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 64px auto minmax(0, 1fr);
  }

  .ui-v3 header {
    grid-column: 1;
    grid-row: 1;
    min-height: 64px;
    padding: 0 16px;
  }

  .ui-v3 .app-nav {
    grid-column: 1;
    grid-row: 2;
    top: 64px;
    width: 100%;
    height: auto;
    padding: 7px 10px;
  }

  .ui-v3 main {
    grid-column: 1;
    grid-row: 3;
    padding: 16px;
  }

  .ui-v3 .nav-item,
  .ui-v3 .nav-card-button,
  .ui-v3 .nav-more-toggle {
    width: auto;
  }

  .ui-v3 .lead-stages {
    grid-template-columns: repeat(6, 104px);
    overflow-x: auto;
  }

  .ui-v3 .comms-workspace {
    height: calc(100dvh - 190px);
  }
}

@media (max-width: 680px) {
  .ui-v3 header h1 {
    font-size: 16px;
  }

  .ui-v3 main {
    padding: 12px;
  }

  .ui-v3 .home-identity-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .ui-v3 .home-identity-strip button {
    width: 100%;
  }

  .ui-v3 .home-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .ui-v3 .home-actions .quick-card {
    grid-template-columns: 38px minmax(0, 1fr) 18px;
    min-height: 74px;
  }

  .ui-v3 .home-actions .quick-card > span:not(.quick-index) {
    display: none;
  }

  .ui-v3 .lead-tools {
    grid-template-columns: 1fr auto auto;
  }

  .ui-v3 .lead-tools .search-input {
    grid-column: 1 / -1;
  }

  .ui-v3 [data-page="leads"] .table-wrap {
    max-height: calc(100dvh - 390px);
  }

  .ui-v3 .lead-detail-drawer {
    inset: 0;
    width: 100%;
    border: 0;
    border-radius: 0;
  }

  .ui-v3 .search-builder,
  .ui-v3 .search-output-head,
  .ui-v3 .search-results,
  .ui-v3 .acquisition-builder {
    padding-right: 14px;
    padding-left: 14px;
  }

  .ui-v3 .module-tabs {
    gap: 15px;
    padding: 0 10px;
    overflow-x: auto;
  }

  .ui-v3 .module-tab {
    flex: 0 0 auto;
    font-size: 10px;
  }

  .ui-v3 .comms-module-tabs .channel-head-actions {
    position: sticky;
    right: 0;
    flex: 0 0 auto;
    margin-left: auto;
    padding-left: 4px;
    background: #fff;
  }

  .ui-v3 .comms-module-tabs .channel-head-actions button {
    width: 38px;
    min-width: 38px;
    padding: 0;
    font-size: 0;
  }

  .ui-v3 .comms-module-tabs .channel-head-actions button svg {
    width: 17px;
    height: 17px;
  }

  .ui-v3 .comms-workspace {
    min-height: 500px;
    height: calc(100dvh - 205px);
  }

  .ui-v3 .comms-workspace .message-card {
    max-width: 88%;
  }

  .ui-v3 [data-page="team"] > .content,
  .ui-v3 [data-page="account"] > .content,
  .ui-v3 [data-page="billing"] > .content,
  .ui-v3 [data-page="history"] > .content,
  .ui-v3 [data-page="tasks"] > .content,
  .ui-v3 [data-page="reports"] > .content,
  .ui-v3 [data-page="admin"] > .content {
    padding: 13px;
  }

  .ui-v3 .billing-plan {
    min-height: 0;
  }
}

@media (max-width: 1100px) and (min-width: 841px) {
  .ui-v3 .login-screen {
    padding: 0;
  }

  .ui-v3 .auth-shell {
    height: 100dvh;
    min-height: 100dvh;
    grid-template-columns: minmax(350px, 43%) minmax(0, 1fr);
  }

  .ui-v3 .auth-aside {
    padding: 28px;
  }

  .ui-v3 .auth-aside-copy {
    margin-top: 40px;
  }

  .ui-v3 .auth-aside-copy h1 {
    font-size: 32px;
  }

  .ui-v3 .auth-ops-board {
    margin-top: 22px;
  }

  .ui-v3 .auth-ops-signals {
    gap: 8px;
    padding-right: 13px;
    padding-left: 13px;
  }

  .ui-v3 .login-box {
    padding: 34px 38px;
  }
}

@media (max-height: 760px) and (min-width: 841px) {
  .ui-v3 .login-screen {
    padding: 0;
  }

  .ui-v3 .auth-shell {
    height: 100dvh;
    min-height: 100dvh;
  }

  .ui-v3 .auth-aside {
    padding-top: 24px;
    padding-bottom: 22px;
  }

  .ui-v3 .auth-aside-copy {
    margin-top: 26px;
  }

  .ui-v3 .auth-aside-copy h1 {
    font-size: 32px;
  }

  .ui-v3 .auth-aside-copy p {
    margin-top: 9px;
  }

  .ui-v3 .auth-hero-actions {
    margin-top: 13px;
  }

  .ui-v3 .auth-start-free {
    min-height: 38px;
  }

  .ui-v3 .auth-ops-board {
    margin-top: 18px;
  }

  .ui-v3 .auth-ops-head {
    padding-top: 11px;
    padding-bottom: 11px;
  }

  .ui-v3 .auth-ops-flow {
    padding-top: 13px;
    padding-bottom: 13px;
  }

  .ui-v3 .auth-ops-signals {
    padding-top: 9px;
    padding-bottom: 9px;
  }

  .ui-v3 .auth-aside-foot {
    gap: 5px;
  }

  .ui-v3 .login-box {
    padding-top: 28px;
    padding-bottom: 28px;
  }

  .ui-v3 .auth-card-meta {
    margin-bottom: 17px;
  }

  .ui-v3 .auth-tabs {
    margin-bottom: 20px;
  }

  .ui-v3 .auth-heading {
    margin-bottom: 18px;
  }

  .ui-v3 .auth-security-note {
    margin-top: 14px;
  }
}

@media (max-width: 840px) {
  .ui-v3 .login-screen {
    padding: 0;
    background: #fff;
  }

  .ui-v3 .auth-shell {
    height: 100dvh;
    min-height: 100dvh;
    grid-template-columns: 1fr;
    grid-template-rows: 92px minmax(0, 1fr);
    overflow: hidden;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .ui-v3 .auth-aside {
    height: 92px;
    min-height: 92px;
    padding: 18px 20px;
  }

  .ui-v3 .auth-aside::before {
    display: block;
    background-position: center 62%;
  }

  .ui-v3 .auth-aside::after {
    display: block;
    background: rgba(8, 25, 22, 0.72);
  }

  .ui-v3 .auth-aside .brand-mark {
    width: 40px;
    height: 40px;
  }

  .ui-v3 .auth-brand-copy strong {
    font-size: 17px;
  }

  .ui-v3 .auth-aside-copy,
  .ui-v3 .auth-ops-board,
  .ui-v3 .auth-aside-foot {
    display: none;
  }

  .ui-v3 .login-box {
    height: calc(100dvh - 92px);
    min-height: 0;
    overflow-y: auto;
    align-items: flex-start;
    padding: 30px 20px 40px;
  }

  .ui-v3 .auth-card {
    margin: 0 auto;
  }

  .ui-v3 .auth-card-meta {
    margin-bottom: 18px;
  }

  .ui-v3 .auth-tabs {
    margin-bottom: 24px;
  }

  .ui-v3 .auth-heading h2 {
    font-size: 25px;
  }
}

@media (max-width: 480px) {
  .ui-v3 .auth-security-note {
    gap: 5px;
    font-size: 8px;
  }

  .ui-v3 .auth-card-meta {
    font-size: 9px;
  }
}

/* Authentication V4: full-bleed editorial visual + independent account panel */
.ui-v3 .auth-shell {
  grid-template-columns: minmax(620px, 58%) minmax(480px, 42%);
}

.ui-v3 .auth-visual {
  position: relative;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
  padding: 0;
  background: #111a18;
}

.ui-v3 .auth-visual::before,
.ui-v3 .auth-visual::after {
  display: none;
}

.ui-v3 .auth-visual-image,
.ui-v3 .auth-visual-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.ui-v3 .auth-visual-image {
  display: block;
  object-fit: cover;
  object-position: 58% center;
}

.ui-v3 .auth-visual-shade {
  background: rgba(5, 17, 15, 0.38);
}

.ui-v3 .auth-visual-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  padding: 28px 36px 24px;
  color: #fff;
}

.ui-v3 .auth-visual .auth-aside-brand {
  gap: 12px;
}

.ui-v3 .auth-visual .auth-aside-brand .brand-mark {
  width: 46px;
  height: 46px;
}

.ui-v3 .auth-visual-message {
  width: min(520px, 100%);
  align-self: center;
}

.ui-v3 .auth-visual-message .auth-aside-kicker {
  margin-bottom: 13px;
  color: #8ad9bf;
  font-size: 9px;
  letter-spacing: 0;
}

.ui-v3 .auth-visual-message h1 {
  max-width: 500px;
  margin: 0;
  color: #fff;
  font-size: 38px;
  line-height: 1.24;
  letter-spacing: 0;
}

.ui-v3 .auth-visual-message > p {
  max-width: 500px;
  margin: 14px 0 0;
  color: #d6e0dc;
  font-size: 13px;
  line-height: 1.75;
}

.ui-v3 .auth-capability-list {
  width: min(520px, 100%);
  margin-top: 25px;
  border-top: 1px solid rgba(225, 238, 234, 0.24);
  border-bottom: 1px solid rgba(225, 238, 234, 0.24);
}

.ui-v3 .auth-capability-list > div {
  min-height: 50px;
  display: grid;
  grid-template-columns: 28px 22px minmax(0, 1fr) auto;
  gap: 9px;
  align-items: center;
  border-bottom: 1px solid rgba(225, 238, 234, 0.16);
}

.ui-v3 .auth-capability-list > div:last-child {
  border-bottom: 0;
}

.ui-v3 .auth-capability-list span {
  color: #7bd0b5;
  font-size: 9px;
  font-weight: 800;
}

.ui-v3 .auth-capability-list svg {
  width: 15px;
  height: 15px;
  color: #d8e7e2;
}

.ui-v3 .auth-capability-list strong {
  overflow: hidden;
  color: #fff;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ui-v3 .auth-capability-list small {
  color: #bacac5;
  font-size: 9px;
  white-space: nowrap;
}

.ui-v3 .auth-commercial-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 18px;
  align-items: center;
  padding-top: 17px;
  border-top: 1px solid rgba(225, 238, 234, 0.28);
}

.ui-v3 .auth-commercial-strip > div {
  min-width: 0;
}

.ui-v3 .auth-commercial-strip strong,
.ui-v3 .auth-commercial-strip span {
  display: block;
}

.ui-v3 .auth-commercial-strip strong {
  color: #fff;
  font-size: 18px;
  line-height: 1;
}

.ui-v3 .auth-commercial-strip > div span {
  margin-top: 5px;
  color: #bbcbc6;
  font-size: 9px;
  white-space: nowrap;
}

.ui-v3 .auth-commercial-strip button {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 0 13px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 6px;
  color: #17251f;
  background: #fff;
  box-shadow: 0 10px 24px rgba(5, 16, 14, 0.18);
}

.ui-v3 .auth-commercial-strip button:hover {
  border-color: #fff;
  color: #0c5e4b;
  background: #f2f7f5;
}

.ui-v3 .auth-commercial-strip button span {
  color: inherit;
  font-size: 11px;
  font-weight: 750;
}

.ui-v3 .auth-commercial-strip button svg {
  width: 15px;
  height: 15px;
}

.ui-v3 .login-box {
  height: 100dvh;
  min-height: 0;
  display: grid;
  grid-template-rows: 64px minmax(0, 1fr) 52px;
  align-items: stretch;
  overflow: hidden;
  padding: 0;
  background: #fff;
}

.ui-v3 .auth-panel-header,
.ui-v3 .auth-panel-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 38px;
  color: #69756f;
  background: #fff;
}

.ui-v3 .auth-panel-header {
  border-bottom: 1px solid #e2e7e5;
  font-size: 10px;
}

.ui-v3 .auth-panel-header > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.ui-v3 .auth-panel-header svg {
  width: 14px;
  height: 14px;
  color: var(--v3-teal);
}

.ui-v3 .auth-card {
  width: 100%;
  max-width: none;
  height: 100%;
  min-height: 0;
  display: flex;
  align-items: center;
  overflow-y: auto;
  padding: 32px 42px;
}

.ui-v3 .auth-card:has(#authRegisterPane:not(.hidden)) {
  align-items: flex-start;
}

.ui-v3 .auth-card-inner {
  width: min(420px, 100%);
  margin: auto;
}

.ui-v3 .auth-card:has(#authRegisterPane:not(.hidden)) .auth-card-inner {
  margin: 0 auto;
}

.ui-v3 .auth-card .auth-tabs {
  margin-bottom: 30px;
}

.ui-v3 .auth-card .auth-heading {
  margin-bottom: 24px;
}

.ui-v3 .auth-card .auth-heading h2 {
  font-size: 27px;
}

.ui-v3 .auth-card .auth-heading > span {
  font-size: 9px;
  letter-spacing: 0;
}

.ui-v3 .auth-panel-footer {
  border-top: 1px solid #e2e7e5;
  font-size: 9px;
}

.ui-v3 .auth-panel-footer > span {
  color: #98a19d;
  white-space: nowrap;
}

.ui-v3 .auth-panel-footer .auth-security-note {
  display: flex;
  grid-template-columns: none;
  gap: 13px;
  margin: 0;
  font-size: 8px;
}

.ui-v3 .auth-panel-footer .auth-security-note > span {
  gap: 4px;
}

@media (max-width: 1100px) and (min-width: 841px) {
  .ui-v3 .auth-shell {
    grid-template-columns: minmax(430px, 50%) minmax(0, 1fr);
  }

  .ui-v3 .auth-visual-content {
    padding: 26px 28px 22px;
  }

  .ui-v3 .auth-visual-message h1 {
    font-size: 32px;
  }

  .ui-v3 .auth-capability-list small {
    display: none;
  }

  .ui-v3 .auth-commercial-strip {
    gap: 10px;
  }

  .ui-v3 .auth-commercial-strip strong {
    font-size: 16px;
  }

  .ui-v3 .auth-commercial-strip button {
    gap: 8px;
    padding: 0 10px;
  }

  .ui-v3 .auth-card {
    padding-right: 34px;
    padding-left: 34px;
  }
}

@media (max-height: 720px) and (min-width: 841px) {
  .ui-v3 .auth-visual-content {
    padding-top: 22px;
    padding-bottom: 18px;
  }

  .ui-v3 .auth-visual-message .auth-aside-kicker {
    margin-bottom: 9px;
  }

  .ui-v3 .auth-visual-message h1 {
    font-size: 31px;
  }

  .ui-v3 .auth-visual-message > p {
    margin-top: 9px;
    font-size: 11px;
  }

  .ui-v3 .auth-capability-list {
    margin-top: 16px;
  }

  .ui-v3 .auth-capability-list > div {
    min-height: 42px;
  }

  .ui-v3 .auth-commercial-strip {
    padding-top: 12px;
  }

  .ui-v3 .auth-panel-header {
    min-height: 56px;
  }

  .ui-v3 .login-box {
    grid-template-rows: 56px minmax(0, 1fr) 48px;
  }

  .ui-v3 .auth-card {
    padding-top: 24px;
    padding-bottom: 24px;
  }
}

@media (max-width: 840px) {
  .ui-v3 .auth-shell {
    grid-template-columns: 1fr;
    grid-template-rows: 78px minmax(0, 1fr);
  }

  .ui-v3 .auth-visual {
    height: 78px;
    min-height: 78px;
  }

  .ui-v3 .auth-visual-image {
    object-position: 64% 38%;
  }

  .ui-v3 .auth-visual-shade {
    background: rgba(5, 17, 15, 0.5);
  }

  .ui-v3 .auth-visual-content {
    display: block;
    padding: 15px 20px;
  }

  .ui-v3 .auth-visual .auth-aside-brand .brand-mark {
    width: 40px;
    height: 40px;
  }

  .ui-v3 .auth-visual-message,
  .ui-v3 .auth-commercial-strip {
    display: none;
  }

  .ui-v3 .login-box {
    height: calc(100dvh - 78px);
    grid-template-rows: 52px minmax(0, 1fr) 46px;
  }

  .ui-v3 .auth-panel-header,
  .ui-v3 .auth-panel-footer {
    padding-right: 20px;
    padding-left: 20px;
  }

  .ui-v3 .auth-card {
    align-items: flex-start;
    padding: 24px 20px 30px;
  }

  .ui-v3 .auth-card-inner,
  .ui-v3 .auth-card:has(#authRegisterPane:not(.hidden)) .auth-card-inner {
    margin: 0 auto;
  }

  .ui-v3 .auth-panel-footer > span {
    display: none;
  }

  .ui-v3 .auth-panel-footer .auth-security-note {
    width: 100%;
    justify-content: space-between;
  }
}

@media (max-width: 480px) {
  .ui-v3 .auth-panel-header {
    font-size: 9px;
  }

  .ui-v3 .auth-panel-footer .auth-security-note {
    gap: 5px;
    font-size: 7px;
  }
}
