/* 
   Mango Micro Markets - Premium Styles 
   Theme: Modern, Dynamic, Fresh, Tech-forward
*/

:root {
    --primary: #FF8F00;
    /* Mango Orange */
    --primary-dark: #cc7200;
    --acc-green: #43A047;
    /* Leaf Green */
    --dark-bg: #121212;
    --dark-card: #1E1E1E;
    --text-main: #FFFFFF;
    --text-muted: #B0B0B0;
    --glass-bg: rgba(30, 30, 30, 0.6);
    --glass-border: rgba(255, 255, 255, 0.1);
    --font-main: 'Outfit', sans-serif;
    --transition-fast: 0.3s ease;
    --transition-medium: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--dark-bg);
    color: var(--text-main);
    overflow-x: hidden;
    line-height: 1.6;
}

/* --- Typography --- */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

h1 {
    font-size: 3.5rem;
    background: linear-gradient(135deg, #FFF 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

p {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

/* --- Utility Classes --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    background: var(--primary);
    color: white;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.05em;
    box-shadow: 0 8px 16px rgba(255, 143, 0, 0.2);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    background: var(--primary-dark);
    transition: var(--transition-fast);
    z-index: -1;
}

.btn:hover::before {
    width: 100%;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(255, 143, 0, 0.4);
}

.section-padding {
    padding: 1.5rem 0;
}

/* --- Navigation --- */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: var(--transition-medium);
    background: rgba(18, 18, 18, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid transparent;
}

nav.scrolled {
    padding: 1rem 0;
    border-bottom: 1px solid var(--glass-border);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: white;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo span {
    color: var(--primary);
}

.logo img {
    background: linear-gradient(145deg, rgba(30, 30, 30, 0.9), rgba(10, 10, 10, 0.95));
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    padding: 8px 12px;
    border-radius: 12px;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    font-weight: 500;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition-fast);
}

.nav-links a:hover::after {
    width: 100%;
}

/* --- Hero Section --- */
.hero {
    min-height: 50vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: 80px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: radial-gradient(circle at top right, rgba(255, 143, 0, 0.1), transparent 40%),
        radial-gradient(circle at bottom left, rgba(67, 160, 71, 0.1), transparent 40%);
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s forwards 0.5s;
}

.hero-image {
    position: relative;
    opacity: 0;
    transform: translateX(30px);
    animation: fadeInRight 1s forwards 0.8s;
}

.hero-image img {
    width: 100%;
    max-width: 600px;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    /* Floating animation */
    animation: float 6s ease-in-out infinite;
}

/* --- Features / Products --- */
.product-showcase {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-bottom: 4rem;
}

.product-showcase.reverse {
    direction: rtl;
    /* Crude quick swap, better to order items */
}

.product-showcase.reverse .text-box {
    direction: ltr;
}

.image-box {
    position: relative;
}

.image-box img {
    width: 100%;
    border-radius: 12px;
    transition: transform 0.5s ease;
}

.image-box:hover img {
    transform: scale(1.02);
}

.feature-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.card {
    background: var(--dark-card);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid var(--glass-border);
    transition: var(--transition-fast);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--acc-green));
    opacity: 0;
    transition: var(--transition-fast);
}

.card:hover {
    transform: translateY(-10px);
    background: #252525;
}

.card:hover::before {
    opacity: 1;
}

.card h3 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.icon-large {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: block;
}

/* --- Animations --- */
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* --- Footer --- */
footer {
    background: #0a0a0a;
    padding: 4rem 0 2rem;
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-col h4 {
    color: white;
    margin-bottom: 1.5rem;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 0.8rem;
}

.footer-col ul li a {
    color: var(--text-muted);
}

.footer-col ul li a:hover {
    color: var(--primary);
}

.copyright {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: #666;
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-image {
        margin-top: 2rem;
        transform: translateX(0);
        animation: fadeInUp 1s forwards 0.8s;
    }

    .product-showcase {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .product-showcase.reverse {
        direction: ltr;
        /* Reset direction */
    }

    /* Swap image order on mobile for consistency if needed */
    .product-showcase .image-box {
        order: -1;
    }

    /* Mobile Navigation */
    .hamburger {
        display: block;
        cursor: pointer;
        font-size: 2rem;
        color: var(--text-main);
        z-index: 1001;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 100%;
        /* Full width for better touch targets */
        background: rgba(18, 18, 18, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1000;
        display: flex;
        /* Ensure it's display flex to stack items */
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links li {
        margin: 1.5rem 0;
        opacity: 0;
    }

    /* Stagger animation for links */
    .nav-links.active li {
        animation: fadeInUp 0.5s ease forwards;
    }

    .nav-links.active li:nth-child(1) {
        animation-delay: 0.1s;
    }

    .nav-links.active li:nth-child(2) {
        animation-delay: 0.2s;
    }

    .nav-links.active li:nth-child(3) {
        animation-delay: 0.3s;
    }

    .nav-links.active li:nth-child(4) {
        animation-delay: 0.4s;
    }

    .nav-links.active li:nth-child(5) {
        animation-delay: 0.5s;
    }

    .nav-links.active li:nth-child(6) {
        animation-delay: 0.6s;
    }

    .nav-links.active li:nth-child(7) {
        animation-delay: 0.7s;
    }

    .nav-links a {
        font-size: 1.5rem;
    }
}

/* Default Hamburger State (Hidden on Desktop) */
.hamburger {
    display: none;
}