:root {
  --intro-bg: var(--bg, #000);
  --intro-fg: var(--text, #ececec);
  --intro-muted: var(--muted, #8b8b8b);
  --intro-accent: #ff6a2b;
  --intro-mono: ui-monospace, "JetBrains Mono", "SFMono-Regular", Menlo, Consolas, monospace;
}

.intro__canvas {
  position: fixed;
  top: 0;
  left: 0;
  z-index: -1;
  display: block;
  width: 100vw;
  height: 100lvh;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.2s ease;
}

.intro__canvas.is-ready {
  opacity: 1;
}

.intro {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: calc(100svh - 4rem);
  padding-bottom: 2rem;
}

.intro > * {
  animation: intro-rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.cv {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
}

.cv__toggle {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border: 0;
  background: none;
  color: var(--intro-fg);
  font: inherit;
  text-decoration: underline;
  text-decoration-color: var(--intro-muted);
  text-underline-offset: 3px;
  cursor: pointer;
}

.cv__toggle::after {
  content: "";
  width: 0.38em;
  height: 0.38em;
  margin-left: 0.5em;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  transition: transform 0.25s ease;
}

.cv__toggle[aria-expanded="true"]::after {
  transform: rotate(135deg);
}

.intro__links .cv__options a:hover,
.intro__links .cv__options a:focus-visible {
  background: var(--intro-accent);
  border-color: var(--intro-accent);
  color: #000;
}

.cv__options:not([hidden]) {
  display: inline-flex;
  gap: 0.5rem;
}

.cv__options a {
  padding: 0.2rem 0.65rem;
  border: 1px solid rgb(255 106 43 / 0.55);
  background: rgb(255 106 43 / 0.08);
  font-family: var(--intro-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-decoration: none;
  animation: cv-in 0.3s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.cv__options a + a {
  animation-delay: 0.06s;
}

.cv__options a:hover,
.cv__options a:focus-visible {
  background: var(--intro-accent);
  border-color: var(--intro-accent);
  color: #000;
}

@keyframes cv-in {
  from { opacity: 0; transform: translateX(-8px); }
}

.intro > :nth-child(1) { animation-delay: 0.8s; }
.intro > :nth-child(2) { animation-delay: 0.95s; }
.intro > :nth-child(3) { animation-delay: 1.1s; }
.intro > :nth-child(4) { animation-delay: 1.25s; }
.intro > :nth-child(5) { animation: intro-fade 1s ease 2s both; }

.intro__eyebrow {
  margin: 0 0 0.75rem;
  font-family: var(--intro-mono);
  font-size: 1rem;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: rgb(255 145 0);
}

.intro__title {
  margin: 0;
  font-size: clamp(2.5rem, 9vw, 4.5rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.03em;
}

.intro__lede {
  margin: 1rem 0 1.4rem;
  max-width: 34rem;
  color: #bab8b8;
  text-shadow: #8b8b8b 2px 0 10px;
}

.intro__links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: 0.9rem;
}

.intro__links a:hover,
.intro__links a:focus-visible {
  color: var(--intro-accent);
  text-decoration-color: currentColor;
}

.intro__meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 3.5rem;
  font-family: var(--intro-mono);
  font-size: 0.72rem;
  color: var(--intro-muted);
}

.intro__meta p {
  margin: 0;
  opacity: 0.7;
}

.intro__meta a {
  color: inherit;
  text-decoration: none;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.intro__meta a:hover,
.intro__meta a:focus-visible {
  color: var(--intro-fg);
}

@keyframes intro-rise {
  from { opacity: 0; transform: translateY(14px); }
}

@keyframes intro-fade {
  from { opacity: 0; }
}

@media (max-width: 34rem) {
  .intro {
    min-height: calc(100svh - 2.5rem);
  }

  .intro__meta p {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .intro__canvas,
  .intro > *,
  .cv__options a {
    animation: none !important;
    transition: none;
  },
  .cv__toggle::after {
    transition: none;
  }
}
