:root {
  color-scheme: light;
  --ink: #202124;
  --muted: #667085;
  --line: #e5e7eb;
  --paper: #ffffff;
  --soft: #fff7f2;
  --rose: #e25563;
  --rose-dark: #bf3346;
  --teal: #138a86;
  --gold: #f2b84b;
  --warm: #ffe4d6;
  --cream: #fffaf4;
  --shadow: 0 20px 45px rgba(20, 28, 38, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  position: relative;
  min-width: 320px;
  margin: 0;
  background:
    radial-gradient(circle at 9% 12%, rgba(226, 85, 99, 0.14), transparent 24%),
    radial-gradient(circle at 88% 10%, rgba(242, 184, 75, 0.18), transparent 20%),
    radial-gradient(circle at 75% 88%, rgba(19, 138, 134, 0.1), transparent 24%),
    var(--soft);
  color: var(--ink);
  font-family: Arial, "Microsoft YaHei", "PingFang SC", sans-serif;
  letter-spacing: 0;
}

button {
  font: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  min-height: 68px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 0 5vw;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.86);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-weight: 900;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  background: var(--rose);
  color: #ffffff;
}

.step-nav {
  display: inline-flex;
  gap: 8px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
}

.step-link {
  min-height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #667085;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
}

.step-link.active {
  background: var(--ink);
  color: #ffffff;
}

.view {
  display: none;
  width: min(1180px, 90vw);
  min-height: calc(100vh - 68px);
  margin: 0 auto;
  padding: 34px 0 58px;
  animation: viewIn 220ms ease both;
}

.view.active {
  display: block;
}

@keyframes viewIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.love-float {
  position: fixed;
  z-index: -1;
  color: rgba(226, 85, 99, 0.2);
  font-size: 44px;
  line-height: 1;
  animation: floatLove 7s ease-in-out infinite;
  pointer-events: none;
}

.love-float.one {
  top: 16%;
  left: 3%;
}

.love-float.two {
  top: 38%;
  right: 4%;
  color: rgba(242, 184, 75, 0.22);
  animation-delay: 1.4s;
}

.love-float.three {
  bottom: 12%;
  left: 8%;
  color: rgba(19, 138, 134, 0.14);
  animation-delay: 2.2s;
}

@keyframes floatLove {
  0%,
  100% {
    transform: translateY(0) rotate(-5deg);
  }

  50% {
    transform: translateY(-14px) rotate(7deg);
  }
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--teal);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.welcome-view {
  position: relative;
  width: 100%;
  max-width: none;
  min-height: calc(100vh - 68px);
  padding: 0;
  overflow: hidden;
}

.welcome-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.88), transparent 20%),
    radial-gradient(circle at 76% 22%, rgba(255, 210, 128, 0.38), transparent 24%),
    radial-gradient(circle at 72% 78%, rgba(226, 85, 99, 0.18), transparent 28%),
    linear-gradient(135deg, #fffaf4 0%, #ffe4d6 45%, #fff1f3 100%);
}

.welcome-bg::before,
.welcome-bg::after {
  content: "♥";
  position: absolute;
  color: rgba(226, 85, 99, 0.12);
  font-size: clamp(140px, 18vw, 260px);
  line-height: 1;
  transform: rotate(-12deg);
}

.welcome-bg::before {
  right: 8%;
  top: 14%;
}

.welcome-bg::after {
  left: 8%;
  bottom: 7%;
  color: rgba(242, 184, 75, 0.18);
  transform: rotate(12deg);
}

.warm-dot {
  position: absolute;
  display: block;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 18px 70px rgba(226, 85, 99, 0.16);
}

.dot-one {
  width: 220px;
  height: 220px;
  left: 10%;
  top: 18%;
}

.dot-two {
  width: 150px;
  height: 150px;
  right: 18%;
  bottom: 18%;
}

.dot-three {
  width: 96px;
  height: 96px;
  right: 38%;
  top: 16%;
  background: rgba(255, 244, 220, 0.72);
}

.welcome-content {
  position: relative;
  z-index: 1;
  display: flex;
  width: min(1180px, 90vw);
  min-height: calc(100vh - 68px);
  margin: 0 auto;
  padding: 72px 0 46px;
  flex-direction: column;
  justify-content: flex-end;
  color: #542d32;
}

.date-badge {
  width: max-content;
  max-width: 100%;
  margin-top: 34px;
  margin-bottom: 30px;
  padding: 9px 13px;
  border: 1px solid rgba(255, 255, 255, 0.44);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--rose-dark);
  font-size: 13px;
  font-weight: 900;
  backdrop-filter: blur(12px);
}

.welcome-content .eyebrow {
  color: var(--rose-dark);
}

h1 {
  max-width: 740px;
  margin-bottom: 18px;
  font-size: clamp(54px, 10vw, 112px);
  line-height: 0.96;
  letter-spacing: 0;
}

.lead {
  max-width: 680px;
  margin-bottom: 28px;
  color: #70434a;
  font-size: 18px;
  line-height: 1.8;
}

.welcome-actions,
.control-actions,
.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.primary-button,
.ghost-button,
.secondary-button,
.back-button,
.copy-button,
.reset-button,
.plain-button,
.filter,
.choose-button,
.note-button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 900;
}

.primary-button,
.copy-button {
  padding: 0 22px;
  border: 0;
  background: var(--gold);
  color: #211a07;
}

.ghost-button {
  padding: 0 22px;
  border: 1px solid rgba(226, 85, 99, 0.36);
  background: rgba(255, 255, 255, 0.58);
  color: var(--rose-dark);
}

.secondary-button {
  padding: 0 16px;
  border: 0;
  background: var(--ink);
  color: #ffffff;
}

.back-button,
.plain-button,
.reset-button {
  padding: 0 16px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: #344054;
}

.plain-button {
  min-height: 40px;
}

.date-promises {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 160px));
  gap: 1px;
  width: min(540px, 100%);
  margin-top: 44px;
  overflow: hidden;
  border: 1px solid rgba(226, 85, 99, 0.16);
  border-radius: 8px;
  background: rgba(226, 85, 99, 0.12);
  box-shadow: 0 18px 46px rgba(226, 85, 99, 0.12);
}

.date-promises div {
  padding: 18px;
  background: rgba(255, 255, 255, 0.68);
  backdrop-filter: blur(10px);
}

.date-promises strong {
  display: block;
  margin-bottom: 6px;
  color: #542d32;
  font-size: 17px;
}

.date-promises span {
  color: #805962;
  font-size: 13px;
  font-weight: 900;
}

.page-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  margin-bottom: 24px;
}

.page-head h2,
.result-hero h2 {
  margin-bottom: 12px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.04;
}

.page-head p,
.result-hero p,
.preference-copy p,
.match-hint {
  color: var(--muted);
  line-height: 1.7;
}

.preference-panel {
  display: grid;
  grid-template-columns: minmax(240px, 0.72fr) minmax(0, 1.28fr);
  gap: 22px;
  margin-bottom: 22px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 32px rgba(20, 28, 38, 0.08);
}

.preference-copy h3 {
  margin-bottom: 12px;
  font-size: clamp(26px, 3.5vw, 40px);
  line-height: 1.16;
}

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

.mood-button {
  min-height: 68px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.mood-button strong {
  display: block;
  font-size: 17px;
}

.mood-button span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.mood-button:hover,
.mood-button.active {
  transform: translateY(-2px);
  border-color: rgba(226, 85, 99, 0.52);
  box-shadow: 0 12px 24px rgba(20, 28, 38, 0.1);
}

.mood-button.active {
  background: #fff7f8;
}

.controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter {
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line);
  background: #ffffff;
  color: #344054;
}

.filter.active,
.filter:hover {
  border-color: var(--ink);
  background: var(--ink);
  color: #ffffff;
}

.control-actions {
  align-items: center;
  justify-content: flex-end;
}

.match-hint {
  font-size: 14px;
  font-weight: 800;
}

.restaurant-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.restaurant-card {
  display: flex;
  min-height: 100%;
  overflow: hidden;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(20, 28, 38, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.restaurant-card:hover,
.restaurant-card.selected {
  transform: translateY(-3px);
  border-color: rgba(226, 85, 99, 0.42);
  box-shadow: 0 22px 40px rgba(20, 28, 38, 0.14);
}

.restaurant-card.hidden {
  display: none;
}

.restaurant-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #d1d5db;
}

.card-body {
  display: flex;
  min-height: 320px;
  flex: 1;
  flex-direction: column;
  padding: 18px;
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.card-topline span,
.restaurant-facts span {
  min-width: 0;
  padding: 6px 10px;
  overflow: hidden;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-topline span {
  background: #eef9f8;
  color: #0f766e;
}

.card-topline strong {
  color: #98a2b3;
  font-size: 13px;
}

.restaurant-card h3 {
  min-height: 58px;
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.35;
}

.restaurant-card p {
  color: #4b5563;
  line-height: 1.65;
}

.restaurant-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 14px;
}

.restaurant-facts span {
  background: #f2f4f7;
  color: #475467;
  line-height: 1;
}

.card-reason {
  margin-bottom: 16px;
  padding: 12px;
  border-left: 3px solid var(--gold);
  background: #fffaf0;
  font-size: 14px;
}

.choose-button {
  width: 100%;
  margin-top: auto;
  border: 0;
  background: var(--ink);
  color: #ffffff;
}

.choose-button:hover {
  background: var(--rose);
}

.result-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: 26px;
  align-items: stretch;
}

.result-hero,
.confirm-card {
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.result-hero {
  position: relative;
  display: flex;
  overflow: hidden;
  flex-direction: column;
  min-height: 620px;
  padding: clamp(28px, 5vw, 54px);
  color: #ffffff;
  background:
    linear-gradient(180deg, rgba(32, 20, 18, 0.12), rgba(32, 20, 18, 0.34) 44%, rgba(32, 20, 18, 0.76)),
    url("images/result-date-photo.jpg") center / cover,
    url("images/result-date-photo.png") center / cover,
    linear-gradient(145deg, #9f293b 0%, #c95f61 52%, #eaa05d 100%);
}

.result-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 22%, rgba(255, 235, 185, 0.22), transparent 24%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.18), transparent 46%);
  opacity: 1;
  pointer-events: none;
}

.result-hero > * {
  position: relative;
  z-index: 1;
}

.result-hero .eyebrow {
  color: #ffe4d6;
}

.result-hero p {
  max-width: 520px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

.handdrawn-date {
  display: none;
}

.cartoon-date {
  position: relative;
  z-index: 2;
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 18px 22px rgba(116, 22, 35, 0.18));
}

.cartoon-date .big-heart {
  fill: rgba(255, 255, 255, 0.14);
  stroke: rgba(255, 250, 244, 0.88);
  stroke-width: 8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cartoon-date .ground-line,
.cartoon-date .arm,
.cartoon-date .leg,
.cartoon-date .shoe,
.cartoon-date .smile {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cartoon-date .ground-line {
  stroke: rgba(255, 250, 244, 0.48);
  stroke-width: 8;
}

.cartoon-date .small-hearts path {
  fill: rgba(255, 250, 244, 0.78);
  stroke: rgba(255, 255, 255, 0.82);
  stroke-width: 3;
  transform-origin: center;
  animation: heartFloat 4.8s ease-in-out infinite;
}

.cartoon-date .small-hearts path:nth-child(2) {
  animation-delay: 0.6s;
}

.cartoon-date .small-hearts path:nth-child(3) {
  animation-delay: 1.2s;
}

.cartoon-date .small-hearts path:nth-child(4) {
  animation-delay: 1.8s;
}

@keyframes heartFloat {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-8px) scale(1.04);
  }
}

.cartoon-person .face {
  fill: #ffe0c8;
  stroke: #fffaf4;
  stroke-width: 6;
}

.cartoon-person .hair {
  fill: #5c2b31;
  stroke: rgba(255, 250, 244, 0.74);
  stroke-width: 3;
  stroke-linejoin: round;
}

.cartoon-person .eye {
  fill: #4a252b;
}

.cartoon-person .smile {
  stroke: #8d3b45;
  stroke-width: 4;
}

.cartoon-person .shirt,
.cartoon-person .dress {
  stroke: #fffaf4;
  stroke-width: 6;
  stroke-linejoin: round;
}

.cartoon-person .boy-shirt {
  fill: #8bd3ca;
}

.cartoon-person .dress {
  fill: #ffd166;
}

.cartoon-person .arm,
.cartoon-person .leg,
.cartoon-person .shoe {
  stroke: #fffaf4;
}

.cartoon-person .arm {
  stroke-width: 11;
}

.cartoon-person .hand-arm {
  stroke: #ffe0c8;
}

.cartoon-person .hand {
  fill: #ffe0c8;
  stroke: #fffaf4;
  stroke-width: 4;
}

.cartoon-person .leg {
  stroke-width: 11;
}

.cartoon-person .shoe {
  stroke-width: 8;
}

.confirm-card {
  display: flex;
  min-height: 620px;
  flex-direction: column;
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--line);
  background: #ffffff;
}

.result-kicker {
  display: inline-flex;
  width: max-content;
  margin-bottom: 18px;
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff1f2;
  color: var(--rose-dark);
  font-size: 13px;
  font-weight: 900;
}

.confirm-card h3 {
  margin-bottom: 14px;
  font-size: clamp(34px, 5vw, 54px);
  line-height: 1.1;
}

.confirm-card > p {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.8;
}

.love-note span {
  display: block;
  margin-bottom: 8px;
  color: #98a2b3;
  font-size: 12px;
  font-weight: 900;
}

.love-note {
  margin: 0 0 18px;
  padding: 18px;
  border: 1px solid #ffd5db;
  border-radius: 8px;
  background: #fff7f8;
}

.love-note span {
  color: var(--rose-dark);
}

.love-note p {
  margin-bottom: 14px;
  color: #344054;
  font-size: 16px;
  line-height: 1.65;
}

.note-button {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid rgba(226, 85, 99, 0.34);
  background: #ffffff;
  color: var(--rose-dark);
}

.copy-button {
  background: var(--rose);
  color: #ffffff;
}

.reset-button:hover,
.plain-button:hover,
.back-button:hover {
  border-color: var(--rose);
  color: var(--rose-dark);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 26px 5vw;
  background: #ffffff;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 1080px) {
  .restaurant-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .preference-panel,
  .result-layout {
    grid-template-columns: 1fr;
  }

  .result-hero,
  .confirm-card {
    min-height: auto;
  }

  .result-hero {
    min-height: 560px;
  }

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

@media (max-width: 760px) {
  .topbar {
    align-items: flex-start;
    min-height: auto;
    flex-direction: column;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .step-nav {
    width: 100%;
    justify-content: space-between;
  }

  .step-link {
    flex: 1;
  }

  .view {
    width: min(100% - 28px, 1180px);
    min-height: 0;
    padding-top: 24px;
  }

  .welcome-content {
    width: min(100% - 28px, 1180px);
    min-height: calc(100vh - 120px);
    padding-top: 52px;
  }

  .welcome-stats,
  .date-promises,
  .restaurant-grid,
  .mood-grid {
    grid-template-columns: 1fr;
  }

  .page-head,
  .controls {
    align-items: flex-start;
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .preference-panel {
    padding: 20px;
  }

  .control-actions {
    justify-content: flex-start;
  }

  .card-body {
    min-height: auto;
  }

  .restaurant-card h3 {
    min-height: 0;
  }

  .result-hero {
    min-height: 520px;
    padding: 28px;
  }

  .handdrawn-date {
    min-height: 270px;
    margin-top: 22px;
  }

  .cartoon-date {
    width: min(100%, 360px);
    margin: 0 auto;
  }

  .result-actions,
  .welcome-actions {
    flex-direction: column;
  }

  .primary-button,
  .ghost-button,
  .secondary-button,
  .copy-button,
  .reset-button,
  .plain-button {
    width: 100%;
  }

  .footer {
    flex-direction: column;
  }
}
