:root {
  --yellow: #fdd41a;   /* Decara brand yellow */
  --ink: #0a0a0a;
  --ink-2: #555;
  --ink-3: #8a8a8a;
  --line: #e5e5e5;
  --line-2: #d4d4d4;
  --bg: #fff;
  --soft: #f7f7f5;
  --danger: #c4321c;
  --radius: 8px;
  --ring: 0 0 0 3px rgb(253 212 26 / .55);
  --head: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --body: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.55 var(--body);
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 640px;
  margin: 0 auto;
  padding: 56px 24px 40px;
}

/* ---------- Intro ---------- */

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--ink);
  text-decoration: none;
  font: 700 17px/1 var(--head);
  letter-spacing: -.01em;
}
.brand img { display: block; width: 54px; height: auto; aspect-ratio: 1755 / 2480; object-fit: contain; border-radius: 4px; background: var(--yellow); }

h1 {
  margin: 40px 0 10px;
  font: 700 40px/1.05 var(--head);
  letter-spacing: -.02em;
}

.lead { margin: 0; color: var(--ink-2); font-size: 16px; max-width: 52ch; }

/* ---------- Sections ---------- */

section { padding: 36px 0 4px; border-top: 1px solid var(--line); margin-top: 36px; }
.intro + form section:first-of-type { margin-top: 40px; }

h2 {
  margin: 0 0 18px;
  font: 600 13px/1 var(--body);
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ink-3);
}

.hint { margin: -8px 0 16px; color: var(--ink-3); font-size: 14px; }

/* ---------- Fields ---------- */

.field { margin-bottom: 18px; min-width: 0; }
.field--narrow { max-width: 160px; }

.row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }

label { display: block; font-weight: 500; font-size: 14px; margin-bottom: 6px; }
.req { color: var(--ink-3); font-weight: 400; }

input, select, textarea {
  width: 100%;
  font: inherit;
  color: inherit;
  background: var(--bg);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  padding: 9px 12px;
  min-height: 40px;
  transition: border-color .12s, box-shadow .12s;
  appearance: none;
}
textarea { resize: vertical; min-height: 88px; }
input::placeholder, textarea::placeholder { color: #b3b3b3; }

select {
  padding-right: 32px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a8a8a' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

input:hover, select:hover, textarea:hover { border-color: #b8b8b8; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--ink); box-shadow: var(--ring); }

.invalid { border-color: var(--danger) !important; }
.invalid:focus { box-shadow: 0 0 0 3px rgb(196 50 28 / .15); }
.field-error { margin: 6px 0 0; color: var(--danger); font-size: 13px; }

.suffix { position: relative; }
.suffix input { padding-right: 40px; }
.suffix span { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }

input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; }
input[type=number] { -moz-appearance: textfield; }

/* ---------- Repeatable rows ---------- */

.list { display: grid; gap: 8px; }
.list:empty { display: none; }

.item { display: grid; grid-template-columns: 1.1fr 1fr 1.2fr 32px; gap: 8px; align-items: center; }
.item--2 { grid-template-columns: 1.6fr 1fr 32px; }

.remove {
  width: 32px; height: 32px;
  border: 0; border-radius: 6px;
  background: transparent; color: var(--ink-3);
  font-size: 20px; line-height: 1; cursor: pointer;
}
.remove:hover { background: var(--soft); color: var(--ink); }

.add {
  margin-top: 10px;
  padding: 6px 10px 6px 8px;
  border: 0; border-radius: 6px;
  background: transparent;
  color: var(--ink-2);
  font: 500 14px var(--body);
  cursor: pointer;
}
.add:hover { background: var(--soft); color: var(--ink); }
.add:focus-visible, .remove:focus-visible { outline: none; box-shadow: var(--ring); }

/* ---------- Photos ---------- */

.photos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }

.drop, .thumb { aspect-ratio: 4 / 5; border-radius: var(--radius); }

.drop {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  margin: 0;
  border: 1px dashed var(--line-2);
  background: var(--soft);
  color: var(--ink-2);
  font-size: 14px; font-weight: 500;
  cursor: pointer;
  transition: border-color .12s, background .12s;
}
.drop:hover, .drop.over { border-color: var(--ink); background: #fffbe6; }
.drop:focus-within { box-shadow: var(--ring); border-color: var(--ink); }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; }

.thumb { position: relative; overflow: hidden; background: var(--soft); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .remove {
  position: absolute; top: 6px; right: 6px;
  width: 26px; height: 26px; font-size: 17px;
  background: rgb(255 255 255 / .92); color: var(--ink);
  box-shadow: 0 1px 2px rgb(0 0 0 / .15);
}
.thumb .remove:hover { background: #fff; }

/* ---------- Final ---------- */

.final { padding-top: 28px; }

.check { display: grid; grid-template-columns: 20px 1fr; gap: 10px; font-weight: 400; color: var(--ink-2); line-height: 1.5; cursor: pointer; }
.check input {
  width: 18px; height: 18px; min-height: 0; padding: 0; margin: 2px 0 0;
  border-radius: 5px; cursor: pointer;
}
.check input:checked {
  background: var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fdd41a' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 13px no-repeat;
  border-color: var(--ink);
}
.check a { color: inherit; text-underline-offset: 2px; }

.error { margin: 16px 0 0; color: var(--danger); font-size: 14px; }

.submit {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  margin-top: 24px;
  min-width: 180px; height: 44px; padding: 0 22px;
  border: 0; border-radius: var(--radius);
  background: var(--ink); color: #fff;
  font: 600 15px var(--body);
  cursor: pointer;
  transition: transform .08s, background .12s;
}
.submit:hover { background: #262626; }
.submit:active { transform: translateY(1px); }
.submit:focus-visible { outline: none; box-shadow: var(--ring); }
.submit[disabled] { cursor: progress; }
.submit[disabled] .label { visibility: hidden; }

.spinner {
  position: absolute; width: 18px; height: 18px;
  border: 2px solid rgb(255 255 255 / .3); border-top-color: var(--yellow);
  border-radius: 50%;
  display: none;
  animation: spin .7s linear infinite;
}
.submit[disabled] .spinner { display: block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Done ---------- */

.done { padding: 72px 0 24px; outline: none; }
.done__mark {
  width: 56px; height: 56px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--yellow); color: var(--ink);
  margin-bottom: 24px;
}
.done h2 { font: 700 32px/1.1 var(--head); text-transform: none; letter-spacing: -.02em; color: var(--ink); margin: 0 0 10px; }
.done p { color: var(--ink-2); margin: 0 0 28px; max-width: 46ch; }
.back { color: var(--ink); font-weight: 500; text-underline-offset: 3px; }

.foot { margin-top: 56px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--ink-3); font-size: 13px; }
.foot a { color: inherit; text-underline-offset: 3px; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Combobox (search + pick from list) ---------- */

.combo-wrap { position: relative; min-width: 0; }

.combo {
  padding-right: 32px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238a8a8a' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.combo-list {
  position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 4px);
  min-width: 200px; max-height: 240px; overflow-y: auto;
  margin: 0; padding: 4px; list-style: none;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgb(0 0 0 / .08), 0 1px 3px rgb(0 0 0 / .06);
}
.combo-list li { padding: 7px 10px; border-radius: 5px; cursor: pointer; }
.combo-list [aria-selected=true] { background: var(--soft); box-shadow: inset 2px 0 0 var(--yellow); }
.combo-list .combo-empty { color: var(--ink-3); cursor: default; }

.item--1 { grid-template-columns: 1fr 32px; max-width: 360px; }

.check--field { margin: 4px 0 18px; color: var(--ink); font-weight: 500; }

/* ---------- Small screens ---------- */

@media (max-width: 560px) {
  .page { padding: 32px 18px 32px; }
  h1 { font-size: 32px; margin-top: 32px; }
  .row { grid-template-columns: 1fr; }
  .item { grid-template-columns: 1fr 1fr 32px; }
  .item > [name=accent] { grid-column: 1 / 3; grid-row: 2; }
  .item--1 { grid-template-columns: 1fr 32px; max-width: none; }
  .photos { gap: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation-duration: 1.5s !important; }
}
