:root {
  --near-black: #151517;
  --card: #1c1c1f;
  --card-hover: #222225;
  --pink: #e872a8;
  --pink-soft: rgba(232, 114, 168, 0.08);
  --pink-border: rgba(232, 114, 168, 0.22);
  --lime: #d2f34c;
  --warm-white: #f0ece6;
  --muted: #9a9894;
  --muted-dim: #5e5e64;
  --border: rgba(240, 236, 230, 0.08);
  --red: #f87171;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--near-black); }

body {
  background: var(--near-black);
  color: var(--warm-white);
  font-family: Inter, system-ui, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  position: relative;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 900px 700px at 5% 10%, rgba(232, 114, 168, 0.14), transparent 60%),
    radial-gradient(ellipse 800px 600px at 95% 50%, rgba(180, 100, 220, 0.09), transparent 60%),
    radial-gradient(ellipse 700px 500px at 50% 100%, rgba(210, 243, 76, 0.05), transparent 60%);
}

.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 32px;
  position: relative;
  z-index: 2;
}

.banner {
  background: var(--near-black);
  border-bottom: 1px solid var(--border);
  text-align: center;
  padding: 12px 20px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--warm-white);
  position: relative;
  z-index: 10;
}

.banner .dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--lime);
  border-radius: 50%;
  margin-right: 10px;
  box-shadow: 0 0 0 3px rgba(210, 243, 76, 0.25);
  animation: pulse 2s ease-in-out infinite;
  vertical-align: middle;
}

.banner strong { color: var(--lime); font-weight: 500; }

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(210, 243, 76, 0.25); }
  50% { box-shadow: 0 0 0 6px rgba(210, 243, 76, 0.05); }
}

nav {
  padding: 24px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.logo-wordmark {
  font-family: Poppins, sans-serif;
  font-weight: 800;
  font-size: 22px;
  color: var(--warm-white);
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.bolt-mark { width: 22px; height: 28px; }
.bolt-mark svg { width: 100%; height: 100%; display: block; }

.nav-email {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  color: var(--muted);
}

.setup-main { position: relative; z-index: 2; padding: 24px 0 80px; }
.setup-wrap { max-width: 940px; margin: 0 auto; }

/* The connect section is a flex column so we can reorder children with `order`
   based on whether the user is mid-setup (step cards + sync notice + accounts
   + bottom CTA) or already linked (compact CTA at top + accounts below). */
#panelConnect { display: flex; flex-direction: column; }
#setupEyebrow { order: 1; }
#setupTitle { order: 2; }
#setupSub { order: 3; }
#progressMeter { order: 4; }
#stepsFrame { order: 5; }
#syncNotice { order: 6; }
#setupDone { order: 7; }
#claudeInstall { order: 7; }
#accountsPanel { order: 8; }
#connectMsg { order: 9; }
.setup-footer { order: 10; }

/* Default (mid-setup): CTA sits below accounts list. Ready mode keeps the
   DOM order (CTA above accounts) — so no override needed there. */
#panelConnect:not(.is-ready-mode) #accountsPanel { order: 6; }

/* Ready mode: the walkthrough is the page, so keep top setup copy out of the way. */
#panelConnect.is-ready-mode #setupEyebrow,
#panelConnect.is-ready-mode #setupTitle,
#panelConnect.is-ready-mode #setupSub {
  display: none;
}

#panelConnect.is-ready-mode #syncNotice {
  order: 4;
}

#panelConnect.is-ready-mode #setupDone,
#panelConnect.is-ready-mode #claudeInstall {
  order: 5;
}

#panelConnect.is-ready-mode #accountsPanel {
  order: 6;
  margin-top: 12px;
}

.eyebrow-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  background: rgba(232, 114, 168, 0.1);
  border: 1px solid var(--pink-border);
  color: var(--pink);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.eyebrow-pill::before {
  content: "";
  width: 6px;
  height: 6px;
  background: var(--pink);
}

h1.setup-title {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin-bottom: 14px;
}

h1.setup-title .pink { color: var(--pink); }

.setup-sub {
  font-size: 17px;
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 12px;
  max-width: 660px;
}

.setup-sub strong { color: var(--warm-white); font-weight: 600; }

.progress-meter {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 22px 0 28px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.progress-track {
  flex: 1;
  height: 4px;
  background: var(--card);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.progress-fill {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0%;
  background: var(--lime);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.progress-count { color: var(--lime); white-space: nowrap; }

/* Auth panel */
.auth-panel {
  max-width: 440px;
  margin: 0 auto 40px;
}

.auth-card {
  background: var(--card);
  border: 1px solid var(--pink-border);
  padding: 32px;
}

.auth-card h2 {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-size: 26px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.auth-card h2 .pink { color: var(--pink); }

.auth-card .auth-sub {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 22px;
}

form label {
  display: block;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--lime);
  margin-bottom: 8px;
  font-weight: 500;
}

form input {
  width: 100%;
  background: rgba(21, 21, 23, 0.6);
  border: 1px solid var(--pink-border);
  color: var(--warm-white);
  padding: 14px 16px;
  font-size: 15px;
  margin-bottom: 16px;
  outline: none;
}

form input:focus {
  border-color: var(--pink);
  box-shadow: 0 0 0 2px rgba(232, 114, 168, 0.15);
}

.btn-lime {
  width: 100%;
  background: var(--lime);
  color: var(--near-black);
  border: 0;
  padding: 14px 16px;
  font-weight: 800;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
  transition: box-shadow 0.2s, background 0.2s;
}

.btn-lime:hover {
  background: #e5ff6a;
  box-shadow: 0 0 28px rgba(210, 243, 76, 0.38);
}

.btn-lime:disabled,
.btn-lime.btn-disabled {
  background: #6b7a2a;
  color: rgba(21, 21, 23, 0.6);
  cursor: not-allowed;
  box-shadow: none;
}

.btn-linkedin {
  width: 100%;
  background: #0a66c2;
  color: #fff;
  border: 0;
  padding: 14px 16px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.02em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: box-shadow 0.2s, background 0.2s;
}

.btn-linkedin svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.btn-linkedin:hover {
  background: #004182;
  box-shadow: 0 0 28px rgba(10, 102, 194, 0.35);
}

.btn-linkedin:disabled {
  background: #3d5a7a;
  color: rgba(255, 255, 255, 0.6);
  cursor: not-allowed;
  box-shadow: none;
}

.terms-consent {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 0 0 16px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
  cursor: pointer;
  user-select: none;
}

.terms-consent input[type="checkbox"] {
  margin-top: 2px;
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  accent-color: var(--pink);
  cursor: pointer;
}

.terms-consent a {
  color: var(--pink);
  font-weight: 600;
  text-decoration: none;
}

.terms-consent a:hover { text-decoration: underline; }

.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 20px 0;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-toggle {
  text-align: center;
  margin-top: 16px;
  font-size: 13px;
  color: var(--muted);
}

.auth-toggle a {
  color: var(--pink);
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

.msg {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  color: var(--muted);
  margin-top: 12px;
  min-height: 16px;
  text-align: center;
}

.msg.err { color: var(--red); }
.msg.ok { color: var(--lime); }

/* Connect steps */
.steps-frame {
  border: 1px solid var(--pink-border);
  background: rgba(232, 114, 168, 0.04);
  padding: 24px 20px 20px;
  position: relative;
  margin-top: 8px;
}

.steps-frame-label {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
  position: absolute;
  top: -9px;
  left: 18px;
  background: var(--near-black);
  padding: 0 8px;
}

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

.step-card {
  background: linear-gradient(180deg, #1f1f24 0%, #18181b 100%);
  border: 1px solid rgba(232, 114, 168, 0.38);
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  min-height: 280px;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.step-card.is-done {
  border-color: rgba(210, 243, 76, 0.5);
  background: linear-gradient(180deg, rgba(210, 243, 76, 0.08) 0%, #18181b 60%);
}

.step-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.step-icon {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--pink-soft);
  border: 1px solid var(--pink-border);
  color: var(--pink);
}

.step-card.is-done .step-icon {
  background: rgba(210, 243, 76, 0.08);
  border-color: rgba(210, 243, 76, 0.35);
  color: var(--lime);
}

.step-icon svg { width: 20px; height: 20px; }

.step-badge {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: 30px;
  color: var(--muted-dim);
}

.step-card.is-done .step-badge { color: var(--lime); }

.step-label {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: 8px;
}

.step-card h3 {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: 17px;
  margin-bottom: 8px;
}

.step-card > p {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
  flex: 1;
}

.step-card > p strong { color: var(--warm-white); }

.step-action { margin-top: auto; position: relative; }

.btn-connect {
  width: 100%;
  background: var(--lime);
  color: var(--near-black);
  border: 0;
  padding: 13px 14px;
  font-weight: 800;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.btn-connect:hover {
  background: #e5ff6a;
  box-shadow: 0 0 28px rgba(210, 243, 76, 0.38);
}

.step-status-done {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 14px;
  border: 1px solid rgba(210, 243, 76, 0.4);
  background: rgba(210, 243, 76, 0.06);
  color: var(--lime);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.step-status-done .check {
  width: 16px;
  height: 16px;
  background: var(--lime);
  color: var(--near-black);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.step-foot {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 9px;
  color: var(--muted-dim);
  margin-top: 10px;
  line-height: 1.5;
}

.accounts-panel {
  max-width: 760px;
  margin: 16px auto 0;
  background: var(--card);
  border: 1px solid var(--border);
  padding: 0;
}

.accounts-disclosure summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
}

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

.accounts-disclosure summary span:first-child {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--warm-white);
}

.accounts-disclosure summary strong {
  color: var(--lime);
}

.accounts-summary-action {
  flex-shrink: 0;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lime);
}

.accounts-disclosure[open] .accounts-summary-action {
  color: var(--muted);
}

.accounts-panel-hint {
  font-size: 12px;
  color: var(--muted);
  margin: 0 16px 14px;
  line-height: 1.45;
}

.accounts-panel-discovering {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text);
  background: rgba(210, 243, 76, 0.06);
  border: 1px solid rgba(210, 243, 76, 0.18);
  border-radius: 10px;
  padding: 10px 12px;
  margin: 0 16px 14px;
  line-height: 1.45;
}

.acct-discovering-dot {
  width: 9px;
  height: 9px;
  margin-top: 4px;
  border-radius: 50%;
  flex-shrink: 0;
  background: var(--lime, #d2f34c);
  animation: pulse 1.6s ease-in-out infinite;
}

.accounts-panel-reconnect {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text);
  background: rgba(255, 184, 76, 0.08);
  border: 1px solid rgba(255, 184, 76, 0.28);
  border-radius: 10px;
  padding: 10px 12px;
  margin: 0 16px 14px;
  line-height: 1.45;
}

.accounts-panel-reconnect a {
  color: var(--pink, #ff5fa2);
  font-weight: 600;
  text-decoration: underline;
}

.acct-reconnect-icon {
  flex-shrink: 0;
  margin-top: 1px;
  font-size: 13px;
  color: rgba(255, 184, 76, 0.95);
}

ul.accounts {
  list-style: none;
  max-height: 320px;
  overflow-y: auto;
  padding: 0 16px 4px;
}

ul.accounts li.acct-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

ul.accounts li.acct-row:last-child { border-bottom: none; }

.acct-row-main {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 0;
  flex: 1;
}

.acct-info { min-width: 0; }

.acct-name {
  font-weight: 600;
  color: var(--warm-white);
  word-break: break-word;
}

.acct-id {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  color: var(--muted-dim);
  margin-top: 4px;
}

.acct-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex-shrink: 0;
}

.acct-actions-label {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-dim);
}

.hs-status {
  font-size: 11px;
  font-weight: 600;
}

.hs-status.is-connected { color: var(--lime); }

.hs-btn {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--warm-white);
  cursor: pointer;
  text-decoration: none;
}

.hs-btn.hs-connect {
  border-color: var(--pink-border);
  color: var(--pink);
}

.hs-btn.hs-connect:hover {
  background: var(--pink-soft);
}

.hs-btn.hs-share {
  border-color: rgba(210, 243, 76, 0.35);
  color: var(--lime);
}

.hs-btn.hs-share:hover {
  background: rgba(210, 243, 76, 0.08);
}

.hs-btn.hs-share:disabled {
  opacity: 0.6;
  cursor: wait;
}

.hs-btn.hs-disconnect {
  color: var(--muted);
  font-size: 9px;
  padding: 4px 8px;
  border-color: transparent;
}

.hs-btn.hs-disconnect:hover { color: var(--warm-white); }

.mcp-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.mcp-toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.mcp-toggle-track {
  width: 36px;
  height: 20px;
  background: var(--border);
  border-radius: 10px;
  position: relative;
  transition: background 0.15s;
}

.mcp-toggle-track::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: var(--muted);
  border-radius: 50%;
  transition: transform 0.15s, background 0.15s;
}

.mcp-toggle input:checked + .mcp-toggle-track {
  background: rgba(210, 243, 76, 0.25);
  border: 1px solid rgba(210, 243, 76, 0.45);
}

.mcp-toggle input:checked + .mcp-toggle-track::after {
  transform: translateX(16px);
  background: var(--lime);
}

.mcp-toggle-label {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 8px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-dim);
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  line-height: 1;
}

.sync-panel {
  max-width: 760px;
  margin: 18px auto 0;
  padding: 14px 16px;
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 3px solid var(--lime);
}

.sync-panel-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 0;
}

.sync-spinner {
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(210, 243, 76, 0.45);
  background: rgba(210, 243, 76, 0.06);
  color: var(--lime);
}

.sync-spinner svg {
  width: 18px;
  height: 18px;
  animation: sync-spin 2.4s linear infinite;
}

@keyframes sync-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.sync-eyebrow {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: 3px;
}

.sync-panel-title {
  display: none;
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--warm-white);
  margin-bottom: 8px;
}

.sync-panel-sub {
  font-size: 13px;
  line-height: 1.4;
  color: var(--muted);
  max-width: none;
}

.sync-callout {
  display: none;
}

.sync-callout svg {
  width: 20px;
  height: 20px;
  color: var(--lime);
  flex-shrink: 0;
  margin-top: 2px;
}

.sync-callout-big {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--warm-white);
  margin-bottom: 4px;
}

.sync-callout-small {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10.5px;
  letter-spacing: 0.03em;
  color: var(--muted);
  line-height: 1.45;
}

.setup-footer {
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.setup-nudge {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.setup-done {
  width: 100%;
  box-sizing: border-box;
  max-width: 520px;
  margin: 24px auto 0;
  padding: 28px 24px 26px;
  background: var(--card);
  border: 1px solid rgba(210, 243, 76, 0.35);
  box-shadow: 0 0 40px rgba(210, 243, 76, 0.08);
  text-align: center;
}

/* Returning-user variant: full-width compact card above the accounts list. */
#panelConnect.is-ready-mode .setup-done.is-compact {
  max-width: none;
  margin: 16px 0 0;
  padding: 18px 20px 16px;
  text-align: left;
}

.setup-done-head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.setup-done.is-compact .setup-done-head {
  flex-direction: row;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 14px;
}

.setup-done-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(210, 243, 76, 0.45);
  background: rgba(210, 243, 76, 0.08);
  color: var(--lime);
}

.setup-done.is-compact .setup-done-icon {
  width: 40px;
  height: 40px;
  margin: 0;
}

.setup-done-icon svg {
  width: 24px;
  height: 24px;
}

.setup-done.is-compact .setup-done-icon svg {
  width: 20px;
  height: 20px;
}

.setup-done-text {
  width: 100%;
  min-width: 0;
}

.setup-done.is-compact .setup-done-text {
  flex: 1;
}

.setup-done-title {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(22px, 3vw, 28px);
  letter-spacing: -0.02em;
  color: var(--warm-white);
  margin-bottom: 12px;
}

.setup-done.is-compact .setup-done-title {
  font-size: 18px;
  margin-bottom: 6px;
  line-height: 1.25;
}

.setup-done-body {
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
}

.setup-done.is-compact .setup-done-body {
  font-size: 13px;
  line-height: 1.5;
}

.setup-done-body strong {
  color: var(--warm-white);
  font-weight: 600;
}

.setup-done-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  margin-top: 20px;
  padding: 14px 28px;
  font-size: 12px;
}

.setup-done.is-compact .setup-done-cta {
  margin-top: 0;
  padding: 12px 20px;
}

.setup-done-cta:disabled,
.setup-done-cta.btn-disabled {
  opacity: 0.65;
  cursor: progress;
}

.setup-done-foot {
  margin: 12px 0 0;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: var(--muted-dim);
  line-height: 1.5;
}

.setup-done.is-compact .setup-done-foot {
  margin-top: 10px;
  font-size: 10px;
}

.claude-install {
  width: 100%;
  box-sizing: border-box;
  max-width: 760px;
  margin: 16px auto 0;
  padding: 24px;
  background: var(--card);
  border: 1px solid rgba(210, 243, 76, 0.35);
  box-shadow: 0 0 40px rgba(210, 243, 76, 0.08);
}

#panelConnect.is-ready-mode .claude-install.is-compact {
  max-width: none;
  margin: 16px 0 0;
  padding: 18px 20px 16px;
}

.claude-steps {
  margin: 18px 0 18px;
  padding-left: 20px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.claude-steps li {
  margin-bottom: 8px;
}

.claude-steps strong {
  color: var(--warm-white);
  font-weight: 600;
}

.connector-url-box {
  margin-bottom: 0;
}

.connector-url-box > label {
  display: block;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--lime);
  margin-bottom: 8px;
  font-weight: 500;
}

.connector-url-row {
  display: flex;
  gap: 8px;
}

.connector-url-row input {
  flex: 1;
  min-width: 0;
  background: rgba(21, 21, 23, 0.6);
  border: 1px solid var(--pink-border);
  color: var(--warm-white);
  padding: 12px 14px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  outline: none;
}

.btn-copy {
  flex-shrink: 0;
  background: var(--lime);
  color: var(--near-black);
  border: 0;
  padding: 12px 16px;
  font-weight: 800;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: box-shadow 0.2s, background 0.2s;
}

.btn-copy:hover {
  background: #e5ff6a;
  box-shadow: 0 0 20px rgba(210, 243, 76, 0.35);
}

.video-embed {
  position: relative;
  width: 100%;
  margin: 20px 0 18px;
  padding-bottom: 64.28571428571428%;
  height: 0;
  border: 1px solid rgba(210, 243, 76, 0.35);
  background: rgba(21, 21, 23, 0.4);
  box-shadow: 0 0 34px rgba(210, 243, 76, 0.08);
  overflow: hidden;
}

.video-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

#setupDoneEmail {
  color: var(--lime);
  font-weight: 600;
}

footer {
  padding: 28px 0;
  border-top: 1px solid var(--border);
  text-align: center;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  color: var(--muted);
  position: relative;
  z-index: 2;
}

.is-hidden { display: none !important; }

.loading-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
  padding: 64px 24px;
}

.loading-title {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
}

.loading-sub {
  font-size: 14px;
  color: var(--muted);
  max-width: 420px;
  line-height: 1.5;
  margin: 0;
}

.error-card {
  text-align: center;
}

.error-card h2 {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 10px;
  letter-spacing: -0.02em;
}

.error-card .auth-sub {
  text-align: left;
}

.error-card .auth-sub strong {
  color: var(--warm-white);
  font-weight: 600;
}

.error-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--pink-border);
  background: var(--pink-soft);
  color: var(--pink);
}

.error-icon svg {
  width: 26px;
  height: 26px;
}

.error-callout {
  margin: 20px 0 16px;
  padding: 16px 18px;
  text-align: left;
  background: rgba(232, 114, 168, 0.04);
  border: 1px solid var(--pink-border);
}

.error-callout p {
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: var(--warm-white);
  margin-bottom: 10px;
}

.error-callout ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.error-callout li {
  margin-bottom: 6px;
}

.error-foot {
  font-size: 13px;
  line-height: 1.55;
  color: var(--muted);
  text-align: left;
  margin-bottom: 20px;
}

.error-cta {
  display: inline-flex;
  width: 100%;
  text-decoration: none;
}

.spinner-mini {
  width: 12px;
  height: 12px;
  border: 2px solid var(--lime);
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
  vertical-align: middle;
}

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

@media (max-width: 760px) {
  .steps-grid { grid-template-columns: 1fr; }
  .container { padding: 0 20px; }
}
