/* ==========================================================================
   Portfolio stylesheet
   1. Tokens  2. Base  3. Layout & type  4. Header  5. Buttons
   6. Hero  7. Topology panel  8. Ticker  9. Stats  10. About
   11. Bento & cards  12. Experience  13. Certifications  14. Contact
   15. Footer  16. Motion  17. Utilities
   ========================================================================== */

/* 1. Tokens
   ========================================================================== */
:root {
  --bg: #07080b;
  --bg-2: #0b0d12;
  --card: #0d1016;
  --card-2: #11151d;
  --border: rgba(255, 255, 255, 0.07);
  --border-2: rgba(255, 255, 255, 0.13);
  --text: #f3f5f9;
  --text-2: #a3aab8;
  --text-3: #7d8494; /* 4.8:1 or better on every surface (WCAG AA) */
  --accent: #6d9eff;
  --accent-2: #9dbdff;
  --accent-glow: rgba(109, 158, 255, 0.16);
  --green: #4ade80;

  --sans: "Inter", "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system,
    BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Cascadia Code", Menlo, Consolas, monospace;

  --fs-sm: 0.875rem;
  --fs-md: 1.0625rem;
  --fs-lg: clamp(1.0625rem, 0.95rem + 0.5vw, 1.25rem);
  --fs-xl: clamp(1.25rem, 1.05rem + 0.8vw, 1.625rem);
  --fs-h2: clamp(2rem, 1.3rem + 3vw, 3.5rem);
  --fs-hero: clamp(2.6rem, 1.4rem + 5vw, 5.25rem);

  --max: 76rem;
  --gutter: clamp(1.25rem, 0.6rem + 3vw, 2.5rem);
  --section: clamp(4rem, 2.5rem + 4.5vw, 6.5rem);
  --header-h: 4.25rem;
  --radius: 16px;
  --radius-sm: 10px;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* 2. Base
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 1.5rem);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  flex: 1 0 auto;
}

h1,
h2,
h3,
h4,
p,
ul,
ol,
dl,
dd,
figure,
blockquote {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

h1,
h2,
h3,
h4 {
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

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

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

button {
  font: inherit;
  color: inherit;
}

::selection {
  background: var(--accent);
  color: #05070b;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

/* 3. Layout & type
   ========================================================================== */
.container {
  width: 100%;
  max-width: calc(var(--max) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  position: relative;
  padding-block: var(--section);
}

.section-head {
  display: grid;
  gap: 1.1rem;
  max-width: 46rem;
  margin-bottom: clamp(2.75rem, 2rem + 3vw, 4.5rem);
}

.section-head--center {
  margin-inline: auto;
  text-align: center;
  justify-items: center;
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--accent-2);
}

.kicker__num {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--text-3);
}

.kicker__num::after {
  content: "";
  display: inline-block;
  width: 1.75rem;
  height: 1px;
  margin-left: 0.6rem;
  vertical-align: middle;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.h2 {
  font-size: var(--fs-h2);
  line-height: 1.06;
  letter-spacing: -0.035em;
}

/* Subtle vertical fade on large headings */
.grad {
  background: linear-gradient(180deg, #ffffff 30%, #a7afbe 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.sub {
  font-size: var(--fs-lg);
  line-height: 1.6;
  color: var(--text-2);
}

/* 4. Header
   ========================================================================== */
.skip-link {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 100;
  padding: 0.7rem 1rem;
  border-radius: 8px;
  background: var(--text);
  color: var(--bg);
  font-weight: 600;
  transform: translateY(-250%);
}

.skip-link:focus {
  transform: none;
}

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  transition: background-color 300ms var(--ease), border-color 300ms var(--ease);
  border-bottom: 1px solid transparent;
}

.header.is-scrolled {
  background: rgba(7, 8, 11, 0.94);
  border-bottom-color: var(--border);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border: 1px solid var(--border-2);
  border-radius: 9px;
  background: linear-gradient(180deg, #161b25, #0c0f15);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* Keep the full name and the menu button side by side on small phones. */
@media (max-width: 23.99em) {
  .header__inner {
    gap: 0.75rem;
  }

  .brand {
    gap: 0.55rem;
    font-size: 0.9375rem;
  }
}

.nav__list {
  display: flex;
  flex-direction: column;
}

.nav__link {
  display: block;
  color: var(--text-2);
  transition: color 200ms var(--ease), background-color 200ms var(--ease);
}

.nav__link:hover,
.nav__link.is-active {
  color: var(--text);
}

.header .header__cta {
  display: none;
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-right: -0.4rem;
  border: 0;
  background: none;
  cursor: pointer;
}

.nav-toggle__bars {
  position: relative;
  width: 1.2rem;
  height: 0.6rem;
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 1.5px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 250ms var(--ease), top 250ms var(--ease);
}

.nav-toggle__bars::before {
  top: 0;
}

.nav-toggle__bars::after {
  top: calc(100% - 1.5px);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before,
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after {
  top: calc(50% - 0.75px);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before {
  transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after {
  transform: rotate(-45deg);
}

@media (max-width: 55.99em) {
  .nav {
    position: fixed;
    inset: var(--header-h) 0 0;
    padding: 1rem var(--gutter) 2rem;
    background: var(--bg);
    border-top: 1px solid var(--border);
    visibility: hidden;
    opacity: 0;
    transition: opacity 250ms var(--ease), visibility 0s linear 250ms;
  }

  .nav.is-open {
    visibility: visible;
    opacity: 1;
    transition-delay: 0s;
  }

  .nav__link {
    padding-block: 1rem;
    border-bottom: 1px solid var(--border);
    font-size: 1.5rem;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--text);
  }

  body.nav-open {
    overflow: hidden;
  }
}

@media (min-width: 56em) {
  .nav-toggle {
    display: none;
  }

  .nav {
    padding: 0.3rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: rgba(13, 16, 22, 0.7);
  }

  .nav__list {
    flex-direction: row;
    gap: 0.15rem;
  }

  .nav__link {
    padding: 0.42rem 0.95rem;
    border-radius: 999px;
    font-size: var(--fs-sm);
  }

  .nav__link:hover {
    background: rgba(255, 255, 255, 0.05);
  }

  .nav__link.is-active {
    background: rgba(255, 255, 255, 0.08);
  }

  .header .header__cta {
    display: inline-flex;
  }
}

/* 5. Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  height: 2.9rem;
  padding: 0 1.3rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.9375rem;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 200ms var(--ease), border-color 200ms var(--ease),
    transform 200ms var(--ease), box-shadow 200ms var(--ease);
}

.btn--primary {
  background: var(--text);
  color: #07080b;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.1), 0 8px 30px -10px rgba(109, 158, 255, 0.55);
}

.btn--primary:hover {
  background: #ffffff;
  transform: translateY(-1px);
}

.btn--ghost {
  border-color: var(--border-2);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.05);
}

.btn--sm {
  height: 2.35rem;
  padding: 0 1rem;
  font-size: var(--fs-sm);
}

.btn svg {
  width: 1rem;
  height: 1rem;
  transition: transform 200ms var(--ease);
}

.btn:hover svg {
  transform: translateX(2px);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* 6. Hero
   ========================================================================== */
.hero {
  position: relative;
  padding-top: clamp(3rem, 1.5rem + 6vw, 7rem);
  padding-bottom: clamp(4rem, 2rem + 5vw, 7rem);
  isolation: isolate;
  overflow-x: clip;
}

/* Fine grid with a soft light, fading out at the edges */
.hero::before {
  content: "";
  position: absolute;
  inset: calc(var(--header-h) * -1) 0 0;
  z-index: -1;
  background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
}

.hero::after {
  content: "";
  position: absolute;
  top: -12rem;
  left: 50%;
  z-index: -1;
  width: min(70rem, 120vw);
  height: 36rem;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, var(--accent-glow), transparent);
  pointer-events: none;
}

.hero__grid {
  display: grid;
  gap: clamp(3rem, 2rem + 3vw, 4.5rem);
  align-items: center;
}

@media (min-width: 64em) {
  .hero__grid {
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  }
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0.85rem 0.35rem 0.6rem;
  border: 1px solid var(--border-2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.8125rem;
  color: var(--text-2);
}

.identity {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.35rem 1.1rem 0.35rem 0.35rem;
  border: 1px solid var(--border-2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
}

.identity__photo {
  position: relative;
  flex: none;
}

.identity__photo img {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 1px var(--border-2);
}

.identity__dot {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 0.7rem;
  height: 0.7rem;
  border: 2px solid var(--bg);
  border-radius: 50%;
  background: var(--green);
}

.identity__text {
  display: grid;
  line-height: 1.3;
}

.identity__text strong {
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.identity__text span {
  font-size: 0.8125rem;
  color: var(--text-2);
}

.pulse {
  position: relative;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
}

.pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--green);
  opacity: 0.6;
}

.hero__title {
  margin-top: 1.5rem;
  font-size: var(--fs-hero);
  line-height: 1.02;
  letter-spacing: -0.045em;
}

.hero__title .accent {
  background: linear-gradient(90deg, #ffffff 0%, var(--accent-2) 55%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero__lede {
  margin-top: 1.5rem;
  max-width: 34rem;
  font-size: var(--fs-lg);
  color: var(--text-2);
}

.hero__lede strong {
  color: var(--text);
  font-weight: 500;
}

.hero .btn-row {
  margin-top: 2.25rem;
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-top: 2.5rem;
  font-size: var(--fs-sm);
  color: var(--text-3);
}

.hero__meta li {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.hero__meta svg {
  width: 1rem;
  height: 1rem;
  color: var(--accent);
}

/* 7. Topology panel
   ========================================================================== */
.panel {
  position: relative;
  border: 1px solid var(--border-2);
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(20, 25, 35, 0.9), rgba(10, 12, 17, 0.95));
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.panel__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--text-3);
}

.panel__title {
  color: var(--text-2);
}

.panel__state {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.panel__state .pulse {
  width: 6px;
  height: 6px;
}

.topology {
  width: 100%;
  height: auto;
}

.topo-link {
  fill: none;
  stroke: rgba(255, 255, 255, 0.13);
  stroke-width: 1.2;
}

.topo-link--accent {
  stroke: rgba(109, 158, 255, 0.45);
}

.topo-node rect {
  fill: #121722;
  stroke: rgba(255, 255, 255, 0.14);
  stroke-width: 1;
}

.topo-node--core rect {
  fill: #141c2c;
  stroke: rgba(109, 158, 255, 0.65);
}

.topo-node text {
  fill: #e9edf4;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.topo-node .topo-sub {
  fill: #7d8597;
  font-family: var(--mono);
  font-size: 9.5px;
  font-weight: 400;
  letter-spacing: 0;
}

.topo-dot {
  fill: var(--green);
}

.topo-packet {
  fill: var(--accent-2);
}

.topo-ring {
  fill: none;
  stroke: rgba(109, 158, 255, 0.35);
}

.panel__foot {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 0.7rem;
}

.panel__foot div {
  display: grid;
  gap: 0.2rem;
  padding: 0.8rem 1.1rem;
}

.panel__foot div + div {
  border-left: 1px solid var(--border);
}

.panel__foot span {
  color: var(--text-3);
}

.panel__foot strong {
  font-weight: 500;
  color: var(--green);
}

/* 8. Ticker
   ========================================================================== */
.ticker {
  position: relative;
  padding-block: 1.6rem;
  border-block: 1px solid var(--border);
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.ticker__track {
  display: flex;
  width: max-content;
}

.ticker__list {
  display: flex;
  flex: none;
  align-items: center;
  gap: 3.25rem;
  padding-right: 3.25rem;
  font-size: 1.0625rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--text-3);
  white-space: nowrap;
}

.ticker__list li {
  display: inline-flex;
  align-items: center;
  gap: 3.25rem;
}

.ticker__list li::after {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--border-2);
}

/* 9. Stats
   ========================================================================== */
.stats {
  display: grid;
  gap: 1rem;
}

@media (min-width: 48em) {
  .stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.stat {
  padding: clamp(1.5rem, 1.1rem + 1.4vw, 2.25rem);
}

.stat__value {
  font-size: clamp(2.75rem, 1.8rem + 3.6vw, 4.5rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.05em;
  font-variant-numeric: tabular-nums;
}

.stat__label {
  margin-top: 0.9rem;
  color: var(--text-2);
}

/* 10. About
   ========================================================================== */
.about {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 48em) {
  .about {
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.4fr);
  }

  .about__side {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.portrait {
  position: relative;
  aspect-ratio: 4 / 5;
}

@media (min-width: 48em) {
  .portrait {
    min-height: 28rem;
    aspect-ratio: auto;
  }
}

.portrait img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 20%;
  filter: saturate(0.82) contrast(1.06) brightness(0.92);
}

/* Fade the photo into the card so the caption stays legible */
.portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    /* Spotlight on the subject, background falls away into the card */
    radial-gradient(ellipse 62% 55% at 50% 34%, rgba(7, 8, 11, 0) 40%, rgba(7, 8, 11, 0.62) 100%),
    linear-gradient(180deg, rgba(7, 8, 11, 0.35) 0%, rgba(7, 8, 11, 0) 22%),
    linear-gradient(180deg, rgba(7, 8, 11, 0) 48%, rgba(7, 8, 11, 0.6) 72%, rgba(7, 8, 11, 0.96) 100%),
    linear-gradient(180deg, rgba(109, 158, 255, 0.08), rgba(109, 158, 255, 0.02));
}

.portrait__caption {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  gap: 0.2rem;
  padding: clamp(1.25rem, 1rem + 1vw, 1.75rem);
}

.portrait__caption strong {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.portrait__caption span {
  font-size: var(--fs-sm);
  color: var(--text-2);
}

.about__story {
  display: grid;
  gap: 1.25rem;
  align-content: center;
  padding: clamp(1.75rem, 1.2rem + 2vw, 3rem);
}

.about__lead {
  font-size: var(--fs-xl);
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text);
}

.about__story p:not(.about__lead) {
  color: var(--text-2);
}

.about__side {
  display: grid;
  gap: 1.25rem;
  align-content: start;
}

.facts-list {
  padding: 0.5rem clamp(1.5rem, 1.1rem + 1vw, 2rem);
}

.facts-list div {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 1rem;
  border-bottom: 1px solid var(--border);
  font-size: var(--fs-sm);
}

.facts-list div:last-child {
  border-bottom: 0;
}

.facts-list dt {
  color: var(--text-3);
}

.facts-list dd {
  text-align: right;
  color: var(--text);
  font-weight: 500;
  text-wrap: balance;
}

/* Small phones: label above value so longer values stay readable */
@media (max-width: 29.99em) {
  .facts-list div {
    flex-direction: column;
    gap: 0.2rem;
  }

  .facts-list dd {
    text-align: left;
  }
}

.quote {
  padding: clamp(1.5rem, 1.1rem + 1vw, 2rem);
}

.quote__mark {
  width: 1.75rem;
  height: 1.75rem;
  color: var(--accent);
}

.quote p {
  margin-top: 1rem;
  font-size: 1.1875rem;
  line-height: 1.45;
  letter-spacing: -0.015em;
}

.quote figcaption {
  margin-top: 1.1rem;
  font-size: var(--fs-sm);
  color: var(--text-3);
}

/* 11. Bento & cards
   ========================================================================== */
.card {
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  overflow: hidden;
  isolation: isolate;
  transition: border-color 300ms var(--ease), transform 300ms var(--ease);
}

/* Light that follows the cursor (position set from JS) */
.card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(
    420px circle at var(--mx, 50%) var(--my, -20%),
    rgba(109, 158, 255, 0.1),
    transparent 45%
  );
  opacity: 0;
  transition: opacity 300ms var(--ease);
}

.card:hover {
  border-color: var(--border-2);
}

.card:hover::before {
  opacity: 1;
}

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

@media (min-width: 44em) {
  .bento {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 64em) {
  .bento {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  /* Rows: 4 + 2, 2 + 4, 3 + 3 */
  .bento > :nth-child(1),
  .bento > :nth-child(4) {
    grid-column: span 4;
  }

  .bento > :nth-child(2),
  .bento > :nth-child(3) {
    grid-column: span 2;
  }

  .bento > :nth-child(5),
  .bento > :nth-child(6) {
    grid-column: span 3;
  }
}

.feature {
  display: grid;
  gap: 1rem;
  align-content: start;
  padding: clamp(1.5rem, 1.1rem + 1.2vw, 2.1rem);
}

.icon {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--border-2);
  border-radius: 12px;
  background: linear-gradient(180deg, #171d29, #0f131a);
  color: var(--accent-2);
}

.icon svg {
  width: 1.3rem;
  height: 1.3rem;
}

.feature__title {
  margin-top: 0.5rem;
  font-size: 1.1875rem;
  letter-spacing: -0.02em;
}

.feature__text {
  color: var(--text-2);
  font-size: 0.9625rem;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.4rem;
}

.chip {
  padding: 0.3rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.025);
  font-size: 0.78rem;
  color: var(--text-2);
  white-space: nowrap;
}

/* 12. Experience
   ========================================================================== */
.xp {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 64em) {
  .xp {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  }
}

.card__label {
  margin-bottom: 1.75rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.work {
  display: grid;
  gap: 1.25rem;
}

.work__item {
  display: grid;
  gap: 0.6rem;
  align-content: start;
  padding: clamp(1.5rem, 1.2rem + 1vw, 2rem);
}

.work__metric {
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.035em;
  color: var(--accent-2);
  font-variant-numeric: tabular-nums;
}

.work__metric span {
  margin-left: 0.35rem;
  font-size: 0.8125rem;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--text-3);
}

.work__title {
  font-size: 1.125rem;
  letter-spacing: -0.015em;
}

.work__text {
  color: var(--text-2);
  font-size: 0.9625rem;
}

.work .chips {
  margin-top: 0.4rem;
}

.work__figure {
  margin: 0.5rem 0 0;
}

.work__shot {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid var(--border-2);
  border-radius: 0.75rem;
  background: #0a0d14;
}

.work__shot img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.4s var(--ease);
}

.work__zoom {
  position: absolute;
  right: 0.6rem;
  bottom: 0.6rem;
  padding: 0.3rem 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(10, 13, 20, 0.85);
  font-size: 0.75rem;
  color: var(--text);
}

.work__shot:hover img,
.work__shot:focus-visible img {
  transform: scale(1.03);
}

.work__shot:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  .work__shot img {
    transition: none;
  }
}

.timeline {
  position: relative;
  padding: clamp(1.75rem, 1.2rem + 2vw, 2.75rem);
}

.timeline__list {
  position: relative;
  display: grid;
  gap: 2rem;
}

.timeline__list::before {
  content: "";
  position: absolute;
  top: 0.5rem;
  bottom: 0.5rem;
  left: 0.4rem;
  width: 1px;
  background: linear-gradient(180deg, var(--accent), rgba(109, 158, 255, 0.05));
}

.timeline__item {
  position: relative;
  padding-left: 2.25rem;
}

.timeline__item::before {
  content: "";
  position: absolute;
  top: 0.4rem;
  left: 0;
  width: 0.85rem;
  height: 0.85rem;
  border: 2px solid var(--accent);
  border-radius: 50%;
  background: var(--bg);
}

.timeline__phase {
  margin-bottom: 0.3rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--accent);
}

.timeline__title {
  font-size: 1.125rem;
  letter-spacing: -0.015em;
}

.timeline__text {
  margin-top: 0.35rem;
  color: var(--text-2);
  font-size: 0.9625rem;
}

/* 13. Certifications
   ========================================================================== */
.certs {
  display: grid;
  gap: 1rem;
}

@media (min-width: 44em) {
  .certs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 64em) {
  .certs {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.cert {
  display: grid;
  gap: 1.1rem;
  align-content: start;
  padding: 1.6rem;
}

.cert__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.cert__badge {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border: 1px solid var(--border-2);
  border-radius: 50%;
  background: radial-gradient(circle at 30% 25%, #1d2636, #0d1118);
  color: var(--accent-2);
}

.cert__badge svg {
  width: 1.35rem;
  height: 1.35rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 500;
  background: rgba(74, 222, 128, 0.1);
  color: var(--green);
}

.tag--progress {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-2);
}

.cert__name {
  font-size: 1.125rem;
  letter-spacing: -0.015em;
}

.cert__issuer {
  margin-top: 0.25rem;
  color: var(--text-2);
  font-size: var(--fs-sm);
}

.cert__issuer-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-width: 3rem;
  height: 2rem;
  padding-inline: 0.7rem;
  border: 1px solid var(--border-2);
  border-radius: 8px;
  background: linear-gradient(180deg, #161b25, #0d1118);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--text);
}

.cert .cert__name {
  min-height: 2.8em;
  line-height: 1.4;
}

.cert__foot {
  display: flex;
  justify-content: space-between;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  font-size: var(--fs-sm);
  color: var(--text-3);
}

.cert__foot span:last-child {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--text-2);
}

/* Issuer logos: official colours and proportions, shown at a fixed height */
.cert__logo {
  width: auto;
  height: 0.95rem;
}

/* The AWS mark is a stacked wordmark, so it needs more height to read at the same size */
.cert__logo--aws {
  height: 1.3rem;
}

.cred__logo--aws {
  height: 1.05rem;
}

.cred__issuer {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.cred__logo {
  width: auto;
  height: 0.8rem;
}

/* Issuer summary */
.issuers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.issuers li {
  display: grid;
  gap: 0.2rem;
  padding: 1.25rem 1.5rem;
}

.issuers li:nth-child(n + 3) {
  border-top: 1px solid var(--border);
}

.issuers li:nth-child(even) {
  border-left: 1px solid var(--border);
}

.issuers strong {
  font-size: 1.75rem;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.03em;
}

.issuers span {
  font-size: var(--fs-sm);
  color: var(--text-2);
}

@media (min-width: 48em) {
  .issuers {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .issuers li:nth-child(n + 3) {
    border-top: 0;
  }

  .issuers li + li {
    border-left: 1px solid var(--border);
  }
}

/* Full credential list */
.creds {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

@media (min-width: 56em) {
  .creds {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.creds__group {
  padding: clamp(1.5rem, 1.2rem + 1vw, 2rem);
}

.creds__head {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 0.75rem;
}

.creds__head h3 {
  font-size: 1.125rem;
  letter-spacing: -0.015em;
}

.cred {
  display: grid;
  gap: 0.2rem;
  padding-block: 0.9rem;
  border-top: 1px solid var(--border);
}

.cred:first-child {
  border-top: 0;
}

.cred__name {
  font-size: 0.9625rem;
  font-weight: 500;
  color: var(--text);
}

.cred__course {
  display: inline-block;
  margin-left: 0.4rem;
  padding: 0.05rem 0.45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.6875rem;
  font-weight: 500;
  color: var(--text-2);
  vertical-align: 0.1em;
}

.cred__meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.8125rem;
  color: var(--text-3);
}

.cred__year {
  font-family: var(--mono);
  color: var(--text-2);
}

/* 14. Contact
   ========================================================================== */
.cta {
  position: relative;
  padding: clamp(2.5rem, 1.5rem + 5vw, 5.5rem) clamp(1.5rem, 1rem + 3vw, 4rem);
  text-align: center;
}

.cta::after {
  content: "";
  position: absolute;
  bottom: -60%;
  left: 50%;
  z-index: -1;
  width: 120%;
  height: 100%;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(109, 158, 255, 0.2), transparent);
  pointer-events: none;
}

.cta__avatar {
  width: 4.5rem;
  height: 4.5rem;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 1px var(--border-2), 0 0 0 6px rgba(109, 158, 255, 0.08),
    0 12px 40px rgba(109, 158, 255, 0.25);
}

.cta .section-head {
  margin-bottom: 2.25rem;
}

.cta .btn-row {
  justify-content: center;
}

.cta__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1.75rem;
  margin-top: 2.25rem;
  font-size: var(--fs-sm);
  color: var(--text-2);
}

.cta__links a {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: color 200ms var(--ease);
}

.cta__links a:hover {
  color: var(--text);
}

.cta__links svg {
  width: 1rem;
  height: 1rem;
}

.copy-note {
  min-height: 1.25rem;
  margin-top: 1rem;
  font-size: var(--fs-sm);
  color: var(--green);
}

/* 404 */
.not-found {
  display: grid;
  justify-items: center;
  gap: 1.5rem;
  padding-block: clamp(6rem, 4rem + 8vw, 11rem);
  text-align: center;
}

/* 15. Footer
   ========================================================================== */
.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 2rem;
  border-top: 1px solid var(--border);
  font-size: var(--fs-sm);
  color: var(--text-3);
}

.footer__links {
  display: flex;
  gap: 1.5rem;
}

.footer a:hover {
  color: var(--text);
}

/* 16. Motion
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .pulse::after {
    animation: pulse 2.2s var(--ease) infinite;
  }

  @keyframes pulse {
    from {
      transform: scale(1);
      opacity: 0.6;
    }
    to {
      transform: scale(3);
      opacity: 0;
    }
  }

  .ticker__track {
    animation: ticker 42s linear infinite;
  }

  .ticker:hover .ticker__track {
    animation-play-state: paused;
  }

  @keyframes ticker {
    to {
      transform: translateX(-50%);
    }
  }

  .topo-link--flow {
    stroke-dasharray: 3 7;
    animation: flow 1.6s linear infinite;
  }

  @keyframes flow {
    to {
      stroke-dashoffset: -20;
    }
  }

  .rise {
    animation: rise 900ms var(--ease) both;
  }

  .rise--2 {
    animation-delay: 90ms;
  }

  .rise--3 {
    animation-delay: 180ms;
  }

  .rise--4 {
    animation-delay: 270ms;
  }

  @keyframes rise {
    from {
      opacity: 0;
      transform: translateY(18px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 800ms var(--ease), transform 800ms var(--ease);
  }

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

/* 17. Utilities
   ========================================================================== */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media print {
  .header,
  .ticker,
  .hero::before,
  .hero::after {
    display: none;
  }
}
