/* ---------- THEME COLORS ---------- */
:root {
    --dark-card-bg: #ffffff;
    --text-light: #000000;
    --accent-silver: #C0C0C0;
    --glow-shadow: 0 0 8px #C0C0C0, 0 0 16px #C0C0C0, 0 0 24px #C0C0C0;
    --highlight-blue: #1E3A8A;
    --green-dark: #0F3D2E;
}

/* ---------- GLOBAL ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}
body {
    background: var(--dark-card-bg);
    color: white;
    scroll-behavior: smooth;
    line-height: 1.6;
}

/* ---------- NAVBAR ---------- */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 30px;
    background: #66996f;
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 5px 5px rgba(192, 192, 192, 0.25);
}
nav .logo img {
    height: 80px;
    width: auto;
    border-radius: 14px;
    object-fit: cover;
    padding: 4px;
    transition: all 0.35s ease-in-out;
}
nav .logo img:hover {
    transform: scale(1.1) rotate(-2deg);
    border-radius: 18px;
}
.nav-links a {
    color: white;
    padding: 8px 14px;
    border-radius: 25px;
    font-weight: 500;
    transition: 0.3s;
    text-decoration: none !important;
}
.nav-links a:hover {
    background: rgba(30, 58, 138, 0.15);
    color: var(--text-light);
}
.nav-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

/* ---------- SEARCH BOX ---------- */
.nav-search {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #0F3D2E;
    padding: 5px 10px;
    border-radius: 25px;
    transition: 0.3s;
}
.nav-search:hover {
    box-shadow: 0 5px 15px rgba(30, 58, 138, 0.15);
}
.nav-search input {
    border: none;
    outline: none;
    font-size: 0.9rem;
    padding: 6px 10px;
    width: 180px;
    border-radius: 25px;
    background: white;
}
.nav-search button {
    background: #0F3D2E;
    border: none;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

/* ---------- SHOP HEADER ---------- */
.shop-header {
    text-align: center;
    padding: 20px 20px 30px;
    background-color: #599664;
    margin-top: 10px;
    border-radius: 35px;
}
.shop-header h1 {
    font-size: 2.8rem;
    color: white;
    margin-bottom: 10px;
    animation: fadeUp 1s ease forwards;
}
.shop-header p {
    color: white;
    font-size: 1rem;
    animation: fadeUp 1s 0.3s ease forwards;
    opacity: 0;
}

/* ---------- FILTER BUTTONS ---------- */
.filter-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 25px auto;
    flex-wrap: wrap;
}
.filter-buttons button {
    background: #ffffff;
    color: #000000;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.3s;
    position: relative;
    overflow: hidden;
}
.filter-buttons button.active,
.filter-buttons button:hover {
    background: #e9c3c3;
}
.filter-buttons button::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,0.15);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}
.filter-buttons button:hover::after {
    transform: scaleX(1);
}

/* ---------- BADGES ---------- */
.badge {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 10px 18px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.8rem;
    background: var(--green-dark);
    color: #ffffff;
    background-size: 400% 400%;
    animation: gradientShift 3s ease infinite, fadeIn 1s ease forwards;
}
.badge.soldout {
    background: #555;
    text-transform: uppercase;
}

/* ---------- PRODUCTS SECTION ---------- */
.products {
    padding: 50px 25px;
    text-align: center;
    width: 100%;
    max-width: 1300px;
    margin: auto;
}
.products h2 {
    font-size: 2rem;
    margin-bottom: 40px;
}

/* ---------- PRODUCT GRID ---------- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 300px)); /* max width for single card */
    justify-content: center; /* center single product */
    gap: 25px;
    margin: auto;
}

/* ---------- PRODUCT CARD ---------- */
.product-card {
    background: var(--dark-card-bg);
    border-radius: 15px;
    border: 1px solid #ddd;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    width: 100%; /* will respect grid minmax */
    transition: 0.3s;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.15);
}

/* ---------- IMAGE CONTAINER ---------- */
.image-container {
    width: 100%;
    aspect-ratio: 4/3; /* maintains height automatically */
    overflow: hidden;
    background-color: #f5f5f5;
    display: flex;
    justify-content: center;
    align-items: center;
}
.image-container img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* cover → cut hoti thi, contain → full dikhegi */
    object-position: cover;
}

/* ---------- PRODUCT INFO ---------- */
.product-info {
    flex: 1;
    padding: 15px 18px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.product-info h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #000000;
    text-align: left;
}
.product-info p {
    font-weight: bold;
    font-size: 0.9rem;
    color: #000000;
    line-height: 1.3;
    text-align: left;
}
.price {
    color: #000000;
    margin-top: 8px;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
}
.original-price {
    text-decoration: line-through;
    margin-right: 5px;
    color: #8d8d8d;
}
.discounted-price {
    font-weight: 700;
    text-align: left;
    color: #000000;
}
.product-info button {
    margin-top: auto;   /* 🔥 MAIN FIX */
    width: 100%;
    padding: 12px;
    border: none;
    background: var(--green-dark);
    color: #ffffff;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s ease;
}

.product-info button:hover {
    background: #0c2f23;
}


/* ---------- CART ICON & BADGE ---------- */
.cart-icon {
    position: relative;
    display: inline-block;
    font-size: 1.5rem;
    color: var(--highlight-blue);
}
.cart-badge { 
    position: absolute; 
    top: -10px; 
    right: -10px; 
    background: black; 
    color: #fff; 
    font-size: 0.75rem; 
    font-weight: 700; 
    padding: 3px 7px; 
    border-radius: 50%; 
    box-shadow: 0 2px 6px rgba(0,0,0,0.2); 
    transition: all 0.3s ease;
}

/* ---------- FOOTER ---------- */
footer {
    background: #0F3D2E;
    padding: 10px 10px;
    color: white;
    text-align: center;
    margin-top: 30px;
}
.footer-container {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    padding: 20px 0;
    gap: 20px;
    max-width: 1200px;
    margin: auto;
}
footer h3 {
    font-weight: 600;
    margin-bottom: 12px;
}
.footer-container a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    display: block;
    margin-bottom: 6px;
}
.footer-container a:hover {
    color: #76d7b1;
}
.footer-container p {
    color: white;
    font-size: 0.95rem;
    text-align: center;
}
.about-column {
    flex: 1;
    text-align: center;
}
.social-column {
    text-align: right;
}

/* ---------- ANIMATIONS ---------- */
@keyframes fadeUp { from {opacity:0; transform:translateY(40px);} to {opacity:1; transform:translateY(0);} }
@keyframes fadeIn { from {opacity:0;} to {opacity:1;} }
@keyframes gradientShift {
    0% { background-position:0% 50%; }
    50% { background-position:100% 50%; }
    100% { background-position:0% 50%; }
}
@keyframes cartBounce { 0%,100%{transform:scale(1);} 50%{transform:scale(1.3);} }
.bounce { animation: cartBounce 0.6s ease; }

/* ---------- RESPONSIVE ---------- */
@media(max-width: 1400px) { body { min-width: auto; } }
@media(max-width: 1200px) { 
    .product-grid { gap: 25px; } 
    .product-card { width: 260px; } 
    .image-container { aspect-ratio: 16/9; }
}
@media(max-width: 992px) {
    nav { padding: 10px 20px; }
    .nav-links { display: flex; flex-direction: row; gap: 10px; overflow-x: auto; white-space: nowrap; flex-wrap: nowrap; scrollbar-width: none; }
    .nav-links::-webkit-scrollbar { display: none; }
    .buttons { flex-shrink: 0; padding: 8px 14px; font-size: 0.85rem; }
    .nav-search input { width: 130px; }
    .product-grid {  display: flex; flex-direction: column; grid-template-columns: repeat(3,1fr); gap: 20px; justify-items: center; }
    .image-container { aspect-ratio: 4/3; }
}
@media (max-width: 992px) {
    footer p,
    .footer-container p,
    .footer-container,
    .footer-container div {
        text-align: center !important;
    }

    .footer-container {
        flex-direction: column;
        align-items: center;
    }
}

@media(max-width: 768px) {
    .shop-header h1 { font-size: 1.8rem; }
    .shop-header p { font-size: 0.9rem; }
    .filter-buttons { gap: 8px; }
    .filter-buttons button { padding: 6px 14px; font-size: 0.85rem; }
    .product-grid {  display: flex; flex-direction: column !important; grid-template-columns: repeat(2,1fr) !important; gap: 20px !important; justify-items: center; }
    .product-card { width: 100% !important; height: auto !important; }
}
@media(max-width: 600px) {
    nav { padding: 8px 12px; }
    .nav-search { display: none !important; }
    .logo img { height: 55px; }
}
/* Mobile devices */
@media (max-width: 576px) {
    .product-grid { grid-template-columns: repeat(auto-fit, minmax(180px, 220px)); }
    .image-container { aspect-ratio: 1/1; }
}
@media(max-width: 480px) {
    nav .logo img { height: 55px; }
    .nav-links a { padding: 6px 10px; font-size: 0.85rem; }
    .product-grid {  display: flex; flex-direction: column !important; grid-template-columns: repeat(2,1fr) !important; gap: 15px !important; }
    .product-card { width: 100% !important; }
    .image-container { aspect-ratio: 1/1; }
}
