/* ===== Custom Styles for Landry Ranch Vacation Home ===== */

/* Base & Typography */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Lato', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, .font-serif {
    font-family: 'Playfair Display', Georgia, serif;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #1a1d24;
}
::-webkit-scrollbar-thumb {
    background: #4b525c;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #636a75;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes floatCard {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

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

.animate-fade-in {
    animation: fadeIn 0.8s ease-out forwards;
}

.animate-float-card {
    animation: floatCard 0.8s ease-out forwards;
}

/* Floating animation for cards after initial load */
.animate-float-card:nth-child(1) {
    animation: floatCard 0.8s ease-out 0.6s forwards, float 4s ease-in-out 1.4s infinite;
}
.animate-float-card:nth-child(2) {
    animation: floatCard 0.8s ease-out 0.9s forwards, float 4.5s ease-in-out 1.7s infinite;
}
.animate-float-card:nth-child(3) {
    animation: floatCard 0.8s ease-out 1.2s forwards, float 5s ease-in-out 2s infinite;
}
.animate-float-card:nth-child(4) {
    animation: floatCard 0.8s ease-out 1.5s forwards, float 4.2s ease-in-out 2.3s infinite;
}

/* ===== Navbar ===== */
#navbar {
    transition: background-color 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background-color: rgba(15, 17, 22, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05);
}

.nav-link {
    position: relative;
}

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

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

/* Mobile Menu */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

.mobile-link {
    position: relative;
}

.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1px;
    background: #f97316;
    transition: width 0.3s ease;
}

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

/* Menu Lines Animation */
.menu-line {
    transition: all 0.3s ease;
}

#menuToggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#menuToggle.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

#menuToggle.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 1.5rem;
}

/* ===== Section Scroll Reveal ===== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* ===== Image Hover Effects ===== */
.overflow-hidden {
    position: relative;
}

.overflow-hidden::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 17, 22, 0.2) 0%, transparent 40%);
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.overflow-hidden:hover::after {
    opacity: 1;
}

/* ===== Button Focus States ===== */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #f97316;
    outline-offset: 2px;
}

/* ===== Input Focus States ===== */
input:focus,
textarea:focus {
    border-color: rgba(249, 115, 22, 0.5) !important;
    box-shadow: 0 0 0 1px rgba(249, 115, 22, 0.3) !important;
}

/* ===== Amenity Card Hover ===== */
.group:hover .group-hover\:bg-coral-500\/20 {
    background-color: rgba(249, 115, 22, 0.2);
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
    .font-serif {
        font-size: clamp(1.75rem, 5vw, 2.5rem);
    }
}

/* ===== Selection Color ===== */
::selection {
    background: rgba(249, 115, 22, 0.3);
    color: #f6f6f7;
}

/* ===== Print Styles ===== */
@media print {
    #navbar,
    #menuToggle,
    button {
        display: none !important;
    }
    
    body {
        background: white;
        color: #1a1d24;
    }
}
