/* ============================================================
   Russ Gohl — personal site
   Minimal, monochrome, text-forward. Hand-written (no framework).
   ============================================================ */

:root {
  --bg: #fafafa;
  --text: #111;
  --muted: #5e5e5e;
  --border: #e3e2e2;
  --hover: #f1f1f1;
  --invert-bg: #111;
  --invert-text: #fafafa;
  --nav-bg: rgba(250, 250, 250, 0.8);
  --max: 680px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111;
    --text: #efefef;
    --muted: #c6c6c6;
    --border: #2a2a2a;
    --hover: #1b1b1b;
    --invert-bg: #efefef;
    --invert-text: #111;
    --nav-bg: rgba(17, 17, 17, 0.8);
  }
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Source Serif 4", Georgia, "Times New Roman", serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--text);
  color: var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}
a:hover { text-decoration: underline; }

.material-symbols-outlined {
  font-family: "Material Symbols Outlined";
  font-weight: normal;
  font-style: normal;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  display: inline-block;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "liga";
}

/* utility for the Hanken Grotesk (sans) face */
.sans {
  font-family: "Hanken Grotesk", system-ui, -apple-system, sans-serif;
}

/* ---------------- Nav ---------------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--nav-bg);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.9rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
}
.brand:hover { text-decoration: none; opacity: 0.7; }
.nav-links {
  display: flex;
  gap: 1.1rem;
  flex-wrap: wrap;
}
.nav-link {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
  transition: color 0.2s ease;
}
.nav-link:hover { color: var(--text); text-decoration: none; }
.nav-link.active { color: var(--text); }

/* ---------------- Layout ---------------- */
.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 1rem;
}

/* ---------------- Hero ---------------- */
.hero {
  padding: 2rem 0 1.5rem;
}
.hero-name {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 600;
  font-size: 3rem;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
}
.hero-tagline {
  font-size: 1.25rem;
  margin: 0 0 0.6rem;
  max-width: 32ch;
}
.hero-location {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

/* ---------------- Sections ---------------- */
.section {
  padding: 2.75rem 0;
  border-top: 1px solid var(--border);
  scroll-margin-top: 90px;
}
.section-label {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--muted);
  margin: 0 0 1.25rem;
}
.lead { margin: 0 0 1.25rem; }

.more-link {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  display: inline-block;
  margin-top: 0.5rem;
  color: var(--muted);
}
.more-link:hover { color: var(--text); }

/* ---------------- Talents ---------------- */
.talent-list {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  columns: 2;
  column-gap: 2.5rem;
}
.talent-list li {
  padding: 0.3rem 0;
  break-inside: avoid;
}
.talent-list li::before {
  content: "·";
  margin-right: 0.65rem;
  color: var(--muted);
}
.talent-note { margin: 0; }

/* ---------------- Timeline ---------------- */
.timeline {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0 0 0 1.5rem;
  border-left: 1px solid var(--border);
}
.timeline-item {
  position: relative;
  padding: 0 0 1.6rem;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: "";
  position: absolute;
  left: calc(-1.5rem - 5px);
  top: 0.5rem;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--text);
}
.timeline-date {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 0.2rem;
}
.timeline-event {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 500;
  font-size: 1.05rem;
}

/* ---------------- Projects ---------------- */
.projects {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.project-card {
  border: 1px solid var(--border);
  padding: 1.5rem;
  cursor: pointer;
  transition: background 0.2s ease;
}
.project-card:hover { background: var(--hover); }
.project-card:focus-visible {
  outline: 2px solid var(--muted);
  outline-offset: 2px;
}
.project-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.project-title {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 600;
  font-size: 1.15rem;
  margin: 0 0 0.35rem;
}
.project-summary {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}
.project-chevron {
  font-size: 1.4rem;
  color: var(--muted);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}
.project-card.expanded .project-chevron { transform: rotate(180deg); }
.project-detail {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}
.project-card.expanded .project-detail { max-height: 420px; }
.project-detail-inner {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}
.project-detail-inner p { margin: 0 0 0.75rem; }
.project-detail-inner p:last-child { margin-bottom: 0; }
.project-link {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  border-bottom: 1px solid currentColor;
}
.project-link:hover { text-decoration: none; opacity: 0.7; }

/* ---------------- Contact ---------------- */
.contact-list {
  list-style: none;
  padding: 0;
  margin: 0 0 0.5rem;
}
.contact-list li { margin-bottom: 0.4rem; }
.contact-link { border-bottom: 1px solid currentColor; }
.contact-link:hover { text-decoration: none; opacity: 0.7; }

/* ---------------- Ask AI ---------------- */
.ask-ai {
  margin: 3rem 0 0;
  padding: 1.5rem;
  border: 1px solid var(--border);
  background: var(--invert-bg);
  color: var(--invert-text);
}
.ask-ai-label {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.68rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  opacity: 0.7;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 0.9rem;
}
.ask-ai-label .material-symbols-outlined { font-size: 1rem; }
.ask-ai-prompt {
  font-style: italic;
  margin: 0 0 1.1rem;
  opacity: 0.92;
  font-size: 0.98rem;
}
.ask-ai-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}
/* Provider buttons — understated, native to the monochrome palette. */
.ai-btn {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--invert-text);
  background: transparent;
  border: 1px solid var(--invert-text);
  opacity: 0.78;
  padding: 0.45rem 0.85rem;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  transition: opacity 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.ai-btn:hover,
.ai-btn:focus-visible {
  opacity: 1;
  background: var(--invert-text);
  color: var(--invert-bg);
  text-decoration: none;
  outline: none;
}
.ai-copy {
  margin-left: auto;
  opacity: 0.55;
}
.ai-copy:hover,
.ai-copy:focus-visible { opacity: 1; }

/* ---------------- Footer ---------------- */
.footer {
  border-top: 1px solid var(--border);
  margin-top: 3rem;
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2rem 1.5rem 3rem;
  text-align: center;
  color: var(--muted);
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
}

/* ---------------- Sub-page bits ---------------- */
.back-link {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  display: inline-block;
  margin: 0.5rem 0 2.25rem;
}
.back-link:hover { color: var(--text); text-decoration: none; }
.page-title {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 600;
  font-size: 2.25rem;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin: 0 0 1.5rem;
}
.page-body p { margin: 0 0 1.15rem; }
.page-body .talent-list,
.page-body .timeline { margin-top: 1.5rem; }
.subpage-project-title {
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 600;
  font-size: 1.25rem;
  margin: 0 0 0.5rem;
}
article.page-body + article.page-body { margin-top: 1.75rem; }
.page-note {
  margin-top: 2.5rem;
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

/* ---------------- Responsive ---------------- */
@media (max-width: 560px) {
  .nav-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.55rem;
  }
  .nav-links { gap: 0.85rem; }
  .nav-link { font-size: 0.65rem; letter-spacing: 0.1em; }
  .hero-name { font-size: 2.25rem; }
  .talent-list { columns: 1; }
  .page-title { font-size: 1.85rem; }
}
