/* ==========================================================================
   Trail Explorer - Core Variables, Typography & Utility Resets
   ========================================================================== */
:root {
  --primary: #ea580c;
  --primary-hover: #c2410c;
  --primary-light: #fff7ed;
  --primary-subtle: #ffedd5;
  --transit: #6366f1;
  --transit-dark: #4338ca;
  --walk: #10b981;
  --accent: #0284c7;
  --bg-surface: rgba(255, 255, 255, 0.96);
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  height: 100%;
  width: 100%;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  color: var(--text-main);
  background-color: #0f172a;
}

#appRoot {
  display: flex;
  height: 100%;
  width: 100%;
  position: relative;
  overflow: hidden;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  outline: none;
}

input, select {
  font-family: inherit;
  outline: none;
}

/* ==========================================================================
   Drag & Drop Full-Window Overlay & GPX Import Modal
   ========================================================================== */
#windowDragOverlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  width: 100%;
  height: 100%;
  height: 100dvh;
  background: rgba(15, 23, 42, 0.88);
  backdrop-filter: blur(14px);
  z-index: 12000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

#windowDragOverlay.active {
  opacity: 1;
  visibility: visible;
  pointer-events: all;
}

#windowDragOverlay * {
  pointer-events: none;
}

.drag-drop-box {
  border: 3px dashed var(--primary);
  background: rgba(234, 88, 12, 0.08);
  border-radius: 24px;
  padding: 48px 36px;
  max-width: 500px;
  width: 90%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  transform: scale(0.92);
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 25px 50px -12px rgba(234, 88, 12, 0.35);
}

#windowDragOverlay.active .drag-drop-box {
  transform: scale(1);
}

.drag-drop-icon {
  font-size: 3.5rem;
  line-height: 1;
  animation: bounceDrop 1.5s infinite ease-in-out;
}

@keyframes bounceDrop {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.drag-drop-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: #ffffff;
}

.drag-drop-sub {
  font-size: 0.85rem;
  color: #cbd5e1;
}

/* Sidebar + Import Button */
.btn-import-gpx-sidebar {
  background: #eff6ff;
  border: 1px solid #93c5fd;
  color: #1d4ed8;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s;
}

.btn-import-gpx-sidebar:hover {
  background: #dbeafe;
  border-color: #3b82f6;
  color: #1e40af;
  transform: scale(1.04);
}

/* Import GPX Modal */
.gpx-modal-preview-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 12px;
  text-align: center;
}

.gpx-preview-val {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fed7aa;
}

.gpx-preview-lbl {
  font-size: 0.68rem;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  margin-top: 2px;
}
