/* ============================================================
   DocFlow — Design System Tokens (Trust & Authority)
   Generated from design-system/docflow/MASTER.md
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700&family=Poppins:wght@400;500;600;700;800&display=swap');

:root {
  /* Colors */
  --color-primary: #1E293B;
  --color-on-primary: #FFFFFF;
  --color-secondary: #334155;
  --color-accent: #2563EB;
  --color-accent-hover: #1D4ED8;
  --color-background: #F8FAFC;
  --color-surface: #FFFFFF;
  --color-foreground: #0F172A;
  --color-muted: #F1F5F9;
  --color-muted-foreground: #64748B;
  --color-border: #E2E8F0;
  --color-destructive: #DC2626;
  --color-success: #059669;
  --color-warning: #D97706;
  --color-ring: #1E293B;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;

  /* Shadow */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(15, 23, 42, 0.08), 0 2px 4px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(15, 23, 42, 0.10), 0 8px 10px -6px rgba(15, 23, 42, 0.04);

  /* Radius */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  /* Fonts */
  --font-heading: 'Poppins', system-ui, sans-serif;
  --font-body: 'Open Sans', system-ui, sans-serif;
}

/* ============================================================
   Base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--color-background);
  color: var(--color-foreground);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-primary);
  margin: 0;
}

h1 { font-size: clamp(2rem, 4vw + 1rem, 3.75rem); line-height: 1.1; }
h2 { font-size: clamp(1.75rem, 2.5vw + 1rem, 2.5rem); line-height: 1.15; }
h3 { font-size: 1.5rem; line-height: 1.25; }
h4 { font-size: 1.25rem; line-height: 1.3; }

p { margin: 0; color: var(--color-secondary); }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }

/* Selection */
::selection { background: var(--color-accent); color: white; }

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

/* ============================================================
   Layout
   ============================================================ */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container-narrow { max-width: 880px; }
.container-wide { max-width: 1360px; }

.section { padding: 5rem 0; }
.section-sm { padding: 3rem 0; }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 200ms ease;
  white-space: nowrap;
  text-decoration: none;
  user-select: none;
  border: 2px solid transparent;
}

.btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.4);
}

.btn-primary {
  background: var(--color-accent);
  color: white;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: var(--color-accent-hover);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-secondary {
  background: white;
  color: var(--color-primary);
  border-color: var(--color-border);
}
.btn-secondary:hover {
  border-color: var(--color-primary);
  background: var(--color-muted);
}

.btn-dark {
  background: var(--color-primary);
  color: white;
}
.btn-dark:hover {
  background: var(--color-foreground);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--color-secondary);
}
.btn-ghost:hover {
  color: var(--color-primary);
  background: var(--color-muted);
}

.btn-lg { padding: 1rem 2rem; font-size: 1rem; }
.btn-sm { padding: 0.5rem 1rem; font-size: 0.875rem; }
.btn-block { width: 100%; }

/* ============================================================
   Cards
   ============================================================ */
.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: all 200ms ease;
}

.card-interactive { cursor: pointer; }
.card-interactive:hover {
  border-color: var(--color-accent);
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

/* Tool card */
.tool-card {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  cursor: pointer;
  transition: all 200ms ease;
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
}
.tool-card::before {
  content: '';
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--color-accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 250ms ease;
}
.tool-card:hover {
  border-color: var(--color-accent);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}
.tool-card:hover::before { transform: scaleX(1); }
.tool-card .tool-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: rgba(37, 99, 235, 0.08);
  color: var(--color-accent);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.tool-card h4 {
  font-size: 1.05rem;
  color: var(--color-primary);
}
.tool-card p {
  font-size: 0.9rem;
  color: var(--color-muted-foreground);
  margin: 0;
}

/* ============================================================
   Forms
   ============================================================ */
.input, .select, .textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  background: white;
  color: var(--color-foreground);
  transition: border-color 200ms ease, box-shadow 200ms ease;
}
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: 0.4rem;
  font-family: var(--font-heading);
}

.helper-text {
  font-size: 0.8rem;
  color: var(--color-muted-foreground);
  margin-top: 0.4rem;
}

/* ============================================================
   Header
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 2rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-primary);
}
.brand-mark {
  width: 32px; height: 32px;
  border-radius: 8px;
  background: var(--color-primary);
  color: white;
  display: grid; place-items: center;
}

.nav { display: flex; align-items: center; gap: 0.25rem; }
.nav a {
  padding: 0.5rem 0.9rem;
  border-radius: var(--radius-md);
  color: var(--color-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 150ms ease;
}
.nav a:hover { color: var(--color-primary); background: var(--color-muted); }
.nav a.active { color: var(--color-primary); }

.header-actions { display: flex; gap: 0.75rem; align-items: center; }

.menu-toggle { display: none; }

@media (max-width: 900px) {
  .nav, .header-actions .desktop-only { display: none; }
  .menu-toggle {
    display: grid; place-items: center;
    width: 44px; height: 44px;
    border-radius: var(--radius-md);
    color: var(--color-primary);
  }
  .nav.open {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    top: 72px; left: 0; right: 0;
    background: white;
    border-bottom: 1px solid var(--color-border);
    padding: 1rem;
    gap: 0.25rem;
  }
}

/* ============================================================
   Hero
   ============================================================ */
.hero {
  padding: 5rem 0 4rem;
  background:
    radial-gradient(ellipse at top, rgba(37, 99, 235, 0.06), transparent 60%),
    var(--color-background);
  position: relative;
  overflow: hidden;
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--color-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-border) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 50% at 50% 0%, black, transparent);
  opacity: 0.4;
  pointer-events: none;
}
.hero-content { position: relative; text-align: center; max-width: 820px; margin: 0 auto; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.9rem;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-secondary);
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-sm);
}
.eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--color-success);
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.18);
}

.hero h1 { margin-bottom: 1.25rem; }
.hero p.lead {
  font-size: 1.2rem;
  color: var(--color-secondary);
  max-width: 640px;
  margin: 0 auto 2rem;
}
.hero-cta { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

/* ============================================================
   Logo bar
   ============================================================ */
.logo-bar {
  padding: 2rem 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  background: white;
}
.logo-bar p {
  text-align: center;
  font-size: 0.85rem;
  color: var(--color-muted-foreground);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
  font-weight: 600;
}
.logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 2rem;
  align-items: center;
  justify-items: center;
  opacity: 0.7;
}
.logo-grid > * {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--color-secondary);
  letter-spacing: -0.02em;
}

/* ============================================================
   Sections
   ============================================================ */
.section-header { text-align: center; max-width: 720px; margin: 0 auto 3rem; }
.section-header .eyebrow { margin-bottom: 1rem; }
.section-header h2 { margin-bottom: 0.75rem; }
.section-header p { font-size: 1.1rem; color: var(--color-muted-foreground); }

/* Tool grid */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.category-tabs {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}
.category-tab {
  padding: 0.5rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--color-border);
  background: white;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-secondary);
  cursor: pointer;
  transition: all 150ms ease;
}
.category-tab:hover { border-color: var(--color-primary); color: var(--color-primary); }
.category-tab.active {
  background: var(--color-primary);
  color: white;
  border-color: var(--color-primary);
}

/* ============================================================
   Stats / Trust
   ============================================================ */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  padding: 3rem;
  background: var(--color-primary);
  color: white;
  border-radius: var(--radius-xl);
  text-align: center;
}
.stats-bar .stat-value {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 2.5rem;
  letter-spacing: -0.02em;
  color: white;
}
.stats-bar .stat-label {
  font-size: 0.9rem;
  color: #CBD5E1;
  margin-top: 0.4rem;
}

.security-badges {
  display: flex; gap: 1.5rem; flex-wrap: wrap; justify-content: center; align-items: center;
}
.security-badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.5rem 1rem;
  border: 1px solid var(--color-border);
  background: white;
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-secondary);
}
.security-badge svg { color: var(--color-success); }

/* ============================================================
   Features
   ============================================================ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}
.feature {
  padding: 1.5rem;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}
.feature-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-md);
  background: rgba(37, 99, 235, 0.08);
  color: var(--color-accent);
  display: grid; place-items: center;
  margin-bottom: 1rem;
}
.feature h4 { font-size: 1.05rem; margin-bottom: 0.4rem; }
.feature p { font-size: 0.95rem; color: var(--color-muted-foreground); }

/* ============================================================
   CTA Banner
   ============================================================ */
.cta-banner {
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  color: white;
  border-radius: var(--radius-xl);
  padding: 4rem 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-banner::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at top right, rgba(37, 99, 235, 0.25), transparent 60%);
}
.cta-banner > * { position: relative; }
.cta-banner h2 { color: white; margin-bottom: 0.75rem; }
.cta-banner p { color: #CBD5E1; font-size: 1.1rem; margin-bottom: 2rem; }

/* ============================================================
   FAQ
   ============================================================ */
.faq-item {
  border-bottom: 1px solid var(--color-border);
}
.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.25rem 0;
  text-align: left;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--color-primary);
  cursor: pointer;
  transition: color 150ms ease;
}
.faq-question:hover { color: var(--color-accent); }
.faq-question .chevron { transition: transform 200ms ease; flex-shrink: 0; color: var(--color-muted-foreground); }
.faq-question[aria-expanded="true"] .chevron { transform: rotate(180deg); color: var(--color-accent); }
.faq-answer {
  display: none;
  padding-bottom: 1.25rem;
  color: var(--color-secondary);
  line-height: 1.7;
}
.faq-question[aria-expanded="true"] + .faq-answer { display: block; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: var(--color-primary);
  color: #CBD5E1;
  padding: 4rem 0 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(4, 1fr);
  gap: 2.5rem;
  margin-bottom: 3rem;
}
@media (max-width: 880px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
.site-footer h5 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: white;
  margin-bottom: 1rem;
  font-weight: 600;
}
.site-footer .brand { color: white; margin-bottom: 1rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.6rem; }
.site-footer ul a {
  color: #CBD5E1;
  font-size: 0.9rem;
  transition: color 150ms ease;
}
.site-footer ul a:hover { color: white; }
.footer-bottom {
  border-top: 1px solid #334155;
  padding-top: 1.5rem;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.85rem;
  color: #94A3B8;
}

/* ============================================================
   Upload zone
   ============================================================ */
.upload-zone {
  border: 2px dashed var(--color-border);
  border-radius: var(--radius-xl);
  padding: 3rem 2rem;
  text-align: center;
  background: white;
  transition: all 200ms ease;
  cursor: pointer;
}
.upload-zone:hover, .upload-zone.dragover {
  border-color: var(--color-accent);
  background: rgba(37, 99, 235, 0.03);
}
.upload-zone .upload-icon {
  width: 72px; height: 72px;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.08);
  color: var(--color-accent);
  display: grid; place-items: center;
  margin: 0 auto 1.25rem;
}
.upload-zone h3 { font-size: 1.4rem; margin-bottom: 0.4rem; }
.upload-zone p { color: var(--color-muted-foreground); margin-bottom: 1.5rem; }
.upload-zone .upload-options {
  display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap;
}

/* File item */
.file-item {
  display: flex; align-items: center; gap: 1rem;
  padding: 1rem;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
}
.file-item .file-icon {
  width: 40px; height: 40px;
  background: rgba(37, 99, 235, 0.08);
  color: var(--color-accent);
  border-radius: var(--radius-sm);
  display: grid; place-items: center;
  flex-shrink: 0;
}
.file-item .file-name { font-weight: 600; color: var(--color-primary); }
.file-item .file-meta { font-size: 0.85rem; color: var(--color-muted-foreground); }

/* Step indicator */
.steps {
  display: flex; gap: 0.5rem; align-items: center; justify-content: center;
  margin-bottom: 2rem;
}
.step {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--color-muted-foreground);
  font-weight: 600;
}
.step .step-num {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--color-muted);
  color: var(--color-muted-foreground);
  display: grid; place-items: center;
  font-size: 0.85rem;
}
.step.active { color: var(--color-primary); }
.step.active .step-num { background: var(--color-accent); color: white; }
.step.done .step-num { background: var(--color-success); color: white; }
.step-divider { width: 32px; height: 1px; background: var(--color-border); }

/* ============================================================
   PDF page thumbnails (split tool)
   ============================================================ */
.page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1rem;
}
.page-thumb {
  position: relative;
  aspect-ratio: 1 / 1.414;
  background: white;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 200ms ease;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0.5rem;
}
.page-thumb::before {
  content: '';
  position: absolute; inset: 0.5rem 0.5rem 1.75rem;
  background: repeating-linear-gradient(
    to bottom,
    var(--color-muted) 0 6px,
    transparent 6px 12px
  );
  border-radius: 4px;
}
.page-thumb .page-num {
  position: relative;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-muted-foreground);
}
.page-thumb.selected {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}
.page-thumb.selected::after {
  content: '';
  position: absolute; top: 0.5rem; right: 0.5rem;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--color-accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

/* ============================================================
   PDF Editor canvas
   ============================================================ */
.editor-layout {
  display: grid;
  grid-template-columns: 240px 1fr 280px;
  gap: 1rem;
  height: calc(100vh - 72px);
  padding: 1rem;
}
@media (max-width: 1100px) {
  .editor-layout { grid-template-columns: 1fr; height: auto; }
}
.editor-panel {
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow-y: auto;
}
.editor-toolbar {
  display: flex; gap: 0.4rem; padding: 0.75rem; flex-wrap: wrap;
  border-bottom: 1px solid var(--color-border);
}
.editor-tool {
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  display: grid; place-items: center;
  color: var(--color-secondary);
  cursor: pointer;
  transition: all 150ms ease;
}
.editor-tool:hover { background: var(--color-muted); color: var(--color-primary); }
.editor-tool.active { background: var(--color-accent); color: white; }

.editor-canvas {
  background: var(--color-muted);
  display: grid; place-items: center;
  border-radius: var(--radius-lg);
  padding: 2rem;
  min-height: 500px;
  position: relative;
}
.editor-page {
  width: 100%;
  max-width: 540px;
  aspect-ratio: 1 / 1.414;
  background: white;
  box-shadow: var(--shadow-xl);
  border-radius: 4px;
  position: relative;
  padding: 3rem;
}

/* Sidebar items */
.panel-section { padding: 1rem; border-bottom: 1px solid var(--color-border); }
.panel-section h5 {
  font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--color-muted-foreground); margin-bottom: 0.75rem;
  font-weight: 600;
}

/* ============================================================
   Pricing
   ============================================================ */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  align-items: stretch;
}
.pricing-card {
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  transition: all 200ms ease;
}
.pricing-card.featured {
  border: 2px solid var(--color-accent);
  box-shadow: var(--shadow-xl);
  position: relative;
  transform: scale(1.02);
}
.pricing-card.featured .badge {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--color-accent); color: white;
  padding: 0.3rem 0.8rem; border-radius: 999px;
  font-size: 0.75rem; font-weight: 700;
  letter-spacing: 0.05em; text-transform: uppercase;
}
.pricing-card h3 { font-size: 1.25rem; margin-bottom: 0.4rem; }
.pricing-card .price {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--color-primary);
  margin: 1rem 0;
}
.pricing-card .price span { font-size: 1rem; color: var(--color-muted-foreground); font-weight: 500; }
.pricing-card ul { list-style: none; padding: 0; margin: 1.5rem 0; flex-grow: 1; display: flex; flex-direction: column; gap: 0.75rem; }
.pricing-card ul li {
  display: flex; gap: 0.6rem; align-items: flex-start;
  font-size: 0.95rem;
  color: var(--color-secondary);
}
.pricing-card ul li svg { color: var(--color-success); flex-shrink: 0; margin-top: 3px; }

/* ============================================================
   Login
   ============================================================ */
.auth-shell {
  min-height: calc(100vh - 72px);
  display: grid;
  place-items: center;
  padding: 3rem 1rem;
  background:
    radial-gradient(ellipse at top, rgba(37, 99, 235, 0.05), transparent 60%),
    var(--color-background);
}
.auth-card {
  width: 100%;
  max-width: 440px;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-lg);
}
.auth-card h2 { font-size: 1.75rem; margin-bottom: 0.4rem; text-align: center; }
.auth-card p.muted { text-align: center; color: var(--color-muted-foreground); margin-bottom: 2rem; }
.divider {
  display: flex; align-items: center; gap: 1rem;
  margin: 1.5rem 0;
  color: var(--color-muted-foreground);
  font-size: 0.85rem;
}
.divider::before, .divider::after {
  content: ''; flex: 1; height: 1px; background: var(--color-border);
}

.btn-google {
  background: white;
  color: var(--color-foreground);
  border: 1px solid var(--color-border);
  width: 100%;
  padding: 0.85rem;
  font-weight: 600;
  font-family: var(--font-heading);
  display: inline-flex; align-items: center; justify-content: center; gap: 0.75rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 200ms ease;
}
.btn-google:hover {
  border-color: var(--color-primary);
  background: var(--color-muted);
}

/* ============================================================
   Dashboard
   ============================================================ */
.dashboard-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  min-height: calc(100vh - 72px);
}
@media (max-width: 880px) { .dashboard-layout { grid-template-columns: 1fr; } }
.sidebar {
  background: white;
  border-right: 1px solid var(--color-border);
  padding: 1.5rem 1rem;
}
.sidebar-link {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-md);
  color: var(--color-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 150ms ease;
  margin-bottom: 0.2rem;
}
.sidebar-link:hover { background: var(--color-muted); color: var(--color-primary); }
.sidebar-link.active { background: var(--color-primary); color: white; }
.sidebar-link.active svg { color: white; }

.dashboard-main {
  padding: 2rem;
  background: var(--color-background);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.metric-card {
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
}
.metric-card .label {
  font-size: 0.8rem; color: var(--color-muted-foreground);
  text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600;
}
.metric-card .value {
  font-family: var(--font-heading); font-weight: 700;
  font-size: 1.75rem; color: var(--color-primary);
  margin-top: 0.4rem;
}
.metric-card .delta { font-size: 0.85rem; color: var(--color-success); margin-top: 0.25rem; }

.data-table {
  width: 100%; border-collapse: collapse;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.data-table th, .data-table td {
  text-align: left; padding: 0.85rem 1rem; font-size: 0.9rem;
}
.data-table thead { background: var(--color-muted); }
.data-table th { color: var(--color-secondary); font-weight: 600; font-family: var(--font-heading); }
.data-table tbody tr { border-top: 1px solid var(--color-border); }
.data-table tbody tr:hover { background: var(--color-muted); }
.status-pill {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.2rem 0.6rem; border-radius: 999px;
  font-size: 0.75rem; font-weight: 600;
}
.status-pill.success { background: rgba(5, 150, 105, 0.1); color: var(--color-success); }
.status-pill.processing { background: rgba(37, 99, 235, 0.1); color: var(--color-accent); }
.status-pill.failed { background: rgba(220, 38, 38, 0.1); color: var(--color-destructive); }

/* ============================================================
   Legal pages
   ============================================================ */
.legal-shell {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 3rem;
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}
@media (max-width: 880px) { .legal-shell { grid-template-columns: 1fr; gap: 1rem; } }

.legal-toc {
  position: sticky;
  top: 88px;
  align-self: start;
  font-size: 0.9rem;
}
.legal-toc h5 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-muted-foreground);
  font-weight: 600;
  margin-bottom: 1rem;
}
.legal-toc ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.4rem; }
.legal-toc a {
  display: block;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  color: var(--color-secondary);
  font-weight: 500;
  border-left: 2px solid transparent;
}
.legal-toc a:hover { color: var(--color-primary); background: var(--color-muted); }

.legal-content {
  max-width: 720px;
  font-size: 1rem;
  line-height: 1.75;
  color: var(--color-secondary);
}
.legal-content h1 {
  font-size: 2.25rem;
  margin-bottom: 0.5rem;
}
.legal-content .meta {
  color: var(--color-muted-foreground);
  font-size: 0.9rem;
  margin-bottom: 2.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border);
}
.legal-content h2 {
  font-size: 1.5rem;
  margin: 2.5rem 0 1rem;
  color: var(--color-primary);
}
.legal-content h3 {
  font-size: 1.15rem;
  margin: 1.75rem 0 0.5rem;
  color: var(--color-primary);
}
.legal-content p { margin: 0 0 1rem; }
.legal-content ul, .legal-content ol {
  padding-left: 1.5rem;
  margin: 0 0 1rem;
}
.legal-content li { margin-bottom: 0.5rem; }
.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0 1.5rem;
  font-size: 0.95rem;
}
.legal-content th, .legal-content td {
  text-align: left;
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--color-border);
  vertical-align: top;
}
.legal-content thead { background: var(--color-muted); }
.legal-content th { font-weight: 600; color: var(--color-primary); font-family: var(--font-heading); }
.legal-content a { color: var(--color-accent); text-decoration: underline; }
.legal-content code {
  background: var(--color-muted);
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-family: ui-monospace, SFMono-Regular, monospace;
  font-size: 0.9em;
}
.legal-callout {
  padding: 1rem 1.25rem;
  background: rgba(37, 99, 235, 0.05);
  border-left: 3px solid var(--color-accent);
  border-radius: 6px;
  margin: 1.25rem 0;
  font-size: 0.95rem;
  color: var(--color-secondary);
}
.legal-callout.warn {
  background: rgba(217, 119, 6, 0.06);
  border-left-color: var(--color-warning);
}

/* ============================================================
   Cookie consent banner
   ============================================================ */
#cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  max-width: 640px;
  margin: 0 auto;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: 12px;
  box-shadow: var(--shadow-xl);
  padding: 1.25rem 1.5rem;
  display: none;
  align-items: center;
  gap: 1rem;
  z-index: 1000;
  font-size: 0.9rem;
  color: var(--color-secondary);
}
#cookie-banner.show { display: flex; }
@media (max-width: 600px) { #cookie-banner { flex-direction: column; align-items: stretch; text-align: center; } }
#cookie-banner p { margin: 0; flex: 1; }
#cookie-banner a { color: var(--color-accent); text-decoration: underline; }
#cookie-banner .actions { display: flex; gap: 0.5rem; flex-shrink: 0; }

/* ============================================================
   Contact form / About
   ============================================================ */
.about-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}
.about-stat {
  padding: 1.5rem;
  background: white;
  border: 1px solid var(--color-border);
  border-radius: 12px;
}
.about-stat .label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-muted-foreground);
  font-weight: 600;
}
.about-stat .value {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-top: 0.4rem;
}

/* ============================================================
   Utilities
   ============================================================ */
.text-center { text-align: center; }
.flex { display: flex; }
.flex-col { display: flex; flex-direction: column; }
.gap-2 { gap: 0.5rem; } .gap-3 { gap: 0.75rem; } .gap-4 { gap: 1rem; }
.mt-2 { margin-top: 0.5rem; } .mt-4 { margin-top: 1rem; } .mt-6 { margin-top: 1.5rem; } .mt-8 { margin-top: 2rem; }
.mb-2 { margin-bottom: 0.5rem; } .mb-4 { margin-bottom: 1rem; } .mb-6 { margin-bottom: 1.5rem; } .mb-8 { margin-bottom: 2rem; }
.muted { color: var(--color-muted-foreground); }
.small { font-size: 0.875rem; }
.bold { font-weight: 700; }
