:root {
  --bg: #fbfaf7;
  --surface: rgba(255, 255, 255, 0.88);
  --surface-strong: #ffffff;
  --ink: #121212;
  --muted: #666055;
  --line: rgba(18, 18, 18, 0.08);
  --accent: #8d6a3a;
  --accent-soft: rgba(141, 106, 58, 0.1);
  --shadow: 0 24px 70px rgba(31, 24, 18, 0.08);
  --headline: "Didot", "Bodoni 72", "Iowan Old Style", "Times New Roman", serif;
  --body: "Avenir Next", "Helvetica Neue", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--body);
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(141, 106, 58, 0.08), transparent 26%),
    radial-gradient(circle at 85% 10%, rgba(210, 199, 180, 0.22), transparent 24%),
    linear-gradient(180deg, #fffdf9 0%, #f7f4ee 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.page-glow {
  pointer-events: none;
  position: fixed;
  inset: 0;
}

.page-glow {
  filter: blur(90px);
  opacity: 0.48;
}

.page-glow-left {
  background: rgba(185, 151, 106, 0.12);
  transform: translate(-28%, -12%);
}

.page-glow-right {
  background: rgba(226, 214, 196, 0.36);
  transform: translate(55%, 18%);
}

.site-header,
.section,
.marquee {
  width: min(1160px, calc(100vw - 40px));
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 0 14px;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(14px);
  background: linear-gradient(180deg, rgba(255, 253, 249, 0.92), rgba(255, 253, 249, 0.56));
}

.brand {
  font-family: var(--headline);
  font-size: 1.3rem;
  letter-spacing: 0.04em;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 120px;
  min-height: 48px;
}

.brand-orb {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 30%, #c9ab7e, #8d6a3a 65%, rgba(141, 106, 58, 0.4));
  box-shadow:
    0 0 0 0 rgba(141, 106, 58, 0.24),
    0 0 28px rgba(141, 106, 58, 0.22);
  animation: brand-pulse 3.4s ease-in-out infinite;
}

.brand-orb-delay {
  width: 6px;
  height: 6px;
  opacity: 0.78;
  animation-delay: 0.9s;
}

.brand-line {
  width: 56px;
  height: 1px;
  background: linear-gradient(90deg, rgba(141, 106, 58, 0.9), rgba(141, 106, 58, 0.08));
  transform-origin: left center;
  animation: brand-line-glow 4.2s ease-in-out infinite;
}

.nav {
  display: flex;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--muted);
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow);
}

.nav a {
  padding: 10px 14px;
  border-radius: 999px;
  transition:
    background-color 220ms ease,
    color 220ms ease;
}

.nav a:hover,
.nav a:focus-visible {
  background: var(--accent-soft);
  color: var(--ink);
}

.section {
  padding: 64px 0;
}

.hero {
  min-height: calc(100vh - 110px);
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, 360px);
  gap: 36px;
  align-items: center;
}

.eyebrow {
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.74rem;
  color: var(--accent);
}

.hero h1,
.section-heading h2,
.skills-panel h2,
.site-footer h2 {
  margin: 0;
  font-family: var(--headline);
  line-height: 0.96;
  letter-spacing: -0.03em;
}

.hero h1 {
  font-size: clamp(4.6rem, 12vw, 8.6rem);
  max-width: 9ch;
  line-height: 0.9;
}

.hero-title {
  transform-origin: left center;
  position: relative;
  padding-bottom: 12px;
  animation: hero-entrance 1s cubic-bezier(0.2, 0.9, 0.2, 1) both;
}

.hero-title::after {
  content: "";
  position: absolute;
  left: 2px;
  bottom: 0;
  width: min(140px, 38%);
  height: 2px;
  background: linear-gradient(90deg, var(--accent), rgba(141, 106, 58, 0.08));
}

.hero-title-beat {
  display: inline-block;
  transform-origin: left center;
  animation: heartbeat 2.8s ease-in-out 1.1s infinite;
}

.hero-subtitle {
  margin: 18px 0 0;
  font-size: 1.16rem;
  font-weight: 500;
  color: var(--muted);
  opacity: 0;
  animation: fade-up 0.8s ease 0.28s forwards;
}

.lead {
  max-width: 36rem;
  margin: 20px 0 0;
  font-size: 1.03rem;
  line-height: 1.9;
  color: var(--muted);
  opacity: 0;
  animation: fade-up 0.8s ease 0.42s forwards;
}

.hero-actions {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 30px;
  opacity: 0;
  animation: fade-up 0.8s ease 0.56s forwards;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  font-size: 0.95rem;
  transition:
    transform 220ms ease,
    background-color 220ms ease,
    color 220ms ease,
    border-color 220ms ease;
}

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

.button-primary {
  background: var(--ink);
  color: #ffffff;
}

.button-secondary {
  border: 1px solid var(--line);
  background: var(--surface-strong);
}

.hero-panel,
.card,
.timeline-item,
.project-card,
.skills-panel,
.quote-panel {
  border: 1px solid var(--line);
  background: var(--surface);
  backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.hero-panel {
  padding: 30px;
  border-radius: 32px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.98), rgba(250, 246, 238, 0.82)),
    var(--surface);
}

.hero-stat + .hero-stat {
  margin-top: 22px;
}

.note-label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero-panel-mark {
  position: absolute;
  right: 18px;
  bottom: -18px;
  font-family: var(--headline);
  font-size: 7rem;
  line-height: 1;
  color: rgba(141, 106, 58, 0.08);
  pointer-events: none;
}

.summary-grid,
.split-layout,
.projects-block,
.compact-grid,
.site-footer {
  border-top: 1px solid var(--line);
}

.section-heading {
  display: grid;
  gap: 14px;
  margin-bottom: 28px;
}

.section-heading h2,
.skills-panel h2,
.site-footer h2 {
  font-size: clamp(2.35rem, 5vw, 4.6rem);
  max-width: 11ch;
  line-height: 0.98;
}

.intro-cards,
.project-list,
.compact-grid {
  display: grid;
  gap: 18px;
}

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

.card,
.timeline-item,
.project-card,
.skills-panel,
.quote-panel {
  border-radius: 28px;
  padding: 28px;
}

.card h3,
.timeline-item h3,
.project-card h3 {
  margin: 0 0 10px;
  font-size: 1.3rem;
  font-family: var(--headline);
  letter-spacing: 0.01em;
}

.card-date {
  display: block;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 0.9rem;
  letter-spacing: 0.03em;
}

.card p:last-child,
.timeline-item p:last-child,
.project-card p,
.quote-note {
  color: var(--muted);
  line-height: 1.78;
}

.detail-list {
  margin: 0;
  padding-left: 22px;
  color: var(--muted);
  line-height: 1.8;
}

.detail-list li + li {
  margin-top: 10px;
}

.card,
.timeline-item,
.project-card,
.skills-panel,
.quote-panel,
.hero-panel {
  transition:
    transform 280ms ease,
    box-shadow 280ms ease,
    border-color 280ms ease;
}

.card:hover,
.timeline-item:hover,
.project-card:hover,
.skills-panel:hover,
.quote-panel:hover,
.hero-panel:hover {
  transform: translateY(-4px);
  box-shadow: 0 28px 90px rgba(31, 24, 18, 0.1);
  border-color: rgba(141, 106, 58, 0.18);
}

.timeline {
  display: grid;
  gap: 18px;
}

.timeline-item {
  position: relative;
  overflow: hidden;
}

.timeline-item::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: linear-gradient(180deg, var(--accent), rgba(141, 106, 58, 0.18));
}

.timeline-date,
.project-meta,
.timeline-role {
  color: var(--muted);
}

.timeline-date,
.project-meta span {
  font-size: 0.84rem;
  letter-spacing: 0.04em;
}

.timeline-role {
  margin: 0 0 12px;
  font-weight: 600;
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
}

.project-card + .project-card {
  margin-top: 16px;
}

.project-meta {
  margin-bottom: 14px;
}

.tag-row,
.contact-list {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.tag-row {
  margin-top: 18px;
}

.tag-row span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.82);
  font-size: 0.92rem;
}

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

.skill-group h3 {
  margin: 0 0 8px;
  font-family: var(--headline);
  font-size: 1.18rem;
}

.skill-group p {
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.compact-grid {
  grid-template-columns: 1.15fr 0.85fr;
  align-items: start;
}

.quote-panel {
  min-height: 100%;
  background: var(--surface);
}

.education-stack {
  display: grid;
  gap: 18px;
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: end;
  padding-bottom: 70px;
}

.contact-list a {
  min-height: 44px;
  padding: 0 18px;
  align-items: center;
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-strong);
}

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

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

@keyframes hero-entrance {
  0% {
    opacity: 0;
    transform: scale(0.64);
    letter-spacing: 0.12em;
    filter: blur(8px);
  }
  60% {
    opacity: 1;
    transform: scale(1.06);
    letter-spacing: 0.01em;
    filter: blur(0);
  }
  100% {
    opacity: 1;
    transform: scale(1);
    letter-spacing: -0.03em;
    filter: blur(0);
  }
}

@keyframes heartbeat {
  0%,
  40%,
  100% {
    transform: scale(1);
  }
  8% {
    transform: scale(1.045);
  }
  16% {
    transform: scale(0.99);
  }
  24% {
    transform: scale(1.085);
  }
  32% {
    transform: scale(1);
  }
}

@keyframes brand-pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow:
      0 0 0 0 rgba(141, 106, 58, 0.18),
      0 0 22px rgba(141, 106, 58, 0.16);
  }
  50% {
    transform: scale(1.35);
    box-shadow:
      0 0 0 10px rgba(141, 106, 58, 0),
      0 0 30px rgba(201, 171, 126, 0.3);
  }
}

@keyframes brand-line-glow {
  0%,
  100% {
    opacity: 0.7;
    transform: scaleX(0.9);
  }
  50% {
    opacity: 1;
    transform: scaleX(1.08);
  }
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 980px) {
  .hero,
  .compact-grid,
  .site-footer,
  .intro-cards {
    grid-template-columns: 1fr;
  }

  .skill-groups {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 26px;
  }

  .site-footer {
    align-items: start;
  }
}

@media (max-width: 720px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .nav {
    gap: 6px;
    flex-wrap: wrap;
    border-radius: 22px;
  }

  .section,
  .site-header {
    width: min(1160px, calc(100vw - 28px));
  }

  .hero h1 {
    font-size: clamp(3rem, 18vw, 4.8rem);
  }

  .section-heading h2,
  .skills-panel h2,
  .site-footer h2 {
    max-width: none;
    font-size: clamp(2.1rem, 12vw, 3.2rem);
  }

  .card,
  .timeline-item,
  .experience-card,
  .project-card,
  .skills-panel,
  .quote-panel,
  .hero-panel {
    border-radius: 22px;
    padding: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-title,
  .hero-title-beat,
  .brand-orb,
  .brand-line,
  .hero-subtitle,
  .lead,
  .hero-actions,
  .reveal {
    transition: none;
    animation: none;
  }

  .hero-subtitle,
  .lead,
  .hero-actions,
  .reveal {
    opacity: 1;
    transform: none;
  }
}
