:root {
  color-scheme: dark;
  --bg: #0b0e12;
  --bg-2: #111826;
  --surface: #151e2b;
  --surface-2: #1b2636;
  --accent: #ff7a00;
  --accent-2: #ffb454;
  --text: #f6f7fb;
  --muted: #9aa6b2;
  --error: #ff5d5d;
  --shadow: 0 20px 50px rgba(0,0,0,0.35);
  --radius: 20px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(255,122,0,0.18), transparent 60%),
    radial-gradient(900px 500px at 90% 0%, rgba(255,180,84,0.14), transparent 60%),
    linear-gradient(160deg, var(--bg), var(--bg-2));
  min-height: 100vh;
}

.app {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 10;
  padding: 16px 20px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  backdrop-filter: blur(12px);
  background: rgba(11,14,18,0.78);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  box-shadow: 0 4px 12px rgba(255,122,0,0.2);
  background: #0c0c0c;
}

.brand-title {
  font-family: "Nunito", sans-serif;
  font-size: 17px;
  letter-spacing: 0.2px;
  font-weight: 700;
}

.brand-subtitle {
  font-size: 11px;
  color: var(--muted);
}

.status {
  font-size: 12px;
  color: var(--accent-2);
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.05);
}

.theme-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}

.theme-btn:active {
  transform: scale(0.95);
}

.theme-btn.active {
  color: #1a1206;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 8px 18px rgba(255,122,0,0.28);
}

.progress {
  padding: 12px 20px 8px;
}

.progress-track {
  width: 100%;
  height: 6px;
  background: rgba(255,255,255,0.08);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 999px;
  transition: width 0.3s ease;
}

.progress-label {
  margin-top: 6px;
  font-size: 12px;
  color: var(--muted);
}

.app-main {
  flex: 1;
  padding: 12px 20px 32px;
}

.startup-loader {
  display: none;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px 20px 64px;
}

.startup-loader-card {
  width: min(100%, 360px);
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid rgba(255,255,255,0.08);
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.025));
  box-shadow: var(--shadow);
  text-align: center;
}

.startup-loader-logo {
  width: min(34vw, 132px);
  height: 96px;
  margin: 0 auto 22px;
  object-fit: contain;
  filter: drop-shadow(0 14px 26px rgba(255,122,0,0.24));
}

.startup-loader-title {
  font-family: "Nunito", sans-serif;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0.2px;
  margin-bottom: 16px;
}

.startup-loader-track {
  width: 100%;
  height: 7px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255,255,255,0.08);
}

.startup-loader-fill {
  width: 42%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 22px rgba(255,122,0,0.35);
  animation: startupLoaderRun 1.15s ease-in-out infinite;
}

body.startup-loading .app * { animation-play-state: paused !important; }
body.startup-loading .step { animation: none; }
.step[data-step="intro"] { animation: none; }
body.startup-error .startup-loader-track { display: none; }
body.font-fallback .app * { font-family: system-ui, sans-serif !important; }
img.startup-image-unavailable { visibility: hidden; }

.step {
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  animation: fadeIn 0.3s ease;
}

.step h1 {
  font-family: "Nunito", sans-serif;
  font-size: 20px;
  margin: 0 0 12px 0;
  font-weight: 800;
  letter-spacing: 0.2px;
}

.step-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.step-head h1 {
  margin-bottom: 0;
}

.step[data-step="boss"] .step-head {
  margin-bottom: 10px;
}

.step[data-step="boss"] {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto;
  height: calc(100vh - 170px);
  height: calc(100svh - 170px);
  overflow: hidden;
}

.step[data-step="boss"] #bossList {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding-right: 4px;
  scroll-snap-type: y mandatory;
  align-content: start;
}

.step[data-step="boss"] #bossList .btn,
.step[data-step="boss"] #bossList .empty-note {
  scroll-snap-align: start;
}

.step[data-step="boss"] > .btn.ghost[data-back] {
  margin-top: 10px;
}

body.boss-step-active {
  overflow: hidden;
}

body.boss-step-active .app {
  height: 100vh;
  height: 100svh;
}

body.boss-step-active .app-main {
  overflow: hidden;
}

.icon-btn {
  -webkit-appearance: none;
  appearance: none;
  width: 36px;
  height: 36px;
  border-radius: 11px;
  border: 1px solid rgba(255,255,255,0.16);
  background: rgba(12, 18, 27, 0.62);
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.icon-btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: var(--accent-2);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 4px rgba(255, 122, 0, 0.3));
}

.icon-btn:hover {
  border-color: rgba(255, 122, 0, 0.56);
  background: rgba(255, 122, 0, 0.2);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.14),
    0 7px 14px rgba(255, 122, 0, 0.16);
  filter: saturate(1.08);
}

.icon-btn:active {
  transform: translateY(1px) scale(0.98);
}

.icon-btn.is-open {
  border-color: rgba(255, 122, 0, 0.72);
  background: rgba(255, 122, 0, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.15),
    0 8px 16px rgba(255, 122, 0, 0.2);
}

.icon-btn.is-open svg {
  stroke: #ffd5a0;
}

.search-wrap {
  margin: 10px 0 12px;
  animation: fadeIn 0.2s ease;
}

.search-input {
  padding-right: 16px;
}

.empty-note {
  margin: 4px 0 2px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}

.hint {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 12px 0;
}

.step[data-step="intro"] h1 {
  text-align: center;
  margin-bottom: 14px;
}

.intro-card {
  position: relative;
  isolation: isolate;
  overflow: visible;
  margin: 10px 0 8px;
  padding: 22px 18px 18px;
  border-radius: 16px;
  background: transparent;
  border: 1px solid transparent;
  background-image: none;
}

.intro-card::before {
  content: none;
}

.intro-card::after {
  content: none;
}

.intro-border-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.intro-border-track {
  fill: none;
  stroke: rgba(255, 158, 70, 0.42);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.intro-border-flow {
  fill: none;
  stroke-linecap: round;
  stroke-width: 1.05;
  vector-effect: non-scaling-stroke;
}

.intro-border-glow {
  fill: none;
  stroke-linecap: round;
  stroke-width: 2.8;
  vector-effect: non-scaling-stroke;
}

.intro-border-glow-a {
  stroke: rgba(255, 122, 0, 0.28);
  stroke-dasharray: 136 864;
  stroke-dashoffset: 0;
  opacity: 0.52;
  filter: blur(2px);
  animation: introStrokeRun 9.4s linear infinite;
}

.intro-border-glow-b {
  stroke: rgba(255, 180, 100, 0.2);
  stroke-dasharray: 102 898;
  stroke-dashoffset: 0;
  opacity: 0.42;
  filter: blur(2.3px);
  animation: introStrokeRunReverse 9.4s linear infinite;
  animation-delay: -4.7s;
}

.intro-border-flow-a {
  stroke: rgba(255, 130, 16, 0.66);
  stroke-dasharray: 136 864;
  stroke-dashoffset: 0;
  opacity: 0.72;
  filter:
    drop-shadow(0 0 4px rgba(255, 122, 0, 0.34))
    drop-shadow(0 0 10px rgba(255, 122, 0, 0.24));
  animation: introStrokeRun 9.4s linear infinite, introStrokeGlow 2.4s ease-in-out infinite;
}

.intro-border-flow-b {
  stroke: rgba(255, 186, 112, 0.46);
  stroke-dasharray: 102 898;
  stroke-dashoffset: 0;
  opacity: 0.58;
  filter:
    drop-shadow(0 0 3px rgba(255, 170, 86, 0.24))
    drop-shadow(0 0 8px rgba(255, 170, 86, 0.16));
  animation: introStrokeRunReverse 9.4s linear infinite, introStrokeGlow 2.4s ease-in-out infinite reverse;
  animation-delay: -4.7s, -1.2s;
}

.intro-list {
  margin-top: 2px;
  display: grid;
  gap: 10px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.intro-copy {
  margin: 0;
  font-size: 16px;
  line-height: 1.45;
  color: var(--text);
  font-weight: 600;
}

.intro-start-wrap {
  margin-top: 16px;
  display: flex;
  justify-content: center;
  position: relative;
  z-index: 1;
}

#introStartBtn {
  min-width: 180px;
}

.input {
  width: 100%;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(9,12,18,0.8);
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border 0.2s ease, box-shadow 0.2s ease;
}

.input:focus {
  border-color: rgba(255,122,0,0.6);
  box-shadow: 0 0 0 3px rgba(255,122,0,0.15);
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.stack {
  display: grid;
  gap: 10px;
}

.step > .btn.ghost[data-back] {
  margin-top: 10px;
}

.btn {
  border: none;
  border-radius: 16px;
  padding: 14px 16px;
  font-size: 15px;
  font-weight: 700;
  font-family: "Manrope", "Segoe UI", sans-serif;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease;
}

.btn.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #1a1206;
  box-shadow: 0 12px 28px rgba(255,122,0,0.3);
}

.btn.secondary {
  background: rgba(255,255,255,0.08);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.12);
}

.btn.ghost {
  background: transparent;
  color: var(--muted);
  border: 1px dashed rgba(255,255,255,0.2);
}

.btn-inline-toggle {
  margin: -2px 0 8px;
  padding: 6px 8px;
  border-style: solid;
  border-color: rgba(255,255,255,0.12);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-align: left;
}

#changeOldCarPicker {
  margin-bottom: 6px;
}

.change-old-car-option {
  text-align: left;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.25;
}

.change-old-car-option.is-active {
  border-color: rgba(255, 122, 0, 0.6);
  box-shadow: inset 0 0 0 1px rgba(255, 122, 0, 0.32);
}

.btn:active {
  transform: scale(0.98);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}

.preview {
  margin-top: 12px;
  min-height: 120px;
  border-radius: 16px;
  background: rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 13px;
  overflow: hidden;
}

.preview.is-hint {
  align-items: flex-start;
  justify-content: flex-start;
  text-align: left;
  white-space: pre-line;
  line-height: 1.4;
  padding: 12px 14px;
}

.actions-inline {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.actions-inline .btn {
  margin-top: 0 !important;
}

.photo-preview-wrap {
  position: relative;
}

.photo-check-progress {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(7, 14, 30, 0.52);
}

.photo-check-progress-label {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 8px;
}

.photo-check-progress-track {
  height: 8px;
  width: 100%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}

.photo-check-progress-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, #ff8a00 0%, #ffd86b 100%);
  transition: width 180ms linear;
}

.photo-check-progress-overlay {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  margin-top: 0;
  z-index: 3;
  pointer-events: none;
  background: rgba(7, 14, 30, 0.74);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.step[data-step="photo"] .preview,
.step[data-step="change-photo"] .preview {
  margin-bottom: 10px;
}

.preview img {
  width: 100%;
  height: auto;
  display: block;
}

.summary {
  background: rgba(9,12,18,0.6);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 16px;
  font-size: 14px;
  line-height: 1.4;
  white-space: pre-wrap;
}

.consent-block {
  margin: 2px 0 12px;
}

.consent-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.35;
}

.consent-checkbox input[type="checkbox"] {
  margin-top: 2px;
  accent-color: var(--accent);
}

.step > .grid + .summary {
  margin-top: 12px;
}

.step[data-step="change-menu"] #changeList {
  margin-top: 12px;
}

.code {
  background: rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 12px;
  font-size: 12px;
  color: var(--accent-2);
  overflow-x: auto;
}

.error {
  color: var(--error);
  font-size: 12px;
  margin: 0;
  min-height: 0;
}

.error:not(:empty) {
  margin: 8px 0 12px;
  min-height: 16px;
}

.step .error + .btn {
  margin-top: 10px;
}

.step .error:not(:empty) + .btn {
  margin-top: 0;
}

.step[data-step="change-fio"] [data-cancel-change] {
  margin-top: 12px;
}


.pickup-note {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 180, 84, 0.6);
  background: rgba(255, 122, 0, 0.14);
  color: #ffd9ab;
  font-size: 14px;
  font-weight: 700;
}

.status-timer {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 180, 84, 0.35);
  background: rgba(255, 180, 84, 0.08);
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 700;
}

.step.hidden { display: none; }
.hidden { display: none; }

@media (prefers-color-scheme: light) {
  :root {
    color-scheme: light;
    --bg: #f4f7fc;
    --bg-2: #e9eef7;
    --surface: #ffffff;
    --surface-2: #f6f9ff;
    --text: #1b2433;
    --muted: #627086;
    --shadow: 0 12px 26px rgba(26, 36, 56, 0.12);
  }

  body {
    background:
      radial-gradient(1200px 500px at 10% -10%, rgba(255, 122, 0, 0.14), transparent 60%),
      radial-gradient(900px 500px at 90% 0%, rgba(255, 180, 84, 0.1), transparent 60%),
      linear-gradient(160deg, var(--bg), var(--bg-2));
  }

  .app-header {
    background: rgba(255, 255, 255, 0.78);
    border-bottom: 1px solid rgba(30, 41, 59, 0.1);
  }

  .brand-logo {
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(255, 122, 0, 0.18);
  }

  .progress-track {
    background: rgba(30, 41, 59, 0.1);
  }

  .step {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(245, 249, 255, 0.95));
    border: 1px solid rgba(30, 41, 59, 0.12);
  }

  .input {
    border: 1px solid #ccd6e6;
    background: #ffffff;
    color: var(--text);
  }

  .input:focus {
    border-color: rgba(255, 122, 0, 0.66);
    box-shadow: 0 0 0 3px rgba(255, 122, 0, 0.14);
  }

  .btn.secondary {
    background: #f2f6fd;
    color: var(--text);
    border: 1px solid #d5deec;
  }

  .icon-btn {
    border-color: #d2dced;
    background: linear-gradient(180deg, #ffffff, #f1f6ff);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
  }

  .icon-btn:hover {
    border-color: rgba(255, 122, 0, 0.58);
    background: linear-gradient(180deg, rgba(255, 122, 0, 0.24), rgba(255, 122, 0, 0.12));
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.9),
      0 8px 16px rgba(255, 122, 0, 0.14);
  }

  .icon-btn.is-open {
    border-color: rgba(255, 122, 0, 0.64);
    background: linear-gradient(180deg, rgba(255, 122, 0, 0.28), rgba(255, 122, 0, 0.16));
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.9),
      0 9px 18px rgba(255, 122, 0, 0.18);
  }

  .icon-btn svg {
    stroke: #8b4d00;
    filter: none;
  }

  .btn.ghost {
    color: #67758c;
    border: 1px dashed #c7d0de;
  }

  .preview {
    background: #eef3fb;
    color: #65748b;
  }

  .summary {
    background: #f7faff;
    border: 1px solid #d8e0ee;
  }

  .photo-check-progress {
    background: #f6f9ff;
    border: 1px solid #d8e3f2;
  }

  .photo-check-progress-overlay {
    background: rgba(246, 249, 255, 0.9);
    box-shadow: 0 8px 18px rgba(43, 74, 122, 0.2);
  }

  .photo-check-progress-track {
    background: rgba(30, 41, 59, 0.14);
  }

  .intro-card {
    background: transparent;
    border: 1px solid transparent;
  }

  .code {
    background: #ffffff;
    border: 1px solid #d8e0ee;
    color: #9b5700;
  }

  .pickup-note {
    border: 1px solid rgba(255, 153, 51, 0.55);
    background: rgba(255, 122, 0, 0.1);
    color: #8c4c00;
  }

  .theme-toggle {
    border: 1px solid #d5deec;
    background: #f2f6fd;
  }
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f4f7fc;
  --bg-2: #e9eef7;
  --surface: #ffffff;
  --surface-2: #f6f9ff;
  --text: #1b2433;
  --muted: #627086;
  --shadow: 0 12px 26px rgba(26, 36, 56, 0.12);
}

:root[data-theme="light"] body {
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(255, 122, 0, 0.14), transparent 60%),
    radial-gradient(900px 500px at 90% 0%, rgba(255, 180, 84, 0.1), transparent 60%),
    linear-gradient(160deg, var(--bg), var(--bg-2));
}

:root[data-theme="light"] .app-header {
  background: rgba(255, 255, 255, 0.78);
  border-bottom: 1px solid rgba(30, 41, 59, 0.1);
}

:root[data-theme="light"] .brand-logo {
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(255, 122, 0, 0.18);
}

:root[data-theme="light"] .progress-track {
  background: rgba(30, 41, 59, 0.1);
}

:root[data-theme="light"] .step {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(245, 249, 255, 0.95));
  border: 1px solid rgba(30, 41, 59, 0.12);
}

:root[data-theme="light"] .input {
  border: 1px solid #ccd6e6;
  background: #ffffff;
  color: var(--text);
}

:root[data-theme="light"] .input:focus {
  border-color: rgba(255, 122, 0, 0.66);
  box-shadow: 0 0 0 3px rgba(255, 122, 0, 0.14);
}

:root[data-theme="light"] .btn.secondary {
  background: #f2f6fd;
  color: var(--text);
  border: 1px solid #d5deec;
}

:root[data-theme="light"] .icon-btn {
  border-color: #d2dced;
  background: linear-gradient(180deg, #ffffff, #f1f6ff);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
}

:root[data-theme="light"] .icon-btn:hover {
  border-color: rgba(255, 122, 0, 0.58);
  background: linear-gradient(180deg, rgba(255, 122, 0, 0.24), rgba(255, 122, 0, 0.12));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.9),
    0 8px 16px rgba(255, 122, 0, 0.14);
}

:root[data-theme="light"] .icon-btn.is-open {
  border-color: rgba(255, 122, 0, 0.64);
  background: linear-gradient(180deg, rgba(255, 122, 0, 0.28), rgba(255, 122, 0, 0.16));
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.9),
    0 9px 18px rgba(255, 122, 0, 0.18);
}

:root[data-theme="light"] .icon-btn svg {
  stroke: #8b4d00;
  filter: none;
}

:root[data-theme="light"] .btn.ghost {
  color: #67758c;
  border: 1px dashed #c7d0de;
}

:root[data-theme="light"] .preview {
  background: #eef3fb;
  color: #65748b;
}

:root[data-theme="light"] .summary {
  background: #f7faff;
  border: 1px solid #d8e0ee;
}

:root[data-theme="light"] .intro-card {
  background: transparent;
  border: 1px solid transparent;
}

:root[data-theme="light"] .code {
  background: #ffffff;
  border: 1px solid #d8e0ee;
  color: #9b5700;
}

:root[data-theme="light"] .pickup-note {
  border: 1px solid rgba(255, 153, 51, 0.55);
  background: rgba(255, 122, 0, 0.1);
  color: #8c4c00;
}

:root[data-theme="light"] .status-timer {
  border: 1px solid rgba(255, 153, 51, 0.35);
  background: rgba(255, 122, 0, 0.08);
  color: #9b5700;
}

:root[data-theme="light"] .theme-toggle {
  border: 1px solid #d5deec;
  background: #f2f6fd;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b0e12;
  --bg-2: #111826;
  --surface: #151e2b;
  --surface-2: #1b2636;
  --accent: #ff7a00;
  --accent-2: #ffb454;
  --text: #f6f7fb;
  --muted: #9aa6b2;
  --error: #ff5d5d;
  --shadow: 0 20px 50px rgba(0,0,0,0.35);
  --radius: 20px;
}

:root[data-theme="dark"] body {
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(255,122,0,0.18), transparent 60%),
    radial-gradient(900px 500px at 90% 0%, rgba(255,180,84,0.14), transparent 60%),
    linear-gradient(160deg, var(--bg), var(--bg-2));
}

:root[data-theme="dark"] .app-header {
  background: rgba(11,14,18,0.78);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

:root[data-theme="dark"] .brand-logo {
  background: #0c0c0c;
  box-shadow: 0 4px 12px rgba(255,122,0,0.2);
}

:root[data-theme="dark"] .progress-track {
  background: rgba(255,255,255,0.08);
}

:root[data-theme="dark"] .step {
  background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  border: 1px solid rgba(255,255,255,0.08);
}

:root[data-theme="dark"] .input {
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(9,12,18,0.8);
  color: var(--text);
}

:root[data-theme="dark"] .icon-btn {
  border-color: rgba(255,255,255,0.16);
  background: rgba(12, 18, 27, 0.62);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

:root[data-theme="dark"] .icon-btn:hover {
  border-color: rgba(255, 122, 0, 0.56);
  background: rgba(255, 122, 0, 0.2);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.14),
    0 7px 14px rgba(255, 122, 0, 0.16);
}

:root[data-theme="dark"] .icon-btn.is-open {
  border-color: rgba(255, 122, 0, 0.72);
  background: rgba(255, 122, 0, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.15),
    0 8px 16px rgba(255, 122, 0, 0.2);
}

:root[data-theme="dark"] .icon-btn svg {
  stroke: var(--accent-2);
  filter: drop-shadow(0 0 4px rgba(255, 122, 0, 0.3));
}

:root[data-theme="dark"] .btn.secondary {
  background: rgba(255,255,255,0.08);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.12);
}

:root[data-theme="dark"] .btn.ghost {
  color: var(--muted);
  border: 1px dashed rgba(255,255,255,0.2);
}

:root[data-theme="dark"] .preview {
  background: rgba(255,255,255,0.04);
  color: var(--muted);
}

:root[data-theme="dark"] .summary {
  background: rgba(9,12,18,0.6);
  border: 1px solid rgba(255,255,255,0.08);
}

:root[data-theme="dark"] .intro-card {
  background: transparent;
  border: 1px solid transparent;
}

:root[data-theme="dark"] .code {
  background: rgba(0,0,0,0.4);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--accent-2);
}

:root[data-theme="dark"] .pickup-note {
  border: 1px solid rgba(255, 180, 84, 0.6);
  background: rgba(255, 122, 0, 0.14);
  color: #ffd9ab;
}

:root[data-theme="dark"] .status-timer {
  border: 1px solid rgba(255, 180, 84, 0.35);
  background: rgba(255, 180, 84, 0.08);
  color: var(--accent-2);
}

:root[data-theme="dark"] .theme-toggle {
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.05);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes introStrokeRun {
  from { stroke-dashoffset: 0; }
  to { stroke-dashoffset: -1000; }
}

@keyframes introStrokeRunReverse {
  from { stroke-dashoffset: 0; }
  to { stroke-dashoffset: 1000; }
}

@keyframes introStrokeGlow {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 0.95; }
}

@keyframes startupLoaderRun {
  0% {
    transform: translateX(-115%);
  }
  55% {
    transform: translateX(65%);
  }
  100% {
    transform: translateX(240%);
  }
}

@media (min-width: 720px) {
  .app {
    align-items: center;
  }
  .app-header,
  .progress,
  .app-main {
    width: 420px;
  }
  .app-header {
    border-radius: 0 0 20px 20px;
  }
}
