/* ==========================================================================
   竹苗露營包區整合網 - 極簡露營風樣式表 (Modern Outdoor Minimalist)
   Palette:
     - 森林深綠 Forest Green: #2D4F3E
     - 森林濃綠 Deep Forest: #1E372B
     - 暖沙大地 Sand Base:   #F4F1EA
     - 暖沙深質 Sand Dark:   #EAE4D6
     - 營火暖橘 Campfire:    #D97736
     - 營火焰橘 Campfire Hi: #C26223
     - 晨霧純白 Pure White:  #FFFFFF
   ========================================================================== */

:root {
  --forest: #2D4F3E;
  --forest-dark: #1E372B;
  --forest-light: #3E6B55;
  --forest-subtle: #EDF3F0;
  --sand: #F4F1EA;
  --sand-dark: #E7E1D2;
  --sand-border: #DCD5C3;
  --campfire: #D97736;
  --campfire-hover: #BF6223;
  --campfire-light: #FAEDE4;
  --card-bg: #FFFFFF;
  --text-primary: #1F2937;
  --text-secondary: #4B5563;
  --text-muted: #6B7280;
}

/* 基礎設定 */
html {
  scroll-behavior: smooth;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  background-color: var(--sand);
  color: var(--text-primary);
}

body {
  min-height: 100vh;
  background-color: var(--sand);
  background-image: radial-gradient(#E5DFCF 1px, transparent 1px);
  background-size: 24px 24px;
}

/* 特製自訂捲軸 */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--sand);
}
::-webkit-scrollbar-thumb {
  background: #C8BFAB;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #A99E86;
}

/* 森林深綠主題色彩類別 */
.bg-forest {
  background-color: var(--forest);
}
.bg-forest-dark {
  background-color: var(--forest-dark);
}
.bg-forest-light {
  background-color: var(--forest-light);
}
.bg-forest-subtle {
  background-color: var(--forest-subtle);
}
.text-forest {
  color: var(--forest);
}
.border-forest {
  border-color: var(--forest);
}

/* 暖沙大地主題色彩類別 */
.bg-sand {
  background-color: var(--sand);
}
.bg-sand-dark {
  background-color: var(--sand-dark);
}
.border-sand {
  border-color: var(--sand-border);
}

/* 營火暖橘主題色彩類別 */
.bg-campfire {
  background-color: var(--campfire);
}
.bg-campfire:hover {
  background-color: var(--campfire-hover);
}
.text-campfire {
  color: var(--campfire);
}
.border-campfire {
  border-color: var(--campfire);
}
.bg-campfire-light {
  background-color: var(--campfire-light);
}

/* 卡片外觀與質感 */
.camp-card {
  background-color: var(--card-bg);
  border: 1px solid #E5E0D5;
  border-radius: 1rem;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
}
.camp-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(45, 79, 62, 0.1), 0 8px 10px -6px rgba(45, 79, 62, 0.05);
  border-color: #CBD5CE;
}

/* 切換開關 Toggle Checkbox */
.switch-checkbox:checked {
  right: 0;
  background-color: var(--forest);
}
.switch-checkbox:checked + .switch-label {
  background-color: var(--forest);
}

/* 膠囊 Badge 樣式 */
.badge-icamping {
  background-color: #2D4F3E;
  color: #FFFFFF;
}
.badge-easycamp {
  background-color: #1565C0;
  color: #FFFFFF;
}

/* 車程數據膠囊 */
.drive-time-tag {
  background-color: #F8F7F3;
  border: 1px solid #E6E1D3;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
}

/* 互動反饋按鈕動態 */
.btn-active-scale {
  transition: all 0.15s ease-in-out;
}
.btn-active-scale:active {
  transform: scale(0.97);
}

/* 旋轉動畫 */
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
.animate-spin-custom {
  animation: spin 0.85s linear infinite;
}

/* Toast 提示浮窗動態 */
@keyframes toastSlideIn {
  from {
    opacity: 0;
    transform: translate(-50%, 20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}
@keyframes toastSlideOut {
  from {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
  to {
    opacity: 0;
    transform: translate(-50%, 15px) scale(0.95);
  }
}

.toast-container {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  pointer-events: none;
}

.toast-item {
  animation: toastSlideIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  pointer-events: auto;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}
.toast-item.closing {
  animation: toastSlideOut 0.25s ease-in forwards;
}

/* 出發地設定 Modal 動態 */
.modal-backdrop {
  backdrop-filter: blur(4px);
  background-color: rgba(30, 55, 43, 0.45);
}
.modal-content {
  animation: modalEnter 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes modalEnter {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* 滿區與可包標記 */
.zone-pill-available {
  background-color: #E8F5E9;
  color: #1B5E20;
  border: 1px solid #C8E6C9;
}
.zone-pill-partial {
  background-color: #FEECEB;
  color: #B71C1C;
  border: 1px solid #FFCDD2;
}
.zone-pill-canopy {
  background-color: #E3F2FD;
  color: #0D47A1;
  border: 1px solid #BBDEFB;
}
