:root {
  --bg: #07090d;
  --bg-soft: #10141d;
  --card: rgba(18, 22, 32, 0.88);
  --card-strong: rgba(24, 30, 43, 0.96);
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.18);
  --text: #f6f1e8;
  --muted: #a9afbd;
  --soft: #d9deea;
  --gold: #d7b46a;
  --mint: #5ee0bb;
  --rose: #d7799d;
  --danger: #f08f8f;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
  --radius: 24px;
  --radius-sm: 16px;
  --focus: 0 0 0 4px rgba(215, 180, 106, 0.18);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(215, 180, 106, 0.2), transparent 34rem),
    radial-gradient(circle at 85% 10%, rgba(94, 224, 187, 0.11), transparent 24rem),
    linear-gradient(145deg, #050608 0%, #0a0d14 42%, #121623 100%);
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
}

[hidden] {
  display: none !important;
}

.app-shell {
  width: min(100%, 760px);
  margin: 0 auto;
  padding: 22px 16px 44px;
}

.hero {
  position: relative;
  overflow: hidden;
  margin: 8px 0 18px;
  padding: 34px 24px 30px;
  border: 1px solid var(--line);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(215, 180, 106, 0.16), rgba(94, 224, 187, 0.08) 46%, rgba(215, 121, 157, 0.12)),
    rgba(14, 18, 27, 0.9);
  box-shadow: var(--shadow);
}

.hero::after {
  position: absolute;
  right: -80px;
  bottom: -110px;
  width: 220px;
  height: 220px;
  border: 1px solid rgba(215, 180, 106, 0.28);
  border-radius: 50%;
  content: "";
}

.hero__badge {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  margin-bottom: 18px;
  padding: 8px 13px;
  border: 1px solid rgba(215, 180, 106, 0.28);
  border-radius: 999px;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.04);
}

.hero h1,
.section-heading h2 {
  margin: 0;
  letter-spacing: 0;
}

.hero h1 {
  max-width: 9ch;
  font-size: clamp(2.45rem, 12vw, 4.5rem);
  line-height: 0.94;
}

.hero p {
  max-width: 25rem;
  margin: 18px 0 0;
  color: var(--soft);
  font-size: 1.05rem;
  line-height: 1.55;
}

.card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), transparent 18rem),
    var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.form-card {
  padding: 22px;
}

.output-card {
  margin-top: 18px;
  padding: 22px;
}

.section-heading {
  margin-bottom: 20px;
}

.output-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.section-kicker {
  display: block;
  margin-bottom: 8px;
  color: var(--mint);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.section-heading h2 {
  font-size: 1.25rem;
}

.listing-form {
  display: grid;
  gap: 18px;
}

.shoe-fields {
  display: grid;
  gap: 18px;
}

.field,
.choice-group {
  min-width: 0;
}

.field label,
.choice-group legend {
  display: block;
  margin-bottom: 10px;
  color: var(--soft);
  font-size: 0.92rem;
  font-weight: 750;
}

.choice-group {
  margin: 0;
  padding: 0;
  border: 0;
}

input[type="text"],
select,
textarea {
  width: 100%;
  min-height: 56px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--text);
  outline: none;
  background: rgba(255, 255, 255, 0.055);
  transition: border-color 180ms ease, background 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

textarea {
  min-height: 132px;
  padding-top: 16px;
  resize: vertical;
  line-height: 1.55;
}

select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--gold) 50%),
    linear-gradient(135deg, var(--gold) 50%, transparent 50%);
  background-position:
    calc(100% - 22px) 50%,
    calc(100% - 15px) 50%;
  background-size: 7px 7px;
  background-repeat: no-repeat;
}

input::placeholder,
textarea::placeholder {
  color: rgba(217, 222, 234, 0.45);
}

input[type="text"]:hover,
select:hover,
textarea:hover {
  border-color: var(--line-strong);
  background-color: rgba(255, 255, 255, 0.075);
}

input[type="text"]:focus,
select:focus,
textarea:focus {
  border-color: rgba(215, 180, 106, 0.65);
  box-shadow: var(--focus);
}

.pill-grid,
.chip-grid,
.mode-grid {
  display: grid;
  gap: 10px;
}

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

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

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

.pill-radio,
.chip,
.mode-card {
  display: block;
  cursor: pointer;
}

.pill-radio input,
.chip input,
.mode-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.pill-radio span,
.chip span,
.mode-card span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.045);
  transition: border-color 180ms ease, color 180ms ease, background 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}

.chip span {
  justify-content: flex-start;
  text-align: left;
}

.pill-radio:hover span,
.chip:hover span,
.mode-card:hover span {
  border-color: rgba(255, 255, 255, 0.22);
  color: var(--text);
  transform: translateY(-1px);
}

.pill-radio input:focus-visible + span,
.chip input:focus-visible + span,
.mode-card input:focus-visible + span {
  box-shadow: var(--focus);
}

.pill-radio input:checked + span,
.chip input:checked + span,
.mode-card input:checked + span {
  border-color: rgba(215, 180, 106, 0.72);
  color: var(--text);
  background:
    linear-gradient(135deg, rgba(215, 180, 106, 0.22), rgba(94, 224, 187, 0.11)),
    rgba(255, 255, 255, 0.08);
}

.mode-selector {
  margin-top: 4px;
  padding: 16px;
  border: 1px solid rgba(215, 180, 106, 0.14);
  border-radius: 20px;
  background: rgba(215, 180, 106, 0.035);
}

.mode-card span {
  min-height: 58px;
  font-weight: 800;
}

.generate-button,
.copy-button {
  min-height: 56px;
  border-radius: 16px;
  color: #111318;
  cursor: pointer;
  font-weight: 900;
  background: linear-gradient(135deg, var(--gold), #f1d99b 45%, var(--mint));
  box-shadow: 0 18px 36px rgba(215, 180, 106, 0.2);
  transition: transform 180ms ease, filter 180ms ease, box-shadow 180ms ease;
}

.generate-button {
  width: 100%;
  margin-top: 6px;
  font-size: 1.02rem;
}

.copy-button {
  min-width: 96px;
  padding: 0 18px;
}

.generate-button:hover,
.copy-button:hover:not(:disabled) {
  filter: brightness(1.05);
  transform: translateY(-2px);
  box-shadow: 0 20px 42px rgba(94, 224, 187, 0.18);
}

.generate-button:active,
.copy-button:active:not(:disabled) {
  transform: translateY(0);
}

.generate-button:focus-visible,
.copy-button:focus-visible {
  outline: none;
  box-shadow: var(--focus), 0 18px 36px rgba(215, 180, 106, 0.2);
}

.copy-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  filter: grayscale(0.4);
}

.feedback {
  display: block;
  min-height: 22px;
  margin: -6px 0 10px;
  color: var(--mint);
  font-size: 0.9rem;
  font-weight: 750;
}

.feedback--error {
  color: var(--danger);
}

.prompt-output {
  min-height: 260px;
  max-height: 520px;
  margin: 0;
  padding: 18px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 18px;
  color: #eef3f7;
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.58;
  background: rgba(0, 0, 0, 0.26);
}

@media (min-width: 620px) {
  .app-shell {
    padding: 34px 24px 64px;
  }

  .hero {
    padding: 42px 36px;
  }

  .hero h1 {
    max-width: none;
  }

  .form-card,
  .output-card {
    padding: 30px;
  }

  .listing-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }

  .choice-group,
  .field:has(textarea),
  .shoe-fields,
  .mode-selector,
  .generate-button {
    grid-column: 1 / -1;
  }

  .shoe-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }

  .chip-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .mode-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto;
    transition-duration: 0.01ms;
  }
}
