:root {
  --red-950: #4a0710;
  --red-900: #650815;
  --red-800: #7f0a19;
  --red-700: #a30d1f;
  --red-600: #c3192d;
  --red-500: #dc3043;
  --red-100: #ffe4e8;
  --red-50: #fff4f5;
  --cream: #fffaf7;
  --paper: #ffffff;
  --ink: #231c1e;
  --muted: #74696c;
  --line: #eadfe1;
  --green: #23794a;
  --amber: #986208;
  --shadow-lg: 0 32px 90px rgba(84, 7, 20, 0.18);
  --shadow-md: 0 18px 42px rgba(72, 18, 29, 0.12);
  --radius-xl: 30px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .72), rgba(255, 244, 245, .86)),
    repeating-linear-gradient(90deg, rgba(127, 10, 25, .025) 0, rgba(127, 10, 25, .025) 1px, transparent 1px, transparent 38px),
    #f8eeee;
  font-family: Arial, Helvetica, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

button,
input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

h1,
h2,
h3,
p { margin-top: 0; }

h1,
h2,
h3,
.brand-title {
  font-family: Georgia, "Times New Roman", serif;
  color: var(--ink);
  letter-spacing: -.025em;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(2.25rem, 5vw, 4rem);
  line-height: 1.03;
  font-weight: 700;
}

h2 {
  margin-bottom: 24px;
  font-size: clamp(1.75rem, 3.4vw, 2.65rem);
  line-height: 1.16;
  font-weight: 700;
  outline: none;
}

h3 {
  margin-bottom: 14px;
  font-size: 1.25rem;
  line-height: 1.25;
}

p {
  margin-bottom: 14px;
  font-size: 1.02rem;
  line-height: 1.72;
}

.muted { color: var(--muted); }

.ambient-shape {
  position: fixed;
  z-index: -1;
  pointer-events: none;
  opacity: .8;
}

.ambient-shape-one {
  width: 340px;
  height: 340px;
  top: -120px;
  right: -70px;
  background: linear-gradient(140deg, rgba(195, 25, 45, .2), rgba(127, 10, 25, .04));
  clip-path: polygon(50% 0, 100% 30%, 82% 100%, 12% 85%, 0 25%);
  animation: driftOne 11s ease-in-out infinite alternate;
}

.ambient-shape-two {
  width: 280px;
  height: 280px;
  bottom: -110px;
  left: -80px;
  border: 40px solid rgba(163, 13, 31, .1);
  border-radius: 50%;
  animation: driftTwo 13s ease-in-out infinite alternate;
}

.page-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 34px;
}

.survey-frame {
  width: min(1120px, 100%);
  min-height: 660px;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  border: 1px solid rgba(127, 10, 25, .12);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: var(--paper);
  animation: frameIn .7s cubic-bezier(.18, .78, .2, 1) both;
}

.brand-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 36px;
  padding: 42px 36px;
  color: #fff;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, .08), transparent 42%),
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, .035) 0, rgba(255, 255, 255, .035) 2px, transparent 2px, transparent 16px),
    linear-gradient(160deg, var(--red-700), var(--red-950));
  overflow: hidden;
}

.brand-panel::before {
  content: "";
  position: absolute;
  width: 210px;
  height: 210px;
  right: -88px;
  top: 160px;
  border: 28px solid rgba(255, 255, 255, .08);
  transform: rotate(25deg);
}

.brand-panel::after {
  content: "";
  position: absolute;
  width: 120px;
  height: 120px;
  left: -60px;
  bottom: 105px;
  background: rgba(255, 255, 255, .06);
  transform: rotate(45deg);
}

.brand-mark {
  position: relative;
  z-index: 1;
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .42);
  background: rgba(255, 255, 255, .12);
  transform: rotate(-8deg);
  box-shadow: inset 0 0 0 7px rgba(255, 255, 255, .05);
}

.brand-mark span {
  color: #fff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2rem;
  font-weight: 700;
  transform: rotate(8deg);
}

.brand-kicker,
.eyebrow,
.question-number {
  display: inline-block;
  font-size: .73rem;
  line-height: 1.25;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.brand-kicker { color: rgba(255, 255, 255, .72); }

.brand-title {
  position: relative;
  z-index: 1;
  margin: 16px 0 0;
  color: #fff;
  font-size: 2rem;
  line-height: 1.13;
}

.brand-note {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 9px;
}

.brand-note span {
  width: fit-content;
  padding: 8px 11px;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 999px;
  color: rgba(255, 255, 255, .82);
  background: rgba(255, 255, 255, .06);
  font-size: .79rem;
}

.survey-card {
  min-width: 0;
  display: flex;
  align-items: center;
  padding: clamp(34px, 6vw, 74px);
  background:
    linear-gradient(rgba(255, 255, 255, .95), rgba(255, 255, 255, .98)),
    radial-gradient(circle at 100% 0, var(--red-50), transparent 45%);
}

.survey-card form { width: 100%; }

.eyebrow,
.question-number {
  margin-bottom: 14px;
  color: var(--red-700);
}

.welcome-screen { max-width: 650px; }

.name-field {
  display: grid;
  gap: 9px;
  margin-top: 28px;
}

.name-field > span {
  color: var(--ink);
  font-size: .84rem;
  font-weight: 800;
  letter-spacing: .03em;
}

.name-field input,
.copy-field input,
.stack-form input {
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 16px;
  color: var(--ink);
  background: #fff;
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.name-field input::placeholder,
.copy-field input::placeholder,
.stack-form input::placeholder { color: #a69b9e; }

.name-field input:focus,
.copy-field input:focus,
.stack-form input:focus {
  border-color: var(--red-600);
  box-shadow: 0 0 0 4px rgba(195, 25, 45, .11);
  background: var(--red-50);
}

.bot-field {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

.primary-btn,
.secondary-btn,
.ghost-btn,
.back-btn {
  min-height: 48px;
  border-radius: 10px;
  padding: 12px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  text-decoration: none;
  font-weight: 800;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease, color .2s ease;
}

.primary-btn {
  border: 1px solid var(--red-700);
  color: #fff;
  background: linear-gradient(135deg, var(--red-700), var(--red-900));
  box-shadow: 0 12px 24px rgba(127, 10, 25, .22);
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 28px rgba(127, 10, 25, .28);
}

.primary-btn:active { transform: translateY(0); }
.primary-btn:disabled { cursor: wait; opacity: .72; transform: none; }

.secondary-btn {
  border: 1px solid rgba(163, 13, 31, .18);
  color: var(--red-800);
  background: var(--red-50);
}

.secondary-btn:hover {
  border-color: rgba(163, 13, 31, .38);
  background: var(--red-100);
}

.ghost-btn,
.back-btn {
  border: 1px solid transparent;
  color: var(--muted);
  background: transparent;
}

.ghost-btn:hover,
.back-btn:hover {
  color: var(--red-800);
  background: var(--red-50);
}

.start-btn { margin-top: 18px; }

.screen { display: none; }

.screen.active {
  display: block;
  animation: questionForward .48s cubic-bezier(.2, .8, .2, 1) both;
}

.screen.active[data-direction="backward"] {
  animation-name: questionBackward;
}

.screen.active > * {
  animation: fadeRise .45s ease both;
}

.screen.active > *:nth-child(2) { animation-delay: .035s; }
.screen.active > *:nth-child(3) { animation-delay: .07s; }
.screen.active > *:nth-child(4) { animation-delay: .105s; }

.progress-wrap { margin-bottom: 38px; }

.progress-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: .8rem;
}

.progress-meta strong { color: var(--red-700); }

.progress-track,
.mini-track {
  overflow: hidden;
  background: #f0e6e8;
}

.progress-track {
  height: 5px;
  border-radius: 999px;
}

.progress-bar,
.mini-track span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--red-600), var(--red-900));
  transition: width .45s cubic-bezier(.2, .75, .25, 1);
}

.question-screen { max-width: 720px; }

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

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

.choice-card {
  display: block;
  cursor: pointer;
}

.choice-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.choice-content {
  position: relative;
  min-height: 70px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 14px;
  border: 1px solid var(--line);
  border-left: 4px solid #e7dadd;
  border-radius: 11px;
  padding: 13px 16px 13px 13px;
  color: var(--ink);
  background: #fff;
  box-shadow: 0 5px 14px rgba(69, 22, 31, .035);
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.choice-letter {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--red-800);
  background: var(--red-50);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
  transition: color .2s ease, background .2s ease, transform .2s ease;
}

.choice-content strong {
  font-size: .96rem;
  line-height: 1.4;
}

.choice-check {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid #dfd2d5;
  border-radius: 50%;
  color: transparent;
  font-size: .72rem;
  transition: color .2s ease, background .2s ease, border-color .2s ease, transform .2s ease;
}

.choice-card:hover .choice-content {
  transform: translateX(4px);
  border-color: #d8b8be;
  border-left-color: var(--red-500);
  box-shadow: 0 10px 22px rgba(102, 13, 31, .08);
}

.choice-card input:focus-visible + .choice-content {
  outline: 3px solid rgba(195, 25, 45, .17);
  outline-offset: 3px;
}

.choice-card input:checked + .choice-content {
  border-color: rgba(163, 13, 31, .45);
  border-left-color: var(--red-700);
  background: linear-gradient(90deg, var(--red-50), #fff 70%);
  box-shadow: 0 10px 24px rgba(127, 10, 25, .1);
}

.choice-card input:checked + .choice-content .choice-letter {
  color: #fff;
  background: var(--red-700);
  transform: scale(1.05);
}

.choice-card input:checked + .choice-content .choice-check {
  color: #fff;
  border-color: var(--red-700);
  background: var(--red-700);
  transform: scale(1.04);
}

.form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}

.form-actions .primary-btn { margin-left: auto; }

.form-error {
  min-height: 24px;
  margin: 13px 0 0;
  color: var(--red-700);
  font-size: .9rem;
  font-weight: 700;
}

.loading-dot {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, .4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .8s linear infinite;
}

.result-card,
.login-card {
  width: min(620px, 100%);
  padding: clamp(34px, 7vw, 62px);
  border: 1px solid rgba(127, 10, 25, .13);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, .97);
  box-shadow: var(--shadow-lg);
  text-align: center;
  animation: frameIn .62s cubic-bezier(.18, .78, .2, 1) both;
}

.result-icon {
  width: 76px;
  height: 76px;
  margin: 0 auto 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: linear-gradient(145deg, var(--red-600), var(--red-900));
  box-shadow: 0 14px 30px rgba(127, 10, 25, .24);
  font-size: 2rem;
  font-weight: 900;
}

.result-success .result-icon { background: linear-gradient(145deg, #2f9a62, #17663c); }
.result-card .primary-btn,
.result-card .secondary-btn { margin-top: 12px; }

/* Dashboard */
.dashboard-body {
  min-height: 100vh;
  background:
    linear-gradient(180deg, #f7eeee, #fff 240px),
    #f7f2f3;
}

.dashboard-header {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px clamp(20px, 5vw, 72px);
  border-bottom: 1px solid rgba(127, 10, 25, .12);
  background: rgba(255, 255, 255, .91);
  backdrop-filter: blur(16px);
}

.dashboard-brand,
.header-actions {
  display: flex;
  align-items: center;
  gap: 15px;
}

.dashboard-header h1 {
  margin: 2px 0 0;
  font-size: 1.45rem;
}

.dashboard-header .brand-kicker { color: var(--red-700); }

.brand-mark-small {
  width: 45px;
  height: 45px;
  border-color: rgba(127, 10, 25, .25);
  background: linear-gradient(145deg, var(--red-600), var(--red-900));
  box-shadow: none;
}

.brand-mark-small span { font-size: 1.35rem; }
.brand-mark-center { margin: 0 auto 24px; background: linear-gradient(145deg, var(--red-600), var(--red-900)); }

.dashboard-main {
  width: min(1500px, calc(100% - 40px));
  margin: 0 auto;
  padding: 34px 0 64px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.stat-card,
.dashboard-panel,
.result-card-mini {
  border: 1px solid rgba(127, 10, 25, .1);
  background: #fff;
  box-shadow: 0 10px 28px rgba(75, 17, 28, .06);
}

.stat-card {
  position: relative;
  overflow: hidden;
  min-height: 150px;
  padding: 24px;
  border-radius: var(--radius-lg);
}

.stat-card::after {
  content: "";
  position: absolute;
  width: 84px;
  height: 84px;
  right: -32px;
  bottom: -36px;
  border: 18px solid rgba(163, 13, 31, .06);
  border-radius: 50%;
}

.stat-card > span {
  display: block;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.stat-card strong {
  display: block;
  margin: 12px 0 5px;
  color: var(--red-800);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.6rem;
  line-height: 1;
}

.stat-card small { color: var(--muted); }

.dashboard-grid-two {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 20px;
  margin-bottom: 20px;
}

.dashboard-panel {
  margin-bottom: 20px;
  padding: 26px;
  border-radius: var(--radius-lg);
}

.dashboard-grid-two .dashboard-panel { margin-bottom: 0; }

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

.panel-heading h2 {
  margin: 2px 0 0;
  font-size: 1.65rem;
}

.panel-heading .eyebrow { margin-bottom: 5px; }

.helper-text {
  margin-bottom: 16px;
  color: var(--muted);
  font-size: .91rem;
  line-height: 1.6;
}

.copy-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.copy-field input {
  min-width: 0;
  color: var(--red-800);
  background: var(--red-50);
  font-family: Consolas, Monaco, monospace;
  font-size: .88rem;
}

.email-status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: .9rem;
}

.email-status strong { color: var(--ink); }

.status-pill,
.response-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: .75rem;
  font-weight: 800;
  white-space: nowrap;
}

.status-pill.sent {
  color: var(--green);
  background: #e8f7ef;
}

.status-pill.failed {
  color: var(--red-800);
  background: var(--red-100);
}

.status-pill.pending,
.status-pill.unknown {
  color: var(--amber);
  background: #fff3d7;
}

.response-count {
  color: var(--red-800);
  background: var(--red-50);
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.result-card-mini {
  padding: 20px;
  border-radius: var(--radius-md);
}

.result-card-mini:last-child:nth-child(odd) { grid-column: 1 / -1; }
.result-card-mini .question-number { margin-bottom: 8px; }

.distribution-list {
  display: grid;
  gap: 14px;
}

.distribution-meta {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 7px;
  color: var(--muted);
  font-size: .83rem;
  line-height: 1.35;
}

.distribution-meta span { max-width: 72%; }
.distribution-meta strong { color: var(--ink); white-space: nowrap; }
.distribution-meta small { color: var(--muted); font-weight: 600; }

.mini-track {
  height: 7px;
  border-radius: 999px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
}

table {
  width: 100%;
  min-width: 1220px;
  border-collapse: collapse;
  background: #fff;
}

th,
td {
  padding: 14px 15px;
  border-bottom: 1px solid #f0e8ea;
  text-align: left;
  vertical-align: top;
  font-size: .84rem;
  line-height: 1.45;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: var(--red-800);
  background: var(--red-50);
  font-size: .72rem;
  letter-spacing: .035em;
  text-transform: uppercase;
}

tbody tr { transition: background .18s ease; }
tbody tr:hover { background: #fffafa; }
tbody tr:last-child td { border-bottom: 0; }
.reason-cell { min-width: 230px; }
.empty-state { padding: 34px; color: var(--muted); text-align: center; }

.flash-message {
  margin-bottom: 20px;
  border: 1px solid #bfe1cb;
  border-radius: 12px;
  padding: 14px 16px;
  color: var(--green);
  background: #edf9f1;
  font-size: .9rem;
  font-weight: 700;
}

.flash-message.error {
  border-color: #efc5cb;
  color: var(--red-800);
  background: var(--red-50);
}

.stack-form {
  display: grid;
  gap: 15px;
  margin-top: 24px;
  text-align: left;
}

.stack-form .primary-btn { width: 100%; }
.login-card h1 { font-size: clamp(2.2rem, 5vw, 3.35rem); }

@keyframes frameIn {
  from { opacity: 0; transform: translateY(20px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes questionForward {
  from { opacity: 0; transform: translateX(24px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes questionBackward {
  from { opacity: 0; transform: translateX(-24px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes fadeRise {
  from { opacity: 0; transform: translateY(9px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes driftOne {
  from { transform: translate3d(0, 0, 0) rotate(0); }
  to { transform: translate3d(-18px, 16px, 0) rotate(8deg); }
}

@keyframes driftTwo {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(22px, -12px, 0) scale(1.06); }
}

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

@media (max-width: 980px) {
  .page-shell { padding: 22px; }
  .survey-frame { grid-template-columns: 230px minmax(0, 1fr); }
  .brand-panel { padding: 34px 26px; }
  .brand-title { font-size: 1.65rem; }
  .survey-card { padding: 42px; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-grid-two { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  h1 { font-size: clamp(2.1rem, 11vw, 3rem); }
  h2 { font-size: clamp(1.55rem, 7.5vw, 2.15rem); }

  .page-shell {
    display: block;
    min-height: 100vh;
    padding: 0;
  }

  .survey-frame {
    min-height: 100vh;
    grid-template-columns: 1fr;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .brand-panel {
    min-height: auto;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 18px;
    padding: 22px 20px;
  }

  .brand-panel .brand-note { display: none; }
  .brand-panel::before,
  .brand-panel::after { display: none; }

  .brand-mark {
    width: 48px;
    height: 48px;
  }

  .brand-mark span { font-size: 1.45rem; }
  .brand-title { margin-top: 5px; font-size: 1.25rem; }
  .brand-kicker { font-size: .62rem; }

  .survey-card {
    min-height: calc(100vh - 92px);
    align-items: flex-start;
    padding: 34px 20px 28px;
  }

  .progress-wrap { margin-bottom: 30px; }
  .choice-grid-compact { grid-template-columns: 1fr; }
  .choice-content { min-height: 64px; padding: 11px 13px 11px 11px; }
  .choice-card:hover .choice-content { transform: none; }

  .form-actions {
    position: sticky;
    bottom: 0;
    z-index: 5;
    margin: 26px -20px -28px;
    padding: 13px 20px calc(13px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(127, 10, 25, .1);
    background: rgba(255, 255, 255, .94);
    backdrop-filter: blur(14px);
  }

  .form-actions .primary-btn { flex: 1; }

  .result-card,
  .login-card {
    min-height: 100vh;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .dashboard-header {
    position: static;
    align-items: flex-start;
    padding: 15px 18px;
  }

  .dashboard-header .secondary-btn { display: none; }
  .dashboard-header h1 { font-size: 1.15rem; }
  .brand-mark-small { width: 40px; height: 40px; }

  .dashboard-main {
    width: min(100% - 24px, 1500px);
    padding-top: 20px;
  }

  .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { min-height: 125px; padding: 18px; }
  .stat-card strong { font-size: 2.1rem; }
  .dashboard-panel { padding: 18px; }
  .panel-heading { align-items: flex-start; }
  .panel-heading h2 { font-size: 1.35rem; }
  .copy-field { grid-template-columns: 1fr; }
  .copy-field .primary-btn { width: 100%; }
  .result-grid { grid-template-columns: 1fr; }
  .result-card-mini:last-child:nth-child(odd) { grid-column: auto; }
}

@media (max-width: 440px) {
  .stats-grid { grid-template-columns: 1fr; }
  .header-actions { gap: 4px; }
  .ghost-btn { padding-inline: 10px; }
  .choice-content {
    grid-template-columns: 34px minmax(0, 1fr) 21px;
    gap: 10px;
  }
  .choice-letter { width: 32px; height: 32px; }
  .form-actions { gap: 7px; }
  .form-actions button { padding-inline: 13px; }
}

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

/* Job Satisfaction Survey — v7 */
.question-helper {
  margin: -10px 0 18px;
  color: var(--muted);
  font-size: .9rem;
  line-height: 1.5;
}

.choice-card.is-disabled {
  cursor: not-allowed;
  opacity: .48;
}

.choice-card.is-disabled .choice-content {
  transform: none;
  box-shadow: none;
}

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

.rating-card .choice-content {
  min-height: 66px;
  grid-template-columns: minmax(0, 1fr) 22px;
  gap: 8px;
  padding: 10px 12px;
  text-align: center;
}

.rating-number {
  display: grid;
  place-items: center;
  min-height: 40px;
  border-radius: 9px;
  color: var(--red-800);
  background: var(--red-50);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
  font-weight: 700;
  transition: color .2s ease, background .2s ease, transform .2s ease;
}

.rating-card input:checked + .choice-content .rating-number {
  color: #fff;
  background: var(--red-700);
  transform: scale(1.04);
}

.scale-labels {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
}

.scale-labels span:nth-child(2) { text-align: center; }
.scale-labels span:last-child { text-align: right; }

.result-note,
.rating-average {
  margin: -4px 0 14px;
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.5;
}

.rating-average strong {
  color: var(--red-800);
  font-size: 1rem;
}

@media (max-width: 620px) {
  .rating-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .rating-card .choice-content { min-height: 58px; padding: 8px; }
  .rating-card .choice-check { display: none; }
  .rating-card .choice-content { grid-template-columns: 1fr; }
  .rating-number { min-height: 38px; font-size: 1.08rem; }
  .scale-labels { font-size: .7rem; }
}
