/* ========================================
   MoFruits.id - Custom Styles
   ======================================== */

/* ===== CSS Variables ===== */
:root {
    --warm-white: #FDFCFA;
    --brand-green: #22A652;
    --brand-yellow: #F4B824;
    --light-green: #E8F5EC;
    --light-yellow: #FEF8E8;
    --forest-green: #1A5D3A;
    --soft-green: #A8D5BA;

    /* Legacy names for compatibility */
    --warm-sand: #FDFCFA;
    --mineral-green: #E8F5EC;
    --dusty-pink: #FEF8E8;
    --deep-olive: #1A5D3A;
    --soft-sage: #A8D5BA;
}

/* ===== Base Styles ===== */
* {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

::selection {
    background: var(--brand-yellow);
    color: var(--forest-green);
}

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--warm-sand);
}

::-webkit-scrollbar-thumb {
    background: var(--soft-green);
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--brand-green);
}

/* ===== Text Gradient ===== */
.text-gradient {
    background: linear-gradient(135deg, var(--brand-green) 0%, #2ECC71 50%, var(--brand-yellow) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== Glass Navigation ===== */
.glass-nav {
    background: rgba(253, 252, 250, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.glass-nav.scrolled {
    background: rgba(253, 252, 250, 0.95);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

/* ===== Scroll Indicator ===== */
.scroll-indicator {
    width: 24px;
    height: 40px;
    border: 2px solid var(--deep-olive);
    border-radius: 12px;
    position: relative;
}

.scroll-indicator::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--deep-olive);
    border-radius: 2px;
    animation: scroll-bounce 2s ease-in-out infinite;
}

@keyframes scroll-bounce {

    0%,
    100% {
        transform: translateX(-50%) translateY(0);
        opacity: 1;
    }

    50% {
        transform: translateX(-50%) translateY(12px);
        opacity: 0.3;
    }
}

/* ===== Animations ===== */
.animate-fade-in {
    animation: fade-in 0.8s ease-out forwards;
    opacity: 0;
}

.animate-fade-in-up {
    animation: fade-in-up 0.8s ease-out forwards;
    opacity: 0;
}

@keyframes fade-in {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-bounce-slow {
    animation: bounce-slow 2s ease-in-out infinite;
}

@keyframes bounce-slow {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(5px);
    }
}

/* ===== Bento Grid ===== */
.bento-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bento-large {
        grid-row: span 2;
    }

    .bento-wide {
        grid-column: span 2;
    }
}

@media (min-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ===== Bento Cards ===== */
.bento-card {
    background: white;
    border-radius: 1.25rem;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 20px rgba(74, 93, 82, 0.08);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.bento-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 24px rgba(74, 93, 82, 0.12);
    z-index: 10;
}

.card-image {
    position: relative;
    overflow: hidden;
}

.card-placeholder {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.4s ease;
}

.bento-large .card-placeholder {
    height: 300px;
}

.bento-card:hover .card-placeholder {
    transform: scale(1.05);
}

.card-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-badge {
    display: inline-block;
    background: var(--light-green);
    color: var(--forest-green);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.card-badge-soon {
    background: var(--light-yellow);
    color: var(--brand-yellow);
}

.card-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--forest-green);
    margin-bottom: 0.5rem;
}

.card-desc {
    color: rgba(26, 93, 58, 0.8);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

/* Product Tags */
.product-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tag-pill {
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    background: var(--warm-white);
    border: 1px solid var(--soft-green);
    color: var(--forest-green);
    font-weight: 500;
}

.card-actions {
    margin-top: auto;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.card-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    color: white;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.75rem 1.25rem;
    background: var(--forest-green);
    border-radius: 1rem;
    transition: all 0.3s ease;
    flex: 1;
}

.card-cta:hover {
    background: var(--brand-green);
    transform: translateY(-2px);
}

.card-cta-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--light-yellow);
    color: var(--brand-yellow);
    border: 1px solid var(--brand-yellow);
    transition: all 0.3s ease;
}

.card-cta-secondary:hover {
    background: var(--brand-yellow);
    color: white;
    transform: translateY(-2px);
}

/* ===== Map Styles ===== */
.map-container {
    width: 100%;
    height: 400px;
    border-radius: 2rem;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.grayscale-map {
    width: 100%;
    height: 100%;
    filter: grayscale(100%);
    transition: filter 0.5s ease;
}

.map-container:hover .grayscale-map {
    filter: grayscale(0%);
}

/* ===== Floating FAB ===== */
.floating-fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: #25D366;
    color: white;
    border-radius: 50%;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    transition: all 0.3s ease;
    animation: pulse-green 2s infinite;
}

.floating-fab:hover {
    transform: scale(1.1);
}

@keyframes pulse-green {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* ===== Outlet Tabs ===== */
.outlet-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    border-radius: 0.875rem;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--forest-green);
    background: white;
    border: 1px solid var(--light-green);
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    border-color: var(--brand-green);
    background: var(--light-green);
}

.tab-btn.active {
    background: var(--forest-green);
    color: white;
    border-color: var(--forest-green);
    box-shadow: 0 4px 12px rgba(26, 93, 58, 0.3);
}

.tab-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Location Cards ===== */
.location-card {
    background: white;
    border-radius: 1.5rem;
    overflow: hidden;
    border: 1px solid var(--light-green);
    transition: all 0.4s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.location-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
    border-color: var(--brand-green);
}

.location-map-preview {
    height: 150px;
    background: var(--light-green);
    position: relative;
    overflow: hidden;
}

.location-map-preview iframe {
    width: 100%;
    height: 100%;
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.location-card:hover iframe {
    filter: grayscale(0%);
}

.location-info {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.location-btn {
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem;
    background: var(--warm-white);
    color: var(--forest-green);
    border: 1px solid var(--forest-green);
    border-radius: 0.75rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.location-btn:hover {
    background: var(--forest-green);
    color: white;
}

/* ===== Service Cards (Delivery) ===== */
.delivery-logos {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.delivery-badge {
    background: white;
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--forest-green);
    border: 1px solid var(--light-green);
    transition: all 0.3s ease;
}

.delivery-badge:hover {
    border-color: var(--brand-green);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
}

/* ===== CTA Button Pulse ===== */
.cta-button {
    position: relative;
}

.cta-button::before {
    content: '';
    position: absolute;
    inset: -4px;
    background: inherit;
    border-radius: 9999px;
    opacity: 0;
    z-index: -1;
    transition: all 0.3s ease;
}

.cta-button:hover::before {
    inset: -6px;
    opacity: 0.3;
}

/* ===== Scroll Reveal ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

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

/* ===== Parallax Elements ===== */
.parallax-element {
    transition: transform 0.1s linear;
}

/* ===== Mobile Responsive ===== */
@media (max-width: 768px) {
    .service-card {
        flex-direction: column;
        text-align: center;
    }

    .service-icon {
        margin: 0 auto;
    }

    .glass-nav .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(253, 252, 250, 0.98);
        flex-direction: column;
        padding: 2rem;
        gap: 1.5rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
        transition: all 0.4s ease;
    }

    .glass-nav .nav-links.active {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }
}