/* ============================================================
   Driver Application — global styles
   Linear-inspired. Mirrors rate-website token system.
============================================================ */

:root {
  /* Brand */
  --brand:        #3B3FFF;
  --brand-dim:    #2D32CC;
  --brand-faint:  rgba(59, 63, 255, 0.08);

  /* Greys */
  --ink:          #0B0D0F;
  --ink-dim:      #3F434A;
  --ink-faint:    #7B8089;
  --line:         #E4E6EA;
  --line-faint:   #F0F1F3;
  --paper:        #FFFFFF;
  --paper-tint:   #F7F8FA;

  /* Status */
  --ok:           #1A7F37;
  --warn:         #B88300;
  --err:          #C1272D;

  /* Type */
  --font-sans:    'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:    'IBM Plex Mono', ui-monospace, Menlo, monospace;
  --size-1:       11px;
  --size-2:       13px;
  --size-3:       15px;
  --size-4:       17px;
  --size-5:       21px;
  --size-6:       28px;
  --size-7:       40px;

  /* Spacing (4px scale) */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px; --s-6: 32px; --s-7: 48px;

  /* Radii */
  --r-1: 4px; --r-2: 6px; --r-3: 10px; --r-4: 14px;

  /* Layout */
  --container:    640px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--size-3);
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

.nav {
  position: sticky; top: 0; z-index: 10;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.nav__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--s-3) var(--s-4);
  display: flex; align-items: center; justify-content: space-between;
}
.brand {
  display: flex; align-items: center; gap: var(--s-2);
  text-decoration: none; color: var(--ink);
}
.brand__mark { width: 20px; height: 20px; color: var(--brand); }
.brand__name { font-weight: 700; }
.brand__app  { color: var(--ink-faint); }

#lang-toggle {
  font-family: var(--font-sans);
  font-size: var(--size-2);
  padding: var(--s-1) var(--s-2);
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  background: var(--paper);
}

.wizard {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--s-6) var(--s-4) var(--s-7);
}

.footer {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--s-5) var(--s-4);
  color: var(--ink-faint);
  font-size: var(--size-1);
  text-align: center;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-sans); font-weight: 600;
  padding: var(--s-3) var(--s-5);
  border: 1px solid transparent;
  border-radius: var(--r-2);
  cursor: pointer;
  transition: 80ms ease;
}
.btn--primary { background: var(--brand); color: white; }
.btn--primary:hover { background: var(--brand-dim); }
.btn--primary:disabled { background: var(--ink-faint); cursor: not-allowed; }
.btn--ghost { background: transparent; border-color: var(--line); color: var(--ink-dim); }
.btn--ghost:hover { background: var(--paper-tint); }

/* Fields */
.field {
  margin-bottom: var(--s-4);
}
.field__label {
  display: block; margin-bottom: var(--s-1);
  font-size: var(--size-2); color: var(--ink-dim); font-weight: 500;
}
.field__input {
  width: 100%;
  padding: var(--s-3);
  font-family: var(--font-sans); font-size: var(--size-3);
  border: 1px solid var(--line);
  border-radius: var(--r-2);
  background: var(--paper);
}
.field__input:focus { outline: 2px solid var(--brand); outline-offset: -1px; }
.field__input--error { border-color: var(--err); background: #FFFBFB; }
.field__input--error:focus { outline-color: var(--err); }
.field__error { color: var(--err); font-size: var(--size-1); margin-top: var(--s-1); font-weight: 500; }
.field__hint  { color: var(--ink-faint); font-size: var(--size-1); margin-top: var(--s-1); }

/* Progress */
.progress {
  margin-bottom: var(--s-6);
}
.progress__bar {
  height: 4px; background: var(--line);
  border-radius: 2px; overflow: hidden;
}
.progress__fill {
  height: 100%; background: var(--brand);
  transition: width 200ms ease;
}
.progress__label {
  display: flex; justify-content: space-between;
  font-size: var(--size-1); color: var(--ink-faint);
  margin-top: var(--s-1);
  font-family: var(--font-mono);
}

/* Welcome (step 1) checklist */
.welcome__checklist {
  list-style: none;
  padding: 0;
  margin: var(--s-4) 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.welcome__check-item {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  padding: var(--s-3);
  background: var(--paper-tint);
  border: 1px solid var(--line-faint);
  border-radius: var(--r-2);
  font-size: var(--size-3);
}
.welcome__check-dot {
  flex-shrink: 0;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--brand);
  margin-top: 4px;
}

/* Review (step 8) */
.review__section {
  border: 1px solid var(--line);
  border-radius: var(--r-3);
  padding: var(--s-4) var(--s-5);
  margin-bottom: var(--s-4);
  background: var(--paper);
}
.review__header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: var(--s-3);
  padding-bottom: var(--s-2);
  border-bottom: 1px solid var(--line-faint);
}
.review__title {
  font-size: var(--size-4);
  font-weight: 700;
  margin: 0;
}
.review__row {
  display: grid;
  grid-template-columns: minmax(140px, 200px) 1fr;
  gap: var(--s-3);
  padding: var(--s-2) 0;
  border-bottom: 1px solid var(--line-faint);
  align-items: start;
}
.review__row:last-child { border-bottom: none; }
.review__label {
  font-size: var(--size-2);
  color: var(--ink-faint);
  font-weight: 500;
}
.review__value {
  font-size: var(--size-3);
  color: var(--ink);
}
.review__value--missing {
  color: var(--err);
  font-style: italic;
}
.review__value--positive {
  color: var(--ok);
  font-style: italic;
}
.review__entries {
  display: flex; flex-direction: column; gap: var(--s-2);
}
.review__entry {
  background: var(--paper-tint);
  border-radius: var(--r-2);
  padding: var(--s-3);
}
.review__entry-head {
  font-weight: 600;
  font-size: var(--size-3);
  margin-bottom: var(--s-1);
}
.review__entry-sub {
  font-size: var(--size-2);
  color: var(--ink-dim);
  line-height: 1.5;
}
@media (max-width: 480px) {
  .review__row { grid-template-columns: 1fr; gap: var(--s-1); }
  .review__label { font-size: var(--size-1); text-transform: uppercase; letter-spacing: 0.4px; }
  .review__section { padding: var(--s-3); }
}

/* Honeypot — invisible to humans, populated by bots */
.honeypot {
  position: absolute; left: -10000px; top: -10000px;
  width: 1px; height: 1px; opacity: 0;
}

/* Step container */
.step { animation: fade-in 160ms ease; }
@keyframes fade-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: none; }
}
.step__title { font-size: var(--size-6); font-weight: 700; margin: 0 0 var(--s-2); }
.step__sub   { color: var(--ink-faint); margin: 0 0 var(--s-6); }

/* Step navigation */
.step__nav {
  display: flex; gap: var(--s-3);
  margin-top: var(--s-6); padding-top: var(--s-5);
  border-top: 1px solid var(--line);
}
.step__nav .btn--primary { margin-left: auto; }

/* Mobile */
@media (max-width: 480px) {
  .wizard { padding: var(--s-4) var(--s-3) var(--s-6); }
  .nav__inner { padding: var(--s-2) var(--s-3); }
  .step__title { font-size: var(--size-5); }
}
