:root {
  --paper: #f4efe6;
  --paper-2: #fffaf3;
  --ink: #1c1410;
  --ink-soft: #3d342c;
  --muted: #6d6258;
  --line: rgba(28, 20, 16, 0.12);
  --orange: #e85d04;
  --orange-deep: #c2410c;
  --night: #1c1410;
  --cream: #f7f1e8;
  --shadow: 0 24px 50px rgba(28, 20, 16, 0.08);
  --serif: "Newsreader", Georgia, serif;
  --sans: "Manrope", system-ui, sans-serif;
  --max: 1120px;
  --read: 42rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.65;
  background:
    radial-gradient(900px 420px at -10% -10%, rgba(232, 93, 4, 0.09), transparent 55%),
    linear-gradient(180deg, #f8f4ed 0%, var(--paper) 38%, #ebe3d6 100%);
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--orange-deep);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--ink);
}

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

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 50;
  background: var(--ink);
  color: var(--cream);
  padding: 0.6rem 0.9rem;
  text-decoration: none;
}

.skip:focus {
  top: 0.75rem;
}

.wrap {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(244, 239, 230, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.4rem;
  flex-wrap: wrap;
}

.wordmark {
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 650;
  letter-spacing: -0.03em;
  color: var(--ink);
  text-decoration: none;
  line-height: 1;
}

.wordmark em {
  font-style: italic;
  font-weight: 500;
  color: var(--orange);
}

.nav-toggle {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.nav-btn {
  display: none;
  border: 1px solid var(--line);
  background: var(--paper-2);
  color: var(--ink);
  font: 600 0.85rem var(--sans);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.45rem 0.7rem;
  cursor: pointer;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1.35rem;
}

.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--orange-deep);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(240px, 0.7fr);
  gap: 2.5rem;
  padding: 4.2rem 0 3.2rem;
  align-items: end;
}

.kicker {
  margin: 0 0 0.85rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--orange-deep);
}

.hero h1,
.page-head h1,
.tie-copy h1,
.article h1 {
  font-family: var(--serif);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.02;
}

.hero h1 {
  margin: 0 0 1rem;
  max-width: 14ch;
  font-size: clamp(3rem, 7vw, 5.4rem);
}

.lede {
  margin: 0;
  max-width: 38rem;
  color: var(--ink-soft);
  font-size: 1.15rem;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.8rem;
  padding: 0.65rem 1.1rem;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--cream);
  font: 700 0.95rem var(--sans);
  text-decoration: none;
}

.btn:hover {
  background: var(--orange);
  border-color: var(--orange);
  color: #1c1410;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
}

.btn-ghost:hover {
  background: var(--ink);
  color: var(--cream);
}

.hero-note {
  border-top: 1px solid var(--line);
  padding-top: 1.25rem;
}

.hero-note p {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

.hero-note a {
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 650;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.hero-note a:hover {
  color: var(--orange-deep);
}

.section {
  padding: 3.2rem 0;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.4rem;
}

.section-head h2,
.tie-block h2,
.article h2 {
  font-family: var(--serif);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.section-head a {
  font-weight: 700;
  text-decoration: none;
}

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

.post-card {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  background: var(--paper-2);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease;
}

.post-card:hover {
  transform: translateY(-3px);
  color: inherit;
}

.post-swatch {
  height: 8px;
  background: var(--orange);
}

.post-card:nth-child(2) .post-swatch { background: #1c1410; }
.post-card:nth-child(3) .post-swatch { background: #8a5a44; }

.post-body {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  padding: 1.25rem 1.2rem 1.35rem;
  height: 100%;
}

.post-meta,
.article-meta {
  margin: 0;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.post-card h3 {
  margin: 0;
  font-family: var(--serif);
  font-size: 1.55rem;
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.post-card p {
  margin: 0;
  color: var(--ink-soft);
}

.post-card .more {
  margin-top: auto;
  font-weight: 700;
  color: var(--orange-deep);
}

.tie-band {
  background: var(--night);
  color: var(--cream);
}

.tie-band a {
  color: #ffb07a;
}

.tie-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(180px, 0.55fr);
  gap: 2rem;
  align-items: center;
  padding: 3.5rem 0;
}

.tie-layout h2 {
  margin: 0.3rem 0 0.8rem;
  max-width: 12ch;
  font-family: var(--serif);
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 0.98;
}

.tie-layout p {
  margin: 0;
  max-width: 36rem;
  color: rgba(247, 241, 232, 0.82);
}

.tie-layout .btn {
  margin-top: 1.4rem;
  background: var(--orange);
  border-color: var(--orange);
  color: #1c1410;
}

.tie-layout .btn:hover {
  background: var(--cream);
  border-color: var(--cream);
}

.tie-art {
  justify-self: center;
  width: min(220px, 70%);
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 1.6rem 0 2.2rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.footer-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-footer nav {
  display: flex;
  gap: 1rem;
}

.site-footer a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 600;
}

.page-head {
  padding: 3.2rem 0 1.4rem;
  border-bottom: 1px solid var(--line);
}

.page-head h1 {
  margin: 0;
  font-size: clamp(2.6rem, 6vw, 4.4rem);
  max-width: 16ch;
}

.page-head .lede {
  margin-top: 0.9rem;
}

.stack {
  display: grid;
  gap: 0;
  padding: 1rem 0 3rem;
}

.stack-item {
  display: grid;
  grid-template-columns: 7.5rem minmax(0, 1fr);
  gap: 1.5rem;
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: inherit;
}

.stack-item:hover h2 {
  color: var(--orange-deep);
}

.stack-item h2 {
  margin: 0.25rem 0 0.4rem;
  font-family: var(--serif);
  font-size: clamp(1.7rem, 3vw, 2.2rem);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.stack-item p {
  margin: 0;
  max-width: 40rem;
  color: var(--ink-soft);
}

.article {
  width: min(100% - 2rem, var(--read));
  margin: 0 auto;
  padding: 2.6rem 0 3.5rem;
}

.article h1 {
  margin: 0.4rem 0 1rem;
  font-size: clamp(2.4rem, 5vw, 3.6rem);
}

.article-lead {
  margin: 0 0 1.6rem;
  font-family: var(--serif);
  font-size: 1.35rem;
  line-height: 1.45;
  color: var(--ink-soft);
}

.article h2 {
  margin: 2rem 0 0.6rem;
  font-size: 1.7rem;
}

.article p,
.article li {
  color: var(--ink-soft);
}

.article ul,
.article ol {
  padding-left: 1.2rem;
}

.callout {
  margin: 1.6rem 0;
  padding: 1rem 1.1rem;
  border-left: 3px solid var(--orange);
  background: rgba(232, 93, 4, 0.08);
}

.callout p {
  margin: 0;
}

.related {
  margin-top: 2.4rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--line);
}

.related h2 {
  margin-top: 0;
  font-size: 1.3rem;
}

.related ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.related li + li {
  margin-top: 0.45rem;
}

.tie-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(200px, 0.7fr);
  gap: 2rem;
  align-items: center;
  padding: 3.4rem 0 2.6rem;
}

.tie-copy h1 {
  margin: 0 0 0.8rem;
  font-size: clamp(3rem, 7vw, 5.2rem);
  max-width: 10ch;
}

.toc {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 0;
  padding: 0 0 1.4rem;
  list-style: none;
  border-bottom: 1px solid var(--line);
}

.toc a {
  display: inline-block;
  padding: 0.35rem 0.65rem;
  border: 1px solid var(--line);
  background: var(--paper-2);
  color: var(--ink);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 650;
}

.toc a:hover {
  border-color: var(--orange);
  color: var(--orange-deep);
}

.tie-block {
  padding: 2.4rem 0;
  border-bottom: 1px solid var(--line);
}

.tie-block h2 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.8rem, 3vw, 2.5rem);
}

.steps {
  list-style: none;
  margin: 1.4rem 0 0;
  padding: 0;
  display: grid;
  gap: 0;
}

.steps li {
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr);
  gap: 0.9rem;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
}

.steps strong {
  display: block;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 650;
}

.num {
  font-family: var(--serif);
  font-size: 1.4rem;
  color: var(--orange);
  font-weight: 650;
}

.knot-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
  margin-top: 1.2rem;
}

.knot-card {
  padding: 1.1rem 1rem 1.2rem;
  background: var(--paper-2);
  border: 1px solid var(--line);
}

.knot-card h3 {
  margin: 0 0 0.35rem;
  font-family: var(--serif);
  font-size: 1.35rem;
}

.knot-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.98rem;
}

.knot-card .tag {
  display: inline-block;
  margin-bottom: 0.55rem;
  color: var(--orange-deep);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.cmp {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1rem;
  font-size: 0.95rem;
}

.cmp th,
.cmp td {
  text-align: left;
  padding: 0.75rem 0.6rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.cmp th {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 0.85rem 0;
}

.faq summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--ink);
}

.faq details p {
  margin: 0.55rem 0 0.2rem;
  color: var(--ink-soft);
}

@media (max-width: 860px) {
  .hero,
  .tie-layout,
  .tie-hero,
  .post-grid,
  .knot-grid,
  .stack-item {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 2.4rem;
  }

  .hero-note {
    border-top: 1px solid var(--line);
    border-left: 0;
    padding-top: 1.2rem;
  }

  .nav-btn {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.8rem;
    padding: 0 0 1rem;
  }

  .nav-toggle:checked ~ .site-nav {
    display: flex;
  }

  .cmp {
    display: block;
    overflow-x: auto;
  }
}
