/* Custom styles for V Smile Design */

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

/* Navbar scroll state */
.nav {
    background: transparent;
    transition: background 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
}

.nav.scrolled {
    background: rgba(254, 252, 248, 0.97);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.nav.scrolled .nav-logo-text {
    color: #0f172a;
}

.nav.scrolled .nav-link {
    color: #475569;
}

.nav.scrolled .nav-link:hover {
    color: #d44f2e;
}

/* Nav link hover underline */
.nav-link {
    position: relative;
}

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

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

/* Hero parallax-like subtle effect */
.hero {
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(ellipse at 20% 80%, rgba(212, 79, 46, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(228, 163, 74, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

/* Service card hover lift */
.service-card {
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.4s ease;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Process step hover */
.process-step:hover .w-20 {
    transform: scale(1.05);
    transition: transform 0.3s ease;
}

/* Mobile menu animation */
.mobile-menu {
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile menu button active state */
.mobile-menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active .menu-line:nth-child(3) {
    width: 1.5rem;
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile links */
.mobile-link {
    position: relative;
    display: block;
}

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

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

/* Scroll reveal animations (below the fold only) */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

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

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

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

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

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

/* Selection color */
::selection {
    background: rgba(212, 79, 46, 0.2);
    color: #0f172a;
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(212, 79, 46, 0.1);
}

/* Image loading placeholder */
img {
    background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

img.loaded {
    animation: none;
    background: none;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.25rem;
        line-height: 1.15;
    }
    
    .service-card {
        padding: 1.5rem;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .process-connector {
        display: none !important;
    }
}
