/* ------------------- */
/* Custom Properties   */
/* ------------------- */
:root {
    --clr-dark: #232830;
    --clr-light: #F2F5F9;
    --clr-primary: #6A5ACD; /* A modern purple */
    --clr-accent: #FFA500; /* A warm orange accent */
    --clr-white: #FFFFFF;
    
    --font-family: 'Poppins', sans-serif;
    --box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    --transition-speed: 0.3s;
}

/* ------------------- */
/* Reset & Globals     */
/* ------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-family);
    background-color: var(--clr-light);
    color: var(--clr-dark);
    line-height: 1.6;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

/* ------------------- */
/* Buttons             */
/* ------------------- */
.btn {
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    font-family: var(--font-family);
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
}

.btn-primary {
    background-color: var(--clr-primary);
    color: var(--clr-white);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(106, 90, 205, 0.4);
}

.btn-accent {
    background-color: var(--clr-accent);
    color: var(--clr-dark);
}

.btn-accent:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(255, 165, 0, 0.4);
}

/* ------------------- */
/* Header & Navigation */
/* ------------------- */
#main-header {
    background-color: var(--clr-white);
    box-shadow: var(--box-shadow);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

#main-header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--clr-primary);
    text-decoration: none;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--clr-dark);
    font-weight: 500;
    transition: color var(--transition-speed) ease;
}

.nav-links a:hover {
    color: var(--clr-primary);
}

/* ------------------- */
/* Main Content        */
/* ------------------- */
main {
    padding: 2rem 0;
}

#hero {
    text-align: center;
    padding: 4rem 0;
}

#hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

#products-section {
    padding: 4rem 0;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
}

/* ------------------- */
/* Product Card        */
/* ------------------- */
.product-card {
    background-color: var(--clr-white);
    border-radius: 15px;
    box-shadow: var(--box-shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
    opacity: 0; /* Initially hidden for fade-in animation */
    transform: translateY(20px); /* Start slightly lower for animation */
    animation: fadeIn 0.5s ease forwards;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.product-image-container {
    width: 100%;
    padding-top: 100%; /* Creates a square aspect ratio */
    position: relative;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures the image covers the container without distortion */
}

.product-info {
    padding: 1.5rem;
    text-align: left;
    flex-grow: 1; /* Pushes the button to the bottom */
}

.product-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.product-price {
    font-size: 1.1rem;
    color: var(--clr-primary);
    font-weight: 700;
}

.product-card .add-to-cart-btn {
    width: 100%;
    border-radius: 0 0 15px 15px; /* Match card corners */
    padding: 1rem;
}

/* ------------------- */
/* Animations          */
/* ------------------- */
@keyframes fadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Add animation delay to each card for a staggered effect */
.product-card:nth-child(1) { animation-delay: 0.1s; }
.product-card:nth-child(2) { animation-delay: 0.2s; }
.product-card:nth-child(3) { animation-delay: 0.3s; }
.product-card:nth-child(4) { animation-delay: 0.4s; }


/* ------------------- */
/* Footer              */
/* ------------------- */
#main-footer {
    background-color: var(--clr-dark);
    color: var(--clr-light);
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
}

/* css/style.css (Add this to the bottom) */

/* ------------------- */
/* Utility Classes     */
/* ------------------- */
.hidden {
    display: none !important;
}

/* ------------------- */
/* Secondary Button    */
/* ------------------- */
.btn-secondary {
    background-color: #6c757d;
    color: var(--clr-white);
}
.btn-secondary:hover {
    background-color: #5a6268;
}

.btn-danger {
    background-color: #dc3545;
    color: var(--clr-white);
}

/* ------------------- */
/* User Profile        */
/* ------------------- */
#user-profile {
    display: flex;
    align-items: center;
    gap: 1rem;
}

#user-profile span {
    font-weight: 500;
}

/* ------------------- */
/* Auth Modal          */
/* ------------------- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* JS will remove .hidden, making it visible */
.modal-overlay:not(.hidden) {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: var(--clr-white);
    padding: 2.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    width: 90%;
    max-width: 450px;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay:not(.hidden) .modal-content {
    transform: scale(1);
}

.modal-close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    background: none;
    border: none;
    font-size: 2rem;
    color: #aaa;
    cursor: pointer;
}

/* ------------------- */
/* Auth Forms          */
/* ------------------- */
.auth-forms h2 {
    text-align: center;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    font-family: var(--font-family);
}

.form-error {
    color: #dc3545;
    margin-bottom: 1rem;
    text-align: center;
    min-height: 1.2em;
}

.form-switcher {
    text-align: center;
    margin-top: 1.5rem;
}

.form-switcher a {
    color: var(--clr-primary);
    font-weight: 500;
    text-decoration: none;
}

/* ------------------- */
/* Cart Page Styles    */
/* ------------------- */
#cart-section {
    padding: 6rem 0;
    max-width: 900px;
    margin: 0 auto;
}

.cart-item {
    display: grid;
    grid-template-columns: 100px 1fr auto; 
    align-items: center;
    gap: 1.5rem;
    background: var(--clr-white);
    padding: 1.5rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    margin-bottom: 1.5rem;
}

.cart-item-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: var(--border-radius);
}

.cart-item-details {
    flex-grow: 1;
}

.cart-item-name {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 600;
}

.cart-item-price {
    color: var(--clr-gray);
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cart-item-quantity {
    width: 60px;
    padding: 0.5rem;
    text-align: center;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    -moz-appearance: textfield; 
}
.cart-item-quantity::-webkit-outer-spin-button,
.cart-item-quantity::-webkit-inner-spin-button {
    -webkit-appearance: none; 
    margin: 0;
}

.remove-item-btn {
    background-color: #fee2e2;
    color: #ef4444;
    border: none;
    padding: 0.6rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    display: inline-flex; /* Use flex to align text and icon */
    align-items: center;
    gap: 0.5rem; /* Space between text and icon */
}
.remove-item-btn:hover {
    background-color: #ef4444;
    color: var(--clr-white);
}
.remove-item-btn .remove-text {
    display: inline;
}

#cart-summary {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
    text-align: right;
}

.cart-total {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
}
/* css/style.css (Add this to the bottom) */

/* ------------------- */
/* Checkout Page       */
/* ------------------- */
#checkout-section {
    padding: 4rem 0;
}

.checkout-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: flex-start;
}

.order-summary, .shipping-info {
    background-color: var(--clr-white);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: var(--box-shadow);
}

.order-summary h2, .shipping-info h2 {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 1rem;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.summary-total {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
    font-size: 1.5rem;
    display: flex;
    justify-content: space-between;
}

.btn-full {
    width: 100%;
    padding: 1rem;
    font-size: 1.1rem;
    margin-top: 1rem;
}

/* Responsive adjustments for checkout */
@media (max-width: 768px) {
    .checkout-layout {
        grid-template-columns: 1fr;
    }
}

/* ------------------- */
/* Thank You Page      */
/* ------------------- */
#thank-you-section {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 6rem 0;
}

.thank-you-content h1 {
    font-size: 3.5rem;
    color: var(--clr-primary);
    margin-bottom: 1rem;
}

.thank-you-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}
/* ------------------- */
/* Orders Page         */
/* ------------------- */
#orders-section {
    padding: 4rem 0;
}

.order-card {
    background: var(--clr-white);
    border-radius: 10px;
    box-shadow: var(--box-shadow);
    margin-bottom: 2rem;
    padding: 1.5rem;
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #eee;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}

.order-id {
    font-size: 1.1rem;
}
.order-id span {
    font-family: monospace;
    font-size: 0.9rem;
}

.order-date {
    font-size: 0.9rem;
    color: #6c757d;
}

.order-total {
    font-size: 1.3rem;
    font-weight: 600;
}

.order-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.5rem 0;
}

.order-item-image {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 5px;
}

:root {
    --clr-primary: #7C5CFA;
    --clr-primary-dark: #6A4DE8;
    --clr-primary-light: #9A7EFF;
    --clr-secondary: #FF9F66;
    --clr-accent: #4CD7F6;
    --clr-dark: #1A1D2B;
    --clr-dark-light: #2A2F45;
    --clr-light: #F8FAFC;
    --clr-gray: #94A3B8;
    --clr-white: #FFFFFF;
    
    --gradient-primary: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-primary-light) 100%);
    --gradient-secondary: linear-gradient(135deg, var(--clr-secondary) 0%, #FF7B54 100%);
    
    --shadow-sm: 0 4px 6px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 25px 50px rgba(0, 0, 0, 0.25);
    
    --border-radius: 12px;
    --border-radius-lg: 20px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    
    --font-body: 'Inter', sans-serif;
    --font-heading: 'Playfair Display', serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-body);
    background-color: var(--clr-light);
    color: var(--clr-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 { font-family: var(--font-heading); font-weight: 700; line-height: 1.2; }
.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 1.5rem; }
a { text-decoration: none; }

/* --- Header --- */
#main-header {
    position: fixed; top: 0; left: 0; width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000; padding: 1rem 0;
    transition: var(--transition);
}
#main-header.scrolled { padding: 0.75rem 0; box-shadow: var(--shadow-md); }
#main-header nav { display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 1.75rem; font-weight: 800; color: var(--clr-primary); display: flex; align-items: center; gap: 0.5rem; }
.logo::before { content: "✨"; }
.nav-links { display: flex; list-style: none; gap: 2rem; }
.nav-links a { color: var(--clr-dark); font-weight: 500; transition: var(--transition); position: relative; }
.nav-links a:after { content: ''; position: absolute; bottom: -5px; left: 0; width: 0; height: 2px; background: var(--gradient-primary); transition: var(--transition); }
.nav-links a:hover:after { width: 100%; }
.nav-links a:hover { color: var(--clr-primary); }

/* --- Buttons --- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.75rem 1.75rem; border-radius: var(--border-radius); font-weight: 600; font-size: 1rem; cursor: pointer; transition: var(--transition); border: none; outline: none; position: relative; overflow: hidden; }
.btn:before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent); transition: var(--transition-slow); }
.btn:hover:before { left: 100%; }
.btn-primary { background: var(--gradient-primary); color: var(--clr-white); box-shadow: 0 10px 20px rgba(124, 92, 250, 0.3); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 15px 30px rgba(124, 92, 250, 0.4); }
.btn-secondary { background: var(--clr-dark-light); color: var(--clr-white); }
.btn-secondary:hover { background: var(--clr-dark); transform: translateY(-3px); }

/* --- Hero Section --- */
#hero { min-height: 100vh; display: flex; align-items: center; position: relative; padding-top: 5rem; overflow: hidden; background: url('https://images.unsplash.com/photo-1607083206968-13611e3d76db?auto=format&fit=crop&q=80&w=1920') no-repeat center center/cover; }
#hero:after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(90deg, var(--clr-light) 40%, rgba(248, 250, 252, 0.8) 60%, transparent 100%); }
.hero-content { max-width: 50%; padding: 2rem 0; z-index: 2; position: relative; }
.hero-content h1 { font-size: 3.5rem; margin-bottom: 1.5rem; background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-content p { font-size: 1.25rem; color: var(--clr-dark-light); margin-bottom: 2.5rem; line-height: 1.8; }
.hero-cta { padding: 1rem 2.5rem; font-size: 1.1rem; }
.hero-stats { display: flex; gap: 2rem; margin-top: 3rem; }
.stat-item { display: flex; flex-direction: column; }
.stat-value { font-size: 2.5rem; font-weight: 800; background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.stat-label { font-size: 0.9rem; color: var(--clr-gray); text-transform: uppercase; letter-spacing: 1px; }

/* --- Products Section --- */
#products-section { padding: 6rem 0; }
.section-title { text-align: center; font-size: 2.5rem; margin-bottom: 3rem; position: relative; padding-bottom: 1rem; }
.section-title:after { content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 80px; height: 4px; background: var(--gradient-primary); border-radius: 2px; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 2.5rem; margin-top: 3rem; }
.product-card { background: var(--clr-white); border-radius: var(--border-radius-lg); overflow: hidden; box-shadow: var(--shadow-md); transition: var(--transition); position: relative; }
.product-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-xl); }
.product-image-container { position: relative; width: 100%; padding-top: 100%; overflow: hidden; }
.product-image { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; transition: var(--transition-slow); }
.product-card:hover .product-image { transform: scale(1.05); }
.product-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(transparent 60%, rgba(0, 0, 0, 0.7)); opacity: 0; transition: var(--transition); display: flex; align-items: flex-end; justify-content: center; padding: 1.5rem; }
.product-card:hover .product-overlay { opacity: 1; }
.product-actions { display: flex; gap: 0.5rem; transform: translateY(20px); transition: var(--transition); }
.product-card:hover .product-actions { transform: translateY(0); }
.action-btn { width: 40px; height: 40px; border-radius: 50%; background: var(--clr-white); color: var(--clr-dark); display: flex; align-items: center; justify-content: center; border: none; cursor: pointer; transition: var(--transition); box-shadow: var(--shadow-md); }
.action-btn:hover { background: var(--clr-primary); color: var(--clr-white); transform: translateY(-3px); }
.product-info { padding: 1.5rem; }
.product-name { font-size: 1.25rem; margin-bottom: 0.5rem; font-weight: 600; }
.product-price { font-size: 1.5rem; font-weight: 700; color: var(--clr-primary); }
.product-rating { display: flex; align-items: center; gap: 0.25rem; margin-bottom: 0.5rem; }
.product-rating i { color: #FFD700; font-size: 0.9rem; }
.product-rating span { font-size: 0.9rem; color: var(--clr-gray); margin-left: 0.5rem; }

/* --- About & Footer & Other Sections from your design --- */
/* In style.css, find and replace the existing #about section styles */

#about {
    padding: 6rem 0;
    background: var(--gradient-dark);
    color: var(--clr-dark); /* This will now work correctly on the dark background */
    position: relative;
    overflow: hidden;
}
.about-content { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; position: relative; z-index: 2; }
.about-image img { width: 100%; border-radius: var(--border-radius-lg); box-shadow: var(--shadow-xl); }
.features { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 2rem; }
.feature { display: flex; flex-direction: column; align-items: flex-start; }
.feature-icon { width: 60px; height: 60px; border-radius: 50%; background: rgba(255, 255, 255, 0.1); display: flex; align-items: center; justify-content: center; margin-bottom: 1rem; font-size: 1.5rem; color: var(--clr-primary-light); }
#newsletter { padding: 6rem 0; background: var(--clr-white); }
.newsletter-content { max-width: 600px; margin: 0 auto; text-align: center; }
#newsletter-form { display: flex; gap: 1rem; margin-top: 2rem; }
#newsletter-form input { flex: 1; padding: 1rem 1.5rem; border: 1px solid #E2E8F0; border-radius: var(--border-radius); font-size: 1rem; transition: var(--transition); }
#newsletter-form input:focus { outline: none; border-color: var(--clr-primary); box-shadow: 0 0 0 3px rgba(124, 92, 250, 0.2); }
#main-footer { background: var(--clr-dark); color: var(--clr-white); padding: 4rem 0 2rem; }
.footer-content { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 3rem; margin-bottom: 3rem; }
.footer-section h4 { font-size: 1.2rem; margin-bottom: 1.5rem; color: var(--clr-white); }
.footer-section ul { list-style: none; }
.footer-section li { margin-bottom: 0.75rem; }
.footer-section a { color: var(--clr-gray); transition: var(--transition); }
.footer-section a:hover { color: var(--clr-primary-light); }
.social-links { display: flex; gap: 1rem; }
.social-links a { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--clr-dark-light); color: var(--clr-white); transition: var(--transition); }
.social-links a:hover { background: var(--clr-primary); transform: translateY(-3px); }
.footer-bottom { border-top: 1px solid var(--clr-dark-light); padding-top: 2rem; text-align: center; opacity: 0.7; }

/* --- Utility & Animation Classes --- */
.hidden { display: none !important; }
.loading-spinner { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: var(--clr-light); display: flex; justify-content: center; align-items: center; z-index: 9999; transition: opacity 0.5s ease; }
.spinner { width: 50px; height: 50px; border: 5px solid rgba(124, 92, 250, 0.2); border-radius: 50%; border-top-color: var(--clr-primary); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.fade-in { animation: fadeIn 1s ease forwards; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.slide-in-left { animation: slideInLeft 1s ease forwards; }
@keyframes slideInLeft { from { opacity: 0; transform: translateX(-50px); } to { opacity: 1; transform: translateX(0); } }
.slide-in-right { animation: slideInRight 1s ease forwards; }
@keyframes slideInRight { from { opacity: 0; transform: translateX(50px); } to { opacity: 1; transform: translateX(0); } }

/* --- Mobile Menu --- */
.mobile-menu-btn { display: none; background: none; border: none; font-size: 1.5rem; color: var(--clr-dark); cursor: pointer; z-index: 1001; }
@media (max-width: 768px) {
    .nav-links { display: none; }
    .mobile-menu-btn { display: block; }
    #hero:after { background: linear-gradient(90deg, var(--clr-light) 70%, rgba(248, 250, 252, 0.8) 85%, transparent 100%); }
    .hero-content { max-width: 100%; text-align: center; }
    .hero-stats { justify-content: center; }
    .about-content { grid-template-columns: 1fr; }
    #newsletter-form { flex-direction: column; }
}

/* Auth Modal Styles (Copied from previous version) */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.6); display: flex; justify-content: center; align-items: center; z-index: 2000; opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; }
.modal-overlay:not(.hidden) { opacity: 1; visibility: visible; }
.modal-content { background-color: var(--clr-white); padding: 2.5rem; border-radius: 15px; box-shadow: var(--shadow-lg); width: 90%; max-width: 450px; position: relative; transform: scale(0.9); transition: transform 0.3s ease; }
.modal-overlay:not(.hidden) .modal-content { transform: scale(1); }
.modal-close-btn { position: absolute; top: 15px; right: 20px; background: none; border: none; font-size: 2rem; color: #aaa; cursor: pointer; }
.auth-forms h2 { text-align: center; margin-bottom: 1.5rem; font-family: var(--font-heading); }
.form-group { margin-bottom: 1.2rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 500; }
.form-group input { width: 100%; padding: 0.8rem; border: 1px solid #ccc; border-radius: 8px; font-size: 1rem; font-family: var(--font-body); }
.form-error { color: #dc3545; margin-bottom: 1rem; text-align: center; min-height: 1.2em; }
.form-switcher { text-align: center; margin-top: 1.5rem; }
.form-switcher a { color: var(--clr-primary); font-weight: 500; }
/* Add this to style.css */

html {
    height: 100%;
}

body {
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

main {
    flex-grow: 1; /* This is the key part that pushes the footer down */
}
/* Add this to the bottom of style.css */

/* --- Mobile Menu & Responsive Header --- */
.mobile-menu-btn {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--clr-dark);
    cursor: pointer;
    z-index: 1001;
}

@media (max-width: 768px) {
    .nav-links {
        display: none; /* Hide the desktop nav links */
    }

    .nav-link-item {
        display: none; /* Hide the "My Orders" link in the user profile on mobile */
    }

    .mobile-menu-btn {
        display: block; /* Show the hamburger button */
    }

    .nav-menu.active .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 60px; /* Adjust as needed */
        right: 1.5rem;
        background: var(--clr-white);
        box-shadow: var(--shadow-lg);
        border-radius: var(--border-radius);
        padding: 1rem;
        gap: 1rem;
        animation: fadeIn 0.3s ease;
    }
}:root {
    --clr-primary: #7C5CFA;
    --clr-primary-dark: #6A4DE8;
    --clr-primary-light: #9A7EFF;
    --clr-secondary: #FF9F66;
    --clr-dark: #1A1D2B;
    --clr-dark-light: #2A2F45;
    --clr-light: #F8FAFC;
    --clr-gray: #94A3B8;
    --clr-white: #FFFFFF;
    
    --gradient-primary: linear-gradient(135deg, var(--clr-primary) 0%, var(--clr-primary-light) 100%);
    --gradient-dark: linear-gradient(135deg, var(--clr-dark) 0%, #2D3748 100%);
    
    --shadow-md: 0 10px 15px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 25px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 25px 50px rgba(0, 0, 0, 0.25);
    
    --border-radius: 12px;
    --border-radius-lg: 20px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    
    --font-body: 'Inter', sans-serif;
    --font-heading: 'Playfair Display', serif;
}

/* --- Global Reset & Sticky Footer Setup --- */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { height: 100%; }
body {
    font-family: var(--font-body);
    background-color: var(--clr-light);
    color: var(--clr-dark);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100%;
    display: flex;
    flex-direction: column;
}
main {
    flex-grow: 1;
}
.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 1.5rem; }
h1, h2, h3 { font-family: var(--font-heading); font-weight: 700; line-height: 1.2; }
a { text-decoration: none; }
.hidden { display: none !important; }

/* --- Header & Navigation --- */
#main-header { position: sticky; top: 0; width: 100%; background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(10px); z-index: 1000; padding: 1rem 0; transition: var(--transition); border-bottom: 1px solid #eee; }
#main-header.scrolled { box-shadow: var(--shadow-md); }
#main-header nav { display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 1.75rem; font-weight: 800; color: var(--clr-primary); display: flex; align-items: center; gap: 0.5rem; }
.logo::before { content: "✨"; }
.nav-menu { position: relative; }
.nav-links { display: flex; list-style: none; gap: 2rem; align-items: center; padding-left: 0; }
.nav-links a { color: var(--clr-dark); font-weight: 500; transition: var(--transition); }
.nav-links a:hover, .nav-links a.active-link { color: var(--clr-primary); }
#auth-container { display: flex; align-items: center; gap: 1rem; }
#user-profile { display: flex; align-items: center; gap: 1rem; }
#user-profile span { font-weight: 600; }
#user-profile .nav-link-item { color: var(--clr-dark); font-weight: 500; text-decoration: none; }
#user-profile .nav-link-item:hover { color: var(--clr-primary); }

/* --- Buttons --- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 0.75rem 1.5rem; border-radius: var(--border-radius); font-weight: 600; font-size: 1rem; cursor: pointer; transition: var(--transition); border: none; outline: none; }
.btn-primary { background: var(--gradient-primary); color: var(--clr-white); box-shadow: 0 10px 20px rgba(124, 92, 250, 0.3); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 15px 30px rgba(124, 92, 250, 0.4); }
.btn-secondary { background: var(--clr-dark-light); color: var(--clr-white); }
.btn-secondary:hover { background: var(--clr-dark); transform: translateY(-3px); }

/* --- Hero Section --- */
#hero { min-height: 90vh; display: flex; align-items: center; position: relative; padding-top: 5rem; overflow: hidden; background: url('https://images.unsplash.com/photo-1607083206968-13611e3d76db?auto=format&fit=crop&q=80&w=1920') no-repeat center center/cover; }
#hero:after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(90deg, var(--clr-light) 40%, rgba(248, 250, 252, 0.8) 60%, transparent 100%); }
.hero-content { max-width: 50%; padding: 2rem 0; z-index: 2; position: relative; }
.hero-content h1 { font-size: 3.5rem; margin-bottom: 1.5rem; background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.hero-content p { font-size: 1.25rem; color: var(--clr-dark-light); margin-bottom: 2.5rem; line-height: 1.8; }
.hero-cta { padding: 1rem 2.5rem; font-size: 1.1rem; }
.hero-stats { display: flex; gap: 2rem; margin-top: 3rem; }
.stat-item { display: flex; flex-direction: column; }
.stat-value { font-size: 2.5rem; font-weight: 800; background: var(--gradient-primary); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.stat-label { font-size: 0.9rem; color: var(--clr-gray); text-transform: uppercase; letter-spacing: 1px; }

/* --- Products Section --- */
#products-section { padding: 6rem 0; }
.section-title { text-align: center; font-size: 2.5rem; margin-bottom: 3rem; position: relative; padding-bottom: 1rem; }
.section-title:after { content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: 80px; height: 4px; background: var(--gradient-primary); border-radius: 2px; }
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 2.5rem; margin-top: 3rem; }
.product-card { background: var(--clr-white); border-radius: var(--border-radius-lg); overflow: hidden; box-shadow: var(--shadow-md); transition: var(--transition); position: relative; }
.product-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-xl); }
.product-image-container { position: relative; width: 100%; padding-top: 100%; overflow: hidden; }
.product-image { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; transition: var(--transition-slow); }
.product-card:hover .product-image { transform: scale(1.05); }
.product-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(transparent 60%, rgba(0, 0, 0, 0.7)); opacity: 0; transition: var(--transition); display: flex; align-items: flex-end; justify-content: center; padding: 1.5rem; }
.product-card:hover .product-overlay { opacity: 1; }
.product-actions { display: flex; gap: 0.5rem; transform: translateY(20px); transition: var(--transition); }
.product-card:hover .product-actions { transform: translateY(0); }
.action-btn { width: 40px; height: 40px; border-radius: 50%; background: var(--clr-white); color: var(--clr-dark); display: flex; align-items: center; justify-content: center; border: none; cursor: pointer; transition: var(--transition); box-shadow: var(--shadow-md); }
.action-btn i { pointer-events: none; }
.action-btn:hover { background: var(--clr-primary); color: var(--clr-white); transform: translateY(-3px); }
.product-info { padding: 1.5rem; }
.product-name { font-size: 1.25rem; margin-bottom: 0.5rem; font-weight: 600; }
.product-price { font-size: 1.5rem; font-weight: 700; color: var(--clr-primary); }

/* --- About Section --- */
#about { padding: 6rem 0; background: var(--gradient-dark); color: var(--clr-white); position: relative; overflow: hidden; }
.about-content { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; position: relative; z-index: 2; }
.about-text h2 { font-size: 2.5rem; margin-bottom: 1.5rem; }
.about-text p { font-size: 1.1rem; line-height: 1.8; margin-bottom: 2rem; opacity: 0.9; }
.about-image img { width: 100%; border-radius: var(--border-radius-lg); box-shadow: var(--shadow-xl); }
.features { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 2rem; }
.feature { display: flex; flex-direction: column; align-items: flex-start; }
.feature-icon { width: 60px; height: 60px; border-radius: 50%; background: rgba(255, 255, 255, 0.1); display: flex; align-items: center; justify-content: center; margin-bottom: 1rem; font-size: 1.5rem; color: var(--clr-primary-light); }
.feature h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }
.feature p { font-size: 0.9rem; opacity: 0.8; margin-bottom: 0; }

/* --- Other Sections (Newsletter, Footer, Modals, etc.) --- */
#newsletter { padding: 6rem 0; background: var(--clr-white); }
.newsletter-content { max-width: 600px; margin: 0 auto; text-align: center; }
#newsletter-form { display: flex; gap: 1rem; margin-top: 2rem; }
#newsletter-form input { flex: 1; padding: 1rem 1.5rem; border: 1px solid #E2E8F0; border-radius: var(--border-radius); font-size: 1rem; transition: var(--transition); }
#newsletter-form input:focus { outline: none; border-color: var(--clr-primary); box-shadow: 0 0 0 3px rgba(124, 92, 250, 0.2); }
#main-footer { background: var(--clr-dark); color: var(--clr-white); padding: 4rem 0 2rem; }
.footer-content { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 3rem; margin-bottom: 3rem; }
.footer-section h4 { font-size: 1.2rem; margin-bottom: 1.5rem; color: var(--clr-white); }
.footer-section ul { list-style: none; padding-left: 0; }
.footer-section li { margin-bottom: 0.75rem; }
.footer-section a { color: var(--clr-gray); transition: var(--transition); }
.footer-section a:hover { color: var(--clr-primary-light); }
.social-links { display: flex; gap: 1rem; }
.social-links a { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--clr-dark-light); color: var(--clr-white); transition: var(--transition); }
.social-links a:hover { background: var(--clr-primary); transform: translateY(-3px); }
.footer-bottom { border-top: 1px solid var(--clr-dark-light); padding-top: 2rem; text-align: center; opacity: 0.7; }
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.6); display: flex; justify-content: center; align-items: center; z-index: 2000; opacity: 0; visibility: hidden; transition: opacity 0.3s ease, visibility 0.3s ease; }
.modal-overlay:not(.hidden) { opacity: 1; visibility: visible; }
.modal-content { background-color: var(--clr-white); padding: 2.5rem; border-radius: 15px; box-shadow: var(--shadow-lg); width: 90%; max-width: 450px; position: relative; transform: scale(0.9); transition: transform 0.3s ease; }
.modal-overlay:not(.hidden) .modal-content { transform: scale(1); }
.modal-close-btn { position: absolute; top: 15px; right: 20px; background: none; border: none; font-size: 2rem; color: #aaa; cursor: pointer; }
.auth-forms h2 { text-align: center; margin-bottom: 1.5rem; }
.form-group { margin-bottom: 1.2rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 500; }
.form-group input { width: 100%; padding: 0.8rem; border: 1px solid #ccc; border-radius: 8px; font-size: 1rem; }
.form-error { color: #dc3545; margin-bottom: 1rem; text-align: center; min-height: 1.2em; }
.form-switcher { text-align: center; margin-top: 1.5rem; }
.form-switcher a { color: var(--clr-primary); font-weight: 500; }
#cart-section, #orders-section, #checkout-section, #admin-section, #thank-you-section { padding: 6rem 2rem; }

/* --- Loading Spinner & Animations --- */
.loading-spinner { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: var(--clr-light); display: flex; justify-content: center; align-items: center; z-index: 9999; transition: opacity 0.5s ease; }
.spinner { width: 50px; height: 50px; border: 5px solid rgba(124, 92, 250, 0.2); border-radius: 50%; border-top-color: var(--clr-primary); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.slide-in-left { animation: slideInLeft 1s ease forwards; }
@keyframes slideInLeft { from { opacity: 0; transform: translateX(-50px); } to { opacity: 1; transform: translateX(0); } }
.slide-in-right { animation: slideInRight 1s ease forwards; }
@keyframes slideInRight { from { opacity: 0; transform: translateX(50px); } to { opacity: 1; transform: translateX(0); } }

/* --- Responsive Design & Mobile Menu --- */
.mobile-menu-btn { display: none; background: none; border: none; font-size: 1.5rem; color: var(--clr-dark); cursor: pointer; z-index: 1002; }

@media (max-width: 820px) {
    .nav-menu > .nav-links { display: none; }
    .mobile-menu-btn { display: block; }
    #user-profile .nav-link-item { display: none; }
    .hero-content { max-width: 100%; text-align: center; }
    .hero-stats { justify-content: center; }
    .about-content { grid-template-columns: 1fr; }
    #newsletter-form { flex-direction: column; }
    .footer-content { grid-template-columns: 1fr; }

    .nav-menu.active > .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 65px;
        right: 1.5rem;
        background: var(--clr-white);
        box-shadow: var(--shadow-lg);
        border-radius: var(--border-radius);
        padding: 1rem;
        gap: 1rem;
        width: 200px;
        align-items: flex-start;
        animation: fadeIn 0.2s ease;
    }
    #mobile-orders-link.visible-in-mobile {
        display: block !important;
    }
}
/* --- Search Bar --- */
.search-container {
    position: relative;
    margin-bottom: 3rem;
    margin-top: 2rem; 
}
#search-input {
    width: 100%;
    padding: 1rem 1rem 1rem 3.5rem; 
    font-size: 1.1rem;
    border-radius: var(--border-radius);
    border: 1px solid #E2E8F0;
    font-family: var(--font-body);
    transition: var(--transition);
}
#search-input:focus {
    outline: none;
    border-color: var(--clr-primary);
    box-shadow: 0 0 0 4px rgba(124, 92, 250, 0.2);
}
.search-icon {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--clr-gray);
    font-size: 1.2rem;
}
/* --- Toast Notifications --- */
#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.toast {
    background: var(--clr-dark);
    color: var(--clr-white);
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transform: translateX(100%);
    animation: slideInAndOut 4s ease forwards;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.toast.success {
    background: #28a745; /* Green */
}
.toast.error {
    background: #dc3545; /* Red */
}
@keyframes slideInAndOut {
    0% { opacity: 0; transform: translateX(100%); }
    15% { opacity: 1; transform: translateX(0); }
    85% { opacity: 1; transform: translateX(0); }
    100% { opacity: 0; transform: translateX(100%); }
}

/* --- Wishlist Button --- */
.action-btn.wishlist-btn.active {
    background-color: #ef4444; /* A nice red color */
    color: var(--clr-white);
}

/* Add this to the bottom of style.css */

@media (max-width: 768px) {
    #cart-summary .btn {
        padding: 0.8rem 1rem;
        font-size: 1rem;
        width: 100%; /* Make it full-width for a better mobile layout */
    }
}

/* --- Mobile-specific Cart Button Icon --- */
@media (max-width: 768px) {
    .remove-item-btn {
        width: 40px;
        height: 40px;
        border-radius: 50%; /* Make it a circle */
        padding: 0;
        justify-content: center;
        gap: 0;
    }
    .remove-item-btn .remove-text {
        display: none;
    }
}

    .remove-item-btn::before {
        content: "\f2ed"; 
        font-family: "Font Awesome 6 Free"; 
        font-weight: 900; 
        font-size: 1rem;
        color: #ef4444; 
    
    .remove-item-btn:hover::before {
        color: var(--clr-white); 
    }
}

/* new one */

/* --- Admin Dashboard Enhancements --- */
.admin-card {
    background: var(--clr-white);
    padding: 2rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
}
.manage-product-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid #eee;
}
.manage-product-item:last-child {
    border-bottom: none;
}
.manage-product-details {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.manage-product-image {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    object-fit: cover;
}
.manage-product-actions {
    display: flex;
    gap: 0.5rem;
}
.btn-edit {
    background-color: var(--clr-accent);
    color: var(--clr-white);
}
.btn-delete {
    background-color: #dc3545;
    color: var(--clr-white);
}


/* --- Checkout Page Payment Method Alignment --- */
.payment-method-selector .form-group {
    display: flex;       
    align-items: center;
    gap: 10px;          
    margin-bottom: 10px; 
}

.payment-method-selector label {
    margin-bottom: 0;    
    font-weight: normal;
}

.payment-method-selector input[type="radio"] {
    
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color); 
    cursor: pointer;
}
