/* =========================================
   1. GLOBAL RESETS & VARIABLES
   ========================================= */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background-color: #f4f4f4;
  color: #333;
  overflow-x: hidden; /* Horizontal scroll rokne ke liye */
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; }

/* =========================================
   2. HEADER / NAVBAR
   ========================================= */
.main-header {
    height: 60px; /* Height fix kar di taaki kuch hile nahi */
    padding: 0 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff;
    gap: 5px; /* Items ke beech thoda gap */
}

.nav-left {
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: -10px;
    flex-shrink: 0;
}
.nav-right {
    display: flex;
    align-items: center;
    gap: 12px; /* Icons ke beech gap */
    flex-shrink: 0;
}.nav-center {
    flex-grow: 1; /* Bachi hui jagah lega */
    margin: 0 5px; /* Side se thoda gap */
    min-width: 0; /* Taaki flexbox mein shrink ho sake */
}.nav-left p{
  display: none;
}
.nav-left .logo {
    flex-shrink: 0 !important; /* Browser ko bolo: Isko chota mat karna! */
    display: flex;
    align-items: center;
    padding-right: 5px; /* Thoda sa gap search bar se */
}
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}
.logo img, .header-logo-img {
    height: 65px !important;
    width: auto !important;
    max-width: none !important;
    transform: scale(2);
    margin: 0px 20px !important;
    object-fit: contain !important;
    display: block;
}

.nav-icon {
    font-size: 2rem;
    color: #333;
    margin: 0 !important; /* Purana margin hatao */
}.nav-right .nav-icon:first-child { margin-left: 0; }

.nav-icon, #cart-icon-btn {
    position: relative !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.cart-count {
    position: absolute !important;
    top: -8px !important;   /* Thoda upar */
    right: -8px !important; /* Thoda right */
    
    background-color: #ff3b30 !important; /* Red Color */
    color: white !important;
    font-size: 10px !important;
    font-weight: bold;
    
    min-width: 18px; /* Golai ke liye */
    height: 18px;
    border-radius: 50%; /* Gol shape */
    
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
    z-index: 10;
    border: 2px solid white; /* Border taaki saaf dikhe */
}


.search-bar {
    width: 100%;
    height: 36px;
    padding: 0 10px;
    background-color: #f5f5f5;
    border-radius: 6px;
    display: flex;
    align-items: center;
}
.search-bar input {
    width: 100%;
    font-size: 13px; /* Font thoda chota mobile ke liye */
}
/* =========================================
   3. MOBILE NAVIGATION (Hamburger Menu)
   ========================================= */
.mobile-nav {
  position: fixed; top: 0; left: -280px;
  width: 280px; height: 100%;
  background-color: #ffffff; z-index: 2000;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
  transition: left 0.3s ease-in-out;
}
.mobile-nav.active { left: 0; }

.mobile-nav-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 15px 20px; border-bottom: 1px solid #e0e0e0;
}
.close-btn { font-size: 1.8rem; background: none; border: none; color: #555; }

.mobile-nav ul li a { display: block; padding: 15px 20px; border-bottom: 1px solid #f0f0f0; }

/* Menu Buttons (Login/Register) */
.nav-auth-buttons { display: flex; gap: 15px; padding: 20px; border-top: 1px solid #f0f0f0; }
.btn { flex: 1; padding: 10px; text-align: center; border-radius: 6px; font-weight: bold; }
.btn-login { border: 2px solid #d3a14b; color: #d3a14b; }
.btn-register { background-color: #d3a14b; color: white; border: 2px solid #d3a14b; }

.overlay {
  display: none; position: fixed; top: 0; left: 0;
  width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.5); z-index: 1999;
}
.overlay.active { display: block; }


/* =========================================
   4. HERO BANNER (Slider)
   ========================================= */
.hero-banner-slider {min-height: 200px;
    background-color: #f0f0f0; width: 100%; min-height: 200px; overflow: hidden; background-color: #f0f0f0; }
.slider-track { display: flex; width: 400%; transition: transform 0.5s ease-in-out; }
.slide { width: 100%; height: 200px; overflow: hidden; } /* Mobile Height */
.slide img { width: 100%; height: 100%; object-fit: cover; display: block; }


/* =========================================
   5. CATEGORY NAV (Top Icons)
   ========================================= */
.category-nav {
  display: flex; overflow-x: auto; background-color: #fff;
  padding: 15px 10px; border-bottom: 1px solid #f0f0f0;
  scrollbar-width: none;
}
.category-nav::-webkit-scrollbar { display: none; }

.category-item { flex: 0 0 70px; text-align: center; margin: 0 5px; }
.category-item img {
  width: 55px; height: 55px; border-radius: 50%;
  background-color: #f0f0f0; border: 1px solid #e0e0e0; object-fit: cover;
}
.category-item p { font-size: 0.75rem; margin-top: 5px; white-space: nowrap; }


/* =========================================
   6. MY RANGE SECTION ( FIX APPLIED HERE )
   ========================================= */
.horizontal-list {
  display: flex;
  overflow-x: auto;
  gap: 30px; 
  padding: 0 15px; 
  align-items: flex-start !important; /* TOP alignment ko force karo */
  scrollbar-width: none;
}

.list-item-circle {
  flex: 0 0 85px; 
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  margin: 0; 
  padding-bottom: 5px; /* Neeche se halka sa padding */
}

/* IMAGE: Ensure margin is minimal */
.list-item-circle img {
  width: 75px; 
  height: 75px;
  border-radius: 50%;
  border: 1px solid #e0e0e0;
  object-fit: cover;
  margin-bottom: 4px; /* Image ke neeche ka gap */
}

/* TEXT: Fixed Height and Margin Reset */
.list-item-circle p {
  font-size: 0.75rem; 
  color: #333;
  line-height: 1.2;
  
  /* YEH HAI ULTIMATE FIX: Margin aur Padding poora hatao */
  margin: 0 !important; 
  padding: 0 !important;

  /* Height ko fixed karo (2 lines space) */
  height: 36px; 
  min-height: 36px; 
  
  display: flex;
  align-items: flex-start; /* Text ko box ke upar chipkao */
  justify-content: center;
  width: 100%;
}


/* =========================================
   7. HOME PAGE PRODUCT CARDS (B2B)
   ========================================= */
.product-carousel { padding: 20px 0; background-color: #f9f9f9; }
.carousel-title { text-align: center; color: #d3a14b; margin-bottom: 20px; text-transform: uppercase; }
.carousel-container { min-height: 320px; display: flex; overflow-x: auto; padding: 10px 15px; gap: 15px; scrollbar-width: none; }
.carousel-container::-webkit-scrollbar { display: none; }

.product-card-b2b {
  flex: 0 0 170px; background: #fff; border: 1px solid #e0e0e0;
  border-radius: 12px; overflow: hidden; box-shadow: 0 4px 8px rgba(0,0,0,0.05);
}
.card-image-container { position: relative; height: 180px; }
.product-image { width: 100%; height: 100%; object-fit: cover; }
.brand-logo-container {
  position: absolute; bottom: -20px; left: 50%; transform: translateX(-50%);
  width: 40px; height: 40px; background: #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.brand-logo { width: 80%; height: auto; }

.card-info-container { padding: 25px 10px 10px 10px; text-align: center; }
.product-brand { font-size: 1rem; font-weight: bold; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;}
.product-category { font-size: 0.8rem; color: #777; margin-bottom: 10px; }

.b2b-info { display: flex; justify-content: space-between; border-top: 1px solid #f0f0f0; padding-top: 8px; text-align: left; }
.info-left, .info-right { display: flex; flex-direction: column; }
.info-right { text-align: right; }
.product-price-label, .moq-label { font-size: 0.7rem; color: #888; text-transform: uppercase; }
.product-price, .moq-value { font-size: 0.85rem; font-weight: bold; color: #333; }
.moq-value { color: #d9534f; }


/* =========================================
   8. PRODUCT LISTING PAGE (Grid)
   ========================================= */
.page-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 15px; background: #fff; position: sticky; top: 0; z-index: 900;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.header-left { display: flex; align-items: center; }
.back-arrow { font-size: 1.2rem; margin-right: 10px; }
.page-title h3 { font-size: 1rem; margin: 0; }
.page-title span { font-size: 0.8rem; color: #777; }

.product-grid-container {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 8px; padding: 10px; background: #f4f4f4;
}

.plp-card {
  background: #fff; border: 1px solid #e0e0e0; border-radius: 6px;
  overflow: hidden; display: flex; flex-direction: column;
}
.plp-image-box { position: relative; border-bottom: 1px solid #f0f0f0; }
.plp-image-box img { width: 100%; height: 125px; object-fit: cover; display: block; }
.wishlist-icon {
  position: absolute; top: 5px; right: 5px; width: 25px; height: 25px;
  background: rgba(255,255,255,0.9); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; color: #555;
}

.plp-details { padding: 8px; flex-grow: 1; display: flex; flex-direction: column; }
.plp-brand { font-size: 0.9rem; font-weight: bold; margin-bottom: 2px; }
.plp-title { font-size: 0.75rem; color: #666; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plp-meta-info { font-size: 0.7rem; color: #999; margin: 5px 0; }
.plp-b2b-info { background: #f8f8f8; font-size: 0.7rem; padding: 4px; margin-bottom: 5px; border-radius: 4px; }
.plp-price { font-size: 0.95rem; font-weight: bold; margin-top: auto; }


/* =========================================
   9. BOTTOM SHEET (Pop-ups)
   ========================================= */
.overlay-modal {
  display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0,0,0,0.5); z-index: 2000;
}
.overlay-modal.active { display: block; }

.bottom-sheet-container {
  position: fixed; left: 0; bottom: -100%; width: 100%;
  background: #fff; border-radius: 16px 16px 0 0;
  z-index: 2001; transition: bottom 0.3s ease-in-out;
  max-height: 80vh;
}
.bottom-sheet-container.active { bottom: 0; }

.sheet-header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 15px 20px; border-bottom: 1px solid #eee;
}
.sheet-close-btn { background: #f0f0f0; border: none; border-radius: 50%; width: 30px; height: 30px; }

.sheet-content { padding: 20px; overflow-y: auto; max-height: 60vh; }
.subcategory-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.subcategory-item { text-align: center; display: flex; flex-direction: column; align-items: center; }
.subcategory-item img { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; margin-bottom: 5px; border: 1px solid #eee; }
.subcategory-item p { font-size: 0.8rem; color: #333; }


/* =========================================
   10. FOOTER
   ========================================= */
.site-footer { background-color: #2c3e50; color: #bdc3c7; padding: 40px 0 0 0; margin-top: 30px;}
.footer-container { padding: 0 20px; display: flex; flex-direction: column; gap: 30px; }
.footer-logo { color: #fff; font-size: 1.8rem; margin-bottom: 10px; }
.footer-column h4 { color: #fff; margin-bottom: 15px; text-transform: uppercase; font-size: 1rem; }
.footer-links li { margin-bottom: 8px; font-size: 0.9rem; }
.footer-bottom { background: #233140; text-align: center; padding: 15px; margin-top: 20px; font-size: 0.8rem; }


/* =========================================
   11. RESPONSIVE (Tablet & Desktop)
   ========================================= */

   /* =========================================
   13. CART DRAWER (Side Pop-up)
   ========================================= */

/* Overlay (Puraana wala .overlay-modal use hoga) */
/* Humne iske liye pehle hi style likh diya hai */

/* Cart Container */
.cart-drawer {
  position: fixed;
  top: 0;
  right: -100%; /* Default me screen ke bahar (hidden) */
  width: 100%;
  max-width: 380px; /* Max width 380px, phone pe poora */
  height: 100%;
  background-color: #ffffff;
  z-index: 2002; /* Bottom sheet se bhi upar */
  box-shadow: -4px 0 15px rgba(0,0,0,0.1);
  transition: right 0.3s ease-in-out; /* Smooth slide */
  
  /* Poore cart ko flex me baant do (Header, Content, Footer) */
  display: flex;
  flex-direction: column;
}
.cart-drawer.active {
  right: 0; /* Active class lagne par dikhega */
}

/* 1. Cart Header */
.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid #e0e0e0;
  flex-shrink: 0; /* Ye shrink nahi hoga */
}
.cart-header h3 { font-size: 1.2rem; }
.cart-close-btn {
  background: none; border: none; font-size: 1.5rem; color: #555;
}

/* 2. Cart Content (Items Area) */
.cart-content {
  padding: 15px;
  overflow-y: auto; /* Agar items zyada ho toh scroll hoga */
  flex-grow: 1; /* Beech ki poori jagah lega */
}

.cart-empty {
  text-align: center;
  padding: 50px 0;
  color: #aaa;
}
.cart-empty i { font-size: 3rem; margin-bottom: 15px; }

/* Ek Cart Item ka Style */
.cart-item {
  display: flex;
  gap: 15px;
  align-items: center;
  padding-bottom: 15px;
  margin-bottom: 15px;
  border-bottom: 1px solid #f0f0f0;
}
.cart-item img {
  width: 70px;
  height: 70px;
  border-radius: 8px;
  border: 1px solid #eee;
  object-fit: cover;
}
.item-details { flex-grow: 1; }
.item-brand { font-size: 0.8rem; color: #888; margin-bottom: 2px; }
.item-name { font-size: 0.95rem; font-weight: bold; margin-bottom: 5px; }
.item-price { font-size: 1rem; font-weight: bold; color: #333; }
.item-moq { font-size: 0.8rem; font-weight: normal; color: #d9534f; }
.item-remove-btn {
  background: #f8f8f8; border: 1px solid #e0e0e0;
  width: 30px; height: 30px; border-radius: 50%;
  color: #d9534f;
}

/* 3. Cart Footer (Checkout) */
.cart-footer {
  padding: 15px 20px;
  border-top: 1px solid #e0e0e0;
  background-color: #f9f9f9;
  flex-shrink: 0; /* Ye shrink nahi hoga */
}
.subtotal-row {
  display: flex;
  justify-content: space-between;
  font-size: 1rem;
  margin-bottom: 15px;
}
.subtotal-price { font-weight: bold; font-size: 1.2rem; color: #333; }
.btn-checkout {
  display: block;
  width: 100%;
  padding: 15px;
  background-color: #d3a14b;
  color: white;
  text-align: center;
  font-size: 1.1rem;
  font-weight: bold;
  border: none;
  border-radius: 8px;
}

/* =========================================
   14. TOAST / SANDWICH POPUP
   ========================================= */
#toast-popup {
  visibility: hidden; /* Default me chupa hua */
  opacity: 0;
  min-width: 250px;
  background-color: #333; /* Dark background */
  color: #fff; /* White text */
  text-align: center;
  border-radius: 8px;
  padding: 16px;
  position: fixed; /* Hamesha screen par fix */
  z-index: 9999; /* Sabse upar */
  left: 50%;
  transform: translateX(-50%); /* Center me */
  bottom: 30px; /* Neeche se 30px upar */
  font-size: 1rem;
  transition: opacity 0.3s, bottom 0.3s ease-in-out;
  
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Jab 'show' class lagegi, tab ye dikhega */
#toast-popup.show {
  visibility: visible;
  opacity: 1;
  bottom: 50px; /* Slide hoke upar aayega */
}

#toast-popup i {
  color: #28a745; /* Green Check */
  font-size: 1.2rem;
}
/* =========================================
   SEARCH SUGGESTIONS (Autocomplete)
   ========================================= */
.suggestions-box {
  position: absolute;
  top: 100%; /* Input ke theek neeche */
  left: 0;
  width: 100%;
  background-color: #fff;
  border: 1px solid #ddd;
  border-top: none;
  border-radius: 0 0 8px 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  list-style: none;
  padding: 0;
  margin: 0;
  z-index: 9999;
  display: none; /* Default me chupa rahega */
  max-height: 300px;
  overflow-y: auto;
}

.suggestions-box.active {
  display: block; /* JS isse dikhayega */
}

.suggestions-box li {
  padding: 10px 15px;
  cursor: pointer;
  border-bottom: 1px solid #f5f5f5;
  font-size: 0.9rem;
  color: #333;
  display: flex;
  justify-content: space-between;
}

.suggestions-box li:hover {
  background-color: #f9f9f9;
  color: #d3a14b; /* Highlight color */
}

.suggestion-type {
  font-size: 0.75rem;
  color: #999;
  text-transform: uppercase;
}

.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 20px;
    right: 10px;
    background-color: #25d366;
    color: #FFF;
    border-radius: 50px;
    text-align: center;
    font-size: 30px;
    box-shadow: 2px 2px 3px #999;
    z-index: 1000; /* Taaki ye sabse upar dikhe */
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    background-color: #128c7e; /* Hover karne par thoda dark hoga */
    transform: scale(1.1); /* Thoda bada hoga */
    color: white;
}

/* --- INTRO VIDEO OVERLAY --- */
#intro-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #fff; /* Background color peeche ka */
    z-index: 99999; /* Sabse upar dikhana hai */
    display: flex;
    align-items: center;
    justify-content: center;
}

#intro-video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Video puri screen bharega bina stretch huye */
}

/* Skip Button (Optional) */
#skip-btn {
    position: absolute;
    bottom: 30px;
    right: 30px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: 1px solid white;
    padding: 8px 15px;
    cursor: pointer;
    font-size: 14px;
    border-radius: 20px;
    z-index: 100000;
}

#skip-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

@media (min-width: 768px) {
  
  /* 1. Global Width Control */
  body { background-color: #e9e9e9; }
  .main-header, .container, .site-footer { max-width: 1200px; margin: 0 auto; }

  /* 2. Header Ko Bada Karo (Desktop Feel) */
  .main-header {
      height: 80px; /* Height badhayi */
      padding: 0 30px; /* Side spacing badhayi */
      gap: 40px; /* Elements ke beech khula gap */
  }

  /* 3. LOGO FIX (Mobile wala rule todne ke liye) */
  /* Mobile par 28px tha, yahan hum override kar rahe hain */
  .logo img, .header-logo-img {
      height: 50px !important; /* Bada Logo */
      width: auto !important;
      max-width: none !important; /* Width limit hatao */
      margin-top: 0;
  }
  
  /* Menu Button Desktop par gayab */
  #menu-toggle { 
      display: none !important; /* !important zaroori hai */
  }

  /* 4. Search Bar (Center & Wide) */
  .nav-center {
      flex-grow: 1;
      display: flex;
      justify-content: center;
      margin: 0;
  }
  .search-bar {
      width: 100%;
      max-width: 600px; /* Search bar ki chaudai control mein */
      height: 45px; /* Thoda bada input box */
  }
  .search-bar input {
      font-size: 1rem;
  }

  /* 5. Right Icons */
  .nav-right {
      gap: 20px;
  }
  .nav-icon {
      font-size: 1.4rem; /* Icons thode bade */
      cursor: pointer;
      display: none;
  }

  /* --- BAAKI DESKTOP STYLES (Same as before) --- */
  .category-nav { justify-content: center; }
  .horizontal-list { justify-content: center; }
  
  .product-grid-container { grid-template-columns: repeat(4, 1fr); gap: 20px; padding: 20px; }
  .plp-image-box img { height: 200px; }
  
  .slide { height: 400px; }
  .hero-banner-slider { min-height: 400px; }
  
  .whatsapp-float { width: 50px; height: 50px; bottom: 20px; right: 20px; font-size: 25px; }
  .slogen { display: none !important; }
  
  .footer-container { flex-direction: row; flex-wrap: wrap; justify-content: space-between; }
  .footer-column { flex: 1; min-width: 200px; }
}

#intro-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000; /* Black background */
    z-index: 9999; /* Sabse upar dikhega */
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease; /* Smooth gayab hone ke liye */
}

#intro-video {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Video poore screen par fit hogi */
}

#skip-btn {
    position: absolute;
    bottom: 30px;
    right: 30px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid white;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    z-index: 10000;
}

#skip-btn:hover {
    background: rgba(255, 255, 255, 0.5);
    color: black;
}