:root {
  --bg: radial-gradient(circle at 10% 10%, #ffd7e6 0%, #fff1f6 35%, #fff9fb 100%);
  --card: rgba(255, 255, 255, 0.84);
  --card-strong: rgba(255, 255, 255, 0.95);
  --text: #2d1635;
  --muted: #6b4a76;
  --border: rgba(209, 124, 166, 0.28);
  --shadow: 0 12px 36px rgba(160, 94, 135, 0.18);
  --accent: #db4f97;
  --accent-strong: #b63f7c;
  --success: #128f66;
  --danger: #9d3355;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", "Segoe UI", sans-serif;
  color: var(--text);
  background: #fff4f8;
  position: relative;
}

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

.backdrop {
  position: fixed;
  inset: 0;
  background: var(--bg);
  z-index: -2;
}

.backdrop::before,
.backdrop::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(2px);
}

.backdrop::before {
  width: 380px;
  height: 380px;
  top: -100px;
  right: -120px;
  background: rgba(255, 157, 191, 0.35);
}

.backdrop::after {
  width: 260px;
  height: 260px;
  left: -90px;
  bottom: 30%;
  background: rgba(189, 122, 255, 0.16);
}

.page {
  width: min(960px, calc(100% - 2rem));
  margin: 2rem auto 3rem;
  display: grid;
  gap: 1.2rem;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  padding: 1.4rem;
  animation: rise-in 450ms ease both;
}

.hero {
  background: linear-gradient(145deg, var(--card-strong), rgba(255, 235, 246, 0.9));
}

.hero::after {
  content: "";
  display: block;
  margin-top: 0.4rem;
  height: 3px;
  width: min(180px, 40%);
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(219, 79, 151, 0.2), rgba(219, 79, 151, 0.75));
}

.hero-top-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}

.eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--muted);
}

h1,
h2,
h3 {
  font-family: "Fraunces", "Times New Roman", serif;
  margin-top: 0;
}

h1 {
  font-size: clamp(1.8rem, 3.4vw, 2.8rem);
  margin-bottom: 0.45rem;
  margin-top: 0.7rem;
}

.lead {
  margin-top: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.help-callout {
  margin-top: 0.8rem;
  border-left: 4px solid rgba(182, 63, 124, 0.6);
  padding: 0.55rem 0.8rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.84);
}

.countdown {
  margin-top: 0.9rem;
  border: 1px solid rgba(182, 63, 124, 0.3);
  border-radius: 14px;
  padding: 0.7rem;
  background: rgba(255, 255, 255, 0.78);
}

.countdown-kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.72rem;
  color: var(--muted);
  font-weight: 700;
}

.countdown-title {
  margin: 0.2rem 0 0;
  font-weight: 700;
}

.countdown-grid {
  margin-top: 0.55rem;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.45rem;
}

.countdown-cell {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(209, 124, 166, 0.26);
  border-radius: 12px;
  padding: 0.38rem 0.3rem;
  text-align: center;
}

.countdown-value {
  margin: 0;
  font-family: "Fraunces", "Times New Roman", serif;
  font-size: 1.18rem;
  font-weight: 700;
  transition: transform 220ms ease, color 220ms ease;
}

.countdown-value.bump {
  transform: scale(1.08);
  color: var(--accent-strong);
}

.countdown-label {
  margin: 0.15rem 0 0;
  color: var(--muted);
  font-size: 0.74rem;
}

.help-kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.74rem;
  color: var(--muted);
  font-weight: 700;
}

.help-copy {
  margin: 0.2rem 0 0;
  font-weight: 600;
}

.instruction-box {
  margin-top: 1rem;
  background: rgba(255, 255, 255, 0.75);
  border: 1px dashed rgba(182, 63, 124, 0.35);
  border-radius: 14px;
  padding: 0.95rem 1rem;
}

.instruction-box h2 {
  margin: 0;
  font-size: 1.16rem;
}

.instruction-box ul {
  margin: 0.55rem 0 0;
  padding-left: 1.1rem;
  color: var(--muted);
}

.instruction-box li + li {
  margin-top: 0.38rem;
}

.language-picker {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.45rem 0.65rem;
  font-size: 0.95rem;
  color: var(--text);
  background: #fff;
}

.name-form {
  display: grid;
  gap: 0.8rem;
}

.name-form label {
  display: grid;
  gap: 0.3rem;
  font-weight: 600;
}

.input-hint {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 500;
}

input {
  border: 1px solid rgba(169, 96, 140, 0.36);
  border-radius: 11px;
  padding: 0.64rem 0.72rem;
  font-size: 16px;
}

input:focus {
  outline: 2px solid rgba(219, 79, 151, 0.26);
  border-color: var(--accent);
}

.button-primary {
  border: none;
  border-radius: 12px;
  padding: 0.7rem 1rem;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  min-height: 44px;
  background: linear-gradient(145deg, var(--accent), var(--accent-strong));
  cursor: pointer;
  transition: transform 140ms ease, box-shadow 140ms ease;
}

.button-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 7px 15px rgba(182, 63, 124, 0.34);
}

.form-message {
  min-height: 1.2rem;
  color: var(--muted);
  margin: 0.72rem 0 0;
}

.form-message.success {
  color: var(--success);
}

.form-message.error {
  color: var(--danger);
}

.suggestion-headline-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
}

.tiny-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.suggestion-controls {
  display: grid;
  gap: 0.35rem;
  justify-items: end;
}

.mine-only-label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.88rem;
  color: var(--muted);
}

.suggestions-list {
  margin-top: 0.8rem;
  display: grid;
  gap: 0.65rem;
}

.shortlist-list {
  margin-top: 0.8rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 0.6rem;
}

.shortlist-chip {
  border: 1px solid rgba(209, 124, 166, 0.3);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  padding: 0.45rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.shortlist-rank {
  color: var(--muted);
  font-size: 0.8rem;
}

.shortlist-name {
  font-weight: 700;
}

.shortlist-score {
  color: var(--accent-strong);
  font-weight: 700;
  font-size: 0.9rem;
}

.suggestion-item {
  border: 1px solid rgba(209, 124, 166, 0.25);
  border-radius: 14px;
  padding: 0.8rem;
  background: rgba(255, 255, 255, 0.82);
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: center;
  transition: transform 120ms ease, box-shadow 120ms ease;
  flex-wrap: wrap;
}

.suggestion-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(160, 94, 135, 0.15);
}

.suggestion-name {
  margin-bottom: 0.2rem;
  font-size: 1.23rem;
}

.suggestion-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.suggestion-score-block {
  text-align: right;
  min-width: 170px;
}

.comments-block {
  width: 100%;
  border-top: 1px dashed rgba(169, 96, 140, 0.32);
  margin-top: 0.6rem;
  padding-top: 0.6rem;
}

.comments-title {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted);
}

.comments-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.comments-content.is-collapsed {
  display: none;
}

.comments-list {
  margin-top: 0.45rem;
  display: grid;
  gap: 0.35rem;
}

.comment-line {
  margin: 0;
  font-size: 0.9rem;
}

.comment-author {
  font-weight: 700;
}

.comment-form {
  margin-top: 0.45rem;
  display: flex;
  gap: 0.4rem;
}

.comment-input {
  flex: 1;
}

.comment-submit {
  white-space: nowrap;
}

.comment-actions {
  display: inline-flex;
  margin-left: 0.4rem;
  gap: 0.3rem;
}

.comment-action-btn {
  font-size: 0.75rem;
  padding: 0.12rem 0.38rem;
}

.score {
  margin: 0 0 0.3rem;
  font-weight: 700;
}

.vote-buttons {
  display: flex;
  justify-content: flex-end;
  gap: 0.35rem;
}

.vote-btn {
  border: 1px solid rgba(169, 96, 140, 0.36);
  border-radius: 10px;
  background: #fff;
  font-size: 1.05rem;
  min-height: 40px;
  padding: 0.38rem 0.6rem;
  cursor: pointer;
}

.vote-btn:hover {
  border-color: var(--accent);
}

.vote-counts {
  margin: 0.3rem 0 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.empty-state {
  margin: 0;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.75);
  border: 1px dashed rgba(169, 96, 140, 0.3);
  border-radius: 12px;
  padding: 0.9rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

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

@media (max-width: 720px) {
  .page {
    width: min(960px, calc(100% - 1rem));
    margin-top: 1rem;
  }

  .card {
    border-radius: 16px;
    padding: 1rem;
  }

  h1 {
    font-size: clamp(1.55rem, 8vw, 2rem);
    line-height: 1.15;
  }

  .lead {
    font-size: 0.98rem;
  }

  .hero-top-row,
  .suggestion-headline-row,
  .suggestion-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-top-row {
    width: 100%;
  }

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

  .language-picker-wrap,
  .language-picker {
    width: 100%;
  }

  .language-picker {
    min-height: 44px;
  }

  .suggestion-controls {
    justify-items: start;
    width: 100%;
    gap: 0.5rem;
  }

  .mine-only-label {
    font-size: 0.95rem;
  }

  .mine-only-label input {
    width: 18px;
    height: 18px;
  }

  .suggestion-score-block {
    width: 100%;
    text-align: left;
  }

  .vote-buttons {
    justify-content: flex-start;
  }

  .comment-form {
    flex-direction: column;
  }

  .comment-submit {
    width: 100%;
  }
}
