:root {
  --bg: #fff5f8;
  --bg-grad: linear-gradient(180deg, #ffe6ef 0%, #fff5f8 55%, #fff0f5 100%);
  --ink: #3a1d2c;
  --muted: #a47887;
  --accent: #ec6b9a;
  --accent-dark: #d44878;
  --accent-soft: #ffd6e3;
  --accent-ink: #ffffff;
  --card: #ffffff;
  --line: #f5cdda;
  --ok: #5fa37e;
  --err: #c84545;
  --radius: 18px;
  --radius-lg: 24px;
  --pad: 18px;
  --shadow-soft: 0 6px 20px rgba(236, 107, 154, 0.10);
  --shadow-pop: 0 8px 24px rgba(236, 107, 154, 0.28);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  background-image: var(--bg-grad);
  background-attachment: fixed;
  color: var(--ink);
  font: 16px/1.5 "Quicksand", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  font-weight: 500;
  -webkit-font-smoothing: antialiased;
}

main {
  max-width: 600px;
  margin: 0 auto;
  padding: max(env(safe-area-inset-top), 24px) var(--pad) calc(env(safe-area-inset-bottom) + 48px);
}

header {
  text-align: center;
  margin: 4px 0 28px;
}

.bloom {
  display: block;
  margin: 0 auto 12px;
  filter: drop-shadow(0 4px 10px rgba(236, 107, 154, 0.25));
}

h1 {
  font-family: "Quicksand", sans-serif;
  font-weight: 700;
  font-size: 28px;
  margin: 0 0 6px;
  letter-spacing: 0.01em;
  color: var(--accent-dark);
}

.tagline {
  font-family: "Caveat", cursive;
  font-weight: 600;
  font-size: 26px;
  margin: 0 0 14px;
  color: var(--accent);
  line-height: 1;
}

.tagline .heart {
  color: var(--accent-dark);
  margin-left: 2px;
}

.subtitle {
  color: var(--muted);
  margin: 0 auto;
  max-width: 38ch;
  font-size: 15px;
}

.muted { color: var(--muted); font-weight: 500; }
.small { font-size: 13px; }

.pickers {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 8px 0 20px;
}

.pick-btn {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 16px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  text-align: center;
  user-select: none;
  box-shadow: var(--shadow-pop);
  -webkit-tap-highlight-color: transparent;
  transition: transform 120ms ease, box-shadow 120ms ease;
}
.pick-btn:hover { transform: translateY(-1px); }
.pick-btn:active { transform: scale(0.98); }

.pick-btn--secondary {
  background: var(--card);
  color: var(--accent-dark);
  border: 2px solid var(--accent);
  box-shadow: var(--shadow-soft);
}

.items { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 12px; }

.item {
  display: grid;
  grid-template-columns: 84px 1fr auto;
  gap: 14px;
  align-items: start;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 12px;
  box-shadow: var(--shadow-soft);
}
.item .thumb {
  width: 84px;
  height: 84px;
  background: var(--accent-soft) center/cover no-repeat;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--accent-dark);
}
.item .thumb img,
.item .thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 14px;
  display: block;
}
.item .meta { min-width: 0; }
.item .filename {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 6px;
}
.item .note {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 14px;
  font-family: inherit;
  background: #fff;
  color: var(--ink);
}
.item .note:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.item .progress {
  height: 5px;
  background: var(--accent-soft);
  border-radius: 3px;
  margin-top: 10px;
  overflow: hidden;
  display: none;
}
.item.uploading .progress,
.item.done .progress,
.item.error .progress { display: block; }
.item .bar {
  height: 100%;
  width: 0;
  background: var(--accent);
  transition: width 120ms linear;
}
.item.done .bar { background: var(--ok); width: 100% !important; }
.item.error .bar { background: var(--err); }
.item .state {
  font-size: 12px;
  margin-top: 6px;
  color: var(--muted);
  min-height: 16px;
}
.item.done .state { color: var(--ok); font-weight: 600; }
.item.error .state { color: var(--err); }
.item .remove {
  background: transparent;
  border: 0;
  color: var(--muted);
  font-size: 28px;
  line-height: 1;
  padding: 0 6px;
  cursor: pointer;
}
.item .remove:hover { color: var(--accent-dark); }
.item.uploading .remove,
.item.done .remove { display: none; }

.turnstile { margin: 4px 0 12px; min-height: 0; }

.submit {
  display: block;
  width: 100%;
  padding: 18px;
  font-size: 17px;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%);
  color: var(--accent-ink);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  box-shadow: var(--shadow-pop);
  -webkit-tap-highlight-color: transparent;
  transition: transform 120ms ease, box-shadow 120ms ease, opacity 120ms ease;
}
.submit:hover:not(:disabled) { transform: translateY(-1px); }
.submit:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  box-shadow: none;
}
.submit:active:not(:disabled) { transform: scale(0.99); }

.status { text-align: center; margin: 16px 0 0; min-height: 22px; color: var(--muted); font-weight: 600; }
.status.ok { color: var(--ok); }
.status.err { color: var(--err); }

footer {
  margin-top: 40px;
  text-align: center;
  color: var(--muted);
  letter-spacing: 0.06em;
}
