:root {
  --paper: #f4efe6;
  --stone: #e4dccf;
  --ink: #241c16;
  --muted: #5c5148;
  --red: #8d3b2e;
  --oak: #6a4b32;
  --line: rgba(36, 28, 22, 0.16);
  --col: 44rem;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Palatino, "Palatino Linotype", "Iowan Old Style", Georgia, serif;
  font-size: 1.125rem;
  line-height: 1.55;
}
img { max-width: 100%; display: block; }
a { color: var(--red); }
a:hover { color: var(--ink); }
button, input { font: inherit; }

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--ink);
  color: var(--paper);
  padding: 0.4rem 0.7rem;
  z-index: 80;
}
.skip:focus { top: 0.6rem; }

.top {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.85rem 1.4rem;
  background: rgba(244, 239, 230, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.brand {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.nav { display: flex; flex-wrap: wrap; gap: 0.9rem 1.1rem; }
.nav a {
  color: var(--ink);
  text-decoration: none;
  font-family: "Segoe UI", sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.nav a:hover { color: var(--red); }

main { position: relative; z-index: 1; }
.wrap { max-width: var(--col); margin: 0 auto; padding: 0 1.25rem; }

.hero { padding-top: 3.2rem; padding-bottom: 1rem; }
.kicker {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red);
  margin: 0 0 0.6rem;
}
h1 { font-size: clamp(2.6rem, 7vw, 4.6rem); line-height: 0.95; font-weight: 500; margin: 0 0 1rem; }
.lead { font-size: 1.35rem; margin: 0 0 1rem; }
.quiet { color: var(--muted); }
.hero-img { margin: 1.6rem 0 0; }
.hero-img img { width: 100%; aspect-ratio: 3/2; object-fit: cover; }
.hero-img figcaption, figcaption { color: var(--muted); font-size: 0.95rem; margin-top: 0.4rem; }

.band { padding: 2.4rem 0; border-top: 1px solid var(--line); }
h2 { font-size: 2rem; font-weight: 500; margin: 0 0 0.8rem; }
.points { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; margin-top: 1.4rem; }
.points h3 { margin: 0 0 0.35rem; font-size: 1.2rem; font-weight: 600; }
.points p { margin: 0; color: var(--muted); }
.steps { margin: 0.6rem 0 0; padding-left: 1.2rem; }
.steps li { margin: 0.25rem 0; }

.wide { max-width: 72rem; }
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem 1rem;
  margin-top: 1.2rem;
}
.card {
  margin: 0;
  background: transparent;
  border: 0;
  padding: 0;
  text-align: left;
  color: inherit;
  cursor: pointer;
}
.card img { width: 100%; aspect-ratio: 3/2; object-fit: cover; background: var(--stone); }
.card:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
.tag {
  font-family: "Segoe UI", sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--red);
}
.card strong { display: block; font-weight: 600; color: var(--ink); }
.card p { color: var(--muted); font-size: 0.95rem; margin: 0.4rem 0 0; }

.foot {
  border-top: 1px solid var(--line);
  padding: 1.6rem 1.4rem 2.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.4rem;
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.98rem;
}
.foot nav { display: flex; gap: 1rem; }
.legal { max-width: 40rem; margin: 0 auto; padding: 3rem 1.25rem 4rem; }
.legal h1 { font-size: 2.4rem; }

#studio { position: fixed; inset: 0; z-index: 30; pointer-events: none; }
.frame {
  position: fixed;
  z-index: 31;
  pointer-events: auto;
  padding: 9px;
  background: linear-gradient(160deg, #8a5a34, #3e2616 70%);
  box-shadow: 0 14px 28px rgba(36, 28, 22, 0.28);
  border: 0;
  cursor: pointer;
  transform-origin: center bottom;
}
.frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #efe4d0;
  opacity: 0;
  transition: opacity 0.7s ease;
}
.frame.hung img { opacity: 1; }
.frame.born { animation: born 0.7s ease; }
@keyframes born {
  from { transform: scale(0.2) rotate(-2deg); opacity: 0; }
  to { transform: none; opacity: 1; }
}

.artist {
  position: fixed;
  z-index: 33;
  width: 78px;
  height: 118px;
  left: 0;
  top: 0;
  pointer-events: none;
  will-change: transform;
}
.artist .body { width: 78px; height: 118px; transform-origin: 50% 70%; }
.artist.face-left .body { transform: scaleX(-1); }
.artist .leg { transform-origin: 38px 78px; }
.artist.walk .leg-a { animation: step 0.42s ease-in-out infinite alternate; }
.artist.walk .leg-b { animation: step 0.42s ease-in-out infinite alternate-reverse; }
@keyframes step {
  from { transform: rotate(16deg); }
  to { transform: rotate(-16deg); }
}
.hold {
  position: absolute;
  left: 2px;
  top: 46px;
  width: 42px;
  height: 56px;
  object-fit: cover;
  border: 3px solid #4a2e1c;
  background: #efe4d0;
  box-shadow: 2px 4px 0 rgba(36, 28, 22, 0.25);
  transform: rotate(-14deg);
  opacity: 0;
}
.artist.carry .hold { opacity: 1; }
.artist.face-left .hold { left: auto; right: 2px; transform: rotate(14deg); }

#easel {
  position: fixed;
  z-index: 32;
  left: 14px;
  top: 28vh;
  width: 132px;
  pointer-events: none;
  opacity: 0;
  transform: translateX(-16px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
#easel.on { opacity: 1; transform: none; }
#easel .board {
  position: relative;
  height: 168px;
  background: #efe4d0;
  border: 8px solid #6a4328;
  box-shadow: 0 10px 18px rgba(36, 28, 22, 0.2);
  overflow: hidden;
}
#easel .board img { width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 0.6s ease; }
#easel.show-work .board img { opacity: 1; }
#easel .stroke {
  position: absolute;
  left: 14px;
  height: 2px;
  background: #2c211b;
  width: 78px;
  transform: scaleX(0);
  transform-origin: left center;
}
#easel .stroke:nth-child(1) { top: 36%; }
#easel .stroke:nth-child(2) { top: 52%; width: 96px; }
#easel .stroke:nth-child(3) { top: 68%; width: 52px; }
#easel.drawing .stroke { animation: stroke 0.55s ease forwards; }
#easel.drawing .stroke:nth-child(2) { animation-delay: 0.35s; }
#easel.drawing .stroke:nth-child(3) { animation-delay: 0.7s; }
@keyframes stroke { to { transform: scaleX(1); } }
#easel .legs {
  height: 18px;
  border-left: 3px solid #6a4328;
  border-right: 3px solid #6a4328;
  width: 70%;
  margin: 0 auto;
}

dialog {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: min(920px, 92vw);
}
dialog::backdrop { background: rgba(36, 28, 22, 0.72); }
dialog img { width: 100%; max-height: 78vh; object-fit: contain; background: #1a1512; }
dialog .sheet { background: var(--paper); padding: 0.8rem 1rem 1rem; }
dialog .row { display: flex; justify-content: space-between; gap: 1rem; align-items: start; }
dialog p { margin: 0.3rem 0 0; color: var(--muted); }
dialog button {
  background: transparent;
  border: 1px solid var(--line);
  padding: 0.25rem 0.6rem;
  cursor: pointer;
}

@media (max-width: 800px) {
  .points { grid-template-columns: 1fr; }
  .hero { padding-top: 2rem; }
  h1 { font-size: 2.7rem; }
  .lead { font-size: 1.15rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .artist, #easel { display: none; }
  .frame { animation: none; }
}
