/* Custom styles for Bahia and Bahia */

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

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

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

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

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

/* Gold shimmer animation */
@keyframes shimmer {
    0% {
        background-position: -200% center;
    }
    100% {
        background-position: 200% center;
    }
}

.gold-shimmer {
    background: linear-gradient(90deg, #B8860B 0%, #D4AF37 25%, #F3E5AB 50%, #D4AF37 75%, #B8860B 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 4s linear infinite;
}

/* Pulse animation for CTA */
@keyframes pulse-gold {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4);
    }
    50% {
        box-shadow: 0 0 0 15px rgba(212, 175, 55, 0);
    }
}

.pulse-gold {
    animation: pulse-gold 2s infinite;
}

/* Subtle float animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.float-animation {
    animation: float 6s ease-in-out infinite;
}

/* Mobile menu transitions */
.mobile-menu {
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
}

.mobile-menu.hidden {
    transform: translateX(100%);
    opacity: 0;
    pointer-events: none;
}

.mobile-menu.visible {
    transform: translateX(0);
    opacity: 1;
    pointer-events: all;
}

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

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

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

/* Service card hover effect */
.group:hover .group-hover\:bg-bahia-burgundy\/30 {
    background-color: rgba(128, 0, 32, 0.3);
}

/* Form focus states */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: rgba(212, 175, 55, 0.5);
    box-shadow: 0 0 0 1px rgba(212, 175, 55, 0.5);
}

/* Button hover effects */
button:hover,
a:hover {
    transition: all 0.3s ease;
}

/* Image hover zoom effect */
img {
    transition: transform 0.5s ease;
}

/* Reduced motion preference */
@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;
    }
}

/* Print styles */
@media print {
    .no-print {
        display: none;
    }
    
    body {
        background: white;
        color: black;
    }
    
    .gold-shimmer {
        -webkit-text-fill-color: #B8860B;
        background: none;
        animation: none;
    }
}

/* High contrast mode support */
@media (forced-colors: active) {
    .bg-bahia-burgundy {
        background-color: ButtonText;
    }
    
    .text-bahia-gold {
        color: ButtonText;
    }
}

/* Focus visible for keyboard navigation */
:focus-visible {
    outline: 2px solid #D4AF37;
    outline-offset: 2px;
}

/* Loading states */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Success state */
.success {
    animation: fadeIn 0.5s ease;
}

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

/* Error state */
.error {
    border-color: #EF4444 !important;
}

.error-message {
    color: #EF4444;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .font-serif {
        font-size: 1.875rem;
    }
    
    .gold-shimmer {
        background-size: 300% auto;
    }
}

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

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

/* Image optimization */
img {
    max-width: 100%;
    height: auto;
}

/* Smooth image loading */
img {
    transition: opacity 0.3s ease;
}

img.loaded {
    opacity: 1;
}

img:not(.loaded) {
    opacity: 0;
}
