/* ═══════════════════════════════════════════════════════════
   COOKED CORP — SHARED STYLES
   Single source of truth. Every page links this file.
   ═══════════════════════════════════════════════════════════ */

@import url('fonts/fonts.css');

:root {
  /* surfaces */
  --black:        #0d1210;   /* slate board */
  --off-black:    #121816;
  --panel:        #161d1a;

  /* borders */
  --border:       rgba(238,240,230,0.16);
  --border-mid:   rgba(238,240,230,0.28);
  --border-bright:rgba(238,240,230,0.42);

  /* text */
  --white:        #baf6cc;
  --text:         #d2e6d6;   /* phosphor */
  --text-dim:     #7fae90;
  --text-dimmer:  #5c6560;
  --grey:         #8d9689;   /* alias of --text-dim, kept for legacy rules */

  /* type */
  --font-display: 'Oswald', sans-serif;   /* fallback before ransom letters mount */
  --font-label:   'Special Elite', monospace;
  --font-body:    'Chakra Petch', sans-serif;
  --font-mono:    'Courier Prime', monospace;  /* alias */
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  scroll-behavior: smooth;
  background:
    radial-gradient(120% 80% at 18% 12%, rgba(238,240,230,0.055), transparent 60%),
    radial-gradient(90% 70% at 82% 88%, rgba(238,240,230,0.04), transparent 62%),
    var(--black);
}

/* ── PHOSPHOR SCANLINES on the prose column ─────────────── */
.lore-body { position: relative; }
.lore-body::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background: repeating-linear-gradient(0deg, rgba(0,0,0,0.16) 0 1px, transparent 1px 3px);
  mix-blend-mode: multiply;
  opacity: 0.5;
}

/* ── RADIAL WAVE (rings breathing outward from centre) ── */
@keyframes waveOut {
  0%   { transform: scale(0.72); opacity: 0; }
  18%  { opacity: 0.5; }
  70%  { opacity: 0.32; }
  100% { transform: scale(1.62); opacity: 0; }
}
body[data-fractal]::after {
  content: '';
  position: fixed;
  inset: -22%;
  z-index: -1;
  pointer-events: none;
  transform-origin: 50% 50%;
  background: repeating-radial-gradient(circle at 50% 50%,
    rgba(238,240,230,0) 0 58px,
    rgba(238,240,230,0.016) 70px,
    rgba(238,240,230,0.05) 82px,
    rgba(238,240,230,0.016) 94px,
    rgba(238,240,230,0) 108px 164px);
  animation: waveOut 19s linear infinite;
  mask-image: radial-gradient(70% 62% at 50% 50%, #000 8%, rgba(0,0,0,0.45) 48%, transparent 84%);
  -webkit-mask-image: radial-gradient(70% 62% at 50% 50%, #000 8%, rgba(0,0,0,0.45) 48%, transparent 84%);
  will-change: transform, opacity;
  backface-visibility: hidden;
}

/* ── FRACTAL BACKDROP ──────────────────────────────────── */
@keyframes fractalSpiral {
  0%   { transform: rotate(0deg) scale(1.34); }
  25%  { transform: rotate(90deg) scale(1.46); }
  50%  { transform: rotate(180deg) scale(1.36); }
  75%  { transform: rotate(270deg) scale(1.48); }
  100% { transform: rotate(360deg) scale(1.34); }
}
@keyframes fractalBreathe {
  0%, 100% { opacity: 0.26; }
  50%      { opacity: 0.4; }
}
#fractal {
  position: fixed;
  inset: 0;
  animation: fractalSpiral 210s linear infinite, fractalBreathe 41s ease-in-out infinite;
  will-change: transform, opacity;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
  object-fit: contain;
  opacity: 0.6;
  transform-origin: 50% 50%;
  backface-visibility: hidden;
  /* blur and radial falloff are baked into the PNG, so the spiral is a
     pure compositor transform — nothing recomputed per frame */
  contain: strict;
}

body {
  background: transparent;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.9;
  letter-spacing: 0.045em;
  font-variant-ligatures: none;
  overflow-x: hidden;
  cursor: none;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
}

/* landing page locks scroll; content pages don't */
html.is-landing, html.is-landing body { height: 100%; }
html.is-landing body { overflow: hidden; font-size: 17px; }

*, a, button, input, select, textarea { cursor: none !important; }

/* ── RANSOM LETTERS (cut-and-pasted headers) ─────────── */
[data-scrawl] { display: inline-block; }
[data-scrawl] > i { display: inline-block; font-style: normal; }

/* ── SCANLINES ─────────────────────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg, transparent, transparent 2px,
    rgba(0,0,0,0.05) 2px, rgba(0,0,0,0.05) 4px
  );
  pointer-events: none;
  z-index: 900;
}

/* ── EYE CURSOR ────────────────────────────────────────── */
.cursor {
  position: fixed;
  width: 24px;
  height: 15px;
  pointer-events: none;
  z-index: 99999;
  transform: translate(-50%, -50%);
  will-change: transform;
  opacity: 0;
  transition: opacity 0.2s;
}
.cursor svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 3px rgba(150,220,170,0.55)) drop-shadow(0 0 9px rgba(120,200,145,0.3));
  overflow: visible;
  transition: transform 0.15s ease;
}
.cursor.hover svg { transform: scale(1.35); }

@media (hover: none), (pointer: coarse) {
  .cursor { display: none; }
  *, a, button, input, select, textarea { cursor: auto !important; }
}

/* ── LAYOUT ────────────────────────────────────────────── */
.container { max-width: 1080px; margin: 0 auto; padding: 0 36px; }

.section-label {
  font-family: var(--font-label);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dimmer);
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 48px;
}
.section-label::after { content: ''; flex: 1; height: 0; border-top: 1.5px dashed var(--border); opacity: 0.8; }

/* ── TOP NAV ───────────────────────────────────────────── */
.top-nav::before {
  content: '';
  position: absolute;
  inset: -8px 0 -48px;
  pointer-events: none;
  background: linear-gradient(to bottom, var(--black) 34%, rgba(13,18,16,0.85) 62%, transparent);
}
.top-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 500;
  padding: 32px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  position: relative;
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  z-index: 600;
  position: relative;
}
.nav-logo img {
  height: 32px;
  width: auto;
  opacity: 0.88;
  transition: opacity 0.3s;
}
.nav-logo-text {
  font-family: var(--font-display);
  font-size: 21px;
  color: var(--white);
  letter-spacing: 0;
  transition: color 0.3s;
}

body.menu-open .nav-logo img   { opacity: 0.4; }
body.menu-open .nav-logo-text  { color: rgba(240,236,228,0.5); }

/* ── MENU TOGGLE ───────────────────────────────────────── */
.menu-toggle {
  position: relative;
  z-index: 2;
  z-index: 600;
  background: none;
  border: none;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 1.5px;
  background: var(--white);
  transition: transform 0.35s ease, opacity 0.25s ease;
  transform-origin: center;
}
body.menu-open .menu-toggle span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
body.menu-open .menu-toggle span:nth-child(2) { opacity: 0; transform: scaleX(0); }
body.menu-open .menu-toggle span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── MENU OVERLAY ──────────────────────────────────────── */
.menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 400;
  background: rgba(13,18,16,0.975);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
  padding: 0 52px;
}
body.menu-open .menu-overlay { opacity: 1; pointer-events: all; }

.menu-nav {
  list-style: none;
  text-align: right;
  display: flex;
  flex-direction: column;
  width: 100%;
}
.menu-nav a {
  font-family: var(--font-display);
  letter-spacing: 0;
  font-size: clamp(24px, 3.4vw, 40px);
  color: var(--white);
  text-decoration: none;
  display: block;
  width: 100%;
  padding: 14px 0;
  line-height: 1.5;
  transition: color 0.2s;
}
.menu-nav a { opacity: 0.45; transition: opacity 0.2s; }
.menu-nav a:hover,
.menu-nav a.current { color: var(--white); opacity: 1; }

.menu-footer {
  position: absolute;
  bottom: 36px;
  right: 52px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  text-align: right;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--text-dim);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.menu-footer a {
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.2s;
}
.menu-footer a:hover { color: var(--white); }
.menu-footer-links { display: flex; gap: 24px; }

/* ── HERO (landing) ────────────────────────────────────── */
.hero { position: fixed; inset: 0; z-index: 0; }
.hero-artwork {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
  display: block;
}
.hero-gradient {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: 180px;
  background: linear-gradient(to top, rgba(8,8,8,0.75), transparent);
  z-index: 1;
  pointer-events: none;
}

/* ── PAGE HERO (content pages) ─────────────────────────── */
.page-hero {
  position: relative;
  padding: 148px 0 56px;
  border-bottom: 1.5px dashed var(--border);
}
.page-title {
  font-family: var(--font-display);
  will-change: opacity;
  font-size: clamp(42px, 7.4vw, 92px);
  color: var(--white);
  letter-spacing: 0;
  text-transform: none;
  line-height: 1.45;
}
.page-sub {
  font-family: var(--font-body);
  font-size: 17px;
  color: var(--text-dim);
  letter-spacing: 0.02em;
  text-transform: none;
  margin-top: 20px;
}

/* ── FOOTER ────────────────────────────────────────────── */
/* fixed variant — landing only */
.footer-fixed {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 10;
  padding: 28px 48px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}
/* flow variant — content pages */
.footer {
  border-top: 1.5px dashed var(--border);
  padding: 36px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-copy,
.footer-link {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--text-dim);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
}
.footer-links { display: flex; gap: 24px; }
.footer-link { transition: color 0.2s; }
.footer-link:hover { color: var(--white); }

/* ── UTILITY ───────────────────────────────────────────── */
.redacted {
  background: var(--text-dim);
  color: transparent;
  border-radius: 1px;
  user-select: none;
  padding: 0 5px;
}

.tag {
  font-family: var(--font-label);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dimmer);
  border: 1px solid var(--border);
  padding: 4px 10px;
  display: inline-block;
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--border);
}
table.data-table th,
table.data-table td {
  padding: 10px 14px;
  text-align: left;
  font-family: var(--font-body);
  font-size: 15px;
  border-bottom: 1px dashed var(--border);
}
table.data-table th {
  font-family: var(--font-label);
  font-size: 10px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-dimmer);
  background: var(--panel);
}
table.data-table td { color: var(--text-dim); }
table.data-table tr:last-child td { border-bottom: none; }
table.data-table tbody tr:hover td { background: var(--off-black); }

/* ── RESPONSIVE ────────────────────────────────────────── */
@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .footer-inner { flex-direction: column; gap: 14px; text-align: center; }
}
@media (max-width: 640px) {
  .top-nav     { padding: 22px 24px; }
  .footer-fixed{ padding: 20px 24px; }
  .menu-overlay{ padding: 0 24px; }
  .menu-footer { right: 24px; }
}
