:root {
  --bg: #080808;
  --text: #e2ddd5;
  --text-dim: #64605a;
  --text-muted: #2e2c29;
  --accent: #c4b49a;
  --font-display: 'Fraunces', serif;
  --font-ui: 'Syne', sans-serif;
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 14px;
  line-height: 1.5;
  cursor: none;
  overflow-x: hidden;
  scrollbar-width: none;
}

body::-webkit-scrollbar { display: none; }

/* ─── SCROLL PROGRESS ────────────────── */
.scroll-progress {
  position: fixed;
  right: 0;
  top: 0;
  width: 1px;
  height: 0%;
  background: var(--text-dim);
  z-index: 9998;
  pointer-events: none;
  transition: height 0.05s linear;
}


/* ─── GRAIN ──────────────────────────── */
.grain {
  position: fixed;
  inset: -100px;
  width: calc(100% + 200px);
  height: calc(100% + 200px);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-size: 220px 220px;
  opacity: 0.055;
  pointer-events: none;
  z-index: 9999;
  animation: grain 0.65s steps(1) infinite;
}

@keyframes grain {
  0%   { transform: translate(0, 0); }
  10%  { transform: translate(-3%, -4%); }
  20%  { transform: translate(4%,  2%); }
  30%  { transform: translate(-2%, 4%); }
  40%  { transform: translate(3%, -2%); }
  50%  { transform: translate(-4%, 3%); }
  60%  { transform: translate(2%,  4%); }
  70%  { transform: translate(-3%, 1%); }
  80%  { transform: translate(4%, -3%); }
  90%  { transform: translate(-1%, -4%); }
  100% { transform: translate(3%,  2%); }
}

/* ─── CURSOR ─────────────────────────── */
.cursor {
  position: fixed;
  top: 0; left: 0;
  width: 18px;
  height: 18px;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: width 0.3s, height 0.3s;
  will-change: transform;
}

/* Crosshair arms */
.cursor::before,
.cursor::after {
  content: '';
  position: absolute;
  background: var(--text);
  transition: background 0.3s, width 0.3s, height 0.3s;
}

.cursor::before {
  width: 1px;
  height: 100%;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
}

.cursor::after {
  height: 1px;
  width: 100%;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}

.cursor-follower {
  position: fixed;
  top: 0; left: 0;
  width: 27px;
  height: 27px;
  border: 1px solid rgba(226, 221, 213, 0.28);
  border-radius: 2px;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  transition: width 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              height 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              border-color 0.4s;
  will-change: transform;
}

.cursor.active::before,
.cursor.active::after {
  background: var(--accent);
}

.cursor-follower.active {
  width: 46px;
  height: 46px;
  border-color: rgba(196, 180, 154, 0.4);
}

/* ─── NAV ────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 32px 52px;
}

.nav-logo {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--text);
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 44px;
}

.nav-link {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.3s;
}

.nav-link:hover {
  color: var(--text);
}

/* ─── HERO ───────────────────────────── */
.hero {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 136px 52px 52px;
  position: relative;
  overflow: hidden;
}

/* Uncomment to use a full-screen video hero */
.hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 20px;
}

.svg-filters {
  position: absolute;
  width: 0;
  height: 0;
  pointer-events: none;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(72px, 11vw, 152px);
  font-weight: 400;
  line-height: 0.88;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #3dd6c8;
  filter: url(#hero-distort);
  text-shadow:
    0 0 55px rgba(61, 214, 200, 0.6),
    0 0 120px rgba(61, 214, 200, 0.22);
}

.hero-scroll {
  display: none;
  position: absolute;
  bottom: 52px;
  right: 52px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  z-index: 1;
}

.hero-scroll span {
  font-size: 10px;
  font-weight: 300;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
  writing-mode: vertical-rl;
}

.scroll-line {
  width: 1px;
  height: 56px;
  background: linear-gradient(to bottom, var(--text-dim), transparent);
  animation: pulse 2.2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.35; }
  50%       { opacity: 1; }
}

/* ─── WORK ───────────────────────────── */
.work {
  padding: 110px 52px 140px;
}

.work-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 36px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(255,255,255,0.055);
}

.section-label {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.filter-tabs {
  display: flex;
  gap: 28px;
}

.filter-btn {
  background: none;
  border: none;
  border-bottom: 1px solid transparent;
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  cursor: none;
  padding-bottom: 3px;
  transition: color 0.3s, border-color 0.3s;
}

.filter-btn:hover {
  color: var(--text);
}

.filter-btn.active {
  color: var(--text);
  border-color: var(--text);
}

/* ─── GRID ───────────────────────────── */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}

/* ─── CARD ───────────────────────────── */
.project-card {
  cursor: none;
  position: relative;
}

.project-card.hidden {
  display: none;
}

.card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0e0e0e;
}

.card-thumb {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 35% 45%, var(--c2, #1a1a2e), var(--c1, #0d0d11) 70%);
}

.card-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 1;
}

/* Vignette scrim */
.card-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,0.45) 100%);
  opacity: 0;
  transition: opacity 0.5s;
  z-index: 1;
  pointer-events: none;
}

.project-card:hover .card-media::after {
  opacity: 1;
}

.card-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 36px 10px 10px;
  background: linear-gradient(to top, rgba(0,0,0,0.55) 0%, transparent 100%);
  z-index: 2;
  pointer-events: none;
  display: flex;
  flex-direction: row;
  align-items: baseline;
  gap: 0;
}

.card-meta { display: none; }

/* Title glitch / RGB split */
@keyframes rgbSplit {
  0%   { text-shadow: 0 1px 12px rgba(0,0,0,0.9); }
  20%  { text-shadow: -2px 0 rgba(255,0,60,0.65), 2px 0 rgba(20,40,255,0.55), 0 1px 12px rgba(0,0,0,0.9); }
  45%  { text-shadow: 2px 0 rgba(255,0,60,0.45), -2px 0 rgba(20,40,255,0.45), 0 1px 12px rgba(0,0,0,0.9); }
  70%  { text-shadow: -1px 0 rgba(255,0,60,0.2), 1px 0 rgba(20,40,255,0.2), 0 1px 12px rgba(0,0,0,0.9); }
  100% { text-shadow: 0 1px 12px rgba(0,0,0,0.9); }
}

.card-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--text);
  line-height: 1;
  text-shadow: 0 1px 10px rgba(0,0,0,0.95);
  opacity: 0;
  transition: opacity 0.2s;
  white-space: nowrap;
}

.card-sub {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  text-shadow: 0 1px 10px rgba(0,0,0,0.95);
  opacity: 0;
  transition: opacity 0.2s 0.05s;
  white-space: nowrap;
}

.card-sub:not(:empty)::before {
  content: ' — ';
  color: var(--text-muted);
}

.project-card:hover .card-title,
.project-card:hover .card-sub {
  opacity: 1;
}

.card-title.glitch {
  animation: rgbSplit 0.4s ease-out forwards;
}

/* ─── CONTACT ────────────────────────── */
.contact {
  padding: 120px 52px 80px;
  border-top: 1px solid rgba(255,255,255,0.055);
  display: flex;
  flex-direction: column;
  gap: 56px;
}

.contact-nav {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-bottom: 1px solid rgba(255,255,255,0.055);
  padding-bottom: 16px;
}

.contact-tabs {
  display: flex;
  gap: 32px;
}

.contact-ig-icon {
  color: var(--text-muted);
  transition: color 0.3s;
  display: flex;
  align-items: center;
  cursor: none;
}

.contact-ig-icon:hover {
  color: var(--text);
}

.contact-tab {
  background: none;
  border: none;
  border-bottom: 1px solid transparent;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  cursor: none;
  padding-bottom: 4px;
  margin-bottom: -17px;
  transition: color 0.3s, border-color 0.3s;
}

.contact-tab:hover { color: var(--text); }

.contact-tab.active {
  color: var(--text);
  border-color: var(--text);
}

.contact-panel { display: flex; flex-direction: column; gap: 28px; }
.contact-panel.hidden { display: none; }

.contact-inner {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.contact-desc {
  font-size: 13px;
  letter-spacing: 0.02em;
  color: var(--text-dim);
  max-width: 400px;
  line-height: 1.7;
}

/* ─── KIT ────────────────────────────── */
.kit-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.kit-item {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.5vw, 52px);
  font-weight: 300;
  letter-spacing: -0.01em;
  color: var(--text);
  line-height: 1.1;
  border-bottom: 1px solid rgba(255,255,255,0.055);
  padding-bottom: 16px;
  padding-top: 16px;
}

.kit-item:first-child { padding-top: 0; }

.contact-email {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(32px, 4.5vw, 64px);
  font-weight: 300;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
  transition: color 0.35s;
  line-height: 1;
}

.contact-email:hover {
  color: var(--accent);
}

.contact-socials {
  display: flex;
  align-items: center;
  gap: 18px;
}

.contact-social {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.3s;
}

.contact-social:hover {
  color: var(--text);
}

.divider {
  color: var(--text-muted);
}

.footer-copy {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}


/* ─── RESPONSIVE ─────────────────────── */
@media (max-width: 1024px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .nav      { padding: 24px 28px; }
  .hero     { padding: 110px 28px 44px; }
  .work     { padding: 90px 28px 100px; }
  .contact  { padding: 80px 28px 60px; gap: 40px; }
  .work-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
}

@media (max-width: 600px) {
  .grid { grid-template-columns: 1fr; gap: 2px; }
  .nav-links { gap: 24px; }
}
