body.page-video{
  background: var(--text);
  color: var(--text);
  overflow-x: hidden;
  overflow-y: auto;
}

/* Header acts like a “video banner bar” */
.video-header{
  position: relative;   /* ✅ static flow */
  width: 100%;
  height: 84px;
  overflow: hidden;
  background: rgba(8,8,8,0.96);
  z-index: auto;        /* not needed but safe */
}

/* Video only inside header */
.header-video{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.25) contrast(1.08) saturate(1.05);
  z-index: 0;
}

/* Darken the header video for readability */
.header-fade{
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(8,8,8,0.65), rgba(8,8,8,0.25));
  z-index: 1;
  pointer-events: none;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: min(340px, 82vw);
  padding: 92px 22px 22px;
  display: flex;
  flex-direction: column;
  gap: 36px;
  background: rgba(8,8,8,0.92);
  backdrop-filter: blur(12px);
  transform: translateX(100%);
  opacity: 0;
  pointer-events: none;
  transition: transform .28s ease, opacity .28s ease;
  z-index: 70;
  align-items: flex-end;   /* ✅ push items to right */
  text-align: right;       /* ✅ align text right */
}

/* Header content */
.video-header-inner{
  position: relative;
  z-index: 2;
  height: 100%;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  backdrop-filter: blur(6px);
}


/* Brand */
.video-brand{
  font-family: var(--font-brand);
  font-size: clamp(1.35rem, 2vw, 3rem);
  letter-spacing: 0.08em;
  color: var(--accent);
  text-decoration: none;
  white-space: nowrap;
  mix-blend-mode: difference;
  transition: color 0.3s ease;
}

.video-brand:hover{ color: var(--hover); }

/* Desktop nav */
.video-nav{
  display: flex;
  gap: 28px;
  text-transform: uppercase;
}

.video-nav a{
  font-family: var(--font-ui);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  transition: color 0.3s ease;
  white-space: nowrap;
}

.video-nav a:hover{ color: var(--hover); }
.video-nav a.active{ color: var(--hover); }

/* Burger hidden on desktop */
.burger{ display: none; }

/* Burger shown on mobile */
@media (max-width: 768px){
  .video-nav{ display: none; }
  .burger{
    display: grid;
    place-items: center;
    width: 20px;
    height: 5px;
    border: 0;
    background: transparent;
    cursor: pointer;
    padding: 0;
  }
  .burger span{
    display: block;
    width: 26px;
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
    transition: transform .25s ease, opacity .2s ease;
  }
  .burger span:nth-child(1){ transform: translateY(-7px); }
  .burger span:nth-child(3){ transform: translateY(7px); }
  .burger.is-open span:nth-child(1){ transform: rotate(45deg); }
  .burger.is-open span:nth-child(2){ opacity: 0; }
  .burger.is-open span:nth-child(3){ transform: rotate(-45deg); }
}

/* Right-side drawer */
.drawer-scrim{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
  z-index: 60;
}

.drawer{
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: 100%;
  padding: 92px 22px 22px;
  display: flex;
  flex-direction: column;
  gap: 36px;
  background: rgba(8,8,8,0.92);
  backdrop-filter: blur(12px);
  transform: translateX(100%);
  opacity: 0;
  pointer-events: none;
  transition: transform .28s ease, opacity .28s ease;
  z-index: 70;
}

.drawer-close{
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: var(--accent);
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
  transition: color 0.25s ease;
}

.drawer-close:hover{
  color: var(--hover);
}

.drawer a {
  font-family: var(--font-ui);
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: .06em;
  transition: color .25s ease, font-weight .25s ease;
  width: 100%;             /* ensures full clickable width */
  text-align: right;       /* extra safety */
}

.drawer a:hover{ color: var(--hover); font-weight: 600; }
.drawer a.active{ color: var(--hover); }

.drawer.is-open{ transform: translateX(0); opacity: 1; pointer-events: auto; }
.drawer-scrim.is-open{ opacity: 1; pointer-events: auto; }

/* =========================
   VIDEO PAGE CONTENT
   ========================= */
.video-wrap{
  width: 100%;
  max-width: 1500px;
  margin: 18px auto 90px;
  padding: 0 12px;

  display: flex;
  flex-direction: column;
  gap: 72px;
}


.section-title {
  font-family: var(--font-brand);
  font-size: clamp(1.2rem, 2vw, 2rem);
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  text-align: left;
  margin: 0px;
}

.video-grid {
  gap: 1px; /* Sometimes giving it an intentional 1px black gap is cleaner than 0 */
  background: #000;
}

/* Grid (3 columns like your photo grid) */
.video-grid.short{
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0;
}

.video-grid.long {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
  
  /* 1. Centers the grid container itself within the page (if it has a max-width) */
  margin: 0 auto; 

  /* 2. Centers the grid columns inside the container (useful if you ever change 1fr to a fixed size) */
  justify-content: center; 
}

.video-grid.custom {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0;
  
  /* 1. Centers the grid container itself within the page (if it has a max-width) */
  margin: 0 auto; 

  /* 2. Centers the grid columns inside the container (useful if you ever change 1fr to a fixed size) */
  justify-content: center; 
}
/* Force the cards to mimic a 3-column size */
.video-grid.custom .video-card {
  aspect-ratio: 16 / 9;
}


/* Base video card */
.video-card{
  width: 100%;
  overflow: hidden;
  cursor: pointer;
  border: 0;
  padding: 0;
  background: transparent;
  position: relative;
  
}

/* SHORT FORM → 9:16 */
.video-grid.short .video-card{
  aspect-ratio: 9 / 16;
}

/* LONG FORM → 16:9 */
.video-grid.long .video-card{
  aspect-ratio: 16 / 9;
}

/* custom */
.video-grid.custom .video-card {
  aspect-ratio: 16 / 9;
}



/* Video inside */
.video-card video{
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease, filter 0.3s ease-in-out;
  display: block;
}

.video-card:hover video{
  transform: scale(1.03);
  filter: brightness(1.15);
}
/* 2. Show on hover */
.video-card:hover .video-info {
  opacity: 1;
  transform: translateY(0);
}

.video-info {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 20px;
  text-align: left;
  background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
  pointer-events: none;
  z-index: 2;

  /* Hide by default */
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.v-title {
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 1.1rem;
  color: #fff;
  margin: 0 0 4px 0;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.v-details {
  font-family: var(--font-ui);
  font-weight: 400;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.8);
  margin: 0;
  line-height: 1.4;
}

/* Tablets (under 1024px) */
@media (max-width: 1024px) {
  .video-grid.short { grid-template-columns: repeat(6, 1fr); } /* 6 goes to 3 */
  .video-grid.long { grid-template-columns: repeat(2, 1fr); }  /* 4 goes to 2 */
  .video-grid.custom { grid-template-columns: repeat(2, 1fr); } /* 3 goes to 2 */
}

/* Phones (under 600px) */
@media (max-width: 600px) {
  .video-grid.short { grid-template-columns: repeat(3, 1fr); } /* 3 goes to 2 */
  .video-grid.long { grid-template-columns: repeat(1, 1fr); }  /* 2 goes to 1 */
  .video-grid.custom { grid-template-columns: repeat(1, 1fr); } /* 2 goes to 1 */
}

/* Scroll up button */
.scroll-up-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: var(--accent);
  color: #000;
  display: grid;
  place-items: center;
  opacity: 0;
  cursor: pointer;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease, background 0.3s ease;
  z-index: 80;
}
.scroll-up-btn.visible { opacity: 1; pointer-events: all; transform: translateY(0); }
.scroll-up-btn:hover { background: var(--hover); }

/* Video lightbox */
.video-lightbox{
  position: fixed;
  inset: 0;
  background: rgba(8,8,8,0.96);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.video-lightbox.active{
  opacity: 1;
  pointer-events: auto;
}

/* Base Frame */
.lightbox-frame {
  width: 80vw; 
  max-height: 88vh;
  position: relative;
  overflow: hidden; 
  background: #000;
  display: flex;
  margin: 0 auto;
}

/* 16:9 (Horizontal) */
.lightbox-frame.is-horizontal {
  aspect-ratio: 16 / 9;
  /* Prevents it from getting wider than 16:9 if it hits the max height */
  max-width: calc(88vh * 16 / 9); 
}

/* 9:16 (Vertical) */
.lightbox-frame.is-vertical {
  aspect-ratio: 9 / 16;
  max-width: calc(88vh * 9 / 16);
}

/* 4:3 (Custom) */
.lightbox-frame.is-custom {
  aspect-ratio: 1 / 1;
  max-width: calc(88vh * 1 / 1);
}

/* Video Player */
#lightbox-video-player {
  width: 100%;
  height: 100%;
  /* Change this to contain! It ensures the video never gets cropped or stretched */
  object-fit: contain; 
  background: transparent;
  display: block;
}


/* ✅ 2. Fixed Close Button */
.video-close {
  position: absolute;
  top: 18px;
  right: 22px;
  background: none;
  border: none;
  color: var(--text);
  font-size: 3rem;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s ease;
  z-index: 210;
  text-shadow: 0px 0px 15px rgb(0, 0, 0);
}

.video-close:hover { 
  color: var(--accent); 
}

/* ✅ 3. Custom Controls pinned to bottom of the frame */
.video-controls {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(transparent, rgba(0,0,0,0.85));
  padding: 35px 18px 15px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  z-index: 40;
  transition: opacity 0.5s ease;
}

/* Hide UI when mouse is inactive (triggered by your JS) */
.lightbox-frame.is-idle .video-controls,
.lightbox-frame.is-idle .video-close {
  opacity: 0;
  pointer-events: none;
}

/* ✅ 4. Progress Bar Styling */
.progress-bar {
  position: relative;
  width: 100%;
  height: 6px;
  background: rgba(255,255,255,0.25);
  border-radius: 3px;
  cursor: pointer;
  touch-action: none;
}
.progress-buffer, .progress-fill {
  position: absolute;
  top: 0; 
  left: 0; 
  height: 100%;
  border-radius: 3px;
  pointer-events: none;
}
.progress-buffer { background: rgba(255,255,255,0.3); }
.progress-fill { background: var(--accent, #fff); }
.progress-thumb {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 14px;
  height: 14px;
  background: var(--accent, #fff);
  border-radius: 50%;
  pointer-events: none;
}

/* ✅ 5. Play, Mute, Volume Layout */
.controls-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.controls-left, .controls-right {
  display: flex;
  align-items: center;
  gap: 16px;
}
.control-btn {
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
  padding: 0;
  display: grid;
  place-items: center;
  transition: color 0.2s;
}
.control-btn:hover { color: var(--accent, #ccc); }
.time-display { 
  color: #fff; 
  font-family: var(--font-ui, sans-serif); 
  font-size: 0.8rem; 
  letter-spacing: 0.04em;
}

/* ✅ 6. Volume Slider Constraints */
.volume-container {
  position: relative;
  width: 70px;
  height: 12px; /* Increased height to match thumb for better alignment */
  display: flex;
  align-items: center;
}

/* The Background Track (Darker gray) */
.volume-track {
  position: absolute;
  width: 100%;
  height: 4px; /* Thickness of the line */
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  z-index: 1;
}

/* The Red Fill (The progress line) */
.volume-fill {
  position: absolute;
  height: 4px;
  background: #ff0000; /* Your red color */
  border-radius: 2px;
  z-index: 2;
  width: 100%; /* JS updates this, but 100% is default */
}

/* 1. The Slider Input (Invisible Hitbox) */
.volume-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 100%;
  background: transparent;
  cursor: pointer;
  outline: none;
  margin: 0;
  position: absolute; /* Changed to absolute to overlay the track/fill */
  top: 0;
  left: 0;
  z-index: 10;
}

/* 2. The Circle (Chrome, Safari, Edge) */
.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  background: #ffffff;
  border-radius: 50%;
  cursor: pointer;
  border: none;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.4);
  transition: transform 0.1s ease;
}

/* 3. The Circle (Firefox) */
.volume-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  background: #ffffff;
  border-radius: 50%;
  cursor: pointer;
  border: none;
  box-shadow: 0 0 5px rgba(0, 0, 0, 0.4);
}

/* 4. Hover effect */
.volume-slider:hover::-webkit-slider-thumb {
  transform: scale(1.2);
}



