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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #0d1117;
  color: #e6edf3;
  min-height: 100vh;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: #161b22;
  border-bottom: 1px solid #30363d;
  flex-wrap: wrap;
  gap: 0.75rem;
}

header h1 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #e6edf3;
}

.filters {
  display: flex;
  gap: 0.5rem;
}

select {
  background: #21262d;
  color: #e6edf3;
  border: 1px solid #30363d;
  border-radius: 6px;
  padding: 0.4rem 0.75rem;
  font-size: 0.875rem;
  cursor: pointer;
}

select:hover {
  border-color: #58a6ff;
}

main {
  padding: 1.5rem;
}

.date-group {
  margin-bottom: 2rem;
}

.date-heading {
  font-size: 1rem;
  font-weight: 600;
  color: #8b949e;
  margin-bottom: 0.75rem;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid #21262d;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.card {
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 8px;
  padding: 1rem;
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s;
}

.card:hover {
  border-color: #58a6ff;
  transform: translateY(-1px);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.card-camera {
  font-weight: 600;
  font-size: 0.95rem;
}

.badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.badge-sunrise {
  background: #f0883e22;
  color: #f0883e;
}

.badge-full_day {
  background: #58a6ff22;
  color: #58a6ff;
}

.badge-overnight {
  background: #bc8cff22;
  color: #bc8cff;
}

.card-meta {
  color: #8b949e;
  font-size: 0.8rem;
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

/* Empty state */
.empty {
  text-align: center;
  color: #8b949e;
  padding: 4rem 1rem;
  font-size: 1.1rem;
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal.hidden {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
}

.modal-content {
  position: relative;
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 12px;
  padding: 1rem;
  max-width: 90vw;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.modal-close {
  position: absolute;
  top: 0.5rem;
  right: 0.75rem;
  background: none;
  border: none;
  color: #8b949e;
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 1;
}

.modal-close:hover {
  color: #e6edf3;
}

video {
  width: 100%;
  max-height: 75vh;
  border-radius: 8px;
  background: #000;
}

#modal-info {
  color: #8b949e;
  font-size: 0.875rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

#modal-info span {
  color: #e6edf3;
}
