/* Custom styles for Sweet Confections by K & M */

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

/* Base scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0d0a07;
}
::-webkit-scrollbar-thumb {
    background: #3d3528;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #5a4d35;
}

/* Selection color */
::selection {
    background: rgba(212, 174, 85, 0.3);
    color: #fdfbf7;
}

/* Navbar transition states */
.nav-scrolled {
    background: rgba(7, 5, 4, 0.92) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(212, 174, 85, 0.08);
    box-shadow: 0 4px 40px rgba(0, 0, 0, 0.4);
}

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

.menu-open .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
.menu-open .menu-line:nth-child(2) {
    opacity: 0;
}
.menu-open .menu-line:nth-child(3) {
    width: 100%;
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile nav link hover */
.mobile-nav-link {
    position: relative;
}
.mobile-nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #d4ae55, transparent);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}
.mobile-nav-link:hover::after {
    width: 80%;
}

/* Scroll reveal base - content is VISIBLE by default (progressive enhancement) */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Only apply hidden state when JS is active and animation preference allows */
@media (prefers-reduced-motion: no-preference) {
    .reveal-up.reveal-animate {
        opacity: 0;
        transform: translateY(40px);
    }
    .reveal-left.reveal-animate {
        opacity: 0;
        transform: translateX(-40px);
    }
    .reveal-right.reveal-animate {
        opacity: 0;
        transform: translateX(40px);
    }
}

/* Active nav link highlight */
.nav-link.active {
    color: #d4ae55 !important;
}

/* Gold shimmer effect on hover for buttons */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #d4ae55;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Image loading placeholder */
img {
    background: linear-gradient(135deg, #1a1410 0%, #0d0a07 100%);
}

/* Subtle pattern overlay for sections */
.section-pattern {
    background-image: radial-gradient(ellipse at 20% 50%, rgba(229, 77, 47, 0.03) 0%, transparent 50%),
                      radial-gradient(ellipse at 80% 50%, rgba(212, 174, 85, 0.03) 0%, transparent 50%);
}

/* Decorative gold line animation */
@keyframes goldPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.7; }
}

.gold-line-pulse {
    animation: goldPulse 4s ease-in-out infinite;
}

/* Map filter for dark theme - applied via iframe style, but keeping as fallback */
.dark-map {
    filter: invert(90%) hue-rotate(180deg) brightness(0.9) contrast(1.1);
}
