/* Global Variables */
:root {
    --primary-color: #DC143C;
    /* Crimson */
    --primary-dark: #B90E31;
    --accent-gold: #DAA520;
    /* Gold for premium feel */
    --text-color: #333333;
    --text-light: #666666;
    --bg-color: #FFFFFF;
    --bg-light: #FFF5F5;
    /* Very light crimson tint */
    --white: #FFFFFF;
    --black: #000000;
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 15px 40px rgba(220, 20, 60, 0.15);

    --font-heading: 'Playfair Display', serif;
    --font-body: 'Outfit', sans-serif;

    --transition-speed: 0.3s;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-speed);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    color: var(--black);
    line-height: 1.2;
}

h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1.5rem;
    color: var(--text-light);
}

.highlight {
    color: var(--primary-color);
}

.highlight-text {
    color: var(--primary-color);
}

.section-subtitle {
    display: block;
    font-family: var(--font-body);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

/* Buttons */
.btn-primary,
.btn-secondary {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    border: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(220, 20, 60, 0.3);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(220, 20, 60, 0.4);
}

.btn-secondary {
    border: 2px solid var(--text-color);
    color: var(--text-color);
    background: transparent;
    margin-left: 1rem;
}

.btn-secondary:hover {
    background-color: var(--text-color);
    color: var(--white);
    transform: translateY(-2px);
}

/* Header & Nav */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1rem 5%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--black);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links li a {
    font-weight: 500;
    color: var(--text-color);
    position: relative;
}

.nav-links li a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition-speed);
}

.nav-links li a:hover::after {
    width: 100%;
}

.nav-icons {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    font-size: 1.2rem;
}

.cart-icon {
    position: relative;
    color: var(--black);
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--primary-color);
    color: white;
    font-size: 0.7rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.hamburger {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding: 100px 5% 50px;
    background: linear-gradient(135deg, #fff 0%, #fff0f5 100%);
    overflow: hidden;
}

/* Spice Specific Hero Visuals */
.spice-hero .hero-visual {
    position: relative;
    height: auto;
    min-height: 400px;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.spice-circle-bg {
    width: 80%;
    max-width: 500px;
    padding-bottom: 80%;
    /* Aspect Ratio */
    height: 0;
    background: linear-gradient(45deg, #ffe5e5, #fff);
    border-radius: 50%;
    position: absolute;
    z-index: 1;
}

.spice-composition {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
}

.floating-spice {
    position: absolute;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    animation: float 6s ease-in-out infinite;
}

.spice-1 {
    width: 35%;
    padding-bottom: 35%;
    height: 0;
    background-color: #d13030;
    background-image: url('https://images.unsplash.com/photo-1596040033229-a9821ebd058d?ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=80');
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.spice-3 {
    width: 20%;
    padding-bottom: 20%;
    height: 0;
    background-color: #6e4c2e;
    background-image: url('https://images.unsplash.com/photo-1535585209827-a15fcdbc4c2d?ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=80');
    bottom: 25%;
    left: 20%;
    animation-delay: 2s;
}

@keyframes float {
    0% {
        transform: translate(-50%, -50%) translateY(0);
    }

    50% {
        transform: translate(-50%, -50%) translateY(-20px);
    }

    100% {
        transform: translate(-50%, -50%) translateY(0);
    }
}

/* Stacked Hero Layout (Global) */
.hero-content {
    display: flex;
    flex-direction: column-reverse;
    /* Visuals on top */
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 50px;
}

.hero-text {
    width: 100%;
    max-width: 800px;
    /* Limit width for readability */
    padding-right: 0;
    margin-top: 3rem;
    z-index: 2;
}

.spice-hero .hero-visual {
    margin-bottom: 2rem;
}

.subtitle {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(220, 20, 60, 0.1);
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

/* ... existing code ... */

/* Footer Responsive fixes */
@media (max-width: 992px) {
    h1 {
        font-size: 3rem;
    }

    /* Removed hero-content specific rules as they are now global */
    .features-grid {
        padding: 2rem;
        grid-template-columns: 1fr;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {

    /* ... existing mobile styles ... */
    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* Checkout Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 2000;
    display: none;
    /* Hidden by default */
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.modal-overlay.active {
    display: flex;
}

.cart-modal {
    background: white;
    width: 100%;
    max-width: 500px;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}

.close-modal {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #999;
}

.close-modal:hover {
    color: var(--primary-color);
}

/* Cart Item */
.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px dashed #eee;
}

.item-details h4 {
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.item-price {
    color: var(--primary-color);
    font-weight: 600;
}

.qty-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f5f5f5;
    padding: 5px 10px;
    border-radius: 20px;
}

.qty-btn {
    background: white;
    border: none;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    cursor: pointer;
    font-weight: 700;
    color: var(--primary-color);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Cart Summary & Footer */
.cart-summary {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 2px solid #eee;
}

.total-row {
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.checkout-btn {
    width: 100%;
    padding: 15px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-speed);
}

.checkout-btn:hover {
    background: var(--primary-dark);
}

/* Address Form */
.checkout-form {
    display: none;
}

.form-step-title {
    margin-bottom: 1.5rem;
}

.form-group.half {
    display: inline-block;
    width: 48%;
    margin-right: 2%;
}

.form-group.half:nth-child(2n) {
    margin-right: 0;
}

.checkout-form input,
.checkout-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    margin-bottom: 1rem;
}

/* Success View */
.order-success {
    display: none;
    text-align: center;
    padding: 2rem 0;
}

.success-icon {
    font-size: 4rem;
    color: #4CAF50;
    margin-bottom: 1rem;
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    from {
        transform: scale(0);
    }

    to {
        transform: scale(1);
    }
}

/* Features */
.features-section {
    padding: 3rem 0;
    background: white;
    margin-top: -50px;
    position: relative;
    z-index: 3;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    text-align: center;
    background: white;
    padding: 3rem;
    border-radius: 20px;
    box-shadow: var(--shadow-soft);
}

.feature-item i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Products Section */
.section {
    padding: 100px 5%;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.text-center {
    text-align: center;
}

.mt-3 {
    margin-top: 3rem;
}

.category-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 10px 25px;
    border: 1px solid #ddd;
    background: white;
    border-radius: 30px;
    cursor: pointer;
    font-family: var(--font-body);
    font-weight: 600;
    transition: var(--transition-speed);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.product-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    transition: var(--transition-speed);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    border: 1px solid #eee;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.product-image {
    position: relative;
    height: 250px;
    background: #f9f9f9;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.img-placeholder {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
}

.product-card:hover .img-placeholder {
    transform: scale(1.1);
}

.kashmir-chili {
    background-image: url('https://images.unsplash.com/photo-1596040033229-a9821ebd058d?ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=80');
}

.cardamom {
    background-image: url('https://images.pexels.com/photos/6086300/pexels-photo-6086300.jpeg');
}

.turmeric {
    background-image: url('https://images.pexels.com/photos/4198715/pexels-photo-4198715.jpeg');
}

.garam-masala {
    background-image: url('https://images.pexels.com/photos/3040873/pexels-photo-3040873.jpeg');
}

.badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--accent-gold);
    color: var(--black);
    padding: 5px 12px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 2;
}

.badge.new {
    background: #4CAF50;
    /* Green for new */
    color: white;
}

.add-to-cart-btn_overlay {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    color: var(--black);
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    white-space: nowrap;
}

.product-card:hover .add-to-cart-btn_overlay {
    bottom: 20px;
}

.add-to-cart-btn_overlay:hover {
    background: var(--primary-color);
    color: white;
}

.product-info {
    padding: 1.5rem;
}

.product-info h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--black);
}

.product-desc {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    color: var(--text-light);
}

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.price {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
}

.rating {
    font-size: 0.9rem;
    color: var(--accent-gold);
}

/* About Section */
.bg-light {
    background-color: var(--bg-light);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.image-placeholder.spice-market {
    height: 400px;
    background-image: url('https://images.unsplash.com/photo-1509358271058-acd22cc93898?ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=80');
    background-size: cover;
    border-radius: 20px;
}

.promise-list {
    margin-top: 2rem;
}

.promise-list li {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 600;
}

.promise-list i {
    color: #4CAF50;
}

/* Newsletter */
.newsletter-section {
    padding: 5rem 0;
    background: var(--black);
    color: white;
}

.newsletter-section h2 {
    color: white;
    margin-bottom: 1rem;
}

.newsletter-form {
    max-width: 500px;
    margin: 2rem auto 0;
    display: flex;
    gap: 10px;
}

.newsletter-form input {
    flex: 1;
    padding: 12px 20px;
    border-radius: 50px;
    border: none;
}

/* Footer */
footer {
    background-color: #111;
    color: #888;
    padding: 4rem 5% 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-col h3 {
    color: white;
    margin-bottom: 1rem;
}

.footer-col h4 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.2rem;
}

.footer-col ul li {
    margin-bottom: 0.8rem;
}

.footer-col a:hover {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 35px;
    height: 35px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: white;
}

.social-links a:hover {
    background: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid #222;
    padding-top: 2rem;
    text-align: center;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 992px) {
    h1 {
        font-size: 3rem;
    }

    .hero-content {
        flex-direction: column-reverse;
        text-align: center;
    }

    .hero-text {
        margin-top: 2rem;
    }

    .features-grid {
        padding: 2rem;
        grid-template-columns: 1fr;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    /* Mobile menu needs JS */
    .nav-icons {
        margin-right: 1rem;
    }

    .hamburger {
        display: block;
        margin-left: auto;
    }

    .cta-group {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* Auth Modal Specifics */
.auth-modal-content {
    background: white;
    width: 100%;
    max-width: 400px;
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    position: relative;
    animation: slideUp 0.3s ease;
    text-align: center;
}

.auth-form-container h2 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.auth-form-container p {
    margin-bottom: 2rem;
    font-size: 0.95rem;
}

.auth-form-container .form-group {
    text-align: left;
    margin-bottom: 1.2rem;
}

.auth-form-container label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--black);
}

.auth-form-container input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-speed);
}

.auth-form-container input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(220, 20, 60, 0.1);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1.5rem;
}

.forgot-password {
    font-size: 0.85rem;
    color: var(--primary-color);
    font-weight: 500;
}

.btn-primary.full-width {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    box-shadow: 0 4px 15px rgba(220, 20, 60, 0.2);
}

.auth-switch {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
    font-size: 0.9rem;
}

.auth-switch a {
    color: var(--primary-color);
    font-weight: 700;
}

.user-icon {
    font-size: 1.2rem;
    color: var(--black);
    transition: var(--transition-speed);
}

.user-icon:hover {
    color: var(--primary-color);
}