/* ===== Peaceful Mind — Custom Styles ===== */

/* Base */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
}

/* Selection color */
::selection {
  background: rgba(20, 184, 166, 0.3);
  color: #f0fdf9;
}

/* ===== Scroll Reveal ===== */
.scroll-reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (prefers-reduced-motion: no-preference) {
  .scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
  }
  
  .scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Navbar Scroll State ===== */
#navbar.scrolled {
  background: rgba(4, 8, 16, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(20, 184, 166, 0.1);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

#navbar.scrolled .nav-link {
  color: rgba(153, 246, 219, 0.8);
}

/* ===== Mobile Menu ===== */
#mobile-menu.open {
  opacity: 1;
  pointer-events: all;
}

#mobile-menu.open .mobile-link {
  animation: fadeUp 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

#mobile-menu.open .mobile-link:nth-child(1) { animation-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { animation-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { animation-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { animation-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { animation-delay: 0.25s; }

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Mobile menu button active state */
#menu-btn.active .menu-line:nth-child(1) {
  transform: rotate(45deg) translate(3px, 3px);
}

#menu-btn.active .menu-line:nth-child(2) {
  opacity: 0;
}

#menu-btn.active .menu-line:nth-child(3) {
  width: 1.5rem;
  transform: rotate(-45deg) translate(3px, -3px);
}

/* ===== Custom Select ===== */
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%235eead4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

/* ===== Focus visible ===== */
*:focus-visible {
  outline: 2px solid rgba(20, 184, 166, 0.6);
  outline-offset: 2px;
}

/* ===== Button ripple effect ===== */
button, a {
  position: relative;
  overflow: hidden;
}

/* ===== Image aspect ratios ===== */
img {
  max-width: 100%;
  height: auto;
}

/* ===== Smooth scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #040810;
}

::-webkit-scrollbar-thumb {
  background: rgba(20, 184, 166, 0.2);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(20, 184, 166, 0.4);
}

/* ===== Gold accent divider ===== */
.gold-divider {
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, #e8c55a, transparent);
  border: none;
  margin: 1.5rem 0;
}

/* ===== Subtle shimmer animation for hero ===== */
@keyframes shimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

.hero-shimmer {
  background: linear-gradient(90deg, 
    rgba(20, 184, 166, 0) 0%, 
    rgba(20, 184, 166, 0.08) 50%, 
    rgba(20, 184, 166, 0) 100%
  );
  background-size: 200% 100%;
  animation: shimmer 4s ease-in-out infinite;
}

/* ===== Floating animation ===== */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

.float-animation {
  animation: float 4s ease-in-out infinite;
}

/* ===== Pulse ring ===== */
@keyframes pulse-ring {
  0% { transform: scale(0.8); opacity: 0.5; }
  50% { transform: scale(1.2); opacity: 0; }
  100% { transform: scale(0.8); opacity: 0.5; }
}

.pulse-ring::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid rgba(20, 184, 166, 0.4);
  animation: pulse-ring 2s ease-in-out infinite;
}
