:root {
  --bg: #f5efe4;
  --bg-strong: #efe1c6;
  --surface: rgba(255, 252, 245, 0.78);
  --surface-strong: #fbf6ed;
  --text: #10252b;
  --muted: #4c6468;
  --accent: #1f8a70;
  --accent-deep: #0d5c63;
  --accent-soft: #f28f3b;
  --line: rgba(16, 37, 43, 0.12);
  --shadow: 0 20px 50px rgba(16, 37, 43, 0.12);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --content-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(31, 138, 112, 0.22), transparent 28%),
    radial-gradient(circle at top right, rgba(242, 143, 59, 0.2), transparent 25%),
    linear-gradient(180deg, #f9f3e7 0%, var(--bg) 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(16, 37, 43, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(16, 37, 43, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.08));
}

a {
  color: inherit;
}

.page-shell {
  width: min(calc(100% - 2rem), var(--content-width));
  margin: 0 auto;
  padding: 1.25rem 0 4rem;
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(16, 37, 43, 0.08);
  border-radius: 999px;
  background: rgba(255, 248, 235, 0.78);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 1rem;
  z-index: 5;
}

.brand {
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.02em;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--muted);
}

.hero {
  padding: 1.25rem 0 2rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.9fr);
  gap: 1.5rem;
  align-items: stretch;
}

.hero-copy,
.hero-card,
.panel,
.project-card,
.cta {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-copy {
  padding: clamp(2rem, 3vw, 3rem);
}

.hero-card {
  padding: 1.8rem;
  background:
    linear-gradient(180deg, rgba(13, 92, 99, 0.95), rgba(16, 37, 43, 0.92)),
    linear-gradient(135deg, rgba(242, 143, 59, 0.25), transparent);
  color: #f7f2e8;
  position: relative;
  overflow: hidden;
}

.hero-card::after {
  content: "";
  position: absolute;
  right: -4rem;
  bottom: -4rem;
  width: 12rem;
  height: 12rem;
  background: radial-gradient(circle, rgba(242, 143, 59, 0.55), transparent 65%);
}

.eyebrow,
.section-label,
.card-kicker,
.project-type,
.timeline-date {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
}

.eyebrow,
.section-label,
.project-type,
.timeline-date {
  color: var(--accent-deep);
}

.card-kicker {
  color: rgba(247, 242, 232, 0.8);
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.05;
}

h1,
h2 {
  font-family: "Newsreader", serif;
}

h1 {
  margin-top: 0.75rem;
  font-size: clamp(3rem, 6vw, 5.5rem);
  max-width: 12ch;
}

h2 {
  font-size: clamp(2rem, 3vw, 3rem);
}

h3 {
  font-size: 1.2rem;
}

.lede,
.profile-grid p,
.project-card p,
.timeline-item p,
.skill-group p,
.hero-card li,
.site-footer p {
  line-height: 1.75;
  color: var(--muted);
}

.lede {
  margin: 1.5rem 0 0;
  max-width: 65ch;
  font-size: 1.05rem;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.2rem;
  padding: 0.9rem 1.35rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

.button.primary {
  background: var(--accent);
  color: #fdfbf5;
  box-shadow: 0 12px 24px rgba(31, 138, 112, 0.28);
}

.button.secondary {
  background: transparent;
  border: 1px solid rgba(16, 37, 43, 0.18);
}

.contact-strip {
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
}

.contact-strip li {
  padding: 1rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 252, 245, 0.78);
  border: 1px solid rgba(16, 37, 43, 0.08);
  min-width: 0;
}

.contact-strip span {
  display: block;
  margin-bottom: 0.45rem;
  color: var(--muted);
  font-size: 0.85rem;
}

.contact-strip a {
  font-weight: 700;
  text-decoration: none;
  word-break: break-word;
}

.focus-list {
  padding-left: 1.2rem;
  margin: 1.35rem 0 1.8rem;
}

.focus-list li {
  margin-bottom: 0.8rem;
  line-height: 1.65;
  position: relative;
  z-index: 1;
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.mini-stats div {
  padding: 1rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.mini-stats strong {
  display: block;
  font-size: 1.7rem;
  font-weight: 700;
  color: #ffffff;
}

.mini-stats span {
  display: block;
  margin-top: 0.35rem;
  line-height: 1.5;
  color: rgba(247, 242, 232, 0.8);
}

main {
  display: grid;
  gap: 1.5rem;
}

.panel,
.cta {
  padding: 1.8rem;
}

.section-block {
  display: grid;
  gap: 1.5rem;
}

.section-heading {
  display: grid;
  gap: 0.55rem;
  margin-bottom: 1.5rem;
}

.profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.25rem;
}

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

.project-card {
  padding: 1.55rem;
  background: linear-gradient(180deg, rgba(255, 252, 245, 0.85), rgba(251, 246, 237, 0.92));
  transition: transform 180ms ease, border-color 180ms ease;
}

.project-card:hover,
.project-card:focus-within {
  transform: translateY(-4px);
  border-color: rgba(31, 138, 112, 0.35);
}

.project-card h3,
.skill-group h3,
.timeline-item h3 {
  margin-top: 0.5rem;
}

.split-layout {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

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

.skill-group {
  padding: 1.1rem 1.15rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(16, 37, 43, 0.08);
}

.timeline {
  display: grid;
  gap: 1.1rem;
}

.timeline-item {
  position: relative;
  padding: 0.25rem 0 0.25rem 1.4rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55rem;
  bottom: -1.2rem;
  width: 1px;
  background: rgba(16, 37, 43, 0.15);
}

.timeline-item::after {
  content: "";
  position: absolute;
  left: -0.3rem;
  top: 0.55rem;
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: var(--accent-soft);
  box-shadow: 0 0 0 6px rgba(242, 143, 59, 0.16);
}

.timeline-item:last-child::before {
  bottom: 0.9rem;
}

.timeline-meta {
  font-weight: 700;
  color: var(--text);
}

.cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  background:
    linear-gradient(135deg, rgba(31, 138, 112, 0.16), rgba(242, 143, 59, 0.16)),
    rgba(255, 252, 245, 0.8);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1.5rem;
  padding: 0 0.3rem;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  animation: rise 800ms ease forwards;
}

.reveal-delay-1 {
  animation-delay: 120ms;
}

.reveal-delay-2 {
  animation-delay: 240ms;
}

.reveal-delay-3 {
  animation-delay: 360ms;
}

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

@media (max-width: 1000px) {
  .hero-grid,
  .cards-grid,
  .split-layout,
  .profile-grid,
  .skills-grid,
  .contact-strip {
    grid-template-columns: 1fr;
  }

  .cta,
  .site-footer,
  .top-nav {
    flex-direction: column;
    align-items: flex-start;
  }

  .top-nav {
    border-radius: 24px;
  }
}

@media (max-width: 720px) {
  .page-shell {
    width: min(calc(100% - 1rem), var(--content-width));
    padding-top: 0.75rem;
  }

  h1 {
    font-size: clamp(2.5rem, 12vw, 4rem);
  }

  .hero-copy,
  .hero-card,
  .panel,
  .cta {
    padding: 1.3rem;
    border-radius: 24px;
  }

  .nav-links {
    gap: 0.7rem;
  }

  .contact-strip li {
    padding: 0.9rem;
  }
}
