.projects-main { margin: 0 var(--gutter) 100px; }
.projects-heading { display: flex; align-items: flex-end; justify-content: space-between; padding: 65px 0 57px; }
.projects-heading h1 { margin: 0 0 0 -7px; font-size: clamp(80px, 11.4vw, 184px); line-height: .9; letter-spacing: -.085em; pointer-events: auto; text-align: left; }
.projects-heading .heading-dot { display: inline; }
.projects-heading sup { display: inline-block; margin-left: 16px; font-family: "SFMono-Regular", Consolas, monospace; font-size: clamp(14px, 1.5vw, 22px); font-weight: 400; letter-spacing: -.05em; vertical-align: top; padding-top: 12px; }
.studio-name { padding: 0 0 5px 28px; font-size: 16px; line-height: 1.15; letter-spacing: -.035em; }
.project-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 60px 30px; align-items: start; }
.project { min-width: 0; scroll-margin-top: 24px; }
.project-witches, .project-reader { grid-column: span 7; }
.project-octagon, .project-cats { grid-column: span 5; }
.project summary { display: block; list-style: none; cursor: pointer; -webkit-tap-highlight-color: transparent; touch-action: manipulation; outline-offset: 8px; }
.project summary::-webkit-details-marker { display: none; }
.project summary:focus-visible { outline: 2px solid var(--ink); }
.project-visual { position: relative; isolation: isolate; overflow: hidden; height: clamp(320px, 33vw, 530px); }
.visual-label, .art-caption, .project-kind, .project-platform { font-family: "SFMono-Regular", Consolas, monospace; font-size: 11px; font-weight: 400; line-height: 1.5; letter-spacing: .035em; }
.visual-label { position: absolute; z-index: 3; top: 23px; left: 24px; }
.art-caption { position: absolute; z-index: 3; right: 24px; bottom: 20px; }
.project-caption { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 23px 0 0; }
.project-kind { color: var(--muted); font-size: 12px; letter-spacing: 0; }
.project-caption h2 { margin: 5px 0 0; font-size: clamp(25px, 2.5vw, 42px); line-height: 1.13; letter-spacing: -.055em; font-weight: 500; }
.project-toggle { display: block; position: relative; width: 44px; height: 44px; flex-shrink: 0; border: 1px solid #b7b9ae; border-radius: 50%; transition: background 200ms, color 200ms; }
.project-toggle::before, .project-toggle::after { position: absolute; content: ""; top: 50%; left: 50%; width: 14px; height: 1px; background: currentColor; transform: translate(-50%, -50%); }
.project-toggle::after { transform: translate(-50%, -50%) rotate(90deg); transition: transform 200ms; }
.project[open] .project-toggle { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.project[open] .project-toggle::after { transform: translate(-50%, -50%); }
.project-description { margin-top: 20px; padding-top: 19px; border-top: 1px solid var(--line); max-width: 560px; }
.project-description p { max-width: 46ch; margin: 0 0 15px; font-size: 16px; line-height: 1.6; }
.project-platform { color: var(--muted); }

.witches-visual { background: #507340; }
.witches-scene { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 55%; transition: transform 500ms cubic-bezier(.2, .65, .3, 1); }
.witches-visual .visual-label { color: #fff; background: #203220; padding: 6px 10px; top: 17px; left: 18px; }
.witches-visual .art-caption { color: #fff; background: #203220; padding: 3px 8px; bottom: 17px; right: 18px; }
.octagon-visual { background: #293331; color: #e5dfc6; display: grid; place-items: center; }
.octagon-outline { position: absolute; width: 120%; height: 120%; right: -38%; top: -10%; stroke: #6a7871; stroke-width: .15; transform: rotate(22.5deg); opacity: .65; }
.octagon-poster { position: absolute; top: 50%; left: 50%; width: auto; height: 80%; max-width: 72%; object-fit: contain; transform: translate(-50%, -50%) rotate(-8deg); box-shadow: 14px 16px 28px #0d161c55; transition: transform 400ms cubic-bezier(.2, .65, .3, 1); }
.octagon-visual .visual-label { color: #eee8d4; }
.octagon-visual .art-caption { color: #eee8d4; }
.cats-visual { background: #d2ddc8; color: #354430; }
.cat-orbit { position: absolute; width: 86%; height: 80%; left: 7%; top: 10%; border: 1px solid #aebfa5; border-radius: 50%; }
.cat-cast { position: absolute; inset: 0; }
.cat { position: absolute; object-fit: contain; width: 63%; height: auto; bottom: 19%; transition: transform 400ms cubic-bezier(.2, .65, .3, 1); }
.cat-black { left: -5%; bottom: 24%; width: 58%; }
.cat-gray { right: -3%; bottom: 24%; width: 59%; }
.cat-pixel { left: 20%; bottom: 12%; z-index: 1; }
.cats-visual .art-caption { right: 0; left: 0; text-align: center; }
.reader-visual { background: #d4b9a6; color: #46372f; }
.reader-spread { position: absolute; width: 77%; height: 70%; left: 11%; top: 16%; perspective: 1000px; }
.reader-cover, .reader-page { position: absolute; width: 52%; height: 100%; padding: clamp(17px, 2.1vw, 36px); }
.reader-page { right: 0; top: -3%; color: #eadbc0; background: #2b3331; transform: rotate(10deg); box-shadow: 7px 9px 0 #eee4ce, 11px 12px 0 #d2c7b1, 18px 20px 24px #654b3b26; }
.page-chapter { display: block; font-family: Georgia, serif; font-size: clamp(10px, 1.1vw, 16px); text-align: center; }
.page-letter { display: block; font-family: Georgia, serif; font-size: clamp(45px, 7vw, 104px); text-align: center; line-height: 1.35; }
.page-lines { height: 21%; background: repeating-linear-gradient(to bottom, #89938b 0, #89938b 1px, transparent 1px, transparent 10px); opacity: .65; }
.page-number { position: absolute; bottom: 16px; left: 0; right: 0; text-align: center; font-family: Georgia, serif; font-size: 12px; }
.reader-cover { top: 3%; left: 0; z-index: 1; background: #eee8da; color: #252923; transform: rotate(-12deg); box-shadow: inset 7px 0 0 #ded6c7, 10px 9px 0 #cfc3af, 17px 21px 26px #654b3b30; transition: transform 400ms cubic-bezier(.2, .65, .3, 1); display: flex; flex-direction: column; justify-content: center; }
.reader-cover img { width: 34%; height: auto; position: absolute; top: 4%; right: 6%; }
.book-title { font-size: clamp(32px, 4.9vw, 75px); line-height: .96; letter-spacing: -.075em; font-weight: 500; }
.book-title > span { color: #d85d37; }
.book-formats { position: absolute; bottom: 7%; font-family: "SFMono-Regular", Consolas, monospace; font-size: clamp(8px, .8vw, 12px); letter-spacing: .04em; }
.projects-footer { gap: 24px; }
.footer-home { display: grid; place-items: center; min-width: 44px; min-height: 44px; margin-left: -12px; }
.back-top { margin-left: auto; display: flex; gap: 20px; align-items: center; min-height: 44px; font-size: 13px; }
.back-top > span { font-size: 22px; }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .project summary:hover .project-toggle { background: var(--ink); color: var(--paper); border-color: var(--ink); }
  .project summary:hover .witches-scene { transform: scale(1.035); }
  .project summary:hover .octagon-poster { transform: translate(-50%, -50%) rotate(-3deg); }
  .project summary:hover .cat-pixel { transform: translateY(-5px); }
  .project summary:hover .reader-cover { transform: rotate(-8deg) translateX(-3%); }
}
@media (max-width: 1050px) {
  .project-grid { gap: 45px 24px; }
  .projects-heading { padding-block: 54px 45px; }
  .project-visual { height: 34vw; min-height: 300px; }
  .visual-label { top: 18px; left: 18px; }
  .art-caption { right: 18px; bottom: 17px; font-size: 10px; }
  .cat { bottom: 22%; }
  .cat-black, .cat-gray { bottom: 30%; }
  .reader-spread { height: 66%; top: 19%; }
}
@media (max-width: 700px) {
  .projects-main { margin-bottom: 58px; }
  .projects-heading { padding-block: 39px 36px; }
  .projects-heading h1 { margin-left: -3px; font-size: clamp(65px, 17vw, 116px); }
  .projects-heading sup { margin-left: 9px; padding-top: 6px; font-size: 12px; }
  .studio-name { display: none; }
  .project-grid { grid-template-columns: minmax(0, 1fr); gap: 37px; }
  .project { grid-column: 1; }
  .project-visual { height: auto; min-height: 0; aspect-ratio: 1.15; }
  .witches-visual { aspect-ratio: 1.18; }
  .project-caption { padding-top: 18px; }
  .project-caption h2 { font-size: clamp(26px, 6.6vw, 38px); margin-top: 3px; }
  .project-kind { font-size: 11px; }
  .project-toggle { width: 40px; height: 40px; }
  .visual-label { font-size: 10px; }
  .art-caption { font-size: 10px; }
  .cat { bottom: 17%; }
  .cat-black, .cat-gray { bottom: 26%; }
  .reader-spread { width: 79%; height: 70%; left: 10%; top: 16%; }
  .reader-cover, .reader-page { padding: 7%; }
  .book-title { font-size: clamp(31px, 9vw, 59px); }
  .page-letter { font-size: clamp(48px, 15vw, 95px); }
  .page-chapter { font-size: clamp(10px, 2.8vw, 17px); }
  .book-formats { font-size: clamp(8px, 1.9vw, 12px); }
  .reader-cover img { width: 39%; top: 3%; right: 3%; }
  .project-description p { font-size: 15px; }
  .projects-footer { gap: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .project *, .project *::before, .project *::after { transition: none !important; }
}
