:root {
  color-scheme: light;
  --bg: #f4f7f5;
  --surface: #ffffff;
  --surface-strong: #e6efec;
  --text: #1f2524;
  --muted: #65706b;
  --line: rgba(31, 37, 36, 0.14);
  --accent: #b33f2f;
  --accent-strong: #7e2c23;
  --teal: #1f7568;
  --shadow: 0 24px 70px rgba(31, 37, 36, 0.12);
  --radius: 8px;
  --max: 1120px;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #111514;
  --surface: #1a201e;
  --surface-strong: #242b28;
  --text: #f4f1e8;
  --muted: #b7c0bb;
  --line: rgba(244, 241, 232, 0.15);
  --accent: #f06c55;
  --accent-strong: #ff9b84;
  --teal: #6ec6b6;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.32);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

body.nav-open {
  overflow: hidden;
}

a {
  color: inherit;
}

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: 1rem;
  z-index: 20;
  transform: translateY(-160%);
  background: var(--text);
  color: var(--bg);
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  padding: 0.85rem 0;
  backdrop-filter: blur(16px);
}

.site-header.is-scrolled {
  border-bottom: 1px solid var(--line);
}

.brand,
.site-nav,
.hero-actions,
.contact-actions,
.site-footer {
  display: flex;
  align-items: center;
}

.brand {
  gap: 0.7rem;
  text-decoration: none;
  font-weight: 750;
}

.brand-mark {
  display: grid;
  width: 2.35rem;
  height: 2.35rem;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--accent-strong);
  font-size: 0.78rem;
}

.site-nav {
  gap: 0.2rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  padding: 0.25rem;
}

.site-nav a {
  min-width: 4.5rem;
  padding: 0.55rem 0.75rem;
  border-radius: 6px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 650;
  text-align: center;
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a.is-active {
  background: var(--surface-strong);
  color: var(--text);
}

.theme-toggle {
  display: grid;
  width: 2.4rem;
  height: 2.4rem;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}

.hero {
  position: relative;
  min-height: 86vh;
  display: grid;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
  padding: clamp(7rem, 12vw, 10rem) 1rem 4rem;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(244, 247, 245, 0.94) 0%, rgba(244, 247, 245, 0.73) 42%, rgba(244, 247, 245, 0.18) 100%),
    linear-gradient(0deg, var(--bg) 0%, transparent 28%);
}

:root[data-theme="dark"] .hero::after {
  background:
    linear-gradient(90deg, rgba(17, 21, 20, 0.96) 0%, rgba(17, 21, 20, 0.76) 48%, rgba(17, 21, 20, 0.22) 100%),
    linear-gradient(0deg, var(--bg) 0%, transparent 38%);
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.hero-content,
.band,
.resume,
.metrics,
.site-footer {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
}

.hero-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(17rem, 25rem);
  gap: clamp(2rem, 7vw, 5rem);
  align-items: end;
  padding-bottom: clamp(1rem, 4vw, 3rem);
}

.eyebrow,
.section-kicker,
.timeline-meta {
  margin: 0 0 0.8rem;
  color: var(--accent-strong);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 11ch;
  margin-bottom: 1rem;
  font-size: clamp(4rem, 11vw, 9.2rem);
  line-height: 0.9;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: 1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0.65rem;
  font-size: 1.15rem;
  line-height: 1.25;
}

.hero-lede {
  max-width: 34rem;
  color: var(--muted);
  font-size: clamp(1.15rem, 2.4vw, 1.55rem);
}

.role-pill {
  display: inline-flex;
  align-items: center;
  min-height: 2.4rem;
  margin-bottom: 1.15rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  color: var(--accent-strong);
  padding: 0.45rem 0.85rem;
  font-size: 0.95rem;
  font-weight: 780;
}

.hero-actions,
.contact-actions {
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.6rem;
}

.profile-photo {
  margin: 0;
  justify-self: end;
}

.profile-photo img {
  width: min(100%, 25rem);
  aspect-ratio: 1;
  border: 1px solid color-mix(in srgb, var(--surface) 65%, var(--line));
  border-radius: 18px;
  box-shadow: var(--shadow);
  object-fit: cover;
}

.profile-photo figcaption {
  margin-top: 0.75rem;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  text-align: right;
}

.button {
  display: inline-flex;
  min-height: 2.9rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  font-weight: 760;
  text-decoration: none;
}

.button.primary {
  border-color: var(--accent);
  background: var(--accent);
  color: #fffdf8;
}

.button.secondary {
  background: color-mix(in srgb, var(--surface) 82%, transparent);
  color: var(--text);
}

.band,
.resume {
  padding: clamp(4rem, 9vw, 7rem) 0;
}

.intro-grid,
.section-heading,
.contact {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(18rem, 0.85fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.copy,
.section-heading p,
.contact p,
.timeline-item p {
  color: var(--muted);
}

.copy p:last-child,
.section-heading p:last-child,
.contact p:last-child,
.timeline-item p:last-child {
  margin-bottom: 0;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
  box-shadow: var(--shadow);
}

.metrics div {
  min-height: 9rem;
  background: var(--surface);
  padding: 1.35rem;
}

.metrics strong,
.metrics span {
  display: block;
}

.metrics strong {
  margin-bottom: 0.7rem;
  color: var(--teal);
  font-size: 1.35rem;
}

.metrics span {
  color: var(--muted);
}

.section-heading {
  margin-bottom: clamp(2rem, 5vw, 3.5rem);
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: -1.2rem 0 2rem;
}

.skill-tags span {
  display: inline-flex;
  min-height: 2.2rem;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  padding: 0.4rem 0.75rem;
  font-size: 0.9rem;
  font-weight: 700;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.card {
  min-height: 18rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  padding: 1.4rem;
}

.card-icon {
  display: inline-grid;
  width: 2.3rem;
  height: 2.3rem;
  place-items: center;
  margin-bottom: 2.3rem;
  border-radius: 50%;
  background: var(--surface-strong);
  color: var(--accent-strong);
  font-size: 0.75rem;
  font-weight: 800;
}

.card p {
  margin-bottom: 0;
  color: var(--muted);
}

.resume {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.timeline {
  display: grid;
  gap: 1rem;
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 2rem 1fr;
  gap: 1rem;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.timeline-dot {
  width: 0.85rem;
  height: 0.85rem;
  margin-top: 0.35rem;
  border: 3px solid var(--surface-strong);
  border-radius: 50%;
  background: var(--teal);
}

.timeline-company {
  margin-bottom: 0.5rem;
  color: var(--text);
  font-weight: 760;
}

.contact {
  align-items: center;
}

.contact h2 {
  margin-bottom: 0.85rem;
}

.site-footer {
  justify-content: space-between;
  gap: 1rem;
  padding: 2rem 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.site-footer p {
  margin: 0;
}

.site-footer a {
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 820px) {
  .site-header {
    width: calc(100% - 1rem);
  }

  .brand span:last-child {
    display: none;
  }

  .site-nav {
    order: 3;
    width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .site-header {
    flex-wrap: wrap;
  }

  .hero {
    min-height: 88vh;
    padding-top: 8rem;
  }

  .hero::after {
    background:
      linear-gradient(90deg, rgba(244, 247, 245, 0.97) 0%, rgba(244, 247, 245, 0.82) 72%, rgba(244, 247, 245, 0.52) 100%),
      linear-gradient(0deg, var(--bg) 0%, transparent 36%);
  }

  :root[data-theme="dark"] .hero::after {
    background:
      linear-gradient(90deg, rgba(17, 21, 20, 0.96) 0%, rgba(17, 21, 20, 0.78) 70%, rgba(17, 21, 20, 0.44) 100%),
      linear-gradient(0deg, var(--bg) 0%, transparent 36%);
  }

  h1 {
    font-size: clamp(3.6rem, 18vw, 5.8rem);
  }

  .hero-content {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .profile-photo {
    justify-self: start;
    width: min(78vw, 20rem);
  }

  .profile-photo figcaption {
    text-align: left;
  }

  .intro-grid,
  .section-heading,
  .contact,
  .metrics,
  .cards {
    grid-template-columns: 1fr;
  }

  .metrics div {
    min-height: 7rem;
  }
}

@media (max-width: 520px) {
  .site-nav a {
    min-width: 4.2rem;
    padding-inline: 0.6rem;
    font-size: 0.86rem;
  }

  .hero {
    padding-inline: 0.75rem;
  }

  .button {
    width: 100%;
  }

  .hero-actions,
  .contact-actions {
    align-items: stretch;
  }

  .timeline-item {
    grid-template-columns: 1fr;
  }

  .timeline-dot {
    display: none;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
