/* ============================================
   ROOTWATER COLLECTIVE — MAIN STYLESHEET
   Sacred minimalism. Breathing design.
   ============================================ */

/* === GOOGLE FONTS === */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@900&family=Instrument+Serif:ital@1&family=DM+Sans:wght@300;400&family=JetBrains+Mono:wght@300&display=swap');

/* === CSS VARIABLES === */
:root {
  /* Colors */
  --black: #0A0A08;
  --near-black: #121210;
  --cream: #F5F0E6;
  --cream-dim: rgba(245, 240, 230, 0.6);
  --gold: #D4A843;
  --gold-dim: #B8922F;
  --red: #C4392D;
  --green: #2D7A3A;
  --green-deep: #1B5426;

  /* Typography */
  --font-display: 'Playfair Display', serif;
  --font-accent: 'Instrument Serif', serif;
  --font-body: 'DM Sans', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Spacing */
  --section-padding: 120px;
  --container-max: 1400px;
  --text-max: 680px;

  /* Transitions */
  --transition-smooth: cubic-bezier(0.25, 0.1, 0.25, 1.0);
}

/* === RESET & BASE === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--black);
  color: var(--cream);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.8;
  overflow-x: hidden;
  position: relative;
}

/* Film grain overlay */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* Radial gradient atmosphere */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(circle at 20% 80%, rgba(45, 122, 58, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(212, 168, 67, 0.06) 0%, transparent 50%),
    radial-gradient(circle at 50% 100%, rgba(196, 57, 45, 0.05) 0%, transparent 60%);
}

/* All content above the atmosphere */
.page-content {
  position: relative;
  z-index: 1;
}

/* === TYPOGRAPHY === */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.2;
  color: var(--cream);
}

h1 {
  font-size: clamp(2.5rem, 6vw, 5rem);
  letter-spacing: 0.08em;
}

h2 {
  font-size: clamp(2rem, 4vw, 3.5rem);
  letter-spacing: 0.04em;
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
}

.accent-text {
  font-family: var(--font-accent);
  font-style: italic;
  color: var(--gold);
}

.mono-text {
  font-family: var(--font-mono);
  font-weight: 300;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
}

/* === RASTAFARI BAR === */
.rastafari-bar {
  height: 3px;
  width: 100%;
  background: linear-gradient(to right,
    var(--red) 0%,
    var(--red) 33.33%,
    var(--gold) 33.33%,
    var(--gold) 66.66%,
    var(--green) 66.66%,
    var(--green) 100%
  );
  margin: 0;
}

/* === NAVIGATION === */
nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 2rem 4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
  background: linear-gradient(to bottom, var(--black) 0%, transparent 100%);
}

.logo {
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: 0.15em;
  color: var(--cream);
  text-decoration: none;
  transition: color 200ms ease;
}

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

.nav-links {
  display: flex;
  gap: 3rem;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 0.95rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cream-dim);
  text-decoration: none;
  position: relative;
  transition: color 200ms ease;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width 300ms var(--transition-smooth);
}

.nav-links a:hover {
  color: var(--gold);
}

.nav-links a:hover::after {
  width: 100%;
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--cream);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
}

/* Mobile navigation overlay */
.mobile-nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: var(--black);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 400ms ease;
}

.mobile-nav-overlay.active {
  opacity: 1;
  pointer-events: all;
}

.mobile-nav-overlay ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100%;
  gap: 2rem;
}

.mobile-nav-overlay a {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--cream);
  text-decoration: none;
  transition: color 300ms ease;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInStagger 600ms var(--transition-smooth) forwards;
}

.mobile-nav-overlay a:nth-child(1) { animation-delay: 100ms; }
.mobile-nav-overlay a:nth-child(2) { animation-delay: 200ms; }
.mobile-nav-overlay a:nth-child(3) { animation-delay: 300ms; }
.mobile-nav-overlay a:nth-child(4) { animation-delay: 400ms; }
.mobile-nav-overlay a:nth-child(5) { animation-delay: 500ms; }

.mobile-nav-overlay a:hover {
  color: var(--gold);
}

@keyframes fadeInStagger {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* === BUTTONS & CTAs === */
.btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.95rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--black);
  background: var(--gold);
  border: 1px solid var(--gold);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 300ms var(--transition-smooth);
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--cream);
  transition: left 300ms var(--transition-smooth);
  z-index: -1;
}

.btn:hover::before {
  left: 0;
}

.btn:hover {
  color: var(--black);
}

.btn-ghost {
  background: transparent;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
}

.btn-ghost:hover {
  background: var(--gold);
  color: var(--black);
}

/* === CONTAINERS & LAYOUT === */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 2rem;
}

.text-container {
  max-width: var(--text-max);
  margin: 0 auto;
}

section {
  padding: var(--section-padding) 0;
  position: relative;
}

/* === BREATHING ANIMATION === */
@keyframes breathe {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.03);
  }
}

.breathing {
  animation: breathe 8s ease-in-out infinite;
}

/* Honor reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .breathing {
    animation: none;
  }
}

/* === RIPPLE EFFECT === */
.ripple-container {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 300px;
  height: 300px;
  pointer-events: none;
}

.ripple {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: 1px solid var(--gold-dim);
  border-radius: 50%;
  opacity: 0;
  animation: rippleExpand 6s ease-out infinite;
}

.ripple:nth-child(2) {
  animation-delay: 2s;
}

.ripple:nth-child(3) {
  animation-delay: 4s;
}

@keyframes rippleExpand {
  0% {
    width: 50px;
    height: 50px;
    opacity: 0.3;
  }
  100% {
    width: 300px;
    height: 300px;
    opacity: 0;
  }
}

/* === SCROLL REVEAL === */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 600ms var(--transition-smooth),
              transform 600ms var(--transition-smooth);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.reveal-stagger:nth-child(1) { transition-delay: 0ms; }
.reveal-stagger:nth-child(2) { transition-delay: 100ms; }
.reveal-stagger:nth-child(3) { transition-delay: 200ms; }
.reveal-stagger:nth-child(4) { transition-delay: 300ms; }
.reveal-stagger:nth-child(5) { transition-delay: 400ms; }

/* === SCROLL INDICATOR === */
.scroll-indicator {
  position: absolute;
  bottom: 3rem;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 60px;
  background: linear-gradient(to bottom, transparent, var(--gold), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% {
    opacity: 0.4;
    transform: translateX(-50%) translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateX(-50%) translateY(10px);
  }
}

/* === CUSTOM CURSOR === */
.cursor {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  position: fixed;
  pointer-events: none;
  z-index: 10000;
  transition: width 200ms ease, height 200ms ease, opacity 200ms ease;
  box-shadow: 0 0 20px rgba(212, 168, 67, 0.4);
  opacity: 0;
}

.cursor.active {
  opacity: 1;
}

.cursor.hover {
  width: 24px;
  height: 24px;
  background: rgba(212, 168, 67, 0.2);
  border: 1px solid var(--gold);
}

/* Hide custom cursor on mobile */
@media (max-width: 768px) {
  .cursor {
    display: none;
  }
}

/* === FORMS === */
input[type="email"],
input[type="text"],
textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--gold-dim);
  color: var(--cream);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 1rem 0;
  margin-bottom: 2rem;
  transition: border-color 200ms ease;
}

input:focus,
textarea:focus {
  outline: none;
  border-bottom-color: var(--gold);
}

::placeholder {
  color: var(--cream-dim);
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
  :root {
    --section-padding: 80px;
  }

  nav {
    padding: 1.5rem 2rem;
  }
}

@media (max-width: 768px) {
  :root {
    --section-padding: 60px;
  }

  nav {
    padding: 1rem 1.5rem;
  }

  .nav-links {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .mobile-nav-overlay {
    display: block;
  }

  section {
    padding: 60px 0;
  }

  .container {
    padding: 0 1.5rem;
  }
}

/* === ACCESSIBILITY === */
.skip-to-content {
  position: absolute;
  top: -100px;
  left: 0;
  background: var(--gold);
  color: var(--black);
  padding: 1rem 2rem;
  text-decoration: none;
  font-weight: 400;
  z-index: 10001;
  transition: top 200ms ease;
}

.skip-to-content:focus {
  top: 0;
}

/* Focus styles */
a:focus,
button:focus,
input:focus,
textarea:focus {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* Selection color */
::selection {
  background: var(--gold);
  color: var(--black);
}
