:root {
  color-scheme: light;
  --ink: #102033;
  --muted: #667085;
  --paper: #f6fbfc;
  --surface: #ffffff;
  --surface-soft: #eef8f8;
  --line: rgba(16, 32, 51, 0.12);
  --navy: #0b2545;
  --teal: #008b8b;
  --cyan: #00a6d6;
  --mint: #78dcca;
  --blue: #285ea8;
  --amber: #f4b942;
  --rose: #e65f73;
  --shadow: 0 24px 70px rgba(11, 37, 69, 0.14);
  --soft-shadow: 0 16px 42px rgba(11, 37, 69, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  background:
    linear-gradient(rgba(0, 139, 139, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(40, 94, 168, 0.05) 1px, transparent 1px),
    linear-gradient(120deg, #f7fcfd 0%, #eef8f8 46%, #f8fbff 100%);
  background-size: 44px 44px, 44px 44px, 100% 100%;
  overflow-x: hidden;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem max(1rem, calc((100vw - 1120px) / 2));
  border-bottom: 1px solid rgba(16, 32, 51, 0.08);
  background: rgba(246, 251, 252, 0.84);
  backdrop-filter: blur(18px);
  animation: slideDown 520ms ease both;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--navy);
  font-weight: 850;
}

.brand-mark {
  display: grid;
  width: 2.5rem;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  box-shadow: 0 12px 26px rgba(0, 139, 139, 0.24);
}

nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.65rem;
  color: #41566e;
  font-size: 0.95rem;
  font-weight: 750;
}

nav a {
  position: relative;
  padding: 0.45rem 0.2rem;
}

nav a::after {
  position: absolute;
  right: 0.2rem;
  bottom: 0.2rem;
  left: 0.2rem;
  height: 2px;
  content: "";
  background: linear-gradient(90deg, var(--teal), var(--cyan));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 180ms ease;
}

nav a:hover,
nav a:focus-visible {
  color: var(--navy);
}

nav a:hover::after,
nav a:focus-visible::after {
  transform: scaleX(1);
}

main {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(20rem, 0.98fr);
  align-items: center;
  gap: 4.5rem;
  min-height: calc(88svh - 4rem);
  padding: 5.25rem 0 4rem;
}

.hero-copy {
  max-width: 42rem;
}

.eyebrow {
  margin: 0 0 0.9rem;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 13ch;
  margin-bottom: 1.3rem;
  color: var(--navy);
  font-size: 5.7rem;
  line-height: 0.92;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  color: var(--navy);
  font-size: 3.15rem;
  line-height: 1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0.75rem;
  color: var(--navy);
  font-size: 1.35rem;
  line-height: 1.15;
}

.intro {
  max-width: 38rem;
  color: #50657b;
  font-size: 1.18rem;
  line-height: 1.75;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.35rem;
}

.hero-tags span,
.skill-list span {
  display: inline-flex;
  align-items: center;
  min-height: 2.6rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(0, 139, 139, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  color: #26445f;
  font-size: 0.94rem;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(11, 37, 69, 0.06);
}

.hero-tags span::before,
.skill-list span::before {
  width: 0.45rem;
  aspect-ratio: 1;
  margin-right: 0.55rem;
  border-radius: 50%;
  content: "";
  background: var(--teal);
  box-shadow: 0 0 0 5px rgba(0, 139, 139, 0.11);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2rem;
}

.button {
  display: inline-flex;
  min-height: 3.1rem;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.2rem;
  border: 1px solid rgba(11, 37, 69, 0.16);
  border-radius: 8px;
  font-weight: 850;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(11, 37, 69, 0.16);
}

.button.primary {
  color: #fff;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  box-shadow: 0 16px 34px rgba(0, 139, 139, 0.25);
}

.button.secondary {
  background: rgba(255, 255, 255, 0.9);
  color: var(--navy);
}

.portrait-panel {
  position: relative;
  min-height: 34rem;
  overflow: hidden;
  border: 1px solid rgba(16, 32, 51, 0.1);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  isolation: isolate;
  animation: quietFloat 7s ease-in-out infinite;
}

.portrait-panel::before {
  position: absolute;
  inset: 1rem;
  z-index: 2;
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 8px;
  content: "";
  pointer-events: none;
}

.portrait-panel img {
  width: 100%;
  height: 100%;
  min-height: 34rem;
  display: block;
  object-fit: cover;
  object-position: center 28%;
  transform: scale(1.01);
}

.image-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(11, 37, 69, 0.08), rgba(11, 37, 69, 0.72)),
    linear-gradient(135deg, rgba(0, 166, 214, 0.22), rgba(244, 185, 66, 0.1));
}

.profile-card {
  position: absolute;
  right: 1rem;
  bottom: 1rem;
  left: 1rem;
  z-index: 3;
  display: grid;
  gap: 0.3rem;
  padding: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 18px 44px rgba(11, 37, 69, 0.24);
  backdrop-filter: blur(16px);
}

.profile-card strong {
  color: var(--navy);
  font-size: 1.2rem;
}

.profile-card span {
  color: #50657b;
  font-weight: 750;
}

.signal-card {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 3;
  width: min(15rem, calc(100% - 2rem));
  display: grid;
  gap: 0.55rem;
  padding: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 8px;
  background: rgba(11, 37, 69, 0.78);
  color: #fff;
  box-shadow: 0 18px 42px rgba(11, 37, 69, 0.25);
  backdrop-filter: blur(16px);
}

.signal-card div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.signal-card div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.signal-card span {
  color: var(--mint);
  font-size: 0.75rem;
  font-weight: 900;
}

.signal-card strong {
  text-align: right;
  font-size: 0.9rem;
}

.section {
  padding: 5rem 0;
}

.about {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 4rem;
  padding-top: 4.5rem;
  border-top: 1px solid var(--line);
}

.about p:last-child {
  color: #50657b;
  font-size: 1.26rem;
  line-height: 1.7;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  padding: 0 0 4rem;
}

.metrics article {
  min-height: 10rem;
  display: grid;
  align-content: end;
  gap: 0.55rem;
  padding: 1.2rem;
  border: 1px solid rgba(16, 32, 51, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(238, 248, 248, 0.9)),
    var(--surface);
  box-shadow: var(--soft-shadow);
}

.metrics strong {
  color: var(--teal);
  font-size: 2.25rem;
  line-height: 1;
}

.metrics span {
  color: #50657b;
  font-weight: 750;
  line-height: 1.45;
}

.section-heading {
  display: grid;
  gap: 0.4rem;
  max-width: 48rem;
  margin-bottom: 2.2rem;
}

.project-grid,
.timeline-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.project-card,
.timeline-item {
  position: relative;
  min-height: 18rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  padding: 1.25rem;
  border: 1px solid rgba(16, 32, 51, 0.1);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--soft-shadow);
  transition:
    transform 220ms ease,
    box-shadow 220ms ease,
    border-color 220ms ease;
}

.project-card::before,
.timeline-item::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 4px;
  content: "";
  background: linear-gradient(90deg, var(--teal), var(--cyan), var(--amber));
}

.project-card:hover,
.timeline-item:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 139, 139, 0.24);
  box-shadow: 0 28px 70px rgba(11, 37, 69, 0.16);
}

.project-card > span,
.timeline-item > span {
  width: fit-content;
  margin-bottom: auto;
  padding: 0.42rem 0.62rem;
  border-radius: 999px;
  color: var(--navy);
  background: rgba(120, 220, 202, 0.2);
  font-size: 0.78rem;
  font-weight: 900;
}

.project-card p,
.timeline-item p {
  margin-bottom: 0;
  color: #586b7f;
  line-height: 1.6;
  font-weight: 650;
}

.coral {
  background: linear-gradient(150deg, #ffffff 0%, #eefafa 100%);
}

.mint {
  background: linear-gradient(150deg, #ffffff 0%, #eefbf5 100%);
}

.violet {
  background: linear-gradient(150deg, #ffffff 0%, #f3f7ff 100%);
}

.skills {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.skill-list span:nth-child(3n + 2)::before {
  background: var(--cyan);
  box-shadow: 0 0 0 5px rgba(0, 166, 214, 0.11);
}

.skill-list span:nth-child(3n)::before {
  background: var(--amber);
  box-shadow: 0 0 0 5px rgba(244, 185, 66, 0.15);
}

.timeline-item {
  min-height: 16.5rem;
}

.timeline-item h3 {
  margin-top: 1.5rem;
}

.timeline-item.highlight {
  background: linear-gradient(150deg, #ffffff 0%, #fff7df 100%);
}

.contact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  margin: 2rem 0 4rem;
  padding: 2.2rem;
  border: 1px solid rgba(16, 32, 51, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(0, 139, 139, 0.95), rgba(40, 94, 168, 0.96)),
    var(--navy);
  color: #fff;
  box-shadow: var(--shadow);
}

.contact .eyebrow,
.contact h2 {
  color: #fff;
}

.contact h2 {
  max-width: 17ch;
}

.contact .button.primary {
  color: var(--navy);
  background: #fff;
  box-shadow: 0 16px 34px rgba(11, 37, 69, 0.18);
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 600ms ease,
    transform 600ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.hero.reveal {
  transition-delay: 80ms;
}

.project-card,
.timeline-item,
.skill-list span,
.metrics article {
  animation: fadeLift 640ms ease both;
}

.project-card:nth-child(2),
.timeline-item:nth-child(2),
.metrics article:nth-child(2) {
  animation-delay: 100ms;
}

.project-card:nth-child(3),
.timeline-item:nth-child(3),
.metrics article:nth-child(3) {
  animation-delay: 200ms;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeLift {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes quietFloat {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-10px);
  }
}

@media (max-width: 960px) {
  h1 {
    font-size: 4.5rem;
  }

  h2 {
    font-size: 2.65rem;
  }

  .hero {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    min-height: auto;
    padding-top: 4rem;
  }

  .about,
  .metrics,
  .project-grid,
  .timeline-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 0.9rem 1rem;
  }

  nav {
    width: 100%;
    justify-content: space-between;
    gap: 0.35rem 0.75rem;
    font-size: 0.9rem;
  }

  main {
    width: min(100% - 1.25rem, 1120px);
  }

  .hero {
    padding-top: 3rem;
  }

  h1 {
    max-width: 11ch;
    font-size: 3.2rem;
  }

  h2 {
    font-size: 2.15rem;
  }

  .intro,
  .about p:last-child {
    font-size: 1.05rem;
  }

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

  .portrait-panel,
  .portrait-panel img {
    min-height: 26rem;
  }

  .signal-card {
    top: 0.75rem;
    right: 0.75rem;
    left: 0.75rem;
    width: auto;
  }

  .profile-card {
    right: 0.75rem;
    bottom: 0.75rem;
    left: 0.75rem;
  }

  .section {
    padding: 3.5rem 0;
  }

  .metrics {
    padding-bottom: 2.5rem;
  }

  .project-card,
  .timeline-item {
    min-height: 14.5rem;
  }

  .contact {
    align-items: flex-start;
    flex-direction: column;
    padding: 1.35rem;
  }
}

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

  .reveal {
    opacity: 1;
    transform: none;
  }
}
