:root {
  color-scheme: light;
  --orange-1: #000;
  --orange-2: #ff5c2b;
  --text-main: #1f2937;
  --text-sub: #6b7280;
  --glass-bg: rgba(255, 255, 255, 0.82);
  --glass-border: rgba(255, 255, 255, 0.6);
  --shadow-lg: 0 24px 60px rgba(15, 23, 42, 0.18);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #CF3720;
  color: var(--text-main);
}

button {
  font: inherit;
  border: none;
  outline: none;
}

.hidden {
  display: none !important;
}

.page-shell {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: linear-gradient(180deg, #fff2ea 0%, #f8fafc 100%);
}

.page-header {
  position: absolute;
  top: max(16px, env(safe-area-inset-top));
  left: 16px;
  z-index: 100;
  display: flex;
  align-items: center;
  height: 44px;
}

.page-header .page-title {
  font-size: 18px;
  font-weight: 600;
  color: #1f2937;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

.map-container {
  position: absolute;
  inset: 0;
  top: 0;
}

.overlay-stage {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}


.scenic-overlay {
  position: absolute;
  transform-origin: top left;
  pointer-events: none;
}

.scenic-overlay__shape {
  position: absolute;
  inset: 0;
  overflow: hidden;
  clip-path: var(--region-clip);
  border: 3px solid var(--region-accent);
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.22);
  background: rgba(15, 23, 42, 0.16);
}

.scenic-overlay.is-plain .scenic-overlay__shape {
  overflow: visible;
  clip-path: none;
  border: none !important;
  box-shadow: none !important;
  background: transparent !important;
}

.scenic-overlay.is-plain .scenic-overlay__image {
  opacity: 1 !important;
  mix-blend-mode: normal !important;
}

.scenic-overlay.is-plain .scenic-overlay__sheen {
  display: none !important;
}

.scenic-overlay__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: var(--region-object-fit, cover);
  object-position: var(--region-object-position, center center);
  opacity: var(--region-opacity, 0.9);
  mix-blend-mode: var(--region-blend-mode, multiply);
  filter: saturate(1.08) contrast(1.06);
}


.scenic-overlay.is-plain .scenic-overlay__image {
  filter: none;
}


.scenic-overlay__sheen {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0.04) 40%, rgba(17, 24, 39, 0.16) 100%);
}

.scenic-overlay__label {
  position: absolute;
  left: 12px;
  bottom: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: #fff;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 10px 20px rgba(15, 23, 42, 0.18);
}

.glass-panel {
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-lg);
}

.topbar {
  position: absolute;
  top: max(16px, env(safe-area-inset-top));
  left: 16px;
  right: 16px;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  border-radius: 22px;
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: rgba(31, 41, 55, 0.56);
}

.page-title {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.ghost-button,
.primary-button,
.fab {
  cursor: pointer;
}

.ghost-button {
  flex-shrink: 0;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
}

.route-badge {
  position: absolute;
  top: calc(max(16px, env(safe-area-inset-top)) + 98px);
  left: 16px;
  z-index: 19;
  max-width: calc(100% - 32px);
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(31, 41, 55, 0.72);
  color: #fff;
  font-size: 13px;
  line-height: 1.4;
}

.status-card {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: calc(20px + env(safe-area-inset-bottom));
  z-index: 18;
  padding: 14px 16px;
  border-radius: 22px;
}

.status-card.is-success {
  border-color: rgba(34, 197, 94, 0.24);
}

.status-card.is-warn {
  border-color: rgba(245, 158, 11, 0.24);
}

.status-card.is-error {
  border-color: rgba(239, 68, 68, 0.24);
}

.status-title {
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 700;
}

.status-text {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-sub);
}

.floating-actions {
  position: absolute;
  right: 16px;
  bottom: calc(120px + env(safe-area-inset-bottom));
  z-index: 19;
}

.fab {
  padding: 14px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--orange-1) 0%, var(--orange-2) 100%);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 18px 32px rgba(253, 124, 63, 0.28);
}

.spot-card {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: calc(120px + env(safe-area-inset-bottom));
  z-index: 21;
  overflow: hidden;
  border-radius: 26px;
}

.close-button {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(17, 24, 39, 0.4);
  color: #fff;
  font-size: 22px;
  line-height: 1;
}

.spot-image {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: cover;
  background: linear-gradient(135deg, #ffe1cf 0%, #ffc6a8 100%);
}

.spot-content {
  padding: 18px;
}

.spot-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.spot-title {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
}

.spot-location {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--text-sub);
}

.spot-tag {
  flex-shrink: 0;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(253, 124, 63, 0.12);
  color: var(--orange-2);
  font-size: 12px;
  font-weight: 700;
}

.spot-film {
  margin: 14px 0 18px;
  font-size: 14px;
  line-height: 1.6;
  color: #374151;
}

.primary-button {
  width: 100%;
  padding: 14px 18px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--orange-1) 0%, var(--orange-2) 100%);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}

.loading-mask {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(248, 250, 252, 0.32);
}

.loading-card {
  width: min(280px, calc(100% - 48px));
  padding: 28px 22px;
  border-radius: 24px;
  text-align: center;
}

.spinner {
  width: 44px;
  height: 44px;
  margin: 0 auto 14px;
  border-radius: 50%;
  border: 4px solid rgba(253, 124, 63, 0.18);
  border-top-color: var(--orange-2);
  animation: spin 0.9s linear infinite;
}

#loadingText {
  margin: 0;
  color: var(--text-sub);
  font-size: 14px;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (min-width: 768px) {
  .topbar,
  .status-card,
  .spot-card {
    left: 24px;
    right: 24px;
  }

  .route-badge {
    left: 24px;
  }

  .floating-actions {
    right: 24px;
  }
}
