:root {
  --cream: #f8f1e8;
  --cream-2: #f2e8db;
  --paper: #fffdfa;
  --ink: #3b3229;
  --ink-soft: #7a6f62;
  --ink-faint: #a89c8d;
  --clay: #c0805e;
  --clay-deep: #a4643f;
  --blush: #f4e5d8;
  --blush-line: #e7d3c1;
  --line: #ece2d4;
  --shadow: 22px 30px 60px -34px rgba(90, 62, 40, .35);
  --shadow-sm: 0 10px 24px -16px rgba(90, 62, 40, .45);
  --radius: 22px;
  --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Fraunces', Georgia, serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  background-image:
    radial-gradient(120% 60% at 100% 0%, #fbf5ee 0%, rgba(251,245,238,0) 55%),
    radial-gradient(90% 50% at 0% 100%, #f0e4d4 0%, rgba(240,228,212,0) 60%);
  background-attachment: fixed;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 120px;
}

.wrap { max-width: 520px; margin: 0 auto; padding: 0 18px; }

/* ---------- header ---------- */
header {
  padding: 40px 0 22px;
  text-align: center;
}
.kicker {
  font-size: 12px;
  letter-spacing: .42em;
  text-transform: uppercase;
  color: var(--clay-deep);
  font-weight: 700;
  margin-bottom: 18px;
  padding-left: .42em;
}
h1 {
  font-family: var(--font-display);
  font-optical-sizing: auto;
  font-weight: 500;
  font-size: clamp(30px, 8.5vw, 40px);
  line-height: 1.08;
  letter-spacing: -.01em;
  margin-bottom: 14px;
}
h1 em { font-style: italic; color: var(--clay-deep); }
.lede {
  color: var(--ink-soft);
  font-size: 15.5px;
  max-width: 34ch;
  margin: 0 auto;
}
.rule {
  width: 46px; height: 2px; border-radius: 2px;
  background: var(--clay);
  margin: 22px auto 0;
  opacity: .7;
}

/* ---------- name field ---------- */
.name-field {
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 18px;
  padding: 15px 16px 16px;
  box-shadow: var(--shadow-sm);
  animation: rise .5s cubic-bezier(.2,.7,.2,1) both;
}
.name-field label {
  display: block;
  font-family: var(--font-display);
  font-weight: 600; font-size: 16px; margin-bottom: 9px;
}
.name-field input {
  width: 100%;
  font-family: var(--font-body); font-size: 16px; color: var(--ink);
  background: var(--cream); border: 1.5px solid var(--line);
  border-radius: 13px; padding: 12px 14px;
  transition: border-color .2s, background .2s;
}
.name-field input:focus { outline: none; border-color: var(--clay); background: #fff; }
.name-field input::placeholder { color: var(--ink-faint); }

/* ---------- section label ---------- */
.section-label {
  display: flex; align-items: center; gap: 12px;
  margin: 30px 2px 16px;
  color: var(--ink-soft);
  font-size: 12.5px; letter-spacing: .16em; text-transform: uppercase;
  font-weight: 700;
}
.section-label::after {
  content: ""; flex: 1; height: 1px; background: var(--line);
}

/* ---------- item cards ---------- */
.items { display: flex; flex-direction: column; gap: 12px; }

.card {
  position: relative;
  display: flex; align-items: flex-start; gap: 15px;
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px 12px 12px;
  cursor: pointer;
  transition: border-color .25s, background .25s, transform .12s, box-shadow .25s;
  box-shadow: var(--shadow-sm);
  animation: rise .55s cubic-bezier(.2,.7,.2,1) both;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}
.card:active { transform: scale(.985); }
.card.on {
  border-color: var(--clay);
  background: linear-gradient(180deg, #fdf6ee, var(--blush));
  box-shadow: 0 16px 30px -20px rgba(164, 100, 63, .5);
}

.thumb {
  width: 92px; height: 92px; flex: none;
  border-radius: 15px; overflow: hidden;
  background: var(--cream-2);
}
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb.ph {
  display: grid; place-items: center;
  background: linear-gradient(150deg, #f3e7d8, #e9d6c2);
}
.thumb.ph svg { width: 40px; height: 40px; opacity: .55; }

.body { flex: 1; min-width: 0; padding-right: 30px; }
.name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 17px;
  line-height: 1.15;
  letter-spacing: -.005em;
  margin-bottom: 5px;
}
.desc {
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.42;
}

.check {
  position: absolute; top: 12px; right: 12px;
  width: 25px; height: 25px; flex: none;
  border: 2px solid var(--blush-line);
  border-radius: 50%;
  background: #fff;
  display: grid; place-items: center;
  transition: all .2s;
}
.check svg { width: 13px; height: 13px; stroke: #fff; opacity: 0; transform: scale(.4); transition: all .2s; }
.card.on .check { background: var(--clay); border-color: var(--clay); transform: scale(1.05); }
.card.on .check svg { opacity: 1; transform: scale(1); }

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

/* ---------- suggestions ---------- */
.suggest-intro {
  color: var(--ink-soft); font-size: 14px; margin: 0 2px 14px; line-height: 1.5;
}
.suggest-form { display: flex; gap: 9px; margin-bottom: 10px; }
.suggest-form input {
  flex: 1; min-width: 0;
  font-family: var(--font-body); font-size: 15px; color: var(--ink);
  background: var(--paper);
  border: 1.5px solid var(--line); border-radius: 15px;
  padding: 13px 15px;
  transition: border-color .2s;
}
.suggest-form input:focus { outline: none; border-color: var(--clay); }
.suggest-form input::placeholder { color: var(--ink-faint); }
.btn-add {
  flex: none;
  font-family: var(--font-body); font-weight: 700; font-size: 14px;
  color: #fff; background: var(--ink);
  border: none; border-radius: 15px; padding: 0 18px;
  cursor: pointer; transition: transform .12s, background .2s;
}
.btn-add:active { transform: scale(.95); }
.btn-add:disabled { opacity: .4; cursor: default; }

.hint { font-size: 12.5px; margin: 2px 2px 0; min-height: 16px; transition: color .2s; }
.hint.err { color: var(--clay-deep); }
.hint.ok { color: #6f8a5f; }

.suggest-list { display: flex; flex-direction: column; gap: 9px; margin-top: 16px; }
.sug {
  display: flex; align-items: center; gap: 12px;
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: 16px; padding: 12px 14px;
  animation: rise .5s cubic-bezier(.2,.7,.2,1) both;
}
.sug .txt { flex: 1; font-size: 14.5px; line-height: 1.35; word-break: break-word; }
.like {
  flex: none; display: flex; align-items: center; gap: 6px;
  background: var(--blush); border: 1.5px solid var(--blush-line);
  border-radius: 999px; padding: 7px 12px; cursor: pointer;
  font-family: var(--font-body); font-weight: 700; font-size: 13px; color: var(--clay-deep);
  transition: transform .12s, background .2s, border-color .2s;
  -webkit-tap-highlight-color: transparent;
}
.like:active { transform: scale(.9); }
.like svg { width: 15px; height: 15px; fill: none; stroke: var(--clay-deep); stroke-width: 2; transition: fill .2s, stroke .2s; }
.like.on { background: var(--clay); border-color: var(--clay); color: #fff; }
.like.on svg { fill: #fff; stroke: #fff; }
.like.pop { animation: pop .32s ease; }
@keyframes pop { 0%{transform:scale(1);} 40%{transform:scale(1.22);} 100%{transform:scale(1);} }

.empty { color: var(--ink-faint); font-size: 13.5px; text-align: center; padding: 18px 0; }

/* ---------- sticky submit ---------- */
.dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  padding: 12px 18px calc(14px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(248,241,232,0), var(--cream) 42%);
}
.dock-inner { max-width: 520px; margin: 0 auto; }
.btn-submit {
  width: 100%;
  font-family: var(--font-body); font-weight: 700; font-size: 16.5px; color: #fff;
  background: var(--clay); border: none; border-radius: 18px;
  padding: 17px 20px; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  box-shadow: 0 16px 32px -14px rgba(164,100,63,.7);
  transition: transform .12s, background .25s;
}
.btn-submit:active { transform: scale(.98); }
.btn-submit.done { background: #6f8a5f; box-shadow: 0 16px 32px -14px rgba(111,138,95,.6); }
.btn-submit .count {
  background: rgba(255,255,255,.22); border-radius: 999px;
  min-width: 26px; height: 24px; padding: 0 11px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13.5px; font-weight: 800; white-space: nowrap;
}

.toast {
  position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%) translateY(20px);
  background: var(--ink); color: #fff; font-size: 14px; font-weight: 600;
  padding: 12px 20px; border-radius: 999px; z-index: 40;
  opacity: 0; pointer-events: none; transition: all .35s cubic-bezier(.2,.7,.2,1);
  box-shadow: var(--shadow); max-width: 90vw; text-align: center;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

footer {
  text-align: center; color: var(--ink-faint); font-size: 11.5px;
  letter-spacing: .04em; padding: 34px 0 10px;
}

.skeleton { height: 116px; border-radius: var(--radius); background:
  linear-gradient(100deg, var(--cream-2) 30%, #f7efe4 50%, var(--cream-2) 70%);
  background-size: 200% 100%; animation: sk 1.3s infinite; }
@keyframes sk { to { background-position: -200% 0; } }
