:root {
  --paper: #fafaf9;
  --header-paper: rgba(255, 255, 253, 0.94);
  --nav-paper: rgba(254, 254, 252, 0.96);
  --ink: #1c1917;
  --muted: #78716c;
  --line: #e7e5e4;
  --accent: #e11d48;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family:
    "Avenir Next", Avenir, "Helvetica Neue", ui-sans-serif, system-ui,
    -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

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

p,
h1,
h2,
h3,
ul,
figure {
  margin: 0;
}

.top-anchor {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 1px;
  pointer-events: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  justify-items: center;
  min-height: 76px;
  padding: 0 52px;
  color: var(--ink);
  background: var(--header-paper);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
  overflow: visible;
  cursor: pointer;
  user-select: none;
}

.brand {
  position: relative;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  min-width: 250px;
  min-height: 54px;
  padding: 2px 32px 4px;
  border-radius: 999px;
  font-family:
    "Snell Roundhand", "Brush Script MT", "Segoe Script", "Apple Chancery",
    cursive;
  font-size: clamp(2.05rem, 3.8vw, 3.15rem);
  font-weight: 500;
  line-height: 1;
  text-transform: lowercase;
  transform-origin: center;
  overflow: visible;
}

.brand-text {
  display: inline-block;
  padding-right: 0.28em;
  padding-left: 0.08em;
  margin-right: -0.14em;
  margin-left: -0.04em;
  transform-origin: center;
  overflow: visible;
}

.brand::before {
  position: absolute;
  inset: 7px 10px;
  z-index: -1;
  content: "";
  border-radius: 999px;
  opacity: 0;
  transform: scaleX(0.9) scaleY(0.76);
}

.brand::before {
  background: var(--header-paper);
}

.brand.is-swallowing {
  animation: brand-gulp 1248ms cubic-bezier(0.2, 0.85, 0.2, 1);
}

.brand.is-swallowing .brand-text {
  animation: brand-ripple 1248ms cubic-bezier(0.2, 0.85, 0.2, 1);
}

.brand.is-swallowing::before {
  animation: membrane 1248ms cubic-bezier(0.2, 0.85, 0.2, 1);
}

.site-header.is-animation-paused .brand,
.site-header.is-animation-paused .brand *,
.site-header.is-animation-paused .brand::before {
  animation-play-state: paused;
}

.site-nav {
  position: sticky;
  top: 76px;
  z-index: 9;
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 52px;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: lowercase;
  letter-spacing: 0;
  background: var(--nav-paper);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.site-nav a {
  padding: 8px 0;
  color: var(--muted);
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--accent);
  outline: none;
}

.emoji-lane {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.emoji {
  position: absolute;
  top: 15px;
  left: 0;
  font-size: 1.55rem;
  line-height: 1;
  filter: saturate(1.1);
  transform: translate3d(-48px, 0, 0);
  will-change: transform, opacity;
}

.emoji.is-entering {
  filter: saturate(0.9) contrast(1.05);
}

@keyframes brand-gulp {
  0% {
    transform: scaleX(1) scaleY(1);
  }
  22% {
    transform: scaleX(1.18) scaleY(0.86);
  }
  43% {
    transform: scaleX(0.88) scaleY(1.22);
  }
  66% {
    transform: scaleX(1.12) scaleY(0.93);
  }
  100% {
    transform: scaleX(1) scaleY(1);
  }
}

@keyframes brand-ripple {
  0% {
    transform: translateX(0) skewX(0deg);
  }
  25% {
    transform: translateX(8px) skewX(-8deg);
  }
  50% {
    transform: translateX(-6px) skewX(6deg);
  }
  75% {
    transform: translateX(3px) skewX(-3deg);
  }
  100% {
    transform: translateX(0) skewX(0deg);
  }
}

@keyframes membrane {
  0% {
    opacity: 0;
    transform: scaleX(0.74) scaleY(0.58);
  }
  30% {
    opacity: 0.92;
    transform: scaleX(1.1) scaleY(0.72);
  }
  54% {
    opacity: 0.72;
    transform: scaleX(0.88) scaleY(1.18);
  }
  100% {
    opacity: 0;
    transform: scaleX(1.26) scaleY(0.86);
  }
}

.section {
  position: relative;
  min-height: calc(100svh - 118px);
  padding: 185px 52px 72px;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}

.hero {
  padding-top: 38px;
}

.section[id] {
  scroll-margin-top: 116px;
}

#top {
  scroll-margin-top: 0;
}

.section-jump {
  position: absolute;
  left: 50%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 28px;
  height: 20px;
  color: rgba(120, 113, 108, 0.34);
  transform: translateX(-50%);
}

.section-jump::before {
  width: 11px;
  height: 11px;
  content: "";
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
}

.section-jump-up {
  top: 7px;
}

.section-jump-up::before {
  transform: translateY(4px) rotate(225deg);
}

.section-jump-down {
  bottom: 18px;
}

.section-jump-down::before {
  transform: translateY(-4px) rotate(45deg);
}

.section-jump:hover,
.section-jump:focus-visible {
  color: rgba(28, 25, 23, 0.7);
  outline: none;
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.58fr);
  gap: 72px;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
}

.hero-grid {
  grid-template-columns: minmax(0, 1fr);
  max-width: 790px;
}

.fix-grid {
  grid-template-columns: minmax(180px, 0.42fr) minmax(360px, 0.72fr);
  gap: 44px;
  max-width: 880px;
}

.copy-column {
  max-width: 790px;
}

.copy-column.wide {
  grid-column: 1 / -1;
  max-width: 980px;
}

h1 {
  max-width: 760px;
  margin-bottom: 44px;
  font-size: 6.25rem;
  font-weight: 700;
  line-height: 0.92;
}

.hero-heading {
  max-width: 790px;
  margin-bottom: 28px;
  font-size: clamp(1.55rem, 2.1vw, 2.15rem);
  font-weight: 700;
  line-height: 1.18;
}

.section-title {
  max-width: 420px;
  font-size: clamp(1.65rem, 2.3vw, 2.45rem);
  font-weight: 650;
  line-height: 1.12;
}

.column-title {
  width: fit-content;
  margin-bottom: 24px;
  color: var(--muted);
  font-size: 1.02rem;
  font-weight: 500;
  line-height: 1.3;
}

.column-title::after {
  display: block;
  width: 42px;
  height: 1px;
  margin-top: 12px;
  content: "";
  background: rgba(120, 113, 108, 0.28);
}

.column-title .cursive-wordmark {
  color: var(--ink);
}

.copy-column p,
.pattern-list,
.lorem-column p {
  font-size: 1.58rem;
  font-weight: 400;
  line-height: 1.55;
}

.copy-column p + p {
  margin-top: 22px;
}

.hero .copy-column p + p,
.hero .copy-block + p {
  margin-top: 34px;
}

.copy-block {
  display: grid;
  grid-template-columns: minmax(0, max-content) 42px;
  align-items: center;
  gap: 12px;
  width: fit-content;
  max-width: 100%;
  margin: 22px auto 0;
  padding: 14px 14px 14px 18px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
}

.copy-block + p {
  margin-top: 22px;
}

.copy-block code {
  overflow-wrap: anywhere;
  font-family:
    "IBM Plex Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 1.02rem;
  line-height: 1.35;
}

.copy-button {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  cursor: pointer;
}

.copy-button:hover,
.copy-button:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
  outline: none;
}

.copy-button.is-copied {
  color: #15803d;
  border-color: #15803d;
}

.copy-button svg {
  grid-area: 1 / 1;
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
  transition: opacity 160ms ease, transform 160ms ease;
}

.copy-button .check-icon {
  opacity: 0;
  transform: scale(0.78);
}

.copy-button.is-copied .copy-icon {
  opacity: 0;
  transform: scale(0.78);
}

.copy-button.is-copied .check-icon {
  opacity: 1;
  transform: scale(1);
}

.pattern-list {
  display: grid;
  gap: 28px;
  padding: 0;
  list-style: none;
}

.pattern-list li {
  position: relative;
  min-height: 116px;
  padding: 0 0 26px;
  border-bottom: 1px solid var(--line);
}

.examples-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  row-gap: 48px;
}

.examples-heading {
  grid-column: 1 / -1;
}

.examples-column {
  min-width: 0;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.examples-list {
  display: grid;
  gap: 22px;
  padding: 0;
  font-size: 1.58rem;
  line-height: 1.55;
  list-style: none;
}

.examples-list a {
  border-bottom: 1px solid currentColor;
}

.examples-list a:hover,
.examples-list a:focus-visible {
  color: var(--accent);
  outline: none;
}

.lorem-column {
  align-self: end;
  color: var(--muted);
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.about-copy {
  align-self: start;
}

.about-copy a {
  border-bottom: 1px solid currentColor;
}

.about-copy a:hover,
.about-copy a:focus-visible {
  color: var(--accent);
  outline: none;
}

.cursive-wordmark {
  font-family:
    "Snell Roundhand", "Brush Script MT", "Segoe Script", "Apple Chancery",
    cursive;
  font-size: 1.28em;
  line-height: 1;
}

.site-footer {
  display: flex;
  align-items: center;
  min-height: 92px;
  padding: 0 52px;
  font-size: 0.78rem;
  font-weight: 700;
}

@media (max-width: 900px) {
  .site-header,
  .section,
  .site-footer {
    padding-right: 28px;
    padding-left: 28px;
  }

  .section {
    min-height: calc(100svh - 112px);
    padding-top: 142px;
  }

  .hero {
    padding-top: 36px;
  }

  .site-header {
    min-height: 70px;
  }

  .section-grid {
    grid-template-columns: 1fr;
    gap: 54px;
  }

  .site-nav {
    top: 70px;
    padding-right: 28px;
    padding-left: 28px;
  }

  h1 {
    font-size: 4.7rem;
  }

  .brand {
    min-width: 224px;
  }
}

@media (max-width: 560px) {
  .site-header,
  .section,
  .site-footer {
    padding-right: 20px;
    padding-left: 20px;
  }

  .section {
    min-height: calc(100svh - 108px);
    padding-top: 116px;
    padding-bottom: 58px;
  }

  .hero {
    padding-top: 32px;
  }

  .site-header {
    min-height: 66px;
  }

  .site-nav {
    top: 66px;
    gap: 14px;
    padding-right: 20px;
    padding-left: 20px;
    font-size: 0.72rem;
  }

  .brand {
    min-width: 196px;
    padding-right: 14px;
    padding-left: 14px;
  }

  .emoji {
    top: 16px;
    font-size: 1.12rem;
  }

  h1 {
    margin-bottom: 36px;
    font-size: 3.35rem;
  }

  .copy-column p,
  .pattern-list,
  .lorem-column p,
  .examples-list {
    font-size: 1.22rem;
    line-height: 1.5;
  }

  .pattern-list li {
    min-height: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .emoji-lane {
    display: none;
  }

  .brand,
  .brand *,
  .brand::before {
    animation: none !important;
  }
}
