/* Custom styles for Resilience Health Care */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #121417;
}

::-webkit-scrollbar-thumb {
    background: #43474f;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #636774;
}

/* Selection color */
::selection {
    background: rgba(232, 106, 91, 0.3);
    color: #f6f6f7;
}

/* Service card hover glow */
.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    padding: 1px;
    background: linear-gradient(135deg, transparent, rgba(232, 106, 91, 0.1), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.service-card {
    position: relative;
    overflow: hidden;
}

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

/* Testimonial card subtle pattern */
.testimonial-card {
    position: relative;
    overflow: hidden;
}

.testimonial-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(232, 106, 91, 0.3), transparent);
    opacity: 0;
    transition: opacity 0.5s ease;
}

.testimonial-card:hover::after {
    opacity: 1;
}

/* Navbar scroll state */
.navbar-scrolled {
    background: rgba(18, 20, 23, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(67, 71, 79, 0.5);
}

/* Mobile menu animation */
.menu-line {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#menuBtn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: translateX(-10px);
}

#menuBtn.active .menu-line:nth-child(3) {
    width: 20px;
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Scroll reveal animations */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    
    .scroll-reveal {
        opacity: 1;
        transform: none;
    }
    
    .service-card,
    .testimonial-card {
        transition: none;
    }
    
    .service-card:hover,
    .testimonial-card:hover {
        transform: none;
    }
}

/* Focus visible for accessibility */
:focus-visible {
    outline: 2px solid #e86a5b;
    outline-offset: 2px;
}

/* Button press effect */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* Image loading placeholder */
img {
    background: linear-gradient(135deg, #25282d 0%, #35383e 100%);
}

/* Custom select arrow */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237e818c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* Hero decorative line animation */
@keyframes scrollIndicator {
    0%, 100% {
        opacity: 0.3;
        transform: scaleY(0.5);
        transform-origin: top;
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* Pulse dot animation */
@keyframes softPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

.animate-pulse {
    animation: softPulse 2s ease-in-out infinite;
}
