/* =========================================================
   GLOBAL RESET & BASE LAYOUT
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }

body {
    margin-top: 62px;
    margin-bottom: 120px;
    background-color: #d5eeef;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    font-family: "Helvetica Neue", sans-serif;
    overflow-x: hidden;
}
.dropdown-menu {
    z-index: 2000 !important;
}

/* =========================================================
   HEADER & FOOTER
   ========================================================= */
/* Header */
.header {
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 2000;
    background-color: #03143a;
    padding: 5px;
    color: #fff;
}

/* Menu button */
.menu-btn {
    background: transparent !important;
    border: none !important;
    padding: 0;
}

.menu-btn:focus {
    outline: none !important;
    box-shadow: none !important;
}

/* Dropdown visibility fix */
.dropdown-menu {
    z-index: 10000 !important;
}

/* User icon */
.user-icon {
    font-size: 22px;
    color: white;
}

.signin-link {
    text-decoration: none;
    color: white;
}

.signin-link:hover .signin-text {
    text-decoration: underline;
}

/* Cart link */
.cart-link {
    text-decoration: none;
}

/* Amazon-style footer background */
.amazon-footer {
    background: #102237; /* Amazon dark footer color */
    color: #ddd;
    padding: 30px 15px;
    font-family: Arial, sans-serif;
}

/* Main links: 2 columns */
.footer-links {
    display: flex;
    justify-content: center;
    gap: 120px; /* space between the two columns */
    max-width: 900px;
    margin: auto;
    padding: 20px 0;
}

/* each column */
.footer-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col a {
    color: #ddd;
    text-decoration: none;
    font-size: 15px;
}

.footer-col a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Mobile */
@media (max-width: 408px) {
    .footer-links {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }
}

/* Language + Country */
.footer-locale {
    margin-top: 10px;
    border-top: 1px solid #2c3743;
    padding-top: 20px;
    display: flex;
    justify-content: center;
    gap: 25px;
    font-size: 14px;
}

/* Bottom legal text */
.footer-legal {
    margin-top: 10px;
    font-size: 12px;
    text-align: center;
    color: #bbb;
}

.footer-legal p {
    margin: 5px 0;
}

/* Mobile view */
@media (max-width: 768px) {
    .footer-links {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-locale {
        flex-direction: column;
        gap: 10px;
    }
}

/* =========================================================
   ALWAYS 2 COLUMNS — STRENGTHENED SO NOTHING CAN BREAK IT
   ========================================================= */
.container {
    padding: 0 8px !important;
    width: 100% !important;
    max-width: 100% !important;
}

.row {
    display: flex !important;
    flex-wrap: wrap !important;
    margin: 0 -8px !important;
}

/* Force EVERY column to be exactly 50% width */
.col-6,
.col-sm-6,
.col-md-6,
.col-lg-6,
.col-xl-6,
[class*="col-"] {
    flex: 0 0 50% !important;
    max-width: 50% !important;
    padding: 0 8px !important;
    box-sizing: border-box !important;
}

/* text alignment helpers */
.text-holder-4 { justify-content: flex-start; text-align: left; }
.text-holder-5 { justify-content: center; text-align: center; }
.text-holder-6 { justify-content: flex-end; text-align: right; }

/* =========================================================
   ORIGINAL STYLES — UNTOUCHED
   ========================================================= */
.business-logo { max-height:50px; border-radius:20%; }

.discount-badge { 
    position:absolute; top:8px; right:8px; background:#dc3545!important; color:#fff!important;
    font-weight:bold; font-size:13px; padding:4px 8px; border-radius:6px;
    box-shadow:0 2px 6px rgba(0,0,0,.25); z-index:10;
}

.view-btn {
    background:rgba(23,162,184,.15); color:tomato; width:60px; font-size:12px;
    box-shadow:0px 4px 6px rgba(0,0,0,.2), 0px -4px 6px rgba(0,0,0,.2),
                4px 0px 6px rgba(0,0,0,.2), -4px 0px 6px rgba(0,0,0,.2);
}

.animated-bar { 
    margin:-10px 2 -5px; background:#00122a; height:100px;
    display:flex; justify-content:space-between; align-items:center; 
    border-top:2px solid white;
}

/* =========================================================
   SCROLL + SLIDER
   ========================================================= */
.scroll-container,
.slider-container {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 5px;
    padding: 10px;
    width: 100%;
    background: transparent;
    -webkit-overflow-scrolling: touch;
}

.scroll-container::-webkit-scrollbar,
.slider-container::-webkit-scrollbar {
    height: 2px;
}

.scroll-container::-webkit-scrollbar-thumb,
.slider-container::-webkit-scrollbar-thumb {
    border-radius: 4px;
}

.scroll-container::-webkit-scrollbar-track,
.slider-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.scroll-item,
.slide-item {
    flex: 0 0 auto;
    position: relative;
    border-radius: 8px;
    border: none;
    overflow: hidden;
    scroll-snap-align: start;
    transition: transform 0.3s ease;
}

.scroll-item:hover,
.slide-item:hover {
    transform: scale(1.05);
}

.scroll-item {
    width: 120px;
    height: 120px;
}

.slide-item {
    width: 250px;
    height: 120px;
}

.scroll-item img,
.slide-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.scroll-item p,
.slide-item p {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    font-weight: bold;
    font-size: 18px;
    color: lime;
    text-align: center;
    text-shadow: 1px 1px 2px black;
    pointer-events: none;
}

/* =========================================
   CATEGORIES GRID — ALWAYS 3 COLUMNS
   ========================================= */
.grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 0 10px;
}

.grid-item {
    width: 100%;
    height: 150px;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.grid-item:hover {
    transform: scale(1.04);
}

.grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* =========================================================
   LATEST PRODUCTS — TIGHT LAYOUT & STRICT 2 COLUMNS
   ========================================================= */

/* Ensure strict 2-column layout */
.latest-products-row {
    display: flex !important;
    flex-wrap: wrap !important;
}

.latest-products-row > .col-md-6 {
    flex: 0 0 50% !important;
    max-width: 50% !important;
    padding: 0 8px !important;
}

/* Card uniform height and flex structure */
.product-card {
    min-height: 230px !important;
    display: flex !important;
    flex-direction: column !important;
}

.product-image {
    height: 200px !important;
    object-fit: cover;
    width: 100%;
}

/* Card body takes remaining space */
.card-body {
    flex-grow: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    padding: 12px !important;
}

/* Description: max 2 lines, small bottom margin only */
.product-description {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.5;
    color: #222;
    margin-bottom: 0 !important;
    text-align: center;
    
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

/* Price: pushed to bottom, tight spacing */
.price-info {
margin-top: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 8px !important;
    line-height: 1.1 !important;
}

.original-price {
    font-size: 14px;
    color: #999;
    text-decoration: line-through;
    margin-right: 10px;
}

.discounted-price {
    font-size: 19px;
    font-weight: bold;
    color: #28a745;
}

/* CloseBy card matches height */
.business-card {
    min-height: 360px !important;
}
/* =========================================================
   ADSENSE AD CONTAINER — CENTERED, 90% WIDTH, RESPONSIVE
   ========================================================= */

/* =========================================================
   ADSENSE AD CONTAINER — CENTERED, 90% WIDTH, REDUCED & RESPONSIVE HEIGHT
   ========================================================= */

/* Main container - centered, 90% width, dynamic height */
.adsense-container {
    width: 90% !important;
    max-width: 90% !important;
    margin: 20px auto !important;          /* Centers horizontally + vertical spacing */
    padding: 12px 10px !important;         /* Comfortable internal padding */
    box-sizing: border-box !important;
    overflow: hidden !important;
    text-align: center !important;
    max-height: 400px  !important ;
    
    /* Optional styling - remove if you want invisible */
    border: 1px solid #604242;
    background-color: #f9f9f9;
    border-radius: 8px;
}

/* AdSense <ins> element - full width inside container, natural height */
.adsense-container ins {
    display: block !important;
    margin: 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 400px !important;               /* Allows natural ad height */
    min-height: 90px !important;           /* Minimum height so it doesn't collapse */
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .adsense-container {
        width: 95% !important;
        max-width: 95% !important;
        padding: 10px 8px !important;
        margin: 15px auto !important;
    }
    
    .adsense-container ins {
        min-height: 80px !important;
    }
}

@media (max-width: 480px) {
    .adsense-container {
        width: 98% !important;
        max-width: 98% !important;
        padding: 8px !important;
        margin: 12px auto !important;
    }
    
    .adsense-container ins {
        min-height: 70px !important;       /* Even smaller min on tiny screens */
    }
}

/* Optional: Max height cap to prevent super tall ads (rare) */
.adsense-container ins {
    max-height: 300px !important;          /* Caps very tall ads if needed */
    overflow: hidden !important;
}
/* Main container - full width but no overflow */
.marquee-container {
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;   /* Prevents horizontal offshoot */
    box-sizing: border-box !important;
    padding: 10px 15px;            /* Internal padding for content */
    margin: 10px 0;                /* Vertical spacing between sections */
    background: transparent;       /* Adjust if needed for your design */
}

/* Promo image - responsive, no overflow */
.marquee-container img {
    width: 100% !important;
    height: auto !important;
    max-width: 100% !important;
    object-fit: contain;           /* Keeps image proportional without cropping */
    border-radius: 8px;            /* Optional: rounded corners */
}

/* Contact info section - centered and contained */
.marquee-container.text-center {
    text-align: center !important;
}

/* Social icons - prevent overflow, responsive */
.social-icons {
    display: flex !important;
    justify-content: center !important;
    gap: 15px !important;          /* Space between icons */
    flex-wrap: wrap;               /* Wrap on small screens if needed */
    max-width: 100% !important;
}

.social-icons a {
    font-size: 29px !important;    /* Keep your size, but ensure no overflow */
}

/* Marquee text - wrap and contain */
.marquee-text {
    white-space: nowrap;           /* For marquee scrolling if intended */
    overflow: hidden !important;
    text-overflow: ellipsis !important;  /* Ellipsis if too long */
    font-size: 16px;               /* Adjust size if needed */
    max-width: 100% !important;
}

/* Rotating text - contained */
#rotatingText {
    font-size: 12px !important;
    white-space: nowrap;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    max-width: 100% !important;
}

/* Mobile adjustments - ensure no overflow on small screens */
@media (max-width: 768px) {
    .marquee-container {
        padding: 8px 10px;
    }
    
    .social-icons a {
        font-size: 24px !important;  /* Slightly smaller on mobile */
    }
    
    .marquee-text {
        white-space: normal !important;  /* Allow wrapping on mobile */
    }
}