:root {
  --metal-0: #f3f4f5;
  --metal-1: #e6e8eb;
  --metal-2: #d4d8dd;
  --ink: #172020;
  --dark: #202629;
  --muted: #697278;
  --line: rgba(23, 32, 32, 0.1);
  --white: #ffffff;
  --accent: #ef4128;
  --blue: #2284ff;
  --green: #18a56f;
  --font-display: "Barlow Condensed", "Arial Narrow", Arial, sans-serif;
  --font-body: "Inter", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body {
  color: var(--ink);
  font-family: var(--font-body);
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.62), transparent 34%),
    linear-gradient(145deg, var(--metal-0), var(--metal-1) 44%, var(--metal-2));
}

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

button,
input,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

[hidden] {
  display: none !important;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 18px;
  height: 18px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.performance-shell {
  width: min(100%, 430px);
  min-height: 100svh;
  margin: 0 auto;
  padding: max(14px, env(safe-area-inset-top)) 14px max(18px, env(safe-area-inset-bottom));
}

.performance-shell.has-result {
  min-height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr;
}

.performance-shell.has-result .performance-hero,
.performance-shell.has-result .wizard-stage {
  display: none;
}

.page-header {
  display: grid;
  grid-template-columns: 42px 1fr 42px;
  align-items: center;
  gap: 10px;
}

.icon-button {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.48);
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.68);
  backdrop-filter: blur(18px);
  cursor: pointer;
}

.brand-wordmark {
  justify-self: center;
  display: grid;
  justify-items: center;
}

.brand-wordmark span {
  color: #2b3235;
  font-family: var(--font-display);
  font-size: 24px;
  line-height: 0.84;
  font-style: italic;
  font-weight: 800;
  text-transform: uppercase;
  transform: skewX(-7deg);
}

.brand-wordmark small {
  margin-top: 4px;
  color: #2b3235;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.performance-hero {
  min-height: 168px;
  margin: 18px 0 14px;
  padding: 20px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 82px;
  align-items: end;
  gap: 14px;
  border-radius: 28px;
  background:
    radial-gradient(circle at 88% 8%, rgba(34, 132, 255, 0.24), transparent 36%),
    linear-gradient(135deg, rgba(32, 38, 41, 0.98), rgba(48, 55, 58, 0.94));
  color: var(--white);
  box-shadow: 0 18px 44px rgba(23, 32, 32, 0.18);
}

.eyebrow {
  margin: 0 0 8px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.performance-hero h1,
.loading-panel h2,
.result-title {
  margin: 0;
  font-family: var(--font-display);
  font-size: 42px;
  line-height: 0.9;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.performance-hero p:not(.eyebrow),
.loading-panel p,
.result-summary {
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 12px;
  line-height: 1.45;
  font-weight: 700;
}

.hero-meter {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  gap: 2px;
  align-content: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.1);
}

.hero-meter .icon {
  width: 24px;
  height: 24px;
}

.hero-meter span {
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.wizard-panel,
.loading-panel,
.result-panel {
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.74),
    0 12px 34px rgba(23, 32, 32, 0.08);
}

.wizard-stage {
  position: relative;
}

.wizard-panel.is-blocked {
  pointer-events: none;
  user-select: none;
  filter: blur(2px);
  transform: scale(0.995);
}

.step-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.progress-track {
  margin: 12px 0 18px;
  display: grid;
  grid-template-columns: repeat(var(--step-count, 6), 1fr);
  gap: 5px;
}

.progress-track span {
  height: 4px;
  border-radius: 999px;
  background: rgba(23, 32, 32, 0.12);
}

.progress-track span.active {
  background: var(--dark);
}

.wizard-panel h2 {
  margin: 0;
  color: var(--dark);
  font-family: var(--font-display);
  font-size: 36px;
  line-height: 0.92;
  font-weight: 800;
  text-transform: uppercase;
}

.wizard-panel p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  font-weight: 700;
}

.answer-area {
  margin-top: 16px;
  display: grid;
  gap: 10px;
}

.choice-button {
  width: 100%;
  min-height: 52px;
  padding: 12px 13px;
  display: grid;
  grid-template-columns: 24px 1fr;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(23, 32, 32, 0.1);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.52);
  color: var(--dark);
  text-align: left;
  cursor: pointer;
}

.choice-button .choice-dot {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(23, 32, 32, 0.16);
  border-radius: 50%;
}

.choice-button .choice-dot::after {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: transparent;
}

.choice-button strong {
  display: block;
  font-size: 13px;
  line-height: 1.2;
  font-weight: 900;
}

.choice-button small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.3;
  font-weight: 700;
}

.choice-button.selected {
  border-color: rgba(32, 38, 41, 0.94);
  background: var(--dark);
  color: var(--white);
}

.choice-button.selected small {
  color: rgba(255, 255, 255, 0.7);
}

.choice-button.selected .choice-dot {
  border-color: rgba(255, 255, 255, 0.42);
}

.choice-button.selected .choice-dot::after {
  background: var(--white);
}

.field-label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.field-label input,
.field-label textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(23, 32, 32, 0.1);
  border-radius: 18px;
  outline: 0;
  background: rgba(255, 255, 255, 0.56);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.field-label input {
  min-height: 48px;
  padding: 0 13px;
}

.field-label textarea {
  min-height: 104px;
  padding: 12px 13px;
  resize: vertical;
  line-height: 1.4;
}

.media-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(32, 38, 41, 0.08), rgba(255, 255, 255, 0.34));
}

.voice-button,
.upload-drop {
  min-height: 52px;
  display: grid;
  align-items: center;
  border: 1px solid rgba(23, 32, 32, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--dark);
  cursor: pointer;
}

.voice-button {
  grid-template-columns: 22px 1fr;
  gap: 10px;
  padding: 0 13px;
  text-align: left;
  font-size: 13px;
  font-weight: 900;
}

.voice-button.is-recording {
  background: rgba(239, 65, 40, 0.12);
  color: #8c2b1f;
}

.record-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 5px rgba(239, 65, 40, 0.12);
}

.voice-button.is-recording .record-dot {
  animation: pulseRecord 900ms ease-in-out infinite;
}

.media-hint {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
  font-weight: 700;
}

.member-note {
  margin: 2px 0 0;
  padding: 10px 12px;
  border: 1px solid rgba(34, 132, 255, 0.18);
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(34, 132, 255, 0.1), rgba(255, 255, 255, 0.42));
  color: var(--dark);
  font-size: 11px;
  line-height: 1.45;
  font-weight: 800;
}

.upload-drop {
  position: relative;
  min-height: 76px;
  padding: 13px;
  gap: 4px;
  text-align: center;
}

.upload-drop span {
  color: var(--dark);
  font-size: 13px;
  font-weight: 900;
}

.upload-drop small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
  font-weight: 700;
}

.file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.preview-box {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 18px;
  background: var(--dark);
}

.preview-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.wizard-actions,
.result-actions,
.recommendation-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.wizard-actions {
  margin-top: 18px;
}

.ghost-button,
.solid-button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.ghost-button {
  border: 1px solid rgba(23, 32, 32, 0.12);
  background: rgba(255, 255, 255, 0.48);
  color: var(--dark);
}

.solid-button {
  border: 1px solid var(--dark);
  background: var(--dark);
  color: var(--white);
}

.ghost-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.loading-panel {
  position: absolute;
  inset: 0;
  z-index: 5;
  margin-top: 0;
  display: grid;
  place-items: center;
  min-height: 100%;
  padding: 28px 18px;
  text-align: center;
  color: var(--white);
  background:
    radial-gradient(circle at 50% 12%, rgba(34, 132, 255, 0.2), transparent 34%),
    linear-gradient(135deg, rgba(32, 38, 41, 0.98), rgba(48, 55, 58, 0.94));
}

.loader-ring {
  width: 58px;
  height: 58px;
  border: 4px solid rgba(255, 255, 255, 0.18);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 820ms linear infinite;
}

.loading-panel .eyebrow {
  margin-top: 18px;
}

.result-panel {
  margin-top: 18px;
  display: grid;
  gap: 14px;
}

.performance-shell.has-result .result-panel {
  min-height: calc(100svh - 88px);
  align-content: start;
}

.status-card {
  padding: 18px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 92% 0%, rgba(34, 132, 255, 0.18), transparent 36%),
    linear-gradient(135deg, rgba(32, 38, 41, 0.98), rgba(48, 55, 58, 0.94));
  color: var(--white);
}

.score-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.score-pill {
  min-width: 72px;
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  text-align: center;
  font-size: 18px;
  font-weight: 900;
}

.status-label {
  color: rgba(255, 255, 255, 0.64);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.result-section {
  display: grid;
  gap: 9px;
}

.section-title {
  margin: 0;
  color: var(--dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.finding-list,
.next-list {
  display: grid;
  gap: 8px;
}

.finding-item,
.next-item,
.warning-strip {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 9px;
  align-items: start;
  padding: 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.46);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  font-weight: 700;
}

.finding-item .icon,
.next-item .icon {
  color: var(--blue);
}

.finding-item strong,
.next-item strong {
  display: block;
  margin-bottom: 2px;
  color: var(--dark);
  font-weight: 900;
}

.warning-strip {
  background: rgba(239, 65, 40, 0.09);
  color: #8c2b1f;
}

.warning-strip .icon {
  color: var(--accent);
}

.recommendation-list {
  display: grid;
  gap: 10px;
}

.recommendation-card {
  padding: 13px;
  display: grid;
  gap: 10px;
  border: 1px solid rgba(23, 32, 32, 0.08);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.5);
}

.product-line {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.product-line h3 {
  margin: 0;
  color: var(--dark);
  font-size: 14px;
  line-height: 1.18;
  font-weight: 900;
}

.product-line span {
  flex: 0 0 auto;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
}

.recommendation-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  font-weight: 700;
}

.recommendation-card p strong {
  color: var(--dark);
}

.priority-badge {
  width: fit-content;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(32, 38, 41, 0.08);
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.recommendation-actions .ghost-button,
.recommendation-actions .solid-button {
  min-height: 40px;
  font-size: 12px;
}

.result-actions {
  grid-template-columns: 1fr;
}

.exit-offer-overlay {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: end center;
  padding: 16px 14px max(16px, env(safe-area-inset-bottom));
  background:
    radial-gradient(circle at 50% 100%, rgba(34, 132, 255, 0.16), transparent 38%),
    rgba(10, 13, 14, 0.58);
  backdrop-filter: blur(16px);
}

.exit-offer-overlay[hidden] {
  display: none;
}

.has-exit-offer {
  overflow: hidden;
}

.exit-offer-card {
  position: relative;
  width: min(100%, 402px);
  padding: 22px 18px 18px;
  display: grid;
  gap: 13px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 28px;
  background:
    radial-gradient(circle at 92% 8%, rgba(34, 132, 255, 0.24), transparent 32%),
    linear-gradient(145deg, rgba(32, 38, 41, 0.98), rgba(19, 24, 26, 0.98));
  color: var(--white);
  box-shadow: 0 22px 64px rgba(0, 0, 0, 0.32);
}

.exit-offer-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.76);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.exit-offer-card h2 {
  margin: 0;
  padding-right: 28px;
  font-family: var(--font-display);
  font-size: 42px;
  line-height: 0.9;
  font-weight: 800;
  text-transform: uppercase;
}

.exit-offer-copy {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  line-height: 1.5;
  font-weight: 750;
}

.exit-offer-timer,
.exit-offer-code {
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
}

.exit-offer-timer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.exit-offer-timer span {
  font-family: var(--font-display);
  font-size: 34px;
  line-height: 0.9;
  font-weight: 800;
}

.exit-offer-timer small,
.exit-offer-code small {
  color: rgba(255, 255, 255, 0.58);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.exit-offer-code {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
}

.exit-offer-code strong {
  padding: 6px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, #2284ff, #ff7a1a);
  color: var(--white);
  font-size: 12px;
  font-weight: 950;
  letter-spacing: 0.08em;
}

.exit-offer-actions {
  display: grid;
  gap: 9px;
}

.exit-offer-card .ghost-button {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
}

.plain-exit-button {
  min-height: 38px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.6);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.action-hero {
  min-height: 146px;
}

.action-panel {
  padding: 18px;
  display: grid;
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.74),
    0 12px 34px rgba(23, 32, 32, 0.08);
}

.summary-box {
  padding: 14px;
  display: grid;
  gap: 8px;
  border-radius: 20px;
  background: rgba(32, 38, 41, 0.08);
}

.summary-box strong {
  color: var(--dark);
  font-size: 13px;
  font-weight: 900;
}

.summary-box p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
  font-weight: 700;
}

.summary-box .product-price-mini {
  width: fit-content;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(239, 65, 40, 0.1);
  color: var(--accent);
  font-size: 11px;
  font-weight: 900;
}

.mock-form {
  display: grid;
  gap: 11px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.mock-note {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
  font-weight: 700;
}

.inline-status {
  min-height: 44px;
  padding: 12px;
  display: none;
  align-items: center;
  gap: 9px;
  border-radius: 16px;
  background: rgba(24, 165, 111, 0.1);
  color: #0f7650;
  font-size: 12px;
  line-height: 1.4;
  font-weight: 800;
}

.inline-status.is-visible {
  display: flex;
}

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

@keyframes pulseRecord {
  0%,
  100% {
    transform: scale(0.9);
    opacity: 0.72;
  }

  50% {
    transform: scale(1.12);
    opacity: 1;
  }
}

@media (min-width: 768px) {
  body {
    display: grid;
    place-items: start center;
    background:
      radial-gradient(circle at 50% 8%, rgba(255, 255, 255, 0.22), transparent 34%),
      #121719;
  }

  .performance-shell {
    min-height: 100vh;
    box-shadow: 0 24px 90px rgba(0, 0, 0, 0.18);
  }
}
