/* ---------------------------------------------------
   the basement — design tokens
--------------------------------------------------- */
:root{
  --ink:        #121210;
  --ink-soft:   #171613;
  --wall:       #1c1a16;
  --wall-line:  rgba(237,231,216,.14);
  --paper:      #ede7d8;
  --paper-dim:  rgba(237,231,216,.62);
  --hazard:     #e7b723;
  --blood:      #c13324;
  --bulb:       #ffdf9c;

  --display: "Anton", "Arial Narrow", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --body: "Work Sans", system-ui, sans-serif;

  --wrap: min(1180px, 100% - 3rem);
  --radius: 2px;
}

*, *::before, *::after{ box-sizing: border-box; }
html{ color-scheme: dark; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
}

body{
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img{ max-width: 100%; display: block; }
a{ color: inherit; }

.skip-link{
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--hazard);
  color: var(--ink);
  padding: .75rem 1rem;
  z-index: 999;
  font-family: var(--mono);
}
.skip-link:focus{ left: 1rem; top: 1rem; }

:focus-visible{
  outline: 2px solid var(--hazard);
  outline-offset: 3px;
}

/* ---------------------------------------------------
   film grain + darkness scrim (signature: the flashlight)
--------------------------------------------------- */
.grain{
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 40;
  opacity: .05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.scrim{
  position: fixed;
  inset: 0;
  z-index: 30;
  pointer-events: none;
  background: radial-gradient(
    circle 260px at var(--mx, 50%) var(--my, 20%),
    transparent 0%,
    rgba(10,9,7,.72) 42%,
    rgba(10,9,7,.97) 78%
  );
  opacity: 1;
  transition: opacity .9s ease;
}
body.lights-on .scrim{ opacity: 0; }

/* ---------------------------------------------------
   header
--------------------------------------------------- */
.site-header{
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem clamp(1.2rem, 4vw, 2.5rem);
  background: linear-gradient(to bottom, rgba(18,18,16,.9), rgba(18,18,16,0));
}

.brand{
  display: flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
}
.brand__mark{
  display: inline-block;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  background-color: var(--hazard);
  -webkit-mask-image: url("images/logo.png");
  mask-image: url("images/logo.png");
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
  filter: drop-shadow(0 0 6px rgba(0,0,0,.4));
}
.brand__name{
  font-family: var(--display);
  letter-spacing: .02em;
  font-size: 1.15rem;
  text-transform: lowercase;
}

.site-nav{
  display: flex;
  gap: clamp(1rem, 3vw, 2rem);
  font-family: var(--mono);
  font-size: .85rem;
  text-transform: lowercase;
  letter-spacing: .02em;
}
.site-nav a{
  text-decoration: none;
  color: var(--paper-dim);
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  transition: color .2s ease, border-color .2s ease;
}
.site-nav a:hover{ color: var(--hazard); border-color: var(--hazard); }

.switch{
  display: flex;
  align-items: center;
  gap: .55rem;
  background: none;
  border: 1px solid var(--wall-line);
  color: var(--paper);
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .03em;
  text-transform: lowercase;
  padding: .5rem .8rem .5rem .6rem;
  border-radius: 999px;
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease;
}
.switch:hover{ border-color: var(--hazard); }

.switch__chain{
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--hazard);
  box-shadow: 0 0 0 3px rgba(231,183,35,.16);
  flex-shrink: 0;
  transition: background .3s ease, box-shadow .3s ease;
}
body.lights-on .switch__chain{
  background: var(--bulb);
  box-shadow: 0 0 10px 3px rgba(255,223,156,.7);
}

.switch__state{ display: none; }
body.lights-off .switch__state--off{ display: inline; }
body.lights-on .switch__state--on{ display: inline; }

.switch--hero{
  position: relative;
  z-index: 41;
  margin: 2.6rem auto 0;
  padding: .95rem 1.6rem .95rem 1.2rem;
  font-size: 1.05rem;
  gap: .75rem;
}
.switch--hero .switch__chain{
  width: 15px;
  height: 15px;
  box-shadow: 0 0 12px 3px rgba(231,183,35,.65), 0 0 0 5px rgba(231,183,35,.16);
  animation: switch-glow 2.6s ease-in-out infinite;
}
body.lights-on .switch--hero .switch__chain{
  box-shadow: 0 0 18px 6px rgba(255,223,156,.85), 0 0 0 5px rgba(255,223,156,.2);
}
@keyframes switch-glow{
  0%, 100% { box-shadow: 0 0 12px 3px rgba(231,183,35,.65), 0 0 0 5px rgba(231,183,35,.16); }
  50% { box-shadow: 0 0 18px 5px rgba(231,183,35,.85), 0 0 0 5px rgba(231,183,35,.22); }
}
body.lights-on .switch--hero .switch__chain{ animation: none; }
@media (prefers-reduced-motion: reduce){
  .switch--hero .switch__chain{ animation: none; }
}

/* ---------------------------------------------------
   hero
--------------------------------------------------- */
.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 7rem 1.5rem 4rem;
  overflow: hidden;
  background:
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(255,223,156,.10), transparent 60%),
    repeating-linear-gradient(0deg, rgba(255,255,255,.015) 0 1px, transparent 1px 3px),
    var(--ink);
}

.hero__bulb-rig{
  position: absolute;
  top: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero__cord{
  width: 2px;
  height: 54px;
  background: linear-gradient(to bottom, rgba(237,231,216,.5), rgba(237,231,216,.15));
}
.hero__mark{
  width: 88px;
  height: 88px;
  margin-top: -4px;
  opacity: .45;
  filter:
    invert(1)
    brightness(.4)
    drop-shadow(0 0 0 rgba(255,223,156,0));
  transition: filter .6s ease, opacity .6s ease;
}
.hero__glow{
  position: absolute;
  top: 60px;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,223,156,.16), transparent 70%);
  filter: blur(2px);
  transition: opacity .8s ease, transform .8s ease;
  opacity: .55;
}
body.lights-on .hero__mark{
  opacity: 1;
  filter:
    invert(1)
    brightness(1.1)
    drop-shadow(0 0 10px rgba(255,223,156,.85))
    drop-shadow(0 0 34px rgba(255,223,156,.55));
}
body.lights-on .hero__glow{
  opacity: 1;
  transform: scale(1.25);
}

.hero__content{ position: relative; max-width: 46rem; }

.eyebrow{
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--hazard);
  margin: 0 0 1.1rem;
}

.hero__title{
  font-family: var(--display);
  text-transform: lowercase;
  margin: 0;
  line-height: .86;
  font-size: clamp(3.4rem, 13vw, 8.5rem);
  letter-spacing: -.01em;
}
.hero__title span{ display: block; }
.hero__title span:last-child{ color: var(--hazard); }

.hero__tagline{
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--paper-dim);
  max-width: 34rem;
  margin: 1.6rem auto 0;
}

.scroll-cue{
  position: absolute;
  bottom: 2.2rem;
  left: 50%;
  transform: translateX(-50%);
}
.scroll-cue span{
  display: block;
  width: 1px;
  height: 42px;
  background: linear-gradient(to bottom, transparent, var(--paper-dim));
  animation: cue 2.2s ease-in-out infinite;
}
@keyframes cue{
  0%, 100% { transform: scaleY(.6); opacity: .4; }
  50% { transform: scaleY(1); opacity: 1; }
}
@media (prefers-reduced-motion: reduce){
  .scroll-cue span{ animation: none; }
}

/* ---------------------------------------------------
   the wall / gallery
--------------------------------------------------- */
.wall{
  width: var(--wrap);
  margin: 0 auto;
  padding: 6rem 0 5rem;
}

.section-head{ max-width: 34rem; margin-bottom: 3rem; }
.section-head h2{
  font-family: var(--display);
  text-transform: lowercase;
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  margin: 0 0 .6rem;
  line-height: 1.05;
}
.section-sub{ color: var(--paper-dim); margin: 0; }
.section-note{
  font-family: var(--mono);
  font-size: .78rem;
  text-transform: lowercase;
  color: var(--hazard);
  opacity: .85;
  margin: .6rem 0 0;
}

.gallery{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.6rem, 3vw, 2.4rem);
}

.piece{
  margin: 0;
  position: relative;
  background: var(--wall);
  border: 1px solid var(--wall-line);
  padding: .8rem .8rem 1rem;
  transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}
.piece--r1{ transform: rotate(-1.4deg); }
.piece--r2{ transform: rotate(1.1deg); }
.piece--r3{ transform: rotate(-.6deg); }

.piece__trigger{
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  font: inherit;
  color: inherit;
}

.piece img{
  width: 100%;
  height: auto;
  display: block;
  filter: saturate(.85) contrast(1.02);
  transition: filter .4s ease, transform .5s ease;
}

.tape{
  position: absolute;
  top: -14px;
  left: 50%;
  width: 74px;
  height: 26px;
  transform: translateX(-50%) rotate(-3deg);
  background: rgba(231,183,35,.28);
  border: 1px solid rgba(231,183,35,.22);
  backdrop-filter: blur(1px);
}

.piece figcaption{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .6rem;
  padding-top: .75rem;
  font-family: var(--mono);
}
.piece__title{
  text-transform: lowercase;
  font-size: .92rem;
  letter-spacing: .01em;
}
.piece__tag{
  font-size: .68rem;
  color: var(--paper-dim);
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.piece:hover,
.piece:focus-within{
  transform: rotate(0deg) translateY(-4px);
  border-color: var(--hazard);
  box-shadow: 0 18px 34px rgba(0,0,0,.45);
  z-index: 2;
}
.piece:hover img,
.piece:focus-within img{
  filter: saturate(1) contrast(1);
  transform: scale(1.015);
}

/* ---------------------------------------------------
   manifesto
--------------------------------------------------- */
.manifesto{
  width: var(--wrap);
  margin: 0 auto;
  padding: 5rem 0 7rem;
  border-top: 1px dashed var(--wall-line);
  max-width: 46rem;
  position: relative;
}
.manifesto__mark{
  position: absolute;
  right: 0;
  top: 4.2rem;
  width: 84px;
  height: 84px;
  background-color: var(--hazard);
  -webkit-mask-image: url("images/logo.png");
  mask-image: url("images/logo.png");
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
  opacity: .9;
}

.manifesto__title{
  font-family: var(--display);
  text-transform: lowercase;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  line-height: 1.08;
  margin: 0 0 1.4rem;
  max-width: 26rem;
}
.manifesto__body{
  color: var(--paper-dim);
  font-size: 1.02rem;
  max-width: 32rem;
}
/* ---------------------------------------------------
   footer
--------------------------------------------------- */
.site-footer{
  border-top: 1px solid var(--wall-line);
  padding: 2.4rem clamp(1.2rem, 4vw, 2.5rem) 2.2rem;
}
.site-footer__top{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
  max-width: var(--wrap);
  margin: 0 auto;
}
.brand__name--footer{
  font-family: var(--display);
  text-transform: lowercase;
  font-size: 1.3rem;
}
.footer-links{
  list-style: none;
  display: flex;
  gap: 1.6rem;
  padding: 0;
  margin: 0;
  font-family: var(--mono);
  font-size: .82rem;
  text-transform: lowercase;
}
.footer-links a{ text-decoration: none; color: var(--paper-dim); }
.footer-links a:hover{ color: var(--hazard); }

.site-footer__bottom{
  max-width: var(--wrap);
  margin: 1.6rem auto 0;
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--paper-dim);
  opacity: .7;
}

/* ---------------------------------------------------
   responsive
--------------------------------------------------- */
@media (max-width: 900px){
  .gallery{ grid-template-columns: repeat(2, 1fr); }
  .manifesto__mark{ position: static; width: 60px; height: 60px; margin-bottom: 1.4rem; }
}

@media (max-width: 640px){
  .site-nav{ display: none; }
  .gallery{ grid-template-columns: 1fr; }
  .switch__label{ display: none; }
  .switch{ padding: .55rem; }
}

/* ---------------------------------------------------
   lightbox
--------------------------------------------------- */
.lightbox{
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1rem, 5vw, 4rem);
}
.lightbox[hidden]{ display: none; }

.lightbox__backdrop{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  margin: 0;
  padding: 0;
  background: rgba(8,7,6,.9);
  backdrop-filter: blur(2px);
  cursor: zoom-out;
  animation: lightbox-fade .25s ease both;
}

.lightbox__panel{
  position: relative;
  z-index: 1;
  margin: 0;
  max-width: min(90vw, 900px);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: lightbox-in .28s cubic-bezier(.2,.9,.3,1) both;
}

@keyframes lightbox-fade{
  from{ opacity: 0; }
  to{ opacity: 1; }
}
@keyframes lightbox-in{
  from{ opacity: 0; transform: scale(.96) translateY(8px); }
  to{ opacity: 1; transform: scale(1) translateY(0); }
}
@media (prefers-reduced-motion: reduce){
  .lightbox__backdrop, .lightbox__panel{ animation: none; }
}

.lightbox__frame{
  position: relative;
  display: inline-block;
  line-height: 0;
  max-width: 100%;
}

.lightbox__img{
  max-width: 100%;
  max-height: 68vh;
  width: auto;
  height: auto;
  border: 1px solid var(--wall-line);
  background: var(--wall);
}

@media (pointer: fine){
  .lightbox__img{ cursor: none; }
}

.magnifier{
  position: absolute;
  top: 0;
  left: 0;
  width: 190px;
  height: 190px;
  border-radius: var(--radius);
  border: 2px solid var(--hazard);
  box-shadow: 0 10px 26px rgba(0,0,0,.55), inset 0 0 0 1px rgba(0,0,0,.5);
  background-repeat: no-repeat;
  background-color: var(--wall);
  pointer-events: none;
  z-index: 5;
  display: none;
}
.magnifier.is-active{ display: block; }

@media (max-width: 640px){
  .magnifier{ width: 130px; height: 130px; }
}

.lightbox__hint{
  margin: .7rem 0 0;
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .03em;
  text-transform: lowercase;
  color: var(--paper-dim);
  opacity: .75;
}
.lightbox__hint--coarse{ display: none; }
@media (pointer: coarse){
  .lightbox__hint--fine{ display: none; }
  .lightbox__hint--coarse{ display: inline; }
}

.lightbox__close{
  position: absolute;
  top: -3rem;
  right: -.4rem;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  border: 1px solid var(--wall-line);
  background: var(--wall);
  color: var(--paper);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  transition: border-color .2s ease, color .2s ease;
}
.lightbox__close:hover{ border-color: var(--hazard); color: var(--hazard); }

.lightbox__caption{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding-top: .9rem;
  font-family: var(--mono);
}
.lightbox__caption .piece__title{ font-size: 1rem; text-transform: lowercase; }
.lightbox__caption .piece__tag{
  font-size: .7rem;
  color: var(--paper-dim);
  text-transform: uppercase;
  letter-spacing: .04em;
  white-space: nowrap;
}

@media (max-width: 640px){
  .lightbox__close{ top: -2.8rem; right: 0; }
}
