/* Space Sections Container */
.space-section {
  min-height: 90vh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
  overflow: hidden;
}

/* Safe Spaces Section */
.safe-spaces {
  background: linear-gradient(rgba(0,0,0,0.5),rgba(0,0,0,0.5)), url(images/safe-space.jpg);
  animation: gradientShift 8s ease infinite;
}

.safe-spaces::after {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255,255,255,0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(255,255,255,0.12) 0%, transparent 50%),
    radial-gradient(circle at 90% 10%, rgba(255,255,255,0.06) 0%, transparent 50%);
  animation: pearlShift 8s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

/* Creative Spaces Section */
.creative-spaces {
  background: linear-gradient(rgba(0,0,0,0.5),rgba(0,0,0,0.5)), url(images/creative-space.jpg);
  animation: gradientShift 8s ease infinite;
}

.creative-spaces::after {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255,255,255,0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(255,255,255,0.12) 0%, transparent 50%),
    radial-gradient(circle at 90% 10%, rgba(255,255,255,0.06) 0%, transparent 50%);
  animation: pearlShift 8s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

/* Thematic Spaces Section */
.thematic-spaces {
  background: linear-gradient(rgba(0,0,0,0.5),rgba(0,0,0,0.5)), url(images/thematic-space.jpg);
  animation: gradientShift 8s ease infinite;
}

.thematic-spaces::after {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255,255,255,0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 20%, rgba(255,255,255,0.12) 0%, transparent 50%),
    radial-gradient(circle at 90% 10%, rgba(255,255,255,0.06) 0%, transparent 50%);
  animation: pearlShift 8s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

/* Gradient Animation */
@keyframes gradientShift {
  0%, 100% { filter: hue-rotate(0deg); }
  50% { filter: hue-rotate(20deg); }
}

/* Pearl Shift Animation */
@keyframes pearlShift {
  0%, 100% {
    transform: scale(1) translateX(0);
    opacity: 0.8;
  }
  50% {
    transform: scale(1.1) translateX(20px);
    opacity: 1;
  }
}

/* Floating Particles */
.space-section .particles {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 1;
}

.particle {
  position: absolute;
  background: rgba(255,255,255,0.5);
  border-radius: 50%;
  animation: particleFloat 15s linear infinite;
}

@keyframes particleFloat {
  0% {
    transform: translateY(100vh) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    transform: translateY(-100px) rotate(360deg);
    opacity: 0;
  }
}

/* Overlay Container */
.space-overlay {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 900px;
  animation: fadeInUp 1s ease-out;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Space Content */
.space-content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
}

/* Headings */
.space-content h1, .space-content h2 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #fff 0%, rgba(255,255,255,0.7) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: titleSlide 1s ease-out 0.2s both;
}

@keyframes titleSlide {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Paragraphs */
.space-content p {
  font-size: 1.15rem;
  line-height: 1.8;
  margin: 1.5rem auto;
  opacity: 0.95;
  animation: fadeIn 1s ease-out 0.4s both;
  max-width: 800px;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 0.95; }
}

/* Buttons */
.btn {
  display: inline-block;
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
  color: #fff;
  padding: 1rem 2.5rem;
  text-decoration: none;
  border-radius: 50px;
  border: 2px solid rgba(255,255,255,0.3);
  font-size: 1.1rem;
  font-weight: 600;
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
  margin-top: 2rem;
  cursor: pointer;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.3), rgba(255,255,255,0.1));
  transform: translateX(-100%);
  transition: transform 0.4s ease;
}

.btn:hover {
  transform: scale(1.05);
  border-color: rgba(255,255,255,0.8);
  box-shadow: 0 10px 30px rgba(255,255,255,0.2);
}

.btn:hover::before {
  transform: translateX(0);
}

.btn span {
  position: relative;
  z-index: 1;
}

/* Divider */
hr {
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  border: none;
  margin: 0;
}

/* Responsive */
@media (max-width: 992px) {
  .space-content h1 {
    font-size: 2rem;
  }

  .space-content p {
    font-size: 1rem;
  }

  .btn {
    padding: 0.9rem 2rem;
    font-size: 1rem;
  }
}

@media (max-width: 768px) {
  .space-section {
    min-height: auto;
    padding: 3rem 1.5rem;
  }

  .space-content h1 {
    font-size: 1.75rem;
  }

  .space-content p {
    font-size: 0.95rem;
    margin: 1rem auto;
  }

  .btn {
    padding: 0.8rem 1.8rem;
    font-size: 0.95rem;
  }
}