/* ============================================================
   Austin Ali — design system
   Palette pulled from the hero photograph's own stage lighting
   (violet/blue with a warm amber accent) — #646496 is sampled
   directly from the photo.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

:root {
  --bg: #0a0912;
  --bg-panel: #131025;
  --bg-panel-raised: #181432;
  --line: rgba(212, 206, 255, 0.10);
  --line-strong: rgba(212, 206, 255, 0.20);

  --text: #eeebf8;
  /* Alphas chosen so every step clears WCAG AA (4.5:1) on --bg: soft 12.4,
     dim 8.0, faint 4.7. The previous values left faint at 2.2, which read
     as flat grey rather than quiet. */
  --text-soft: rgba(238, 235, 248, 0.86);
  --text-dim: rgba(238, 235, 248, 0.68);
  --text-faint: rgba(238, 235, 248, 0.50);

  --tint: #646496;          /* the exact hero-photo duotone color */
  --accent: #9c97dc;        /* brightened for UI: links, labels, focus */
  --accent-soft: rgba(156, 151, 220, 0.55);
  --accent-faint: rgba(156, 151, 220, 0.09);
  --accent-blue: #6fa9d8;   /* secondary cool accent, used sparingly */

  --serif: 'Spectral', Georgia, serif;
  /* Montserrat stands in for Proxima Nova, which needs a commercial licence.
     Swap the stack here and the font link in build.py to switch. */
  --sans: 'Montserrat', 'Proxima Nova', -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
  background: var(--bg);
  font-size: 17px;
  color: var(--text);
  font-family: var(--sans);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; }
img { max-width: 100%; display: block; }

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

/* ━━ NAV ━━ */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px 56px;
  transition: padding 0.4s ease, background 0.4s ease, border-color 0.4s ease;
  border-bottom: 1px solid transparent;
  /* Scrim so the bar reads over the hero photo instead of fighting it. */
  background: linear-gradient(to bottom,
    rgba(10, 9, 18, 0.88) 0%, rgba(10, 9, 18, 0.55) 55%, transparent 100%);
}
nav.scrolled {
  padding: 12px 56px;
  background: rgba(10, 9, 18, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}
.nav-name {
  display: flex; align-items: center; gap: 16px;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 20px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  line-height: 1;
}
.nav-logo {
  width: 52px; height: auto; display: block; flex-shrink: 0;
  transition: width 0.4s ease;
}
nav.scrolled .nav-logo { width: 42px; }
@media (max-width: 720px) {
  .nav-name { font-size: 14px; letter-spacing: 0.14em; gap: 10px; }
  .nav-logo, nav.scrolled .nav-logo { width: 34px; }
}
.nav-links {
  list-style: none; display: flex; align-items: center; gap: 34px;
}
.nav-links a {
  font-size: 14.5px;
  font-weight: 400;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.25s;
}
.nav-links a:hover, .nav-links a:focus-visible, .nav-links a.active { color: var(--text); }
.nav-links a.active { color: var(--accent); }

/* Contact is the action we want people to take, so it reads as a button. */
.nav-links a.nav-cta {
  border: 1px solid var(--line-strong);
  padding: 7px 13px;
  /* Cancel the box's left padding so the gap between WORKS and CONTACT
     measures text-to-text, matching the gaps between the other items. */
  margin-left: -13px;
  color: var(--text);
  transition: border-color 0.25s, color 0.25s, background 0.25s;
}
.nav-links a.nav-cta:hover { border-color: var(--accent); color: var(--accent); }
.nav-links a.nav-cta.active {
  border-color: var(--accent-soft); background: var(--accent-faint); color: var(--accent);
}
.nav-toggle { display: none; }

@media (max-width: 720px) {
  /* The logo + wordmark already links home, so the Home item is a duplicate
     that costs scarce horizontal room on a phone. */
  .nav-links li.nav-home { display: none; }
  /* Stack the wordmark: min-content is the width of the longest word, so the
     line breaks at the space and ALI drops under AUSTIN instead of running
     into ABOUT. */
  .nav-name span { display: inline-block; width: min-content; line-height: 1.08; }
  nav { padding: 18px 22px; }
  nav.scrolled { padding: 14px 22px; }
  .nav-links { gap: 18px; }
  .nav-links a { font-size: 12.5px; }
  .nav-links a.nav-cta { padding: 6px 10px; margin-left: -10px; }
}

/* Small phones. Even with the wordmark stacked there is no slack left at
   320-390px, so the nav items give up a little tracking and size to keep a
   real gap between ALI and ABOUT. */
@media (max-width: 400px) {
  nav { padding: 16px 16px; }
  nav.scrolled { padding: 12px 16px; }
  .nav-name { font-size: 13px; gap: 8px; }
  .nav-logo, nav.scrolled .nav-logo { width: 30px; }
  .nav-links { gap: 12px; }
  .nav-links a { font-size: 11px; letter-spacing: 0.12em; }
  .nav-links a.nav-cta { padding: 5px 8px; margin-left: -8px; }
}

/* iPhone SE and friends. At 320px the tier above still leaves the wordmark
   touching ABOUT, so this one buys back about 35px. */
@media (max-width: 344px) {
  nav { padding: 14px 12px; }
  nav.scrolled { padding: 11px 12px; }
  .nav-name { font-size: 12px; gap: 6px; }
  .nav-logo, nav.scrolled .nav-logo { width: 28px; }
  .nav-links { gap: 10px; }
  .nav-links a { font-size: 10.5px; letter-spacing: 0.08em; }
  .nav-links a.nav-cta { padding: 4px 6px; margin-left: -6px; }
}

/* ━━ SHARED SECTION RHYTHM ━━ */
main { display: block; }
.section {
  max-width: 1080px;
  margin: 0 auto;
  padding: 120px 56px;
  scroll-margin-top: 90px;
}
@media (max-width: 720px) {
  .section { padding: 88px 24px; }
}

.eyebrow {
  display: flex; align-items: center; gap: 20px;
  margin-bottom: 28px;
}
.eyebrow-line { width: 44px; height: 1px; background: var(--accent); }
.eyebrow-text {
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--accent);
}

h1, h2, h3 { font-family: var(--serif); font-weight: 400; text-wrap: balance; }
h2 {
  font-size: clamp(28px, 4vw, 40px);
  margin-bottom: 20px;
}
.section-lead {
  font-size: 18px;
  line-height: 1.75;
  color: var(--text-soft);
  max-width: 68ch;
}

/* ━━ FOOTER ━━ */
footer {
  border-top: 1px solid var(--line);
  padding: 54px 56px 58px;
  display: flex; flex-direction: column; align-items: center;
  gap: 20px; text-align: center;
}
.footer-logo { width: 54px; height: auto; display: block; opacity: 0.9; }
.footer-name {
  font-family: var(--sans); font-weight: 600; font-size: 14px;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--text-dim);
}
.footer-social {
  list-style: none; display: flex; gap: 26px; flex-wrap: wrap; justify-content: center;
}
.footer-social a {
  font-size: 11.5px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--text-faint); text-decoration: none; transition: color 0.25s;
}
.footer-social a:hover { color: var(--accent); }
@media (max-width: 720px) {
  footer { padding: 40px 24px 48px; }
}

/* ━━ BIO PHOTO ━━ */
.bio-photo {
  width: 100%;
  border: 1px solid var(--line-strong);
}
.bio-photo img { width: 100%; height: auto; display: block; }
.bio-photo-cap {
  font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-faint); margin-top: 12px;
}
