/* ─────────────────────────────────────────────────
   global.css — gdsparks.com
   ───────────────────────────────────────────────── */

/* ── Tokens ──────────────────────────────────────── */
:root {
  --bg:        #0a0a0a;
  --surface:   #111111;
  --border:    #1e1e1e;
  --muted:     #444;
  --dim:       #888;
  --text:      #d4d0c8;
  --bright:    #f0ece0;
  --accent:    #c8b89a;   /* warm sand — the signature note */
  --accent2:   #5a8a6a;   /* optional green for tags */

  --nav-h:     60px;
  --page-max:  1080px;
  --pad-x:     clamp(20px, 5vw, 80px);
  --pad-y:     clamp(60px, 8vh, 120px);

  --sans: system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "SF Mono", "Fira Code", "Cascadia Code", Consolas, monospace;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --fast: 0.18s;
  --mid:  0.35s;
}

/* ── Reset ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: clamp(15px, 1.6vw, 17px);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { cursor: pointer; font: inherit; background: none; border: none; }

/* ── Typography scale ────────────────────────────── */
h1, h2, h3, h4 {
  color: var(--bright);
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.2rem, 5.5vw, 4rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.4rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); }

p { margin-bottom: 1.1em; }
p:last-child { margin-bottom: 0; }

/* ── Eyebrow label ───────────────────────────────── */
.eyebrow {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.9rem;
  font-weight: 500;
}

/* ── Section rule ────────────────────────────────── */
.section-rule {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0;
}

/* ── Page wrapper ────────────────────────────────── */
.page-wrap {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--pad-x);
}

/* ── Fade-in ─────────────────────────────────────── */
.fade-in {
  opacity: 0;
  transform: translateY(16px);
  animation: fadeUp var(--mid) var(--ease) forwards;
}
.fade-in.delay-1 { animation-delay: 0.1s; }
.fade-in.delay-2 { animation-delay: 0.2s; }
.fade-in.delay-3 { animation-delay: 0.35s; }

@keyframes fadeUp {
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .fade-in { animation: none; opacity: 1; transform: none; }
}

/* ── Scroll-reveal (JS adds .revealed) ──────────── */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}
.reveal.revealed {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}

/* ── Circa caption ───────────────────────────────── */
.circa {
  font-size: 0.78rem;
  color: var(--dim);
  margin-top: 10px;
  text-align: center;
  font-style: italic;
}

/* ── Arrow scroll button ─────────────────────────── */
.scroll-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--dim);
  text-decoration: none;
  transition: border-color var(--fast), color var(--fast), transform var(--fast);
  flex-shrink: 0;
}
.scroll-btn svg { width: 20px; height: 20px; display: block; }
.scroll-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(2px);
}

/* ── Inline text link ────────────────────────────── */
.text-link {
  color: var(--bright);
  text-decoration: underline;
  text-decoration-color: var(--border);
  text-underline-offset: 3px;
  transition: text-decoration-color var(--fast), color var(--fast);
}
.text-link:hover {
  text-decoration-color: var(--accent);
  color: var(--accent);
}

/* ── Tag pill ────────────────────────────────────── */
.tag {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 100px;
  border: 1px solid var(--border);
  color: var(--dim);
  white-space: nowrap;
  font-family: var(--mono);
  transition: border-color var(--fast), color var(--fast), background var(--fast);
  cursor: pointer;
  background: transparent;
}
.tag:hover,
.tag.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(200,184,154,0.07);
}

/* ── ─────────────────────────────────────────────── */
/* NAV                                                */
/* ── ─────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(10,10,10,0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  display: flex;
  align-items: center;
}

.nav-inner {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 var(--pad-x);
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1rem;
  font-weight: 600;
  color: var(--bright);
  text-decoration: none;
  letter-spacing: -0.01em;
  transition: color var(--fast);
}
.nav-logo:hover { color: var(--accent); }

.nav-links {
  display: flex;
  gap: clamp(16px, 3vw, 36px);
  list-style: none;
}

.nav-links a {
  font-size: 0.85rem;
  color: var(--dim);
  text-decoration: none;
  transition: color var(--fast);
  position: relative;
  padding-bottom: 2px;
}
.nav-links a::after {
  content: "";
  position: absolute;
  bottom: 0; left: 0;
  height: 1px;
  width: 0;
  background: var(--accent);
  transition: width var(--fast) var(--ease);
}
.nav-links a:hover,
.nav-links a.active { color: var(--bright); }
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

/* Hamburger */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
  color: var(--dim);
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: currentColor;
  transition: transform var(--fast), opacity var(--fast);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Mobile nav */
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0; right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 24px var(--pad-x) 32px;
  z-index: 99;
  flex-direction: column;
  gap: 20px;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  font-size: 1.15rem;
  color: var(--dim);
  text-decoration: none;
  transition: color var(--fast);
}
.nav-mobile a:hover, .nav-mobile a.active { color: var(--bright); }

@media (max-width: 640px) {
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
}

/* ── Footer ──────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  padding: 40px var(--pad-x);
  max-width: var(--page-max);
  margin: 0 auto;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer-copy {
  font-size: 0.78rem;
  color: var(--muted);
}
.footer-links {
  display: flex;
  gap: 20px;
  list-style: none;
}
.footer-links a {
  font-size: 0.78rem;
  color: var(--muted);
  text-decoration: none;
  transition: color var(--fast);
}
.footer-links a:hover { color: var(--bright); }

/* ── Body offset for fixed nav ───────────────────── */
body { padding-top: var(--nav-h); }
