/* Custom styles for Carolina Towing & Recovery */

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

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

.card-hover:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 60px -20px rgba(10, 22, 40, 0.15);
}

/* Navigation states */
.nav-link {
    position: relative;
}

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

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

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 40px rgba(10, 22, 40, 0.08);
}

.nav-scrolled .nav-logo-text {
    color: #0a1628 !important;
}

.nav-scrolled .nav-link {
    color: #0f2240 !important;
}

.nav-scrolled .menu-line {
    background: #0a1628 !important;
}

/* Mobile menu animation */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: auto !important;
}

.menu-open .menu-line:first-child {
    transform: rotate(45deg) translate(4px, 4px);
}

.menu-open .menu-line:nth-child(2) {
    opacity: 0;
}

.menu-open .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(4px, -4px);
}

/* Reveal animations (progressive enhancement) */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Image lazy loading shimmer */
img {
    background: linear-gradient(135deg, #f0f0f0 0%, #e0e0e0 100%);
}

/* Selection color */
::selection {
    background: #5fe8be;
    color: #0a1628;
}

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

::-webkit-scrollbar-track {
    background: #0a1628;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #1a3d6e;
}

/* Form styles */
.form-input {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 16px;
    font-family: inherit;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: #ffffff;
    color: #0a1628;
}

.form-input:focus {
    outline: none;
    border-color: #0fb882;
    box-shadow: 0 0 0 4px rgba(15, 184, 130, 0.1);
}

.form-input::placeholder {
    color: #9ca3af;
}

/* Success message */
.success-message {
    display: none;
    padding: 16px 20px;
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border: 1px solid #5fe8be;
    border-radius: 12px;
    color: #065f46;
    font-weight: 500;
    margin-top: 16px;
    animation: slideIn 0.4s ease;
}

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

/* Button ripple effect */
.btn-ripple {
    position: relative;
    overflow: hidden;
}

.btn-ripple::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-ripple:active::after {
    width: 300px;
    height: 300px;
}
