/* ================= Base ================= */
:root {
  --ink:  #0B0F14;
  --deep: #101720;
  --card: #141C27;
  --line: #1E2937;
  --mist: #8A97A6;
  --fog:  #C9D2DC;
  --sea:  #6FA8A0;
  --gold: #C7A97B;
  --rose: #B08A8E;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  font-family: 'Montserrat', 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--ink);
  color: var(--fog);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  background-image:
    radial-gradient(1100px 600px at 75% -10%, rgba(111,168,160,0.10), transparent 60%),
    radial-gradient(900px 500px at 10% 25%, rgba(199,169,123,0.06), transparent 60%);
  background-repeat: no-repeat;
}

::selection { background: rgba(111,168,160,0.28); }

a { text-decoration: none; color: inherit; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }

header, main, footer { position: relative; z-index: 2; }

/* ================= Typography ================= */
.eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-weight: 500;
}

h1 {
  font-size: clamp(2.4rem, 7vw, 4.6rem);
  font-weight: 300;
  line-height: 1.12;
  color: var(--fog);
}
h1 strong, h2 strong { font-weight: 600; }

h2 {
  font-size: clamp(1.7rem, 4.5vw, 2.6rem);
  font-weight: 300;
  line-height: 1.25;
  color: var(--fog);
}

.lead {
  color: var(--mist);
  font-weight: 300;
  font-size: clamp(1rem, 2vw, 1.13rem);
  line-height: 1.8;
}

.text-sea  { color: var(--sea); }
.text-gold { color: var(--gold); }
.text-rose { color: var(--rose); }

/* ================= Ambient: sea ================= */
.sea {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: 32vh;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to top, black 55%, transparent);
          mask-image: linear-gradient(to top, black 55%, transparent);
}
.sea svg {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 200%;
  height: 100%;
}
.wave-a { animation: seaDrift 70s linear infinite; }
.wave-b { animation: seaDriftBack 95s linear infinite; }

@keyframes seaDrift     { from { transform: translateX(0); }     to { transform: translateX(-50%); } }
@keyframes seaDriftBack { from { transform: translateX(-50%); } to { transform: translateX(0); } }

/* ================= Ambient: lightning ================= */
.bolt {
  position: absolute;
  z-index: 0;
  pointer-events: none;
  color: var(--gold);
  opacity: 0.05;
  filter: drop-shadow(0 0 7px currentColor);
}
.bolt-1 { top: 4%;  right: 12%; width: 46px; height: 210px; animation: flicker 4s linear infinite; }
.bolt-2 { top: 16%; left: 8%;   width: 34px; height: 150px; color: var(--sea); animation: flicker 4s linear infinite 0.18s; }

/* One lightning strike every 4 seconds (double flash) */
@keyframes flicker {
  0%, 84%, 100% { opacity: 0.06; }
  86%           { opacity: 0.75; }
  88%           { opacity: 0.15; }
  90%           { opacity: 0.55; }
  93%           { opacity: 0.07; }
}

/* Faint sky flash synced with the bolts */
.flash {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(900px 480px at 72% -5%, rgba(199, 214, 230, 0.9), transparent 65%);
  opacity: 0;
  animation: skyflash 4s linear infinite;
}
@keyframes skyflash {
  0%, 85%, 100% { opacity: 0; }
  86.5%         { opacity: 0.14; }
  88%           { opacity: 0.03; }
  90%           { opacity: 0.10; }
  92.5%         { opacity: 0; }
}

/* ================= Ambient: rain ================= */
.rain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='220'><g stroke='%23AEC4D8' stroke-opacity='0.13' stroke-width='1' stroke-linecap='round'><line x1='22' y1='12' x2='17' y2='64'/><line x1='92' y1='95' x2='87' y2='147'/><line x1='142' y1='170' x2='137' y2='218'/></g></svg>"),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='210' height='300'><g stroke='%23AEC4D8' stroke-opacity='0.08' stroke-width='1' stroke-linecap='round'><line x1='45' y1='20' x2='39' y2='88'/><line x1='150' y1='130' x2='144' y2='198'/><line x1='95' y1='230' x2='89' y2='295'/></g></svg>");
  background-size: 160px 220px, 210px 300px;
  animation: rainFall 1.3s linear infinite;
}
@keyframes rainFall {
  from { background-position: 0 0, 60px 0; }
  to   { background-position: 0 220px, 60px 300px; }
}

/* Faint stars in hero and CTA */
.stars { position: relative; }
.stars::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 12% 20%, rgba(201,210,220,0.35), transparent 100%),
    radial-gradient(1px 1px at 28% 65%, rgba(201,210,220,0.22), transparent 100%),
    radial-gradient(1.5px 1.5px at 46% 30%, rgba(201,210,220,0.30), transparent 100%),
    radial-gradient(1px 1px at 62% 75%, rgba(201,210,220,0.20), transparent 100%),
    radial-gradient(1px 1px at 78% 18%, rgba(201,210,220,0.32), transparent 100%),
    radial-gradient(1.5px 1.5px at 88% 55%, rgba(201,210,220,0.22), transparent 100%),
    radial-gradient(1px 1px at 35% 85%, rgba(201,210,220,0.18), transparent 100%);
}

/* ================= Nav ================= */
nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 30px 0;
}
.logo {
  color: var(--fog);
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-size: 0.85rem;
}
.nav-tag {
  color: var(--mist);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  text-align: right;
}
@media (max-width: 600px) {
  .nav-tag { font-size: 0.56rem; letter-spacing: 0.12em; }
}

/* ================= Buttons ================= */
.btn {
  display: inline-block;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  padding: 16px 36px;
  text-align: center;
}
.btn-sm { padding: 11px 22px; font-size: 0.68rem; }

.btn-primary {
  background: var(--sea);
  color: var(--ink);
  transition: transform 0.35s cubic-bezier(0.22,1,0.36,1), box-shadow 0.35s ease;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 40px -12px rgba(111,168,160,0.45);
}

.btn-ghost {
  border: 1px solid var(--line);
  color: var(--mist);
  font-weight: 500;
  transition: border-color 0.35s ease, color 0.35s ease, transform 0.35s cubic-bezier(0.22,1,0.36,1);
}
.btn-ghost:hover {
  border-color: rgba(199,169,123,0.6);
  color: var(--gold);
  transform: translateY(-2px);
}

/* ================= Hero ================= */
.hero { text-align: center; padding: 90px 0 130px; }
.hero .eyebrow { color: var(--sea); margin-bottom: 26px; }
.hero h1 { max-width: 800px; margin: 0 auto; }
.hero .lead { max-width: 620px; margin: 32px auto 0; }
.hero-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 52px;
}
@media (min-width: 640px) { .hero-actions { flex-direction: row; } }

.compass { margin-top: 80px; display: flex; justify-content: center; }
.compass svg { width: 42px; height: 42px; color: var(--gold); opacity: 0.7; animation: driftY 7s ease-in-out infinite; }
@keyframes driftY { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ================= Sections ================= */
section { padding: 90px 0; }
.center { text-align: center; }

.rule {
  height: 1px;
  border: none;
  background: linear-gradient(90deg, transparent, rgba(199,169,123,0.45), transparent);
  margin-bottom: 60px;
}

.manifesto p.big {
  font-size: clamp(1.35rem, 3.4vw, 1.9rem);
  font-weight: 300;
  line-height: 1.55;
  color: var(--fog);
}
.manifesto .lead { margin-top: 30px; }
.narrow { max-width: 720px; margin-left: auto; margin-right: auto; }

/* ================= Pillar cards ================= */
.section-head { margin-bottom: 60px; }
.section-head .eyebrow { margin-bottom: 14px; }

.pillars {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
}
@media (min-width: 768px) { .pillars { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 42px 34px;
  transition: transform 0.45s cubic-bezier(0.22,1,0.36,1),
              border-color 0.45s ease,
              box-shadow 0.45s ease;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(111,168,160,0.45);
  box-shadow: 0 18px 50px -20px rgba(111,168,160,0.22);
}
.card h3 {
  color: var(--fog);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.card p {
  color: var(--mist);
  font-weight: 300;
  font-size: 0.95rem;
  line-height: 1.75;
}
.icon {
  width: 46px;
  height: 46px;
  margin-bottom: 24px;
  display: block;
}

/* ================= CTA ================= */
.cta { text-align: center; padding: 110px 0 130px; }
.cta h2 { font-size: clamp(2.1rem, 6vw, 3.3rem); margin: 22px 0 30px; }
.cta .lead { max-width: 560px; margin: 0 auto 50px; }

/* ================= Footer ================= */
footer { border-top: 1px solid var(--line); }
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 38px 0;
  text-align: center;
}
@media (min-width: 768px) { .footer-inner { flex-direction: row; } }
.footer-inner .tag {
  color: var(--mist);
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}
.footer-inner .copy { color: rgba(138,151,166,0.6); font-size: 0.75rem; font-weight: 300; }

/* ================= Scroll reveal (only when JS is available) ================= */
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s cubic-bezier(0.22,1,0.36,1),
              transform 0.9s cubic-bezier(0.22,1,0.36,1);
  will-change: opacity, transform;
}
.js .reveal.visible { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: 0.12s; }
.delay-2 { transition-delay: 0.24s; }
.delay-3 { transition-delay: 0.36s; }

@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .wave-a, .wave-b, .bolt-1, .bolt-2, .compass svg, .flash, .rain { animation: none; }
  .flash { opacity: 0; }
}

/* ================= Footer links ================= */
.footer-link {
  color: var(--mist);
  font-size: 0.75rem;
  font-weight: 400;
  transition: color 0.3s ease;
}
.footer-link:hover { color: var(--sea); }

/* ================= Legal pages (privacy policy) ================= */
.legal {
  max-width: 720px;
  margin: 0 auto;
  padding: 30px 24px 110px;
}
.legal h1 {
  font-size: clamp(1.9rem, 5vw, 2.7rem);
  margin-bottom: 12px;
}
.legal .updated {
  color: var(--mist);
  font-size: 0.85rem;
  font-weight: 300;
  margin-bottom: 46px;
}
.legal h2 {
  color: var(--fog);
  font-size: 1.1rem;
  font-weight: 600;
  margin: 38px 0 12px;
}
.legal p, .legal li {
  color: var(--mist);
  font-weight: 300;
  line-height: 1.8;
  font-size: 0.95rem;
  margin-bottom: 12px;
}
.legal ul { padding-left: 22px; margin-bottom: 12px; }
.legal a { color: var(--sea); }
.legal a:hover { color: var(--gold); }

/* Per-pillar accent colors on card headings */
.card h3.text-gold { color: var(--gold); }
.card h3.text-sea  { color: var(--sea); }
.card h3.text-rose { color: var(--rose); }
