/* ============================================================
   C#NT — THE PICTURES (/photos)
   The photographer's frames from the night. Same chrome as
   /aftermath; hard edges: no radius, no shadows, no gradients.
   ============================================================ */

:root {
  --green: #39FF14;
  --blue:  #1F1FD4;
  --pink:  #FF1493;
  --ground:#0A0A0A;
  --black: #000000;
  --bone:  #F2F0EC;
  --panel: #111111;
  --border:#211F1C;
  --body:  #8A857D;
  --anton: 'Anton', sans-serif;
  --mono:  'Space Mono', monospace;
  --gap: 6px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  background: var(--ground);
  color: var(--bone);
  font-family: var(--mono);
  min-height: 100vh;
}
body.is-open { overflow: hidden; }

.page {
  width: min(1180px, 100vw);
  margin: 0 auto;
  padding: 0 16px 96px;
}

/* ---------------- film grain + CRT (as /aftermath) ---------------- */
.grain {
  position: fixed;
  inset: -50%;
  width: 200%;
  height: 200%;
  z-index: 60;
  pointer-events: none;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain-shift 1.2s steps(3) infinite;
}
@keyframes grain-shift {
  0%   { transform: translate(0, 0); }
  33%  { transform: translate(-4%, 3%); }
  66%  { transform: translate(3%, -3%); }
  100% { transform: translate(0, 0); }
}

.crt {
  position: fixed;
  inset: 0;
  z-index: 61;
  pointer-events: none;
  background:
    repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.16) 0, rgba(0, 0, 0, 0.16) 1px, transparent 1px, transparent 3px),
    radial-gradient(130% 130% at 50% 50%, transparent 55%, rgba(0, 0, 0, 0.5) 100%);
  animation: crt-flicker 4s steps(40) infinite;
}
.crt::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -25%;
  height: 24%;
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.045), transparent);
  animation: crt-roll 8s linear infinite;
}
@keyframes crt-roll   { 0% { top: -25%; } 100% { top: 100%; } }
@keyframes crt-flicker {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.94; }
  52% { opacity: 1; }
  70% { opacity: 0.975; }
}
/* the overlays are page chrome, not part of the pictures: while a frame is
   open they come off entirely, so the photo is seen clean (Alexis, 8 Sep) */
body.is-open .crt, body.is-open .grain { display: none; }

/* ---------------- header ---------------- */
.head {
  position: relative;
  padding: 40px 0 24px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 20px;
}
.head__punch {
  position: absolute;
  top: 14px;
  right: -6px;
  width: 42px;
  height: 42px;
  pointer-events: none;
}
.lk { display: block; width: 232px; text-decoration: none; }
.lk__block {
  display: block;
  text-align: center;
  background: transparent;
  border: 0.06em solid currentColor;
  color: var(--green);
  font-family: var(--anton);
  font-weight: 400;
  font-size: 54px;
  line-height: 0.86;
  padding: 0.1em 0;
  transform: skewX(-6deg);
}
.hash {
  display: inline-block;
  width: 0.62em;
  height: 0.87em;
  margin: 0 0.02em;
  vertical-align: baseline;
}
.lk__strap {
  display: flex;
  justify-content: space-between;
  width: 100%;
  margin-top: 9px;
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--bone);
}

.label {
  margin-top: 28px;
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--green);
}
.head__title {
  font-family: var(--anton);
  font-size: clamp(40px, 9vw, 82px);
  line-height: 0.9;
  transform: skewX(-6deg);
  margin-top: 8px;
  color: var(--bone);
}
.head__sub {
  margin-top: 14px;
  font-size: 13px;
  line-height: 1.75;
  color: var(--body);
  max-width: 62ch;
}
.head__sub b { color: var(--bone); font-weight: 400; }
.head__sub a { color: var(--green); text-decoration: none; }
.head__sub a:hover, .head__sub a:focus-visible { color: var(--bone); outline: none; }
.head__meta {
  margin-top: 10px;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--body);
}

/* ---------------- the wall ----------------
   A grid in the photographer's order, row by row - 1 2 3 4 / 5 6 7 8 -
   four across on a desktop, three on a tablet, two on a phone. Every row
   is the height of a portrait cell (js/photos.js sets --row-h from the
   measured cell width), so rows stay uniform whatever they hold. A
   landscape frame spans two cells (see .frame--wide) unless it would land
   in the last column. Order is never rearranged: no dense packing. */
.wall {
  --cols: 4;
  display: grid;
  grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
  grid-auto-rows: var(--row-h, 300px);
  gap: var(--gap);
}
.frame {
  display: block;
  position: relative;
  overflow: hidden;
  background: var(--panel);
  border: 1px solid var(--border);
  -webkit-tap-highlight-color: transparent;
}
.frame--wide { grid-column: span 2; }
.frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;                    /* a 3:2 in a two-cell box is ~4:3: a sliver off each side */
}
/* no number on the pictures (Alexis, 8 Sep). hover is a colour swap on the
   border, never a fade (brand: "color swap rather than opacity/scale") */
.frame:hover, .frame:focus-visible { border-color: var(--green); outline: none; }

/* Brand imagery rule (cnt-assets/brand/README.md, "Imagery"): post-event
   photography is flash B&W + grain or a green/blue duotone. The frames go up
   in the photographer's colour; add class "wall--mono" to .wall to show the
   wall in B&W and keep colour for the opened frame and the download. */
.wall--mono .frame img { filter: grayscale(1) contrast(1.12); }

/* ---------------- footer ---------------- */
.foot {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.foot__note {
  width: 100%;
  margin-top: 8px;
  font-size: 12px;
  line-height: 1.75;
  color: var(--body);
}

.btn {
  display: inline-block;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 13px 20px;
  border: 1px solid var(--green);
  background: var(--green);
  color: var(--black);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.box__nav { -webkit-tap-highlight-color: transparent; }
.btn:hover, .btn:focus-visible { background: var(--ground); color: var(--green); outline: none; }
.btn--ghost { background: transparent; color: var(--bone); border-color: var(--border); }
.btn--ghost:hover, .btn--ghost:focus-visible { color: var(--green); border-color: var(--green); }
.btn--sm { padding: 10px 14px; font-size: 11px; }

.note {
  font-size: 13px;
  line-height: 1.8;
  color: var(--body);
  padding: 40px 0;
}

/* ---------------- one frame, full screen ---------------- */
.box {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: var(--black);
  display: flex;
  flex-direction: column;
}
.box__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) 14px 10px;
  border-bottom: 1px solid var(--border);
  flex: none;
}
.box__pos {
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.3em;
  color: var(--green);
}
.box__acts { display: flex; gap: 8px; }

.box__fig {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 10px;
  padding-bottom: calc(10px + env(safe-area-inset-bottom));
}
.box__img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  background: var(--panel);
  /* the previous frame stays until the next has decoded, no white flash */
}
.box__cap {
  flex: none;
  margin-top: 10px;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--body);
  text-align: center;
}

.box__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 56px;
  height: 96px;
  border: 1px solid var(--border);
  background: var(--black);
  color: var(--bone);
  font-family: var(--mono);
  font-size: 22px;
  cursor: pointer;
}
.box__nav:hover, .box__nav:focus-visible { color: var(--green); border-color: var(--green); outline: none; }
.box__nav--prev { left: 0; border-left: 0; }
.box__nav--next { right: 0; border-right: 0; }
.box__nav[disabled] { opacity: 0.25; cursor: default; }

@media (prefers-reduced-motion: reduce) {
  .crt { animation: none; }
  .crt::after { display: none; }
  .grain { animation: none; }
}

@media (max-width: 900px) {
  .wall { --cols: 3; }
}
@media (max-width: 560px) {
  .lk__block { font-size: 40px; }
  .wall { --cols: 2; }
  .box__nav { width: 40px; height: 72px; font-size: 18px; }
  .btn--sm { padding: 9px 11px; font-size: 10px; letter-spacing: 0.18em; }
}
