:root {
  color-scheme: light;
  --bg: oklch(1 0 0);
  --surface: oklch(0.965 0.006 49);
  --ink: oklch(0.17 0.018 45);
  --muted: oklch(0.46 0.018 45);
  --primary: oklch(0.62 0.189 49);
  --primary-dark: oklch(0.48 0.17 45);
  --accent: oklch(0.31 0.12 252);
  --line: oklch(0.86 0.012 45);
  --code-bg: oklch(0.205 0.023 45);
  --page-pad: clamp(1rem, 4vw, 4rem);
  --content: 90rem;
  font-family: "Onest", system-ui, sans-serif;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 20rem;
  background: var(--bg);
  color: var(--ink);
  font-size: 1rem;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

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

button {
  font: inherit;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.65rem 0.9rem;
  border: 2px solid var(--ink);
  background: var(--bg);
  font-weight: 700;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 3px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(100%, var(--content));
  min-height: 5.25rem;
  margin: 0 auto;
  padding: 0 var(--page-pad);
  border-bottom: 1px solid var(--line);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.wordmark-mark {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  background: var(--primary);
  color: var(--bg);
  font-size: 0.88rem;
  font-weight: 800;
}

.site-header nav {
  display: flex;
  align-items: center;
  gap: clamp(0.8rem, 2vw, 1.8rem);
}

.nav-link,
.nav-action {
  font-size: 0.92rem;
  font-weight: 650;
  text-decoration: none;
}

.nav-link {
  color: var(--muted);
}

.nav-link:hover {
  color: var(--ink);
}

.nav-action {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
}

.hero {
  display: grid;
  grid-template-columns: minmax(18rem, 0.8fr) minmax(34rem, 1.2fr);
  gap: clamp(2.5rem, 6vw, 7rem);
  align-items: center;
  width: min(100%, var(--content));
  min-height: min(52rem, calc(100svh - 5.25rem));
  margin: 0 auto;
  padding: clamp(4rem, 8vw, 7.5rem) var(--page-pad);
  overflow: hidden;
}

.hero-copy {
  position: relative;
  z-index: 2;
}

.hero-kicker {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 1.6rem;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-kicker > span {
  width: 0.7rem;
  height: 0.7rem;
  background: var(--primary);
}

.hero h1 {
  max-width: 11ch;
  margin: 0;
  font-size: clamp(3.35rem, 6.5vw, 5.5rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 0.95;
}

.hero h1 span {
  display: block;
  color: var(--primary-dark);
}

.hero-summary {
  max-width: 35rem;
  margin: 1.7rem 0 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 1.5vw, 1.22rem);
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.1rem;
}

.button {
  display: inline-flex;
  min-height: 3rem;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.8rem 1.15rem;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 160ms ease, background-color 160ms ease, color 160ms ease;
}

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

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

.button-secondary {
  border-color: var(--line);
  background: var(--bg);
}

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

.hero-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1.3rem;
  margin: 1.5rem 0 0;
  padding: 0;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  list-style: none;
}

.hero-proof li::before {
  content: "✓";
  margin-right: 0.35rem;
  color: var(--primary-dark);
  font-weight: 800;
}

.product-stage {
  position: relative;
  min-height: 40rem;
  isolation: isolate;
}

.product-stage::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: -3.5rem -12rem -4rem 22%;
  background: var(--primary);
}

.product-stage::after {
  content: "";
  position: absolute;
  z-index: -1;
  right: -2rem;
  bottom: 1.5rem;
  width: 9rem;
  height: 2.25rem;
  border: 1px solid oklch(0.8 0.12 49);
  background: oklch(0.72 0.175 49);
  transform: rotate(-4deg);
}

.yaml-panel,
.portfolio-window {
  overflow: hidden;
  border: 1px solid oklch(0.2 0.018 45 / 28%);
  border-radius: 0.75rem;
  box-shadow: 0 1.4rem 4rem oklch(0.22 0.05 45 / 18%);
}

.yaml-panel {
  position: absolute;
  z-index: 3;
  top: 2.6rem;
  left: 0;
  width: min(24rem, 52%);
  background: var(--code-bg);
  color: oklch(0.9 0.012 85);
  transform: rotate(-2deg);
}

.panel-bar,
.browser-bar {
  display: flex;
  min-height: 2.7rem;
  align-items: center;
  gap: 0.55rem;
  padding: 0 0.8rem;
  border-bottom: 1px solid oklch(1 0 0 / 12%);
  font-size: 0.72rem;
  font-weight: 650;
}

.file-dot {
  width: 0.55rem;
  height: 0.55rem;
  background: var(--primary);
}

.saved-state {
  margin-left: auto;
  color: oklch(0.7 0.03 95);
}

.yaml-panel pre {
  margin: 0;
  padding: 1.25rem;
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: clamp(0.68rem, 1vw, 0.79rem);
  line-height: 1.7;
  tab-size: 2;
}

.yaml-key {
  color: oklch(0.79 0.13 72);
}

.yaml-value {
  color: oklch(0.86 0.1 225);
}

.yaml-active {
  display: inline-block;
  padding: 0 0.28rem;
  background: oklch(0.4 0.12 252);
  color: oklch(0.95 0.04 225);
}

.portfolio-window {
  position: absolute;
  z-index: 2;
  right: 0;
  bottom: 1rem;
  width: min(38rem, 79%);
  background: var(--bg);
  transition: background-color 200ms ease, color 200ms ease;
}

.browser-bar {
  border-color: var(--line);
  background: oklch(0.975 0.004 45);
  color: var(--muted);
}

.browser-controls {
  display: flex;
  gap: 0.3rem;
}

.browser-controls span {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: oklch(0.77 0.015 45);
}

.browser-address {
  margin: 0 auto;
  padding: 0.28rem 1.8rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg);
  font-size: 0.65rem;
}

.browser-status {
  color: oklch(0.45 0.13 145);
}

.browser-status::before {
  content: "";
  display: inline-block;
  width: 0.42rem;
  height: 0.42rem;
  margin-right: 0.3rem;
  border-radius: 50%;
  background: oklch(0.65 0.16 145);
}

.portfolio-page {
  min-height: 29rem;
  padding: clamp(1.15rem, 3vw, 2.2rem);
  background: var(--preview-bg, oklch(0.18 0.035 252));
  color: var(--preview-ink, oklch(0.96 0.015 250));
  transition: background-color 220ms ease, color 220ms ease;
}

.portfolio-nav {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  font-size: 0.68rem;
  font-weight: 650;
}

.portfolio-logo {
  display: grid;
  width: 2rem;
  height: 2rem;
  margin-right: auto;
  place-items: center;
  background: var(--preview-accent, oklch(0.8 0.13 224));
  color: var(--preview-accent-ink, oklch(0.18 0.035 252));
  font-size: 0.63rem;
  font-weight: 800;
}

.portfolio-intro {
  max-width: 25rem;
  margin-top: clamp(3rem, 7vw, 5.2rem);
  margin-left: 42%;
}

.portfolio-intro > p {
  margin: 0 0 0.65rem;
  color: var(--preview-muted, oklch(0.76 0.035 250));
  font-size: 0.67rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.portfolio-intro h2 {
  margin: 0;
  font-size: clamp(1.65rem, 3.4vw, 2.7rem);
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.portfolio-intro ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 1.15rem 0 0;
  padding: 0;
  list-style: none;
}

.portfolio-intro li {
  padding: 0.35rem 0.6rem;
  border: 1px solid var(--preview-line, oklch(0.55 0.05 252));
  border-radius: 999px;
  font-size: 0.57rem;
}

.project-list {
  margin-top: 2.2rem;
  border-top: 1px solid var(--preview-line, oklch(0.55 0.05 252));
}

.project-list article {
  display: grid;
  grid-template-columns: 1.5rem 1fr auto;
  gap: 0.65rem;
  align-items: center;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--preview-line, oklch(0.55 0.05 252));
}

.project-list article > span {
  color: var(--preview-muted, oklch(0.76 0.035 250));
  font-size: 0.57rem;
}

.project-list h3,
.project-list p {
  margin: 0;
}

.project-list h3 {
  font-size: 0.78rem;
}

.project-list p {
  margin-top: 0.12rem;
  color: var(--preview-muted, oklch(0.76 0.035 250));
  font-size: 0.58rem;
}

.theme-control {
  display: flex;
  width: 100%;
  min-height: 3rem;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1rem;
  border: 0;
  border-top: 1px solid var(--line);
  background: var(--bg);
  color: var(--muted);
  cursor: pointer;
  font-size: 0.72rem;
  text-align: left;
}

.theme-control:hover {
  color: var(--ink);
}

.theme-control strong {
  color: var(--ink);
}

.theme-control > span:last-child {
  margin-left: auto;
  color: var(--ink);
  font-size: 1rem;
}

.theme-swatch {
  width: 0.72rem;
  height: 0.72rem;
  border-radius: 50%;
  background: var(--preview-accent, oklch(0.8 0.13 224));
  box-shadow: 0 0 0 3px oklch(0.9 0.02 49);
}

[data-portfolio-theme="sunset-light"] {
  --preview-bg: oklch(0.96 0.035 67);
  --preview-ink: oklch(0.24 0.05 36);
  --preview-muted: oklch(0.49 0.045 38);
  --preview-line: oklch(0.79 0.06 49);
  --preview-accent: oklch(0.66 0.19 37);
  --preview-accent-ink: oklch(0.99 0.01 67);
}

[data-portfolio-theme="forest-dark"] {
  --preview-bg: oklch(0.2 0.04 155);
  --preview-ink: oklch(0.95 0.025 145);
  --preview-muted: oklch(0.75 0.045 145);
  --preview-line: oklch(0.47 0.055 153);
  --preview-accent: oklch(0.76 0.13 126);
  --preview-accent-ink: oklch(0.2 0.04 155);
}

.stage-label {
  position: absolute;
  z-index: 4;
  top: 0;
  left: -1.2rem;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  color: oklch(0.32 0.08 45);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.stage-label span {
  display: grid;
  width: 1.8rem;
  height: 1.8rem;
  place-items: center;
  border: 1px solid oklch(0.33 0.09 45);
  border-radius: 50%;
  font-size: 0.58rem;
}

.stage-label-result {
  inset: auto 0 0 auto;
}

.flow-arrow {
  position: absolute;
  z-index: 5;
  top: 46%;
  left: 38%;
  display: grid;
  width: 3rem;
  height: 3rem;
  place-items: center;
  border: 3px solid var(--bg);
  border-radius: 50%;
  background: var(--ink);
  color: var(--bg);
}

.flow-arrow svg {
  width: 1.4rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.how-it-works {
  display: grid;
  grid-template-columns: minmax(15rem, 0.7fr) minmax(25rem, 1.3fr);
  gap: clamp(3rem, 8vw, 9rem);
  width: min(100%, var(--content));
  margin: 0 auto;
  padding: clamp(5rem, 10vw, 9rem) var(--page-pad);
  border-top: 1px solid var(--line);
}

.process-intro h2 {
  max-width: 12ch;
  margin: 0;
  font-size: clamp(2.2rem, 4.5vw, 4rem);
  letter-spacing: -0.035em;
  line-height: 1.03;
}

.process-intro p {
  max-width: 30rem;
  margin: 1.25rem 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.process-list {
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--ink);
  list-style: none;
  counter-reset: steps;
}

.process-list li {
  display: grid;
  grid-template-columns: 2rem minmax(9rem, 0.7fr) minmax(14rem, 1.3fr);
  gap: 1rem;
  align-items: baseline;
  padding: 1.65rem 0;
  border-bottom: 1px solid var(--line);
}

.process-list li > span {
  color: var(--primary-dark);
  font-size: 0.75rem;
  font-weight: 800;
}

.process-list h3,
.process-list p {
  margin: 0;
}

.process-list h3 {
  font-size: 1rem;
}

.process-list p {
  color: var(--muted);
  font-size: 0.94rem;
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 8rem;
  padding: 2rem var(--page-pad);
  background: var(--ink);
  color: var(--bg);
}

footer p {
  margin: 0;
  font-size: clamp(1.2rem, 2vw, 1.8rem);
  font-weight: 700;
  letter-spacing: -0.025em;
}

footer a {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.88rem;
  font-weight: 650;
  text-decoration: none;
}

.is-ready .hero-copy {
  animation: rise-in 540ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

.is-ready .product-stage {
  animation: reveal-stage 680ms 80ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(1rem);
  }
}

@keyframes reveal-stage {
  from {
    opacity: 0;
    clip-path: inset(0 0 100% 0);
  }

  to {
    opacity: 1;
    clip-path: inset(0);
  }
}

@media (max-width: 68rem) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    overflow: visible;
  }

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

  .product-stage {
    width: min(100%, 52rem);
    margin: 0 auto;
  }

  .product-stage::before {
    inset: -2.5rem calc(var(--page-pad) * -1) -3rem 18%;
  }
}

@media (max-width: 45rem) {
  .site-header {
    min-height: 4.5rem;
  }

  .nav-link {
    display: none;
  }

  .hero {
    padding-top: 3.5rem;
  }

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

  .product-stage {
    display: grid;
    gap: 1rem;
    min-height: auto;
    padding: 2.6rem 0;
  }

  .product-stage::before {
    inset: 0 calc(var(--page-pad) * -1);
  }

  .product-stage::after,
  .flow-arrow,
  .stage-label {
    display: none;
  }

  .yaml-panel,
  .portfolio-window {
    position: relative;
    inset: auto;
    width: 100%;
    transform: none;
  }

  .yaml-panel pre {
    overflow-x: auto;
  }

  .portfolio-page {
    min-height: 25rem;
  }

  .portfolio-intro {
    margin-left: 0;
  }

  .how-it-works {
    grid-template-columns: 1fr;
  }

  .process-list li {
    grid-template-columns: 1.5rem 1fr;
  }

  .process-list p {
    grid-column: 2;
  }

  footer {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
  }
}

@media (max-width: 24rem) {
  .wordmark > span:last-child {
    display: none;
  }

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

  .hero h1 {
    font-size: 2.85rem;
  }

  .browser-address {
    padding-inline: 0.7rem;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
