/* ============================================================
   TYGE ALEKSANDER — Personal Brand Design System
   tygealeksander.com
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@300;400;500;600;700&family=Barlow:wght@300;400;500&family=Lora:ital,wght@0,400;0,500;1,400;1,500&display=swap');

/* ── TOKENS ── */
:root {
  /* Palette — warm, grounded, premium */
  --ink:        #1a1410;
  --ink-soft:   #2e2520;
  --bark:       #5c3d2a;
  --bark-mid:   #7a5240;
  --bark-pale:  #a67c64;
  --sand:       #c4a882;
  --sand-pale:  #dfd0bb;
  --parchment:  #f5efe6;
  --cream:      #faf7f3;
  --white:      #ffffff;
  --muted:      #9e8e80;
  --rule:       rgba(92,61,42,0.18);

  /* Type */
  --display: 'Barlow Condensed', sans-serif;
  --body:    'Barlow', sans-serif;
  --serif:   'Lora', Georgia, serif;

  /* Space */
  --max:  1100px;
  --pad:  clamp(1.5rem, 5vw, 3rem);
  --gap:  clamp(3rem, 8vw, 6rem);

  /* Motion */
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --fast: 0.18s;
  --mid:  0.35s;
  --slow: 0.65s;
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink-soft);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; display: block; }
a { color: var(--bark); text-decoration: none; transition: color var(--fast) var(--ease); }
a:hover { color: var(--bark-mid); }

/* ── NAVIGATION ── */
.site-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  background: rgba(250,247,243,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--rule);
  transition: background var(--mid) var(--ease);
}
.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad);
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-wordmark {
  display: flex;
  align-items: center;
  transition: opacity var(--fast) var(--ease);
}
.nav-wordmark img {
  height: 32px;
  width: auto;
  display: block;
}
.nav-wordmark:hover { opacity: 0.75; }
.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  list-style: none;
}
.nav-links a {
  font-family: var(--display);
  font-weight: 500;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color var(--fast) var(--ease);
}
.nav-links a:hover,
.nav-links a.active { color: var(--bark); }
.nav-links a.active {
  position: relative;
}
.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0; right: 0;
  height: 1px;
  background: var(--bark);
}
.nav-cta {
  font-family: var(--display) !important;
  font-weight: 600 !important;
  font-size: 0.75rem !important;
  letter-spacing: 0.16em !important;
  text-transform: uppercase !important;
  color: var(--white) !important;
  background: var(--bark);
  padding: 0.45rem 1.1rem;
  border-radius: 2px;
  transition: background var(--fast) var(--ease) !important;
}
.nav-cta:hover { background: var(--bark-mid) !important; }
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}
.hamburger span {
  display: block;
  width: 24px; height: 1.5px;
  background: var(--bark);
  transition: transform var(--fast) var(--ease), opacity var(--fast) var(--ease);
}

/* ── MOBILE NAV ── */
@media (max-width: 680px) {
  .hamburger { display: flex; }
  .nav-links {
    display: none;
    position: fixed;
    top: 64px; left: 0; right: 0; bottom: 0;
    background: var(--cream);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    z-index: 199;
  }
  .nav-links.open { display: flex; }
  .nav-links a {
    font-size: 1.1rem !important;
    letter-spacing: 0.18em !important;
  }
  .nav-cta { padding: 0.7rem 2rem !important; }
}

/* ── UTILITIES ── */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }
.section { padding: var(--gap) 0; }
.section--dark { background: var(--ink); color: var(--parchment); }
.section--parchment { background: var(--parchment); }

/* Eyebrow labels */
.eyebrow {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--bark);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.2rem;
}
.eyebrow::before {
  content: '';
  display: block;
  width: 28px; height: 1px;
  background: var(--bark);
  flex-shrink: 0;
}
.section--dark .eyebrow { color: var(--sand); }
.section--dark .eyebrow::before { background: var(--sand); }

/* Display headings */
.display-xl {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(3.2rem, 8vw, 6.5rem);
  line-height: 0.95;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-transform: uppercase;
}
.display-lg {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-transform: uppercase;
}
.display-md {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  line-height: 1.1;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-transform: uppercase;
}
.section--dark .display-xl,
.section--dark .display-lg,
.section--dark .display-md { color: var(--cream); }

/* Serif pull quote */
.pull {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.25rem, 2.5vw, 1.6rem);
  line-height: 1.5;
  color: var(--bark-mid);
}
.section--dark .pull { color: var(--sand); }

/* Body prose */
.prose {
  font-family: var(--body);
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--ink-soft);
  max-width: 64ch;
}
.prose p + p { margin-top: 1.2em; }
.section--dark .prose { color: var(--sand-pale); }

/* Ruled divider */
.rule {
  border: none;
  border-top: 1px solid var(--rule);
  margin: var(--gap) 0;
}
.section--dark .rule { border-color: rgba(196,168,130,0.2); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.85rem 1.8rem;
  border-radius: 2px;
  transition: all var(--fast) var(--ease);
  cursor: pointer;
  border: none;
}
.btn-primary {
  background: var(--bark);
  color: var(--cream);
}
.btn-primary:hover {
  background: var(--bark-mid);
  color: var(--cream);
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent;
  color: var(--bark);
  border: 1px solid var(--bark);
}
.btn-outline:hover {
  background: var(--bark);
  color: var(--cream);
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent;
  color: var(--sand-pale);
  border: 1px solid rgba(196,168,130,0.4);
}
.btn-ghost:hover {
  border-color: var(--sand);
  color: var(--sand);
  transform: translateY(-1px);
}
.btn svg { width: 14px; height: 14px; flex-shrink: 0; }

/* Arrow link */
.arrow-link {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--bark);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: gap var(--fast) var(--ease), color var(--fast) var(--ease);
}
.arrow-link:hover { gap: 0.85rem; color: var(--bark-mid); }
.arrow-link::after { content: '→'; }
.section--dark .arrow-link { color: var(--sand); }
.section--dark .arrow-link:hover { color: var(--sand-pale); }

/* ── FOOTER ── */
.site-footer {
  background: var(--ink);
  color: var(--muted);
  padding: clamp(2.5rem, 6vw, 4rem) 0 2rem;
  border-top: 1px solid rgba(92,61,42,0.3);
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--pad);
}
.footer-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: start;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(196,168,130,0.1);
  margin-bottom: 2rem;
}
.footer-wordmark {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--parchment);
  margin-bottom: 0.5rem;
}
.footer-tagline {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.88rem;
  color: var(--muted);
}
.footer-nav {
  display: flex;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  list-style: none;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.footer-nav a {
  font-family: var(--display);
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color var(--fast) var(--ease);
}
.footer-nav a:hover { color: var(--sand); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer-legal {
  font-size: 0.75rem;
  color: rgba(158,142,128,0.6);
}
.footer-legal a { color: rgba(158,142,128,0.6); }
.footer-legal a:hover { color: var(--muted); }
.footer-social {
  display: flex;
  gap: 1rem;
}
.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border: 1px solid rgba(196,168,130,0.2);
  border-radius: 2px;
  color: var(--muted);
  transition: all var(--fast) var(--ease);
}
.footer-social a:hover {
  border-color: var(--sand);
  color: var(--sand);
}
.footer-social svg { width: 15px; height: 15px; }

/* ── FADE-IN ON SCROLL ── */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity var(--slow) var(--ease), transform var(--slow) var(--ease);
}
.fade-in.visible {
  opacity: 1;
  transform: none;
}
.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.35s; }
.fade-in-delay-4 { transition-delay: 0.5s; }

/* ── PAGE TRANSITION ── */
body { animation: pageIn var(--mid) var(--ease) both; }
@keyframes pageIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@media (max-width: 680px) {
  .footer-top { grid-template-columns: 1fr; }
  .footer-nav { justify-content: flex-start; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}
