@font-face { font-family: "Fell SC"; src: url(fonts/fell-sc.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Fell"; src: url(fonts/fell.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Fell"; src: url(fonts/fell-italic.woff2) format("woff2"); font-style: italic; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url(fonts/garamond-400.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url(fonts/garamond-400-italic.woff2) format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "EB Garamond"; src: url(fonts/garamond-500.woff2) format("woff2"); font-weight: 500; font-display: swap; }

/* Mislead LLC
   An old printed sheet: weathered parchment, sepia ink, double ruled frame.
   The only color besides ink is the hood red from the logo. */
:root {
  --parch: #dccaa4;
  --parch-light: #e9dcbd;
  --ink: #2e2219;
  --ink-soft: #5a4636;
  --red: #9e1118;

  --display: "Fell SC", "EB Garamond", Georgia, serif;
  --fell: "Fell", "EB Garamond", Georgia, serif;
  --book: "EB Garamond", Georgia, serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  color: var(--ink);
  font: 400 1.25rem/1.65 var(--book);
  background-color: var(--parch);
  /* darkened edges + a few old stains + paper grain + mottling */
  background-image:
    radial-gradient(circle at 12% 18%, rgba(120, 78, 30, .14), transparent 18%),
    radial-gradient(circle at 86% 64%, rgba(120, 78, 30, .12), transparent 22%),
    radial-gradient(circle at 30% 88%, rgba(120, 78, 30, .10), transparent 16%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='420'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .32 0 0 0 0 .22 0 0 0 0 .1 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    radial-gradient(ellipse at 70% 12%, rgba(255, 246, 222, .35), transparent 35%),
    radial-gradient(ellipse at 25% 55%, rgba(255, 246, 222, .25), transparent 30%);
}
/* darkened, burnt looking page edges that stay put while you scroll */
body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: -1;
  background: radial-gradient(ellipse at 50% 40%, transparent 45%, rgba(84, 52, 22, .38) 100%);
}

a { color: inherit; text-decoration-color: var(--red); text-decoration-thickness: 1px; text-underline-offset: 4px; }
a:hover { color: var(--red); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 4px; }

.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: var(--parch-light); padding: .5rem 1rem; }
.skip:focus { left: 1rem; top: 1rem; }

/* The double ruled frame around the whole sheet, like an old handbill */
.sheet {
  max-width: 64rem;
  margin: 1.5rem auto;
  padding: 0 clamp(1.25rem, 4vw, 3.5rem);
  border: 3px solid var(--ink);
  outline: 1px solid var(--ink);
  outline-offset: 5px;
  position: relative;
}
.top {
  display: flex; justify-content: space-between; align-items: baseline;
  flex-wrap: wrap; gap: .5rem 2rem;
  padding: 1.25rem 0 .9rem;
  border-bottom: 1px solid var(--ink);
}
.brand { font: 400 1.35rem/1 var(--display); text-decoration: none; letter-spacing: .04em; }
.top nav { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.top nav a { text-decoration: none; font-family: var(--fell); font-style: italic; color: var(--ink-soft); }
.top nav a:hover { color: var(--red); }

/* Hero: the logo inside a drifting globe of ink dots */
.hero { text-align: center; padding: 1rem 0 3.5rem; }
.stage {
  position: relative;
  width: min(40rem, 100%);
  aspect-ratio: 1 / 1;
  margin: 0 auto;
  touch-action: pan-y;
}
.dots, .crows { position: absolute; inset: 0; width: 100%; height: 100%; }
.crows { pointer-events: none; }
.logo {
  position: absolute; left: 50%; top: 50%;
  width: 62%; transform: translate(-50%, -50%);
  pointer-events: none;
}
.logo img { display: block; width: 100%; height: auto; filter: drop-shadow(0 .6rem .8rem rgba(46, 34, 25, .35)) sepia(.08); }

.wordmark {
  margin: -.5rem 0 0;
  font: 400 clamp(3.6rem, 12vw, 8rem)/1 var(--display);
  letter-spacing: .06em;
}
.wordmark .tm { font: .14em/1 var(--book); vertical-align: top; margin-left: .1em; letter-spacing: 0; }

.rule-line {
  display: flex; align-items: center; gap: 1rem;
  max-width: 26rem; margin: .6rem auto 0;
  color: var(--red); font-size: 1.6rem; line-height: 1;
}
.rule-line::before, .rule-line::after { content: ""; flex: 1; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); height: 4px; }

.lede { max-width: 32rem; margin: 1.25rem auto 0; font-size: clamp(1.3rem, 2.2vw, 1.5rem); line-height: 1.5; }
.aside { margin: .6rem 0 0; font-family: var(--fell); font-style: italic; color: var(--red); }

/* Headings sit between rules, like a poster banner */
h2 {
  display: flex; align-items: center; gap: 1.25rem;
  font: 400 clamp(2rem, 4vw, 2.75rem)/1.1 var(--display);
  letter-spacing: .05em;
  margin: 0 0 2rem;
}
h2::before, h2::after { content: ""; flex: 1; border-top: 1px solid var(--ink); }

.made, .pair { padding: 3rem 0; border-top: 3px double var(--ink); }

/* PagerPals as an engraved plate */
.product {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  gap: 2.75rem;
  align-items: center;
}
/* the pager sits in its own little patch of shadow, like something found in an attic */
.relic { position: relative; padding: 2.5rem 1.5rem 3rem; }
.relic::before {
  content: ""; position: absolute; inset: 4% 0 0;
  background: radial-gradient(ellipse 50% 46% at 50% 52%, rgba(40, 28, 18, .42), rgba(40, 28, 18, .16) 55%, rgba(40, 28, 18, 0) 72%);
  filter: blur(6px);
}
.pager { position: relative; transform: rotate(-4deg); filter: drop-shadow(0 22px 16px rgba(26, 17, 10, .5)); }
.pager img { width: 100%; height: auto; display: block; }
.lcd {
  position: absolute; left: 24.4%; top: 32.6%; width: 48.4%; height: 29.4%;
  animation: hum 5s infinite;
}
@keyframes hum { 0%, 100% { opacity: 1 } 48% { opacity: .93 } 50% { opacity: .78 } 52% { opacity: .95 } }
@media (prefers-reduced-motion: reduce) { .lcd { animation: none; } }
.product h3 { font: 400 2.4rem/1.05 var(--display); margin: 0; letter-spacing: .03em; }
.kind { font-family: var(--fell); font-style: italic; color: var(--ink-soft); margin: .4rem 0 1rem; }
.product-text p { max-width: 34rem; }
.links { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.5rem; margin-top: 1.5rem; }
.btn {
  display: inline-block;
  font: 400 1.15rem/1 var(--display); letter-spacing: .05em;
  text-decoration: none; color: var(--parch-light);
  background: var(--ink);
  padding: .8rem 1.4rem;
  outline: 1px solid var(--ink); outline-offset: 3px;
}
.btn:hover { background: var(--red); outline-color: var(--red); color: #fff; }

.next { max-width: 40rem; margin: 3rem auto 0; text-align: center; color: var(--ink-soft); }
.next em { font-family: var(--fell); color: var(--ink); }

.pair { display: grid; grid-template-columns: 1.2fr 1fr; gap: 3rem; }
.pair p { margin: 0 0 1rem; }
.pair h2 { font-size: clamp(1.8rem, 3vw, 2.3rem); }

.foot {
  text-align: center; font-size: 1rem; color: var(--ink-soft);
  padding: 1.25rem 0 1.5rem;
  border-top: 1px solid var(--ink);
}
.foot p { margin: .15rem 0; }

@media (max-width: 760px) {
  .sheet { margin: .75rem; }
  .product { grid-template-columns: 1fr; gap: 1.5rem; }
  .relic { max-width: 24rem; margin: 0 auto; padding: 1.5rem 1rem 2rem; }
  .pair { grid-template-columns: 1fr; gap: 1.5rem; }
  .logo { width: 70%; }
}

/* The page the crows lead to */
body.lost { min-height: 100vh; display: grid; place-items: center; }
body.lost::before { background: radial-gradient(ellipse at 50% 45%, rgba(84, 52, 22, .05) 20%, rgba(40, 22, 8, .78) 100%); }
.sky { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.lost-page { position: relative; text-align: center; padding: 2rem 1.5rem 4rem; }
.lone-crow { width: min(360px, 80vw); height: auto; display: block; margin: 0 auto; }
.lost-page h1 { font: 400 clamp(2.2rem, 6vw, 3.6rem)/1.1 var(--display); letter-spacing: .04em; margin: .5rem 0 0; }
.fortune { font-family: var(--fell); font-size: clamp(1.4rem, 3vw, 1.9rem); line-height: 1.4; max-width: 30rem; margin: 1.5rem auto 0; }
.fortune-or { font-family: var(--fell); font-style: italic; font-size: 1.05rem; color: var(--ink-soft); margin: .7rem 0 0; }
.fortune.fortune-bad { margin-top: .7rem; opacity: .72; }
.choose { font-family: var(--fell); font-style: italic; font-size: 1.1rem; max-width: 26rem; margin: 1.6rem auto 0; color: #8b1e1e; }
.lost-text { font-family: var(--fell); font-style: italic; font-size: 1.1rem; color: var(--ink-soft); margin: 2rem 0 0; }
.lost-way { margin: 3.5rem 0 0; font-size: .95rem; opacity: .55; }
.lost-way a { text-decoration: none; }
.lost-way a:hover { opacity: 1; color: var(--red); }
