/* ============================================================
   1. CSS CUSTOM PROPERTIES (DESIGN TOKENS)
   ============================================================ */
:root {
  /* --- Color Palette --- */
  --bg-main: #101010;
  --text-white: #ffffff;
  --text-secondary: #969696;
  --text-muted: #707070;
  --text-dark: #2d2d2d;
  --text-dark-card: #313131;
  --accent-green: #20cb0a;
  --accent-gold: #e5a93c;
  --meta-pages: #c4c4c4;

  /* --- Surfaces & Overlays --- */
  --surface-base: rgba(20, 20, 20, 0.64);
  --surface-card: rgba(30, 30, 30, 0.6);
  --surface-modal: rgba(45, 45, 45, 0.95);
  --surface-modal-panel: rgba(45, 45, 45, 0.97);
  --overlay-bg: rgba(16, 16, 16, 0.85);
  --divider-color: rgba(112, 112, 112, 0.48);
  --divider-light: rgba(112, 112, 112, 0.2);
  --btn-hover-bg: rgba(60, 60, 60, 0.8);
  --hover-highlight: rgba(255, 255, 255, 0.03);

  /* --- Typography --- */
  --font-inter: 'Inter', sans-serif;
  --font-handjet: 'Handjet', sans-serif;
  --font-fraunces: 'Fraunces', serif;
  --font-redacted: 'Redacted', sans-serif;

  /* --- Layout & Spacing --- */
  --content-max-width: 40rem;
  --page-padding-x: 2.5rem;
  --page-padding-y: 10rem;
  --section-gap: 1.5rem;
  --section-content-gap: 1rem;
  --section-margin-bottom: 2rem;

  /* --- Radii --- */
  --radius-xs: 0.25rem;
  --radius-sm: 0.625rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-pill: 2rem;
  --radius-full: 4rem;
  --radius-circle: 50%;

  /* --- Transitions --- */
  --transition-fast: 0.2s ease;
  --transition-base: 0.25s ease;
  --transition-smooth: 0.35s ease;
  --transition-accordion: 0.4s cubic-bezier(0.22, 1, 0.36, 1);

  /* --- Z-Indexes --- */
  --z-base: 1;
  --z-indicator: 2;
  --z-page: 3;
  --z-tooltip: 100;
  --z-fixed-nav: 1000;
  --z-modal: 2000;
}

/* ============================================================
   2. RESETS AND BASE STYLES
   ============================================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: clamp(0.875rem, calc(0.875rem + 0.179vw), 1.25rem);
  scroll-behavior: smooth;
}

body {
  background: var(--bg-main);
  color: var(--text-white);
  font-family: var(--font-inter);
  min-height: 100vh;
  overflow-x: hidden;
}

a {
  color: inherit;
}

button {
  font-family: inherit;
}

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

/* ============================================================
   3. LAYOUT CONTAINERS AND GLOBAL UTILITIES
   ============================================================ */
.page-wrapper {
  position: relative;
  z-index: var(--z-page);
  padding: var(--page-padding-y) var(--page-padding-x);
}

.content-area {
  max-width: var(--content-max-width);
  margin: 2rem auto;
  /* margin-top: 12rem; */
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
}

.section {
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
  width: 100%;
  margin-bottom: var(--section-margin-bottom);
}

.section-divider {
  height: 1px;
  background: var(--divider-color);
  width: 100%;
  border: none;
  display: block;
}

.section-heading {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.section-main-heading {
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.section-main-desc {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.placeholder-img {
  background-color: var(--bg-main);
  background-image: repeating-conic-gradient(
    rgba(255, 255, 255, 0.04) 0% 25%,
    transparent 0% 50%
  );
  background-size: 1.25rem 1.25rem;
}

/* ============================================================
   4. NAVIGATION COMPONENTS
   ============================================================ */
.nav-fixed {
  position: fixed;
  top: 5.5rem;
  z-index: var(--z-fixed-nav);
}

.nav-right {
  right: var(--page-padding-x);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
}

.nav-left {
  left: var(--page-padding-x);
}

.nav-btn {
  background: var(--surface-base);
  border: 1px solid var(--divider-color);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background var(--transition-fast);
  border-radius: var(--radius-pill);
}

.nav-btn:hover {
  background: var(--btn-hover-bg);
}

.nav-btn .icon svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: var(--text-white);
  display: block;
}

.nav-btn--sm {
  width: 2rem;
  height: 2rem;
}

.icon-svg-nav {
  width: 1.25rem;
  height: 1.25rem;
  fill: var(--text-white);
  display: block;
}

.nav-menu-dropdown {
  background: var(--surface-base);
  border: 1px solid var(--divider-color);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 1rem 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: fit-content;
  margin-top: 0.25rem;
  border-radius: var(--radius-xl);
}

.nav-menu-dropdown[hidden] {
  display: none;
}

.nav-menu-item {
  display: flex;
  flex-direction: row;
  gap: 0.25rem;
  align-items: center;
  text-decoration: none;
  cursor: pointer;
}

.nav-menu-item .arrow-indicator {
  width: 0.5rem;
  height: 0.5rem;
  opacity: 0;
  flex-shrink: 0;
}

.nav-menu-item .arrow-indicator svg {
  width: 0.5rem;
  height: 0.5rem;
  fill: var(--text-white);
  display: block;
}

.nav-menu-item.active .arrow-indicator {
  opacity: 1;
}

.nav-menu-item span.label {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-white);
  text-transform: uppercase;
}

.nav-years-pill {
  background: var(--surface-base);
  border: 1px solid var(--divider-color);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  padding: 0.625rem 1rem;
  border-radius: var(--radius-pill);
}

.nav__years {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__year-text {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.nav__year-link {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--text-muted);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  transition: color var(--transition-fast);
}

.nav__year-link:hover,
.nav__year-link.active {
  color: var(--text-white);
}

.nav__year-link.active {
  text-decoration: underline;
}

/* ============================================================
   5. HERO & ABOUT SECTION
   ============================================================ */
.section--hero {
  gap: var(--section-content-gap);
}

.hero-greeting {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
}

.hero-name {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1.5rem;

  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.hero-pronunciation {
  font-family: var(--font-inter);
  font-style: italic;
  font-weight: 300;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.pronunciation-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
}

.pronunciation-btn svg {
  width: 0.75rem;
  height: 0.75rem;
  fill: var(--text-muted);
  display: block;
}

h1.hero-headline {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: clamp(2rem, 4vw, 2.5rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

h1.hero-headline strong {
  color: var(--text-white);
  font-weight: 400;
}

.hero-bio-primary,
.hero-bio-secondary {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

.hero-bio-primary strong {
  color: var(--text-white);
  font-weight: 400;
}

.books-link {
  color: var(--text-secondary);
  text-decoration: underline;
}

.books-link:hover {
  color: var(--text-white);
}

.hero-cta {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.hero-top-container {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: var(--section-gap);
  width: 100%;
}

.hero-text-block {
  display: flex;
  flex-direction: column;
  gap: var(--section-content-gap);
  flex: 1;
}

.hero-illustration-wrapper {
  flex-shrink: 0;
  width: 12rem;
  height: 12rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-illustration {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: invert(1);
  user-select: none;
}

/* --- Interactive Avatar --- */
#avatar-container {
  width: 100%;
  height: 100%;
  aspect-ratio: 1 / 1;
  cursor: pointer;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.3s ease-out;
  opacity: 0.7;
}

#avatar-container.is-active {
  transition: none;
}

.avatar-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transition: opacity 0.4s ease-in-out;
}

#default-avatar-wrapper {
  opacity: 1;
}

#hover-avatar-wrapper {
  opacity: 0;
}

#avatar-container.is-hovered #default-avatar-wrapper {
  opacity: 0;
}

#avatar-container.is-hovered #hover-avatar-wrapper {
  opacity: 1;
}

.avatar-layer svg,
.avatar-layer img {
  width: 100%;
  height: 100%;
  pointer-events: none;
  display: block;
}

.hero-illustration-wrapper {
  flex-shrink: 0;
  width: 12rem;
  height: 12rem;

  width: clamp(6.5rem, 20vw, 12rem);
  height: clamp(6.5rem, 20vw, 12rem);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible; /* Allows the chalk dust to bleed outward */
  cursor: pointer;
}

.avatar-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transition: opacity 0.4s ease-in-out;
  /* Apply the chalk displacement and grain */
  filter: url(#chalk-filter) drop-shadow(0 0 1px rgba(255, 255, 255, 0.4));
  will-change: filter;
}

@keyframes avatarWobble {
  0%,
  100% {
    transform: translateY(-8px) rotate(0deg) scale(1.08);
  }
  25% {
    transform: translateY(-8px) rotate(-4deg) scale(1.08);
  }
  75% {
    transform: translateY(-8px) rotate(4deg) scale(1.08);
  }
}

.hero-illustration-wrapper.is-wobbling {
  animation: avatarWobble 0.5s ease;
}

/* ============================================================
   6. BUTTONS & INTERACTIVE PILLS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 2.25rem;
  padding: 0.5rem 0.75rem;
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1;
  letter-spacing: 0;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: all var(--transition-fast);
  border-radius: var(--radius-full);
}

.btn:hover {
  transform: translateY(-2px) scale(1.05) rotate(-1deg);
  transform-origin: center;
}

.btn .icon svg {
  width: 1rem;
  height: 1rem;
  display: block;
}

.btn--primary {
  background: var(--text-white);
  color: var(--text-dark);
}

.btn--primary .icon svg {
  fill: var(--text-dark);
}

.btn--secondary {
  background: transparent;
  color: var(--text-white);
  border: 1px solid var(--text-muted);
}

.btn--secondary .icon svg {
  fill: var(--text-white);
}

.btn--copied {
  background: var(--accent-green);
  color: var(--bg-main);
}

.pill {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  background: var(--text-dark);
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.5rem;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--text-white);
  transition: background var(--transition-fast);
  border-radius: var(--radius-full);
}

/* ============================================================
   7. SELECTED WORK (PROJECT CARDS)
   ============================================================ */
.projects-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.project-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.5rem 1rem 0.5rem 0;
  cursor: pointer;
  position: relative;
  text-decoration: none;
  transition:
    background var(--transition-fast),
    border-left var(--transition-fast),
    padding-left var(--transition-fast);
  overflow: hidden;
  border-left: 2px solid transparent;
}

.project-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--hover-highlight);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.project-card:hover::after {
  opacity: 1;
}

.project-card:hover {
  background: var(--surface-base);
  border-left: 4px solid var(--text-dark);
  padding-left: 0.75rem;
}

.project-card:hover .pill {
  background: var(--text-dark-card);
}

.project-pills {
  display: flex;
  flex-direction: row;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.project-name {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.project-desc {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

/* ============================================================
   8. SKILLS SECTION
   ============================================================ */
.skills-list {
  display: flex;
  flex-direction: column;
  gap: var(--section-content-gap);
}

.skill-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.skill-type {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

.skill-list {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

/* ============================================================
   9. WORK EXPERIENCE & EDUCATION ACCORDIONS
   ============================================================ */
.section-heading-row {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}

.collapse-btn {
  display: flex;
  flex-direction: row;
  gap: 0.25rem;
  align-items: center;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.collapse-btn span {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.8rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.collapse-btn .icon svg {
  width: 0.65rem;
  height: 0.65rem;
  fill: var(--text-muted);
  display: block;
}

.jobs-list,
.edu-list {
  display: flex;
  flex-direction: column;
}

.job-entry,
.edu-entry {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.job-entry[data-expanded='true'],
.edu-entry[data-expanded='true'] {
  margin-bottom: 1.25rem;
}

.job-entry[data-expanded='false'],
.edu-entry[data-expanded='false'] {
  margin-bottom: 0;
}

.job-header,
.edu-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
}

.job-header-left,
.edu-header-left {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.875rem;
  min-width: 0;
}

.job-logo-badge,
.edu-logo-badge {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-sm);
  background: var(--text-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  padding: 0.35rem;
}

.job-logo-badge img,
.edu-logo-badge img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.job-logo-badge img.white {
  filter: brightness(0) invert(1);
}

.job-titles,
.edu-titles {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.job-company,
.edu-degree {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--text-white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.job-role,
.edu-college {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.8125rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--text-secondary);
}

.job-duration,
.edu-duration {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  text-transform: uppercase;
  flex-shrink: 0;
  text-align: right;
}

.job-bullets,
.edu-bullets {
  list-style: none;
  padding: 0;
  margin: 0 0 0 3.75rem;
  overflow: hidden;
  will-change: max-height, opacity;
  position: relative;
}

.job-bullets::before,
.edu-bullets::before {
  content: '';
  position: absolute;
  top: 0.5rem;
  bottom: 0.5rem;
  left: 0.25rem;
  width: 1px;
  background: var(--divider-color);
  opacity: 0.6;
}

.job-bullets li,
.edu-bullets li {
  position: relative;
  padding-left: 1rem;
  margin-bottom: 0.5rem;
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.8125rem;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: var(--text-secondary);
}

.job-bullets li:last-child,
.edu-bullets li:last-child {
  margin-bottom: 0.25rem;
}

.job-bullets strong,
.edu-bullets strong {
  color: var(--text-white);
  font-weight: 500;
}

.timeline-pointer {
  position: absolute;
  left: -0.0625rem;
  top: 0.35rem;
  width: 0.625rem;
  height: 0.625rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-white);
  background: var(--bg-main);
  z-index: var(--z-indicator);
}

.timeline-pointer svg {
  width: 0.625rem;
  height: 0.625rem;
  fill: currentColor;
  display: block;
}

.job-entry[data-expanded='false'] .job-bullets,
.edu-entry[data-expanded='false'] .edu-bullets {
  max-height: 0;
  opacity: 0;
  transition:
    max-height 0.25s cubic-bezier(0, 0.7, 0.1, 1),
    opacity var(--transition-fast);
}

.job-entry[data-expanded='true'] .job-bullets,
.edu-entry[data-expanded='true'] .edu-bullets {
  max-height: 16rem;
  opacity: 1;
  transition:
    max-height var(--transition-smooth),
    opacity var(--transition-base);
}

/* ============================================================
   10. TESTIMONIALS SECTION
   ============================================================ */
.testimonials-heading-row {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
  align-items: center;
}

.shuffle-btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
}

.shuffle-btn svg {
  width: 0.75rem;
  height: 0.75rem;
  fill: var(--text-muted);
  display: block;
}

.testimonial-block {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
  transition:
    opacity var(--transition-smooth),
    transform var(--transition-smooth);
}

.testimonial-block.fading-out {
  opacity: 0;
  transform: translateY(-0.625rem);
}

.testimonial-block.fading-in {
  opacity: 0;
  transform: translateY(0.625rem);
}

.testimonial-quote-icon svg {
  width: 2rem;
  height: 2rem;
  fill: var(--divider-color);
  display: block;
}

.testimonial-quote {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4;
  color: var(--text-white);
}

.testimonial-divider {
  width: 4rem;
  height: 2px;
  background: var(--text-dark);
  border: none;
}

.testimonial-person {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
  align-items: flex-start;
}

.testimonial-avatar {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-circle);
  object-fit: cover;
  background: var(--text-dark);
  flex-shrink: 0;
}

.testimonial-info {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.testimonial-name {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--text-white);
}

.testimonial-designation {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--text-secondary);
}

/* ============================================================
   11. SITE FOOTER
   ============================================================ */
.site-footer {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.footer-copy {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.625rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.footer-colophon-link {
  color: var(--text-white);
  text-decoration: underline;
}

.footer-social {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
  align-items: center;
}

.footer-social a,
.footer-email-btn {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--text-white);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  position: relative;
}

.footer-email-btn svg {
  width: 1rem;
  height: 1rem;
  fill: var(--text-white);
  display: block;
}

.footer-time {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.625rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.footer-link {
  transition: transform var(--transition-base);
}

.footer-link:hover {
  transform: translateY(-0.25rem) scale(1.02);
}

.copy-tooltip {
  position: absolute;
  bottom: calc(100% + 0.25rem);
  left: 50%;
  transform: translateX(-50%);
  background: var(--text-dark);
  color: var(--text-white);
  font-family: var(--font-inter);
  font-size: 0.625rem;
  padding: 0.25rem 0.5rem;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--transition-fast);
  z-index: var(--z-tooltip);
}

.copy-tooltip.visible {
  opacity: 1;
}

/* ============================================================
   12. PROJECT PAGE COMPONENTS
   ============================================================ */
.project-overview-header {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.project-overview-title {
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.project-type-pill {
  display: inline-block;
  background: var(--text-white);
  color: var(--bg-main);
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 0.75rem;
  border-radius: var(--radius-md);
  padding: 0.25rem 0.5rem;
  width: fit-content;
}

.project-hero-image {
  width: 100%;
  aspect-ratio: 640 / 400;
  object-fit: cover;
  background: var(--bg-main);
  border-radius: var(--radius-lg);
}

.project-meta {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.meta-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.meta-label {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.meta-value {
  font-family: var(--font-inter);
  font-size: 1rem;
  line-height: 1.4;
  color: var(--text-white);
}

.meta-value--redacted {
  font-family: var(--font-redacted);
  position: relative;
  cursor: help;
}

.meta-value--redacted::after {
  content: 'Protected under NDA';
  position: absolute;
  bottom: calc(100% + 0.25rem);
  left: 0;
  background: var(--text-dark);
  color: var(--text-white);
  font-family: var(--font-inter);
  font-size: 0.625rem;
  padding: 0.25rem 0.5rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-fast);
  z-index: 10;
}

.meta-value--redacted:hover::after {
  opacity: 1;
}

.project-details-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.project-detail-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.detail-label {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.detail-value {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.accordion-list {
  display: flex;
  flex-direction: column;
}

.accordion-item {
  border-left: 0.5px solid var(--divider-color);
}

.accordion-header {
  display: flex;
  flex-direction: row;
  gap: 0.25rem;
  align-items: center;
  padding: 0.5rem 0;
  background: none;
  border: none;
  cursor: pointer;
  width: 100%;
  text-align: left;
}

.accordion-num {
  width: 2rem;
  height: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.4;
  color: var(--text-white);
  flex-shrink: 0;
}

.accordion-title {
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.accordion-body {
  overflow: hidden;
  height: 0;
  opacity: 0;
  transition:
    height var(--transition-accordion),
    opacity 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0 0 1rem 2.25rem;
}

.accordion-item[data-open='true'] {
  border-left: 2px solid var(--text-white);
}

.accordion-item[data-open='true'] .accordion-body {
  height: auto;
  opacity: 1;
}

.accordion-desc {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.project-img {
  width: 100%;
  aspect-ratio: 640 / 400;
  object-fit: cover;
  border-radius: var(--radius-lg);
}

.img-caption {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

/* Project Carousel */
.carousel {
  position: relative;
  width: 100%;
  aspect-ratio: 640 / 400;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  height: 100%;
}

.carousel-slide {
  min-width: 100%;
  aspect-ratio: 640 / 400;
  flex-shrink: 0;
}

.carousel-prev {
  position: absolute;
  left: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
}

.carousel-next {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
}

.carousel-prev .icon svg,
.carousel-next .icon svg {
  width: 1.5rem;
  height: 1.5rem;
  fill: var(--text-white);
  display: block;
}

.breakdown-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.breakdown-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.breakdown-num {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.breakdown-heading {
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.breakdown-desc {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

/* Project Impact Metrics */
.metrics-intro {
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.metric-card {
  display: flex;
  flex-direction: row;
  gap: 0.5rem;
  padding: 1.5rem 1rem;
  position: relative;
  border: 1px solid var(--divider-color);
  overflow: hidden;
  margin: -0.5px;
}

.metric-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  z-index: var(--z-base);
}

.metric-highlight {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1.4;
  color: var(--text-white);
}

.metric-heading {
  font-family: var(--font-inter);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-white);
}

.metric-desc {
  font-family: var(--font-inter);
  font-weight: 400;
  font-size: 0.75rem;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text-secondary);
}

.metric-icon {
  position: absolute;
  bottom: 1rem;
  right: 1rem;
  width: 5rem;
  height: 5rem;
  opacity: 0.25;
}

.metric-icon svg {
  width: 5rem;
  height: 5rem;
  fill: var(--text-dark);
  display: block;
}

/* Project Reflection Cards */
.reflection-list {
  display: flex;
  flex-direction: column;
}

.reflection-item {
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
  padding: 1.5rem 1rem;
  border: 1px solid var(--divider-color);
  margin-top: -1px;
}

.reflection-icon {
  width: 5rem;
  height: 5rem;
  flex-shrink: 0;
}

.reflection-icon svg {
  width: 5rem;
  height: 5rem;
  fill: var(--text-muted);
  display: block;
}

.reflection-text {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.reflection-heading {
  font-family: var(--font-inter);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-white);
  letter-spacing: -0.02em;
}

.reflection-desc {
  font-family: var(--font-inter);
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--text-secondary);
  letter-spacing: -0.02em;
  line-height: 1.4;
}

/* ============================================================
   13. BOOKSHELF PAGE COMPONENTS
   ============================================================ */
.bookshelf-header {
  padding-top: var(--page-padding-y);
}

.bookshelf-title {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: clamp(1.5rem, 6vw, 2.5rem);
  line-height: 1;
  letter-spacing: 0.04em;
  color: var(--text-white);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.bookshelf-subtitle {
  font-family: var(--font-inter);
  font-weight: 300;
  font-size: 1rem;
  color: var(--text-secondary);
  letter-spacing: -0.02em;
}

.year-section {
  padding-top: var(--section-content-gap);
}

.year-heading {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.books-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(9.375rem, 1fr));
  gap: 0.75rem;
}

.book-cover {
  width: 100%;
  aspect-ratio: 5 / 7;
  cursor: pointer;
  position: relative;
  background: var(--bg-main);
  border: none;
  padding: 0;
  overflow: visible;
  transition:
    transform var(--transition-base),
    box-shadow var(--transition-base);
}

.book-cover:hover {
  transform: translateY(-0.25rem) scale(1.02);
  box-shadow: 0 0.75rem 2rem rgba(0, 0, 0, 0.5);
}

.book-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-cover .book-placeholder {
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: inherit;
  background: linear-gradient(160deg, var(--bg-main) 0%, #252525 100%);
  background-size: cover;
  position: relative;
}

.book-cover::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 0.5rem);
  left: 50%;
  transform: translateX(-50%);
  background: var(--text-dark);
  color: var(--text-white);
  font-family: var(--font-inter);
  font-size: 0.8125rem;
  line-height: 1.3;
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-xs);
  /* Replace white-space: nowrap with auto-wrapping */
  white-space: normal;
  width: max-content;
  max-width: min(18rem, calc(100vw - 2 * var(--page-padding-x)));
  text-align: center;
  pointer-events: none;
  opacity: 0;
  transition:
    opacity var(--transition-fast),
    transform var(--transition-fast);
  z-index: var(--z-tooltip);
}

.book-cover:hover::after,
.book-cover:focus-visible::after {
  opacity: 1;
  transform: translateX(-50%) translateY(-2px);
}

.book-overlay {
  position: fixed;
  inset: 0;
  background: var(--overlay-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-modal);
}

.book-overlay[hidden] {
  display: none;
}

.book-overlay__backdrop {
  position: absolute;
  inset: 0;
  background: var(--overlay-bg);
  cursor: pointer;
}

.book-overlay__panel {
  position: relative;
  z-index: var(--z-base);
  width: min(37.5rem, 90vw);
  background: var(--surface-modal-panel);
  border: 1px solid rgba(112, 112, 112, 0.5);
  display: flex;
  flex-direction: row;
  gap: 1.25rem;
  padding: 1rem;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: var(--radius-lg);
}

.book-overlay__close {
  position: absolute;
  right: 0.8rem;
  width: 1.75rem;
  height: 1.75rem;
  background: var(--text-dark);
  border: 1px solid rgba(112, 112, 112, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-white);
  z-index: var(--z-indicator);
  border-radius: var(--radius-circle);
}

.book-overlay__close svg {
  width: 1rem;
  height: 1rem;
  display: block;
  fill: currentColor;
}

.book-overlay__img-wrap {
  width: 10rem;
  flex-shrink: 0;
  aspect-ratio: 5 / 7;
  background: var(--bg-main);
  overflow: hidden;
}

.book-overlay__img-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(160deg, var(--bg-main), #2a2a2a);
}

.book-overlay__info {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.5rem 0;
  flex: 1;
  min-width: 0;
}

.book-overlay__title {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--text-white);
  text-transform: uppercase;
  word-break: break-word;
}

.book-overlay__meta {
  font-family: var(--font-inter);
  font-size: 0.75rem;
  color: var(--text-secondary);
  letter-spacing: -0.01em;
}

.book-overlay__genres {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.book-genre-pill {
  background: var(--bg-main);
  padding: 0.2rem 0.5rem;
  font-family: var(--font-inter);
  font-size: 0.625rem;
  color: var(--text-white);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.book-overlay__desc {
  font-family: var(--font-inter);
  font-size: 0.8125rem;
  color: var(--text-white);
  line-height: 1.5;
  letter-spacing: -0.01em;
}

/* ============================================================
   14. COLOPHON PAGE COMPONENTS
   ============================================================ */
.colophon-header {
  padding-top: var(--page-padding-y);
}

.colophon-title {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: clamp(1.5rem, 6vw, 2.5rem);
  line-height: 1;
  letter-spacing: 0.04em;
  color: var(--text-white);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.colophon-subtitle {
  font-family: var(--font-inter);
  font-weight: 300;
  font-size: 1rem;
  color: var(--text-secondary);
  letter-spacing: -0.02em;
}

.colophon-section-heading {
  font-family: var(--font-handjet);
  font-weight: 700;
  font-size: 0.75rem;
  line-height: 1;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.colophon-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.colophon-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding-bottom: 1rem;
}

.colophon-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.colophon-item__link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-white);
  text-decoration: none;
  transition: opacity var(--transition-fast);
}

.colophon-item__link:hover {
  opacity: 0.7;
}

.colophon-item__link--no-href {
  cursor: default;
}

.colophon-item__link--no-href:hover {
  opacity: 1;
}

.colophon-item__name {
  font-family: var(--font-inter);
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-white);
  letter-spacing: -0.02em;
}

.colophon-item__desc {
  font-family: var(--font-inter);
  font-size: 0.8125rem;
  color: var(--text-secondary);
  letter-spacing: -0.01em;
  line-height: 1.5;
}

.colophon-pill {
  background: var(--text-dark);
  padding: 0.2rem 0.5rem;
  font-family: var(--font-inter);
  font-size: 0.625rem;
  color: var(--text-white);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  flex-shrink: 0;
  border-radius: var(--radius-lg);
}

.colophon-sustainability {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
}

.colophon-sustainability__icon {
  flex-shrink: 0;
  margin-top: 0.125rem;
}

.colophon-sustainability__icon svg {
  width: 1.25rem;
  height: 1.25rem;
  fill: var(--accent-green);
  display: block;
}

.colophon-sustainability__text {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.colophon-sustainability__text p {
  font-family: var(--font-inter);
  font-size: 0.9375rem;
  color: var(--text-white);
  line-height: 1.5;
  letter-spacing: -0.02em;
}

.colophon-sustainability__link {
  font-family: var(--font-inter);
  font-size: 0.8125rem;
  color: var(--accent-green);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.colophon-sustainability__link:hover {
  text-decoration: underline;
}

/* ============================================================
   15. CONSOLIDATED MEDIA QUERIES
   ============================================================ */
@media (max-width: 48rem) {
  :root {
    --page-padding-x: 1.5rem;
    --page-padding-y: 6.25rem;
  }

  .nav-fixed {
    top: 1.5rem;
  }

  .metrics-grid {
    grid-template-columns: 1fr;
  }

  .site-footer {
    flex-wrap: wrap;
    gap: 1rem;
  }
}

@media (max-width: 40rem) {
  .job-header,
  .edu-header {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 0.875rem;
    row-gap: 0.25rem;
    align-items: start;
  }

  .job-header-left,
  .edu-header-left {
    display: contents;
  }

  .job-logo-badge,
  .edu-logo-badge {
    grid-column: 1;
    grid-row: 1 / span 2;
    align-self: start;
  }

  .job-titles,
  .edu-titles {
    grid-column: 2;
    grid-row: 1;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
  }

  .job-company,
  .edu-degree {
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
  }

  .job-duration,
  .edu-duration {
    grid-column: 2;
    grid-row: 2;
    text-align: left;
    margin: 0.125rem 0 0 0;
  }

  .job-bullets,
  .edu-bullets {
    margin: 0 0 0 2.7rem;
  }
  .hero-top-container {
    flex-direction: column-reverse;
    align-items: flex-start;
    gap: var(--section-content-gap);
  }

  .hero-illustration-wrapper {
    width: 6.5rem;
    height: 6.5rem;
  }

  .content-area {
    margin: 2rem;
  }
}

@media (max-width: 30rem) {
  :root {
    --page-padding-x: 1rem;
    --page-padding-y: 5rem;
  }

  .project-meta {
    flex-direction: column;
    gap: 0.75rem;
  }

  .hero-cta {
    flex-direction: column;
  }

  .book-overlay__panel {
    flex-direction: column;
  }

  .book-overlay__img-wrap {
    width: 100%;
    max-height: 10rem;
  }
}

@media (max-width: 20rem) {
  .hero-greeting {
    flex-direction: column;
  }
}

/* Avatar Tooltip Setup */
.hero-illustration-wrapper {
  position: relative;
}

/* Restrict the avatar tooltip strictly to pointer/hover devices */
@media (hover: hover) and (pointer: fine) {
  .hero-illustration-wrapper::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 0.5rem);
    left: 50%;
    transform: translateX(-50%);
    background: var(--text-dark);
    color: var(--text-white);
    font-family: var(--font-inter);
    font-size: 0.75rem;
    line-height: 1.2;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-xs);
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition:
      opacity var(--transition-fast),
      transform var(--transition-fast);
    z-index: var(--z-tooltip);
  }

  .hero-illustration-wrapper:hover::after,
  .hero-illustration-wrapper:focus-visible::after {
    opacity: 1;
    transform: translateX(-50%) translateY(-2px);
  }
}

/* Floating Cursor Tooltip (Desktop Only) */
.cursor-tooltip {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  background: var(--text-dark);
  color: var(--text-white);
  font-family: var(--font-inter);
  font-size: 0.75rem;
  line-height: 1.2;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-xs);
  white-space: nowrap;
  opacity: 0;
  transform: translate(-50%, -140%);
  transition: opacity var(--transition-fast);
  z-index: var(--z-tooltip);
}

.cursor-tooltip.is-visible {
  opacity: 1;
}
