@font-face {
  font-family: Metropolis;
  src: url("/Metropolis-Regular.ttf") format("truetype");
  font-display: swap;
  font-weight: 400;
}
@font-face {
  font-family: Metropolis;
  src: url("/Metropolis-Bold.ttf") format("truetype");
  font-display: swap;
  font-weight: 700;
}
:root {
  color-scheme: dark;
  --deep: #4b4f54;
  --turquoise: #00aebc;
  --ivory: #fff;
  --muted: #f1f4f5;
  --paper: #fff;
  --ink: #202a2e;
  --edge: #d4dfe1;
  font: 1rem/1.5 Metropolis, Arial, sans-serif;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100svh;
  background: var(--deep);
  color: var(--ivory);
}
[hidden] { display: none !important; }
.postcard {
  display: grid;
  grid-template: "brand panel" auto "letter panel" 1fr / minmax(0,.83fr) minmax(0,1.17fr);
  align-items: start;
  gap: 28px clamp(38px,7vw,105px);
  width: min(100%,1370px);
  margin: auto;
  padding: clamp(28px,5vw,68px) clamp(24px,5.5vw,78px);
}
.brand { grid-area: brand; align-self: start; }
.brand img { display: block; width: 175px; height: auto; margin-left: -9px; }
.letter { grid-area: letter; min-width: 0; align-self: center; max-width: 51ch; }
.eyebrow { margin: 0 0 12px; color: var(--turquoise); font-size: .83rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
h1, h2 { margin: 0; font-weight: 700; line-height: 1.07; letter-spacing: -.057em; }
h1 { margin-bottom: clamp(16px,3vw,30px); font-size: clamp(3.2rem,7vw,6.1rem); }
h1 em { color: var(--turquoise); font-style: normal; }
.letter p:not(.eyebrow) { max-width: 47ch; margin: 0 0 13px; color: var(--muted); }
.signature { display: flex; flex-wrap: wrap; gap: 5px 10px; margin-top: 21px; padding-top: 11px; border-top: 1px solid #ffffff33; color: var(--muted); font-size: .875rem; }
.signature strong { color: var(--ivory); }

.panel {
  grid-area: panel;
  min-width: 0;
  padding: clamp(19px,3vw,34px);
  border: 1px solid #d0dfe1;
  border-top: 5px solid var(--turquoise);
  border-radius: 17px;
  background: var(--paper);
  color: var(--ink);
  color-scheme: light;
  box-shadow: 0 18px 60px #0003;
}
h2 { margin-bottom: 16px; font-size: clamp(1.55rem,3vw,2.22rem); }
.panel :focus-visible { outline: 2px solid #01747e; outline-offset: 3px; }
button, input { font: inherit; }
.name-label, legend { display: block; padding: 0; margin-bottom: 6px; font-size: .94rem; font-weight: 700; }
input[type="text"] { width: 100%; min-height: 43px; padding: 9px 11px; border: 1px solid #b5c6c9; border-radius: 7px; background: #fff; color: var(--ink); }
fieldset { min-width: 0; margin: 17px 0 0; padding: 0; border: 0; }
.question-number { margin-right: 3px; color: #00636d; }
.options { display: flex; flex-wrap: wrap; gap: 5px 6px; }
.option {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 5px 8px;
  border: 1px solid var(--edge);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  font-size: .88rem;
  cursor: pointer;
}
.option:hover { border-color: #008995; }
.option:has(input:checked) { border-color: #007881; background: #e6f7f8; }
input[type="radio"] { flex: 0 0 15px; width: 15px; height: 15px; margin: 0; accent-color: #007881; }
.main-button {
  min-height: 44px;
  margin-top: 20px;
  padding: 10px 15px;
  border: 0;
  border-radius: 7px;
  background: var(--turquoise);
  color: #14272b;
  text-align: left;
  font-weight: 700;
  cursor: pointer;
}
.main-button:hover { background: #48c3cb; }
.main-button:disabled { opacity: .7; cursor: wait; }
.fine, .feedback { margin: 8px 0 0; color: #4b4f54; font-size: .85rem; }
#preview-note { margin: 0 0 12px; color: #4b4f54; }
.feedback { color: #8c3529; font-weight: 700; }
.feedback:empty { display: none; }

.survey-progress { margin-bottom: 19px; padding-bottom: 14px; border-bottom: 1px solid #e1e9ea; }
.progress-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 5px; font-size: .86rem; font-weight: 700; }
.progress-heading output { color: #00636d; font-size: 1.1rem; }
progress { display: block; width: 100%; height: 8px; overflow: hidden; border: 0; border-radius: 4px; appearance: none; background: #dde8e9; accent-color: #00aebc; }
progress::-webkit-progress-bar { background: #dde8e9; }
progress::-webkit-progress-value { background: var(--turquoise); transition: width 160ms ease; }
progress::-moz-progress-bar { background: var(--turquoise); }
.progress-ticks { display: flex; justify-content: space-between; margin-top: 5px; color: #4b4f54; font-size: .72rem; font-variant-numeric: tabular-nums; }
.answer-note { margin: 7px 0 0; padding: 7px 9px; border-inline-start: 3px solid var(--turquoise); background: #edf8f9; font-size: .87rem; }
.answer-note:empty { display: none; }

#confirmation .eyebrow { color: #00636d; }
#confirmation h2 { margin-bottom: 9px; }
#gift-copy { margin: 0; }
.gift { width: min(100%,420px); margin: 16px auto 0; overflow: hidden; border-radius: 11px; background: #30363a; }
.gift img { display: block; width: 100%; height: auto; }
#confirmation { animation: reveal 310ms ease-out both; }
@keyframes reveal { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { #confirmation { animation: none; } progress::-webkit-progress-value { transition: none; } }
@media (max-width: 780px) {
  .postcard { grid-template: "brand" auto "letter" auto "panel" auto / minmax(0,1fr); gap: 16px; padding: 19px 17px 24px; }
  .brand img { width: 145px; margin-left: -8px; }
  .letter { max-width: 55ch; }
  h1 { margin-bottom: 12px; font-size: clamp(2.8rem,10vw,4.5rem); }
  .eyebrow { margin-bottom: 8px; }
  .signature { margin-top: 14px; padding-top: 9px; }
}
