:root {
  --linen: #efe7d6; --linen2: #e6dcc6; --navy: #1d3a8a; --rust: #b4532a; --gold: #d9a441; --green: #3c7a52; --ink: #2a2620;
  --focus: var(--rust);
  --lb-bg: var(--linen); --lb-fg: var(--ink); --lb-font: 'Atkinson Hyperlegible', sans-serif; --lb-border: 3px dashed var(--navy);
  --lb-backdrop: rgba(29,58,138,.7); --lb-radius: 4px;
}
html { background: var(--linen); color-scheme: light; }
body {
  color: var(--ink); font: 400 1.1rem/1.6 'Atkinson Hyperlegible', sans-serif;
  background-color: var(--linen);
  background-image:
    repeating-linear-gradient(0deg, rgba(120,100,70,.07) 0 1px, transparent 1px 4px),
    repeating-linear-gradient(90deg, rgba(120,100,70,.07) 0 1px, transparent 1px 4px);
}
a { color: var(--navy); text-decoration-style: dashed; text-underline-offset: 4px; }
code { font-family: ui-monospace, Menlo, monospace; font-size: .86em; color: var(--rust); }
h2 { font: 900 clamp(2rem, 4.5vw, 3.2rem)/1.05 'Fraunces', serif; color: var(--navy); margin-bottom: 1.6rem; }
h2::after { content: ''; display: block; width: 7rem; margin-top: .6rem; border-top: 3px dashed var(--rust); }

.entry-nav { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 1.4rem; background: var(--navy); color: var(--linen); border-bottom: 3px dashed var(--gold); outline: 3px solid var(--navy); font-size: .95rem; }
.entry-nav a { color: var(--linen); text-decoration: none; padding: .2rem 0; }
.entry-nav a:hover, .entry-nav a:focus-visible { color: var(--gold); }
.n-count { font-family: 'Fraunces', serif; font-style: italic; color: var(--gold); margin-left: .3em; }

main { max-width: 1180px; margin: 0 auto; padding: 0 1.4rem; }
section { padding: 4rem 0; }

.hero { display: grid; grid-template-columns: 1.1fr .9fr; gap: 2.5rem; align-items: center; padding-top: 3.5rem; }
.eyebrow { font-size: .85rem; letter-spacing: .18em; text-transform: uppercase; color: var(--rust); }
.stitched { width: 100%; max-width: 620px; overflow: visible; }
.stitched text { font: 900 128px 'Fraunces', serif; letter-spacing: -2px; }
.satin { fill: var(--navy); }
.run { fill: none; stroke: var(--gold); stroke-width: 2.4; stroke-dasharray: 9 6; stroke-linecap: round; }
.js .run { stroke-dashoffset: 1600; animation: sew 4s ease-out forwards; stroke-dasharray: 9 6; }
@keyframes sew { from { stroke-dashoffset: 1600; opacity: .2; } to { stroke-dashoffset: 0; opacity: 1; } }
.lede { font: 400 italic clamp(1.4rem, 2.6vw, 2rem)/1.25 'Fraunces', serif; margin-top: .4rem; }
.sub { margin-top: .8rem; max-width: 44ch; }
.spools { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: 1.6rem; }
.spools span { position: relative; padding: .35rem .9rem .35rem 2.2rem; background: #fffaf0; border: 2px dashed var(--c); border-radius: 999px; font-weight: 700; }
.spools span::before { content: ''; position: absolute; left: .55rem; top: 50%; width: 1.1rem; height: 1.1rem; margin-top: -.55rem; border-radius: 50%; background: repeating-radial-gradient(circle, var(--c) 0 2px, #fffaf0 2px 3px); }

.hoop { position: relative; justify-self: center; width: min(440px, 90vw); }
.hoop-in { aspect-ratio: 1; border-radius: 50%; overflow: hidden; border: 18px solid #c79a62; box-shadow: inset 0 0 0 6px #a87a45, 0 0 0 4px #8b6235, 0 18px 30px rgba(42,38,32,.25); background: #faf7f0; }
.hoop-in img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.02); }
.screw { position: absolute; top: -18px; left: 50%; width: 56px; height: 30px; margin-left: -28px; background: linear-gradient(#d8d2c4, #8f8878); border: 2px solid #6c665a; border-radius: 6px; }
.hoop-cap { text-align: center; font: italic .95rem 'Fraunces', serif; margin-top: 1rem; }

.swatch { position: relative; background: #fbf6ea; padding: 3rem; margin: 3rem 0; border-radius: 6px; box-shadow: 0 2px 0 var(--linen2), 0 12px 24px rgba(42,38,32,.08); }
.swatch::before { content: ''; position: absolute; inset: 12px; border: 2px dashed rgba(29,58,138,.4); border-radius: 4px; pointer-events: none; }
.two { display: grid; grid-template-columns: 1fr 1.4fr; gap: 2.5rem; font-size: 1.15rem; }

.patches { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.6rem; }
.patches li { position: relative; padding: 1.6rem 1.5rem; border-radius: 22px; color: #fffaf0; box-shadow: 0 0 0 5px var(--linen), 0 0 0 8px var(--bd), 0 10px 18px rgba(42,38,32,.18); }
.patches li::after { content: ''; position: absolute; inset: 8px; border: 2px dashed rgba(255,250,240,.6); border-radius: 15px; pointer-events: none; }
.patches li p { position: relative; }
.patches code { color: inherit; background: rgba(0,0,0,.18); padding: 0 .3em; border-radius: 4px; }
.p0 { background: var(--navy); --bd: var(--navy); } .p1 { background: var(--rust); --bd: var(--rust); }
.p2 { background: var(--green); --bd: var(--green); } .p3 { background: #8a6a1d; --bd: #8a6a1d; }
.patches li:nth-child(odd) { transform: rotate(-1deg); } .patches li:nth-child(even) { transform: rotate(1deg); }

.steps { counter-reset: s; display: grid; gap: 1.1rem; max-width: 56rem; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 3.6rem 1fr; gap: 1rem; align-items: start; }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 3rem; height: 3rem; font: 900 1.4rem 'Fraunces', serif; color: var(--rust); border: 2px dashed var(--rust); border-radius: 50%; background: var(--linen); }
.steps p { padding-top: .5rem; border-bottom: 1px dashed rgba(42,38,32,.25); padding-bottom: 1rem; }

.needles { display: grid; gap: 1rem; }
.needles div { display: grid; grid-template-columns: 15rem 1fr; gap: 1.5rem; padding: 1rem 0; border-top: 2px dashed rgba(29,58,138,.35); }
.needles dt code { font-size: 1rem; color: var(--navy); font-weight: 700; }
.needles dd { margin: 0; }
.aside { margin-top: 1.4rem; font-style: italic; }

.post .x-embed { position: relative; }
.x-fallback { text-align: center; margin-top: 1rem; }

.pins { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.pins figure { position: relative; background: #fffaf0; padding: .8rem; box-shadow: 0 10px 20px rgba(42,38,32,.15); clip-path: polygon(0 2%, 4% 0, 9% 2%, 14% 0, 20% 2%, 26% 0, 32% 2%, 38% 0, 44% 2%, 50% 0, 56% 2%, 62% 0, 68% 2%, 74% 0, 80% 2%, 86% 0, 92% 2%, 96% 0, 100% 2%, 100% 98%, 96% 100%, 90% 98%, 84% 100%, 78% 98%, 72% 100%, 66% 98%, 60% 100%, 54% 98%, 48% 100%, 42% 98%, 36% 100%, 30% 98%, 24% 100%, 18% 98%, 12% 100%, 6% 98%, 0 100%); }
.pins figure::before { content: ''; position: absolute; top: 14px; left: 50%; width: 16px; height: 16px; margin-left: -8px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #f07a52, var(--rust)); box-shadow: 0 2px 3px rgba(0,0,0,.3); z-index: 2; }
.pins img { aspect-ratio: 16 / 10; object-fit: cover; background: #fff; }
.pins figcaption { padding: .7rem .2rem .3rem; font-size: .95rem; }

.label-sec { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2.5rem; align-items: start; }
.care { background: #fff; padding: 2.2rem; border: 2px solid #ddd3bf; position: relative; box-shadow: 0 8px 18px rgba(42,38,32,.1); }
.care::before { content: ''; position: absolute; inset: 10px; border: 2px dashed var(--navy); pointer-events: none; }
.install pre { background: var(--linen); border-left: 4px solid var(--navy); padding: 1rem 1.2rem; font-size: .9rem; color: var(--navy); margin-bottom: 1rem; }
.install p { margin-bottom: .8rem; }
.copy { background: var(--navy); color: var(--linen); border: 0; border-radius: 3px; padding: .3rem .7rem; font-weight: 700; cursor: pointer; }
.stat-line { display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; margin-top: 1.6rem; padding-top: 1rem; border-top: 2px dashed var(--rust); font-size: .95rem; }
.stat-line strong { font: 900 1.4rem 'Fraunces', serif; color: var(--rust); }
.tn { font-size: .88rem; margin-top: .8rem; opacity: .8; }
.ribbons h3 { font: 700 1.6rem 'Fraunces', serif; margin-bottom: 1rem; }
.links { display: grid; gap: .8rem; }
.links a { display: block; position: relative; padding: .8rem 1.2rem .8rem 1.4rem; background: var(--navy); color: var(--linen); text-decoration: none; clip-path: polygon(0 0, 100% 0, 94% 50%, 100% 100%, 0 100%); }
.links li:nth-child(2n) a { background: var(--rust); }
.links a:hover, .links a:focus-visible { background: var(--ink); }
.l-label { display: block; font-weight: 700; } .l-sub { font-size: .88rem; opacity: .85; }

.credit { max-width: 1180px; margin: 0 auto; padding: 2rem 1.4rem 4rem; font-size: .95rem; border-top: 3px dashed rgba(29,58,138,.3); }

@media (max-width: 860px) {
  .hero, .two, .label-sec { grid-template-columns: 1fr; }
  .swatch { padding: 2rem 1.4rem; }
  .needles div { grid-template-columns: 1fr; gap: .3rem; }
}
