/* BaliMap — Shared styles for location pages */
:root {
  --color-primary: #667eea;
  --color-primary-dark: #764ba2;
  --color-bg-dark: #1e293b;
  --color-bg-light: #f9fafb;
  --color-bg-page: #f8fafc;
  --color-border: #e5e7eb;
  --color-text: #1e293b;
  --color-text-muted: #64748b;
  --color-text-light: #94a3b8;
  --gradient-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: var(--color-bg-page);
  color: var(--color-text);
}
.page-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
header {
  background: var(--gradient-primary);
  color: white;
  padding: 1.5rem 2rem;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}
header h1 {
  margin: 0 0 0.5rem 0;
  font-size: 1.75rem;
  font-weight: 700;
}
header p {
  margin: 0;
  opacity: 0.9;
  font-size: 1rem;
}
.breadcrumb {
  padding: 1rem 2rem;
  background: white;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.875rem;
}
.breadcrumb a {
  color: var(--color-primary);
  text-decoration: none;
}
.breadcrumb a:hover {
  text-decoration: underline;
}
.breadcrumb span {
  color: var(--color-text-muted);
  margin: 0 0.5rem;
}
.content-wrapper {
  display: flex;
  flex: 1;
  flex-direction: column;
}
@media (min-width: 768px) {
  .content-wrapper {
    flex-direction: row;
  }
}
.map-container {
  flex: 1;
  min-height: 400px;
}
#map {
  height: 100%;
  width: 100%;
  min-height: 400px;
}
.info-panel {
  width: 100%;
  padding: 2rem;
  background: white;
  overflow-y: auto;
}
@media (min-width: 768px) {
  .info-panel {
    width: 400px;
    max-height: calc(100vh - 200px);
  }
}
.info-panel h2 {
  margin: 0 0 1rem 0;
  font-size: 1.25rem;
  color: #334155;
}
.info-panel p {
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: 1rem;
}
.attractions-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}
.attractions-list li {
  padding: 1rem;
  background: var(--color-bg-page);
  border-radius: 8px;
  margin-bottom: 0.75rem;
  border-left: 4px solid var(--color-primary);
}
.attractions-list li strong {
  display: block;
  color: #334155;
  margin-bottom: 0.25rem;
}
.attractions-list li span {
  font-size: 0.875rem;
  color: var(--color-text-muted);
}
.cta-button {
  display: inline-block;
  background: var(--gradient-primary);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
}
.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}
footer {
  background: var(--color-bg-dark);
  color: var(--color-text-light);
  padding: 2rem;
  text-align: center;
}
footer a {
  color: var(--color-primary);
  text-decoration: none;
}
footer a:hover {
  text-decoration: underline;
}
.location-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-top: 1rem;
}
.location-links a {
  background: #334155;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.875rem;
  transition: background 0.2s;
}
.location-links a:hover {
  background: #475569;
}

/* Custom marker styling */
.custom-marker-wrapper {
  background: transparent !important;
  border: none !important;
}
.custom-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 3px solid white;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3), 0 2px 4px rgba(0,0,0,0.2);
  transition: all 0.2s ease;
  cursor: pointer;
}
.custom-marker:hover {
  transform: scale(1.2);
  box-shadow: 0 6px 20px rgba(0,0,0,0.4);
}
.custom-marker .marker-icon {
  font-size: 14px;
}
.leaflet-popup-content-wrapper {
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.2);
}

/* Skip navigation */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--color-primary);
  color: white;
  padding: 8px 16px;
  z-index: 10000;
  transition: top 0.2s;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}
.skip-link:focus {
  top: 0;
}

/* Keyboard focus indicators */
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}
:focus:not(:focus-visible) {
  outline: none;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
