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

/* Screen-reader only - visually hidden but crawlable for SEO */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:root {
  --bg-color: #0a0a0f;
  --text-color: #ffffff;
  --accent-color: #00ff00;
  --accent-glow: rgba(0, 255, 0, 0.5);
  --muted-color: #888888;
  --font-mono: 'IBM Plex Mono', monospace;
  --font-pixel: 'Pixelify Sans', sans-serif;
}

html {
  font-size: 16px !important; /* Override parent site's font-size */
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: var(--font-mono);
}

#app {
  width: 100%;
  height: 100%;
  position: relative;
}

/* Header */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2.5rem;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  background: transparent;
  pointer-events: none;
}

.header * {
  pointer-events: auto;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo {
  font-family: var(--font-pixel);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.logo:hover {
  color: var(--accent-color);
}

.year-badge {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.25rem 0.75rem;
  border: 1px solid var(--accent-color);
  color: var(--accent-color);
  border-radius: 2px;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.read-about {
  font-size: 0.875rem;
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.read-about:hover {
  color: var(--accent-color);
}

.btn-unlock {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.625rem 1.25rem;
  background: transparent;
  border: 1px solid var(--text-color);
  color: var(--text-color);
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-unlock:hover {
  background: var(--accent-color);
  border-color: var(--accent-color);
  color: var(--bg-color);
}

/* Main Content */
.main-content {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  overflow: hidden;
}

/* Stats Panel */
.stats-panel {
  position: absolute;
  left: 2.5rem;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--muted-color);
  text-transform: capitalize;
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 600;
  color: var(--text-color);
  font-variant-numeric: tabular-nums;
}

.stat-item:first-of-type .stat-label {
  font-size: 1rem; /* 0.75rem + 4px */
}

.stat-item:first-of-type .stat-value {
  font-size: 2.75rem; /* 2.5rem + 4px */
}

/* Globe Glow - now handled by WebGL shaders */
#globe-glow {
  display: none; /* Atmosphere glow is now rendered in WebGL */
}

/* Globe Container */
#globe-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

#globe-container canvas {
  width: 100% !important;
  height: 100% !important;
}

/* Footer */
.footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2.5rem;
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 10;
  background: linear-gradient(to top, rgba(10, 10, 15, 0.95) 0%, rgba(10, 10, 15, 0.8) 50%, transparent 100%);
  padding-top: 2rem;
}

/* Ticker */
.ticker-wrapper {
  flex: 1;
  overflow: hidden;
  margin-right: 2rem;
}

.ticker {
  display: flex;
  gap: 2rem;
  animation: none; /* Set by JavaScript */
  white-space: nowrap;
  will-change: transform;
}

.ticker-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
  font-size: 0.875rem;
}

.ticker-name {
  color: var(--accent-color);
}

.ticker-country {
  color: var(--muted-color);
}

/* Ticker keyframes are generated dynamically in JavaScript
   with exact pixel values for seamless looping */

/* Social Icons */
.social-icons {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.social-icons a {
  color: var(--muted-color);
  transition: color 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.social-icons a:hover {
  color: var(--text-color);
}

/* Responsive */
@media (max-width: 1024px) {
  .stats-panel {
    left: 1.5rem;
  }

  .stat-value {
    font-size: 2rem;
  }

  .stat-item:first-of-type .stat-value {
    font-size: 2.25rem; /* 2rem + 4px */
  }
}

@media (max-width: 768px) {
  .header {
    padding: 1rem 1.5rem;
  }

  .header-right {
    gap: 1rem;
  }

  .read-about {
    display: none;
  }

  .stats-panel {
    left: 1rem;
    gap: 1rem;
  }

  .stat-label {
    font-size: 0.625rem;
  }

  .stat-value {
    font-size: 1.5rem;
  }

  .stat-item:first-of-type .stat-label {
    font-size: 0.875rem; /* 0.625rem + 4px */
  }

  .stat-item:first-of-type .stat-value {
    font-size: 1.75rem; /* 1.5rem + 4px */
  }

  .footer {
    padding: 1rem 1.5rem;
  }
}

/* Meetup Modal - Polaroid Style */
.meetup-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 300ms ease-out, visibility 300ms ease-out;
  pointer-events: none;
}

.meetup-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.meetup-modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: transparent;
}

/* Polaroid card */
.meetup-modal-content {
  position: relative;
  background: #fefefe;
  max-width: 320px;
  width: calc(100% - 48px);
  padding: 12px 12px 52px 12px;
  box-shadow:
    0 4px 6px rgba(0, 0, 0, 0.1),
    0 20px 40px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 255, 255, 0.1);
  transform: scale(0.8) rotate(-2deg);
  transition: transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.meetup-modal.active .meetup-modal-content {
  transform: scale(1) rotate(1deg);
}

.meetup-modal-close {
  position: absolute;
  top: -10px;
  right: -10px;
  z-index: 10;
  width: 26px;
  height: 26px;
  border: none;
  background: #1a1a1a;
  color: #ffffff;
  font-size: 16px;
  line-height: 1;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 150ms ease, background 150ms ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.meetup-modal-close:hover {
  background: #333;
  transform: scale(1.1);
}

/* Photo area */
.meetup-carousel {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #f0f0f0;
}

.meetup-slides {
  width: 100%;
  height: 100%;
  position: relative;
}

.meetup-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 300ms ease;
}

.meetup-slide.active {
  opacity: 1;
}

.meetup-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Navigation arrows */
.meetup-prev,
.meetup-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 30px;
  height: 30px;
  border: none;
  background: rgba(0, 0, 0, 0.5);
  color: #ffffff;
  font-size: 16px;
  line-height: 1;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 150ms ease, background 150ms ease;
}

.meetup-carousel:hover .meetup-prev,
.meetup-carousel:hover .meetup-next {
  opacity: 1;
}

.meetup-prev:hover,
.meetup-next:hover {
  background: rgba(0, 0, 0, 0.7);
}

.meetup-prev {
  left: 8px;
}

.meetup-next {
  right: 8px;
}

/* Footer with city name and dots */
.meetup-footer {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px 12px 12px 12px;
  text-align: center;
}

.meetup-city {
  font-family: var(--font-pixel), var(--font-mono), sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: #1a1a1a;
  margin: 0 0 6px 0;
  letter-spacing: 0.3px;
}

.meetup-dots {
  display: flex;
  justify-content: center;
  gap: 5px;
}

.meetup-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  border: none;
  background: #ccc;
  cursor: pointer;
  padding: 0;
  transition: background 150ms ease, transform 150ms ease;
}

.meetup-dot:hover {
  background: #999;
}

.meetup-dot.active {
  background: #1a1a1a;
  transform: scale(1.3);
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .meetup-modal-content {
    max-width: 280px;
    width: calc(100% - 40px);
    padding: 10px 10px 48px 10px;
  }

  .meetup-prev,
  .meetup-next {
    opacity: 1;
    width: 26px;
    height: 26px;
    font-size: 14px;
  }

  .meetup-city {
    font-size: 14px;
  }
}
