/* ============================================================
   Jackson Feist — resume & consulting site
   Editorial, warm-paper palette. One accent. No frameworks.
   ============================================================ */

:root {
  --paper: #FBFAF7;
  --paper-tint: #F4F2EC;
  --card: #FFFFFF;
  --ink: #1C1A15;
  --ink-soft: #43403A;
  --muted: #6E6A5F;
  --hairline: #E4E1D8;
  --accent: #2A5A47;
  --accent-deep: #1E4534;
  --accent-wash: #EAF0EC;
  --radius: 14px;
  --radius-small: 10px;
  --shadow: 0 1px 2px rgba(28, 26, 21, 0.05), 0 8px 24px rgba(28, 26, 21, 0.06);
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-deep); }
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 250, 247, 0.86);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease;
}
.site-header.scrolled { border-bottom-color: var(--hairline); }

.nav {
  max-width: 1080px;
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-brand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--ink);
  letter-spacing: 0.01em;
}
.nav-brand:hover { color: var(--accent-deep); }

.nav-menu {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-menu > a:not(.btn) {
  color: var(--ink-soft);
  font-size: 0.95rem;
  font-weight: 500;
}
.nav-menu > a:not(.btn):hover { color: var(--ink); }
.nav-menu > a.active { color: var(--accent-deep); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  font-size: 0.98rem;
  padding: 13px 26px;
  border-radius: 999px;
  transition: background 0.2s ease, transform 0.2s ease;
}
.btn:hover { background: var(--accent-deep); color: #fff; transform: translateY(-1px); }

.btn-small { padding: 9px 20px; font-size: 0.9rem; }

.btn-ghost {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--hairline);
}
.btn-ghost:hover { background: var(--paper-tint); color: var(--ink); }

.link-quiet {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
}
.link-quiet:hover { color: var(--ink); }

/* ---------- Hero ---------- */

.hero { padding: 96px 0 72px; }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent-deep);
  margin-bottom: 22px;
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.5rem, 6vw, 4.1rem);
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin-bottom: 26px;
}

.hero-lede {
  max-width: 640px;
  font-size: 1.15rem;
  color: var(--ink-soft);
  margin-bottom: 34px;
}
.hero-lede a { font-weight: 500; }

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 56px;
}

.proof-bar {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 40px;
  padding-top: 28px;
  border-top: 1px solid var(--hairline);
  color: var(--muted);
  font-size: 0.92rem;
}
.proof-bar strong {
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  margin-right: 2px;
}

/* ---------- Sections ---------- */

.section { padding: 84px 0; }
.section-tint { background: var(--paper-tint); }

.section-title {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 48px;
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}
.section-title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--hairline);
}

.section-lede {
  max-width: 620px;
  font-size: 1.12rem;
  color: var(--ink-soft);
  margin: -20px 0 44px;
}

/* ---------- Case studies ---------- */

.case {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
  padding: 44px 0;
}
.case + .case { border-top: 1px solid var(--hairline); }
.case:nth-child(odd) .case-media { order: 2; }

.case-media img {
  border-radius: var(--radius);
  border: 1px solid var(--hairline);
  box-shadow: var(--shadow);
}

.case-kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-deep);
  margin-bottom: 10px;
}

.case h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.85rem;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}

.case-body p { color: var(--ink-soft); margin-bottom: 14px; }

.tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 6px 0 16px;
}
.tags li {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--accent-deep);
  background: var(--accent-wash);
  padding: 4px 12px;
  border-radius: 999px;
}

.case-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-weight: 500;
  font-size: 0.98rem;
}

.status-note {
  color: var(--muted);
  font-size: 0.92rem;
  font-style: italic;
  font-weight: 400;
}

/* ---------- Project grid ---------- */

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 24px;
}

.project-card {
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.project-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 2px 4px rgba(28, 26, 21, 0.06), 0 14px 32px rgba(28, 26, 21, 0.1);
}

.project-card img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  width: 100%;
}

.project-card-body { padding: 18px 20px 20px; }

.project-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.13rem;
  margin-bottom: 6px;
}

.project-card p {
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.55;
}

.card-link {
  display: inline-block;
  margin-top: 10px;
  font-size: 0.9rem;
  font-weight: 500;
}

/* ---------- Services ---------- */

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.service-card {
  background: var(--card);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 28px 26px;
  box-shadow: var(--shadow);
}

.service-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  margin-bottom: 10px;
}

.service-card > p { font-size: 0.95rem; color: var(--ink-soft); }

.service-stack {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--hairline);
  font-size: 0.82rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.service-cta {
  margin-top: 48px;
  background: var(--accent-wash);
  border: 1px solid #D8E3DC;
  border-radius: var(--radius);
  padding: 36px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.service-cta p {
  font-size: 1.08rem;
  color: var(--accent-deep);
  max-width: 560px;
}

/* ---------- Experience ---------- */

.xp-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 64px;
  align-items: start;
}

.timeline {
  list-style: none;
  border-left: 2px solid var(--hairline);
}

.timeline li {
  position: relative;
  padding: 0 0 36px 30px;
}
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 8px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2.5px solid var(--paper-tint);
}

.timeline h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.22rem;
}

.timeline-meta {
  font-size: 0.88rem;
  color: var(--muted);
  margin: 3px 0 10px;
}

.timeline li > p { font-size: 0.97rem; color: var(--ink-soft); }

.xp-aside { display: grid; gap: 36px; }

.aside-block h3 {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
  margin-bottom: 12px;
}

.aside-block p, .aside-block ul { font-size: 0.97rem; color: var(--ink-soft); }
.aside-block ul:not(.tags) { list-style: none; }
.aside-block ul:not(.tags) li { padding: 3px 0; }

.tags-loose { margin: 0; }

/* ---------- About ---------- */

.about-layout {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 64px;
  align-items: center;
}

.about-media img {
  border-radius: var(--radius);
  border: 1px solid var(--hairline);
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 62% center;
}

.about-body .section-title { margin-bottom: 28px; }
.about-body p {
  color: var(--ink-soft);
  margin-bottom: 16px;
  font-size: 1.05rem;
}

/* ---------- Contact ---------- */

.section-contact {
  background: var(--ink);
  color: var(--paper);
  padding: 100px 0;
}
.section-contact .section-title { color: #8F8B80; }
.section-contact .section-title::after { background: #37342C; }

.contact-lede {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.6rem, 4vw, 2.5rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
  margin-bottom: 36px;
}

.contact-email {
  color: #9CC5B0;
  border-bottom: 2px solid rgba(156, 197, 176, 0.35);
  transition: border-color 0.2s ease;
}
.contact-email:hover { color: #B8D8C7; border-bottom-color: #B8D8C7; }

.contact-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 32px;
}
.contact-links a {
  color: #C9C6BC;
  font-weight: 500;
  font-size: 1rem;
}
.contact-links a:hover { color: var(--paper); }

/* ---------- Footer ---------- */

.site-footer {
  background: var(--ink);
  color: #8F8B80;
  padding: 0 0 36px;
  font-size: 0.88rem;
}
.site-footer .container {
  border-top: 1px solid #37342C;
  padding-top: 28px;
}

/* ---------- Reveal animation ---------- */

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .project-card { transition: none; }
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .case,
  .about-layout {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .case:nth-child(odd) .case-media { order: 0; }
  .xp-layout { grid-template-columns: 1fr; gap: 56px; }
  .about-media { max-width: 420px; }
}

@media (max-width: 720px) {
  .hero { padding: 64px 0 56px; }
  .section { padding: 64px 0; }

  .nav-toggle { display: flex; }
  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    background: var(--paper);
    border-bottom: 1px solid var(--hairline);
    padding: 12px 24px 20px;
    box-shadow: var(--shadow);
  }
  .nav-menu.open { display: flex; }
  .nav-menu > a:not(.btn) {
    padding: 10px 0;
    font-size: 1.05rem;
    width: 100%;
  }
  .nav-menu .btn {
    margin-top: 12px;
    padding: 13px 26px;
    text-align: center;
  }

  .proof-bar { gap: 14px 28px; }
  .service-cta { padding: 28px 24px; }
}
