/* ==========================================================================
   REVID — Design Tokens
   Palette: industrial charcoal + safety-orange accent (automotive/garage feel)
   ========================================================================== */

:root,
[data-theme='light'] {
  --color-bg: #f4f1ec;
  --color-surface: #ffffff;
  --color-surface-2: #fbf9f5;
  --color-surface-offset: #ece7dd;
  --color-divider: #ddd6c8;
  --color-border: #d2c9b8;

  --color-text: #1c1a16;
  --color-text-muted: #6b6455;
  --color-text-faint: #7a7057;
  --color-text-inverse: #fbf8f2;

  --color-primary: #d9560c;
  --color-primary-hover: #b8480a;
  --color-primary-active: #963c08;
  --color-primary-highlight: #f6ddc9;

  --color-success: #3f7a3a;
  --color-success-hover: #305e2c;
  --color-success-highlight: #d9e8d3;

  --color-warning: #b8860b;
  --color-warning-hover: #966d08;
  --color-warning-highlight: #f0e0b0;

  --color-error: #b3261e;
  --color-error-hover: #8f1e17;
  --color-error-highlight: #f3d6d3;

  --radius-sm: 0.4rem;
  --radius-md: 0.7rem;
  --radius-lg: 1.1rem;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px rgba(28, 26, 22, 0.06);
  --shadow-md: 0 6px 18px rgba(28, 26, 22, 0.09);
  --shadow-lg: 0 16px 40px rgba(28, 26, 22, 0.14);

  --font-display: 'Cabinet Grotesk', 'General Sans', sans-serif;
  --font-body: 'General Sans', 'Helvetica Neue', sans-serif;
}

[data-theme='dark'] {
  --color-bg: #17140f;
  --color-surface: #1e1a14;
  --color-surface-2: #221d16;
  --color-surface-offset: #29231a;
  --color-divider: #342c20;
  --color-border: #3d3325;

  --color-text: #f1ece1;
  --color-text-muted: #b3a790;
  --color-text-faint: #7a7057;
  --color-text-inverse: #1c1a16;

  --color-primary: #ef7b2e;
  --color-primary-hover: #f5934f;
  --color-primary-active: #f8a86c;
  --color-primary-highlight: #4a3420;

  --color-success: #79c26e;
  --color-success-hover: #93d189;
  --color-success-highlight: #2b3d24;

  --color-warning: #e0b843;
  --color-warning-hover: #ecc866;
  --color-warning-highlight: #4a3d1c;

  --color-error: #e5645c;
  --color-error-hover: #ec857e;
  --color-error-highlight: #4a2320;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.5);
}

:root {
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3rem);

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
}

/* ==========================================================================
   Base
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: none;
  text-size-adjust: none;
  -webkit-font-smoothing: antialiased;
  scroll-behavior: smooth;
}

body {
  min-height: 100dvh;
  line-height: 1.55;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-bg);
  transition: background-color 200ms ease, color 200ms ease;
}

img, svg {
  display: block;
  max-width: 100%;
}

/* Default size for inline action/decoration icons rendered via the icon()
   helper (viewBox 0 0 24 24). Prevents icons from rendering at their raw
   viewBox size and blowing out flex layouts. Specific contexts (choice
   cards, safety banners, chevrons, brand mark) override as needed. */
svg[viewBox='0 0 24 24'] {
  width: 18px;
  height: 18px;
}

button {
  cursor: pointer;
  background: none;
  border: none;
  font: inherit;
  color: inherit;
}

h1, h2, h3, h4 {
  text-wrap: balance;
  line-height: 1.15;
  font-family: var(--font-display);
}

p, li {
  text-wrap: pretty;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

/* ==========================================================================
   Layout shell
   ========================================================================== */

#app {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-4) var(--space-5);
  border-bottom: 1px solid var(--color-divider);
  position: sticky;
  top: 0;
  background: var(--color-bg);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  text-decoration: none;
  color: var(--color-text);
}

.brand-mark {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-lg);
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  color: var(--color-text-muted);
  transition: background-color 160ms ease, color 160ms ease;
}
.theme-toggle:hover {
  background: var(--color-surface-offset);
  color: var(--color-text);
}

.main {
  flex: 1;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: var(--space-8) var(--space-5) var(--space-16);
}

.footer {
  padding: var(--space-6) var(--space-5) var(--space-10);
  text-align: center;
  color: var(--color-text-faint);
  font-size: var(--text-xs);
  max-width: 640px;
  margin: 0 auto;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: var(--space-4);
  margin-top: var(--space-3);
  flex-wrap: wrap;
}

.footer-link {
  background: none;
  border: none;
  color: var(--color-text-faint);
  font-size: var(--text-xs);
  text-decoration: underline;
  text-underline-offset: 2px;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
}

.footer-link:hover,
.footer-link:focus-visible {
  color: var(--color-primary);
}

.prose {
  text-align: left;
  color: var(--color-text);
  font-size: var(--text-sm);
  line-height: 1.65;
  max-width: 680px;
}

.prose h3 {
  font-family: var(--font-display);
  font-size: var(--text-base);
  margin-top: var(--space-5);
  margin-bottom: var(--space-2);
  color: var(--color-text);
}

.prose p {
  margin-bottom: var(--space-3);
}

.prose h3:first-child {
  margin-top: 0;
}

.preview-note {
  margin-top: var(--space-6);
  padding-top: var(--space-5);
  border-top: 1px solid var(--color-divider);
  color: var(--color-text-faint);
  font-size: var(--text-xs);
  line-height: 1.5;
}

/* ==========================================================================
   Screens — shared
   ========================================================================== */

.screen {
  animation: rise 260ms cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.eyebrow {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-2);
}

.screen-title {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-3);
  color: var(--color-text);
}

.screen-subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  margin-bottom: var(--space-8);
  max-width: 52ch;
}

/* ==========================================================================
   Intro / hero
   ========================================================================== */

.hero {
  text-align: center;
  padding: var(--space-8) 0 var(--space-10);
}

.hero-title {
  font-size: var(--text-2xl);
  font-weight: 800;
  letter-spacing: -0.015em;
  margin-bottom: var(--space-4);
}

.hero-title .accent {
  color: var(--color-primary);
}

.hero-subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 46ch;
  margin: 0 auto var(--space-8);
}

.hero-cta {
  display: inline-flex;
}

/* ==========================================================================
   Card grid (skill levels, symptom categories)
   ========================================================================== */

.option-grid {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: 1fr;
}

@media (min-width: 560px) {
  .option-grid.grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.choice-card {
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  text-align: left;
  width: 100%;
  height: 100%;
  padding: var(--space-5);
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.choice-card:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.choice-card:active {
  transform: translateY(0);
}

.choice-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--color-primary-highlight);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.choice-body {
  flex: 1;
}

.choice-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-base);
  margin-bottom: var(--space-1);
  text-wrap: balance;
}

.choice-desc {
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  display: block;
}

/* ==========================================================================
   Question screen
   ========================================================================== */

.progress-track {
  height: 6px;
  border-radius: var(--radius-full);
  background: var(--color-surface-offset);
  overflow: hidden;
  margin-bottom: var(--space-6);
}

.progress-fill {
  height: 100%;
  background: var(--color-primary);
  border-radius: var(--radius-full);
  transition: width 260ms cubic-bezier(0.16, 1, 0.3, 1);
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  margin-bottom: var(--space-2);
}

.question-text {
  font-size: var(--text-lg);
  font-weight: 600;
  margin-bottom: var(--space-6);
  font-family: var(--font-display);
}

.option-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
}

.option-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  width: 100%;
  padding: var(--space-4) var(--space-5);
  background: var(--color-surface);
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-md);
  font-size: var(--text-base);
  font-weight: 500;
  text-align: left;
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.option-btn:hover {
  border-color: var(--color-primary);
  background: var(--color-primary-highlight);
}

.option-btn:active {
  transform: scale(0.99);
}

.option-btn .chev {
  flex-shrink: 0;
  color: var(--color-text-faint);
}

.nav-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.text-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  font-weight: 500;
  padding: var(--space-2) var(--space-1);
  white-space: nowrap;
  transition: color 160ms ease;
}
.text-btn svg {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
}
.text-btn:hover {
  color: var(--color-text);
}

/* ==========================================================================
   Result screen
   ========================================================================== */

.result-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: 700;
  margin-bottom: var(--space-5);
}
.result-badge svg {
  width: 16px;
  height: 16px;
}

.result-badge.severity-high {
  background: var(--color-error-highlight);
  color: var(--color-error);
}
.result-badge.severity-medium {
  background: var(--color-warning-highlight);
  color: var(--color-warning);
}
.result-badge.severity-low {
  background: var(--color-success-highlight);
  color: var(--color-success);
}

.result-title {
  font-size: var(--text-xl);
  font-weight: 700;
  margin-bottom: var(--space-5);
}

.safety-banner {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md);
  background: var(--color-error-highlight);
  border: 1.5px solid var(--color-error);
  color: var(--color-text);
  margin-bottom: var(--space-6);
}

.safety-banner .icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  color: var(--color-error);
  margin-top: 2px;
}

.safety-banner strong {
  display: block;
  color: var(--color-error);
  margin-bottom: var(--space-1);
}

.verdict-card {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-6);
  border: 2px solid transparent;
}

.verdict-card.verdict-diy {
  background: var(--color-success-highlight);
  border-color: var(--color-success);
}

.verdict-card.verdict-shop {
  background: var(--color-error-highlight);
  border-color: var(--color-error);
}

.verdict-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: var(--text-lg);
  margin-bottom: var(--space-2);
}

.verdict-diy .verdict-label { color: var(--color-success); }
.verdict-shop .verdict-label { color: var(--color-error); }

.verdict-text {
  color: var(--color-text);
  font-size: var(--text-sm);
}

.result-section {
  margin-bottom: var(--space-6);
}

.result-section-title {
  font-size: var(--text-sm);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-faint);
  margin-bottom: var(--space-3);
}

.cause-list, .check-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.cause-list li, .check-list li {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  padding: var(--space-3) var(--space-4);
  background: var(--color-surface);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  list-style: none;
}

.cause-list li .dot, .check-list li .num {
  flex-shrink: 0;
  color: var(--color-primary);
  font-weight: 700;
}

.why-text {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  padding: var(--space-4) var(--space-5);
  background: var(--color-surface-2);
  border-radius: var(--radius-md);
  border-left: 3px solid var(--color-primary);
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-8);
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: var(--text-base);
  transition: background-color 160ms ease, transform 160ms ease, border-color 160ms ease;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-text-inverse);
}
.btn-primary:hover {
  background: var(--color-primary-hover);
}
.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: var(--color-surface);
  color: var(--color-text);
  border: 1.5px solid var(--color-border);
}
.btn-secondary:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

/* ==========================================================================
   Icons (inline symptom icons)
   ========================================================================== */

.choice-icon svg {
  width: 22px;
  height: 22px;
}

@media (max-width: 400px) {
  .main {
    padding: var(--space-6) var(--space-4) var(--space-12);
  }
  .hero-title {
    font-size: var(--text-xl);
  }
}

/* ==========================================================================
   Home tool grid
   ========================================================================== */

.tool-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
  margin-top: var(--space-7);
  width: 100%;
}

.tool-card {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  text-align: left;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease, background 160ms ease;
}
.tool-card:hover {
  border-color: var(--color-primary);
  transform: translateY(-1px);
}
.tool-card-primary {
  grid-column: 1 / -1;
  background: var(--color-primary);
  border-color: var(--color-primary);
}
.tool-card-primary .tool-title,
.tool-card-primary .tool-desc {
  color: var(--color-bg);
}
.tool-card-primary .tool-icon {
  background: rgba(255,255,255,0.18);
  color: var(--color-bg);
}
.tool-card-primary .tool-chev svg {
  color: var(--color-bg);
}

.tool-icon {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--color-surface-offset);
  color: var(--color-primary);
}
.tool-icon svg {
  width: 20px;
  height: 20px;
}

.tool-body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.tool-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.tool-desc {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.4;
}
.tool-chev {
  flex-shrink: 0;
  color: var(--color-text-faint);
  display: flex;
  align-items: center;
}

.pro-pill {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: rgba(217,86,12,0.14);
  color: var(--color-primary);
}
.tool-card-primary .pro-pill {
  background: rgba(255,255,255,0.2);
  color: var(--color-bg);
}

@media (max-width: 560px) {
  .tool-grid {
    grid-template-columns: 1fr;
  }
  .tool-card-primary {
    grid-column: auto;
  }
}

/* ==========================================================================
   OBD code lookup
   ========================================================================== */

.search-field {
  position: relative;
  width: 100%;
  margin-top: var(--space-5);
}

/* ==========================================================================
   Affiliate dongle card + ad slot (monetization)
   ========================================================================== */

.dongle-card {
  margin-top: var(--space-5);
  padding: var(--space-4);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  background: var(--color-surface);
}
.dongle-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-base);
  color: var(--color-text);
  margin-top: var(--space-1);
}
.dongle-subtitle {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.45;
  margin-top: var(--space-1);
}
.dongle-list {
 list-style: none;
  padding: 0;
  margin: var(--space-3) 0 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.dongle-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-sm);
  background: var(--color-bg);
}
.dongle-item-body {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
  min-width: 0;
}
.dongle-name {
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--color-text);
}
.dongle-desc {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.4;
}
.dongle-buy {
  flex-shrink: 0;
  font-size: var(--text-xs);
  font-weight: 600;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: var(--color-primary);
  color: #fff;
  text-decoration: none;
  white-space: nowrap;
}
.dongle-buy:hover {
  filter: brightness(1.07);
}
.affiliate-disclosure {
  font-size: 11px;
  color: var(--color-text-faint);
  line-height: 1.4;
  margin-top: var(--space-3);
}

.ad-slot {
  margin-top: var(--space-6);
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--color-divider);
  border-radius: var(--radius-md);
  background: var(--color-surface-offset);
}
.ad-slot-label {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* Live engine data dashboard */
.obd-live-btn {
  margin-top: var(--space-3);
}
.live-data {
  margin-top: var(--space-4);
  padding: var(--space-4);
  border: 1px solid var(--color-primary);
  border-radius: var(--radius-md);
  background: var(--color-surface);
}
.live-status {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: var(--space-2);
}
.live-stop-btn {
  margin-bottom: var(--space-3);
}
.live-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-2);
}
.live-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: var(--space-3);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-sm);
  background: var(--color-bg);
}
.live-label {
  font-size: 10px;
  font-weight: 600;
  color: var(--color-text-faint);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.live-value {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--text-base);
  color: var(--color-text);
  line-height: 1.2;
}
@media (max-width: 560px) {
  .live-grid {
    grid-template-columns: 1fr;
  }
}
.search-field svg.search-ico {
  position: absolute;
  left: var(--space-3);
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-text-faint);
  width: 18px;
  height: 18px;
  pointer-events: none;
}
.search-field input {
  width: 100%;
  padding: var(--space-3) var(--space-3) var(--space-3) var(--space-9);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  color: var(--color-text);
  font-size: var(--text-sm);
  font-family: var(--font-body);
}
.search-field input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(217,86,12,0.16);
}

.obd-scan {
  margin: var(--space-5) 0 var(--space-4);
  padding: var(--space-5);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-lg);
  background: var(--color-surface-2);
}

.obd-scan-btn {
  width: 100%;
  justify-content: center;
}

.obd-hint {
  margin: var(--space-3) 0 0;
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.45;
}

.obd-found {
  margin-top: var(--space-4);
}

.obd-found-label {
  font-size: var(--text-sm);
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: var(--space-2);
}

.code-chip {
  font-family: var(--font-mono, var(--font-display));
  font-weight: 700;
  background: var(--color-primary);
  color: #fff;
  cursor: pointer;
}

.code-chip-unknown {
  background: var(--color-surface-3, #e9e7e4);
  color: var(--color-text);
  cursor: default;
}

.exact-hit {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-top: var(--space-4);
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--color-surface-offset);
  font-size: var(--text-sm);
}
.exact-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  color: var(--color-primary);
  font-weight: 600;
  background: none;
  border: none;
  cursor: pointer;
  font-size: var(--text-sm);
}
.exact-link svg {
  width: 16px;
  height: 16px;
}

.code-list {
  display: flex;
  flex-direction: column;
  margin-top: var(--space-4);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-surface);
}
.code-row {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: var(--space-3) var(--space-4);
  background: none;
  border: none;
  border-bottom: 1px solid var(--color-divider);
  text-align: left;
  cursor: pointer;
  transition: background 120ms ease;
}
.code-row:last-child {
  border-bottom: none;
}
.code-row:hover {
  background: var(--color-surface-offset);
}
.code-row svg.chev {
  width: 16px;
  height: 16px;
  color: var(--color-text-faint);
  flex-shrink: 0;
}

.code-tag {
  flex-shrink: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.02em;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  background: var(--color-surface-offset);
  color: var(--color-text);
}
.code-tag-Powertrain { background: rgba(217,86,12,0.14); color: #b04609; }
.code-tag-Body { background: rgba(59,130,246,0.16); color: #2563eb; }
.code-tag-Chassis { background: rgba(16,185,129,0.16); color: #047857; }
.code-tag-Network { background: rgba(139,92,246,0.16); color: #6d28d9; }
[data-theme="dark"] .code-tag-Powertrain { color: #f59e6a; }
[data-theme="dark"] .code-tag-Body { color: #93c5fd; }
[data-theme="dark"] .code-tag-Chassis { color: #6ee7b7; }
[data-theme="dark"] .code-tag-Network { color: #c4b5fd; }

.code-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.code-title {
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--color-text);
}
.code-meta {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}

.code-head {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-4);
}
.code-tag-lg {
  font-size: 16px;
  padding: 6px 12px;
}
.code-system {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-text-faint);
}

.empty-state {
  margin-top: var(--space-6);
  padding: var(--space-6);
  text-align: center;
  color: var(--color-text-muted);
  font-size: var(--text-sm);
  border: 1px dashed var(--color-divider);
  border-radius: var(--radius-md);
}

/* ==========================================================================
   VIN decoder
   ========================================================================== */

.vin-field {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-5);
}
.vin-field input {
  flex: 1;
  min-width: 0;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  color: var(--color-text);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: var(--text-sm);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.vin-field input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(217,86,12,0.16);
}
.vin-field .btn {
  flex-shrink: 0;
}

.vin-result {
  margin-top: var(--space-5);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--color-surface);
}
.vin-head {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: var(--space-4);
  background: var(--color-surface-offset);
  border-bottom: 1px solid var(--color-divider);
}
.vin-make {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-lg);
  color: var(--color-text);
}
.vin-model {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.vin-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin: 0;
}
.vin-grid > div {
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--color-divider);
}
.vin-grid > div:nth-child(odd) {
  border-right: 1px solid var(--color-divider);
}
.vin-grid dt {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--color-text-faint);
  margin-bottom: 2px;
}
.vin-grid dd {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--color-text);
}
.vin-full {
  grid-column: 1 / -1;
  border-right: none !important;
}
.vin-full dd {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: 0.04em;
  word-break: break-all;
}
.vin-error {
  margin-top: var(--space-4);
}

@media (max-width: 480px) {
  .vin-grid {
    grid-template-columns: 1fr;
  }
  .vin-grid > div,
  .vin-grid > div:nth-child(odd) {
    border-right: none;
  }
}

/* ==========================================================================
   Pro roadmap
   ========================================================================== */

.roadmap-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-top: var(--space-5);
}
.roadmap-card {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--color-divider);
  border-radius: var(--radius-md);
  background: var(--color-surface);
}

.status-pill {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: var(--radius-full);
}
.status-now { background: rgba(16,185,129,0.16); color: #047857; }
.status-soon { background: rgba(217,86,12,0.14); color: var(--color-primary); }
.status-next { background: var(--color-surface-offset); color: var(--color-text-muted); }
.status-future { background: var(--color-surface-offset); color: var(--color-text-faint); }
[data-theme="dark"] .status-now { color: #6ee7b7; }
[data-theme="dark"] .status-soon { color: #f59e6a; }

.pro-cta {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  margin-top: var(--space-6);
  padding: var(--space-5);
  border-radius: var(--radius-md);
  background: var(--color-surface-offset);
  border: 1px dashed var(--color-divider);
}
.pro-cta svg {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--color-primary);
  margin-top: 2px;
}
.pro-cta strong {
  display: block;
  font-size: var(--text-sm);
  color: var(--color-text);
  margin-bottom: 4px;
}
.pro-cta p {
  margin: 0;
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.5;
}

/* Fix: search icon must sit above the opaque input */
.search-field svg.search-ico {
  z-index: 2;
}

/* --------------------------------------------------------------------------- */
/* Pro chat (preview)                                                          */
/* --------------------------------------------------------------------------- */

.chat-window {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  min-height: 240px;
  max-height: 52vh;
  overflow-y: auto;
  padding: var(--space-4);
  background: var(--color-surface-offset);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.chat-empty {
  margin: auto;
  color: var(--color-text-faint);
  font-size: var(--text-sm);
  text-align: center;
  max-width: 32ch;
}

.chat-error {
  color: var(--color-error);
  background: var(--color-error-highlight);
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
}

.chat-msg {
  white-space: pre-wrap;
  word-break: break-word;
  font-size: var(--text-sm);
  line-height: 1.5;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-lg);
  max-width: 88%;
}

.chat-msg-user {
  align-self: flex-end;
  background: var(--color-primary-highlight);
  color: var(--color-text);
  border-bottom-right-radius: var(--space-1);
}

.chat-msg-assistant {
  align-self: flex-start;
  background: var(--color-surface);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-bottom-left-radius: var(--space-1);
}

.chat-sources {
  margin-top: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--color-border);
}
.chat-sources-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: var(--space-2);
}
.chat-sources-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.chat-sources-list a {
  font-size: var(--text-xs);
  color: var(--color-primary);
  text-decoration: none;
  word-break: break-all;
}
.chat-sources-list a:hover {
  text-decoration: underline;
}

.chat-input-row {
  display: flex;
  gap: var(--space-3);
  align-items: flex-end;
  margin-top: var(--space-4);
}

.chat-input {
  flex: 1;
  resize: vertical;
  min-height: 3rem;
  max-height: 12rem;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.chat-input:focus {
  outline: 2px solid var(--color-primary);
  outline-offset: 1px;
}

.chat-input:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* ==========================================================================
   Cross-category comparison
   ========================================================================== */
.compare-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}
.compare-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.compare-head {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.compare-head .tool-icon {
  width: 22px;
  height: 22px;
  color: var(--color-primary);
  flex-shrink: 0;
}
.compare-veh {
  font-weight: 700;
  font-size: var(--text-base);
  color: var(--color-text);
}
.compare-cause {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  line-height: 1.35;
}
.compare-causes {
  margin: 0;
  padding-left: var(--space-4);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.4;
}
.compare-causes li {
  margin-bottom: var(--space-1);
}
.compare-causes li.muted {
  color: var(--color-text-faint);
  font-style: italic;
  list-style: none;
  padding-left: 0;
  margin-left: calc(-1 * var(--space-4));
}
.compare-meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-top: var(--space-1);
}
.compare-safety {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}
.compare-safety svg {
  width: 14px;
  height: 14px;
}
.compare-safety-note {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  background: var(--color-surface-offset);
  border-radius: var(--radius-sm);
  padding: var(--space-2) var(--space-3);
  margin: 0;
  line-height: 1.4;
}
.diff-banner {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md);
  background: var(--color-primary-highlight);
  border: 1.5px solid var(--color-primary);
  color: var(--color-text);
  margin-bottom: var(--space-6);
}
.diff-banner svg {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  color: var(--color-primary);
  margin-top: 2px;
}
.diff-banner strong {
  display: block;
  color: var(--color-primary);
  margin-bottom: var(--space-1);
}
.diff-banner p {
  margin: 0;
  font-size: var(--text-sm);
  line-height: 1.5;
}
.new-pill {
  background: var(--color-success-highlight);
  color: var(--color-success);
}
@media (max-width: 560px) {
  .compare-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Cost estimates & parts finder
   ========================================================================== */
.cost-range {
  font-size: var(--text-base);
  margin: 0 0 var(--space-1);
  color: var(--color-text);
}
.cost-range strong {
  font-size: var(--text-lg);
  color: var(--color-primary);
}
.cost-detail {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.cost-note {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.45;
  margin: 0 0 var(--space-3);
}
.parts-row {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
}
.parts-label {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.parts-link {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-primary);
  background: var(--color-primary-highlight);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: background 160ms ease;
}
.parts-link:hover {
  background: var(--color-surface-offset);
}
.compare-cost {
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
}

/* ==========================================================================
   Recalls & TSBs
   ========================================================================== */
.recall-form {
  display: grid;
  grid-template-columns: 90px 1fr 1fr auto;
  gap: var(--space-2);
  align-items: stretch;
  margin-bottom: var(--space-5);
}
.recall-input {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-base);
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-surface);
  outline: none;
}
.recall-input:focus {
  border-color: var(--color-primary);
}
.recall-input:disabled {
  opacity: 0.6;
}
.recall-card {
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-warning);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-5);
  margin-bottom: var(--space-3);
  background: var(--color-surface);
}
.recall-card.recall-parkit {
  border-left-color: var(--color-error);
  background: var(--color-error-highlight);
}
.recall-head {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-bottom: var(--space-2);
}
.recall-component {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 700;
  font-size: var(--text-base);
  color: var(--color-text);
}
.recall-component svg {
  width: 18px;
  height: 18px;
  color: var(--color-warning);
}
.recall-parkit .recall-component svg {
  color: var(--color-error);
}
.parkit-pill {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: var(--color-error);
  color: var(--color-text-inverse);
  padding: 3px 8px;
  border-radius: var(--radius-full);
}
.recall-number {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  margin-bottom: var(--space-2);
}
.recall-summary {
  font-size: var(--text-sm);
  color: var(--color-text);
  line-height: 1.5;
  margin: 0 0 var(--space-2);
}
.recall-detail {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.5;
  margin: 0 0 var(--space-1);
}
.recall-detail strong {
  color: var(--color-text);
}
.tsb-note {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md);
  background: var(--color-surface-offset);
  border: 1px solid var(--color-border);
  margin-top: var(--space-5);
}
.tsb-note svg {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  color: var(--color-text-faint);
  margin-top: 2px;
}
.tsb-note strong {
  display: block;
  margin-bottom: var(--space-1);
}
.tsb-note p {
  margin: 0 0 var(--space-2);
  font-size: var(--text-sm);
  line-height: 1.5;
  color: var(--color-text-muted);
}
@media (max-width: 560px) {
  .recall-form {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Header account button
   ========================================================================== */
.account-slot {
  margin-left: var(--space-2);
  display: flex;
  align-items: center;
}
.account-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
  background: var(--color-primary);
  color: var(--color-text-inverse);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  transition: opacity 160ms ease;
}
.account-btn:hover {
  opacity: 0.9;
}
.account-btn svg {
  width: 16px;
  height: 16px;
}
.account-btn-outline {
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}
@media (max-width: 560px) {
  .account-label {
    display: none;
  }
}

/* ==========================================================================
   Language & region (i18n) settings
   ========================================================================== */
.locale-slot {
  margin-left: var(--space-2);
  display: flex;
  align-items: center;
}
@media (max-width: 560px) {
  .locale-slot .account-label {
    display: none;
  }
}
.settings-field {
  margin-top: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.settings-label {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text);
}
.settings-select {
  font: inherit;
  font-size: var(--text-base);
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
  color: var(--color-text);
  cursor: pointer;
}
.settings-select:focus {
  outline: none;
  border-color: var(--color-primary);
}
.settings-hint {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  line-height: 1.5;
}
.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}
.chip {
  font-size: var(--text-xs);
  font-weight: 500;
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  background: var(--color-surface-offset);
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

/* ==========================================================================
   Auth (login / signup)
   ========================================================================== */
.auth-screen .auth-tabs {
  display: inline-flex;
  gap: var(--space-1);
  background: var(--color-surface-offset);
  border-radius: var(--radius-full);
  padding: var(--space-1);
  margin-bottom: var(--space-5);
}
.auth-tab {
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--color-text-muted);
  background: transparent;
  border: none;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease;
}
.auth-tab.active {
  background: var(--color-surface);
  color: var(--color-primary);
  box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}
.auth-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  max-width: 420px;
}
.auth-input {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-3) var(--space-4);
  font-size: var(--text-base);
  font-family: inherit;
  color: var(--color-text);
  background: var(--color-surface);
  outline: none;
  width: 100%;
}
.auth-input:focus {
  border-color: var(--color-primary);
}
.auth-input:disabled {
  opacity: 0.6;
}
.auth-submit {
  margin-top: var(--space-2);
}
.auth-actions {
  margin-bottom: var(--space-5);
}

/* ==========================================================================
   Garage (saved vehicles + history)
   ========================================================================== */
.garage-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.garage-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-surface);
}
.garage-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.garage-title {
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--color-text);
}
.garage-meta {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.save-row {
  margin-top: var(--space-3);
}

/* ==========================================================================
   Vehicle chip (active-vehicle context)
   ========================================================================== */
.vehicle-chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--text-xs);
  font-weight: 600;
  color: var(--color-primary);
  background: var(--color-primary-highlight);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-full);
  margin-bottom: var(--space-3);
}
.vehicle-chip svg {
  width: 14px;
  height: 14px;
}

/* ==========================================================================
   Repair action plan
   ========================================================================== */
.plan-sub {
  margin-top: var(--space-3);
}
.plan-label {
  display: block;
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-2);
}
.plan-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.plan-list li {
  display: flex;
  gap: var(--space-2);
  align-items: flex-start;
  font-size: var(--text-sm);
  color: var(--color-text);
}
.plan-list .dot {
  color: var(--color-primary);
  flex-shrink: 0;
}
.plan-steps {
  margin: 0;
  padding-left: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.plan-steps li {
  font-size: var(--text-sm);
  color: var(--color-text);
}
.plan-list.plan-warn .dot {
  color: var(--color-error);
}
.plan-list.plan-warn li {
  color: var(--color-text);
}

/* ==========================================================================
   Chat warning banner (AI not connected)
   ========================================================================== */
.chat-warn {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: var(--color-warning);
  color: var(--color-text);
  margin-bottom: var(--space-4);
}
.chat-warn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
