/* ========================================
   Falcons Nest Gibson City - Custom Styles
   ======================================== */

/* Base & Reset */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection Color */
::selection {
    background-color: #166534;
    color: #fefdf8;
}

/* ========================================
   Navbar Scroll State
   ======================================== */
.nav-scrolled {
    background: rgba(250, 248, 243, 0.95) !important;
    backdrop-filter: blur(20px) !important;
    box-shadow: 0 1px 0 rgba(20, 83, 45, 0.08) !important;
}

.nav-scrolled #nav-logo-ring,
.nav-scrolled #nav-logo-star {
    color: #14532d !important;
}

.nav-scrolled #nav-logo-text {
    color: #14532d !important;
}

.nav-scrolled #nav-logo-sub {
    color: #16a34a !important;
}

/* ========================================
   Floating Card Animations
   ======================================== */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -2s;
}

.floating-card:nth-child(3) {
    animation-delay: -4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-12px);
    }
}

/* ========================================
   Scroll Reveal Animations
   ======================================== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* ========================================
   Product Card Image Hover
   ======================================== */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* ========================================
   Button Focus States
   ======================================== */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #16a34a;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ========================================
   Back to Top Button
   ======================================== */
#back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

#back-to-top:not(.visible) {
    opacity: 0;
    pointer-events: none;
    transform: translateY(10px);
}

#back-to-top.visible {
    transform: translateY(0);
}

/* ========================================
   Mobile Menu Animation
   ======================================== */
#mobile-menu {
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 0.3s ease;
}

#mobile-menu.hidden {
    max-height: 0 !important;
    opacity: 0;
    overflow: hidden;
}

#mobile-menu:not(.hidden) {
    max-height: 500px;
    opacity: 1;
}

/* ========================================
   Decorative Line Animations
   ======================================== */
.divider-line {
    transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ========================================
   Image Loading Placeholder
   ======================================== */
img {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
}

/* ========================================
   Reduced Motion
   ======================================== */
@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;
    }
    
    .floating-card {
        animation: none;
    }
}

/* ========================================
   Smooth Scroll Offset for Fixed Nav
   ======================================== */
section[id] {
    scroll-margin-top: 80px;
}

/* ========================================
   Print Styles
   ======================================== */
@media print {
    nav, #back-to-top, .floating-card {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}
