:root {
  color-scheme: light;
  --ink: #152033;
  --muted: #657086;
  --line: #dce2ec;
  --soft: #f5f7fb;
  --paper: #ffffff;
  --surface: #ffffff;
  --surface-raised: #ffffff;
  --input: #ffffff;
  --header: rgba(255,255,255,.92);
  --hero-start: #fafaff;
  --hero-end: #ffffff;
  --brand: #635bff;
  --brand-dark: #4038d7;
  --brand-soft: #eeedff;
  --teal: #0a8f7a;
  --warn: #a35b00;
  --danger: #c4324b;
  --shadow: 0 18px 55px rgba(34, 46, 76, .12);
  --radius: 18px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); line-height: 1.55; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: var(--brand-dark); }
.hidden { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link { position: fixed; top: -60px; left: 16px; z-index: 100; background: var(--ink); color: white; padding: 10px; }
.skip-link:focus { top: 12px; }
.site-header {
  height: 72px; padding: 0 clamp(18px, 5vw, 76px); display: flex; align-items: center;
  gap: 32px; position: sticky; top: 0; z-index: 20; background: var(--header);
  border-bottom: 1px solid rgba(220,226,236,.8); backdrop-filter: blur(14px);
}
body[data-shell="app"] .site-header { box-shadow: 0 8px 28px rgba(34,46,76,.045); }
body[data-shell="auth"] .site-header { border-bottom-color: transparent; }
body[data-shell="auth"] .site-header .auth-out { display: none !important; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-weight: 760; white-space: nowrap; }
.brand-mark {
  width: 34px; height: 34px; display: block; flex: 0 0 auto; border-radius: 10px;
  box-shadow: 0 7px 16px rgba(99,91,255,.26);
}
.brand-mark img, .product-logo img, .product-avatar img { display: block; width: 100%; height: 100%; }
.main-nav { display: flex; align-items: center; gap: 24px; margin: 0 auto; }
.main-nav a { color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 600; }
.main-nav a:hover { color: var(--ink); }
.app-header-nav { justify-content: center; }
.workspace-status { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; font-weight: 750; }
.workspace-status i { width: 7px; height: 7px; border-radius: 50%; background: #24a982; box-shadow: 0 0 0 4px rgba(36,169,130,.12); }
.header-actions { display: flex; align-items: center; gap: 9px; }
.language-control select {
  border: 0; background: transparent; color: var(--muted); font-size: 13px; font-weight: 700; cursor: pointer;
}
.theme-toggle {
  width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line);
  border-radius: 10px; color: var(--ink); background: var(--surface); cursor: pointer;
}
.theme-toggle:hover { color: var(--brand); border-color: #b9b4ff; background: var(--brand-soft); }
.header-user {
  min-width: 0; display: flex; align-items: center; gap: 9px; max-width: 210px;
  padding: 5px 8px; border-radius: 10px; color: var(--ink); text-decoration: none;
}
.header-user:hover { background: var(--soft); }
.header-avatar {
  width: 32px; height: 32px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 10px;
  color: white; background: linear-gradient(135deg, var(--brand), #827cff); font-size: 12px; font-weight: 850;
}
.header-user-copy { min-width: 0; display: grid; line-height: 1.15; }
.header-user-copy strong, .side-account strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.header-user-copy small { color: var(--muted); font-size: 10px; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--brand); border-radius: 10px; padding: 11px 18px;
  background: var(--brand); color: white; font-weight: 700; text-decoration: none; cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.button:hover { background: var(--brand-dark); transform: translateY(-1px); box-shadow: 0 8px 22px rgba(99,91,255,.22); }
.button:disabled { opacity: .48; cursor: not-allowed; transform: none; box-shadow: none; }
[aria-busy="true"] .button:disabled { cursor: wait; }
.button.ghost { color: var(--ink); border-color: var(--line); background: var(--surface); }
.button.ghost:hover { border-color: #b6becc; background: var(--soft); box-shadow: none; }
.button.danger { color: var(--danger); border-color: #f1c4cc; background: #fff5f6; }
.button.copy-success { color: white; border-color: var(--teal); background: var(--teal); }
.button.small { padding: 8px 13px; font-size: 13px; }
.button.wide { width: 100%; }
.hero {
  position: relative; overflow: hidden; padding: clamp(72px, 10vw, 132px) 22px 82px;
  background:
    radial-gradient(circle at 78% 18%, rgba(99,91,255,.16), transparent 27%),
    radial-gradient(circle at 20% 72%, rgba(10,143,122,.09), transparent 25%),
    linear-gradient(180deg, var(--hero-start) 0%, var(--hero-end) 100%);
}
.hero-grid { max-width: 1180px; margin: auto; display: grid; grid-template-columns: 1.1fr .9fr; gap: 72px; align-items: center; }
.eyebrow { color: var(--brand); font-size: 12px; letter-spacing: .13em; font-weight: 800; text-transform: uppercase; }
h1 { margin: 14px 0 22px; max-width: 760px; font-size: clamp(42px, 6vw, 72px); line-height: 1.04; letter-spacing: -.045em; }
h2 { margin: 8px 0 15px; font-size: clamp(28px, 4vw, 44px); line-height: 1.12; letter-spacing: -.035em; }
h3 { margin: 0 0 9px; font-size: 19px; line-height: 1.25; }
.lead { color: var(--muted); font-size: clamp(18px, 2vw, 21px); max-width: 690px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin: 30px 0 19px; }
.microcopy { color: var(--muted); font-size: 13px; }
.hero-trust { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 24px; color: var(--muted); font-size: 11px; font-weight: 650; }
.hero-trust span::first-letter { color: var(--teal); }
.product-preview {
  overflow: hidden; border: 1px solid rgba(99,91,255,.23); border-radius: 24px;
  background: var(--surface-raised); box-shadow: 0 34px 75px rgba(23,28,62,.20); transform: rotate(1deg);
}
.product-preview-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 15px 18px;
  border-bottom: 1px solid var(--line); background: var(--soft); font-size: 12px;
}
.product-preview-head > div { display: flex; align-items: center; gap: 9px; }
.product-logo { width: 29px; height: 29px; display: block; border-radius: 9px; box-shadow: 0 5px 12px rgba(99,91,255,.22); }
.product-live { display: flex; align-items: center; gap: 6px; color: var(--teal); font-size: 10px; font-weight: 750; }
.product-live i, .product-activity i { width: 7px; height: 7px; border-radius: 50%; background: #24a982; box-shadow: 0 0 0 4px rgba(36,169,130,.12); }
.product-preview-body { display: grid; gap: 11px; padding: 18px; }
.product-route {
  display: flex; align-items: center; gap: 11px; padding: 12px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface);
}
.product-route-icon { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 11px; color: white; background: #128c7e; font-size: 11px; font-weight: 850; }
.product-route-icon.vm { background: var(--brand); }
.product-route > div { min-width: 0; display: grid; flex: 1; }
.product-route small, .product-task small { color: var(--muted); font-size: 9px; font-weight: 750; text-transform: uppercase; letter-spacing: .06em; }
.product-route strong { font-size: 12px; }
.product-check { color: var(--teal); font-weight: 850; }
.product-status { padding: 4px 8px; border-radius: 99px; color: #08735f; background: #e5f8f1; font-size: 9px; font-weight: 800; }
.product-task { display: grid; gap: 3px; padding: 14px; border-radius: 13px; color: #e9eaff; background: #16192d; }
.product-task > strong { font-size: 13px; }
.product-task-meta { display: flex; gap: 6px; margin-top: 7px; }
.product-task-meta span { padding: 3px 7px; border: 1px solid #363b58; border-radius: 99px; color: #aeb3d0; font-size: 8px; }
.product-message { display: flex; align-items: flex-start; gap: 10px; padding: 11px 12px; border-radius: 13px; background: var(--brand-soft); }
.product-message .product-avatar { width: 28px; height: 28px; flex: 0 0 auto; display: block; border-radius: 9px; }
.product-message p { margin: 0; color: var(--ink); font-size: 10px; line-height: 1.5; }
.product-activity { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 9px; }
.workflow-strip { padding: 30px 22px 70px; background: var(--hero-end); }
.workflow-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin-bottom: 25px; }
.workflow-heading h2 { max-width: 680px; margin-bottom: 0; font-size: clamp(28px, 3.4vw, 42px); }
.workflow-heading p { max-width: 330px; margin: 0; color: var(--muted); }
.workflow-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: 0 16px 45px rgba(34,46,76,.06); }
.workflow-grid article { display: flex; gap: 14px; padding: 23px; }
.workflow-grid article + article { border-left: 1px solid var(--line); }
.workflow-grid article > span { color: var(--brand); font-size: 11px; font-weight: 850; }
.workflow-grid h3 { font-size: 15px; }
.workflow-grid p { margin: 0; color: var(--muted); font-size: 12px; }
.voice-section { padding-top: 74px; }
.voice-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: center; }
.voice-copy h2 { max-width: 560px; }
.voice-example {
  display: grid; gap: 8px; margin-top: 28px; padding: 18px 20px;
  border: 1px solid var(--line); border-radius: 16px; background: var(--surface);
  box-shadow: 0 12px 34px rgba(34,46,76,.07);
}
.voice-example span { color: var(--muted); text-transform: uppercase; letter-spacing: .08em; font-size: 10px; font-weight: 800; }
.voice-example code { color: var(--brand-dark); font: 600 14px/1.55 ui-monospace, SFMono-Regular, Consolas, monospace; overflow-wrap: anywhere; }
.voice-steps { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.voice-step { display: grid; grid-template-columns: 52px 1fr; gap: 16px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.voice-step-number { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 12px; color: var(--brand); background: var(--brand-soft); font-size: 11px; font-weight: 850; }
.voice-step h3 { margin: 0 0 5px; font-size: 16px; }
.voice-step p { margin: 0; color: var(--muted); font-size: 13px; }
.terminal {
  border-radius: 22px; overflow: hidden; color: #e5e7ff; background: #13162b;
  box-shadow: 0 34px 75px rgba(23,28,62,.28); transform: rotate(1.2deg);
}
.terminal-head { display: flex; align-items: center; gap: 7px; padding: 15px 18px; background: #1c2039; }
.terminal-dot { width: 9px; height: 9px; border-radius: 50%; background: #ff6c7d; }
.terminal-dot:nth-child(2) { background: #ffc45a; }
.terminal-dot:nth-child(3) { background: #55d69e; }
.terminal-title { margin-left: 8px; color: #9399b9; font: 12px ui-monospace, monospace; }
.terminal-body { padding: 25px; min-height: 315px; font: 14px/1.75 ui-monospace, SFMono-Regular, Consolas, monospace; }
.terminal-body .prompt { color: #9a94ff; }
.terminal-body .ok { color: #63ddb0; }
.terminal-card { margin: 18px 0; padding: 14px; border: 1px solid #323754; border-radius: 10px; background: #1a1e34; }
.section { padding: 92px 22px; }
.section.soft { background: var(--soft); }
.section-inner { max-width: 1180px; margin: auto; }
.section-heading { max-width: 720px; margin-bottom: 40px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.card-icon { width: 42px; height: 42px; display: grid; place-items: center; margin-bottom: 20px; border-radius: 12px; background: var(--brand-soft); color: var(--brand); font-weight: 800; }
.card p, .section-heading p { color: var(--muted); }
.showcase-grid { align-items: stretch; }
.showcase-card { display: flex; flex-direction: column; }
.showcase-glyph { width: 44px; height: 44px; display: grid; place-items: center; margin-bottom: 20px; border-radius: 13px; color: white; font-size: 17px; font-weight: 850; }
.whatsapp-glyph { background: #128c7e; }
.panel-glyph { background: var(--brand); }
.context-glyph { background: #b16d20; }
.showcase-flow { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 20px; color: var(--brand-dark); font-size: 10px; font-weight: 800; }
.showcase-flow span { padding: 4px 7px; border: 1px solid var(--line); border-radius: 99px; background: var(--soft); }
.showcase-flow i { color: var(--muted); font-style: normal; }
.security-panel { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: center; }
.check-list { list-style: none; padding: 0; margin: 24px 0 0; }
.check-list li { position: relative; padding: 8px 0 8px 30px; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--teal); font-weight: 900; }
.pricing-grid { max-width: 820px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; margin: auto; }
.price-card { position: relative; display: flex; flex-direction: column; }
.price-card.featured { border: 2px solid var(--brand); box-shadow: var(--shadow); }
.price-tag { margin: 12px 0 20px; font-size: 42px; font-weight: 780; letter-spacing: -.04em; }
.price-tag small { font-size: 14px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.price-card .button { margin-top: auto; }
.landing-cta { padding-top: 40px; }
.landing-cta-card { display: flex; align-items: center; justify-content: space-between; gap: 30px; padding: 34px 38px; border: 1px solid #d8d5ff; border-radius: 24px; background: linear-gradient(135deg, var(--brand-soft), var(--surface)); }
.landing-cta-card h2 { margin-bottom: 8px; }
.landing-cta-card p { max-width: 610px; margin: 0; color: var(--muted); }
.landing-cta-card .hero-actions { flex: 0 0 auto; margin: 0; }
.page { max-width: 1180px; min-height: calc(100vh - 72px); margin: auto; padding: 54px 22px 90px; }
.auth-page { max-width: 1000px; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(390px, .95fr); gap: 34px; align-items: center; }
.auth-card { border: 1px solid var(--line); border-radius: 22px; padding: 34px; box-shadow: var(--shadow); background: var(--surface-raised); }
.auth-card h1 { font-size: 35px; margin: 8px 0 12px; }
.auth-context { padding: 46px; border-radius: 26px; color: #f1f2ff; background: linear-gradient(145deg, #171a31, #28265d); box-shadow: 0 25px 65px rgba(23,28,62,.22); }
.auth-context .eyebrow { color: #9f9aff; }
.auth-context h2 { margin: 13px 0 14px; font-size: clamp(32px, 4vw, 48px); }
.auth-context > p { color: #b8bdd5; }
.auth-context ul { display: grid; gap: 9px; margin: 26px 0; padding: 0; list-style: none; color: #dfe1f2; font-size: 13px; }
.auth-context ul li::first-letter { color: #63ddb0; }
.auth-context-route { display: flex; align-items: center; gap: 9px; margin-top: 35px; }
.auth-context-route span { padding: 8px 10px; border: 1px solid #44486d; border-radius: 9px; background: rgba(255,255,255,.06); font-size: 10px; font-weight: 750; }
.auth-context-route i { color: #777ca4; font-style: normal; }
.form-stack { display: grid; gap: 16px; margin-top: 25px; }
.field { display: grid; gap: 7px; color: var(--ink); font-size: 14px; font-weight: 650; }
.field input, .field select, .field textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 11px 12px; color: var(--ink); background: var(--input);
}
.field textarea { min-height: 96px; resize: vertical; font: inherit; line-height: 1.5; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); outline: 3px solid rgba(99,91,255,.13); }
.checkbox { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-size: 13px; }
.checkbox input { margin-top: 4px; }
.divider { display: flex; align-items: center; gap: 12px; margin: 19px 0; color: var(--muted); font-size: 12px; }
.divider::before, .divider::after { content: ""; height: 1px; flex: 1; background: var(--line); }
.form-note { color: var(--muted); font-size: 13px; }
.form-error { padding: 11px 13px; border-radius: 9px; color: #98253a; background: #fff0f2; font-size: 13px; }
.app-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 36px; }
.app-sidebar { min-width: 0; display: grid; align-content: space-between; gap: 28px; position: sticky; top: 96px; min-height: calc(100vh - 150px); }
.side-nav { display: grid; align-content: start; gap: 5px; }
.side-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 9px; color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 650; }
.side-nav a > span { width: 19px; flex: 0 0 auto; color: #8a93a7; text-align: center; font-size: 14px; font-weight: 850; }
.side-nav a.active, .side-nav a:hover { color: var(--brand-dark); background: var(--brand-soft); }
.side-nav a.active > span, .side-nav a:hover > span { color: var(--brand); }
.side-nav-separator { height: 1px; margin: 7px 10px; background: var(--line); }
.side-account { min-width: 0; display: flex; align-items: center; gap: 10px; padding: 11px; border: 1px solid var(--line); border-radius: 13px; color: var(--ink); background: var(--surface); text-decoration: none; }
.side-account:hover { border-color: #bbb6ff; background: var(--brand-soft); }
.side-account > span:last-child { min-width: 0; display: grid; line-height: 1.25; }
.side-account small { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 9px; }
.app-head { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; margin-bottom: 28px; }
.app-head h1 { font-size: 38px; margin: 3px 0 8px; }
.badge { display: inline-flex; border-radius: 999px; padding: 5px 10px; background: var(--brand-soft); color: var(--brand-dark); font-size: 12px; font-weight: 750; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.stat { border: 1px solid var(--line); border-radius: 15px; padding: 20px; }
.stat-value { font-size: 27px; font-weight: 760; }
.stat-label { color: var(--muted); font-size: 13px; }
.usage-progress { width: 100%; height: 9px; margin-top: 12px; border: 0; border-radius: 99px; overflow: hidden; background: #e9ecf3; }
.usage-progress::-webkit-progress-bar { border-radius: 99px; background: #e9ecf3; }
.usage-progress::-webkit-progress-value { border-radius: 99px; background: linear-gradient(90deg, var(--brand), #8a84ff); }
.usage-progress::-moz-progress-bar { border-radius: 99px; background: linear-gradient(90deg, var(--brand), #8a84ff); }
.onboarding-card {
  margin-bottom: 24px; padding: 26px; overflow: hidden; border: 1px solid #d8d5ff;
  border-radius: var(--radius); background: linear-gradient(145deg, #faf9ff, #f4f7ff);
}
.onboarding-card.is-complete { border-color: #bce8da; background: linear-gradient(145deg, #f5fffb, #f7fbff); }
.onboarding-head { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; }
.onboarding-head h2 { margin: 7px 0 6px; font-size: 27px; }
.onboarding-head p { margin: 0; color: var(--muted); }
.progress-ring {
  width: 54px; height: 54px; flex: 0 0 auto; display: grid; place-items: center;
  border: 5px solid #dcd9ff; border-top-color: var(--brand); border-radius: 50%;
  color: var(--brand-dark); font-size: 13px; font-weight: 800;
}
.is-complete .progress-ring { border-color: #b9ead9; color: var(--teal); }
.onboarding-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 22px; }
.onboarding-step {
  min-width: 0; display: grid; grid-template-columns: 30px 1fr; gap: 10px;
  padding: 15px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface);
}
.onboarding-step.current {
  border-color: #aaa4ff;
  box-shadow: 0 10px 30px rgba(99,91,255,.11);
}
.step-number {
  width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%;
  background: #eef0f5; color: var(--muted); font-size: 12px; font-weight: 800;
}
.onboarding-step.current .step-number { color: white; background: var(--brand); }
.onboarding-step.complete .step-number { color: white; background: var(--teal); }
.step-title { font-size: 14px; font-weight: 760; }
.step-title span {
  display: inline-flex; margin-left: 4px; padding: 2px 7px; border-radius: 99px;
  color: var(--muted); background: var(--soft); font-size: 9px; letter-spacing: .04em; text-transform: uppercase;
}
.onboarding-step.complete .step-title span { color: #08735f; background: #e5f8f1; }
.onboarding-step p { min-height: 58px; margin: 5px 0 12px; color: var(--muted); font-size: 12px; }
.inline-phone-form { display: grid; gap: 10px; }
.inline-phone-form .field { font-size: 12px; }
.inline-phone-form input { padding: 9px 10px; background: var(--input); }
.inline-phone-form .button { width: 100%; }
.onboarding-action-stack { display: grid; gap: 8px; }
.first-value-recipes { grid-column: 1 / -1; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.first-value-recipes h3 { margin: 0 0 10px; font-size: 15px; }
.whatsapp-routing { display: grid; gap: 6px; }
.linked-number {
  display: inline-flex; width: fit-content; padding: 5px 9px; border-radius: 99px;
  color: #08735f; background: #e5f8f1; font-size: 11px; font-weight: 750;
}
.destination-number {
  display: inline-flex; width: fit-content; padding: 5px 9px; border-radius: 99px;
  color: var(--brand-dark); background: var(--brand-soft); font-size: 11px; font-weight: 750;
}
.compact-actions { display: flex; gap: 7px; flex-wrap: wrap; }
.whatsapp-button { border-color: #128c7e; background: #128c7e; }
.whatsapp-button:hover { border-color: #08776b; background: #08776b; }
.service-warning {
  padding: 9px 10px; border-radius: 9px; color: #7a4b07; background: #fff3d9; font-size: 11px;
}
.installing-note {
  padding: 9px 10px; border-radius: 9px; color: #08735f; background: #e5f8f1;
  font-size: 11px; font-weight: 700;
}
.locked-step { display: block; padding: 8px 10px; border-radius: 8px; background: var(--soft); }
.ready-card {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px;
  align-items: center; padding: 22px 24px;
}
.ready-status {
  width: 48px; height: 48px; display: grid; place-items: center; border-radius: 15px;
  background: #e5f8f1;
}
.ready-status span {
  width: 13px; height: 13px; border-radius: 50%; background: var(--teal);
  box-shadow: 0 0 0 6px rgba(10,143,122,.13);
}
.ready-copy h2 { margin: 3px 0 4px; font-size: 23px; }
.ready-copy p { margin: 0; color: var(--muted); font-size: 13px; }
.ready-destination { display: block; margin-top: 5px; color: #08735f; font-size: 12px; font-weight: 750; }
.ready-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.table-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.table-head { display: flex; justify-content: space-between; gap: 20px; padding: 20px; border-bottom: 1px solid var(--line); }
.vm-list { display: grid; }
.vm-row { display: flex; align-items: center; gap: 15px; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.vm-row:last-child { border: 0; }
.vm-meta { min-width: 0; flex: 1; }
.vm-name { font-weight: 750; }
.vm-detail { color: var(--muted); font-size: 12px; }
.vm-card { padding: 20px; border-bottom: 1px solid var(--line); }
.vm-card:last-child { border-bottom: 0; }
.vm-card-top { display: flex; align-items: flex-start; gap: 14px; }
.vm-card .status-dot { margin-top: 7px; }
.vm-technical { margin-top: 6px; color: var(--muted); font-size: 11px; overflow-wrap: anywhere; }
.vm-error { display: inline-flex; margin-top: 9px; padding: 6px 9px; border-radius: 8px; color: #98253a; background: #fff0f2; font-size: 11px; }
.vm-install-progress {
  display: grid; gap: 5px; margin-top: 10px; padding: 10px 12px; max-width: 660px;
  border: 1px solid #cfe7df; border-radius: 10px; color: #24584e; background: #f2fbf8;
  font-size: 11px;
}
.vm-install-progress strong { color: #08735f; font-size: 12px; }
.connector-update { border-color: #e8d3a1; color: #674d17; background: #fff9ea; }
.connector-update strong { color: #855f0b; }
.vm-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.status-dot.awaiting_install { background: #e99a2b; box-shadow: 0 0 0 4px #fff2dc; }
.status-dot.error { background: var(--danger); box-shadow: 0 0 0 4px #ffeaee; }
.permission-control { margin: 18px 0 0 23px; padding: 15px; border-radius: 12px; background: var(--soft); }
.permission-title { display: block; margin-bottom: 9px; font-size: 12px; font-weight: 750; }
.permission-options { display: inline-grid; grid-template-columns: repeat(3, auto); gap: 4px; margin-bottom: 7px; padding: 4px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.permission-options label { cursor: pointer; }
.permission-options input { position: absolute; opacity: 0; pointer-events: none; }
.permission-options span { display: block; padding: 7px 10px; border-radius: 7px; color: var(--muted); font-size: 11px; font-weight: 700; }
.permission-options label.selected span { color: white; background: var(--brand); }
.permission-control > .form-note { display: block; margin-top: 3px; }
.status-dot { width: 9px; height: 9px; flex: 0 0 auto; border-radius: 50%; background: #aeb6c5; }
.status-dot.connected { background: #24a982; box-shadow: 0 0 0 4px #e0f7f0; }
.empty { padding: 46px 20px; text-align: center; color: var(--muted); }
.empty strong { display: block; color: var(--ink); font-size: 17px; margin-bottom: 5px; }
.empty p { max-width: 460px; margin: 6px auto 18px; }
.empty-icon {
  width: 42px; height: 42px; display: grid; place-items: center; margin: 0 auto 13px;
  border-radius: 13px; color: var(--brand-dark); background: var(--brand-soft); font-size: 20px; font-weight: 800;
}
.tasks-head { align-items: end; }
.tasks-head-actions { display: flex; align-items: end; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.tasks-machine { min-width: 220px; text-align: left; }
.tasks-machine select { padding-block: 10px; }
.task-live-note {
  display: flex; align-items: center; gap: 10px; margin: -10px 0 20px; padding: 11px 14px;
  border: 1px solid var(--line); border-radius: 11px; color: var(--muted); background: var(--soft);
  font-size: 12px;
}
.task-live-copy { min-width: 0; }
.task-live-state {
  flex: 0 0 auto; margin-left: auto; padding: 5px 9px; border-radius: 99px;
  color: #5c6372; background: #e8ebf0; font-size: 9px; font-weight: 800;
  letter-spacing: .02em; white-space: nowrap;
}
.task-live-state.connected { color: #08735f; background: #dff7ef; }
.task-live-state.fallback { color: #83520a; background: #fff0d6; }
.task-preferences-panel {
  min-width: 0; margin-bottom: 18px; padding: 17px 18px;
  border: 1px solid #d8d5ff; border-radius: var(--radius); background: #faf9ff;
}
.task-preferences-copy {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 22px; margin-bottom: 14px;
}
.task-preferences-copy p { max-width: 670px; margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.task-preferences-note { max-width: 300px; color: #5c54a7; font-size: 10px; line-height: 1.5; text-align: right; }
.task-preferences-form {
  display: grid; grid-template-columns: minmax(150px, 1fr) minmax(130px, .75fr) minmax(170px, 1fr) auto;
  align-items: end; gap: 10px;
}
.task-preferences-form .field { min-width: 0; }
.task-preferences-form select { min-width: 0; padding-block: 10px; }
.task-preferences-save { min-height: 40px; white-space: nowrap; }
.task-full-access {
  grid-column: 1 / -1; padding: 13px 14px; border: 1px solid #e9b8c1;
  border-radius: 11px; color: #7d2637; background: #fff3f5;
}
.task-full-access p { margin: 5px 0 9px; font-size: 11px; line-height: 1.5; }
.task-full-access label { display: flex; align-items: flex-start; gap: 7px; font-size: 11px; font-weight: 700; line-height: 1.45; cursor: pointer; }
.task-full-access input { margin-top: 2px; accent-color: var(--danger); }
.task-preferences-error { margin: 0; }
.task-workspace {
  min-width: 0; display: grid; grid-template-columns: minmax(290px, .75fr) minmax(0, 1.25fr);
  gap: 18px; align-items: start;
}
.task-list-panel, .task-detail-panel {
  min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface);
}
.task-list { display: grid; align-content: start; max-height: calc(100vh - 230px); min-height: 300px; overflow-y: auto; }
.task-row {
  position: relative; display: grid; gap: 8px; width: 100%; min-width: 0; padding: 18px 19px;
  border: 0; border-bottom: 1px solid var(--line); color: var(--ink); background: var(--surface);
  text-align: left; cursor: pointer; transition: background .15s ease, box-shadow .15s ease;
}
.task-row:last-child { border-bottom: 0; }
.task-row:hover { background: #fafaff; }
.task-row.selected { z-index: 1; background: var(--brand-soft); box-shadow: inset 3px 0 var(--brand); }
.task-row-top { min-width: 0; display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.task-row-top strong { min-width: 0; overflow-wrap: anywhere; font-size: 14px; line-height: 1.35; }
.task-row p {
  display: -webkit-box; margin: 0; overflow: hidden; color: var(--muted); font-size: 12px;
  line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2;
}
.task-row-meta { display: flex; flex-wrap: wrap; gap: 8px 12px; color: var(--muted); font-size: 10px; }
.task-open-label { color: var(--brand-dark); font-size: 11px; font-weight: 750; }
.task-status, .task-active {
  display: inline-flex; width: fit-content; flex: 0 0 auto; align-items: center; border-radius: 99px;
  padding: 4px 8px; font-size: 9px; font-weight: 800; letter-spacing: .025em; text-transform: uppercase;
}
.task-status { color: #566078; background: #edf0f5; }
.task-status.ready, .task-status.completed, .task-status.idle { color: #08735f; background: #e5f8f1; }
.task-status.working, .task-status.inProgress, .task-status.active { color: #3e35bd; background: #ebe9ff; }
.task-status.waiting_approval, .task-status.waiting_input, .task-status.queued { color: #83520a; background: #fff0d6; }
.task-status.failed { color: #98253a; background: #fff0f2; }
.task-status.cancelled, .task-status.interrupted, .task-status.declined { color: #5d6574; background: #eceef2; }
.task-active { color: #08735f; background: #e5f8f1; text-transform: none; letter-spacing: 0; }
.task-pagination {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 57px;
  padding: 10px 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px;
}
.task-detail-panel { min-height: 500px; padding: 24px; }
.task-detail-empty, .task-page-empty { min-height: 360px; display: grid; align-content: center; }
.task-detail-head { display: flex; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.task-detail-head h2 { margin: 8px 0 5px; font-size: clamp(25px, 3vw, 33px); overflow-wrap: anywhere; }
.task-detail-badges { display: flex; gap: 7px; flex-wrap: wrap; }
.task-latest { padding: 20px; border: 1px solid #d8d5ff; border-radius: 14px; background: #faf9ff; }
.task-latest.muted { border-color: var(--line); background: var(--soft); }
.task-latest p, .task-message p {
  margin: 8px 0 0; overflow-wrap: anywhere; white-space: pre-wrap; font-size: 13px; line-height: 1.65;
}
.task-instruction-form {
  display: grid; gap: 12px; margin-top: 14px; padding: 16px;
  border: 1px solid var(--line); border-radius: 13px; background: var(--surface);
}
.task-attachment-tools { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.task-attachment-picker { position: relative; overflow: hidden; cursor: pointer; }
.task-attachment-picker input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.task-attachment-name { min-width: 0; max-width: min(100%, 420px); overflow: hidden; color: var(--ink); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.task-attachment-help { margin: -4px 0 0; }
.task-instruction-actions { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.task-instruction-actions > span { max-width: 66%; color: var(--muted); font-size: 10px; line-height: 1.45; }
.task-section-label { color: var(--muted); font-size: 10px; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.timeline-label { margin: 28px 0 10px; }
.task-continue {
  display: flex; align-items: center; gap: 14px; margin-top: 14px; padding: 14px;
  border: 1px solid #cfe7df; border-radius: 13px; background: #f3fbf8;
}
.task-continue span { color: #45645d; font-size: 11px; line-height: 1.45; }
.task-turn { margin-top: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; }
.task-turn-head { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 12px; font-size: 12px; font-weight: 800; }
.task-message { margin-top: 10px; padding: 13px 14px; border-radius: 11px; background: var(--soft); }
.task-message.user { margin-left: 7%; background: var(--brand-soft); }
.task-message.agent { margin-right: 7%; background: #f2fbf8; }
.task-message.plan { border-left: 3px solid var(--brand); }
.task-message strong { font-size: 11px; }
.task-execution { margin-top: 10px; overflow: hidden; border: 1px solid #dfe3eb; border-radius: 11px; }
.task-execution > summary {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px;
  background: #f7f8fb; cursor: pointer; font-size: 12px; font-weight: 800;
}
.task-execution > pre { margin: 0; border-radius: 0; }
.task-execution-meta { padding: 8px 14px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 10px; }
.task-execution > .task-section-label { display: block; padding: 12px 14px 0; }
.task-execution > .form-note { display: block; padding: 2px 14px 13px; }
.task-output {
  max-height: 420px; margin: 9px 14px 14px !important; border-radius: 9px !important;
  white-space: pre-wrap; overflow-wrap: anywhere;
}
.task-file-change { padding: 13px 14px; border-top: 1px solid var(--line); }
.task-file-change > div { display: flex; justify-content: space-between; gap: 12px; font-size: 11px; }
.task-file-change strong { overflow-wrap: anywhere; }
.task-file-change span { color: var(--muted); }
.task-timeline-empty { padding: 22px; }
.task-list-empty { min-height: 300px; display: grid; align-content: center; }
.task-load-error { margin: 18px; }
.page-loading.compact { min-height: 200px; }
.channel-head { align-items: end; }
.channel-head p { max-width: 720px; }
.channel-health {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 16px;
  margin-bottom: 20px; padding: 20px 22px; border: 1px solid #cfe7df; border-radius: var(--radius); background: #f3fbf8;
}
.channel-health.offline { border-color: #ead6b4; background: #fff8eb; }
.channel-health-icon { width: 43px; height: 43px; display: grid; place-items: center; border-radius: 13px; color: #08735f; background: #dff7ef; font-size: 18px; font-weight: 850; }
.channel-health.offline .channel-health-icon { color: #83520a; background: #fff0d6; }
.channel-health h2 { margin: 0 0 3px; font-size: 19px; }
.channel-health p { margin: 0; color: var(--muted); font-size: 12px; }
.channel-status { display: inline-flex; width: fit-content; align-items: center; gap: 7px; padding: 6px 9px; border-radius: 99px; font-size: 10px; font-weight: 800; }
.channel-status i { width: 7px; height: 7px; border-radius: 50%; }
.channel-status.online, .channel-status.verified { color: #08735f; background: #dff7ef; }
.channel-status.online i { background: #24a982; }
.channel-status.offline { color: #83520a; background: #fff0d6; }
.channel-status.offline i { background: #d58a1f; }
.channel-status.waiting { color: #5c54a7; background: var(--brand-soft); }
.channel-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.channel-card { display: flex; min-width: 0; flex-direction: column; }
.channel-card-head { display: flex; align-items: flex-start; gap: 12px; }
.channel-card-head h2 { margin: 0 0 6px; font-size: 22px; }
.channel-card-head p { margin: 0; color: var(--muted); font-size: 12px; }
.channel-number-step { width: 28px; height: 28px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 9px; color: var(--brand); background: var(--brand-soft); font-size: 11px; font-weight: 850; }
.phone-input { display: flex; align-items: center; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--input); }
.phone-input:focus-within { border-color: var(--brand); outline: 3px solid rgba(99,91,255,.13); }
.phone-input > span { padding-left: 12px; color: var(--muted); }
.phone-input input { border: 0; outline: 0 !important; }
.channel-verification { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; margin-top: 18px; padding-top: 17px; border-top: 1px solid var(--line); }
.channel-verification small { color: var(--muted); }
.authorized-sender-list { display: grid; gap: 9px; margin-top: 22px; }
.authorized-sender-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 10px; padding: 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--soft); }
.authorized-sender-avatar { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: var(--brand); background: var(--brand-soft); font-size: 12px; font-weight: 850; }
.authorized-sender-row > div { min-width: 0; display: grid; gap: 2px; }
.authorized-sender-row strong, .authorized-sender-row small { overflow-wrap: anywhere; }
.authorized-sender-row small { color: var(--muted); font-size: 10px; }
.authorized-senders-empty { padding: 18px; border: 1px dashed var(--line); border-radius: 12px; color: var(--muted); background: var(--soft); font-size: 12px; }
.authorized-sender-form { margin-top: 17px; padding-top: 17px; border-top: 1px solid var(--line); }
.gateway-phone { display: flex; align-items: center; gap: 12px; margin: 26px 0 17px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--soft); }
.whatsapp-glyph { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 14px; color: white; background: #128c7e; font-size: 13px; font-weight: 850; }
.gateway-phone > div { min-width: 0; display: grid; }
.gateway-phone small { color: var(--muted); font-size: 9px; font-weight: 800; letter-spacing: .07em; }
.gateway-phone strong { overflow-wrap: anywhere; font-size: 20px; letter-spacing: -.02em; }
.gateway-empty { display: grid; justify-items: start; gap: 13px; margin: 25px 0 15px; padding: 20px; border: 1px dashed var(--line); border-radius: 14px; background: var(--soft); }
.gateway-empty p { max-width: 420px; margin: 0; color: var(--muted); font-size: 12px; }
.gateway-linking { display: flex; align-items: center; gap: 13px; margin: 25px 0 17px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--soft); }
.gateway-linking div { display: grid; gap: 3px; }
.gateway-linking p { margin: 0; color: var(--muted); font-size: 11px; }
.gateway-qr { display: grid; grid-template-columns: 190px 1fr; align-items: center; gap: 22px; margin: 23px 0 17px; padding: 17px; border: 1px solid var(--line); border-radius: 15px; background: #fff; color: #182031; }
.gateway-qr img { display: block; width: 190px; height: 190px; border-radius: 8px; }
.gateway-qr h3 { margin: 0 0 7px; font-size: 18px; }
.gateway-qr p { margin: 0 0 13px; color: #596278; font-size: 12px; line-height: 1.55; }
.linking-pulse { display: inline-flex; align-items: center; gap: 7px; color: #08735f; font-size: 10px; font-weight: 800; }
.linking-pulse i { width: 8px; height: 8px; border-radius: 50%; background: #24a982; box-shadow: 0 0 0 5px rgba(36,169,130,.14); animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .45; transform: scale(.8); } }
.channel-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.disabled-link { opacity: .45; pointer-events: none; }
.managed-channel-note { margin: auto 0 0; padding-top: 18px; color: var(--muted) !important; font-size: 10px !important; line-height: 1.55; }
.same-number-callout { display: flex; gap: 14px; margin-top: 18px; padding: 16px 18px; border: 1px solid #d8d5ff; border-radius: 14px; background: var(--brand-soft); }
.same-number-callout > span { color: var(--brand); font-size: 20px; font-weight: 850; }
.same-number-callout p { margin: 3px 0 0; color: var(--muted); font-size: 12px; }
.channel-flow { margin-top: 30px; }
.channel-flow > h2 { margin-bottom: 18px; font-size: 25px; }
.channel-flow-grid { display: grid; grid-template-columns: repeat(3, 1fr); overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); }
.channel-flow-grid article { display: flex; gap: 11px; padding: 20px; background: var(--surface); }
.channel-flow-grid article + article { border-left: 1px solid var(--line); }
.channel-flow-grid article > span { width: 26px; height: 26px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 8px; color: var(--brand); background: var(--brand-soft); font-size: 10px; font-weight: 850; }
.channel-flow-grid h3 { margin: 2px 0 5px; font-size: 14px; }
.channel-flow-grid p { margin: 0; color: var(--muted); font-size: 11px; }
.settings-card { max-width: 720px; }
.settings-card + .settings-card { margin-top: 20px; }
.profile-channel-card { display: flex; align-items: center; justify-content: space-between; gap: 22px; }
.profile-channel-card h3 { margin-top: 5px; }
.profile-channel-card p { margin: 0; }
.security-vm-list { margin: 18px -24px -24px; border-top: 1px solid var(--line); }
.security-vm-list .vm-card:last-child { border-bottom: 0; }
.danger-zone { border-color: #f0c7ce; }
.docs-layout { display: grid; grid-template-columns: 220px minmax(0, 760px); gap: 52px; }
.docs-nav { display: grid; align-content: start; gap: 8px; position: sticky; top: 100px; }
.docs-nav a { font-size: 14px; text-decoration: none; color: var(--muted); }
.docs-content h1 { font-size: 44px; }
.docs-content h2 { font-size: 28px; margin-top: 50px; }
pre { position: relative; overflow-x: auto; padding: 19px; border-radius: 13px; background: #15182b; color: #e5e7f6; font: 13px/1.65 ui-monospace, monospace; }
code { overflow-wrap: anywhere; }
.callout { border-left: 4px solid var(--brand); padding: 15px 18px; border-radius: 0 10px 10px 0; background: var(--brand-soft); }
.spaced-callout { margin-bottom: 20px; }
.legal-card { margin-top: 28px; }
.paywall { max-width: 720px; margin: 40px auto; text-align: center; }
.paywall .card { padding: 48px; box-shadow: var(--shadow); }
.paywall .check-list { text-align: left; }
.paywall .hero-actions { justify-content: center; }
.page-loading { min-height: calc(100vh - 72px); display: flex; align-items: center; justify-content: center; gap: 10px; color: var(--muted); }
.spinner { width: 18px; height: 18px; border: 2px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.toast { position: fixed; z-index: 50; right: 22px; bottom: 22px; max-width: 390px; padding: 13px 16px; border-radius: 10px; color: white; background: #222a3b; box-shadow: var(--shadow); }
dialog {
  width: min(600px, calc(100vw - 30px)); max-height: calc(100dvh - 30px);
  overflow-y: auto; overscroll-behavior: contain; border: 0; border-radius: 20px;
  padding: 0; box-shadow: var(--shadow);
}
dialog::backdrop { background: rgba(18,24,42,.55); backdrop-filter: blur(2px); }
.dialog-card { padding: 30px; }
.dialog-card h2 { font-size: 31px; }
.secret-row { display: flex; align-items: center; gap: 10px; margin: 22px 0; padding: 13px; border: 1px solid var(--line); border-radius: 10px; background: var(--soft); }
.secret-row code { flex: 1; min-width: 0; font-size: 12px; }
.dialog-actions { display: flex; justify-content: flex-end; }
.split-actions { justify-content: space-between; margin-top: 24px; }
.install-steps { display: grid; gap: 18px; margin: 24px 0; padding-left: 22px; }
.install-steps li { padding-left: 6px; }
.install-steps strong { font-size: 14px; }
.install-steps .secret-row { margin: 8px 0 4px; }
.preflight-box {
  margin: 18px 0 4px; padding: 14px 16px; border: 1px solid #cfe7df;
  border-radius: 12px; color: #24584e; background: #f2fbf8; font-size: 12px;
}
.preflight-box strong { font-size: 13px; }
.preflight-box ul { margin: 7px 0 0; padding-left: 18px; }
.preflight-box li + li { margin-top: 3px; }
.command-row {
  display: flex; align-items: center; gap: 9px; margin-top: 8px; padding: 12px;
  border-radius: 10px; color: #e5e7f6; background: #15182b;
}
.command-row code { min-width: 0; flex: 1; font-size: 11px; overflow-wrap: anywhere; }
.connection-wait { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 10px; color: var(--brand-dark); background: var(--brand-soft); font-size: 13px; }
.connection-wait.accepted { color: #08735f; background: #e5f8f1; }
.connection-wait.connected { color: #08735f; background: #e5f8f1; }
.connection-wait.connected .spinner { display: none; }
.connection-wait.error { color: #8f2639; background: #fff0f2; }
.connection-wait.error .spinner { display: none; }
.connector-diagnostic {
  margin-top: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--soft);
}
.connector-diagnostic p { margin: 0; color: var(--muted); font-size: 11px; }
.connector-diagnostic .command-row { margin-top: 8px; }
.security-note { margin: 12px 0 22px; padding-left: 22px; color: var(--muted); font-size: 12px; }
.security-note::before { content: "✓"; margin-left: -20px; margin-right: 8px; color: var(--teal); font-weight: 900; }
footer { padding: 36px 22px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.footer-inner { max-width: 1180px; display: flex; justify-content: space-between; margin: auto; }

html[data-theme="dark"] {
  color-scheme: dark;
  --ink: #f3f6fc;
  --muted: #a4aec1;
  --line: #2a3548;
  --soft: #161f2e;
  --paper: #0b111b;
  --surface: #111927;
  --surface-raised: #151e2d;
  --input: #0d1521;
  --header: rgba(11,17,27,.92);
  --hero-start: #101624;
  --hero-end: #0b111b;
  --brand: #8c86ff;
  --brand-dark: #b3afff;
  --brand-soft: #242449;
  --teal: #4bd1ae;
  --warn: #ffc065;
  --danger: #ff8195;
  --shadow: 0 20px 60px rgba(0,0,0,.34);
}
html[data-theme="dark"] .site-header { border-bottom-color: rgba(42,53,72,.88); }
html[data-theme="dark"] .language-control select { color: var(--muted); }
html[data-theme="dark"] .theme-toggle:hover { border-color: #6762bd; }
html[data-theme="dark"] .button.danger { color: #ff9bad; border-color: #683746; background: #2d1821; }
html[data-theme="dark"] .hero { background:
  radial-gradient(circle at 78% 18%, rgba(140,134,255,.18), transparent 27%),
  radial-gradient(circle at 20% 72%, rgba(75,209,174,.08), transparent 25%),
  linear-gradient(180deg, var(--hero-start), var(--hero-end));
}
html[data-theme="dark"] .product-preview { border-color: #393a6f; box-shadow: 0 34px 75px rgba(0,0,0,.4); }
html[data-theme="dark"] .product-status,
html[data-theme="dark"] .linked-number,
html[data-theme="dark"] .installing-note,
html[data-theme="dark"] .task-status.ready,
html[data-theme="dark"] .task-status.completed,
html[data-theme="dark"] .task-status.idle,
html[data-theme="dark"] .task-active,
html[data-theme="dark"] .channel-status.online,
html[data-theme="dark"] .channel-status.verified,
html[data-theme="dark"] .connection-wait.accepted,
html[data-theme="dark"] .connection-wait.connected { color: #70dfc0; background: #14342e; }
html[data-theme="dark"] .onboarding-card { border-color: #3d3c6e; background: linear-gradient(145deg, #191a33, #141d2d); }
html[data-theme="dark"] .onboarding-card.is-complete { border-color: #245647; background: linear-gradient(145deg, #112a25, #131e2a); }
html[data-theme="dark"] .progress-ring { border-color: #35355f; }
html[data-theme="dark"] .is-complete .progress-ring { border-color: #245647; }
html[data-theme="dark"] .step-number { background: #263043; }
html[data-theme="dark"] .onboarding-step.complete .step-title span,
html[data-theme="dark"] .ready-status { color: #70dfc0; background: #14342e; }
html[data-theme="dark"] .service-warning,
html[data-theme="dark"] .task-live-state.fallback,
html[data-theme="dark"] .task-status.waiting_approval,
html[data-theme="dark"] .task-status.waiting_input,
html[data-theme="dark"] .task-status.queued,
html[data-theme="dark"] .channel-status.offline,
html[data-theme="dark"] .channel-health.offline .channel-health-icon { color: #ffd18e; background: #3b2c17; }
html[data-theme="dark"] .form-error,
html[data-theme="dark"] .vm-error,
html[data-theme="dark"] .task-status.failed,
html[data-theme="dark"] .connection-wait.error { color: #ff9bad; background: #351c25; }
html[data-theme="dark"] .task-preferences-panel,
html[data-theme="dark"] .task-latest { border-color: #3b3a69; background: #191a32; }
html[data-theme="dark"] .task-preferences-note { color: #bbb7ff; }
html[data-theme="dark"] .task-full-access { border-color: #683746; color: #ff9bad; background: #2d1821; }
html[data-theme="dark"] .task-row:hover { background: #171f30; }
html[data-theme="dark"] .task-status { color: #b4bed0; background: #273143; }
html[data-theme="dark"] .task-status.working,
html[data-theme="dark"] .task-status.inProgress,
html[data-theme="dark"] .task-status.active { color: #bcb8ff; background: #292751; }
html[data-theme="dark"] .task-status.cancelled,
html[data-theme="dark"] .task-status.interrupted,
html[data-theme="dark"] .task-status.declined,
html[data-theme="dark"] .task-live-state { color: #b4bed0; background: #273143; }
html[data-theme="dark"] .task-continue,
html[data-theme="dark"] .task-message.agent,
html[data-theme="dark"] .preflight-box,
html[data-theme="dark"] .vm-install-progress,
html[data-theme="dark"] .channel-health { border-color: #245647; background: #112a25; }
html[data-theme="dark"] .connector-update { border-color: #5a4427; color: #f1d59a; background: #2a2114; }
html[data-theme="dark"] .connector-update strong { color: #ffd18e; }
html[data-theme="dark"] .task-continue span,
html[data-theme="dark"] .preflight-box,
html[data-theme="dark"] .vm-install-progress { color: #9ccfc1; }
html[data-theme="dark"] .task-execution { border-color: var(--line); }
html[data-theme="dark"] .task-execution > summary { background: #182130; }
html[data-theme="dark"] .voice-example code { color: #bcb8ff; }
html[data-theme="dark"] .channel-health.offline { border-color: #5a4427; background: #2a2114; }
html[data-theme="dark"] .channel-health-icon { color: #70dfc0; background: #14342e; }
html[data-theme="dark"] .same-number-callout { border-color: #3b3a69; }
html[data-theme="dark"] dialog { color: var(--ink); background: var(--surface-raised); }
html[data-theme="dark"] .command-row,
html[data-theme="dark"] pre { background: #090e17; }
html[data-theme="dark"] .status-dot.connected { box-shadow: 0 0 0 4px #14342e; }
html[data-theme="dark"] .status-dot.awaiting_install { box-shadow: 0 0 0 4px #3b2c17; }
html[data-theme="dark"] .status-dot.error { box-shadow: 0 0 0 4px #351c25; }

@media (max-width: 900px) {
  .main-nav { display: none; }
  .site-header { padding: 0 16px; gap: 12px; }
  .header-actions { margin-left: auto; }
  .header-actions .button.ghost.auth-out { display: none; }
  .header-user { width: 42px; padding: 5px; }
  .header-user-copy { display: none; }
  .hero-grid, .security-panel, .voice-grid { grid-template-columns: 1fr; }
  .terminal, .product-preview { transform: none; }
  .workflow-heading { display: grid; gap: 10px; }
  .workflow-grid { grid-template-columns: 1fr; }
  .workflow-grid article + article { border-left: 0; border-top: 1px solid var(--line); }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .app-layout, .docs-layout, .auth-page { grid-template-columns: 1fr; }
  .auth-page { max-width: 680px; }
  .onboarding-steps { grid-template-columns: 1fr; }
  .onboarding-step p { min-height: 0; }
  .ready-card { grid-template-columns: auto 1fr; }
  .ready-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .app-sidebar { position: sticky; top: 72px; z-index: 12; display: block; min-height: 0; margin: -12px -22px 20px; }
  .side-nav, .docs-nav {
    position: sticky; top: 72px; z-index: 12; display: flex; overflow-x: auto;
    margin: -12px -22px 20px; padding: 10px 22px;
    border-bottom: 1px solid rgba(220,226,236,.9);
    background: var(--header); scrollbar-width: thin;
    box-shadow: 0 8px 18px rgba(34,46,76,.04);
  }
  .app-sidebar .side-nav { position: static; margin: 0; }
  .side-nav-separator, .side-account { display: none; }
  .side-nav a, .docs-nav a { flex: 0 0 auto; white-space: nowrap; }
  .channel-grid { grid-template-columns: 1fr; }
  .channel-flow-grid { grid-template-columns: 1fr; }
  .channel-flow-grid article + article { border-left: 0; border-top: 1px solid var(--line); }
  .task-preferences-form { grid-template-columns: 1fr 1fr; }
  .task-preferences-save { width: fit-content; }
  .landing-cta-card { align-items: flex-start; flex-direction: column; }
  .landing-cta-card .hero-actions { margin-top: 2px; }
  .task-workspace { grid-template-columns: 1fr; }
  .task-list { max-height: 520px; }
}

@media (max-width: 620px) {
  .site-header .brand span:last-child { display: none; }
  .header-actions { gap: 5px; }
  .header-actions .button { padding: 8px 10px; }
  .hero { padding-top: 62px; }
  .hero-grid { gap: 42px; }
  .product-preview-body { padding: 13px; }
  .hero-trust { display: grid; }
  .workflow-strip { padding: 22px 16px 52px; }
  .workflow-grid article { padding: 18px; }
  .grid-3, .pricing-grid, .stats { grid-template-columns: 1fr; }
  .section { padding: 65px 18px; }
  .landing-cta { padding-top: 18px; }
  .landing-cta-card { padding: 25px 21px; }
  .landing-cta-card .hero-actions { width: 100%; }
  .landing-cta-card .hero-actions .button { flex: 1; }
  .page { padding: 35px 16px 70px; }
  .app-sidebar { margin-inline: -16px; }
  .side-nav, .docs-nav { margin-inline: -16px; padding-inline: 16px; }
  .app-sidebar .side-nav { margin-inline: 0; }
  .auth-context { display: none; }
  .auth-card { padding: 24px; }
  .app-head { display: grid; }
  .tasks-head-actions { display: grid; width: 100%; grid-template-columns: 1fr 1fr; }
  .tasks-machine { min-width: 0; grid-column: 1 / -1; }
  .task-live-note { align-items: flex-start; flex-wrap: wrap; }
  .task-live-state { width: fit-content; margin-left: 19px; }
  .task-preferences-copy { display: grid; gap: 8px; }
  .task-preferences-note { max-width: none; text-align: left; }
  .task-preferences-form { grid-template-columns: 1fr; }
  .task-preferences-save { width: 100%; }
  .task-detail-panel { padding: 16px; }
  .task-list { min-height: 180px; }
  .task-continue { align-items: stretch; flex-direction: column; }
  .task-instruction-actions { align-items: stretch; flex-direction: column; }
  .task-instruction-actions > span { max-width: none; }
  .task-message.user, .task-message.agent { margin-inline: 0; }
  .task-row-top { display: grid; }
  .task-file-change > div { display: grid; }
  .vm-row { align-items: flex-start; flex-wrap: wrap; }
  .vm-card-top { flex-wrap: wrap; }
  .vm-actions { width: 100%; justify-content: flex-start; padding-left: 23px; }
  .permission-options { width: 100%; grid-template-columns: 1fr; }
  .permission-control { margin-left: 0; }
  .onboarding-head { align-items: center; }
  .ready-card { grid-template-columns: 1fr; }
  .ready-status { width: 42px; height: 42px; }
  .ready-actions { grid-column: auto; display: grid; }
  .channel-head { align-items: stretch; }
  .channel-health { grid-template-columns: auto minmax(0, 1fr); }
  .channel-health > .channel-status { grid-column: 2; }
  .channel-card { padding: 20px; }
  .authorized-sender-row { grid-template-columns: auto minmax(0, 1fr) auto; }
  .authorized-sender-row .channel-status { display: none; }
  .gateway-qr { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .gateway-qr img { width: min(220px, 100%); height: auto; aspect-ratio: 1; }
  .channel-actions { display: grid; }
  .profile-channel-card { align-items: stretch; flex-direction: column; }
  .dialog-card { padding: 24px 18px; }
  .dialog-card h2 { font-size: 27px; }
  .install-steps { padding-left: 20px; }
  .command-row, .secret-row { align-items: stretch; flex-direction: column; }
  .footer-inner { display: grid; gap: 8px; }
}
