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

body {
  font-family: Arial, sans-serif;
  background: linear-gradient(to bottom, #081120, #0f172a);
  color: white;
  padding: 20px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 20px;
  padding-bottom: 20px;
  margin-bottom: 20px;
}

h1 {
  font-family: Verdana, sans-serif;
  font-weight: bold;
  color: #ffffff;
}

.logo {
  width: 140px;
  margin-right: 15px;
}

.filters {
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
  margin-bottom: 20px;
  padding: 0 20px;
}

input[type="date"],
button {
  font-family: Arial, sans-serif;
  padding: 10px 15px;
  border: 1px solid #2f3b52;
  border-radius: 6px;
  font-size: 16px;
  line-height: 1.4;
  width: 100%;
}

input[type="date"] {
  background-color: #1f2937;
  color: white;
}

button {
  background-color: #fc3d21;
  color: white;
  cursor: pointer;
  border: none;
  font-weight: bold;
}

button:hover {
  background-color: #d9341c;
}

@media (min-width: 600px) {
  .filters {
    flex-direction: row;
    padding: 0;
  }

  input[type="date"],
  button {
    width: auto;
  }
}

.space-fact {
  background: rgba(255, 255, 255, 0.08);
  border-left: 4px solid #fc3d21;
  padding: 14px 18px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 15px;
}

.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  padding: 20px 0;
  justify-content: center;
}

.gallery-item {
  flex: 1 1 100%;
  min-width: 280px;
  max-width: 500px;
  background: #f3f4f6;
  color: #111827;
  padding: 14px;
  border-radius: 14px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.gallery-item:hover {
  transform: scale(1.03);
}

@media (min-width: 1000px) {
  .gallery-item {
    flex: 0 1 31%;
  }
}

.gallery-item img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: 8px;
}

.gallery-item p {
  margin-top: 10px;
  padding: 3px 5px;
  font-size: 14px;
}

.video-card {
  height: 220px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: #e5e7eb;
  border-radius: 8px;
  text-align: center;
  padding: 20px;
}

.video-btn {
  display: inline-block;
  margin-top: 10px;
  padding: 10px 16px;
  background-color: #fc3d21;
  color: white;
  border-radius: 6px;
  text-decoration: none;
  font-weight: bold;
}

.video-btn:hover {
  background-color: #d9341c;
}

.placeholder {
  flex: 1 1 100%;
  text-align: center;
  padding: 40px;
  color: #d1d5db;
}

.placeholder-icon {
  font-size: 48px;
  margin-bottom: 20px;
}

.message {
  text-align: center;
  font-size: 18px;
  padding: 30px;
  width: 100%;
}

.error {
  color: #ffb4b4;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.82);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
  z-index: 999;
}

.hidden {
  display: none;
}

.modal-content {
  background: white;
  color: #111827;
  max-width: 850px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 12px;
  padding: 20px;
  position: relative;
}

.close-btn {
  position: absolute;
  top: 14px;
  right: 18px;
  font-size: 28px;
  cursor: pointer;
  font-weight: bold;
}

.modal-image {
  width: 100%;
  margin: 15px 0;
  border-radius: 8px;
}

.modal-explanation {
  margin-top: 10px;
  line-height: 1.6;
}

.modal-video-link {
  margin: 15px 0;
}

.video-link {
  margin-top: 10px;
}
