/* =========================================================
   Madhur Kumar Garg — Portfolio
   Editorial executive design system
   ========================================================= */

:root {
  /* Brand palette */
  --navy: #14243a;
  --ivory: #f7f5f0;
  --teal: #247c78;
  --teal-dark: #1b625f;
  --slate: #263548;
  --stone: #e6e1d7;
  --white: #ffffff;
  --muted: #5e6b79;
  --error: #9b2c2c;

  /* Layout */
  --container: 1200px;
  --hero-container: 1280px;
  --page-x: clamp(1.5rem, 5vw, 4rem);
  --section-y: clamp(4rem, 7.5vw, 7.5rem);
  --radius-card: 14px;
  --radius-control: 8px;

  /* Typography */
  --font-heading: "Manrope", Arial, Helvetica, sans-serif;
  --font-body: "Inter", Arial, Helvetica, sans-serif;
  --fs-hero: clamp(2.5rem, 5vw, 4rem);
  --fs-hero-sub: clamp(1.375rem, 2.2vw, 1.75rem);
  --fs-h2: clamp(1.75rem, 3vw, 2.25rem);
  --fs-h3: clamp(1.3125rem, 1.8vw, 1.5rem);
  --fs-h4: clamp(1.125rem, 1.4vw, 1.25rem);
  --fs-lead: clamp(1.0625rem, 1.3vw, 1.1875rem);
  --fs-body: 1rem;
  --fs-small: 0.875rem;
  --fs-caption: 0.75rem;
  --fs-nav: 0.875rem;

  --ease: cubic-bezier(0.2, 0.7, 0.3, 1);
  --duration: 200ms;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ivory);
  color: var(--slate);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  color: var(--navy);
  font-family: var(--font-heading);
  line-height: 1.2;
}

p {
  margin: 0;
}

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

ul,
ol,
dl,
dd {
  margin: 0;
  padding: 0;
}

ul,
ol {
  list-style: none;
}

button,
input,
textarea {
  font: inherit;
}

svg {
  display: block;
  flex: 0 0 auto;
}

::selection {
  background: rgba(36, 124, 120, 0.18);
  color: var(--navy);
}

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

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--page-x);
}

.hero .container {
  max-width: var(--hero-container);
}

.micro-label {
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
  color: var(--muted);
}

.skip-link {
  position: absolute;
  left: 24px;
  top: -100px;
  z-index: 300;
  padding: 12px 18px;
  border-radius: var(--radius-control);
  background: var(--navy);
  color: var(--ivory);
  font-size: var(--fs-small);
  font-weight: 600;
  transition: top var(--duration) var(--ease);
}

.skip-link:focus {
  top: 16px;
}

/* ---------- Buttons & links ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: var(--radius-control);
  font-family: var(--font-body);
  font-size: var(--fs-small);
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  transition:
    background-color var(--duration) var(--ease),
    border-color var(--duration) var(--ease),
    color var(--duration) var(--ease),
    transform var(--duration) var(--ease);
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  background: var(--navy);
  color: var(--ivory);
}

.button-primary:hover {
  background: var(--teal-dark);
  color: var(--white);
}

.button-secondary {
  background: transparent;
  border-color: var(--stone);
  color: var(--navy);
}

.button-secondary:hover {
  border-color: var(--teal);
  color: var(--teal-dark);
}

.button-small {
  height: 46px;
  padding: 0 18px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--teal-dark);
  font-size: var(--fs-small);
  font-weight: 600;
  transition: color var(--duration) var(--ease), gap var(--duration) var(--ease);
}

.text-link:hover {
  color: var(--teal);
  gap: 9px;
}

/* ---------- Scroll progress ---------- */

.progress {
  position: fixed;
  inset: 0 0 auto;
  z-index: 200;
  height: 2px;
  pointer-events: none;
}

.progress span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--teal);
  transition: width 80ms linear;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 120;
  background: var(--ivory);
  border-bottom: 1px solid transparent;
  transition:
    border-color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--stone);
  box-shadow: 0 1px 0 rgba(20, 36, 58, 0.02), 0 10px 30px -28px rgba(20, 36, 58, 0.35);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-height: 78px;
}

.wordmark {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  flex: 0 0 auto;
}

.wordmark-name {
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.wordmark-role {
  color: var(--muted);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.3;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-left: auto;
}

.nav-links a {
  position: relative;
  padding: 8px 0;
  color: var(--slate);
  font-size: var(--fs-nav);
  font-weight: 500;
  transition: color var(--duration) var(--ease);
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--teal);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--duration) var(--ease);
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--teal-dark);
}

.nav-links a:hover::after,
.nav-links a.is-active::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav-cta {
  flex: 0 0 auto;
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  width: 44px;
  height: 44px;
  border: 1px solid var(--stone);
  border-radius: var(--radius-control);
  background: var(--white);
  cursor: pointer;
  transition: border-color var(--duration) var(--ease);
}

.menu-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  border-radius: 2px;
  background: var(--navy);
  transition: transform var(--duration) var(--ease);
}

.menu-toggle:hover {
  border-color: var(--teal);
}

.menu-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(3.25px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-3.25px) rotate(-45deg);
}

.mobile-menu {
  border-top: 1px solid var(--stone);
  border-bottom: 1px solid var(--stone);
  background: var(--ivory);
  padding: 16px var(--page-x) 24px;
}

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

.mobile-links {
  display: flex;
  flex-direction: column;
}

.mobile-links a {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--stone);
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.mobile-links a span {
  color: var(--teal);
  font-family: var(--font-body);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.06em;
}

.mobile-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 20px;
  color: var(--muted);
  font-size: var(--fs-small);
}

.mobile-meta a {
  color: var(--teal-dark);
  font-weight: 500;
}

body.menu-open {
  overflow: hidden;
}

/* ---------- Hero ---------- */

.hero {
  padding-block: clamp(3rem, 6vw, 6rem) clamp(3rem, 6vw, 5.5rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(360px, 0.88fr);
  align-items: center;
  gap: clamp(3rem, 5vw, 5rem);
}

.eyebrow {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1.5;
  text-transform: uppercase;
}

.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--teal);
}

.eyebrow-sep {
  display: inline-block;
  width: 1px;
  height: 12px;
  background: var(--stone);
}

.hero-name {
  margin-top: 24px;
  font-size: var(--fs-hero);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-headline {
  max-width: 22ch;
  margin-top: 16px;
  color: var(--slate);
  font-family: var(--font-heading);
  font-size: var(--fs-hero-sub);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.underlined {
  color: var(--teal-dark);
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}

.hero-lead {
  max-width: 54ch;
  margin-top: 24px;
  color: var(--slate);
  font-size: var(--fs-lead);
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
}

.hero-proof {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--stone);
  color: var(--muted);
  font-size: var(--fs-small);
}

.hero-proof strong {
  color: var(--navy);
  font-weight: 600;
}

.proof-divider {
  display: inline-block;
  width: 1px;
  height: 14px;
  background: var(--stone);
}

/* Hero portrait */

.hero-portrait {
  justify-self: end;
  width: 100%;
  max-width: 420px;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--stone);
  border-radius: var(--radius-card);
  background: var(--navy);
  color: var(--ivory);
}

.portrait-media {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 10px;
  background: var(--navy);
}

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

.portrait-caption {
  padding: 18px 8px 8px;
}

.portrait-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(247, 245, 240, 0.16);
}

.portrait-kicker {
  color: rgba(247, 245, 240, 0.6);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portrait-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(247, 245, 240, 0.85);
  font-size: var(--fs-caption);
  font-weight: 500;
}

.portrait-status span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
}

.portrait-role {
  margin-top: 14px;
  color: var(--ivory);
  font-family: var(--font-heading);
  font-size: var(--fs-h4);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.portrait-company {
  margin-top: 6px;
  color: rgba(247, 245, 240, 0.65);
  font-size: var(--fs-small);
}

/* ---------- Logo strip ---------- */

.logo-strip {
  border-block: 1px solid var(--stone);
}

.logo-strip-inner {
  display: flex;
  align-items: center;
  gap: 32px;
  padding-block: 20px;
}

.logo-strip .micro-label {
  flex: 0 0 auto;
}

.logo-list {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo-list span {
  color: var(--slate);
  font-family: var(--font-heading);
  font-size: var(--fs-small);
  font-weight: 600;
  letter-spacing: -0.01em;
}

/* ---------- Sections ---------- */

.section {
  padding-block: var(--section-y);
  scroll-margin-top: 92px;
}

.section-tinted {
  background: var(--white);
  border-block: 1px solid var(--stone);
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--stone);
}

.section-label {
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.section-note {
  color: var(--muted);
  font-size: var(--fs-caption);
  font-weight: 500;
  letter-spacing: 0.04em;
}

.section-title {
  max-width: 22ch;
  margin-top: 40px;
  color: var(--navy);
  font-size: var(--fs-h2);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.03em;
}

.section-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  align-items: end;
  gap: 40px;
  margin-bottom: 48px;
}

.section-intro .section-title {
  margin-top: 0;
}

.section-lede {
  max-width: 55ch;
  justify-self: end;
  color: var(--slate);
  font-size: var(--fs-lead);
  line-height: 1.7;
}

/* ---------- About ---------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  align-items: start;
  gap: clamp(3rem, 5vw, 4.5rem);
  margin-top: 48px;
}

.about-copy {
  max-width: 65ch;
  margin-top: 24px;
}

.about-copy .lead {
  color: var(--slate);
  font-size: var(--fs-lead);
  line-height: 1.7;
}

.about-copy p + p {
  margin-top: 16px;
}

.about-copy p {
  color: var(--slate);
  font-size: var(--fs-body);
  line-height: 1.7;
}

.facts-card {
  position: sticky;
  top: 100px;
  padding: 28px;
  border: 1px solid var(--stone);
  border-radius: var(--radius-card);
  background: var(--white);
}

.facts-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--stone);
}

.facts-mark {
  color: var(--teal);
  font-family: var(--font-heading);
  font-size: var(--fs-caption);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.facts-list div {
  padding: 14px 0;
  border-bottom: 1px solid var(--stone);
}

.facts-list dt {
  color: var(--muted);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.facts-list dd {
  margin-top: 4px;
  color: var(--slate);
  font-size: var(--fs-small);
  font-weight: 500;
  line-height: 1.5;
}

.available-text {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--teal-dark) !important;
}

.available-text span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
}

.facts-link {
  margin-top: 20px;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  margin-top: 56px;
  padding-top: 32px;
  border-top: 1px solid var(--stone);
}

.principle-index {
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.06em;
}

.principle h3 {
  margin-top: 10px;
  color: var(--navy);
  font-size: var(--fs-h4);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.principle p {
  margin-top: 8px;
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: 1.7;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 56px;
  border-top: 1px solid var(--stone);
}

.stat {
  padding: 24px 24px 0 0;
}

.stat + .stat {
  padding-left: 24px;
  border-left: 1px solid var(--stone);
}

.stat-value {
  display: block;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: clamp(2.25rem, 3.8vw, 3rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.stat-label {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: 1.5;
}

/* ---------- Experience ---------- */

.timeline {
  border-top: 1px solid var(--stone);
}

.timeline-item {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 48px;
  padding: 32px 0;
  border-bottom: 1px solid var(--stone);
}

.timeline-date {
  display: block;
  color: var(--navy);
  font-size: var(--fs-small);
  font-weight: 600;
  line-height: 1.5;
}

.timeline-duration {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: var(--fs-small);
}

.timeline-meta {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: var(--fs-small);
}

.role-top {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.company {
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.02em;
}

.current-pill {
  padding: 3px 8px;
  border: 1px solid var(--teal);
  border-radius: 4px;
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  line-height: 1.4;
}

.timeline-content h3 {
  margin-top: 10px;
  color: var(--navy);
  font-size: var(--fs-h3);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.025em;
}

.role-summary {
  max-width: 72ch;
  margin-top: 12px;
  color: var(--slate);
  font-size: var(--fs-body);
  line-height: 1.7;
}

.responsibilities-label {
  margin-top: 16px;
  color: var(--navy);
  font-size: var(--fs-small);
  font-weight: 600;
  line-height: 1.5;
}

.impact-list {
  max-width: 72ch;
  margin-top: 12px;
}

.impact-list li {
  position: relative;
  padding-left: 20px;
  color: var(--slate);
  font-size: var(--fs-body);
  line-height: 1.7;
}

.impact-list li + li {
  margin-top: 8px;
}

.impact-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--teal);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.tag-row span {
  padding: 4px 10px;
  border: 1px solid var(--stone);
  border-radius: 6px;
  background: var(--ivory);
  color: var(--muted);
  font-size: var(--fs-caption);
  font-weight: 500;
  line-height: 1.5;
}

.section-tinted .tag-row span {
  background: var(--white);
}

/* ---------- Expertise ---------- */

.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px 48px;
}

.skill-group {
  padding-top: 24px;
  border-top: 1px solid var(--stone);
}

.group-index {
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.06em;
}

.skill-group h3 {
  margin-top: 10px;
  color: var(--navy);
  font-size: var(--fs-h3);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.skill-group > p {
  max-width: 52ch;
  margin-top: 8px;
  color: var(--slate);
  font-size: var(--fs-body);
  line-height: 1.7;
}

.tag-row-large {
  margin-top: 20px;
}

.tag-row-large span {
  padding: 6px 12px;
  background: var(--white);
  font-size: var(--fs-small);
}

/* ---------- Credentials ---------- */

.credentials-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 64px;
}

.column-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--stone);
}

.column-head h3 {
  color: var(--navy);
  font-size: var(--fs-h3);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.cert-list li {
  padding: 16px 0;
  border-bottom: 1px solid var(--stone);
}

.cert-name {
  display: block;
  color: var(--slate);
  font-size: var(--fs-body);
  font-weight: 500;
  line-height: 1.5;
}

.cert-issuer {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: var(--fs-small);
}

.edu-list li {
  display: grid;
  gap: 4px;
  padding: 16px 0;
  border-bottom: 1px solid var(--stone);
}

.edu-period {
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.edu-school {
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: var(--fs-h4);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.edu-credential {
  color: var(--slate);
  font-size: var(--fs-body);
  line-height: 1.5;
}

.edu-location {
  color: var(--muted);
  font-size: var(--fs-small);
}

.verified-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 24px;
  padding: 14px 16px;
  border: 1px solid var(--stone);
  border-left: 3px solid var(--teal);
  border-radius: var(--radius-control);
  background: var(--white);
}

.verified-note span {
  flex: 0 0 auto;
  width: 6px;
  height: 6px;
  margin-top: 0.55em;
  border-radius: 50%;
  background: var(--teal);
}

.verified-note p {
  color: var(--teal-dark);
  font-size: var(--fs-small);
  font-weight: 500;
  line-height: 1.5;
}

/* ---------- Contact ---------- */

.contact-section {
  background: var(--navy);
  color: var(--ivory);
}

.contact-head {
  border-bottom-color: rgba(247, 245, 240, 0.18);
}

.contact-head .section-label {
  color: var(--ivory);
}

.contact-head .section-note {
  color: rgba(247, 245, 240, 0.55);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  align-items: start;
  gap: clamp(3rem, 5vw, 4.5rem);
  margin-top: 48px;
}

.contact-title {
  max-width: 18ch;
  margin-top: 0;
  color: var(--ivory);
}

.underlined-light {
  color: var(--ivory);
  text-decoration: underline;
  text-decoration-color: var(--teal);
  text-decoration-thickness: 3px;
  text-underline-offset: 6px;
}

.contact-lede {
  max-width: 50ch;
  margin-top: 24px;
  color: rgba(247, 245, 240, 0.78);
  font-size: var(--fs-lead);
  line-height: 1.7;
}

.contact-details {
  margin-top: 32px;
  border-top: 1px solid rgba(247, 245, 240, 0.18);
}

.contact-details a,
.contact-location {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid rgba(247, 245, 240, 0.18);
  color: var(--ivory);
  transition: color var(--duration) var(--ease);
}

.contact-details a:hover {
  color: var(--white);
}

.contact-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(247, 245, 240, 0.22);
  border-radius: var(--radius-control);
  color: var(--ivory);
  transition: border-color var(--duration) var(--ease);
}

.contact-details a:hover .contact-icon {
  border-color: var(--teal);
}

.contact-details span:last-child {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: var(--fs-small);
  font-weight: 500;
}

.contact-details small {
  color: rgba(247, 245, 240, 0.55);
  font-size: var(--fs-caption);
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.availability {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 24px;
  color: rgba(247, 245, 240, 0.7);
  font-size: var(--fs-small);
}

.contact-form-wrap {
  padding: 32px;
  border-radius: var(--radius-card);
  background: var(--white);
  color: var(--slate);
}

.form-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--stone);
}

.form-head h3 {
  color: var(--navy);
  font-size: var(--fs-h3);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.form-head .micro-label {
  text-align: right;
}

.field {
  margin-top: 20px;
}

.field label {
  display: block;
  color: var(--slate);
  font-size: var(--fs-small);
  font-weight: 500;
}

.field input,
.field textarea {
  width: 100%;
  margin-top: 8px;
  padding: 12px 14px;
  border: 1px solid var(--stone);
  border-radius: var(--radius-control);
  background: var(--white);
  color: var(--navy);
  font-size: var(--fs-body);
  line-height: 1.5;
  transition:
    border-color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease);
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted);
  opacity: 0.75;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(36, 124, 120, 0.15);
}

.field.has-error input,
.field.has-error textarea {
  border-color: var(--error);
}

.field.has-error input:focus,
.field.has-error textarea:focus {
  box-shadow: 0 0 0 3px rgba(155, 44, 44, 0.12);
}

.field-error {
  display: none;
  margin-top: 6px;
  color: var(--error);
  font-size: var(--fs-caption);
  line-height: 1.5;
}

.field.has-error .field-error {
  display: block;
}

.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.submit-button {
  width: 100%;
  margin-top: 24px;
}

.submit-button.is-loading {
  opacity: 0.7;
  pointer-events: none;
}

.form-status {
  min-height: 1.5em;
  margin-top: 16px;
  color: var(--teal-dark);
  font-size: var(--fs-small);
  font-weight: 500;
  line-height: 1.5;
}

.form-status.is-error {
  color: var(--error);
}

.form-success {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px 16px;
  margin-top: 24px;
  padding: 20px;
  border: 1px solid rgba(36, 124, 120, 0.25);
  border-left: 3px solid var(--teal);
  border-radius: var(--radius-control);
  background: rgba(36, 124, 120, 0.06);
}

.form-success[hidden] {
  display: none;
}

.form-success:focus {
  outline: none;
}

.form-success-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--teal);
  color: var(--white);
}

.form-success h4 {
  color: var(--teal-dark);
  font-size: var(--fs-h4);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.form-success p {
  margin-top: 4px;
  color: var(--slate);
  font-size: var(--fs-small);
  line-height: 1.6;
}

.form-success-reset {
  grid-column: 1 / -1;
  justify-self: start;
  margin-top: 2px;
}

.form-note {
  margin-top: 8px;
  color: var(--muted);
  font-size: var(--fs-caption);
  line-height: 1.6;
}

.form-note a {
  color: var(--teal-dark);
  font-weight: 500;
}

.form-note a:hover {
  color: var(--teal);
}

/* ---------- Footer ---------- */

.site-footer {
  padding-top: 48px;
  border-top: 1px solid var(--stone);
  background: var(--ivory);
}

.footer-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, 0.7fr);
  gap: 48px;
  padding-bottom: 40px;
}

.footer-brand p {
  max-width: 32ch;
  margin-top: 16px;
  color: var(--muted);
  font-size: var(--fs-small);
  line-height: 1.7;
}

.footer-nav,
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-nav a,
.footer-contact a {
  width: fit-content;
  color: var(--muted);
  font-size: var(--fs-small);
  transition: color var(--duration) var(--ease);
}

.footer-nav a:hover,
.footer-contact a:hover {
  color: var(--teal-dark);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 20px;
  border-top: 1px solid var(--stone);
}

.footer-bottom p {
  color: var(--muted);
  font-size: var(--fs-caption);
}

/* ---------- 404 ---------- */

.error-page {
  display: flex;
  align-items: center;
  min-height: 100vh;
  padding-block: 5rem;
  background: var(--ivory);
}

.error-code {
  color: var(--teal-dark);
  font-size: var(--fs-caption);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.error-title {
  margin-top: 16px;
  color: var(--navy);
  font-size: var(--fs-hero);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.error-title span {
  color: var(--teal-dark);
}

.error-copy {
  max-width: 55ch;
  margin-top: 24px;
  color: var(--slate);
  font-size: var(--fs-lead);
  line-height: 1.7;
}

.error-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
  .hero-proof .proof-divider:last-of-type {
    display: none;
  }

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

  .facts-card {
    position: static;
    max-width: 620px;
  }

  .credentials-grid {
    gap: 48px;
  }

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

  .contact-form-wrap {
    max-width: 680px;
  }
}

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

  .hero-portrait {
    justify-self: center;
  }
}

@media (max-width: 900px) {
  .nav-links,
  .nav-cta {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .section-intro {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .section-lede {
    justify-self: start;
    max-width: 65ch;
  }

  .timeline-item {
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 32px;
  }

  .skills-grid,
  .credentials-grid {
    grid-template-columns: 1fr;
  }

  .credentials-grid {
    gap: 40px;
  }

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

@media (max-width: 720px) {
  :root {
    --page-x: 1.5rem;
    --section-y: 4rem;
  }

  html {
    scroll-padding-top: 84px;
  }

  .nav-shell {
    min-height: 68px;
  }

  .wordmark-role {
    display: none;
  }

  .hero {
    padding-block: 40px 56px;
  }

  .hero-name {
    margin-top: 20px;
    font-size: 40px;
  }

  .hero-headline {
    font-size: 1.375rem;
  }

  .hero-lead {
    font-size: 1.0625rem;
  }

  .hero-proof {
    gap: 10px;
    font-size: var(--fs-caption);
  }

  .hero-proof .proof-divider {
    display: none;
  }

  .hero-portrait {
    max-width: 380px;
    padding: 10px;
  }

  .portrait-caption {
    padding: 16px 6px 6px;
  }

  .logo-strip-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .logo-list {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 10px 24px;
  }

  .section-title {
    margin-top: 32px;
    font-size: 1.75rem;
  }

  .section-intro {
    margin-bottom: 32px;
  }

  .section-lede {
    font-size: 1.0625rem;
  }

  .about-grid {
    margin-top: 32px;
  }

  .facts-card {
    padding: 24px;
  }

  .principles {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-top: 40px;
    padding-top: 24px;
  }

  .stats {
    grid-template-columns: 1fr 1fr;
    margin-top: 40px;
  }

  .stat {
    padding: 20px 16px 0 0;
  }

  .stat + .stat {
    border-left: 0;
  }

  .stat:nth-child(even) {
    padding-left: 16px;
    border-left: 1px solid var(--stone);
  }

  .stat:nth-child(n + 3) {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--stone);
  }

  .stat-value {
    font-size: 2.25rem;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 24px 0;
  }

  .timeline-side {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 12px;
  }

  .timeline-duration,
  .timeline-meta {
    margin-top: 0;
  }

  .timeline-content h3 {
    font-size: 1.3125rem;
  }

  .contact-form-wrap {
    padding: 24px;
  }

  .form-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .form-head .micro-label {
    text-align: left;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-nav,
  .footer-contact {
    gap: 8px;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .button {
    width: 100%;
  }

  .hero-name {
    font-size: 2.5rem;
  }

  .portrait-role {
    font-size: 1.125rem;
  }

  .contact-title {
    font-size: 1.75rem;
  }

  .error-actions {
    flex-direction: column;
    align-items: stretch;
  }
}

@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;
  }
}

@media print {
  .site-header,
  .progress,
  .hero-actions,
  .contact-form-wrap,
  .site-footer {
    display: none !important;
  }

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

  .section,
  .hero {
    padding-block: 24px;
  }
}
