:root {
  --cream: #f6efe4;
  --paper: #fffdf9;
  --paper-soft: #fcf7ef;
  --ink: #242221;
  --muted: #766f67;
  --line: #eadfce;
  --gold: #c58a3b;
  --gold-dark: #9b6324;
  --gold-pale: #fff4df;
  --sage: #6f806f;
  --danger: #a84c3b;
  --shadow: 0 28px 80px rgba(94, 63, 29, 0.14);
  --radius-card: 30px;
  --radius-control: 14px;
  font-family: "DM Sans", "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--cream);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--cream);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 12% 10%, rgba(197, 138, 59, 0.13), transparent 25rem),
    radial-gradient(circle at 90% 84%, rgba(111, 128, 111, 0.11), transparent 28rem),
    var(--cream);
}

button,
input,
textarea {
  font: inherit;
}

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

.page-shell {
  position: relative;
  display: grid;
  min-height: 100vh;
  place-items: center;
  overflow: hidden;
  padding: 30px 18px 26px;
}

.ambient-glow {
  position: fixed;
  width: 280px;
  height: 280px;
  pointer-events: none;
  border: 1px solid rgba(197, 138, 59, 0.15);
  border-radius: 50%;
}

.ambient-glow::after {
  position: absolute;
  inset: 20px;
  content: "";
  border: 1px solid rgba(197, 138, 59, 0.1);
  border-radius: inherit;
}

.ambient-glow--top {
  top: -170px;
  left: -130px;
}

.ambient-glow--bottom {
  right: -150px;
  bottom: -180px;
  border-color: rgba(111, 128, 111, 0.16);
}

.survey-card {
  position: relative;
  z-index: 1;
  width: min(100%, 680px);
  padding: clamp(23px, 5vw, 50px);
  background: rgba(255, 253, 249, 0.95);
  border: 1px solid rgba(197, 138, 59, 0.17);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow);
}

.brand-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 21px;
  border-bottom: 1px solid var(--line);
}

.brand-kicker,
.location-label,
.eyebrow,
.rating-scale,
.rating-hint,
.card-footer {
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.brand-kicker {
  color: var(--gold-dark);
  font-size: 10px;
  font-weight: 700;
}

.brand-pip {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  background: var(--gold);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(197, 138, 59, 0.12);
}

.brand-lockup {
  display: grid;
  justify-items: center;
  padding: 28px 0 20px;
  text-align: center;
}

.logo-frame {
  display: grid;
  width: min(100%, 330px);
  overflow: hidden;
  background: #fff;
  border: 1px solid rgba(197, 138, 59, 0.14);
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(83, 56, 30, 0.07);
}

.brand-logo {
  display: block;
  width: 100%;
  height: auto;
  mix-blend-mode: multiply;
}

.location-label {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.intro-copy {
  max-width: 565px;
  margin: 4px auto 0;
  text-align: center;
}

.eyebrow {
  margin: 0 0 13px;
  color: var(--sage);
  font-size: 11px;
  font-weight: 800;
}

h1,
h2,
legend {
  font-family: "Playfair Display", Georgia, serif;
}

h1 {
  max-width: 550px;
  margin: 0 auto;
  color: var(--ink);
  font-size: clamp(31px, 5vw, 49px);
  font-weight: 600;
  letter-spacing: -0.045em;
  line-height: 1.04;
  text-wrap: balance;
}

.supporting-copy {
  max-width: 430px;
  margin: 17px auto 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  text-wrap: pretty;
}

.rating-block {
  margin-top: 31px;
  padding: 20px 18px 17px;
  background: var(--paper-soft);
  border: 1px solid var(--line);
  border-radius: 21px;
}

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

.rating-label {
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.rating-scale {
  color: var(--muted);
  font-size: 11px;
}

.stars {
  display: flex;
  justify-content: center;
  gap: clamp(6px, 2.2vw, 14px);
  margin-top: 18px;
}

.star-button {
  display: grid;
  width: clamp(49px, 12vw, 67px);
  height: clamp(49px, 12vw, 67px);
  place-items: center;
  padding: 0;
  color: #d8d0c3;
  background: var(--paper);
  border: 1px solid #e2d5c2;
  border-radius: 18px;
  cursor: pointer;
  font-size: clamp(28px, 7vw, 38px);
  line-height: 1;
  transition: transform 180ms ease, color 180ms ease, background-color 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.star-button:hover,
.star-button:focus-visible {
  color: var(--gold);
  border-color: rgba(197, 138, 59, 0.72);
  box-shadow: 0 8px 20px rgba(197, 138, 59, 0.2);
  outline: none;
  transform: translateY(-2px);
}

.star-button:focus-visible {
  box-shadow: 0 0 0 4px rgba(197, 138, 59, 0.16), 0 8px 20px rgba(197, 138, 59, 0.2);
}

.star-button.is-preview,
.star-button[aria-checked="true"] {
  color: var(--gold);
  background: var(--gold-pale);
  border-color: rgba(197, 138, 59, 0.62);
}

.star-button[aria-checked="true"] {
  box-shadow: 0 8px 20px rgba(197, 138, 59, 0.15);
  transform: translateY(-2px);
}

.rating-hint {
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
  text-align: center;
}

.preview-state {
  min-height: 18px;
  margin: 10px 0 0;
  color: var(--gold-dark);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.45;
  text-align: center;
}

.feedback-panel {
  margin-top: 18px;
  padding: 26px 23px 22px;
  background: #fffaf3;
  border: 1px solid rgba(197, 138, 59, 0.2);
  border-radius: 21px;
  animation: panel-in 260ms ease both;
}

.panel-heading h2,
.success-state h2 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(24px, 4vw, 32px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-wrap: pretty;
}

.panel-heading > p:last-child,
.success-state p {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

#feedback-form {
  display: grid;
  gap: 24px;
  margin-top: 25px;
}

.question-group {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.question-group legend {
  width: 100%;
  margin-bottom: 11px;
  color: var(--ink);
  font-size: 17px;
  font-weight: 600;
  line-height: 1.25;
}

.question-group legend span {
  color: var(--gold-dark);
}

.choice-grid {
  display: grid;
  gap: 9px;
}

.choice-grid--three {
  grid-template-columns: repeat(3, 1fr);
}

.choice-grid--four {
  grid-template-columns: repeat(4, 1fr);
}

.choice-grid--chips {
  display: flex;
  flex-wrap: wrap;
}

.choice-card {
  position: relative;
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 9px 10px;
  color: var(--muted);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  transition: color 160ms ease, border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.choice-card input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.choice-card:hover,
.choice-card:focus-within {
  border-color: rgba(197, 138, 59, 0.6);
  color: var(--gold-dark);
}

.choice-card:has(input:checked) {
  color: var(--gold-dark);
  background: var(--gold-pale);
  border-color: rgba(197, 138, 59, 0.78);
  box-shadow: 0 4px 10px rgba(197, 138, 59, 0.08);
  transform: translateY(-1px);
}

.choice-card--chip {
  min-height: 40px;
  padding-inline: 14px;
  border-radius: 999px;
}

.field-group {
  display: grid;
  gap: 9px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
}

.field-group textarea {
  width: 100%;
  min-height: 110px;
  resize: vertical;
  padding: 13px 14px;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-control);
  font-size: 14px;
  font-weight: 500;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.field-group textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(197, 138, 59, 0.13);
}

.form-feedback {
  margin: -7px 0 0;
  padding: 10px 12px;
  color: var(--danger);
  background: #fff1ed;
  border: 1px solid #ebc5ba;
  border-radius: 11px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.45;
}

.submit-button,
.secondary-button {
  min-height: 49px;
  padding: 12px 18px;
  border-radius: var(--radius-control);
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  transition: transform 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.submit-button {
  color: #fffdf9;
  background: var(--gold-dark);
  border: 0;
}

.submit-button:hover,
.submit-button:focus-visible,
.secondary-button:hover,
.secondary-button:focus-visible {
  box-shadow: 0 9px 18px rgba(155, 99, 36, 0.2);
  outline: none;
  transform: translateY(-1px);
}

.submit-button:hover,
.submit-button:focus-visible {
  background: #814b16;
}

.submit-button:disabled {
  cursor: wait;
  opacity: 0.65;
  transform: none;
}

.success-state {
  padding: 24px 4px 4px;
  text-align: center;
}

.success-icon {
  display: grid;
  width: 46px;
  height: 46px;
  margin: 0 auto 16px;
  place-items: center;
  color: #fff;
  background: var(--sage);
  border-radius: 50%;
  font-size: 23px;
  font-weight: 800;
}

.secondary-button {
  margin-top: 21px;
  color: var(--gold-dark);
  background: var(--paper);
  border: 1px solid rgba(197, 138, 59, 0.45);
}

.card-footer {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-top: 29px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
  text-align: center;
}

.footer-line {
  flex: 1;
  height: 1px;
  background: var(--line);
}

.creator-credit {
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.4;
  text-align: center;
}

.creator-credit a {
  color: var(--gold-dark);
  font-weight: 700;
  text-decoration: none;
  text-underline-offset: 3px;
}

.creator-credit a:hover,
.creator-credit a:focus-visible {
  text-decoration: underline;
}

[hidden] {
  display: none !important;
}

@keyframes panel-in {
  from {
    opacity: 0;
    transform: translateY(-7px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 580px) {
  .page-shell {
    display: flex;
    align-items: center;
    padding: 16px 10px 28px;
  }

  .survey-card {
    padding: 20px 15px 22px;
    border-radius: 24px;
  }

  .brand-header {
    padding-bottom: 18px;
  }

  .brand-kicker {
    max-width: 240px;
    font-size: 9px;
    line-height: 1.35;
  }

  .brand-lockup {
    padding: 22px 0 17px;
  }

  .logo-frame {
    width: min(92%, 285px);
    border-radius: 13px;
  }

  .location-label {
    max-width: 260px;
    font-size: 9px;
    line-height: 1.4;
  }

  h1 {
    font-size: clamp(29px, 9vw, 39px);
  }

  .supporting-copy {
    margin-top: 14px;
    font-size: 14px;
  }

  .rating-block {
    margin-top: 25px;
    padding: 16px 11px 14px;
  }

  .stars {
    gap: 5px;
    margin-top: 15px;
  }

  .star-button {
    border-radius: 14px;
  }

  .feedback-panel {
    padding: 22px 15px 17px;
    border-radius: 18px;
  }

  .panel-heading h2 {
    font-size: 25px;
  }

  .question-group legend {
    font-size: 16px;
  }

  .choice-grid--three,
  .choice-grid--four {
    grid-template-columns: repeat(2, 1fr);
  }

  .choice-card {
    font-size: 11px;
  }

  .card-footer {
    margin-top: 23px;
    font-size: 8px;
  }
}

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