/* css/animations.css */
/* Animation Classes */
.animate-text {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-text.visible {
    opacity: 1;
    transform: translateY(0);
}

.animate-card {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.animate-btn {
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-btn.visible {
    opacity: 1;
    transform: scale(1);
}

/* Coffee Beans Animation */
.coffee-beans-animation {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 1;
    pointer-events: none;
}

.coffee-beans-animation::before,
.coffee-beans-animation::after,
.coffee-beans-animation span {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M50,10 C70,10 85,25 85,45 C85,65 70,80 50,80 C30,80 15,65 15,45 C15,25 30,10 50,10 Z" fill="%23DAA520" opacity="0.7"/><path d="M40,30 C45,25 55,25 60,30 C65,35 65,45 60,50 C55,55 45,55 40,50 C35,45 35,35 40,30 Z" fill="%238B7355" opacity="0.9"/></svg>') no-repeat center;
    background-size: contain;
    opacity: 0;
    animation: floatCoffeeBean 20s linear infinite;
}

.coffee-beans-animation::before {
    top: 10%;
    left: 10%;
    animation-delay: 0s;
    width: 25px;
    height: 25px;
}

.coffee-beans-animation::after {
    top: 20%;
    right: 15%;
    animation-delay: 5s;
    width: 18px;
    height: 18px;
}

.coffee-beans-animation span:nth-child(1) {
    top: 40%;
    left: 5%;
    animation-delay: 10s;
    width: 22px;
    height: 22px;
}

.coffee-beans-animation span:nth-child(2) {
    top: 60%;
    right: 10%;
    animation-delay: 15s;
    width: 20px;
    height: 20px;
}

.coffee-beans-animation span:nth-child(3) {
    top: 80%;
    left: 20%;
    animation-delay: 7s;
    width: 16px;
    height: 16px;
}

@keyframes floatCoffeeBean {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.7;
    }
    90% {
        opacity: 0.7;
    }
    100% {
        transform: translateY(-100px) rotate(360deg);
        opacity: 0;
    }
}


/* Text backdrop - sits behind text but in front of images */
.text-backdrop {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    max-width: 900px;
    height: 60%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 9; /* Between text (z-index: 10) and images (z-index: 3-8) */
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        inset 0 0 50px rgba(255, 255, 255, 0.05);
    pointer-events: none; /* Allows clicking through */
}

/* Full Background Blur Overlay */
.full-backdrop-blur {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0.0000001, 0.00000001); /* Dark overlay */
    backdrop-filter: blur(1.09px); /* This is the blur effect */
    -webkit-backdrop-filter: blur(24px); /* For Safari */
    z-index: 5; /* Above images (3-4) but below text (10) */
    pointer-events: none; /* Allows clicking through */
}

/* Adjust your existing z-indexes */
.hero-content {
    z-index: 10 !important; /* Make sure text is on top */
}

.photo-pop-container {
    z-index: 3; /* Images under the blur */
}

.photo-pop {
    z-index: 4; /* Individual images can be above container */
}

.hero-overlay {
    z-index: 2; /* Keep below everything */
}

/* Hover Effects */
.value-card:hover .value-icon,
.impact-card:hover .impact-icon,
.benefit-item:hover .benefit-icon {
    transform: scale(1.1) rotate(5deg);
    transition: transform 0.3s ease;
}

/* Scroll Progress Indicator */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(to right, var(--sabrosa-green), var(--sabrosa-gold));
    z-index: 1001;
    transition: width 0.1s ease;
}

/* Loading Animation */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-logo {
    width: 150px;
    margin-bottom: 30px;
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 5px solid var(--light-gray);
    border-top: 5px solid var(--sabrosa-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Pulse Animation for CTA buttons */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(218, 165, 32, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(218, 165, 32, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(218, 165, 32, 0);
    }
}

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

/* Product Image Hover Effect */
.product-img {
    transition: transform 0.5s ease;
}

.product-card:hover .product-img {
    transform: scale(1.05) rotate(2deg);
}

/* Section Entrance Animation */
.section {
    opacity: 0;
    transform: translateY(50px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section.visible {
    opacity: 1;
    transform: translateY(0);
}