/* ==========================================================================
   Home Page Styles
   ========================================================================== */

/* Features Section */
.features {
    padding: 120px 0; /* Increased padding for more breathing room */
    background: linear-gradient(135deg, 
        var(--rich-black) 0%, 
        rgba(26, 26, 26, 0.95) 50%,
        var(--soft-black) 100%);
    margin-top: 60px; /* Extra gap after hero to ensure clearance */
    position: relative;
    border-top: 1px solid rgba(212, 175, 55, 0.1);
}

.features::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(212, 175, 55, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(212, 175, 55, 0.03) 0%, transparent 50%);
    z-index: 0;
}

.features .container {
    position: relative;
    z-index: 1;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 4rem;
    margin-top: 5rem;
}

.feature-card {
    text-align: center;
    padding: 3rem 2rem;
    background: rgba(26, 26, 26, 0.5);
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: var(--border-radius-large);
    transition: var(--transition-medium);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(212, 175, 55, 0.1), 
        transparent);
    transition: var(--transition-slow);
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-10px);
    border-color: rgba(212, 175, 55, 0.4);
    box-shadow: var(--shadow-glow);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 2rem;
    background: linear-gradient(135deg, var(--gold-primary), var(--gold-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.feature-icon::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: linear-gradient(45deg, var(--gold-primary), transparent, var(--gold-primary));
    border-radius: 50%;
    z-index: -1;
    animation: rotate 3s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.feature-icon i {
    font-size: 2.5rem;
    color: var(--primary-black);
}

.feature-card h3 {
    font-size: 1.5rem;
    color: var(--gold-primary);
    margin-bottom: 1rem;
    font-weight: 600;
}

.feature-card p {
    color: var(--white-soft);
    line-height: 1.7;
    font-size: 1.1rem;
}

/* Menu Preview Section */
.menu-preview {
    padding: 130px 0; /* Increased padding for better spacing */
    background: linear-gradient(135deg, 
        var(--primary-black) 0%, 
        rgba(10, 10, 10, 0.98) 50%,
        var(--rich-black) 100%);
    position: relative;
    border-top: 2px solid rgba(212, 175, 55, 0.15);
    margin-top: 40px;
}

.menu-preview::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/texture-overlay.png') repeat;
    opacity: 0.05;
    z-index: 0;
}

.menu-preview .container {
    position: relative;
    z-index: 1;
}

.menu-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2.5rem;
    margin: 4rem 0;
}

.menu-item {
    background: linear-gradient(135deg, 
        rgba(26, 26, 26, 0.9) 0%, 
        rgba(45, 45, 45, 0.8) 100%);
    border-radius: var(--border-radius-large);
    overflow: hidden;
    transition: var(--transition-medium);
    border: 1px solid rgba(212, 175, 55, 0.2);
    box-shadow: var(--shadow-light);
}

.menu-item:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-heavy);
    border-color: rgba(212, 175, 55, 0.4);
}

.menu-item-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.menu-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-slow);
}

.menu-item:hover .menu-item-image img {
    transform: scale(1.1);
}

.menu-item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.3) 0%, 
        rgba(212, 175, 55, 0.2) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-medium);
}

.menu-item:hover .menu-item-overlay {
    opacity: 1;
}

.price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gold-primary);
    background: rgba(0, 0, 0, 0.8);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius-medium);
    backdrop-filter: blur(10px);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.menu-item-content {
    padding: 2rem;
}

.menu-item-content h3 {
    font-size: 1.5rem;
    color: var(--gold-primary);
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.menu-item-content p {
    color: var(--white-soft);
    line-height: 1.6;
    font-size: 1rem;
    margin-bottom: 0;
}

.menu-preview-footer {
    text-align: center;
    margin-top: 3rem;
}

.menu-preview-footer .btn-primary {
    padding: 1.25rem 3rem;
    font-size: 1.125rem;
    font-weight: 600;
}

/* Responsive Design for Home Page */
@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .feature-card {
        padding: 2rem 1.5rem;
    }
    
    .menu-preview-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin: 3rem 0;
    }
    
    .menu-item-image {
        height: 200px;
    }
}

@media (max-width: 480px) {
    .feature-icon {
        width: 60px;
        height: 60px;
    }
    
    .feature-icon i {
        font-size: 2rem;
    }
    
    .menu-preview-grid {
        grid-template-columns: 1fr;
    }
    
    .menu-item-content {
        padding: 1.5rem;
    }
}

/* Additional Styling for Better Visibility */
.hero-title-main {
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.8);
}

.hero-title-sub {
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
}

.hero-description {
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(2px);
    padding: 1.5rem 2rem;
    border-radius: var(--border-radius-large);
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.3) 0%, 
        rgba(212, 175, 55, 0.1) 50%,
        rgba(0, 0, 0, 0.3) 100%);
    border: 1px solid rgba(212, 175, 55, 0.2);
    margin-bottom: 4rem;
    font-size: clamp(1rem, 2vw, 1.25rem) !important;
    font-weight: 400;
}

/* Enhanced Menu Item Styling */
.menu-item {
    position: relative;
    overflow: hidden;
}

.menu-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(212, 175, 55, 0.1), 
        transparent);
    transition: left 0.8s ease;
    z-index: 1;
}

.menu-item:hover::before {
    left: 100%;
}

.menu-item-content {
    position: relative;
    z-index: 2;
}

/* Section Header Enhancements for Homepage */
.section-header {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

.section-header::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 2px;
    background: linear-gradient(90deg, 
        transparent, 
        var(--gold-primary), 
        transparent);
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, 
        var(--gold-primary) 0%, 
        var(--gold-light) 50%,
        var(--gold-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 4px 8px rgba(212, 175, 55, 0.3);
}

.section-description {
    font-size: 1.25rem;
    color: var(--gold-light);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Enhanced Menu Preview Footer */
.menu-preview-footer {
    text-align: center;
    margin-top: 5rem;
    padding-top: 3rem;
    border-top: 1px solid rgba(212, 175, 55, 0.1);
}

/* Homepage Specific Animations */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Add floating animation to feature icons */
.feature-icon {
    animation: float 6s ease-in-out infinite;
}

.feature-card:nth-child(2) .feature-icon {
    animation-delay: -2s;
}

.feature-card:nth-child(3) .feature-icon {
    animation-delay: -4s;
}

/* Enhanced Hero Button Styling */
.hero-buttons .btn-primary {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, 
        var(--gold-primary) 0%, 
        var(--gold-accent) 50%,
        var(--gold-primary) 100%);
    background-size: 200% 200%;
    animation: gradient-shift 3s ease infinite;
}

@keyframes gradient-shift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.hero-buttons .btn-primary:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 25px rgba(212, 175, 55, 0.4);
}

.hero-buttons .btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(212, 175, 55, 0.3);
}

/* ==========================================================================
   Homepage Background Animations
   ========================================================================== */

/* Hero Section Enhanced Background */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(45deg, rgba(212, 175, 55, 0.05) 0%, transparent 30%),
        linear-gradient(-45deg, rgba(255, 107, 53, 0.04) 0%, transparent 35%),
        linear-gradient(135deg, rgba(231, 76, 60, 0.03) 0%, transparent 40%);
    animation: heroBackgroundFlow 25s ease-in-out infinite;
    pointer-events: none;
    z-index: -1;
}

@keyframes heroBackgroundFlow {
    0%, 100% {
        transform: translateX(0px) translateY(0px) rotate(0deg);
        opacity: 0.6;
    }
    33% {
        transform: translateX(30px) translateY(-20px) rotate(1deg);
        opacity: 0.8;
    }
    66% {
        transform: translateX(-20px) translateY(30px) rotate(-1deg);
        opacity: 0.7;
    }
}

/* Features Section Wave Animation */
.features::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        repeating-linear-gradient(
            90deg,
            transparent 0px,
            rgba(212, 175, 55, 0.02) 50px,
            transparent 100px,
            rgba(255, 107, 53, 0.015) 150px,
            transparent 200px
        );
    animation: waveFlow 20s linear infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes waveFlow {
    0% {
        background-position-x: 0px;
        opacity: 0.5;
    }
    50% {
        opacity: 0.8;
    }
    100% {
        background-position-x: 200px;
        opacity: 0.5;
    }
}

/* Menu Preview Floating Dots */
.menu-preview::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(212, 175, 55, 0.08) 3px, transparent 4px),
        radial-gradient(circle at 90% 80%, rgba(255, 107, 53, 0.06) 2px, transparent 3px),
        radial-gradient(circle at 50% 50%, rgba(231, 76, 60, 0.04) 2.5px, transparent 3.5px),
        radial-gradient(circle at 20% 70%, rgba(212, 175, 55, 0.05) 1.5px, transparent 2.5px);
    background-size: 200px 200px, 300px 300px, 250px 250px, 180px 180px;
    animation: menuDotsFloat 35s ease-in-out infinite;
    pointer-events: none;
    z-index: 0;
}

@keyframes menuDotsFloat {
    0%, 100% {
        background-position: 0% 0%, 100% 100%, 50% 50%, 0% 100%;
        transform: scale(1);
    }
    25% {
        background-position: 20% 10%, 80% 90%, 60% 40%, 10% 90%;
        transform: scale(1.02);
    }
    50% {
        background-position: 40% 20%, 60% 80%, 70% 30%, 20% 80%;
        transform: scale(0.98);
    }
    75% {
        background-position: 60% 30%, 40% 70%, 80% 20%, 30% 70%;
        transform: scale(1.01);
    }
}

/* Mobile Responsive Enhancements for Homepage */
@media (max-width: 768px) {
    .features {
        padding: 80px 0;
        margin-top: 20px;
    }
    
    .features-grid {
        gap: 2.5rem;
        margin-top: 3rem;
    }
    
    .menu-preview {
        padding: 80px 0;
        margin-top: 20px;
    }
    
    .section-title {
        font-size: clamp(2rem, 6vw, 2.5rem);
    }
    
    .hero-description {
        padding: 1rem 1.5rem;
        margin-bottom: 3rem;
        font-size: 1rem !important;
        line-height: 1.6;
    }
    
    .menu-preview-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin: 3rem 0;
    }
    
    .menu-preview-footer {
        margin-top: 3rem;
        padding-top: 2rem;
    }
    
    /* Disable floating animation on mobile for better performance */
    .feature-icon {
        animation: none;
    }
    
    .hero-buttons .btn-primary,
    .hero-buttons .btn-secondary {
        animation: none;
        background-size: 100% 100%;
    }
}
