/* Base reset and CSS variable instantiation */
:root {
  --color-primary: #B22222; /* Fallback, overridden by JS */
  --color-secondary: #1A1A1A; /* Fallback, overridden by JS */
}

/* Custom Scrollbar for a premium feel */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Logo Text Styling */
.logo-text {
  font-family: 'Montserrat', 'Inter', sans-serif;
  letter-spacing: 0.05em;
  color: #133757; /* Matching the primary color */
}

/* Local SVG Masking */
.svg-icon {
  background-color: currentColor;
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  display: inline-block;
}

/* Hero Section Split Overlay */
.hero-split-overlay {
  background: linear-gradient(135deg, rgba(26,26,26,0.95) 0%, rgba(26,26,26,0.8) 50%, rgba(26,26,26,0.4) 100%);
}

@media (min-width: 768px) {
  .hero-clip-path {
    clip-path: polygon(0 0, 100% 0, 85% 100%, 0% 100%);
  }
}

/* Background video */
.bg-video-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: -1;
}

.bg-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.5s ease-in-out;
}

.bg-video.is-loaded {
  opacity: 1;
}

/* Projects Masonry/Bento Grid */
.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, 1fr);
  }
  
  .projects-item-large {
    grid-column: 1 / 2;
    grid-row: 1 / 3;
  }
  
  .projects-item-top {
    grid-column: 2 / 3;
    grid-row: 1 / 2;
  }
  
  .projects-item-bottom-left {
    grid-column: 2 / 3;
    grid-row: 2 / 3;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }
}

/* Animations */
.fade-in-up {
  animation: fadeInUp 0.8s ease-out forwards;
  opacity: 0;
  transform: translateY(20px);
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
}

/* Badge Styling */
.section-badge {
  display: inline-block;
  padding: 0.375rem 1rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid #e2e8f0;
  background-color: transparent;
  margin-bottom: 1.5rem;
}

.dark-mode-badge {
  border-color: rgba(255,255,255,0.2);
  background-color: rgba(255,255,255,0.1);
  color: white;
}
