/* =========================================================
   ENTROPY — design tokens
   ========================================================= */
:root {
  /* color */
  --bg:          #0a0a0c;
  --surface:     #131317;
  --border:      #232327;
  --text:        #ececee;
  --text-dim:    #8b8b93;
  --accent:      #4bece0;   /* cold cyan — signal */
  --accent-dim:  rgba(75, 236, 224, 0.14);
  --noise-red:   #ff3b5c;   /* used only in the hero glitch split */

  /* type */
  --f-display: 'Space Grotesk', sans-serif;
  --f-body:    'Inter', sans-serif;
  --f-mono:    'JetBrains Mono', monospace;

  /* layout */
  --maxw: 1320px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
}

/* =========================================================
   Reset
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--f-display); margin: 0; font-weight: 500; }
p { margin: 0; }

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

.wrap {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.eyebrow {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-dim);
}

/* =========================================================
   Grain — static entropy texture, applied once, never animated
   ========================================================= */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%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");
}

/* =========================================================
   Nav
   ========================================================= */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem var(--gutter);
  background: rgba(10, 10, 12, 0.82);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.brand {
  font-family: var(--f-display);
  font-size: 1.05rem;
  letter-spacing: 0.04em;
}

.brand span { color: var(--accent); }

.nav-links { display: flex; gap: 2rem; }

.nav-links a {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.nav-links a:hover,
.nav-links a[aria-current="page"] { color: var(--text); }

/* =========================================================
   Hero
   ========================================================= */
.hero {
  min-height: 88vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--gutter);
  position: relative;
}

.hero-sequence {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.75rem;
}

.hero-sequence .eyebrow:not(:last-child)::after {
  content: '→';
  margin-left: 0.75rem;
  color: var(--border);
}

/* Signature element: a frozen glitch split — signal breaking into
   noise. Static (no animation) per brief. Red/cyan channel offset
   is a deliberate, one-time exception to the single-accent rule,
   scoped to this element only. */
.hero-title {
  position: relative;
  font-size: clamp(3.5rem, 13vw, 9.5rem);
  line-height: 0.92;
  letter-spacing: -0.03em;
  color: var(--text);
  width: fit-content;
}

.hero-title::before,
.hero-title::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  mix-blend-mode: screen;
}

.hero-title::before {
  color: var(--accent);
  clip-path: polygon(0 0, 100% 0, 100% 42%, 0 42%);
  transform: translate(-6px, -3px);
  opacity: 0.75;
}

.hero-title::after {
  color: var(--noise-red);
  clip-path: polygon(0 58%, 100% 58%, 100% 100%, 0 100%);
  transform: translate(5px, 3px);
  opacity: 0.6;
}

.hero-line {
  margin-top: 2rem;
  max-width: 42ch;
  font-size: 1.15rem;
  color: var(--text-dim);
}

.hero-line strong { color: var(--text); font-weight: 500; }

/* =========================================================
   Gallery preview strip on homepage
   ========================================================= */
.preview {
  padding: 4rem var(--gutter) 6rem;
  border-top: 1px solid var(--border);
}

.preview-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.preview-head h2 { font-size: 1.4rem; }

.preview-head a {
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  white-space: nowrap;
}

.preview-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--gutter);
}

.preview-strip .frame:nth-child(2) { margin-top: 2.5rem; }
.preview-strip .frame:nth-child(4) { margin-top: 4rem; }

@media (max-width: 900px) {
  .preview-strip { grid-template-columns: repeat(2, 1fr); }
  .preview-strip .frame:nth-child(n) { margin-top: 0; }
}

/* frameless image treatment — no border, no shadow, no radius */
.frame img,
.frame .placeholder { width: 100%; height: auto; display: block; }

.placeholder {
  aspect-ratio: var(--ar, 3/4);
  background:
    linear-gradient(160deg, var(--surface), var(--bg));
  position: relative;
  overflow: hidden;
}

.placeholder::after {
  content: attr(data-label);
  position: absolute;
  bottom: 0.75rem;
  left: 0.75rem;
  font-family: var(--f-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--text-dim);
}

/* =========================================================
   Footer
   ========================================================= */
.site-footer {
  padding: 2.5rem var(--gutter);
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--text-dim);
}

.site-footer a:hover { color: var(--text); }

/* =========================================================
   Gallery page — masonry via CSS columns, no JS layout needed
   ========================================================= */
.gallery-header {
  padding: 6rem var(--gutter) 3rem;
  border-bottom: 1px solid var(--border);
}

.gallery-header h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  margin-top: 0.75rem;
}

.masonry {
  column-count: 3;
  column-gap: var(--gutter);
  padding: var(--gutter);
}

@media (max-width: 1100px) { .masonry { column-count: 2; } }
@media (max-width: 640px)  { .masonry { column-count: 1; } }

.masonry .frame {
  break-inside: avoid;
  margin-bottom: var(--gutter);
}

/* scroll-reveal — the one animation permitted on this page */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
