:root {
  --bg-dark: #070b14;
  --bg-panel: #0f172a;
  --bg-card: #162036;
  --bg-card-hover: #1e293b;
  --border-color: rgba(148, 163, 184, 0.16);
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --vice-pink: #ec4899;
  --vice-cyan: #06b6d4;
  --vice-amber: #f59e0b;
  --vice-emerald: #10b981;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Top Global Navigation Bar */
.site-header {
  height: 58px;
  background: rgba(11, 17, 32, 0.95);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  position: sticky;
  top: 0;
  z-index: 1200;
  backdrop-filter: blur(12px);
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.brand-badge {
  background: linear-gradient(135deg, var(--vice-pink), #8b5cf6);
  color: #fff;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 7px 13px;
  border-radius: 8px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
  background: rgba(236, 72, 153, 0.14);
}

.daily-timer-pill {
  background: rgba(245, 158, 11, 0.14);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Interactive Map Workspace (Above the Fold) */
.map-workspace {
  display: grid;
  grid-template-columns: 360px 1fr;
  height: calc(100vh - 58px);
  min-height: 640px;
  max-height: 920px;
  border-bottom: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.map-sidebar {
  background: var(--bg-panel);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  z-index: 600;
}

.sidebar-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid var(--border-color);
  background: #0a101f;
}

.sidebar-tab-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  padding: 11px 4px;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all 0.15s;
}

.sidebar-tab-btn:hover {
  color: #fff;
}

.sidebar-tab-btn.active {
  color: var(--vice-pink);
  border-bottom-color: var(--vice-pink);
  background: rgba(236, 72, 153, 0.07);
}

.sidebar-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* Search & Progress Bar */
.search-box {
  position: relative;
  margin-bottom: 12px;
}

.search-input {
  width: 100%;
  background: #090e1a;
  border: 1px solid var(--border-color);
  color: #fff;
  padding: 10px 12px 10px 34px;
  border-radius: 8px;
  font-size: 0.85rem;
}

.search-input:focus {
  outline: none;
  border-color: var(--vice-pink);
}

.search-icon {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.85rem;
}

.progress-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 11px 13px;
  margin-bottom: 14px;
}

.progress-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.progress-track {
  height: 7px;
  background: #090e1a;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--vice-pink), var(--vice-cyan));
  width: 0%;
  transition: width 0.25s ease;
}

/* Filter Pill Buttons */
.filter-actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.section-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  font-weight: 800;
}

.mini-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 3px 8px;
  border-radius: 5px;
  font-size: 0.72rem;
  cursor: pointer;
}

.mini-btn:hover {
  border-color: var(--vice-cyan);
}

.category-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-bottom: 14px;
}

.cat-filter-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}

.cat-filter-btn.muted {
  opacity: 0.4;
  background: #090e1a;
}

.cat-count {
  background: rgba(255, 255, 255, 0.08);
  padding: 1px 6px;
  border-radius: 99px;
  font-size: 0.7rem;
  color: var(--text-muted);
}

/* Region Quick Jump */
.region-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.region-pill {
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: #67e8f9;
  padding: 4px 9px;
  border-radius: 6px;
  font-size: 0.73rem;
  font-weight: 600;
  cursor: pointer;
}

.region-pill:hover {
  background: rgba(6, 182, 212, 0.22);
}

/* Marker List in Sidebar */
.marker-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.marker-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 9px 11px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.marker-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--vice-pink);
}

.marker-item.completed {
  opacity: 0.55;
  border-color: rgba(16, 185, 129, 0.4);
}

.marker-item-title {
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.marker-item-meta {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* Map Canvas Area */
.map-canvas-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  background: #050b14;
}

#leonida-map {
  width: 100%;
  height: 100%;
  background: #050b14;
}

.map-floating-bar {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 500;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.map-tool-pill {
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.map-tool-pill:hover,
.map-tool-pill.active {
  border-color: var(--vice-cyan);
  color: #67e8f9;
}

/* Custom Leaflet Pin Icon */
.custom-map-pin {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #0f172a;
  border: 2px solid var(--pin-color, #ec4899);
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.75);
  font-size: 15px;
  transition: transform 0.15s ease;
}

.custom-map-pin:hover {
  transform: scale(1.2);
  z-index: 900 !important;
}

.custom-map-pin.is-found {
  opacity: 0.48;
  filter: grayscale(60%);
}

/* Slide-Over Detail Drawer */
.location-drawer {
  position: absolute;
  top: 0;
  right: 0;
  width: 390px;
  max-width: 92vw;
  height: 100%;
  background: rgba(15, 23, 42, 0.97);
  border-left: 1px solid var(--border-color);
  z-index: 800;
  transform: translateX(102%);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(16px);
}

.location-drawer.open {
  transform: translateX(0);
}

.drawer-header {
  padding: 16px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.drawer-body {
  padding: 16px;
  overflow-y: auto;
  flex: 1;
}

.drawer-close {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #fff;
  width: 30px;
  height: 30px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 1rem;
}

.cta-btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  background: linear-gradient(135deg, var(--vice-pink), #8b5cf6);
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 11px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  margin-top: 12px;
  text-align: center;
}

.cta-btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  margin-top: 8px;
}

/* Google AdSense Slot Containers */
.ad-slot-box {
  background: rgba(9, 14, 26, 0.85);
  border: 1px dashed rgba(148, 163, 184, 0.25);
  border-radius: 10px;
  padding: 10px;
  text-align: center;
  margin: 14px 0;
  min-height: 90px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.ad-slot-label {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #64748b;
  margin-bottom: 4px;
}

/* Below-the-Fold SEO Content Hub & Inner Pages */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 44px 20px;
}

.section-header {
  margin-bottom: 24px;
}

.section-title {
  font-size: 1.65rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.cards-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 18px;
}

.seo-card {
  background: var(--bg-panel);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 20px;
  transition: transform 0.15s ease, border-color 0.15s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.seo-card:hover {
  transform: translateY(-2px);
  border-color: var(--vice-pink);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(236, 72, 153, 0.15);
  color: #f472b6;
}

/* Article / Location Guide Page Layout */
.guide-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 32px;
}

.guide-article {
  background: var(--bg-panel);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 32px;
}

.guide-article h1 {
  font-size: 2rem;
  font-weight: 900;
  line-height: 1.25;
  margin: 12px 0 16px;
}

.guide-article h2 {
  font-size: 1.3rem;
  font-weight: 800;
  margin: 28px 0 12px;
  color: #f8fafc;
  border-left: 3px solid var(--vice-pink);
  padding-left: 12px;
}

.guide-article p {
  color: #cbd5e1;
  margin-bottom: 16px;
  font-size: 1rem;
}

.steps-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 16px 0 24px;
}

.steps-list li {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 14px 16px;
  border-radius: 10px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.step-num {
  background: var(--vice-pink);
  color: #fff;
  font-weight: 800;
  font-size: 0.78rem;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.meta-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
}

.meta-table th,
.meta-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
  font-size: 0.88rem;
}

.meta-table th {
  color: var(--text-muted);
  width: 38%;
}

.site-footer {
  background: #050811;
  border-top: 1px solid var(--border-color);
  padding: 40px 20px;
  margin-top: 60px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

@media (max-width: 960px) {
  .map-workspace {
    grid-template-columns: 1fr;
    grid-template-rows: 52vh 48vh;
    height: auto;
    max-height: none;
  }
  .map-sidebar {
    order: 2;
  }
  .map-canvas-wrap {
    order: 1;
    height: 52vh;
  }
  .guide-layout {
    grid-template-columns: 1fr;
  }
  .daily-timer-pill {
    display: none;
  }
}
