/* Custom styles and overrides */

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

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

::-webkit-scrollbar-track {
    background: #1E1E1E;
}

::-webkit-scrollbar-thumb {
    background: #3D3D3D;
    border-radius: 5px;
}

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

/* Reveal animation base state */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

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

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .animate-float,
    .animate-float-delayed {
        animation: none;
    }
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #FF6B6B;
    outline-offset: 2px;
}

/* Navbar scroll effect */
.navbar-scrolled {
    background-color: rgba(18, 18, 18, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Geometric shape animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

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

/* Card hover effects */
.group:hover .group-hover\\:bg-coral-500\\/20 {
    background-color: rgba(255, 107, 107, 0.2);
}

.group:hover .group-hover\\:rotate-12 {
    transform: rotate(12deg);
}

/* Gradient text utility */
.text-transparent {
    -webkit-background-clip: text;
    background-clip: text;
}

/* Ensure images don't cause layout shift */
img {
    max-width: 100%;
    height: auto;
}

/* Mobile menu animation */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

#mobile-menu.open {
    max-height: 400px;
}

/* Form focus states */
input:focus,
textarea:focus {
    border-color: #FF6B6B !important;
    box-shadow: 0 0 0 1px #FF6B6B !important;
}

/* Button hover effects */
button:hover {
    transform: translateY(-2px);
}

button:active {
    transform: translateY(0);
}

/* Link hover underline animation */
a.hover-underline {
    position: relative;
}

a.hover-underline::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: #FF6B6B;
    transition: width 0.3s ease;
}

a.hover-underline:hover::after {
    width: 100%;
}

/* Accessibility: Skip to content link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: #FF6B6B;
    color: white;
    padding: 8px;
    text-decoration: none;
    z-index: 100;
}

.skip-link:focus {
    top: 0;
}

/* Print styles */
@media print {
    .animate-float,
    .animate-float-delayed {
        animation: none;
    }
    
    nav,
    .reveal {
        display: block !important;
        opacity: 1 !important;
    }
}
