:root {
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #20231c;
  background: #f7edcf;
}
* { box-sizing: border-box; }
body { margin: 0; background: #f7edcf; }
button, input { font: inherit; }
button { cursor: pointer; }
.shell { width: min(760px, calc(100% - 32px)); margin: 0 auto; padding: 40px 0 72px; }
.brand { display:flex; justify-content:space-between; align-items:center; margin-bottom: 50px; font-size: 15px; }
.brand-title { display:inline-flex; align-items:center; gap:10px; text-decoration:none; color:#20231c; }
.brand-logo { width:34px; height:34px; flex:0 0 34px; border-radius:8px; box-shadow:0 2px 6px rgba(32,35,28,.14); }
.brand-text { font-family:Georgia, "Songti SC", serif; font-size:22px; font-weight:800; letter-spacing:-.06em; color:#20231c; display:inline-flex; align-items:baseline; gap:5px; }
.brand-text b { font-family:-apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif; font-size:16px; font-weight:700; letter-spacing:-.02em; color:#e36f32; }
.brand-link { color:#20231c; font-size:13px; font-weight:700; text-decoration:none; padding:6px 14px; border:1px solid rgba(32,35,28,.2); border-radius:20px; background:rgba(255,255,255,.55); transition:transform 160ms var(--ease-out), background-color 180ms ease, border-color 180ms ease, color 180ms ease; display:inline-flex; align-items:center; gap:4px; user-select:none; -webkit-tap-highlight-color:transparent; }
.brand-link:hover { background:#20231c; color:#f7edcf; border-color:#20231c; }
.brand-link:active { transform:scale(0.96); }
.brand-link span { font-size:11px; }
.muted { color: #505645; }
h1 { margin: 0 0 12px; font-family:Georgia, "Songti SC", serif; font-size: clamp(32px, 6vw, 50px); line-height: 1.12; letter-spacing: -0.05em; color: #20231c; }
.intro { max-width: 560px; color: #505645; line-height: 1.65; margin: 0 0 32px; }

.primary, .secondary, .landing-cta {
  transition: transform 160ms var(--ease-out), background-color 180ms ease, border-color 180ms ease, box-shadow 180ms ease, color 180ms ease;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.primary { border:0; background:#20231c; color:#f7edcf; padding: 14px 22px; border-radius: 8px; font-weight:700; box-shadow: 0 2px 8px rgba(32,35,28,.12); }
.secondary { border:1px solid rgba(32,35,28,.22); color:#20231c; background:rgba(255,255,255,.7); padding: 13px 20px; border-radius:8px; font-weight:700; }
.primary:active, .secondary:active, .landing-cta:active { transform: scale(0.97); }

@media (hover: hover) and (pointer: fine) {
  .primary:hover { background: #35392e; color: #fff; }
  .secondary:hover { border-color: #20231c; background: #fff; }
  .landing-cta:hover { background: #35392e; }
}

.question-meta { display:flex; justify-content:space-between; color:#505645; margin-bottom: 22px; font-size:14px; font-weight: 600; }
.progress { height: 5px; background:rgba(32,35,28,.1); border-radius:99px; margin-bottom: 32px; overflow:hidden; }
.progress > div { height:100%; background:#e36f32; transition: width 320ms var(--ease-drawer); }

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

.question { margin-bottom: 28px; animation: questionEntrance 160ms var(--ease-out); }
.question h2 { font-size: clamp(24px, 4vw, 28px); line-height:1.32; margin:0 0 10px; font-family:Georgia, "Songti SC", serif; letter-spacing:-.04em; color: #20231c; }
.question-type { display:inline-block; color:#e36f32; font-size:13px; font-weight:700; margin:-2px 0 12px; }
.question p { margin:0 0 22px; color:#505645; line-height:1.55; }
.options { display:grid; gap:10px; }
.option { width:100%; display:flex; gap:12px; align-items:flex-start; text-align:left; border:1px solid rgba(32,35,28,.16); background:rgba(255,255,255,.8); border-radius:10px; padding:16px; line-height:1.45; cursor:pointer; transition: border-color 140ms ease, background-color 140ms ease, box-shadow 140ms ease, transform 140ms ease; user-select:none; -webkit-tap-highlight-color:transparent; box-shadow: 0 1px 3px rgba(32,35,28,.04); }
@media (hover: hover) and (pointer: fine) {
  .option:hover { border-color:#20231c; background:#fff; }
}
.option:active { transform: scale(0.992); }
.option.selected { border-color:#20231c; background:#fffaf0; box-shadow: inset 0 0 0 1.5px #20231c, 0 2px 8px rgba(32,35,28,.06); }
.choice-control { position:absolute; opacity:0; pointer-events:none; }
.choice-indicator { width:20px; height:20px; flex:0 0 20px; margin-top:1px; border:1.5px solid #8e9285; border-radius:5px; position:relative; background:#fff; transition: background-color 160ms ease, border-color 160ms ease; }
.choice-control[type="radio"] + .choice-indicator { border-radius:50%; }
.choice-control[type="checkbox"]:checked + .choice-indicator { background:#20231c; border-color:#20231c; }
.choice-control[type="checkbox"]:checked + .choice-indicator::after { content:'✓'; position:absolute; inset:0; display:grid; place-items:center; color:#f7edcf; font-size:13px; font-weight:700; }
.choice-control[type="radio"]:checked + .choice-indicator { border:6px solid #20231c; }
.choice-control:focus-visible + .choice-indicator { outline:3px solid rgba(32,35,28,.28); outline-offset:3px; }
.actions { display:flex; justify-content:space-between; gap:12px; padding-top:8px; }
.actions .primary { margin-left:auto; }
.field { width:100%; border:1px solid rgba(32,35,28,.2); border-radius:8px; padding:12px; margin-top:10px; background:#fff; font-size:15px; }
.result-heading { margin-bottom: 30px; }
.result-heading h1 { font-family:Georgia, "Songti SC", serif; letter-spacing:-.05em; color: #20231c; }
.profile { padding:18px 20px; border-left:4px solid #e36f32; background:#fffaf0; margin: 24px 0 32px; line-height:1.65; border-radius: 0 10px 10px 0; box-shadow: 0 2px 8px rgba(32,35,28,.05); border-top:1px solid rgba(32,35,28,.06); border-right:1px solid rgba(32,35,28,.06); border-bottom:1px solid rgba(32,35,28,.06); color:#383d31; }
.group { margin: 38px 0; }
.group h2 { font-size:24px; margin:0 0 6px; font-family:Georgia, "Songti SC", serif; letter-spacing:-.04em; color: #20231c; }
.group > p { margin:0 0 16px; color:#505645; font-size:15px; }

@keyframes cardEntrance {
  from { opacity: 0; transform: translateY(10px) scale(0.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.restaurant {
  background: #fff;
  border: 1px solid rgba(32,35,28,.14);
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 14px;
  box-shadow: 0 2px 8px rgba(32,35,28,.04);
  animation: cardEntrance 300ms var(--ease-out) backwards;
  transition: transform 180ms var(--ease-out), box-shadow 180ms var(--ease-out), border-color 180ms ease;
}
@media (hover: hover) and (pointer: fine) {
  .restaurant:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(32,35,28,.08); border-color: rgba(32,35,28,.24); }
}

.restaurant-top { display:flex; justify-content:space-between; gap:14px; align-items:flex-start; }
.restaurant h3 { margin:0 0 7px; font-size:20px; font-family:Georgia, "Songti SC", serif; letter-spacing:-.03em; color: #20231c; }
.facts { color:#505645; font-size:14px; font-weight: 500; }
.planning-facts { display:flex; flex-wrap:wrap; gap:7px; margin-top:12px; }
.planning-facts span { border:1px solid #e2ddce; background: #f4efdf; border-radius:999px; color:#383d31; font-size:13px; font-weight:600; line-height:1.2; padding:5px 9px; }
.label { white-space:nowrap; padding:4px 10px; border-radius:20px; font-size:12px; font-weight:700; background:#edf2e9; color:#42613e; }
.label.detour { background:#fff3e0; color:#9c5300; }
.label.destination { background:#fbeae3; color:#b83b18; }
.why { line-height:1.6; margin:14px 0 0; color:#20231c; font-size:15px; }
.tradeoff { color:#7c5a51; line-height:1.45; margin:9px 0 0; font-size:14px; }
.location-note { color:#2e4734; background:#eff5ed; border-radius:8px; font-size:13px; line-height:1.45; margin:12px 0 0; padding:9px 11px; }
.links { display:flex; flex-wrap:wrap; gap:12px; margin-top:16px; }
.links a { color:#b83b18; font-size:14px; font-weight:700; text-decoration:underline; text-underline-offset:3px; transition: opacity 160ms ease; }
.links a:hover { opacity: .8; }
.data-note { padding:14px 16px; background:rgba(255,255,255,.6); border:1px solid rgba(32,35,28,.1); font-size:13px; color:#505645; line-height:1.5; border-radius:10px; }
.error { color:#a52620; background:#fff0ef; padding:16px; border-radius:8px; }
.result-actions { display:flex; align-items:center; gap:12px; flex-wrap:wrap; }
.share-button { display:inline-flex; align-items:center; gap:8px; border:1px solid #20231c; border-radius:8px; padding:13px 18px; color:#f7edcf; background:#20231c; box-shadow:0 2px 8px rgba(32,35,28,.12); font-weight:700; transition:transform 160ms var(--ease-out), background-color 180ms ease, box-shadow 180ms ease; user-select:none; -webkit-tap-highlight-color:transparent; }
.share-button span { font-size:18px; line-height:.7; transform:rotate(45deg); }
.share-button:active { transform:scale(.97); }
.share-button:disabled { cursor:wait; opacity:.7; }
.share-status { flex-basis:100%; min-height:18px; margin:0; color:#505645; font-size:13px; }
@media (hover: hover) and (pointer: fine) { .share-button:hover { background:#35392e; box-shadow:0 5px 14px rgba(32,35,28,.16); } }
.result-view-toggle { display:inline-flex; padding:3px; border:1px solid rgba(32,35,28,.18); border-radius:10px; background:rgba(255,255,255,.65); backdrop-filter:blur(12px); -webkit-backdrop-filter:blur(12px); }
.result-view-button { border:0; border-radius:7px; padding:7px 13px; color:#505645; background:transparent; font-size:13px; font-weight:700; transition: transform 160ms var(--ease-out), color 160ms ease, background-color 160ms ease, box-shadow 160ms ease; user-select:none; -webkit-tap-highlight-color:transparent; }
.result-view-button:active { transform: scale(0.96); }
.result-view-button[aria-pressed="true"] { color:#20231c; background:#fff; box-shadow:0 1px 4px rgba(32,35,28,.15); }
.result-map-view { display:grid; grid-template-columns:minmax(310px, .9fr) minmax(0, 1.45fr); min-height:min(72vh, 720px); margin:38px 0; overflow:hidden; border:1px solid rgba(32,35,28,.18); border-radius:12px; background:#fff; box-shadow:0 6px 22px rgba(32,35,28,.08); }
.result-map-view[hidden] { display:none; }
.map-detail-panel { min-height:0; overflow:auto; padding:20px; background:#fffaf0; }
.map-detail-head { display:flex; align-items:baseline; justify-content:space-between; gap:12px; margin:0 0 18px; color:#505645; font-size:13px; }
.map-detail-head strong { color:#20231c; font-size:13px; }
.map-detail-panel .restaurant { margin:0; box-shadow:none; }
#restaurant-map { min-height:min(72vh, 720px); overflow:hidden; background:#e8ece5; }
.map-pin-wrap { background:transparent; border:0; }
.map-pin { display:grid; place-items:center; width:32px; height:32px; border:2px solid #fff; border-radius:50%; color:#fff; background:#b9472d; box-shadow:0 2px 6px rgba(45,24,15,.25); font-size:12px; font-weight:800; transition: transform 250ms var(--ease-spring), background-color 200ms ease; }
.map-pin.active { background:#20231c; transform:scale(1.18); }
.leaflet-popup-content { margin:12px 14px; font-family:-apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif; line-height:1.5; }
.leaflet-popup-content strong { display:block; margin-bottom:2px; font-family:Georgia, "Songti SC", serif; font-size:15px; }
.leaflet-popup-content span { color:#505645; font-size:12px; }
.leaflet-popup-content a { display:inline-block; margin-top:7px; color:#b83b18; font-size:12px; font-weight:700; }
@media (min-width: 721px) {
  .shell.map-active { width:100%; min-height:100svh; margin:0; padding:0; }
  .shell.map-active > .brand { display:none; }
  .shell.map-active .result-heading { position:fixed; z-index:1001; top:22px; left:22px; margin:0; }
  .shell.map-active .result-heading > .muted, .shell.map-active .result-heading h1, .shell.map-active .profile { display:none; }
  .shell.map-active .result-actions { gap:8px; }
  .shell.map-active .result-view-toggle, .shell.map-active .secondary { box-shadow:0 5px 18px rgba(32,35,28,.15); }
  .shell.map-active .result-map-view { grid-template-columns:minmax(380px, 38vw) minmax(0, 1fr); width:100%; min-height:100svh; height:100svh; margin:0; border:0; border-radius:0; }
  .shell.map-active .map-detail-panel { padding:88px 28px 32px; }
  .shell.map-active #restaurant-map { min-height:100svh; }
  .shell.map-active .data-note { display:none; }
}
.landing-shell { width:100%; min-height:100svh; margin:0; padding:0; }
.landing-shell .brand { position:absolute; z-index:2; top:0; left:50%; display:flex; width:min(100% - 48px, 1440px); margin:0; padding:28px 0 0; border-top:0; color:#20231c; transform:translateX(-50%); }
.landing-shell .brand strong { font-size:20px; letter-spacing:-.05em; }
.landing-shell .brand .muted { color:#20231c; font-size:13px; font-weight:700; }
.landing-hero { display:grid; grid-template-columns:minmax(0, 1.1fr) minmax(330px, .9fr); min-height:100svh; overflow:hidden; color:#20231c; background:linear-gradient(90deg, #f7edcf 0 58%, #e36f32 58% 100%); padding:clamp(132px, 15vh, 188px) max(5vw, calc((100vw - 1440px) / 2)) clamp(76px, 10vh, 128px); }
.landing-copy { align-self:center; max-width:710px; }
.landing-copy h1 { margin:0; font-family:Georgia, "Songti SC", serif; font-size:clamp(45px, 5.4vw, 82px); line-height:1.02; letter-spacing:-.08em; white-space:nowrap; }
.landing-subtitle { margin:30px 0 0; font-size:clamp(19px, 1.7vw, 24px); font-weight:700; line-height:1.35; white-space:nowrap; }
.landing-intro { margin:10px 0 0; color:#505645; font-size:16px; line-height:1.55; }
.landing-cta { display:flex; align-items:center; justify-content:space-between; width:260px; margin-top:38px; padding:17px 19px; border-radius:0; color:#f7edcf; background:#20231c; font-size:15px; }
.landing-cta span { font-size:22px; line-height:.7; }
.landing-note { margin:16px 0 0; color:#505645; font-size:12px; }
.landing-ticket { position:relative; align-self:end; justify-self:end; width:min(410px, 100%); padding:29px 30px; color:#f7edcf; background:#20231c; box-shadow:13px 13px 0 rgba(32,35,28,.22); transform:rotate(-3deg); font-family:ui-monospace, SFMono-Regular, Menlo, monospace; }
.landing-ticket::before { content:'NYC'; position:absolute; right:21px; top:-90px; color:#f7edcf; font-family:Georgia, "Songti SC", serif; font-size:142px; font-style:italic; letter-spacing:-.14em; opacity:.42; }
.landing-ticket span { display:block; margin-bottom:18px; font-size:10px; letter-spacing:.09em; }
.landing-ticket strong { display:block; padding:13px 0; border-top:1px dashed rgba(247,237,207,.6); border-bottom:1px dashed rgba(247,237,207,.6); font-size:20px; letter-spacing:-.05em; }
.landing-ticket p { margin:17px 0 0; font-size:12px; line-height:1.6; }
@media (max-width: 520px) {
  .shell { width: min(100% - 24px, 760px); padding-top: 20px; padding-bottom: 48px; }
  .brand { margin-bottom: 24px; }
  .question h2 { font-size: 22px; line-height: 1.3; }
  .option { padding: 14px; min-height: 48px; font-size: 15px; }
  .actions { flex-direction: column-reverse; gap: 10px; }
  .actions .primary { width: 100%; margin-left: 0; padding: 14px; min-height: 48px; font-size: 16px; display: flex; justify-content: center; align-items: center; }
  .actions .secondary { width: 100%; padding: 13px; min-height: 46px; font-size: 15px; display: flex; justify-content: center; align-items: center; }
  .actions span { display: none; }
  .planning-facts { gap: 6px; }
  .planning-facts span { font-size: 12px; padding: 4px 7px; }
  .result-actions { gap:10px; }
  .share-button, .result-actions > .secondary { flex:1 1 calc(50% - 5px); justify-content:center; padding:13px 12px; }
  .result-view-toggle { order:-1; flex-basis:100%; justify-content:center; }
}

@media (max-width: 720px) {
  .landing-shell .brand { width: calc(100% - 32px); padding-top: 20px; }
  .landing-shell .brand .muted { font-size: 12px; }
  .landing-hero { display: flex; flex-direction: column; justify-content: space-between; min-height: 100svh; padding: 96px 20px 40px; background: linear-gradient(180deg, #f7edcf 0 68%, #e36f32 68% 100%); }
  .landing-copy { align-self: auto; max-width: none; }
  .landing-copy h1 { font-size: clamp(30px, 8.5vw, 42px); white-space: normal; word-break: break-word; line-height: 1.1; letter-spacing: -.05em; }
  .landing-subtitle { margin-top: 16px; font-size: 17px; white-space: normal; line-height: 1.4; }
  .landing-intro { font-size: 14px; margin-top: 8px; }
  .landing-cta { width: 100%; min-height: 52px; margin-top: 28px; padding: 16px 20px; font-size: 16px; box-shadow: 0 4px 12px rgba(32,35,28,.15); }
  .landing-note { display: block; margin-top: 12px; opacity: .85; font-size: 12px; }
  .landing-ticket { align-self: stretch; width: 100%; margin-top: 32px; padding: 18px 20px; box-shadow: 6px 6px 0 rgba(32,35,28,.22); transform: none; }
  .landing-ticket::before { top: -48px; right: 12px; font-size: 76px; opacity: .35; }
  .landing-ticket strong { font-size: 16px; padding: 10px 0; }
  .landing-ticket p { margin-top: 12px; font-size: 11px; }

  .result-map-view { display: flex; flex-direction: column; min-height: 0; }
  .map-detail-panel { max-height: none; padding: 16px; order: 2; }
  #restaurant-map { order: 1; height: 50vh; min-height: 320px; }
}
