@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;600;700&family=Outfit:wght@500;600;700&display=swap');

/* ============================================
   CSS Custom Properties
   ============================================ */

/* Dark mode (default) */
:root {
  color-scheme: dark;
  --base: #09090b;
  --surface: #16161a;
  --surface-hover: #1e1e23;
  --border: rgba(255,255,255,0.12);
  --border-bright: rgba(255,255,255,0.20);
  --text: #ededef;
  --text-muted: #8b8b95;
  --accent: #10b981;
  --accent-hover: #059669;
  --accent-glow: rgba(16, 185, 129, 0.15);
  --safe: #22c55e;
  --danger: #ef4444;
  --high: #f97316;
  --warning: #eab308;
  --info: #3b82f6;
  --font-display: 'Inter', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --max-width: 1100px;
  --pill-fill: #0c0d10;
  --pill-stroke: rgba(255,255,255,0.08);
  /* Spacing scale (4px base) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-7: 32px;
  --space-8: 40px;
  --space-9: 48px;
  --space-10: 64px;
  --space-11: 80px;
  --space-12: 96px;
  /* Shadows (dark) */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.3), 0 1px 2px rgba(0,0,0,0.2);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.4), 0 2px 4px rgba(0,0,0,0.2);
}

/* Light mode: manual toggle */
[data-theme="light"] {
  color-scheme: light;
  --base: #fafafa;
  --surface: #ffffff;
  --surface-hover: #f4f4f5;
  --border: rgba(0,0,0,0.10);
  --border-bright: rgba(0,0,0,0.18);
  --text: #18181b;
  --text-muted: #52525b;
  --accent: #059669;
  --accent-hover: #047857;
  --accent-glow: rgba(5, 150, 105, 0.12);
  --safe: #16a34a;
  --danger: #dc2626;
  --high: #ea580c;
  --warning: #d97706;
  --info: #2563eb;
  --pill-fill: #1e2127;
  --pill-stroke: #2d3340;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 2px 8px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-lg: 0 4px 16px rgba(0,0,0,0.10), 0 2px 4px rgba(0,0,0,0.05);
}

/* Light mode: system preference (when no manual override) */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    color-scheme: light;
    --base: #fafafa;
    --surface: #ffffff;
    --surface-hover: #f4f4f5;
    --border: rgba(0,0,0,0.10);
    --border-bright: rgba(0,0,0,0.18);
    --text: #18181b;
    --text-muted: #52525b;
    --accent: #059669;
    --accent-hover: #047857;
    --accent-glow: rgba(5, 150, 105, 0.12);
    --safe: #16a34a;
    --danger: #dc2626;
    --high: #ea580c;
    --warning: #d97706;
    --info: #2563eb;
    --pill-fill: #1e2127;
    --pill-stroke: #2d3340;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 2px 8px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.04);
    --shadow-lg: 0 4px 16px rgba(0,0,0,0.10), 0 2px 4px rgba(0,0,0,0.05);
  }
}

/* ============================================
   Reset & Base
   ============================================ */

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

html {
  scroll-behavior: smooth;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--base);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: var(--accent-glow);
  color: var(--text);
}

a {
  color: inherit;
  text-decoration: none;
}

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

button,
input,
textarea {
  font: inherit;
}

/* ============================================
   Typography
   ============================================ */

.font-display {
  font-family: var(--font-display);
}

.font-mono {
  font-family: var(--font-mono);
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text);
}

h1 { font-size: 2.25rem; line-height: 1.15; letter-spacing: -0.025em; }
h2 { font-size: 1.5rem; line-height: 1.2; letter-spacing: -0.025em; }
h3 { font-size: 1.125rem; line-height: 1.3; letter-spacing: -0.015em; }
h4 { font-size: 1rem; line-height: 1.4; letter-spacing: -0.015em; }

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

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  overflow-x: hidden;
}

.section {
  padding: var(--space-12) 0;
}

/* ============================================
   Alpine.js Utilities
   ============================================ */

[x-cloak] {
  display: none !important;
}

.inline-flex-center {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

[x-collapse] {
  overflow: hidden;
}

/* ============================================
   Nav
   ============================================ */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(9, 9, 11, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

[data-theme="light"] .nav {
  background: rgba(250, 250, 250, 0.95);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .nav {
    background: rgba(250, 250, 250, 0.95);
  }
}

.nav-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 56px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.nav-logo {
  font-family: 'Outfit', var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.375rem;
  letter-spacing: -0.02em;
}

.nav-logo svg {
  flex-shrink: 0;
}

.nav-logo-text {
  color: var(--text);
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  align-items: center;
}

.nav-links a {
  transition: color 150ms ease;
}

.nav-links a:hover {
  color: var(--text);
}

.nav-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  background: var(--accent-glow);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-sm);
}

.nav-theme-toggle {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.375rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 150ms ease;
}

.nav-theme-toggle:hover {
  color: var(--text);
  border-color: var(--border-bright);
}

.nav-lang-toggle {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.375rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
  transition: all 150ms ease;
}

.nav-lang-toggle:hover {
  color: var(--text);
  border-color: var(--border-bright);
}

.nav-more-dropdown { position: relative; }
.nav-more-toggle {
  background: none;
  border: none;
  color: var(--text-muted);
  font: inherit;
  cursor: pointer;
  padding: 0;
  transition: all 150ms ease;
}
.nav-more-toggle:hover { color: var(--text); }
.nav-more-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.25rem 0;
  min-width: 160px;
  z-index: 100;
  box-shadow: var(--shadow-lg);
}
.nav-more-menu a {
  display: block;
  padding: 0.5rem 0.75rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.8125rem;
  transition: all 150ms ease;
}
.nav-more-menu a:hover {
  background: var(--border);
  color: var(--text);
}

.nav-lang-dropdown { position: relative; }
.nav-lang-menu {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.25rem 0;
  min-width: 120px;
  z-index: 100;
  box-shadow: var(--shadow-lg);
}
.nav-lang-menu a {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  font-family: var(--font-mono);
  color: var(--text-muted);
  text-decoration: none;
  transition: all 150ms ease;
}
.nav-lang-menu a:hover {
  color: var(--text);
  background: var(--surface-hover);
}
.nav-lang-name {
  font-weight: 400;
  font-family: var(--font-body);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.5rem;
  font-size: 1.25rem;
  line-height: 1;
}

/* ============================================
   Hero
   ============================================ */

.hero {
  text-align: center;
  padding: 8rem 0 5rem;
  background: radial-gradient(ellipse at 50% 0%, var(--accent-glow) 0%, transparent 60%);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  max-width: 800px;
  margin: 0 auto 1.25rem;
}

.hero-subtitle {
  color: var(--text-muted);
  font-size: 1.125rem;
  max-width: 520px;
  margin: 0 auto 0.5rem;
  line-height: 1.6;
}

.hero-form {
  max-width: 520px;
  margin: 2.5rem auto 0;
}

.scan-tabs {
  display: inline-flex;
  position: relative;
  gap: 2rem;
  margin-bottom: 1.25rem;
  padding-bottom: 6px;
}

.scan-tabs-track {
  position: absolute;
  bottom: 0;
  left: 0;
  width: calc(50% - 1rem);
  height: 2px;
  background: var(--accent);
  border-radius: 1px;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
}

.scan-tabs-track.scan-tabs-right {
  transform: translateX(calc(100% + 2rem));
}

.scan-tab {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  transition: color 150ms ease;
  letter-spacing: 0.01em;
}

.scan-tab:hover {
  color: var(--text);
}

.scan-tab-active {
  color: var(--text);
}

.scan-tab svg {
  opacity: 0.5;
  transition: opacity 150ms ease;
}

.scan-tab-active svg {
  opacity: 0.85;
}

.hero-input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-md);
  padding: 1.125rem 1.25rem;
  font-size: 0.9375rem;
  color: var(--text);
  font-family: var(--font-mono);
  transition: all 150ms ease;
}

.hero-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.hero-input::placeholder {
  color: var(--text-muted);
  opacity: 0.5;
}

.file-drop {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.875rem 1.25rem;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  color: var(--text-muted);
  font-size: 0.875rem;
  font-family: var(--font-body);
  cursor: pointer;
  transition: all 150ms ease;
}

.file-drop:hover {
  border-color: var(--accent);
  color: var(--text);
}

.file-drop-has-file {
  border-style: solid;
  border-color: var(--accent);
  color: var(--text);
}

.file-drop-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  overflow: hidden;
}

.file-drop svg {
  flex-shrink: 0;
  opacity: 0.5;
}

.file-drop:hover svg,
.file-drop-has-file svg {
  opacity: 0.85;
}

.file-drop-text {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-drop-browse {
  flex-shrink: 0;
  padding: 0.3125rem 0.75rem;
  background: var(--surface-hover);
  border-radius: var(--radius-sm);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text);
  transition: all 150ms ease;
}

.file-drop:hover .file-drop-browse {
  background: var(--border-bright);
}

.hero-submit {
  width: 100%;
  margin-top: 0.75rem;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  padding: 1rem 1.25rem;
  border: none;
  border-radius: var(--radius-md);
  font-size: 0.9375rem;
  cursor: pointer;
  transition: all 150ms ease;
  font-family: var(--font-body);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.hero-submit:hover {
  background: var(--accent-hover);
}

.hero-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.hero-note {
  color: var(--text-muted);
  font-size: 0.8125rem;
  margin-top: 1rem;
}

/* Hero example cards */
.hero-examples {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2rem;
}

.hero-examples-label {
  color: var(--text-muted);
  font-size: 0.8125rem;
  letter-spacing: 0.03em;
}

.hero-examples-row {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.hero-example-chip {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.5rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.8125rem;
  color: var(--text);
  text-decoration: none;
  transition: all 150ms ease;
  white-space: nowrap;
}

.hero-example-chip:hover {
  border-color: var(--border-bright);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.hero-example-score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  padding: 0.1875rem 0.4375rem;
  border-radius: var(--radius-sm);
  font-size: 0.8125rem;
  font-weight: 700;
  font-family: var(--font-mono);
  letter-spacing: -0.02em;
}

.hero-example-score.score-safe {
  background: rgba(34, 197, 94, 0.12);
}

.hero-example-score.score-warning {
  background: rgba(245, 158, 11, 0.12);
}

.hero-example-score.score-danger {
  background: rgba(239, 68, 68, 0.12);
}

/* ============================================
   Social Proof Strip
   ============================================ */

.proof-strip {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  padding: 1rem 0;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.proof-strip span.dot {
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--border-bright);
  margin: 0 0.5rem;
}

/* ============================================
   Steps
   ============================================ */

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  position: relative;
}


.why-mcpampel-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  max-width: 720px;
  margin: 0 auto;
}

.why-mcpampel-grid > div {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  text-align: left;
}

.why-mcpampel-grid > div > div:first-child {
  color: var(--accent);
  margin-bottom: 1rem;
}

.why-mcpampel-grid > div > div:first-child svg {
  width: 24px;
  height: 24px;
}

.why-mcpampel-grid h3 {
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 0.375rem;
}

.why-mcpampel-grid p {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.step {
  padding: 2rem 1.75rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.step-number {
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1rem;
}

.step-title {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.625rem;
}

.step-desc {
  color: var(--text-muted);
  font-size: 0.8125rem;
  line-height: 1.6;
}

/* ============================================
   Why This Matters
   ============================================ */

.why-stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem 1.5rem;
  text-align: center;
}

.why-stat .step-desc {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.why-stat-number {
  font-family: var(--font-mono);
  font-size: 2.75rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.025em;
  line-height: 1;
  margin-bottom: 1rem;
}

.why-scan-summary {
  color: var(--text-muted);
  font-size: 0.9375rem;
  line-height: 1.7;
  max-width: 720px;
  margin: 2rem auto 0;
  text-align: center;
}

/* ============================================
   Engine Grid
   ============================================ */

.engine-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

/* ============================================
   Engine Tile
   ============================================ */

.engine-tile {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  cursor: pointer;
  transition: border-color 150ms ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.375rem;
}

.engine-tile:hover {
  border-color: var(--border-bright);
}

.engine-tile-name {
  font-weight: 600;
  font-size: 0.8125rem;
}

.engine-tile-desc {
  color: var(--text-muted);
  font-size: 0.75rem;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.engine-tile-active {
  border-color: var(--border-bright);
}

/* Engine tile header (name + chevron) */
.engine-tile-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.engine-tile-chevron {
  color: var(--text-muted);
  opacity: 0.5;
  transition: transform 150ms ease;
  flex-shrink: 0;
}

.engine-tile-chevron-open {
  transform: rotate(180deg);
}

.engine-tile:hover .engine-tile-chevron {
  opacity: 1;
}

.engine-tile-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.engine-tile-status {
  font-size: 0.6875rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
}

.engine-tile-expand-icon {
  color: var(--text-muted);
  opacity: 0;
  transition: all 150ms ease;
  flex-shrink: 0;
}
.engine-tile:hover .engine-tile-expand-icon {
  opacity: 0.5;
}
.engine-tile.is-expanded .engine-tile-expand-icon {
  opacity: 1;
  transform: rotate(180deg);
}
.engine-tile.is-expanded {
  border-color: var(--border-bright);
}

/* Engine detail panel (homepage expandable info) */
.engine-detail-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: none;
  border-left: 2px solid var(--accent);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  margin-top: -1px;
}

.engine-detail-panel-inner {
  padding: 1rem 1.25rem;
  border-top: 1px solid var(--border);
}

.engine-detail-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
  font-weight: 500;
}

.engine-detail-value {
  font-size: 0.8125rem;
  color: var(--text);
  line-height: 1.6;
  margin-bottom: 0.875rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.engine-detail-link {
  font-size: 0.75rem;
  color: var(--accent);
  transition: color 150ms ease;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
}

.engine-detail-link:hover {
  color: var(--text);
  text-decoration: underline;
}

/* Engine tile status variants */
.engine-tile.safe .engine-tile-status {
  color: var(--safe);
}

.engine-tile.flagged .engine-tile-status {
  color: var(--danger);
}

.engine-tile.skipped .engine-tile-status {
  color: var(--text-muted);
}

.engine-tile.failed .engine-tile-status {
  color: var(--warning);
}

/* ============================================
   Risk Category Cards
   ============================================ */

.engine-view-toggle {
  display: inline-flex;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 2px;
}

.engine-view-toggle button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 28px;
  border: none;
  border-radius: calc(var(--radius-sm) - 2px);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 150ms ease;
}

.engine-view-toggle button:hover {
  color: var(--text);
}

.engine-view-toggle button.active {
  background: var(--surface-hover);
  color: var(--accent);
}

.risk-category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.risk-category-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  cursor: pointer;
  transition: all 150ms ease;
}

.risk-category-card:hover {
  border-color: var(--border-bright);
  box-shadow: var(--shadow-md);
}

.risk-category-card-active {
  border-color: var(--accent);
}

.risk-category-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.risk-category-name {
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 600;
  margin: 0;
}

.risk-category-desc {
  color: var(--text-muted);
  font-size: 0.8125rem;
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

.risk-category-meta {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.risk-stat {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.risk-stat strong {
  color: var(--accent);
  font-size: 1rem;
  font-family: var(--font-mono);
}

.risk-engine-count {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.risk-category-engines {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.risk-engine-item {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.risk-engine-name {
  font-size: 0.8125rem;
  font-weight: 500;
}

.risk-engine-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ============================================
   Recent Scans
   ============================================ */

.recent-list {
  max-width: 720px;
  margin: 0 auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.recent-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  transition: background 150ms ease;
  text-decoration: none;
  color: var(--text);
}

.recent-item:hover {
  background: var(--surface-hover);
}

.recent-item + .recent-item {
  border-top: 1px solid var(--border);
}

.recent-score {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 1rem;
  min-width: 3.5rem;
  text-align: left;
}

.recent-url {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--text-muted);
  flex: 1;
  margin: 0 1rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-time {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  text-align: right;
}

/* ============================================
   Trust Score Display
   ============================================ */

.trust-score-number {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 4rem;
  line-height: 1;
  letter-spacing: -0.02em;
}

.trust-score-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.5rem;
}

.trust-score-sub {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--text-muted);
  margin-top: 0.125rem;
}

.score-safe { color: var(--safe); }
.score-warning { color: var(--warning); }
.score-danger { color: var(--danger); }
.score-neutral { color: var(--text-muted); }

/* ============================================
   Cached Banner
   ============================================ */

.cached-banner {
  background: rgba(59, 130, 246, 0.06);
  border: 1px solid rgba(59, 130, 246, 0.15);
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.cached-rescan {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--accent);
  padding: 0.25rem 0.625rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  margin-left: auto;
  transition: all 150ms ease;
}

.cached-rescan:hover {
  border-color: var(--accent);
  background: var(--accent-glow);
}

/* ============================================
   Verdict Panel
   ============================================ */

.verdict {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  margin-bottom: 1.5rem;
  display: flex;
  gap: 2.5rem;
  align-items: flex-start;
}

.verdict-left {
  flex-shrink: 0;
  width: 120px;
  text-align: center;
  padding-top: 0.25rem;
}

.verdict-right {
  flex: 1;
  min-width: 0;
}

.verdict-text {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.verdict-summary {
  color: var(--text-muted);
  font-size: 0.8125rem;
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

.project-history-link {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
  font-family: var(--font-body);
  color: var(--accent);
  text-decoration: none;
  margin-top: 0.25rem;
  margin-bottom: 0.25rem;
  padding: 0.1875rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all 150ms ease;
}

.project-history-link:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

.project-history-link svg:last-child {
  opacity: 0;
  transform: translateX(-2px);
  transition: all 150ms ease;
}

.project-history-link:hover svg:last-child {
  opacity: 1;
  transform: translateX(0);
}

.verdict-meta {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.verdict-meta > div {
  display: flex;
  flex-direction: column;
  gap: 0.125rem;
}

.verdict-meta-label {
  font-size: 0.6875rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.verdict-meta-value {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
}

/* ============================================
   Severity Section (scan results card)
   ============================================ */

.severity-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

/* ============================================
   Severity Bar
   ============================================ */

.severity-bar {
  display: flex;
  height: 6px;
  border-radius: 3px;
  overflow: hidden;
  background: var(--border);
  margin-top: 0.25rem;
}

.severity-segment {
  min-width: 0;
  transition: width 0.4s ease;
}

.severity-segment.critical { background: var(--danger); }
.severity-segment.high { background: var(--high); }
.severity-segment.medium { background: var(--warning); }
.severity-segment.low { background: var(--info); }

.severity-legend {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.625rem;
}

.severity-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  margin-right: 0.25rem;
  vertical-align: middle;
}

/* ============================================
   Scan Progress
   ============================================ */

.scan-progress {
  text-align: center;
  padding: 4rem 0;
  max-width: 520px;
  margin: 0 auto;
}

.scan-progress-title {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.scan-progress-count {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.progress-bar {
  width: 100%;
  max-width: 480px;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
  margin: 0 auto 1.5rem;
}

.progress-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 2px;
  transition: width 300ms ease;
}

.progress-bar-fill.active {
  animation: progress-pulse 2s ease-in-out infinite;
}

.engine-status-list {
  max-width: 480px;
  margin: 1.5rem auto 0;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.engine-status-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.4375rem 0.875rem;
  font-size: 0.8125rem;
  font-family: var(--font-mono);
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}

.engine-status-item:last-child {
  border-bottom: none;
}

.engine-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.engine-status-dot.running {
  background: var(--accent);
  animation: pulse-dot 1.5s ease-in-out infinite;
}

.engine-status-dot.done {
  background: var(--safe);
}

.engine-status-dot.pending {
  background: var(--border-bright);
}

/* Result view toggle */
.view-toggle {
  display: flex;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 2px;
}
.view-toggle-btn {
  background: none;
  border: none;
  padding: 0.3125rem 0.625rem;
  cursor: pointer;
  border-radius: calc(var(--radius-md) - 2px);
  color: var(--text-muted);
  transition: all 150ms ease;
  display: flex;
  align-items: center;
  gap: 0.3125rem;
  font-size: 0.75rem;
  font-family: var(--font-body);
}
.view-toggle-btn.active {
  background: var(--border);
  color: var(--text);
}
.view-toggle-btn:hover:not(.active) {
  color: var(--text);
}

/* Engine result list view */
.engine-result-list {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.engine-result-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.5625rem 0.875rem;
  font-size: 0.8125rem;
  color: var(--text);
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: all 150ms ease;
}
.engine-result-item:last-child {
  border-bottom: none;
}
.engine-result-item:hover {
  background: var(--surface-hover);
}
.engine-result-item.is-expanded {
  background: var(--surface);
}
.engine-result-item-name {
  flex: 1;
  min-width: 0;
  font-weight: 500;
}
.engine-result-item-status {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  white-space: nowrap;
}
.engine-result-item-chevron {
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 150ms ease;
}
.engine-result-item.is-expanded .engine-result-item-chevron {
  transform: rotate(180deg);
}
.engine-status-dot.done-safe { background: var(--safe); }
.engine-status-dot.done-flagged { background: var(--danger); }
.engine-status-dot.done-skipped { background: var(--text-muted); }
.engine-status-dot.done-failed { background: var(--warning); }

/* ============================================
   Expanded Engine Detail
   ============================================ */

/* Engine detail expand/collapse transitions */
.detail-enter {
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.detail-enter-start {
  opacity: 0;
  transform: translateY(-8px);
}
.detail-enter-end {
  opacity: 1;
  transform: translateY(0);
}
.detail-leave {
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.engine-detail {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 1rem;
}

.engine-detail-header {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.engine-detail-body {
  padding: 1rem;
  overflow: hidden;
}

.finding-item {
  border-left: 3px solid var(--border);
  padding: 0.625rem 0 0.625rem 0.875rem;
  margin-bottom: 0.625rem;
  overflow: hidden;
}

.finding-item:last-child {
  margin-bottom: 0;
}

.finding-item:has(.badge-critical) {
  border-left-color: var(--danger);
}

.finding-item:has(.badge-high) {
  border-left-color: var(--high);
}

.finding-item:has(.badge-medium) {
  border-left-color: var(--warning);
}

.finding-item:has(.badge-low) {
  border-left-color: var(--info);
}

.finding-header {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  margin-bottom: 0.25rem;
  min-width: 0;
  flex-wrap: wrap;
}

.finding-rule {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  overflow-wrap: break-word;
  word-break: break-word;
  min-width: 0;
}

.finding-desc {
  color: var(--text-muted);
  font-size: 0.8125rem;
  line-height: 1.4;
  overflow-wrap: break-word;
  word-break: break-word;
}

.finding-location {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
  overflow-wrap: break-word;
  word-break: break-word;
}

/* ============================================
   Severity Badges
   ============================================ */

.badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.625rem;
  font-weight: 600;
  padding: 0.0625rem 0.375rem;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.badge-critical {
  background: rgba(239, 68, 68, 0.12);
  color: var(--danger);
}

.badge-high {
  background: rgba(249, 115, 22, 0.12);
  color: var(--high);
}

.badge-medium {
  background: rgba(245, 158, 11, 0.12);
  color: var(--warning);
}

.badge-low {
  background: rgba(59, 130, 246, 0.12);
  color: var(--info);
}

.badge-clean {
  background: rgba(34, 197, 94, 0.12);
  color: var(--safe);
}

/* ============================================
   Actions Bar
   ============================================ */

.actions-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text);
  font-size: 0.8125rem;
  cursor: pointer;
  transition: all 150ms ease;
}

.btn-outline:hover {
  border-color: var(--border-bright);
  color: var(--text);
  background: var(--surface-hover);
}

/* ============================================
   Badge Embed
   ============================================ */

.badge-embed {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.875rem 1rem;
}

.badge-embed-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.badge-embed-code {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--text-muted);
  background: var(--base);
  border: 1px solid var(--border);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  word-break: break-all;
}

.badge-embed-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.badge-embed-preview {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.badge-embed-snippet {
  position: relative;
}

.badge-embed-snippet-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1.25rem;
  border-bottom: 1px solid var(--border);
}

.badge-embed-snippet-label {
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge-embed-copy {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.1875rem 0.5rem;
  font-size: 0.625rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 150ms ease;
  white-space: nowrap;
}

.badge-embed-copy:hover {
  border-color: var(--border-bright);
  color: var(--text);
}

.badge-embed-pre {
  margin: 0;
  padding: 1rem 1.25rem;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.6;
  color: var(--text-muted);
  white-space: pre-wrap;
  word-break: break-all;
}

/* ============================================
   Stats Cards
   ============================================ */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
}

.stat-value {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1;
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.8125rem;
  margin-top: 0.5rem;
}

/* ============================================
   Detection Rate Table
   ============================================ */

.detection-row {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin-bottom: 0.5rem;
}

.detection-bar-track {
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 0.5rem;
}

.detection-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.4s ease;
}

/* ============================================
   Footer
   ============================================ */

.footer {
  padding: var(--space-12) 0 var(--space-10);
  border-top: 1px solid var(--border);
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-top: auto;
}

.footer a {
  transition: color 150ms ease;
  line-height: 1.8;
}

.footer a:hover {
  color: var(--text);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin-bottom: 2rem;
  max-width: 480px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-heading {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  font-size: 0.75rem;
  color: var(--text-muted);
}

@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   Section Headers
   ============================================ */

.section-title {
  font-family: var(--font-display);
  font-size: 1.625rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: var(--space-9);
  letter-spacing: -0.025em;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-top: -1rem;
  margin-bottom: 1.5rem;
}

/* ============================================
   FAQ
   ============================================ */

.faq-list {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
}

.faq-question span {
  font-weight: 600;
  font-size: 0.9375rem;
}

.faq-answer {
  padding: 0 1.5rem 1.25rem;
  color: var(--text-muted);
  font-size: 0.875rem;
  line-height: 1.6;
}

/* ============================================
   Back Link
   ============================================ */

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3125rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  transition: color 150ms ease;
  text-decoration: none;
}

.back-link:hover {
  color: var(--text);
}

/* ============================================
   Utility Classes
   ============================================ */

.text-accent { color: var(--accent); }
.text-muted { color: var(--text-muted); }
.text-safe { color: var(--safe); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-info { color: var(--info); }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.hidden { display: none; }

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

/* ============================================
   Animations
   ============================================ */

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

@keyframes progress-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.animate-in {
  animation: fadeInUp 0.4s ease-out both;
}

.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }

/* ============================================
   Spinner
   ============================================ */

.spinner {
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
}

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

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

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

@keyframes pulse-glow {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

@keyframes scan-line {
  0% { transform: translateY(-8px); opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { transform: translateY(8px); opacity: 0; }
}

/* Traffic light pill animations */
@keyframes ampel-breathe-r {
  0%, 100% { opacity: 1; filter: drop-shadow(0 0 7px var(--danger)); }
  50% { opacity: 0.82; filter: drop-shadow(0 0 3px var(--danger)); }
}
@keyframes ampel-breathe-y {
  0%, 100% { opacity: 1; filter: drop-shadow(0 0 6px var(--warning)); }
  50% { opacity: 0.8; filter: drop-shadow(0 0 2px var(--warning)); }
}
@keyframes ampel-breathe-g {
  0%, 100% { opacity: 1; filter: drop-shadow(0 0 8px var(--accent)); }
  50% { opacity: 0.78; filter: drop-shadow(0 0 3px var(--accent)); }
}

.ampel-on-r { animation: ampel-breathe-r 2.8s ease-in-out infinite; }
.ampel-on-y { animation: ampel-breathe-y 2.8s ease-in-out infinite 0.93s; }
.ampel-on-g { animation: ampel-breathe-g 2.8s ease-in-out infinite 1.86s; }
.ampel-off  { opacity: 0.11; }

/* Gradient wordmark */
.amp-grad {
  color: var(--accent);
  background: linear-gradient(90deg, var(--danger) 0%, var(--warning) 48%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}


@media (prefers-reduced-motion: reduce) {
  .nav-logo svg * {
    animation: none !important;
  }
  .ampel-on-r, .ampel-on-y, .ampel-on-g {
    animation: none !important;
  }
}

/* ============================================
   Scrollbar
   ============================================ */

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--base);
}

::-webkit-scrollbar-thumb {
  background: var(--border-bright);
  border-radius: var(--radius-sm);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

* {
  scrollbar-width: thin;
  scrollbar-color: var(--border-bright) var(--base);
}

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 768px) {
  .steps-grid {
    grid-template-columns: 1fr;
  }

  .why-mcpampel-grid {
    grid-template-columns: 1fr;
  }

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

  .risk-category-grid {
    grid-template-columns: 1fr;
  }

  .hero-examples-row {
    flex-direction: column;
    width: 100%;
  }

  .hero-example-chip {
    min-width: 0;
    width: 100%;
    justify-content: flex-start;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .verdict {
    flex-direction: column;
    gap: 1.25rem;
  }

  .verdict-left {
    width: auto;
    text-align: left;
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
  }

  .verdict-meta {
    flex-direction: column;
    gap: 0.75rem;
  }

  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    background: var(--surface);
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
    gap: 0.75rem;
  }

  .nav-links.active {
    display: flex;
  }

  .hero {
    padding: 4rem 0 2.5rem;
  }

  .proof-strip {
    flex-wrap: wrap;
    gap: 1rem;
  }

  /* Prevent iOS Safari zoom on input focus (requires >= 16px) */
  .hero-input,
  .form-input,
  .feedback-textarea,
  input[type="email"],
  input[type="text"],
  input[type="password"],
  input[type="url"],
  textarea,
  select {
    font-size: 16px;
  }

  .nav-links a,
  .nav-more-toggle,
  .nav-lang-toggle,
  .nav-theme-toggle {
    padding: 0.625rem 0;
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .nav-more-toggle { display: none; }
  .nav-more-menu {
    display: flex !important;
    position: static;
    flex-direction: column;
    background: none;
    border: none;
    box-shadow: none;
    padding: 0;
    min-width: 0;
  }
  .nav-more-menu a {
    padding: 0.5rem 0;
    font-size: inherit;
  }

  .hero-input,
  .hero-submit {
    min-height: 48px;
  }

  .hero-form {
    max-width: 100%;
  }

  .steps-grid {
    gap: 1rem;
  }
}

/* ============================================
   Docs Navigation
   ============================================ */

.docs-nav-link {
  display: inline-block;
  padding: 0.375rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all 150ms ease;
}

.docs-nav-link:hover {
  color: var(--text);
  border-color: var(--border-bright);
}

.docs-nav-link.active {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-glow);
}

/* ============================================
   Engine Category Headers
   ============================================ */

.engine-category-header {
  font-family: var(--font-body);
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.5rem;
}

@media (max-width: 480px) {
  .engine-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }

  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.25rem; }

  .section { padding: var(--space-9) 0; }
  .container { padding: 0 1rem; }

  .hero-submit {
    min-height: 48px;
  }

  .hero-input {
    min-height: 48px;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .risk-category-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .why-mcpampel-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ============================================
   Usage Bar (account, monitoring)
   ============================================ */

.usage-bar-track {
  height: 8px;
  background: var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin: 0.75rem 0 0.5rem;
}

.usage-bar-fill {
  height: 100%;
  border-radius: var(--radius-sm);
  transition: width 0.4s ease;
}

/* ============================================
   Tier Badges
   ============================================ */

.tier-badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.125rem 0.625rem;
  border-radius: var(--radius-sm);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.tier-free { background: rgba(108, 111, 133, 0.15); color: var(--text-muted); }
.tier-pro { background: var(--accent-glow); color: var(--accent); }
.tier-team { background: rgba(59, 130, 246, 0.15); color: var(--info); }
.tier-enterprise { background: rgba(245, 158, 11, 0.15); color: var(--warning); }

/* ============================================
   Notification Banners
   ============================================ */

.notification-banner {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.notification-success {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: var(--safe);
}

.notification-info {
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: var(--info);
}

.notification-warning {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  color: var(--warning);
}

/* ============================================
   Form Components
   ============================================ */

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.form-input {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.875rem;
  font-family: var(--font-body);
  transition: all 150ms ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-msg {
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

.form-msg-success { color: var(--safe); }
.form-msg-error { color: var(--danger); }

/* ============================================
   Confirm Dialogs
   ============================================ */

.confirm-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.confirm-dialog {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 2rem;
  max-width: 400px;
  width: 90%;
}

/* ============================================
   Button Variants (shared)
   ============================================ */

.btn-sm {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 500;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 150ms ease;
}

.btn-accent {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-md);
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
}

.btn-accent:hover { background: var(--accent-hover); }
.btn-accent:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  border-color: var(--border-bright);
  color: var(--text);
}

.btn-danger {
  background: transparent;
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
  background: rgba(239, 68, 68, 0.1);
  border-color: var(--danger);
}

/* ============================================
   Locked Engine Tile (paid-only upsell)
   ============================================ */

.engine-tile.locked {
  cursor: pointer;
}

.engine-tile.locked .engine-tile-status {
  color: var(--accent);
}

/* ============================================
   Feedback FAB & Modal
   ============================================ */

.feedback-fab {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 90;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: all 150ms ease;
}

.feedback-fab:hover {
  transform: scale(1.08);
  box-shadow: var(--shadow-lg);
}

.feedback-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 95;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feedback-modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  width: 90%;
  max-width: 420px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.feedback-modal-title {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.feedback-categories {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.feedback-cat-btn {
  flex: 1;
  padding: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 500;
  font-family: var(--font-body);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 9999px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 150ms ease;
}

.feedback-cat-btn:hover {
  border-color: var(--border-bright);
  color: var(--text);
  background: var(--surface-hover);
}

.feedback-cat-btn.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-glow);
}

.feedback-textarea {
  width: 100%;
  min-height: 120px;
  padding: 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text);
  font-size: 0.875rem;
  font-family: var(--font-body);
  resize: vertical;
  margin-bottom: 0.75rem;
  transition: all 150ms ease;
}

.feedback-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.feedback-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}

.feedback-success {
  text-align: center;
  padding: 1.5rem 0;
}

.feedback-success-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 0.75rem;
  border-radius: 50%;
  background: var(--accent-glow);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Axis scores */
.axis-scores {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}
.axis-score-item {
    display: flex;
    flex-direction: column;
    gap: 0.1875rem;
}
.axis-score-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 0.6875rem;
}
.axis-score-label {
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    font-weight: 500;
}
.axis-score-value {
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.6875rem;
}
.axis-score-bar {
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
}
.axis-score-fill {
    height: 100%;
    border-radius: 2px;
    transition: width 0.6s ease;
}

/* Scan page risk category chips */
.scan-risk-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
}
.scan-risk-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: var(--surface-hover);
    border: 1px solid var(--border);
    border-radius: 9999px;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    cursor: default;
    transition: all 150ms ease;
}
.scan-risk-chip:hover {
    border-color: var(--border-bright);
}
.scan-risk-count {
    background: var(--border);
    border-radius: 9999px;
    padding: 0.0625rem 0.375rem;
    font-size: 0.6875rem;
    font-family: var(--font-mono);
    font-weight: 600;
}
.badge-category {
    background: var(--surface-hover);
    color: var(--text-muted);
    border: 1px solid var(--border);
}

@media (max-width: 768px) {
    .axis-scores {
        grid-template-columns: 1fr;
    }
}
