* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background-color: #F4EFE6;
  color: #1E1C19;
  font-family: 'DM Sans', sans-serif;
}

/* Grain overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
}

/* Fade-in on load */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-up { animation: fadeUp 0.7s ease forwards; }
.delay-1 { animation-delay: 0.1s;  opacity: 0; }
.delay-2 { animation-delay: 0.25s; opacity: 0; }
.delay-3 { animation-delay: 0.4s;  opacity: 0; }
.delay-4 { animation-delay: 0.55s; opacity: 0; }

/* Divider rule */
.ruled { border-top: 1px solid #D6CFC2; }

/* Nav link */
.nav-link {
  position: relative;
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9E9890;
  transition: color 0.2s;
}
.nav-link:hover { color: #1E1C19; }
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: #B87333;
  transition: width 0.25s ease;
}
.nav-link:hover::after { width: 100%; }

/* Card hover lift */
.card {
  background: #EDE7D9;
  border: 1px solid #D6CFC2;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(30, 28, 25, 0.08);
}


/* Tag pill */
.tag {
  display: inline-block;
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  background: #D6CFC2;
  color: #3A3830;
  padding: 2px 9px;
  border-radius: 99px;
}

/* Section label */
.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #9E9890;
}
#lightbox.open {
  display: flex;
}

/* Controller SVG background accent */
.controller-bg {
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0.45;
  pointer-events: none;
  width: 300px;
}

/* Timeline */
.timeline-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #B87333;
  flex-shrink: 0;
  margin-top: 6px;
}
.timeline-line {
  width: 1px;
  background: #D6CFC2;
  flex-shrink: 0;
  margin-left: 4px;
}

/* Video placeholder */
.video-placeholder {
  background: #D6CFC2;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
}

/* Video play affordance */
.video-wrapper {
  position: relative;
  overflow: hidden;
}
.video-wrapper .play-hint {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: rgba(30, 28, 25, 0.35);
  backdrop-filter: blur(0.3px);
  color: #F4EFE6;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 2;
}
.video-wrapper .play-hint svg {
  width: 52px;
  height: 52px;
  opacity: 0.92;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
}
.video-wrapper .play-hint span {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.85;
}
.video-wrapper:hover .play-hint,
.video-wrapper.playing .play-hint {
  opacity: 0;
}

/* Skill chip */
.skill-chip {
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  color: #3A3830;
  background: #EDE7D9;
  border: 1px solid #D6CFC2;
  padding: 5px 14px;
  border-radius: 4px;
  transition: background 0.15s, border-color 0.15s;
}
.skill-chip:hover {
  background: #D6CFC2;
  border-color: #9E9890;
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}