/* ---------------------------------------------------------
   Tokens
--------------------------------------------------------- */
:root {
  --navy: #0f1b2d;
  --navy-soft: #16263d;
  --charcoal: #2b303b;
  --ink: #1c2330;
  --paper: #ffffff;
  --paper-alt: #f5f6f8;
  --line: #e2e5ea;
  --muted: #5b6472;
  --accent: #a9822f;
  --accent-soft: #f3ead9;

  --font-display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --max-width: 1080px;
  --transition: 220ms ease;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

ul { margin: 0; padding: 0; list-style: none; }

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

/* ---------------------------------------------------------
   Header / Nav
--------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  color: var(--navy);
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
  transition: color var(--transition);
  position: relative;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--navy);
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width var(--transition);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--navy);
  transition: transform var(--transition), opacity var(--transition);
}

/* ---------------------------------------------------------
   Hero
--------------------------------------------------------- */
.hero {
  background: linear-gradient(180deg, var(--navy) 0%, var(--navy-soft) 100%);
  color: #fff;
  padding: 88px 0 96px;
}

.hero-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 64px;
  align-items: center;
}

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

.hero-text h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.4rem, 4.5vw, 3.4rem);
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}

.hero-headline {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  color: #d8dee8;
  font-weight: 500;
  margin: 0 0 24px;
}

.hero-positioning {
  font-size: 1.02rem;
  color: #b7c0cf;
  max-width: 46ch;
  margin: 0 0 36px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.hero-media {
  display: flex;
  justify-content: center;
}

.headshot {
  width: 100%;
  max-width: 300px;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 6px;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* ---------------------------------------------------------
   Buttons
--------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 28px;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: 3px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background var(--transition), color var(--transition), border-color var(--transition), transform var(--transition);
  white-space: nowrap;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--accent);
  color: #1a1406;
}

.btn-primary:hover { background: #bd9846; }

.btn-secondary {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
}

.btn-secondary:hover {
  border-color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

.contact .btn-primary {
  color: #1a1406;
}

/* ---------------------------------------------------------
   Sections
--------------------------------------------------------- */
.section {
  padding: 88px 0;
}

.section-alt {
  background: var(--paper-alt);
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--navy);
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 0 0 40px;
}

.section-num {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.05em;
}

/* Reveal-on-scroll */
.section-title,
.about-content p,
.timeline-item,
.pill,
.edu-col,
.contact-lead,
.contact-links,
#cvDownloadFooter {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 560ms ease, transform 560ms ease;
}

.is-visible {
  opacity: 1 !important;
  transform: none !important;
}

/* ---------------------------------------------------------
   About
--------------------------------------------------------- */
.about-content {
  max-width: 68ch;
}

.about-content p {
  font-size: 1.08rem;
  color: var(--charcoal);
  margin: 0 0 20px;
}

.about-content p:last-child { margin-bottom: 0; }

/* ---------------------------------------------------------
   Timeline
--------------------------------------------------------- */
.timeline {
  border-top: 1px solid var(--line);
}

.timeline-item {
  border-bottom: 1px solid var(--line);
}

.timeline-toggle {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  padding: 26px 4px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  text-align: left;
  font: inherit;
  color: inherit;
}

.timeline-dates {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.timeline-role {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 600;
  color: var(--navy);
  margin: 0 0 6px;
  line-height: 1.35;
}

.timeline-org {
  font-size: 0.92rem;
  color: var(--muted);
  margin: 0;
}

.chevron {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 6px;
  position: relative;
}

.chevron::before,
.chevron::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 9px;
  height: 1.5px;
  background: var(--navy);
  transition: transform var(--transition);
}

.chevron::before {
  right: 10px;
  transform: rotate(45deg);
}

.chevron::after {
  left: 10px;
  transform: rotate(-45deg);
}

.timeline-item.is-expanded .chevron::before { transform: rotate(-45deg); }
.timeline-item.is-expanded .chevron::after { transform: rotate(45deg); }

.timeline-detail {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 320ms ease;
}

.timeline-detail > ul {
  overflow: hidden;
  padding: 0 4px;
}

.timeline-item.is-expanded .timeline-detail {
  grid-template-rows: 1fr;
}

.timeline-detail li {
  position: relative;
  padding: 0 0 12px 20px;
  font-size: 0.97rem;
  color: var(--charcoal);
  max-width: 68ch;
}

.timeline-item.is-expanded .timeline-detail li {
  padding-top: 2px;
}

.timeline-detail li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.timeline-detail li:last-child { padding-bottom: 30px; }

.timeline-item.is-featured .timeline-role {
  font-size: 1.24rem;
}

/* ---------------------------------------------------------
   Skills / pills
--------------------------------------------------------- */
.pill-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.pill {
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--navy);
  background: var(--paper);
  transition: border-color var(--transition), background var(--transition);
}

.pill:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

/* ---------------------------------------------------------
   Education
--------------------------------------------------------- */
.edu-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}

.edu-heading {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin: 0 0 20px;
}

.edu-list li {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.edu-list li:last-child { margin-bottom: 0; }

.edu-degree {
  font-weight: 600;
  color: var(--navy);
  font-size: 0.97rem;
  line-height: 1.4;
}

.edu-school {
  font-size: 0.88rem;
  color: var(--muted);
}

.lang-list li {
  font-size: 0.97rem;
  color: var(--charcoal);
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
}

.lang-list li:last-child { border-bottom: none; }

/* ---------------------------------------------------------
   Contact
--------------------------------------------------------- */
.contact {
  background: var(--navy);
  color: #fff;
  text-align: center;
}

.contact .section-title {
  justify-content: center;
  color: #fff;
}

.contact-lead {
  color: #b7c0cf;
  font-size: 1.05rem;
  margin: 0 auto 40px;
  max-width: 50ch;
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.contact-link {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 36px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  min-width: 240px;
  transition: border-color var(--transition), background var(--transition);
}

.contact-link:hover {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.04);
}

.contact-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  font-weight: 700;
}

.contact-value {
  font-size: 1rem;
  font-weight: 500;
  color: #fff;
}

/* ---------------------------------------------------------
   Footer
--------------------------------------------------------- */
.site-footer {
  background: var(--navy);
  color: #7c8798;
  text-align: center;
  padding: 28px 0 40px;
  font-size: 0.82rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* ---------------------------------------------------------
   Responsive
--------------------------------------------------------- */
@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 40px;
  }

  .hero-positioning { margin-left: auto; margin-right: auto; }

  .hero-actions { justify-content: center; }

  .edu-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

@media (max-width: 720px) {
  .nav-toggle { display: flex; }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition);
  }

  .nav-links.is-open {
    max-height: 320px;
  }

  .nav-links a {
    display: block;
    padding: 16px 32px;
    border-bottom: 1px solid var(--line);
  }

  .section { padding: 64px 0; }

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

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
