/* ============================================
   HAIR BY KARA JILLIAN — Custom Styles
   ============================================ */

/* Base */
html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Navigation */
.nav-text {
    transition: color 0.3s ease;
}

#navbar.scrolled .nav-text {
    color: #380808;
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #ff5f77;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Mobile Menu */
.mobile-link {
    position: relative;
}

/* Hero Geometric Shapes */
.hero-shape {
    position: absolute;
    opacity: 0.15;
    animation: float 8s ease-in-out infinite;
}

.shape-circle-1 {
    width: 400px;
    height: 400px;
    background: #ff5f77;
    border-radius: 50%;
    top: -100px;
    right: 10%;
    animation-delay: 0s;
}

.shape-circle-2 {
    width: 200px;
    height: 200px;
    background: #ff9faa;
    border-radius: 50%;
    bottom: 15%;
    right: 5%;
    animation-delay: -2s;
}

.shape-circle-3 {
    width: 120px;
    height: 120px;
    background: #fce4e4;
    border-radius: 50%;
    top: 40%;
    left: 5%;
    animation-delay: -4s;
}

.shape-rect-1 {
    width: 150px;
    height: 150px;
    background: #a82020;
    top: 20%;
    right: 35%;
    transform: rotate(45deg);
    animation-delay: -1s;
}

.shape-rect-2 {
    width: 80px;
    height: 80px;
    background: #ff5f77;
    bottom: 30%;
    left: 15%;
    transform: rotate(20deg);
    animation-delay: -3s;
}

.shape-triangle {
    width: 0;
    height: 0;
    border-left: 60px solid transparent;
    border-right: 60px solid transparent;
    border-bottom: 104px solid #ff9faa;
    top: 60%;
    right: 25%;
    animation-delay: -5s;
    opacity: 0.1;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    33% { transform: translateY(-20px) rotate(5deg); }
    66% { transform: translateY(10px) rotate(-3deg); }
}

.shape-rect-1 {
    animation-name: floatRotate;
}

@keyframes floatRotate {
    0%, 100% { transform: translateY(0) rotate(45deg); }
    50% { transform: translateY(-25px) rotate(50deg); }
}

.shape-rect-2 {
    animation-name: floatRotate2;
}

@keyframes floatRotate2 {
    0%, 100% { transform: translateY(0) rotate(20deg); }
    50% { transform: translateY(-15px) rotate(15deg); }
}

/* Marquee */
.marquee-track {
    animation: marquee 30s linear infinite;
}

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

/* Service Cards */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, transparent 60%, rgba(255, 95, 119, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.5s ease;
    border-radius: inherit;
}

.service-card:hover::before {
    opacity: 1;
}

/* Gallery */
.gallery-item {
    cursor: pointer;
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(56, 8, 8, 0.3) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.4s ease;
    border-radius: inherit;
}

.gallery-item:hover::after {
    opacity: 1;
}

/* Testimonials */
.testimonial-card {
    position: relative;
}

.testimonial-card:hover {
    transform: translateY(-4px);
}

/* Scroll Reveal */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.hidden-reveal {
    opacity: 0;
    transform: translateY(40px);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }

/* Back to Top */
#backToTop.visible {
    opacity: 1;
    translate: 0;
    pointer-events: all;
}

/* Prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .reveal.hidden-reveal {
        opacity: 1 !important;
        transform: none !important;
    }
    
    .marquee-track {
        animation: none;
    }
    
    .hero-shape {
        animation: none;
    }
}

/* Mobile responsive */
@media (max-width: 768px) {
    .shape-circle-1 {
        width: 200px;
        height: 200px;
    }
    
    .shape-circle-2 {
        width: 100px;
        height: 100px;
    }
    
    .shape-circle-3, .shape-rect-1, .shape-rect-2, .shape-triangle {
        display: none;
    }
}
