/* =========================================================
   TOKENS
   ========================================================= */
:root {
  --navy: #0f1b2e;
  --navy-light: #16273f;
  --paper: #f7f5f1;
  --paper-dark: #efebe3;
  --ink: #1b2430;
  --steel: #5b6b7c;
  --steel-light: #8b98a6;
  --orange: #ff6b35;
  --orange-dark: #e8531f;
  --yellow: #ffc940;
  --green: #2c9a6b;
  --line: #dcd6c9;
  --line-dark: rgba(255, 255, 255, 0.14);

  --font-display: "Barlow Condensed", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  --max-width: 1080px;
  --radius-sm: 4px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

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

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.05;
  margin: 0;
  letter-spacing: 0.2px;
}

p {
  margin: 0 0 1em;
  color: var(--steel);
  max-width: 62ch;
}

a {
  color: inherit;
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--orange);
  outline-offset: 3px;
}

/* =========================================================
   HEADER / NAV
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 245, 241, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  background: var(--navy);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  border-radius: var(--radius-sm);
}

.brand-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  text-decoration: none;
  color: var(--steel);
  font-size: 15px;
  font-weight: 500;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
  transition:
    color 0.15s ease,
    border-color 0.15s ease;
}

.nav-link:hover {
  color: var(--ink);
}

.nav-link.is-active {
  color: var(--ink);
  border-bottom-color: var(--orange);
}

.nav-cta {
  background: var(--navy);
  color: var(--paper) !important;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  border-bottom: none !important;
}
.nav-cta:hover {
  background: var(--navy-light);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2px;
  width: 22px;
  background: var(--ink);
  margin: 0 auto;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}
.nav-toggle.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle.is-open span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* =========================================================
   HERO
   ========================================================= */
.hero {
  background: var(--navy);
  color: var(--paper);
  padding: 72px 0 48px;
  position: relative;
  overflow: hidden;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 48px;
  align-items: start;
}

.hero-main {
  min-width: 0;
}

.tracking-id {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--yellow);
  margin: 0 0 20px;
  text-transform: uppercase;
}

.hero-title {
  font-size: clamp(48px, 9vw, 92px);
  color: var(--paper);
  margin-bottom: 6px;
}

.hero-role {
  font-family: var(--font-display);
  font-size: clamp(20px, 3vw, 26px);
  color: var(--orange);
  font-weight: 600;
  margin: 0 0 20px;
}

.hero-tagline {
  color: #c4cdd8;
  font-size: 17px;
  max-width: 56ch;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.btn {
  display: inline-block;
  padding: 13px 26px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  border-radius: var(--radius-sm);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    transform 0.1s ease;
}
.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--orange);
  color: #17110c;
}
.btn-primary:hover {
  background: var(--orange-dark);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--paper);
  border-color: rgba(247, 245, 241, 0.35);
}
.btn-ghost:hover {
  border-color: var(--paper);
}

.btn-block {
  width: 100%;
  text-align: center;
}

/* Profile photo */
.hero-photo {
  position: relative;
  width: 220px;
  justify-self: end;
  transform: rotate(2deg);
}

.hero-photo img {
  width: 100%;
  height: auto;
  display: block;
  border: 6px solid var(--paper);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.4);
  border-radius: 2px;
}

.hero-photo-tag {
  position: absolute;
  bottom: -12px;
  left: 50%;
  transform: translateX(-50%) rotate(-2deg);
  background: var(--orange);
  color: #17110c;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  padding: 3px 10px;
  border-radius: 2px;
  letter-spacing: 0.5px;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

/* Route animation */
.route {
  grid-column: 1 / -1;
  max-width: 760px;
  margin-top: 12px;
}
.route-svg {
  width: 100%;
  height: auto;
  display: block;
}
.route-line {
  fill: none;
  stroke: rgba(247, 245, 241, 0.28);
  stroke-width: 2;
  stroke-dasharray: 6 8;
}
.route-node {
  fill: var(--paper);
}
.route-node--origin {
  fill: var(--yellow);
}
.route-node--dest {
  fill: var(--green);
}
.route-dot {
  fill: var(--orange);
}

.route-labels {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--steel-light);
  margin-top: 4px;
}

/* =========================================================
   SECTIONS (shared)
   ========================================================= */
.section {
  padding: 84px 0;
}
.section-alt {
  background: var(--paper-dark);
}

.section-title {
  font-size: clamp(28px, 4vw, 38px);
  margin-bottom: 12px;
  color: var(--ink);
}

.section-sub {
  color: var(--steel);
  margin-bottom: 40px;
  max-width: 60ch;
}

/* =========================================================
   ABOUT / STATS
   ========================================================= */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 56px;
  align-items: start;
}

.about-text p {
  font-size: 16px;
}

.stat-manifest {
  border-top: 1px solid var(--line);
  margin: 0;
}

.stat-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  gap: 16px;
}

.stat-row dt {
  font-size: 15px;
  color: var(--steel);
}

.stat-row dd {
  margin: 0;
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 600;
  color: var(--navy);
  white-space: nowrap;
}

/* =========================================================
   EXPERIENCE / CHECKPOINTS
   ========================================================= */
.checkpoints {
  list-style: none;
  margin: 0;
  padding: 0;
  position: relative;
}

.checkpoint {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 24px;
  padding-bottom: 44px;
  position: relative;
}

.checkpoint:last-child {
  padding-bottom: 0;
}

.checkpoint-marker {
  position: relative;
  display: flex;
  justify-content: center;
}

.checkpoint-marker::before {
  content: "";
  position: absolute;
  top: 22px;
  bottom: -44px;
  width: 1px;
  background: var(--line);
}

.checkpoint:last-child .checkpoint-marker::before {
  display: none;
}

.dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--orange);
  border: 3px solid var(--paper-dark);
  box-shadow: 0 0 0 1.5px var(--orange);
  z-index: 1;
}

.checkpoint-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.checkpoint-head h3 {
  font-size: 22px;
  color: var(--ink);
}

.badge {
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 3px 9px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-active {
  background: rgba(44, 154, 107, 0.14);
  color: var(--green);
}

.checkpoint-meta {
  font-size: 14px;
  color: var(--steel-light);
  margin: 6px 0 14px;
}

.checkpoint-list {
  margin: 0;
  padding-left: 18px;
  color: var(--ink);
}
.checkpoint-list li {
  margin-bottom: 6px;
  font-size: 15px;
}

/* =========================================================
   PROJECTS
   ========================================================= */
.project-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.project-card {
  background: var(--paper-dark);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 28px;
  display: flex;
  flex-direction: column;
}

.project-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.project-head h3 {
  font-size: 21px;
  color: var(--navy);
  max-width: 34ch;
}

.project-date {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--steel-light);
  white-space: nowrap;
}

.project-org {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--orange-dark);
  margin: 0 0 14px;
}

.project-card p {
  font-size: 15px;
  max-width: none;
}

.project-role {
  font-size: 14.5px;
  color: var(--ink);
  background: var(--paper);
  border-left: 3px solid var(--orange);
  padding: 12px 16px;
  margin: 4px 0 18px;
}
.project-role strong {
  color: var(--navy);
}

.project-card .chips {
  margin-top: auto;
}

@media (max-width: 860px) {
  .project-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   SKILLS
   ========================================================= */
.skill-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}

.skill-card {
  background: var(--paper);
  padding: 28px;
}

.skill-card h3 {
  font-size: 20px;
  margin-bottom: 16px;
  color: var(--navy);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  font-size: 13.5px;
  font-weight: 500;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--ink);
  background: var(--paper);
}

/* =========================================================
   CERTIFICATIONS / EDUCATION
   ========================================================= */
.cert-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
}

.cert-item {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}
.cert-item:last-child {
  border-bottom: none;
}

.cert-title {
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 4px;
  font-size: 16px;
}

.cert-org {
  margin: 0;
  color: var(--steel);
  font-size: 14px;
}

/* =========================================================
   CONTACT
   ========================================================= */
.contact-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
}

.contact-list {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
}

.contact-list li {
  display: flex;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}

.contact-list a {
  text-decoration: none;
  color: var(--ink);
  font-weight: 500;
}
.contact-list a:hover {
  color: var(--orange-dark);
}

.contact-label {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--steel-light);
  width: 90px;
  flex-shrink: 0;
  padding-top: 2px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--paper-dark);
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}

.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}

.contact-form input,
.contact-form textarea {
  font-family: var(--font-body);
  font-size: 15px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper);
  color: var(--ink);
  resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--orange);
}

.form-note {
  margin: 0;
  font-size: 13.5px;
  color: var(--green);
  min-height: 18px;
}

/* Photo Collage */
.contact-collage {
  display: flex;
  align-items: center;
  justify-content: center;
}

.collage-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  width: 100%;
  max-width: 300px;
}

.collage-item {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.collage-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer {
  background: var(--navy);
  color: var(--steel-light);
  padding: 28px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  flex-wrap: wrap;
  gap: 12px;
}

.back-top {
  text-decoration: none;
  color: var(--paper);
  font-weight: 500;
}
.back-top:hover {
  color: var(--orange);
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 860px) {
  .about-grid,
  .cert-grid,
  .contact-inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .skill-grid {
    grid-template-columns: 1fr;
  }
  .project-grid {
    grid-template-columns: 1fr;
  }

  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-photo {
    justify-self: center;
    order: -1;
    width: 160px;
    margin-bottom: 12px;
  }
}

@media (max-width: 720px) {
  .nav {
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    padding: 8px 24px 20px;
    gap: 4px;
    display: none;
  }
  .nav.is-open {
    display: flex;
  }
  .nav-link {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
  }
  .nav-cta {
    text-align: center;
    margin-top: 8px;
  }
  .nav-toggle {
    display: flex;
  }

  .checkpoint {
    grid-template-columns: 20px 1fr;
    gap: 16px;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 56px 0 36px;
  }
  .section {
    padding: 60px 0;
  }
}
