/* Okitofa content pages: privacy, terms, 404, projects.
   Paper and ink, the editorial half of the brand. The hero has its own CSS. */
@font-face {
  font-family: 'Okitofa Garamond';
  src: url('/fonts/garamond-roman.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Okitofa Garamond';
  src: url('/fonts/garamond-italic.woff2') format('woff2');
  font-weight: 400; font-style: italic; font-display: swap;
}

:root {
  --paper: #F0E3CC;
  --ink: #302619;
  --ink-soft: #5f4f45;
  --flame: #D85E3A;
  --link: #a8452f;
  --rule: rgb(48 38 25 / 0.16);
  --serif: 'Okitofa Garamond', Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--paper); }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  font: 400 1.2rem/1.55 var(--serif);
  -webkit-font-smoothing: antialiased;
  /* subtle paper tooth */
  background:
    radial-gradient(120% 80% at 50% 0%, rgb(255 250 240 / 0.6), transparent 70%),
    var(--paper);
}

a { color: var(--link); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }

.wrap { width: min(100% - 2.5rem, 40rem); margin-inline: auto; }

.skip-link {
  position: absolute; left: 1rem; top: 1rem; z-index: 10;
  padding: 0.4rem 0.8rem; background: var(--ink); color: var(--paper);
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* header */
.site-header { padding: 2rem 0 0; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.wordmark { display: block; line-height: 0; }
.wordmark img { width: 132px; height: auto; }
.site-nav ul { display: flex; gap: 1.6rem; margin: 0; padding: 0; list-style: none; font-size: 1.1rem; }
.site-nav a { color: var(--ink); text-decoration: none; }
.site-nav a:hover, .site-nav a[aria-current] { text-decoration: underline; }

/* back to the poster */
.back {
  display: inline-block;
  margin: 0 0 1.6rem;
  padding: 0.3rem 0;
  color: var(--ink-soft);
  font-size: 1.05rem;
  text-decoration: none;
}
.back:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }

/* body */
.page { flex: 1; padding: 3.5rem 0 4rem; }
.page h1 {
  margin: 0 0 1.2rem;
  font-weight: 400;
  font-size: clamp(2.4rem, 7vw, 3.4rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
}
.page h2 { margin: 2.4rem 0 0.5rem; font-weight: 400; font-style: italic; font-size: 1.55rem; }
.page p, .page li { max-width: 36rem; }
.page ul { padding-left: 1.2rem; }
.lead { font-size: 1.4rem; font-style: italic; color: var(--ink-soft); }
.updated { margin-top: 3rem; font-size: 1rem; color: var(--ink-soft); }
.empty { color: var(--ink-soft); font-style: italic; }

/* about: a collage of paper. Puzzle pieces for what we make,
   torn notes for how we think. */
.about-page .wrap { width: min(100% - 2.5rem, 52rem); }
.about .kicker { margin: 0 0 0.6rem; font-style: italic; color: var(--link); font-size: 1.1rem; }
.about h1 em { display: block; font-style: italic; color: var(--flame); }
.about .lead { font-style: normal; color: var(--ink); font-size: 1.35rem; line-height: 1.5; max-width: 38rem; }
.about h2 { margin-top: 0; }
.about .sig { font-style: italic; color: var(--link); font-size: 1.3rem; margin: 0.4rem 0 0; }
.company { font-style: normal; line-height: 1.6; }

.puzzle { margin-top: 3rem; }
.engine {
  max-width: 38rem;
  margin: 2.4rem 0 0;
  padding-left: 1.1rem;
  border-left: 2px solid var(--flame);
  font-style: italic;
  font-size: 1.2rem;
  line-height: 1.5;
  color: var(--ink);
}
.pieces {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}
.piece {
  --c: #F6C6CF;
  position: relative;
  padding: 1.4rem 1.7rem 1.6rem 1.4rem;
  background: linear-gradient(160deg, rgb(255 255 255 / 0.5), rgb(255 255 255 / 0) 50%), url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .19 0 0 0 0 .15 0 0 0 0 .10 0 0 0 .12 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"), var(--c);
  border-radius: 10px;
  filter: drop-shadow(0 1px 0 rgb(48 38 25 / 0.14)) drop-shadow(0 10px 16px rgb(60 35 30 / 0.16));
  transition: transform 450ms cubic-bezier(0.16, 1, 0.3, 1);
}
.piece:nth-child(1) { --c: #F6C6CF; z-index: 3; rotate: -0.8deg; }
.piece:nth-child(2) { --c: #CFE1EE; z-index: 2; rotate: 0.6deg; translate: 0 0.5rem; }
.piece:nth-child(3) { --c: #FFD2B4; z-index: 1; rotate: -0.4deg; }
/* the jigsaw knob that locks into the next piece */
.piece:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -1rem;
  top: 50%;
  width: 2rem;
  height: 2rem;
  translate: 0 -50%;
  border-radius: 50%;
  background: var(--c);
}
.piece:hover { transform: translateY(-4px) rotate(0.6deg); }
.piece h3 { margin: 0 0 0.5rem; font-weight: 400; font-size: 1.35rem; line-height: 1.15; }
.piece p { margin: 0; font-size: 1.05rem; line-height: 1.5; color: #4a3d33; }

.note {
  --c: #FFF8EC;
  --r: -0.6deg;
  position: relative;
  isolation: isolate;
  max-width: 38rem;
  margin: 3rem 0 0;
  padding: 1.7rem 2rem 1.9rem;
  rotate: var(--r);
  filter: drop-shadow(0 1px 0 rgb(48 38 25 / 0.14)) drop-shadow(0 12px 18px rgb(60 35 30 / 0.15));
}
.note::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(160deg, rgb(255 255 255 / 0.55), rgb(255 255 255 / 0) 45%), url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .19 0 0 0 0 .15 0 0 0 0 .10 0 0 0 .12 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"), var(--c);
  clip-path: polygon(0 2%, 3% 0, 22% 1.2%, 48% 0, 74% 1.5%, 97% 0, 100% 4%, 99.2% 34%, 100% 63%, 99.4% 97%, 78% 100%, 52% 98.6%, 26% 100%, 1.5% 98.8%, 0.6% 66%, 0 35%);
}
.note p { max-width: none; }
.note p:last-child { margin-bottom: 0; }
.note--work { --c: #FFF8EC; --r: -0.5deg; }
.note--going { --c: #F8D6DB; --r: 0.9deg; max-width: 30rem; margin-left: auto; }
.note--company { --c: #D9E8F2; --r: -0.7deg; max-width: 20rem; }

@media (max-width: 760px) {
  .pieces { grid-template-columns: 1fr; }
  .piece { padding: 1.3rem 1.4rem 1.7rem; }
  .piece:nth-child(2) { translate: 0.4rem 0; }
  .piece:not(:last-child)::after { right: auto; top: auto; left: 50%; bottom: -1rem; translate: -50% 0; }
  .note, .note--going, .note--company { max-width: none; margin-left: 0; padding: 1.5rem 1.4rem 1.7rem; }
}

/* projects */
.project-head { display: flex; align-items: center; gap: 1.2rem; margin-bottom: 1rem; }
.project-head h1 { margin: 0; }
.project-icon { border-radius: 22%; box-shadow: 0 6px 20px rgb(48 38 25 / 0.15); }
.project-meta { margin: 0.2rem 0 0; color: var(--ink-soft); font-size: 1rem; }
.projects { list-style: none; padding: 0; }
.project { display: flex; gap: 1rem; padding: 1.2rem 0; border-top: 1px solid var(--rule); }
.store-links { display: flex; flex-wrap: wrap; gap: 0.8rem; list-style: none; padding: 0; margin: 1.6rem 0; }
.button {
  display: inline-block; padding: 0.5rem 1.1rem;
  background: var(--ink); color: var(--paper); text-decoration: none; border-radius: 999px;
}
.button:hover { background: var(--flame); color: var(--paper); }
.shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: 0.8rem; list-style: none; padding: 0; }
.shots img { width: 100%; height: auto; border-radius: 0.8rem; }

/* 404 */
.lost { text-align: center; padding-top: 5rem; }
.lost .digits {
  display: flex; align-items: center; justify-content: center; gap: 0.08em;
  margin: 0 0 1.4rem; font-size: clamp(5rem, 22vw, 9rem); line-height: 1;
}
.lost .digits img { width: 0.86em; height: 0.86em; transform: translateY(0.04em) rotate(-8deg); }
.lost h1 { font-size: clamp(2rem, 6vw, 2.8rem); margin-bottom: 0.4rem; }
.lost .sig { margin: 0 0 2rem; font-style: italic; color: var(--ink-soft); }

/* footer */
.site-footer { padding: 2rem 0 2.4rem; border-top: 1px solid var(--rule); font-size: 1rem; color: var(--ink-soft); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.8rem; }
.site-footer p { margin: 0; }
.site-footer ul { display: flex; gap: 1.2rem; margin: 0; padding: 0; list-style: none; }
.site-footer a { color: inherit; }
