﻿
@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
    body {
        cursor: none; /* Hide default cursor for desktop, JS will enable standard cursor for mobile */
        overscroll-behavior-y: none;
    }
    
    @media (max-width: 768px) {
        body {
            cursor: auto;
        }
    }
}

@layer utilities {
    .clip-reveal {
        clip-path: inset(100% 0 0 0);
        transition: clip-path 1.2s cubic-bezier(0.77, 0, 0.175, 1);
    }
    .clip-reveal.active {
        clip-path: inset(0 0 0 0);
    }
    
    .clip-reveal-right {
        clip-path: inset(0 100% 0 0);
        transition: clip-path 1.2s cubic-bezier(0.77, 0, 0.175, 1);
    }
    .clip-reveal-right.active {
        clip-path: inset(0 0 0 0);
    }
    
    .text-reveal-wrapper {
        overflow: hidden;
        display: inline-block;
        vertical-align: top;
    }
    
    .text-reveal {
        display: inline-block;
        transform: translateY(110%);
        transition: transform 1s cubic-bezier(0.77, 0, 0.175, 1);
    }
    
    .text-reveal.active {
        transform: translateY(0);
    }

    .fade-up {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 1s ease-out, transform 1s ease-out;
    }
    
    .fade-up.active {
        opacity: 1;
        transform: translateY(0);
    }
    
    .image-parallax {
        transition: transform 0.1s linear;
    }
}

/* Custom Cursor */
#custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 12px;
    height: 12px;
    background-color: #B08D5B;
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    transform: translate(-50%, -50%);
    transition: width 0.3s ease, height 0.3s ease, background-color 0.3s ease;
    mix-blend-mode: difference;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
    color: #1A1A1A;
    opacity: 0;
    letter-spacing: 0.1em;
}

#custom-cursor.active {
    opacity: 1;
}

#custom-cursor.hover-project {
    width: 80px;
    height: 80px;
    background-color: #FBF9F6;
    mix-blend-mode: normal;
}

#custom-cursor.hover-link {
    width: 40px;
    height: 40px;
    background-color: rgba(176, 141, 91, 0.5);
    mix-blend-mode: normal;
}

@media (max-width: 768px) {
    #custom-cursor {
        display: none !important;
    }
}

/* Preloader */
#preloader {
    position: fixed;
    inset: 0;
    background-color: #1A1A1A;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #FBF9F6;
    transition: opacity 0.8s ease-in-out, transform 0.8s ease-in-out;
}

#preloader.hide {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10%);
}

.loading-line-container {
    width: 200px;
    height: 1px;
    background: rgba(255,255,255,0.1);
    margin-top: 30px;
    overflow: hidden;
}

.loading-line {
    width: 100%;
    height: 100%;
    background: #B08D5B;
    transform: translateX(-100%);
    animation: loading 1.5s cubic-bezier(0.77, 0, 0.175, 1) forwards;
}

@keyframes loading {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(0); }
}

/* Scroll Progress */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background-color: #B08D5B;
    width: 0%;
    z-index: 9998;
    transition: width 0.1s;
}

/* Horizontal Scroll Container */
.horizontal-scroll-wrapper {
    overflow: hidden;
}

@media (max-width: 768px) {
    .mobile-carousel {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 1rem;
        padding-bottom: 2rem;
    }
    .mobile-carousel-item {
        scroll-snap-align: center;
        flex: 0 0 85vw;
    }
}

/* Process Timeline */
.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    background: rgba(0,0,0,0.1);
    transform: translateX(-50%);
}

.timeline-progress {
    position: absolute;
    left: 50%;
    top: 0;
    width: 1px;
    background: #B08D5B;
    transform: translateX(-50%);
    transition: height 0.2s linear;
}

/* Services Hover Line */
.service-row {
    position: relative;
}
.service-row::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: #000;
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.6s cubic-bezier(0.77, 0, 0.175, 1);
}
.service-row:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}
.service-img-preview {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.4s ease, transform 0.4s ease;
    pointer-events: none;
}
.service-row:hover .service-img-preview {
    opacity: 1;
    transform: scale(1);
}

/* Magnetic Button */
.magnetic-btn {
    display: inline-block;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Hide scrollbar for clean look */
::-webkit-scrollbar {
    width: 0px;
    background: transparent;
}

