/* ===== Base ===== */
:root {
  --color-navy: #0f1b2d;
  --color-navy-soft: #1a2a44;
  --color-gold: #c9a227;
  --color-cream: #faf7f0;
  --color-ink: #23272f;
  --color-muted: #5c6470;
  --color-line: #e3ddd0;
  --color-card: #ffffff;
  --font-head: "Barlow Condensed", "Arial Narrow", sans-serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;
  --radius: 12px;
  --shadow: 0 10px 30px rgba(15, 27, 45, 0.08);
}

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

html { scroll-behavior: smooth; }

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

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

.container {
  width: min(1100px, 92%);
  margin-inline: auto;
}

/* ===== Header ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 27, 45, 0.96);
  backdrop-filter: blur(6px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.9rem;
}

.logo {
  font-family: var(--font-head);
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #fff;
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: 1.6rem;
}

.site-nav a {
  color: #cfd6e4;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  padding-block: 0.3rem;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: #fff;
  border-color: var(--color-gold);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 6px;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: #fff;
  transition: transform 0.25s, opacity 0.25s;
}

/* ===== Hero ===== */
.hero {
  /* soft blue glow rising out of a dark void: pale core falling off
     through lighter to deeper blues, dissolving to near-black at the edges */
  background:
    radial-gradient(ellipse 80% 65% at 50% 68%,
      rgba(200, 224, 255, 0.85) 0%,
      rgba(107, 159, 255, 0.5) 22%,
      rgba(27, 84, 201, 0.55) 42%,
      rgba(0, 31, 102, 0.8) 60%,
      #000033 100%);
  background-color: #000033;
  color: #fff;
  padding-block: clamp(4rem, 9vw, 7rem) clamp(3rem, 7vw, 5rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 3rem;
  align-items: center;
}

.eyebrow {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.95rem;
  color: var(--color-gold);
  margin-bottom: 0.75rem;
}

.hero h1 {
  font-family: var(--font-head);
  font-size: clamp(3rem, 7vw, 4.6rem);
  font-weight: 700;
  line-height: 1.05;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 1.1rem;
}

.hero-lede {
  font-size: 1.08rem;
  color: #dbe2ef;
  max-width: 54ch;
  margin-bottom: 2rem;
}

.hero-lede strong { color: #fff; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.btn {
  display: inline-block;
  padding: 0.7rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s;
}

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

.btn-primary {
  background: var(--color-gold);
  color: var(--color-navy);
}

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

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

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

.hero-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow);
}

/* Headshot photo (1:1, floating) with the bottle cap over its corner */
.hero-photo-wrap {
  position: relative;
  margin-bottom: 1.4rem;
}

.hero-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  overflow: hidden;
  border: 3px solid var(--color-gold);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.45);
  transform: translateY(-2px);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.hero-photo:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 42px rgba(0, 0, 0, 0.5);
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-photo svg,
.hero-photo span {
  display: block;
}

.hero-photo svg {
  width: 60px;
  height: 60px;
  fill: #9fb0cc;
}

.hero-photo span {
  font-family: var(--font-head);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #9fb0cc;
  margin-top: 0.6rem;
}

/* Placeholder state: center the silhouette */
.hero-photo:not(:has(img)) {
  display: grid;
  place-content: center;
  justify-items: center;
}

.hero-badge {
  position: absolute;
  right: -8px;
  bottom: -10px;
  width: 95px;
  height: 95px;
  margin: 0;
}

/* Fallback when no stat rows exist: float over the photo's corner */
.hero-photo-wrap .hero-badge {
  right: -12px;
  bottom: -30px;
}

/* First stat row anchors the badge */
.stat-first {
  position: relative;
}

.hero-badge-cap {
  display: block;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 5px 12px rgba(0, 0, 0, 0.45));
}

.hero-stats { list-style: none; }

.hero-stats li {
  display: flex;
  flex-direction: column;
  padding-block: 0.55rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-stats li:last-child { border-bottom: 0; }

.hero-stats span {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #9fb0cc;
}

.hero-stats strong {
  font-family: var(--font-head);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #fff;
}

/* ===== Sections ===== */
.section { padding-block: clamp(3.5rem, 7vw, 5.5rem); }

.section-alt { background: #fff; border-block: 1px solid var(--color-line); }

.section-title {
  font-family: var(--font-head);
  font-size: clamp(2rem, 4vw, 2.6rem);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-navy);
  margin-bottom: 2.2rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 56px;
  height: 4px;
  background: var(--color-gold);
  border-radius: 2px;
}

/* About */
.about-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.about-grid p { color: var(--color-muted); }

/* Skills */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.4rem;
}

.skill-card {
  background: var(--color-card);
  border: 1px solid var(--color-line);
  border-radius: var(--radius);
  padding: 1.5rem 1.6rem;
  box-shadow: var(--shadow);
}

.skill-card h3 {
  font-family: var(--font-head);
  font-size: 1.35rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-navy);
  margin-bottom: 0.75rem;
}

.skill-card ul {
  list-style: none;
  display: grid;
  gap: 0.35rem;
}

.skill-card li {
  position: relative;
  padding-left: 1.15rem;
  font-size: 0.95rem;
  color: var(--color-muted);
}

.skill-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--color-gold);
}

/* Experience timeline */
.timeline {
  position: relative;
  display: grid;
  gap: 2.2rem;
  padding-left: 1.75rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: var(--color-line);
}

.timeline-item { position: relative; }

.timeline-marker {
  position: absolute;
  left: -1.75rem;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--color-navy);
  border: 3px solid var(--color-gold);
}

.timeline-when {
  font-family: var(--font-head);
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--color-gold);
  margin-bottom: 0.2rem;
}

.timeline-content h3 {
  font-family: var(--font-head);
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-navy);
}

.timeline-org {
  font-weight: 600;
  color: var(--color-ink);
  margin-bottom: 0.7rem;
}

.timeline-details {
  list-style: none;
  display: grid;
  gap: 0.45rem;
  max-width: 75ch;
}

.timeline-details li {
  position: relative;
  padding-left: 1.15rem;
  color: var(--color-muted);
  font-size: 0.97rem;
}

.timeline-details li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--color-navy);
}

/* Education */
.edu-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.4rem;
}

.edu-card {
  background: var(--color-card);
  border-left: 4px solid var(--color-gold);
  border-radius: var(--radius);
  padding: 1.3rem 1.5rem;
  box-shadow: var(--shadow);
}

.edu-card h3 {
  font-family: var(--font-head);
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-navy);
  margin-bottom: 0.2rem;
}

.edu-meta { color: var(--color-muted); font-size: 0.92rem; }

/* Contact */
.contact {
  background:
    radial-gradient(800px 300px at 15% 110%, rgba(201, 162, 39, 0.15), transparent 60%),
    linear-gradient(160deg, var(--color-navy) 0%, var(--color-navy-soft) 100%);
  color: #fff;
}

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

.contact-lede { color: #cfd6e4; margin-bottom: 2rem; }

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

.contact-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius);
  padding: 1rem 1.3rem;
  text-decoration: none;
  color: #fff;
  transition: background 0.2s, border-color 0.2s;
}

.contact-item:hover,
.contact-item:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--color-gold);
}

.contact-item-static { cursor: default; }

.contact-item span {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #9fb0cc;
}

.contact-item strong { font-weight: 600; }

/* Footer */
.site-footer {
  background: #0b1421;
  color: #8fa0bd;
  padding-block: 1.4rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.88rem;
}

.footer-inner a {
  color: var(--color-gold);
  text-decoration: none;
}

.footer-inner a:hover { text-decoration: underline; }

/* ===== Responsive ===== */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; gap: 1.2rem; }
  .skills-grid { grid-template-columns: 1fr; }
  .edu-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}

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

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--color-navy);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    padding: 1rem 4%;
    display: none;
  }

  .site-nav.open { display: flex; }

  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

/* ===== Print ===== */
@media print {
  .site-header, .hero-actions, .site-footer, .nav-toggle { display: none; }

  body { background: #fff; color: #000; }

  .hero {
    background: none;
    color: #000;
    padding-block: 1rem;
  }

  .hero h1, .hero-lede, .hero-lede strong { color: #000; }

  .hero-card { display: none; }

  .section, .section-alt {
    padding-block: 1.2rem;
    background: #fff;
    border: 0;
  }

  .section-title { color: #000; font-size: 1.4rem; margin-bottom: 1rem; }

  .skill-card, .edu-card, .contact-item {
    box-shadow: none;
    border-color: #999;
    background: #fff;
    break-inside: avoid;
  }

  .timeline::before, .timeline-marker { display: none; }
  .timeline { padding-left: 0; gap: 1rem; }
  .timeline-item { break-inside: avoid; }

  .contact { background: none; color: #000; }
  .contact .section-title, .contact-item, .contact-item strong { color: #000; }
  .contact-lede { color: #444; }

  a { text-decoration: none; color: #000; }
}
