/* ==========================================================================
   CSS Variables
   ========================================================================== */
:root {
    /* Colors */
    --clr-primary-dark: #073D23;
    --clr-primary-light: #356B3C;
    --clr-accent: #F28C18;
    --clr-bg-cream: #F5F1D8;
    --clr-nav-cream: #F8F4DF;
    --clr-white: #FFFFFF;

    /* Typography */
    --font-sans: 'Inter', sans-serif;
    --font-devanagari: 'Noto Sans Devanagari', 'Inter', sans-serif;

    /* Effects */
    --shadow-soft: 0 4px 20px rgba(7, 61, 35, 0.08);
    --shadow-medium: 0 10px 30px rgba(7, 61, 35, 0.12);
    --shadow-phone: 0 24px 60px rgba(0, 0, 0, 0.25);

    /* Spacing */
    --section-pad: 80px 5%;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;
    --border-radius-pill: 100px;
}

/* ==========================================================================
   Base Styles
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-sans);
    color: var(--clr-primary-dark);
    background-color: var(--clr-bg-cream);
    overflow-x: hidden;
    line-height: 1.5;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

/* Typography elements with Devanagari */
[lang="mr"] {
    font-family: var(--font-devanagari);
}

/* ==========================================================================
   Navigation
   ========================================================================== */
.navbar {
    background-color: var(--clr-nav-cream);
    box-shadow: 0 2px 10px rgba(7, 61, 35, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 16px 5%;
}

.navbar-container {
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.logo-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-wrapper h1 {
    font-size: 28px;
    font-weight: 800;
    color: var(--clr-primary-dark);
    letter-spacing: -0.5px;
    line-height: 1;
}

.logo-accent {
    position: absolute;
    top: -8px;
    width: 24px;
    height: 12px;
    border-radius: 12px 12px 0 0;
    border: 3px solid var(--clr-accent);
    border-bottom: none;
    transform: rotate(15deg);
}

.tagline-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tagline {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: var(--clr-primary-dark);
    text-transform: uppercase;
}

.tagline-line {
    width: 20px;
    height: 1px;
    background-color: var(--clr-accent);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav-links a {
    font-size: 16px;
    font-weight: 500;
    color: var(--clr-primary-dark);
    transition: color 0.2s ease, transform 0.2s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--clr-primary-light);
    transition: width 0.3s ease;
}

.nav-links a:hover {
    color: var(--clr-primary-light);
}

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

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.icon-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(7, 61, 35, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--clr-primary-dark);
    transition: all 0.2s ease;
}

.icon-btn:hover {
    background-color: rgba(7, 61, 35, 0.05);
    border-color: var(--clr-primary-dark);
}

.primary-btn {
    background-color: var(--clr-primary-dark);
    color: var(--clr-white);
    padding: 12px 24px;
    border-radius: var(--border-radius-pill);
    font-weight: 600;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.primary-btn i {
    font-size: 18px;
}

.primary-btn:hover {
    background-color: var(--clr-primary-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(7, 61, 35, 0.2);
}

.mobile-menu-btn {
    display: none;
    font-size: 24px;
    color: var(--clr-primary-dark);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    position: relative;
    height: calc(100vh - 140px);
    min-height: 550px;
    background-color: var(--clr-nav-cream);
    /* fallback */
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.bg-layer {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.6;
    /* to let the warm cream show through */
}

.bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(248, 244, 223, 0.4) 0%, rgba(248, 244, 223, 0.8) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1440px;
    margin: 0 auto;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 10px 2% 0;
}

/* Left & Right Scenes */
.hero-scene {
    position: relative;
    width: 380px;
    height: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.scene-left {
    margin-right: auto;
}

.scene-right {
    margin-left: auto;
}

.character-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-medium);
}

.floating-badge {
    position: absolute;
    background: var(--clr-white);
    padding: 10px 20px;
    border-radius: var(--border-radius-pill);
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: var(--shadow-soft);
    z-index: 3;
    animation: float 4s ease-in-out infinite;
}

.badge-left {
    top: 20px;
    left: -25px;
}

.badge-right {
    bottom: -20px;
    right: -30px;
    animation-delay: 1s;
}

.badge-icon {
    width: 32px;
    height: 32px;
    background: var(--clr-bg-cream);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--clr-primary-light);
    font-size: 18px;
}

.badge-text {
    color: var(--clr-primary-dark);
    font-weight: 600;
    font-size: 14px;
}

/* Center Hero Area */
.hero-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    top: 20px;
}

.hero-branding {
    text-align: center;
    margin-bottom: 12px;
}

.hero-logo {
    font-size: 36px;
    font-weight: 800;
    color: var(--clr-primary-dark);
    letter-spacing: -1px;
    line-height: 1;
}

.hero-tagline-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 8px 0 16px;
}

.hero-tagline-wrapper p {
    font-size: 12px;
    font-weight: 700;
    color: var(--clr-primary-dark);
    letter-spacing: 1px;
}

.hero-line {
    width: 40px;
    height: 2px;
    background-color: var(--clr-accent);
}

.coming-soon {
    font-size: 20px;
    font-weight: 600;
    color: var(--clr-primary-dark);
}

/* Smartphone Mockup */
.smartphone {
    width: 270px;
    height: 540px;
    background-color: #111;
    border-radius: 36px;
    padding: 10px;
    box-shadow: var(--shadow-phone);
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.phone-frame {
    width: 100%;
    height: 100%;
    background-color: #FFF;
    border-radius: 32px;
    overflow: hidden;
    position: relative;
}

.phone-notch {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 20px;
    background-color: #111;
    border-radius: 0 0 12px 12px;
    z-index: 20;
}

.phone-screen {
    width: 100%;
    height: 100%;
    overflow-y: auto;
    padding-bottom: 80px;
    /* space for bottom nav */
    scrollbar-width: none;
    /* Firefox */
}

.phone-screen::-webkit-scrollbar,
.hide-scrollbar::-webkit-scrollbar {
    display: none;
    /* Safari and Chrome */
}

.hide-scrollbar {
    scrollbar-width: none;
    /* Firefox */
}

/* App Header */
.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 15px 10px;
}

.location-selector {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    color: var(--clr-primary-dark);
}

.location-icon {
    color: var(--clr-accent);
    font-size: 16px;
}

.caret-icon {
    font-size: 10px;
}

.notification-icon {
    width: 28px;
    height: 28px;
    background: var(--clr-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: var(--clr-primary-dark);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

/* App Search */
.app-search {
    margin: 0 15px 15px;
    background: var(--clr-white);
    border-radius: var(--border-radius-md);
    padding: 10px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(7, 61, 35, 0.05);
}

.app-search i {
    color: var(--clr-primary-light);
    font-size: 16px;
}

.app-search input {
    border: none;
    outline: none;
    width: 100%;
    font-family: var(--font-sans);
    font-size: 11px;
    color: var(--clr-primary-dark);
}

/* App Categories */
.app-categories {
    display: flex;
    justify-content: space-between;
    padding: 0 15px 15px;
    overflow-x: auto;
    scrollbar-width: none;
}

.app-categories::-webkit-scrollbar {
    display: none;
}

.cat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 50px;
}

.cat-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--clr-primary-dark);
}

.bg-grocery {
    background: #E8F5E9;
}

.bg-veg {
    background: #FFF3E0;
}

.bg-med {
    background: #E3F2FD;
}

.bg-bakery {
    background: #FFF8E1;
}

.bg-more {
    background: #F3E5F5;
}

.cat-item span {
    font-size: 10px;
    font-weight: 500;
    color: var(--clr-primary-dark);
}

/* App Section Base */
.app-section {
    padding: 0 15px 15px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.section-header h4 {
    font-size: 12px;
    font-weight: 700;
    color: var(--clr-primary-dark);
}

.view-all {
    font-size: 10px;
    font-weight: 600;
    color: var(--clr-primary-light);
}

/* Category Cards */
.category-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.cat-card {
    background: var(--clr-white);
    border-radius: var(--border-radius-md);
    padding: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.03);
}

.cat-card-img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--clr-bg-cream);
    /* placeholder styles */
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
}

.placeholder-essentials {
    background-image: url('https://images.unsplash.com/photo-1542838132-92c53300491e?auto=format&fit=crop&w=150&q=80');
}

.placeholder-veg {
    background-image: url('https://images.unsplash.com/photo-1566385101042-1a0aa0c1268c?auto=format&fit=crop&w=150&q=80');
}

.placeholder-health {
    background-image: url('https://images.unsplash.com/photo-1584308666744-24d5c474f2ad?auto=format&fit=crop&w=150&q=80');
}

.placeholder-snacks {
    background-image: url('https://images.unsplash.com/photo-1621939514649-280e2ee25f60?auto=format&fit=crop&w=150&q=80');
}


.cat-card p {
    font-size: 10px;
    font-weight: 600;
    text-align: center;
}

/* Support Local Banner */
.support-banner {
    margin: 0 15px 15px;
    background: linear-gradient(135deg, var(--clr-primary-light), var(--clr-primary-dark));
    border-radius: var(--border-radius-md);
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--clr-white);
}

.banner-title {
    font-size: 12px;
    font-weight: 800;
}

.banner-subtitle {
    font-size: 9px;
    font-weight: 500;
    opacity: 0.9;
}

.banner-illustration {
    font-size: 24px;
    color: var(--clr-bg-cream);
    opacity: 0.8;
}

/* Top Stores */
.store-cards {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 5px;
}

.store-cards::-webkit-scrollbar {
    display: none;
}

.store-card {
    min-width: 70px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.store-img {
    width: 56px;
    height: 56px;
    border-radius: var(--border-radius-sm);
    background-color: var(--clr-white);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    background-size: cover;
    background-position: center;
}

.placeholder-kirana {
    background-image: url('https://images.unsplash.com/photo-1604719312566-8912e9227c6a?auto=format&fit=crop&w=150&q=80');
}

.placeholder-medical {
    background-image: url('https://images.unsplash.com/photo-1576602976047-174e57a47881?auto=format&fit=crop&w=150&q=80');
}

.placeholder-bakery {
    background-image: url('https://images.unsplash.com/photo-1509440159596-0249088772ff?auto=format&fit=crop&w=150&q=80');
}

.placeholder-mart {
    background-image: url('https://images.unsplash.com/photo-1578916171728-46686eac8d58?auto=format&fit=crop&w=150&q=80');
}


.store-card p {
    font-size: 9px;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}

/* App Bottom Nav */
.app-bottom-nav {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--clr-white);
    display: flex;
    justify-content: space-around;
    padding: 8px 0 12px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 0 0 26px 26px;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    color: #999;
    font-size: 9px;
    font-weight: 500;
}

.bottom-nav-item i {
    font-size: 16px;
}

.bottom-nav-item.active {
    color: var(--clr-primary-dark);
}

/* Light Trails */
.light-trails {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 5;
}

/* We will animate these trails to simulate flowing energy */
@keyframes flow-trail {
    to {
        stroke-dashoffset: -1000;
    }
}

.trail {
    stroke-dasharray: 200 400;
    stroke-dashoffset: 0;
    animation: flow-trail 4s linear infinite;
}

/* Hero Curve Bottom */
.hero-curve {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    line-height: 0;
    z-index: 20;
}

.hero-curve svg {
    width: 100%;
    height: 3vw;
    /* responsive height */
    min-height: 20px;
    display: block;
}

/* ==========================================================================
   Features Section
   ========================================================================== */
.features {
    background-color: var(--clr-bg-cream);
    padding: 0 5% 10px;
}

.features-container {
    max-width: 1200px;
    margin: -20px auto 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    position: relative;
    z-index: 30;
}

.feature-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0 5px;
}

.feature-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--clr-primary-light), var(--clr-primary-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--clr-white);
    margin-bottom: 6px;
    box-shadow: 0 4px 10px rgba(7, 61, 35, 0.2);
    border: 2px solid var(--clr-white);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover .feature-icon {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(7, 61, 35, 0.35);
}

.feature-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--clr-primary-dark);
    margin-bottom: 4px;
}

.feature-desc {
    font-size: 12px;
    color: var(--clr-primary-light);
    font-weight: 500;
}

.feature-divider {
    width: 1px;
    height: 80px;
    background-color: rgba(7, 61, 35, 0.1);
    align-self: center;
}

/* ==========================================================================
   Animations
   ========================================================================== */
@keyframes float {

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

    50% {
        transform: translateY(-10px);
    }
}

@keyframes slideUpFade {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

@keyframes scaleUp {
    from {
        transform: translateX(-50%) scale(0.95);
        opacity: 0;
    }

    to {
        transform: translateX(-50%) scale(1);
        opacity: 1;
    }
}

.hero-branding {
    animation: slideUpFade 0.8s ease forwards;
}

.hero-center {
    animation: scaleUp 0.8s ease forwards 0.2s;
}

.scene-left {
    animation: slideUpFade 0.8s ease forwards 0.4s;
    opacity: 0;
}

.scene-right {
    animation: slideUpFade 0.8s ease forwards 0.6s;
    opacity: 0;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

/* Laptop / Small Desktop (1024px - 1439px) */
@media (max-width: 1439px) {
    .hero-scene {
        width: 300px;
    }

    .nav-links {
        gap: 20px;
    }
}

/* Tablet (768px - 1023px) */
@media (max-width: 1023px) {
    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .nav-actions {
        display: none;
    }

    .hero-scene {
        width: 200px;
    }

    .floating-badge {
        padding: 8px 12px;
    }

    .badge-text {
        font-size: 12px;
    }

    .features-container {
        flex-wrap: wrap;
        gap: 40px;
    }

    .feature-item {
        flex: 1 1 40%;
    }

    .feature-divider {
        display: none;
    }
}

/* Mobile (320px - 767px) */
@media (max-width: 767px) {
    .navbar {
        padding: 12px 5%;
    }

    .logo-wrapper h1 {
        font-size: 24px;
    }

    .hero {
        min-height: auto;
        padding-top: 20px;
    }

    .hero-content {
        flex-direction: column;
        height: auto;
        padding: 0;
        gap: 40px;
    }

    .hero-center {
        position: relative;
        left: 0;
        transform: none;
        top: 0;
        animation: none;
    }

    .scene-left,
    .scene-right {
        width: 90%;
        height: auto;
        margin: 0 auto;
        opacity: 1;
        animation: none;
    }

    .scene-left {
        order: 2;
    }

    .scene-right {
        order: 3;
    }

    .light-trails {
        display: none;
        /* Hide trails on mobile for cleaner look or recreate specifically for vertical flow */
    }

    .hero-curve {
        position: relative;
        margin-top: -30px;
    }

    .features {
        padding: 40px 5% 40px;
    }

    .features-container {
        flex-wrap: nowrap;
        gap: 5px;
        justify-content: space-between;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .features-container::-webkit-scrollbar {
        display: none;
    }

    .feature-item {
        flex: 1 1 25%;
        margin-bottom: 0;
        padding: 0 2px;
        min-width: 80px;
    }
    
    .feature-icon {
        width: 50px;
        height: 50px;
        font-size: 24px;
        margin-bottom: 10px;
        border-width: 2px;
    }
    
    .feature-title {
        font-size: 12px;
    }
    
    .feature-desc {
        font-size: 10px;
        display: none; /* Hide desc on mobile to save space and keep it clean */
    }
}