:root {
  --ink: #20302f;
  --ink-soft: #425553;
  --muted: #77817e;
  --paper: #f5f3ec;
  --surface: #ffffff;
  --surface-alt: #faf9f4;
  --band: #ecebe2;
  --soft-bg: #f1efe8;
  --line: #e4ded0;
  --green: #0f6b5b;
  --green-deep: #0a4d42;
  --coral: #e2603f;
  --coral-deep: #c44c2e;
  --amber: #e3a72f;
  --sky: #4a8ea6;
  --shadow: 0 20px 50px rgba(24, 44, 41, 0.14);
  --radius: 8px;
  color-scheme: light;
}

[data-theme="dark"] {
  --ink: #e8ece7;
  --ink-soft: #bcc6c1;
  --muted: #8e9a95;
  --paper: #141b1a;
  --surface: #1d2624;
  --surface-alt: #222d2a;
  --band: #18211f;
  --soft-bg: #2a3532;
  --line: #33413e;
  --green: #3fbd9f;
  --green-deep: #7ad9c2;
  --coral: #ff8a66;
  --coral-deep: #ff9a78;
  --amber: #f0bc57;
  --sky: #77b7cd;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
}

body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", system-ui, -apple-system, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

.container {
  width: min(1140px, calc(100% - 48px));
  margin: 0 auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 700;
  font-size: 14px;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-lg {
  min-height: 52px;
  padding: 0 28px;
  font-size: 16px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--coral), var(--coral-deep));
  color: #fff;
  box-shadow: 0 10px 24px rgba(226, 96, 63, 0.28);
}

.btn-primary:hover {
  box-shadow: 0 14px 30px rgba(226, 96, 63, 0.36);
}

.btn-secondary {
  border-color: var(--line);
  background: var(--surface);
  color: var(--ink-soft);
}

.btn-secondary:hover {
  border-color: var(--green);
  color: var(--green);
}

.btn-ghost {
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  backdrop-filter: blur(8px);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.2);
}

.btn.is-loading .btn-icon,
.btn.is-loading .btn-label {
  display: none;
}

.spinner {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

.btn.is-loading .spinner {
  display: block;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  padding: 0 28px;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  font-weight: 800;
  font-size: 19px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--green), #17a091);
  color: #fff;
}

.brand-sub {
  align-self: center;
  margin-left: -4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link,
.nav-icon-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 13px;
  border: 0;
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink-soft);
  font-weight: 700;
  font-size: 14px;
}

.nav-icon-btn {
  width: 40px;
  padding: 0;
}

.nav-link:hover,
.nav-icon-btn:hover {
  background: rgba(15, 107, 91, 0.1);
  color: var(--green);
}

.nav-link-primary {
  margin-left: 6px;
  background: var(--green);
  color: #fff;
}

.nav-link-primary:hover {
  background: var(--green-deep);
  color: #fff;
}

.user-area {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.user-area .nav-link {
  padding: 0 10px;
}

.user-name {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-logout {
  color: var(--muted);
  font-size: 12px;
}

.nav-logout:hover {
  color: var(--coral-deep);
}

.nav-badge {
  min-width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--coral);
  color: #fff;
  font-size: 11px;
}

.icon-sun,
.icon-moon {
  display: block;
}

.icon-moon {
  display: none;
}

[data-theme="dark"] .icon-sun {
  display: none;
}

[data-theme="dark"] .icon-moon {
  display: block;
}

.hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: flex-end;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(8, 38, 36, 0.88) 0%, rgba(8, 38, 36, 0.58) 55%, rgba(8, 38, 36, 0.24) 100%),
    url("https://images.unsplash.com/photo-1506744038136-46273834b3fb?auto=format&fit=crop&w=1800&q=80") center 42% / cover no-repeat,
    linear-gradient(135deg, #145e5a, #3a7f6d);
}

.hero-inner {
  width: min(1140px, calc(100% - 48px));
  margin: 0 auto;
  padding: 110px 0 90px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--coral-deep);
  font-size: 12px;
  font-weight: 800;
}

.hero-eyebrow {
  color: #ffd9a0;
}

.hero h1 {
  margin: 0 0 14px;
  max-width: 720px;
  font-size: 60px;
  line-height: 1.12;
  letter-spacing: 0;
  font-weight: 800;
}

.hero h1 em {
  font-style: normal;
  color: #ffd9a0;
}

.hero-sub {
  max-width: 580px;
  margin: 0 0 32px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 32px;
}

.hero-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 13px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-weight: 600;
  backdrop-filter: blur(8px);
}

.planner-section,
.destination-section,
.how-section,
.empty-section,
.result-section {
  padding: 80px 0;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 30px;
}

.section-head h2,
.result-title-wrap h2,
.empty-copy h2 {
  margin: 0;
  font-size: 34px;
  line-height: 1.2;
  letter-spacing: 0;
  font-weight: 800;
}

.section-note {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 14px;
}

.template-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.template-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.template-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 700;
  transition: all 0.15s ease;
}

.template-chip:hover {
  border-color: var(--green);
  color: var(--green);
  transform: translateY(-1px);
}

.planner-card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.planner-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 9px;
  min-width: 0;
}

.field-destination,
.field-notes {
  grid-column: 1 / -1;
}

.field-label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 700;
}

.input-wrap,
.stepper {
  display: flex;
  align-items: center;
  height: 52px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-alt);
  color: var(--muted);
  overflow: hidden;
}

.input-wrap {
  gap: 9px;
  padding: 0 14px;
}

.input-wrap input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 16px;
  font-weight: 700;
}

.input-wrap input::placeholder {
  color: var(--muted);
  font-weight: 500;
}

.input-date input {
  color-scheme: light;
}

[data-theme="dark"] .input-date input {
  color-scheme: dark;
}

.input-wrap:focus-within,
.stepper:focus-within {
  border-color: var(--green);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(15, 107, 91, 0.14);
}

.input-suffix {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.stepper {
  display: grid;
  grid-template-columns: 52px 1fr 52px;
}

.stepper button {
  align-self: stretch;
  display: grid;
  place-items: center;
  border: 0;
  background: transparent;
  color: var(--green);
}

.stepper button:hover {
  background: rgba(15, 107, 91, 0.1);
}

.stepper input {
  height: 100%;
  width: 100%;
  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  outline: 0;
  background: transparent;
  color: var(--ink);
  text-align: center;
  font-size: 17px;
  font-weight: 800;
  appearance: textfield;
  -moz-appearance: textfield;
}

.stepper input::-webkit-inner-spin-button,
.stepper input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.prefs-row {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.prefs-label {
  flex-shrink: 0;
}

.pref-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  position: relative;
}

.chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.chip-body {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-alt);
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 700;
  transition: all 0.15s ease;
}

.chip:hover .chip-body {
  border-color: var(--green);
  color: var(--green);
}

.chip input:checked + .chip-body {
  border-color: var(--green);
  background: rgba(15, 107, 91, 0.12);
  color: var(--green-deep);
}

.notes-input {
  width: 100%;
  min-height: 72px;
  padding: 12px 14px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  outline: 0;
  background: var(--surface-alt);
  color: var(--ink);
  font-size: 14px;
}

.notes-input:focus {
  border-color: var(--green);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(15, 107, 91, 0.14);
}

.notes-input::placeholder {
  color: var(--muted);
}

.planner-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 24px;
}

.form-feedback {
  min-width: 0;
}

.budget-note {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.form-error {
  margin: 0 0 6px;
  color: #d6402e;
  font-size: 14px;
  font-weight: 700;
}

.progress-text {
  margin: 0 0 6px;
  color: var(--green);
  font-size: 14px;
  font-weight: 700;
}

.progress-text::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 1s ease infinite;
}

@keyframes pulse {
  50% {
    opacity: 0.35;
  }
}

.planner-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.btn-generate {
  min-width: 168px;
}

.setting-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.setting-toggle input {
  width: 16px;
  height: 16px;
  accent-color: var(--green);
}

.city-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.city-card {
  position: relative;
  min-height: 244px;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  color: #fff;
  text-align: left;
  background:
    linear-gradient(160deg, rgba(15, 107, 91, 0.25), rgba(8, 38, 36, 0.75)),
    var(--city-img, linear-gradient(135deg, #145e5a, #3a7f6d)) center 35% / cover no-repeat;
  box-shadow: 0 12px 30px rgba(24, 44, 41, 0.14);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.city-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(8, 38, 36, 0.02) 45%, rgba(8, 38, 36, 0.8) 100%);
  pointer-events: none;
}

.city-card-body {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 2;
  display: block;
}

.city-card-name {
  display: block;
  font-size: 21px;
  font-weight: 800;
}

.city-card-meta {
  display: block;
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
}

.city-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px rgba(24, 44, 41, 0.22);
}

.how-section {
  background: var(--band);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.how-item {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.how-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: 16px;
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
}

.how-item h3 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 800;
}

.how-item p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.empty-section {
  padding-bottom: 0;
}

.empty-panel {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 28px;
  align-items: center;
  padding: 34px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.empty-copy p:last-child {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.example-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.example-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 108px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-alt);
  color: var(--ink);
  text-align: left;
  transition: all 0.15s ease;
}

.example-card:hover {
  border-color: var(--green);
  transform: translateY(-2px);
}

.example-card strong {
  font-size: 15px;
}

.example-card span {
  color: var(--muted);
  font-size: 12px;
}

.result-section {
  max-width: none;
}

.result-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.result-title-wrap h2 {
  margin-bottom: 8px;
  font-size: 26px;
}

.result-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.result-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 11px;
  font-weight: 700;
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex-shrink: 0;
}

.result-actions .btn {
  min-height: 34px;
  padding: 0 10px;
  font-size: 12px;
}

.result-layout {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.result-summary {
  position: sticky;
  top: 84px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 14px 40px rgba(24, 44, 41, 0.08);
}

.summary-label {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.budget-block {
  margin-bottom: 20px;
}

.budget-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 9px;
}

.budget-amount {
  font-size: 28px;
  font-weight: 800;
}

.budget-sub {
  color: var(--muted);
  font-size: 12px;
}

.budget-bar {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--soft-bg);
}

.budget-bar-fill {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--green), var(--amber));
  transition: width 0.5s ease;
}

.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.stat-cell {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-alt);
}

.stat-value {
  display: block;
  font-size: 19px;
  font-weight: 800;
}

.stat-name {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.route-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 18px;
}

.route-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg);
}

.route-item svg {
  flex-shrink: 0;
  color: var(--coral);
}

.route-item strong {
  display: block;
  color: var(--ink);
  font-size: 15px;
  font-weight: 800;
}

.route-item span {
  display: block;
  margin-top: 1px;
  color: var(--muted);
  font-size: 11px;
}

.lodging-card {
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg);
}

.lodging-head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.lodging-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  border-radius: 10px;
  background: rgba(138, 111, 191, 0.14);
  color: #7a6aa8;
}

.lodging-title {
  min-width: 0;
}

.lodging-title strong {
  display: block;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.lodging-title span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.lodging-desc {
  margin: 10px 0;
  color: var(--ink-soft);
  font-size: 12.5px;
  line-height: 1.6;
}

.lodging-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.lodging-price {
  color: var(--coral-deep);
  font-size: 12px;
  font-weight: 800;
}

.btn-sm {
  min-height: 30px;
  padding: 0 10px;
  font-size: 12px;
}

.lodging-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.breakdown-title {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 800;
}

.breakdown-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 0 0 18px;
}

.breakdown-item {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
}

.breakdown-dot {
  width: 9px;
  height: 9px;
  flex-shrink: 0;
  border-radius: 50%;
}

.breakdown-item span:last-child {
  margin-left: auto;
  color: var(--muted);
  font-weight: 700;
}

.summary-tip {
  margin: 0;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: rgba(15, 107, 91, 0.1);
  color: var(--green-deep);
  font-size: 13px;
}

.tips-block {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.tip-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.tip-item svg {
  flex-shrink: 0;
  margin-top: 1px;
  color: var(--green);
}

.map-wrap {
  position: relative;
  margin-bottom: 16px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(24, 44, 41, 0.06);
  z-index: 0;
}

.map-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.map-title {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.map-title svg {
  color: var(--coral);
}

.map-day-tabs {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
}

.map-day-tabs::-webkit-scrollbar {
  display: none;
}

.map-day-tab {
  min-height: 28px;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.map-day-tab:hover {
  border-color: var(--coral);
  color: var(--coral-deep);
}

.map-day-tab.is-active {
  border-color: var(--coral);
  background: var(--coral);
  color: #fff;
}

.map-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 12px;
  align-items: stretch;
}

.itinerary-map {
  display: flex;
  min-height: 148px;
  border-radius: 10px;
  background: var(--bg);
  overflow: auto;
}

.route-map {
  display: flex;
  align-items: stretch;
  width: 100%;
  min-width: max-content;
  padding: 14px 12px 10px;
}

.route-stops {
  display: flex;
  align-items: flex-start;
  width: 100%;
}

.route-stop {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 84px;
  padding-top: 4px;
}

.route-dot {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 4px solid var(--surface);
  box-shadow: 0 0 0 2px currentColor;
}

.route-dot.cat-sight {
  color: var(--green);
  background: var(--green);
}

.route-dot.cat-photo {
  color: var(--sky);
  background: var(--sky);
}

.route-dot.cat-food {
  color: var(--coral);
  background: var(--coral);
}

.route-dot.cat-walk {
  color: var(--amber);
  background: var(--amber);
}

.route-dot.cat-stay {
  color: #7a6aa8;
  background: #7a6aa8;
}

.route-slot {
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.route-name {
  max-width: 84px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  overflow-wrap: anywhere;
}

.route-leg {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 30px;
  padding-top: 9px;
}

.leg-time,
.leg-km {
  color: var(--muted);
  font-size: 10px;
  white-space: nowrap;
}

.leg-time {
  margin-bottom: 4px;
}

.leg-km {
  margin-top: 4px;
}

.leg-line {
  width: 100%;
  height: 2px;
  position: relative;
  background: var(--line);
}

.leg-line::before {
  content: "";
  position: absolute;
  top: -3px;
  right: -2px;
  width: 8px;
  height: 8px;
  border-top: 2px solid var(--muted);
  border-right: 2px solid var(--muted);
  transform: rotate(45deg);
}

.map-stats {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 4px 0;
}

.map-stat {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  font-size: 12px;
}

.map-stat svg {
  flex-shrink: 0;
  color: var(--coral);
}

.map-stat strong {
  display: block;
  margin-top: 1px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 800;
}

.map-stat span {
  display: block;
  color: var(--muted);
  font-size: 11px;
}

.day-cards {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.day-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 12px 34px rgba(24, 44, 41, 0.07);
}

.day-card summary {
  list-style: none;
  cursor: pointer;
}

.day-card summary::-webkit-details-marker {
  display: none;
}

.day-card-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
}

.day-theme {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.theme-icon {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex-shrink: 0;
  border-radius: var(--radius);
  background: rgba(15, 107, 91, 0.12);
  color: var(--green);
}

.day-index-badge {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--green), #17a091);
  color: #fff;
  font-size: 19px;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(15, 107, 91, 0.28);
}

.day-theme strong {
  display: block;
  font-size: 16px;
}

.day-theme span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.day-card-cost {
  margin-left: auto;
  flex-shrink: 0;
  text-align: right;
  color: var(--muted);
  font-size: 12px;
}

.day-card-cost strong {
  display: block;
  color: var(--ink);
  font-size: 20px;
}

.day-card-chevron {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  color: var(--muted);
  transition: transform 0.2s ease;
}

.day-card[open] .day-card-chevron {
  transform: rotate(180deg);
}

.day-card-body {
  padding: 6px 20px 20px;
  border-top: 1px solid var(--line);
}

.budget-options {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 0 4px;
}

.budget-options select {
  height: 34px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  outline: 0;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
}

.transport-estimate {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 14px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 24px 104px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-alt);
  transition: opacity 0.15s ease, outline 0.15s ease;
}

.timeline-item.dragging {
  opacity: 0.45;
}

.timeline-item.drag-over {
  outline: 2px dashed var(--green);
  outline-offset: 2px;
}

.timeline-item.is-fixed {
  background: color-mix(in srgb, var(--surface-alt) 60%, transparent);
  padding: 12px 14px;
}

.timeline-item.is-fixed .slot-meta {
  grid-column: 2;
}

.timeline-item.is-fixed .item-card {
  grid-column: 3;
  padding-top: 2px;
}

.timeline-item.is-fixed .item-meta-row {
  margin: 6px 0 4px;
}

.timeline-item.is-fixed .item-desc {
  margin-bottom: 0;
  font-size: 12.5px;
  line-height: 1.55;
}

.timeline-item.is-fixed .item-tags {
  display: none;
}

.drag-handle {
  align-self: center;
  display: grid;
  place-items: center;
  color: var(--muted);
  font-weight: 800;
  letter-spacing: 0;
  cursor: grab;
  user-select: none;
}

.slot-meta {
  position: relative;
  padding: 4px 0 0 14px;
}

.slot-meta::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
}

.slot-meta::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 18px;
  bottom: -12px;
  width: 2px;
  background: var(--line);
}

.timeline-item:last-child .slot-meta::after {
  display: none;
}

.slot-label {
  display: block;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 800;
}

.slot-time {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
}

.item-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.item-title {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.item-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: var(--radius);
  background: var(--soft-bg);
  color: var(--ink-soft);
}

.item-icon.cat-food {
  background: rgba(226, 96, 63, 0.14);
  color: var(--coral-deep);
}

.item-icon.cat-photo {
  background: rgba(74, 142, 166, 0.16);
  color: var(--sky);
}

.item-icon.cat-sight {
  background: rgba(15, 107, 91, 0.13);
  color: var(--green);
}

.item-icon.cat-walk {
  background: rgba(227, 167, 47, 0.16);
  color: var(--amber);
}

.item-icon.cat-transport {
  background: rgba(74, 142, 166, 0.14);
  color: var(--sky);
}

.item-icon.cat-stay {
  background: rgba(138, 111, 191, 0.14);
  color: #7a6aa8;
}

.item-title h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.item-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.item-cost {
  color: var(--coral-deep);
  font-size: 14px;
  font-weight: 800;
}

.item-copy,
.item-delete {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.item-copy:hover {
  border-color: var(--green);
  color: var(--green);
}

.item-delete:hover {
  border-color: var(--coral);
  color: var(--coral-deep);
}

.book-toggle {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.book-toggle input {
  width: 14px;
  height: 14px;
  accent-color: var(--green);
}

.item-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 10px 0 8px;
  color: var(--muted);
  font-size: 12px;
}

.item-type {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--soft-bg);
  color: var(--ink-soft);
  font-weight: 700;
}

.item-type.type-food {
  background: rgba(226, 96, 63, 0.14);
  color: var(--coral-deep);
}

.item-type.type-photo {
  background: rgba(74, 142, 166, 0.16);
  color: var(--sky);
}

.item-type.type-sight {
  background: rgba(15, 107, 91, 0.13);
  color: var(--green);
}

.item-type.type-walk {
  background: rgba(227, 167, 47, 0.16);
  color: var(--amber);
}

.item-type.type-transport {
  background: rgba(74, 142, 166, 0.14);
  color: var(--sky);
}

.item-type.type-stay {
  background: rgba(138, 111, 191, 0.14);
  color: #7a6aa8;
}

.item-desc {
  margin: 0 0 10px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.7;
}

.item-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.mini-tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  background: var(--soft-bg);
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
}

.day-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-top: 14px;
}

.add-item-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 15px;
  border: 1px dashed var(--green);
  border-radius: var(--radius);
  background: transparent;
  color: var(--green);
  font-size: 13px;
  font-weight: 700;
}

.add-item-btn:hover {
  background: rgba(15, 107, 91, 0.08);
}

.result-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.search-wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 1;
  max-width: 420px;
  height: 44px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.search-wrap input {
  flex: 1;
  min-width: 0;
  height: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
}

.search-wrap:focus-within {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(15, 107, 91, 0.14);
}

.search-results {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 30;
  max-height: 320px;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 16px 40px rgba(24, 44, 41, 0.16);
}

.search-result {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.search-result:hover {
  background: var(--soft-bg);
}

.search-result-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 9px;
  background: var(--soft-bg);
  color: var(--ink-soft);
}

.search-result-icon.cat-food {
  background: rgba(226, 96, 63, 0.14);
  color: var(--coral-deep);
}

.search-result-icon.cat-photo {
  background: rgba(74, 142, 166, 0.16);
  color: var(--sky);
}

.search-result-icon.cat-sight {
  background: rgba(15, 107, 91, 0.13);
  color: var(--green);
}

.search-result-icon.cat-walk {
  background: rgba(227, 167, 47, 0.16);
  color: var(--amber);
}

.search-result-main {
  flex: 1;
  min-width: 0;
}

.search-result-main strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-result-main span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}

.search-result-cost {
  flex-shrink: 0;
  color: var(--coral-deep);
  font-size: 12px;
  font-weight: 800;
}

.search-empty {
  margin: 0;
  padding: 14px 10px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.timeline-item.is-search-hit {
  outline: 2px solid var(--coral);
  outline-offset: 1px;
  box-shadow: 0 8px 22px rgba(226, 96, 63, 0.18);
}

.skeleton-wrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 14px;
}

.skeleton-card {
  height: 118px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--surface-alt) 25%, var(--soft-bg) 37%, var(--surface-alt) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.2s ease infinite;
}

@keyframes shimmer {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: -100% 0;
  }
}

.item-done {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--muted);
  transition: all 0.15s ease;
}

.item-done:hover {
  border-color: var(--green);
  color: var(--green);
}

.item-done svg.checked {
  display: none;
}

.item-done.is-checked {
  border-color: var(--green);
  background: var(--green);
  color: #fff;
}

.item-done.is-checked svg.checked {
  display: block;
}

.item-done.is-checked svg.unchecked {
  display: none;
}

.timeline-item.is-done {
  opacity: 0.55;
}

.timeline-item.is-done .item-title h3 {
  text-decoration: line-through;
}

.day-note {
  margin-top: 14px;
}

.day-note-label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.day-note textarea {
  width: 100%;
  min-height: 56px;
  padding: 10px 12px;
  resize: vertical;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  outline: 0;
  background: var(--surface-alt);
  color: var(--ink);
  font-size: 13px;
}

.day-note textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(15, 107, 91, 0.14);
}

.day-card-footer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.day-card-footer-actions .btn {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}

.copy-day-btn {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-soft);
}

.copy-day-btn:hover {
  border-color: var(--green);
  color: var(--green);
}

.back-top {
  position: fixed;
  right: 22px;
  bottom: 24px;
  z-index: 90;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--green);
  color: #fff;
  box-shadow: 0 10px 24px rgba(15, 107, 91, 0.35);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.back-top:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(15, 107, 91, 0.4);
}

.modal-small {
  width: min(460px, 100%);
}

.auth-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  background: var(--bg);
}

.auth-tab {
  min-height: 36px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.auth-tab.is-active {
  background: var(--surface);
  color: var(--coral-deep);
  box-shadow: 0 2px 8px rgba(24, 44, 41, 0.08);
}

.auth-body .field {
  margin: 0;
}

.auth-body .form-error {
  margin: -4px 0 0;
}

.auth-body .modal-actions .btn {
  width: 100%;
}

.adjust-body {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.adjust-hint {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 6px;
}

.site-footer {
  padding: 26px 0;
  margin-top: 80px;
  background: var(--green-deep);
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.footer-brand {
  color: #fff;
  font-weight: 800;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(16, 34, 32, 0.55);
  backdrop-filter: blur(4px);
}

.modal {
  width: min(600px, 100%);
  max-height: min(640px, calc(100vh - 40px));
  overflow: auto;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 30px 80px rgba(8, 30, 28, 0.35);
  animation: modalIn 0.22s ease;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.modal-head h2 {
  margin: 0;
  font-size: 22px;
  letter-spacing: 0;
}

.modal-head-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.modal-head-actions .btn {
  min-height: 36px;
  padding: 0 13px;
  font-size: 13px;
}

.modal-close {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
}

.modal-close:hover {
  color: var(--coral-deep);
  border-color: var(--coral);
}

.saved-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.saved-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-alt);
}

.saved-info {
  min-width: 0;
}

.saved-info strong {
  display: block;
  font-size: 15px;
}

.saved-info span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.saved-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.saved-actions button {
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 700;
}

.saved-actions button:first-child {
  border-color: var(--green);
  color: var(--green);
}

.saved-actions button:last-child:hover {
  border-color: var(--coral);
  color: var(--coral-deep);
}

.saved-empty {
  margin: 40px 0;
  color: var(--muted);
  text-align: center;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 200;
  transform: translateX(-50%);
  max-width: min(92vw, 480px);
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 12px 30px rgba(8, 30, 28, 0.3);
  animation: toastIn 0.25s ease;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translate(-50%, 10px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

@media (max-width: 960px) {
  .city-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .result-layout {
    grid-template-columns: 1fr;
  }

  .result-summary {
    position: static;
  }

  .empty-panel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .topbar {
    padding: 0 14px;
  }

  .brand-sub {
    display: none;
  }

  .nav-link {
    padding: 0 9px;
    font-size: 13px;
  }

  .nav-icon-btn {
    width: 36px;
  }

  .nav-link-primary {
    margin-left: 0;
  }

  .hero {
    min-height: 520px;
  }

  .hero-inner {
    width: calc(100% - 32px);
    padding: 76px 0 60px;
  }

  .hero h1 {
    font-size: 40px;
  }

  .hero-sub {
    font-size: 16px;
  }

  .planner-section,
  .destination-section,
  .how-section,
  .empty-section,
  .result-section {
    padding: 56px 0;
  }

  .container {
    width: calc(100% - 32px);
  }

  .section-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-head h2,
  .result-title-wrap h2,
  .empty-copy h2 {
    font-size: 28px;
  }

  .template-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .planner-card {
    padding: 20px;
  }

  .planner-grid {
    grid-template-columns: 1fr;
  }

  .field-destination,
  .field-notes {
    grid-column: auto;
  }

  .prefs-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .planner-footer {
    align-items: stretch;
    flex-direction: column-reverse;
  }

  .planner-actions {
    flex-direction: column;
  }

  .btn-generate,
  .planner-actions .btn {
    width: 100%;
  }

  .form-error {
    order: -1;
  }

  .city-grid {
    grid-template-columns: 1fr 1fr;
  }

  .how-grid {
    grid-template-columns: 1fr;
  }

  .example-grid {
    grid-template-columns: 1fr;
  }

  .result-head {
    flex-direction: column;
  }

  .result-actions {
    width: 100%;
  }

  .result-actions .btn {
    flex: 1;
  }

  .result-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .search-wrap {
    max-width: none;
  }

  .map-wrap {
    padding: 12px;
  }

  .map-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .map-day-tabs {
    width: 100%;
  }

  .map-body {
    grid-template-columns: 1fr;
  }

  .map-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }

  .map-stat {
    padding: 8px;
  }

  .map-stat strong {
    font-size: 13px;
  }

  .day-card-head {
    flex-wrap: wrap;
    padding: 14px;
  }

  .day-card-cost {
    margin-left: 58px;
    text-align: left;
  }

  .timeline-item {
    grid-template-columns: 20px 1fr;
    gap: 8px 10px;
  }

  .slot-meta {
    grid-column: 2;
  }

  .item-card {
    grid-column: 2;
  }

  .timeline-item.is-fixed .slot-meta,
  .timeline-item.is-fixed .item-card {
    grid-column: 2;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 460px) {
  .city-grid {
    grid-template-columns: 1fr;
  }

  .nav-link {
    font-size: 12px;
    padding: 0 7px;
  }

  .saved-item {
    align-items: flex-start;
    flex-direction: column;
  }
}
