:root {
    --primary: #FACC15;
    --background: #09090b;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: #fafafa;
    overflow-x: hidden;
}
/*ANIMATION BG*/
#liquidWaveCanvas {
    /* Ensures no gap at the bottom of the section */
    display: block; 
    filter: drop-shadow(0px -10px 15px rgba(250, 204, 21, 0.3));
}
/*RING CANVAS*/
#ringCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Forced to the very front */
    z-index: 0!important; 
    /* Essential: Allows clicking gallery buttons through the rings */
    pointer-events: none !important; 
    /* Blending makes it look like it's behind even though it's on top */
    mix-blend-mode: screen;
    filter: blur(0.4px) contrast(1.2);
    opacity: 1;
    
}
/*ANIMATION BG END*/
.font-display {
    font-family: 'Space Grotesk', sans-serif;
}

.parallax-bg {
    transition: transform 0.1s ease-out;
    will-change: transform;
}

.service-card video {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.service-card:hover video {
    opacity: 0.8;
}

.service-card:hover img {
    opacity: 0;
    transform: scale(1.1);
}

.service-card img {
    transition: all 0.7s ease;
}

/* Modern Transition Effects */
.reveal {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
    filter: blur(10px);
    transition: all 1.2s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform, opacity, filter;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
}

/* Staggered delays for children */
.reveal-stagger>* {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-stagger.active>* {
    opacity: 1;
    transform: translateY(0);
}

.reveal-stagger.active>*:nth-child(1) {
    transition-delay: 0.1s;
}

.reveal-stagger.active>*:nth-child(2) {
    transition-delay: 0.2s;
}

.reveal-stagger.active>*:nth-child(3) {
    transition-delay: 0.3s;
}

.reveal-stagger.active>*:nth-child(4) {
    transition-delay: 0.4s;
}

/* Left/Right Entrances */
.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 1s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}

/* Portfolio Specific Styling */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 2rem;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 2rem;
    transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    background: #18181b;
}

.portfolio-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.5);
}

.portfolio-item img {
    transition: transform 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.4) 50%, transparent 100%);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

/* Floating Badge */
.badge {
    position: absolute;
    top: 2rem;
    right: 2rem;
    padding: 0.5rem 1.25rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    z-index: 20;
    transition: all 0.4s ease;
}

.portfolio-item:hover .badge {
    background: var(--primary);
    color: #000;
    border-color: var(--primary);
}

/* Graphical Stats Styling */
.stat-ring {
    position: relative;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-ring svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.stat-ring circle {
    fill: none;
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 314;
    stroke-dashoffset: 314;
    transition: stroke-dashoffset 2s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.active .stat-ring circle {
    stroke-dashoffset: var(--offset);
}

/* Modal / Floating Contact */
#contact-modal {
    display: none;
    opacity: 0;
    transition: opacity 0.4s ease;
}

#contact-modal.active {
    display: flex;
    opacity: 1;
}

.modal-content {
    transform: scale(0.9) translateY(20px);
    transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

#contact-modal.active .modal-content {
    transform: scale(1) translateY(0);
}
/*Spline Styling*/
/* Mobile Adjustments */
@media (max-width: 767px) {
  .spline-desktop {
    display: none;
  }

  .spline-mobile {
    display: block;
    /* Move the scene up */
    transform:translateY(-15%); 
    scale:1;
  }

  .spline-bottom-bar {
    /* Adjust height to cover more space if the scene moved up */
    height:10%!important; 
    /* Or move it up slightly to meet the Spline scene */
    bottom: 2%; 
  }
}

/* Desktop Logic */
@media (min-width: 768px) {
  .spline-desktop {
    display: block;
  }
  .spline-mobile {
    display: none;
  }
  .spline-bottom-bar {
    height: 8%;
    bottom: 0;
  }
}

/* 3D Carousel Styling */

.carousel-container {
    perspective: 1500px;
    padding-bottom: 100px;width: 100%;
  max-width: 800px;  /* Limit the total width */
  margin: 0 auto;
  overflow: hidden;  /* Prevents items from poking out the sides */
  perspective: 1000px; /* Adjust this to change the "intensity" of the 3D */
}

.carousel-track {
    display: flex;
    align-items: center;
    justify-content: center;
    transform-style: preserve-3d;
    height: 400px;
    position: relative;
}

.carousel-item {
    position: absolute;
    width: 300px;
    height: 400px;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
    cursor: pointer;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    background: #18181b;
    border: 1px solid rgba(255, 255, 255, 0.1);
    user-select: none;
  -webkit-user-drag: none;
  -webkit-tap-highlight-color: transparent;
}

.carousel-item video {
    display: none;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-item.active video {
    display: block;
}

.carousel-item.active img {
    display: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #09090b;
}

::-webkit-scrollbar-thumb {
    background: #27272a;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #FACC15;
}

.hero-title span {
    display: inline-block;
    opacity: 0;
    transform: translateY(20px);
    animation: titleIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes titleIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}