:root {
  --bg: #eef2f5;
  --surface: #ffffff;
  --surface-2: #f5f7fa;
  --line: #d8e0e8;
  --text: #0e1724;
  --muted: #5f6f82;
  --accent: #0c7c70;
  --accent-2: #265f9c;
  --steel: #16495c;
  --amber: #b8812f;
  --gold: #d7b66d;
  --ink: #101721;
  --sidebar: #0d1520;
  --good: #18805c;
  --warn: #9b6a12;
  --danger: #b14242;
  --shadow: 0 18px 50px rgba(12, 21, 32, 0.10);
  --shadow-strong: 0 26px 80px rgba(12, 21, 32, 0.18);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background:
    linear-gradient(180deg, rgba(16, 23, 33, 0.10), rgba(16, 23, 33, 0) 300px),
    linear-gradient(135deg, rgba(12, 124, 112, 0.08), rgba(38, 95, 156, 0.05) 48%, rgba(184, 129, 47, 0.07)),
    var(--bg);
  font-family: "Segoe UI", Roboto, Arial, Helvetica, sans-serif;
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 82px;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  display: block;
  max-width: 100vw;
  min-height: 100vh;
  overflow-x: hidden;
}

.sidebar {
  display: none !important;
  position: sticky;
  top: 0;
  flex-direction: column;
  gap: 24px;
  height: 100vh;
  padding: 24px;
  background: #14202d;
  color: #fff;
  max-width: 100vw;
  overflow-x: hidden;
}

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

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 8px;
  background: #d8efe9;
  color: #0c4f4d;
  font-size: 24px;
  font-weight: 800;
}

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

.brand strong {
  font-size: 20px;
}

.brand span {
  margin-top: 3px;
  color: #b8c7d7;
  font-size: 13px;
}

.nav {
  display: grid;
  gap: 8px;
}

.nav a {
  padding: 11px 12px;
  border-radius: 8px;
  color: #dce6ef;
  text-decoration: none;
}

.nav a.active,
.nav a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.plan-box {
  margin-top: auto;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.plan-box span,
.plan-box small {
  color: #b8c7d7;
}

.plan-box strong {
  display: block;
  margin: 5px 0;
}

.meter,
.progress-line {
  overflow: hidden;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
}

.meter span,
.progress-line span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), #69b77a);
}

.workspace {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 28px 24px 42px;
  overflow-x: hidden;
}

.account-dashboard {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.account-hero,
.command-center,
.security-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 14px;
}

.account-hero,
.command-main,
.subscription-card,
.account-metric,
.billing-board,
.tariff-card,
.security-panel,
.profile-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.account-hero {
  align-items: center;
  overflow: hidden;
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(16, 23, 33, 0.98), rgba(16, 62, 74, 0.96) 52%, rgba(62, 48, 30, 0.95)),
    var(--ink);
  color: #fff;
  box-shadow: var(--shadow-strong);
}

.compact-account .account-grid,
.compact-account .command-center,
.compact-account .billing-board {
  display: none;
}

.compact-account .account-hero {
  min-height: 0;
}

.compact-account .account-copy p {
  max-width: none;
}

.account-copy {
  display: grid;
  gap: 9px;
}

.eyebrow-row,
.cabinet-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 9px;
  border: 1px solid #d2dde7;
  border-radius: 999px;
  background: #f6f8fb;
  color: #455466;
  font-size: 12px;
  font-weight: 700;
  cursor: default;
  user-select: none;
}

.status-active {
  border-color: #bdded7;
  background: #e8f6f1;
  color: var(--good);
}

.account-copy h2 {
  font-size: 34px;
  line-height: 1.15;
  letter-spacing: 0;
}

.account-copy p {
  max-width: 760px;
  color: #cbd5df;
}

.account-card {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 96px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.account-avatar {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 8px;
  background: linear-gradient(135deg, #e7d7ad, var(--gold));
  color: #15110a;
  font-weight: 900;
}

.account-card span,
.account-card small,
.account-metric span,
.account-metric small,
.subscription-card span,
.subscription-card small,
.command-head span,
.security-list span,
.profile-stack span {
  color: var(--muted);
  font-size: 12px;
}

.account-card strong,
.account-card small {
  display: block;
}

.account-card strong {
  margin: 3px 0;
  font-size: 16px;
}

.account-hero .account-card span,
.account-hero .account-card small {
  color: #cbd5df;
}

.account-hero .status-pill {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: #dce7ef;
}

.account-hero .status-active {
  border-color: rgba(198, 161, 91, 0.48);
  background: rgba(198, 161, 91, 0.16);
  color: #f0d99d;
}

.status-note::before {
  content: "";
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 0 3px rgba(198, 161, 91, 0.16);
}

.cabinet-nav {
  position: sticky;
  top: 10px;
  z-index: 20;
  align-items: center;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 28px rgba(24, 35, 51, 0.06);
}

.cabinet-nav button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.cabinet-nav button.active,
.cabinet-nav button:hover {
  background: linear-gradient(135deg, rgba(12, 124, 112, 0.13), rgba(38, 95, 156, 0.10));
  color: var(--accent);
}

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

.account-metric {
  display: grid;
  gap: 5px;
  min-height: 108px;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 249, 250, 0.98)),
    var(--surface);
}

.account-metric strong {
  font-size: 22px;
  line-height: 1.1;
}

.command-main,
.subscription-card {
  padding: 16px;
}

.command-main {
  display: grid;
  gap: 14px;
}

.command-head {
  display: grid;
  gap: 6px;
}

.command-head strong {
  font-size: 18px;
  line-height: 1.25;
}

.command-flow {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.command-flow div {
  min-height: 86px;
  padding: 12px;
  border: 1px solid #d7e7e4;
  border-radius: 8px;
  background: #f5faf9;
}

.command-flow b,
.command-flow span {
  display: block;
}

.command-flow b {
  margin-bottom: 7px;
  color: var(--steel);
  font-size: 12px;
}

.command-flow span {
  color: #334155;
  font-size: 13px;
  line-height: 1.35;
}

.subscription-card {
  display: grid;
  align-content: center;
  gap: 8px;
  background:
    linear-gradient(145deg, rgba(13, 21, 32, 0.98), rgba(20, 54, 66, 0.96)),
    var(--ink);
  color: #fff;
  box-shadow: var(--shadow-strong);
}

.subscription-card span,
.subscription-card small {
  color: #c6d2df;
}

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

.subscription-line {
  overflow: hidden;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
}

.subscription-line span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #45b59c, var(--amber));
}

.billing-board {
  display: grid;
  gap: 16px;
  padding: 20px;
  background:
    linear-gradient(135deg, rgba(16, 23, 33, 0.98), rgba(16, 62, 74, 0.96) 56%, rgba(56, 44, 31, 0.96)),
    var(--ink);
  color: #fff;
}

.billing-copy {
  max-width: 920px;
}

.billing-copy span,
.tariff-card span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.billing-copy h2 {
  margin-top: 6px;
  font-size: 24px;
  line-height: 1.15;
}

.billing-copy p {
  margin-top: 8px;
  color: #cbd5df;
  line-height: 1.45;
}

.billing-board .billing-copy span,
.billing-board .tariff-card span {
  color: #f0d99d;
}

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

.tariff-card {
  display: grid;
  align-content: start;
  gap: 8px;
  min-height: 224px;
  padding: 16px;
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.075);
  color: #fff;
}

.tariff-featured {
  border-color: rgba(240, 217, 157, 0.86);
  background:
    linear-gradient(180deg, rgba(255, 251, 240, 0.16), rgba(255, 255, 255, 0.08)),
    rgba(255, 255, 255, 0.11);
  box-shadow: 0 22px 64px rgba(0, 0, 0, 0.28);
}

.tariff-card strong {
  font-size: 26px;
  line-height: 1.1;
}

.tariff-card small {
  color: #cbd5df;
}

.tariff-card ul {
  display: grid;
  gap: 7px;
  margin: 8px 0 0;
  padding-left: 18px;
  color: #dce6ef;
  line-height: 1.35;
}

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

.payment-grid div {
  display: grid;
  gap: 6px;
  min-height: 112px;
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.075);
}

.payment-grid b,
.payment-grid span {
  display: block;
}

.payment-grid b {
  color: #fff;
}

.payment-grid span {
  color: #cbd5df;
  font-size: 13px;
  line-height: 1.4;
}

.security-grid {
  grid-template-columns: 1.05fr 0.95fr;
  margin-top: 14px;
}

.security-list,
.profile-stack {
  display: grid;
  gap: 9px;
}

.security-list div,
.profile-stack div {
  display: grid;
  gap: 4px;
  padding: 11px;
  border-radius: 8px;
  background: var(--surface-2);
}

.security-list b,
.profile-stack strong {
  color: var(--text);
  font-size: 14px;
}

.mobile-tabbar {
  display: none;
}

.login-body {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 28px;
  background:
    linear-gradient(135deg, rgba(23, 107, 135, 0.10), rgba(201, 130, 43, 0.08)),
    #edf2f6;
}

.login-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  width: min(1040px, 100%);
  min-height: 620px;
  overflow: hidden;
  border: 1px solid rgba(17, 24, 39, 0.10);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(17, 24, 39, 0.16);
}

.login-brand {
  display: grid;
  align-content: center;
  gap: 18px;
  padding: 42px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0)),
    #111827;
  color: #fff;
}

.login-mark {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 8px;
  background: #e8f6f1;
  color: #0f4c61;
  font-size: 30px;
  font-weight: 900;
}

.login-brand h1 {
  font-size: 42px;
  line-height: 1;
}

.login-brand p {
  max-width: 520px;
  color: #c8d3df;
  font-size: 18px;
  line-height: 1.45;
}

.login-points {
  display: grid;
  gap: 10px;
  max-width: 560px;
  margin-top: 10px;
}

.login-points div {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-height: 54px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.login-points b {
  color: #65c8b3;
  font-size: 13px;
}

.login-points span {
  color: #edf4f7;
  font-size: 14px;
}

.login-panel {
  display: grid;
  align-content: center;
  gap: 24px;
  padding: 42px;
}

.login-kicker {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.login-panel h2 {
  margin-top: 8px;
  font-size: 28px;
}

.login-panel p,
.login-footnote {
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.45;
}

.login-form {
  display: grid;
  gap: 14px;
}

.login-form label {
  display: grid;
  gap: 7px;
}

.login-form label span {
  color: #445166;
  font-size: 13px;
  font-weight: 700;
}

.login-form input:not([type="checkbox"]) {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
}

.login-form input:focus {
  outline: 2px solid rgba(23, 107, 135, 0.22);
  outline-offset: 2px;
}

.remember-row {
  display: flex !important;
  grid-template-columns: none;
  align-items: center;
  gap: 9px !important;
}

.remember-row input {
  width: 16px;
  height: 16px;
  accent-color: var(--accent);
}

.login-submit {
  width: 100%;
  min-height: 46px;
  margin-top: 4px;
}

.login-error {
  min-height: 18px;
  color: var(--danger);
  font-size: 13px;
}

.login-footnote {
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}

.workspace *,
.sidebar * {
  overflow-wrap: anywhere;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 32px;
  line-height: 1.15;
}

h2 {
  font-size: 17px;
}

.topbar p {
  margin-top: 6px;
  color: var(--muted);
}

.top-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.primary,
.ghost,
.segmented button,
.strategy-control button,
.card-action {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
}

.primary {
  padding: 0 16px;
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}

.primary:disabled {
  cursor: wait;
  opacity: 0.72;
}

.ghost {
  padding: 0 14px;
}

.network-pill {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(148, 163, 184, 0.32);
  border-radius: 8px;
  padding: 0 12px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.network-pill[data-mode="online"] {
  border-color: rgba(13, 107, 104, 0.28);
  background: rgba(13, 107, 104, 0.09);
  color: var(--accent);
}

.network-pill[data-mode="offline"] {
  border-color: rgba(185, 108, 36, 0.34);
  background: rgba(214, 161, 74, 0.14);
  color: #8a520f;
}

.quick-start {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

.quick-card {
  display: grid;
  gap: 18px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 251, 252, 0.98)),
    #fff;
  box-shadow: var(--shadow);
}

.quick-copy {
  max-width: 780px;
}

.quick-copy span {
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.quick-copy h2 {
  margin-top: 6px;
  font-size: 30px;
  line-height: 1.15;
}

.quick-copy p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 16px;
}

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

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

.quick-pricing span {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid #d8e4ea;
  border-radius: 8px;
  background: #f7fafb;
  color: #334155;
  font-size: 13px;
  font-weight: 700;
}

.quick-pricing b {
  color: var(--accent);
}

.big-action {
  display: grid;
  min-height: 132px;
  align-content: center;
  gap: 8px;
  padding: 18px;
  border: 1px solid #c9d9e5;
  border-radius: 8px;
  background:
    linear-gradient(180deg, #ffffff, #f5f8fb);
  color: var(--text);
  text-align: left;
  text-decoration: none;
  box-shadow: 0 14px 35px rgba(16, 24, 32, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

label.big-action {
  cursor: pointer;
}

.big-action input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.big-action:focus-within {
  border-color: #0d6b68;
  box-shadow: 0 0 0 4px rgba(13, 107, 104, 0.15);
}

.big-action b {
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border-radius: 999px;
  background: #dcece9;
  color: var(--accent);
}

.big-action strong {
  font-size: 23px;
  line-height: 1.1;
}

.big-action small {
  color: var(--muted);
  font-size: 14px;
}

.upload-action,
.find-action,
.export-action {
  border-color: #0d6b68;
}

.big-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 45px rgba(16, 24, 32, 0.13);
}

.demo-disclaimer {
  display: grid;
  gap: 4px;
  margin-top: 12px;
  padding: 12px 14px;
  border: 1px solid #ead4a6;
  border-radius: 8px;
  background: #fffaf0;
  color: #5f4309;
}

.demo-disclaimer strong {
  font-size: 13px;
}

.demo-disclaimer span {
  color: #6f5a23;
  font-size: 13px;
  line-height: 1.45;
}

.find-action,
.export-action {
  background: linear-gradient(135deg, #0a5d58, #0c7c70);
  color: #fff;
}

.export-action {
  background: linear-gradient(135deg, #183f73, #2869b0);
}

.find-action b,
.export-action b {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.find-action small,
.export-action small {
  color: #d9f1ed;
}

.quick-status {
  display: grid;
  grid-template-columns: 1fr 1.2fr 0.8fr;
  gap: 10px;
}

.quick-status div {
  display: grid;
  gap: 6px;
  min-height: 84px;
  padding: 12px;
  border-radius: 8px;
  background: var(--surface-2);
}

.quick-status span {
  color: var(--muted);
  font-size: 13px;
}

.quick-status strong {
  font-size: 15px;
  line-height: 1.3;
}

.quick-status small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.search-progress {
  height: 7px;
  background: #dbe7ec;
}

.find-action.is-loading {
  position: relative;
  border-color: #174d63;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0)),
    #0f4c61;
}

.find-action.is-loading::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 14px;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 999px;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.quick-start .live-panel {
  display: none;
}

.operator-strip {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.75fr);
  align-items: start;
  gap: 14px;
  margin-bottom: 14px;
}

.operator-main,
.live-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.operator-main {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 18px;
  padding: 18px;
}

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

.flow-steps div {
  min-height: 82px;
  padding: 12px;
  border: 1px solid #d7e7e4;
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  background: #f4faf8;
}

.flow-steps b,
.flow-steps strong,
.flow-steps span,
.strategy-panel p,
.live-actions span,
.connector-row span,
.connector-row small {
  display: block;
}

.flow-steps b {
  color: var(--accent);
  font-size: 12px;
}

.flow-steps strong {
  margin: 6px 0 4px;
}

.flow-steps span,
.strategy-panel p,
.live-actions span,
.connector-row span,
.connector-row small {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.strategy-panel {
  display: grid;
  align-content: start;
  gap: 14px;
}

.strategy-control {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.strategy-control button {
  min-width: 0;
  padding: 0 8px;
  background: #fff;
  font-weight: 700;
  overflow-wrap: normal;
  white-space: nowrap;
}

.strategy-control button.active {
  border-color: var(--accent);
  background: #e6f3f0;
  color: #0b504d;
}

.live-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.live-actions span {
  min-width: 0;
}

.live-panel {
  max-height: 290px;
  overflow: hidden;
  padding: 18px;
}

.connector-list {
  display: grid;
  gap: 8px;
  max-height: 215px;
  overflow: auto;
  padding-right: 2px;
}

.connector-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.connector-row b {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  justify-content: center;
  padding: 3px 8px;
  border-radius: 999px;
  background: #edf1f7;
  color: #34445a;
  font-size: 12px;
}

.connector-row small {
  margin-top: 4px;
  text-align: right;
}

.connector-active {
  border-color: #bdded7;
  background: #f4faf8;
}

.connector-active b {
  background: #dff4ec;
  color: var(--good);
}

.connector-needs-contract b,
.connector-needs-api-key b {
  background: #fff1d5;
  color: var(--warn);
}

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

.status-grid article:nth-child(n+5) {
  display: none;
}

.status-grid article,
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.status-grid article {
  padding: 14px;
}

.status-grid span,
.status-grid small {
  display: block;
  color: var(--muted);
}

.status-grid strong {
  display: block;
  margin: 7px 0;
  font-size: 23px;
}

.work-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 14px;
  margin-bottom: 14px;
}

.work-grid-wide {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 360px;
}

.panel {
  padding: 18px;
}

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

.panel-head span,
.badge {
  color: var(--muted);
  font-size: 13px;
}

.badge {
  padding: 5px 8px;
  border-radius: 999px;
  background: var(--surface-2);
}

.dropzone {
  display: grid;
  gap: 6px;
  min-height: 116px;
  padding: 20px;
  border: 1px dashed #a8b7c4;
  border-radius: 8px;
  background: var(--surface-2);
}

.dropzone input {
  display: none;
}

.dropzone strong {
  font-size: 18px;
}

.dropzone span,
.progress-meta,
.extract-list span {
  color: var(--muted);
}

.progress-wrap {
  margin: 16px 0;
}

.progress-line {
  background: #e4ebf1;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 13px;
}

.extract-list,
.history-list,
.source-list,
.mini-list,
.scenario-list,
.compliance-list {
  display: grid;
  gap: 9px;
}

.supplier-actions {
  display: flex;
  justify-content: flex-end;
  margin: -2px 0 12px;
}

.extract-list div,
.history-list div,
.source-list div,
.mini-list div,
.scenario-list div,
.compliance-list div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 11px;
  border-radius: 8px;
  background: var(--surface-2);
}

.extract-list strong,
.history-list span,
.source-list span,
.mini-list span,
.scenario-list span,
.scenario-list small,
.compliance-list span {
  color: var(--muted);
  font-size: 13px;
}

.extract-list small {
  color: var(--muted);
  font-size: 12px;
}

.request-extra {
  margin-top: -5px;
  border-left: 3px solid #bedbd5;
  background: #f4faf8 !important;
}

.extract-list .row-warning {
  border-left: 3px solid #d97706;
  background: #fff7ed;
}

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

.filters label {
  display: grid;
  gap: 7px;
}

.filters label:last-child {
  grid-column: 1 / -1;
}

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

.filters select,
.filters input[type="number"] {
  width: 100%;
  min-height: 40px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.filters input[type="range"] {
  width: 100%;
  accent-color: var(--accent);
}

.segmented {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}

.segmented button {
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  background: transparent;
}

.segmented button.active {
  background: #fff;
  box-shadow: 0 2px 8px rgba(20, 32, 45, 0.08);
}

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

.product-card {
  display: grid;
  gap: 12px;
  min-height: 350px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.product-card.is-missing {
  border-color: #e5c271;
  background: #fffaf0;
}

.product-card header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.product-card h3 {
  margin: 0;
  font-size: 16px;
  line-height: 1.25;
}

.match {
  flex: 0 0 auto;
  color: var(--good);
  font-weight: 800;
}

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

.type-badge,
.risk-badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.type-badge {
  background: #edf1f7;
  color: #34445a;
}

.risk-low {
  background: #e7f5ef;
  color: #176143;
}

.risk-medium {
  background: #fff3d8;
  color: #76500c;
}

.risk-high {
  background: #fde8e8;
  color: #943131;
}

.price-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.request-line {
  display: grid;
  gap: 4px;
  padding: 10px;
  border-radius: 8px;
  background: var(--surface-2);
}

.request-line span {
  color: var(--muted);
  font-size: 12px;
}

.request-line strong {
  font-size: 13px;
  line-height: 1.35;
}

.price {
  font-size: 24px;
  font-weight: 800;
}

.price-stack,
.table-price-stack {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.price-stack span,
.table-price-stack span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

.price-stack b,
.table-price-stack b {
  color: var(--text);
  font-size: 15px;
}

.price-stack span:first-child b {
  color: #2457a6;
}

.price-stack span:last-child b,
.table-price-stack span:last-child b {
  color: var(--good);
}

.price-variance,
.table-price-variance {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 3px 7px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.25;
}

.price-variance-high {
  background: #fde8e8;
  color: #943131;
}

.price-variance-low,
.price-variance-match {
  background: #e7f5ef;
  color: #176143;
}

.price-variance-unknown,
.table-price-variance {
  background: #eef3f8;
  color: var(--muted);
}

.table-price-variance {
  padding: 0;
  background: transparent;
}

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

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

.product-proof div {
  display: grid;
  gap: 3px;
  min-height: 62px;
  padding: 10px;
  border: 1px solid #d8e2eb;
  border-radius: 8px;
  background: #f8fafc;
}

.product-proof span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.product-proof strong {
  overflow-wrap: anywhere;
  color: var(--text);
  font-size: 13px;
  line-height: 1.25;
}

.commercial-grid,
.kpi-stack {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.commercial-grid span,
.kpi-stack div {
  padding: 9px;
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
}

.commercial-grid b {
  color: var(--text);
}

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

.specs span {
  padding: 5px 8px;
  border-radius: 999px;
  background: #edf4f3;
  color: #184d4a;
  font-size: 12px;
}

.alt-links,
.table-alt-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.table-alt-links span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.alt-links {
  padding: 9px;
  border: 1px solid #dbe7e5;
  border-radius: 8px;
  background: #f7fbfa;
}

.alt-links span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.alt-links a,
.table-alt-links a {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 3px 8px;
  border: 1px solid #cfdeda;
  border-radius: 999px;
  background: #fff;
  color: #154f4a;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.alt-links a:hover,
.table-alt-links a:hover {
  border-color: #0d6b68;
  background: #e9f5f2;
}

.table-alt-links {
  max-width: 360px;
  margin-top: 6px;
}

.meta {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 13px;
}

.card-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
  margin-top: auto;
}

.card-action {
  text-decoration: none;
  display: grid;
  place-items: center;
  padding: 0 10px;
}

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

.card-action.saved {
  border-color: #d8c378;
  background: #fff7d6;
}

.primary-link {
  border-color: #1a6d64;
  background: #123d39;
  color: #fff;
  font-weight: 900;
}

.primary-link:hover {
  background: #0b504d;
}

.site-check {
  border-color: #b9d6cd;
  background: #eef8f5;
  color: #0b504d;
}

.table-shell {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.table-scroll-top {
  position: sticky;
  top: 0;
  z-index: 5;
  height: 16px;
  overflow-x: auto;
  overflow-y: hidden;
  border-bottom: 1px solid var(--line);
  background: #f6f8fb;
}

.table-scroll-spacer {
  height: 1px;
  min-width: 100%;
}

.table-wrap {
  overflow: auto;
  max-height: min(72vh, 760px);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1580px;
  background: #fff;
}

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

th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #f6f8fb;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

tbody tr {
  transition: background 0.16s ease, box-shadow 0.16s ease;
}

tbody tr:hover {
  background: #f8fbfc;
  box-shadow: inset 3px 0 0 var(--accent);
}

tbody tr.is-selected-row {
  background: #eef8f5;
  box-shadow: inset 4px 0 0 var(--ok);
}

tbody tr.is-selected-row:hover {
  background: #e7f4f0;
}

td:nth-child(2),
td:nth-child(8) {
  max-width: 320px;
  min-width: 260px;
  white-space: normal;
  line-height: 1.35;
}

th:first-child,
td:first-child {
  position: sticky;
  left: 0;
  z-index: 3;
  width: 112px;
  min-width: 112px;
  max-width: 112px;
  background: #fff;
  box-shadow: 1px 0 0 var(--line);
}

th:first-child {
  z-index: 4;
  background: #f6f8fb;
}

.source-row-cell {
  color: var(--muted);
  font-weight: 800;
}

td:nth-child(3) {
  min-width: 180px;
}

.is-missing-row {
  background: #fffaf0;
}

.is-missing-row:hover {
  background: #fff4dc;
  box-shadow: inset 3px 0 0 #c08a26;
}

.needs-product-link td:nth-child(13) {
  color: #8a5a0a;
}

.needs-product-link td:nth-child(7) {
  color: #8a5a0a;
}

.table-subline {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
  white-space: normal;
}

.quality-pill,
.product-link,
.no-product-link {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.quality-match {
  background: #e7f5ef;
  color: #176143;
}

.quality-manual {
  background: #fff3d8;
  color: #76500c;
}

.product-link {
  border: 1px solid #b9d6cd;
  background: #eef8f5;
  color: #0b504d;
  text-decoration: none;
}

.product-link:hover {
  border-color: #0d6b68;
  background: #e0f2ee;
}

.no-product-link {
  background: #f5eee0;
  color: #7a5315;
}

.panel-kicker {
  display: block;
  margin-bottom: 5px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

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

.result-summary article {
  display: grid;
  gap: 5px;
  min-height: 104px;
  padding: 14px;
  border: 1px solid #d8e2eb;
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 249, 250, 0.98)),
    #fff;
}

.result-summary span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.result-summary strong {
  font-size: 26px;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.result-summary article:last-child strong {
  font-size: 20px;
}

.result-summary small {
  color: var(--muted);
  line-height: 1.35;
}

.result-summary .summary-ready {
  border-color: #bdded7;
  background: #f4faf8;
}

.result-summary .summary-ready strong {
  color: var(--good);
}

.result-summary .summary-manual {
  border-color: #ead4a6;
  background: #fffaf0;
}

.result-summary .summary-manual strong {
  color: #8a5a0a;
}

.procurement-lane {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin: 12px 0;
}

.lane-card {
  min-height: 86px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: var(--surface-2);
}

.lane-card span,
.lane-card small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.lane-card strong {
  display: block;
  margin: 5px 0;
  color: var(--text);
  font-size: 24px;
  line-height: 1;
}

.lane-ok {
  border-color: rgba(13, 107, 104, 0.2);
  background: rgba(13, 107, 104, 0.07);
}

.lane-warn {
  border-color: rgba(214, 161, 74, 0.28);
  background: rgba(214, 161, 74, 0.12);
}

.pro-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.9fr 0.95fr;
  gap: 14px;
  margin-top: 14px;
}

.rfq-list,
.supplier-funnel,
.event-feed {
  display: grid;
  gap: 9px;
}

.rfq-list div,
.supplier-funnel div,
.event-feed div {
  display: grid;
  gap: 5px;
  min-height: 66px;
  padding: 11px;
  border-radius: 8px;
  background: var(--surface-2);
}

.rfq-list span,
.supplier-funnel span,
.event-feed span {
  color: var(--muted);
  font-size: 13px;
}

.supplier-funnel div {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.supplier-funnel span {
  grid-column: 1 / -1;
}

.supplier-funnel strong {
  color: var(--accent);
  font-size: 22px;
}

.event-feed div {
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
}

.event-feed span {
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 800;
}

.cell-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 14px;
  margin-top: 14px;
}

.cell-list,
.gate-list {
  display: grid;
  gap: 9px;
}

.cell-list div,
.gate-list div {
  display: grid;
  gap: 5px;
  min-height: 66px;
  padding: 11px;
  border-radius: 8px;
  background: var(--surface-2);
}

.cell-list div {
  grid-template-columns: minmax(130px, 0.45fr) minmax(0, 0.75fr);
  align-items: center;
}

.cell-list span {
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 13px;
}

.cell-list strong {
  color: var(--accent);
}

.gate-list div {
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: center;
}

.gate-list span {
  display: inline-flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(13, 107, 104, 0.1);
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.table-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  margin: 2px 4px 2px 0;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}

.table-action.saved {
  border-color: #d8c378;
  background: #fff7d6;
}

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

.bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 0.9fr;
  gap: 14px;
  margin-top: 14px;
}

.insights-grid {
  display: grid;
  grid-template-columns: 0.9fr 1fr 1.1fr;
  gap: 14px;
  margin-top: 14px;
}

.kpi-stack div {
  display: grid;
  gap: 5px;
  min-height: 72px;
}

.kpi-stack strong {
  color: var(--text);
  font-size: 21px;
}

.scenario-list div,
.compliance-list div {
  align-items: flex-start;
  flex-direction: column;
}

.scenario-list .active-scenario {
  border: 1px solid #bdded7;
  background: #f4faf8;
}

.scenario-list strong,
.compliance-list strong {
  font-size: 14px;
}

.scenario-list small {
  line-height: 1.35;
}

.wide-empty {
  grid-column: 1 / -1;
}

.ok {
  color: var(--good) !important;
}

.warn {
  color: var(--warn) !important;
}

.hold {
  color: var(--accent-2) !important;
}

.empty {
  justify-content: center !important;
  min-height: 95px;
  color: var(--muted);
}

.hidden {
  display: none !important;
}

.toast {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 10;
  max-width: 360px;
  padding: 13px 15px;
  border-radius: 8px;
  background: #14202d;
  color: #fff;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  transition: 0.18s ease;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1120px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

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

  .plan-box {
    margin-top: 0;
  }

  .cards,
  .bottom-grid,
  .insights-grid,
  .work-grid-wide,
  .account-grid,
  .payment-grid,
  .procurement-lane,
  .pro-grid,
  .cell-grid,
  .result-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-hero,
  .command-center,
  .security-grid {
    grid-template-columns: 1fr;
  }

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

  .filters-panel {
    grid-column: 1 / -1;
  }

  .operator-strip,
  .operator-main {
    grid-template-columns: 1fr;
  }

  .live-panel {
    max-height: none;
  }

  .connector-list {
    max-height: none;
  }
}

@media (max-width: 760px) {
  .login-body {
    padding: 16px;
  }

  .login-shell {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .login-brand,
  .login-panel {
    padding: 24px;
  }

  .login-brand h1 {
    font-size: 34px;
  }

  .login-brand p {
    font-size: 16px;
  }

  .app-shell {
    display: flex;
    flex-direction: column;
  }

  .workspace,
  .sidebar {
    padding: 16px;
  }

  .workspace {
    order: 1;
    display: flex;
    flex-direction: column;
    padding-bottom: 88px;
  }

  .topbar {
    order: 0;
  }

  .quick-start {
    order: 1;
  }

  .account-dashboard {
    order: 2;
  }

  .results-panel,
  .details-shell,
  .insights-grid,
  .bottom-grid,
  .security-grid {
    order: 3;
  }

  .sidebar {
    order: 2;
  }

  .topbar {
    gap: 12px;
    margin-bottom: 8px;
  }

  .quick-copy {
    display: none;
  }

  .topbar p {
    display: -webkit-box;
    max-width: 34rem;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    font-size: 12px;
    line-height: 1.32;
  }

  .account-dashboard {
    gap: 10px;
    margin-bottom: 12px;
  }

  .account-hero,
  .command-main,
  .subscription-card {
    padding: 14px;
  }

  .account-copy h2 {
    font-size: 21px;
  }

  .account-card {
    min-height: auto;
  }

  .cabinet-nav {
    display: none;
  }

  .quick-card {
    padding: 12px;
  }

  .quick-start {
    gap: 10px;
    margin-bottom: 8px;
  }

  .quick-card {
    gap: 10px;
  }

  .quick-copy {
    order: 1;
  }

  .quick-actions {
    order: 2;
    gap: 8px;
  }

  .quick-pricing {
    display: none;
  }

  .big-action {
    grid-template-columns: 34px minmax(0, 1fr);
    align-items: center;
    align-content: center;
    min-height: 68px;
    gap: 3px 10px;
    padding: 10px 12px;
  }

  .big-action b {
    grid-row: span 2;
    width: 30px;
    height: 30px;
  }

  .big-action strong {
    font-size: 18px;
  }

  .big-action small {
    font-size: 12px;
  }

  .demo-disclaimer {
    order: 4;
    margin-top: 0;
    padding: 8px 10px;
  }

  .quick-status {
    order: 3;
    position: sticky;
    top: 8px;
    z-index: 9;
    gap: 7px;
    padding: 7px;
    border: 1px solid rgba(13, 107, 104, 0.2);
    border-radius: 8px;
    background: rgba(248, 251, 253, 0.96);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
  }

  .quick-status div {
    min-height: 0;
    padding: 8px;
  }

  .quick-status strong {
    font-size: 14px;
  }

  .quick-status small {
    font-size: 11px;
  }

  .find-action.is-loading::after {
    right: 12px;
    top: 12px;
  }

  .topbar,
  .extract-list div,
  .history-list div,
  .source-list div,
  .mini-list div,
  .live-actions,
  .connector-row {
    align-items: stretch;
    flex-direction: column;
  }

  .top-actions,
  .quick-actions,
  .quick-pricing,
  .quick-status,
  .account-grid,
  .command-flow,
  .tariff-grid,
  .payment-grid,
  .procurement-lane,
  .pro-grid,
  .cell-grid,
  .result-summary,
  .card-actions,
  .product-proof,
  .commercial-grid,
  .kpi-stack,
  .filters,
  .work-grid,
  .work-grid-wide,
  .cards,
  .bottom-grid,
  .insights-grid,
  .status-grid,
  .nav,
  .flow-steps,
  .strategy-control,
  .connector-row {
    grid-template-columns: 1fr;
  }

  .cell-list div,
  .gate-list div {
    grid-template-columns: 1fr;
  }

  .billing-board {
    padding: 14px;
  }

  .tariff-card {
    min-height: 0;
  }

  .mobile-tabbar {
    position: fixed;
    right: 10px;
    bottom: 10px;
    left: 10px;
    z-index: 20;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
    padding: 6px;
    border: 1px solid rgba(17, 24, 39, 0.14);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 45px rgba(17, 24, 39, 0.18);
    backdrop-filter: blur(12px);
  }

  .mobile-tabbar a {
    display: grid;
    min-height: 42px;
    place-items: center;
    border-radius: 8px;
    color: #334155;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
  }

  .mobile-tabbar a:hover,
  .mobile-tabbar a:focus {
    background: #e7f1f4;
    color: #0f4c61;
  }

  .top-actions {
    display: flex;
    gap: 8px;
  }

  .network-pill {
    min-height: 36px;
    padding: 0 10px;
    font-size: 12px;
  }

  h1 {
    font-size: 24px;
  }
}

.catalog-body {
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(8, 18, 32, 0.94), rgba(38, 34, 25, 0.92)),
    #0b1320;
  color: #f7f1e7;
}

.catalog-shell {
  width: min(1040px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0;
}

.catalog-back {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: #d8c29a;
  font-weight: 800;
  text-decoration: none;
}

.catalog-card {
  margin-top: 18px;
  border: 1px solid rgba(216, 194, 154, 0.28);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.035));
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.32);
  padding: clamp(24px, 4vw, 44px);
}

.catalog-card h1 {
  max-width: 860px;
  margin: 18px 0 14px;
  color: #fff8ea;
  font-size: clamp(30px, 4.5vw, 56px);
  line-height: 1.04;
}

.catalog-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #d7deea;
}

.catalog-meta span,
.catalog-meta b {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.06);
}

.catalog-price {
  margin: 28px 0;
  color: #f5cc72;
  font-size: clamp(34px, 5vw, 64px);
  font-weight: 900;
}

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

.catalog-specs div {
  min-height: 92px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 16px;
  background: rgba(9, 19, 33, 0.62);
}

.catalog-specs dt {
  margin-bottom: 8px;
  color: #aab7c8;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.catalog-specs dd {
  margin: 0;
  color: #f7f1e7;
  font-weight: 800;
}

.catalog-spec-wide {
  grid-column: 1 / -1;
}

@media (max-width: 720px) {
  .catalog-shell {
    width: min(100% - 20px, 1040px);
    padding: 18px 0;
  }

  .catalog-card {
    padding: 20px;
  }

  .catalog-specs {
    grid-template-columns: 1fr;
  }
}

/* Demo focus: keep the first screen as a procurement workspace, not a pricing/search landing page. */
.account-dashboard,
.quick-pricing,
.demo-disclaimer {
  display: none !important;
}

body {
  background: #f3f5f7;
}

.workspace {
  padding-top: 18px;
}

.topbar,
.quick-card,
.results-panel,
.panel {
  box-shadow: none;
}

.topbar {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.topbar h1 {
  font-size: clamp(24px, 3vw, 36px);
  letter-spacing: 0;
}

.topbar p,
.quick-copy p {
  max-width: 760px;
}

.quick-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.quick-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.big-action {
  min-height: 74px;
  border-radius: 8px;
  box-shadow: none;
}

.big-action b {
  width: 24px;
  height: 24px;
  font-size: 12px;
}

.big-action strong {
  font-size: 15px;
}

.big-action small {
  font-size: 12px;
}

.result-summary article,
.status-grid article,
.connector-row,
.tariff-card {
  box-shadow: none;
}

#cardsView.hidden {
  display: none !important;
}

@media (max-width: 700px) {
  .quick-actions {
    grid-template-columns: minmax(0, 1fr);
  }

  .big-action {
    min-height: 68px;
  }
}

/* Premium operator workspace: compact, quiet, and built around the purchase flow. */
:root {
  --premium-bg: #eef1f4;
  --premium-ink: #111827;
  --premium-panel: #ffffff;
  --premium-soft: #f7f9fb;
  --premium-line: #dbe3ea;
  --premium-accent: #0b6f68;
  --premium-blue: #1f5f99;
}

body {
  background:
    linear-gradient(180deg, #e9eef3 0, #f7f9fb 320px, #eef1f4 100%);
  color: var(--premium-ink);
}

.workspace {
  width: min(100%, 1440px);
  padding: 16px 18px 34px;
}

.app-commandbar {
  position: sticky;
  top: 0;
  z-index: 18;
  min-height: 66px;
  margin-bottom: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(17, 24, 39, 0.10);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
}

.app-commandbar h1 {
  font-size: 25px;
  line-height: 1;
  letter-spacing: 0;
}

.app-commandbar p {
  max-width: 620px;
  margin-top: 5px;
  font-size: 13px;
  line-height: 1.35;
}

.top-actions {
  align-items: center;
}

.ghost,
.network-pill,
.segmented,
.card-action,
.table-action {
  border-radius: 8px;
}

.ghost {
  min-height: 36px;
  background: #fff;
  font-size: 13px;
  font-weight: 800;
}

.quick-start {
  margin-bottom: 12px;
}

.quick-card {
  grid-template-columns: minmax(220px, 0.55fr) minmax(520px, 1.45fr);
  align-items: start;
  gap: 12px;
  padding: 12px;
  border-color: rgba(17, 24, 39, 0.10);
  background: var(--premium-panel);
}

.quick-copy {
  display: grid;
  align-content: center;
  min-height: 100%;
  max-width: none;
  padding: 9px 12px;
  border: 1px solid #e3e9ef;
  border-radius: 8px;
  background: #f8fafc;
}

.quick-copy span {
  color: var(--premium-accent);
  font-size: 11px;
  letter-spacing: 0.08em;
}

.quick-copy h2 {
  margin-top: 8px;
  font-size: 19px;
  line-height: 1.12;
}

.quick-copy p {
  max-width: 30rem;
  font-size: 12px;
  line-height: 1.45;
}

.quick-actions {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.big-action {
  min-height: 74px;
  padding: 10px 12px;
  border-color: #ccd8e2;
  background: #fff;
  box-shadow: none;
}

.big-action:hover {
  transform: translateY(-1px);
  border-color: #8fb5c9;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.08);
}

.big-action b {
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: #e7f2f1;
}

.big-action strong {
  font-size: 15px;
  line-height: 1.18;
}

.big-action small {
  font-size: 12px;
  line-height: 1.35;
}

.find-action,
.export-action {
  border-color: transparent;
}

.find-action {
  background: #0a625d;
}

.export-action {
  background: #214f82;
}

.quick-status {
  grid-column: 1 / -1;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.quick-status div {
  min-height: 0;
  padding: 7px 10px;
  border: 1px solid #e1e8ef;
  background: #f8fafc;
}

.quick-status span,
.quick-status small {
  font-size: 11px;
}

.quick-status strong {
  font-size: 12px;
}

.results-panel {
  padding: 12px;
  border-color: rgba(17, 24, 39, 0.10);
  background: #fff;
}

.panel-head {
  margin-bottom: 8px;
}

.panel-head h2 {
  font-size: 17px;
}

.panel-kicker {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 11px !important;
}

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

.result-summary article {
  min-height: 50px;
  padding: 7px 9px;
  border: 1px solid #e1e8ef;
  border-radius: 8px;
  background: #f8fafc;
}

.result-summary article:nth-child(n+5) {
  display: none;
}

.result-summary span,
.result-summary small {
  font-size: 10px;
}

.result-summary strong {
  margin: 2px 0;
  font-size: 16px;
}

.procurement-lane {
  display: none;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  margin-bottom: 8px;
}

.lane-card {
  min-height: 58px;
  padding: 8px 10px;
  border-radius: 8px;
  box-shadow: none;
}

.table-wrap {
  max-height: min(68vh, 720px);
  scroll-padding-top: 44px;
}

th,
td {
  padding: 7px 9px;
}

th {
  font-size: 12px;
  letter-spacing: 0;
}

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

.product-card {
  min-height: 320px;
  padding: 13px;
  box-shadow: none;
}

.product-proof,
.commercial-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.details-shell {
  margin-top: 10px;
  border: 1px solid rgba(17, 24, 39, 0.10);
  border-radius: 8px;
  background: #fff;
  overflow: hidden;
}

.details-shell summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 52px;
  padding: 0 14px;
  cursor: pointer;
  list-style: none;
}

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

.details-shell summary strong {
  font-size: 15px;
}

.details-shell summary span {
  color: var(--muted);
  font-size: 12px;
}

.details-shell summary::after {
  content: "+";
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border: 1px solid var(--premium-line);
  border-radius: 8px;
  color: var(--premium-accent);
  font-weight: 900;
}

.details-shell[open] summary {
  border-bottom: 1px solid var(--premium-line);
}

.details-shell[open] summary::after {
  content: "-";
}

.details-content {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  align-items: start;
  gap: 10px;
  padding: 12px;
}

.live-panel,
.status-grid,
.work-grid,
.insights-grid,
.pro-grid,
.cell-grid,
.bottom-grid,
.security-grid {
  margin: 0;
}

.details-content .live-panel {
  grid-column: 1;
}

.details-content .status-grid {
  grid-column: 2;
}

.details-content .work-grid-wide {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 320px;
}

.details-content .insights-grid,
.details-content .bottom-grid {
  grid-column: 1 / -1;
}

.details-content .pro-grid,
.details-content .cell-grid,
.details-content .security-grid {
  display: none;
}

.status-grid,
.work-grid-wide,
.insights-grid,
.pro-grid,
.cell-grid,
.bottom-grid,
.security-grid {
  gap: 10px;
}

.panel,
.status-grid article,
.live-panel {
  box-shadow: none;
}

.panel {
  padding: 14px;
}

.extract-list,
.history-list,
.source-list,
.mini-list,
.scenario-list,
.compliance-list {
  max-height: 220px;
  overflow: auto;
}

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

.status-grid article {
  min-height: 72px;
  padding: 10px 12px;
}

.status-grid strong {
  margin: 4px 0;
  font-size: 20px;
}

.status-grid span,
.status-grid small {
  font-size: 11px;
}

.work-grid-wide .panel {
  min-height: 0;
}

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

.bottom-grid {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 0.9fr) minmax(0, 1.2fr);
}

.mobile-tabbar {
  border-radius: 8px;
}

@media (max-width: 1180px) {
  .quick-card {
    grid-template-columns: 1fr;
  }

  .quick-copy {
    min-height: 0;
  }

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

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

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

  .details-content,
  .details-content .work-grid-wide,
  .status-grid,
  .insights-grid,
  .bottom-grid {
    grid-template-columns: 1fr;
  }

  .details-content .live-panel,
  .details-content .status-grid,
  .details-content .work-grid-wide,
  .details-content .insights-grid,
  .details-content .bottom-grid {
    grid-column: auto;
  }
}

@media (max-width: 760px) {
  .workspace {
    padding: 10px 10px 86px;
  }

  .app-commandbar {
    position: static;
    min-height: 0;
    padding: 10px;
  }

  .app-commandbar h1 {
    font-size: 19px;
    line-height: 1.15;
  }

  .app-commandbar p {
    display: none;
  }

  .top-actions {
    flex-direction: row;
  }

  .top-actions .ghost,
  .network-pill {
    flex: 1 1 120px;
  }

  .quick-card,
  .results-panel,
  .details-shell {
    padding: 10px;
  }

  .quick-copy {
    display: none;
  }

  .quick-copy h2 {
    font-size: 20px;
  }

  .quick-actions,
  .quick-status,
  .result-summary,
  .procurement-lane,
  .cards {
    grid-template-columns: 1fr;
  }

  .big-action {
    grid-template-columns: 34px minmax(0, 1fr);
    min-height: 66px;
  }

  .big-action b {
    grid-row: span 2;
  }

  .details-shell summary {
    min-height: 48px;
    padding: 0 10px;
  }

  .details-shell summary span {
    display: none;
  }
}

/* One explicit candidate choice per request line. */
.selection-control { display: inline-flex; align-items: center; gap: 7px; cursor: pointer; min-height: 36px; }
.selection-control input { width: 18px; height: 18px; margin: 0; accent-color: #267453; cursor: pointer; flex-shrink: 0; }
.selection-control.saved { border-color: #267453; background: #e8f5ed; color: #165737; }
.selection-control.is-disabled { opacity: .6; cursor: not-allowed; }
.selection-note { flex-basis: 100%; color: var(--muted); line-height: 1.4; }

.selection-recommendation { display: block; max-width: 230px; margin: 5px 0; color: #165737; line-height: 1.35; font-weight: 600; }

.quick-status #uploadReport {
  display: block;
  font-size: 12px;
  overflow-wrap: anywhere;
  margin-top: 8px;
}
.quick-status #uploadReport[hidden] { display: none; }
.quick-status #uploadReport > div {
  display: block;
  padding: 3px 0;
  border: 0;
  background: transparent;
}

.source-row-cell { white-space: normal; overflow-wrap: anywhere; line-height: 1.35; }
.selection-recommendation { white-space: normal; overflow-wrap: anywhere; }
#tableBody td:nth-child(3) { min-width: 220px; white-space: normal; }
#tableBody .table-alt-links { min-width: 240px; }
.product-card .sum { min-width: 90px; overflow-wrap: normal; word-break: normal; }

.decision-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 14px 0; padding: 12px; border: 1px solid #cbded8; background: #f4faf7; border-radius: 8px; }
.decision-toolbar p { margin: 0; max-width: 680px; color: #26473d; line-height: 1.45; }
.decision-toolbar .segmented { flex-shrink: 0; }
.decision-note { display: grid; gap: 6px; margin-top: 9px; font-size: 12px; line-height: 1.45; font-weight: 400; white-space: normal; }
.decision-note strong { font-size: 12px; color: #16614b; }
.decision-note span { overflow-wrap: anywhere; }
.decision-alternatives { justify-self: start; padding: 6px 9px; font-size: 12px; }
.supplier-currency { display: flex; align-items: center; gap: 10px; margin: 12px 0; font-size: 13px; }
.supplier-currency select { min-height: 36px; width: auto; max-width: 200px; }
@media (max-width: 700px) { .decision-toolbar { display: grid; } .decision-toolbar .segmented { display: flex; width: 100%; } .decision-toolbar button { flex: 1; white-space: normal; } .supplier-currency { flex-wrap: wrap; } }
