/* ========== BASE STYLES ========== */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #f4f4f4;
  color: #333;
}

header, footer {
  background-color: #0074d9;
  color: white;
  padding: 0.5rem;
  text-align: center;
}

/* ========== HEADER STRUCTURE ========== */
.top-header {
  position: relative; /* Yeh zaroori hai! */
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  background-color: #0074d9;
  padding: 0.5rem 1rem;
}

.logo img {
  max-height: 60px;
  max-width: 480px;
  width: 100%;
}

/* DESKTOP MENU */
.desktop-menu {
  display: flex;
  background-color: transparent;
}

.desktop-menu ul {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin: 0;
  padding: 0;
}

.desktop-menu li a {
  color: white;
  text-decoration: none;
  font-weight: bold;
  font-size: 1rem;
}

.desktop-menu li a:hover {
  color: #ffdc00;
}

.welcome h2,
.welcome h3 {
  margin-bottom: 0.5rem;
}

/* HAMBURGER ICON */
.hamburger {
  display: none;
  font-size: 1.8rem;
  color: white;
  cursor: pointer;
}

/* MOBILE MENU */
.mobile-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: white;
  z-index: 999;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.mobile-menu ul {
  list-style: none;
  margin: 0;
  padding: 0;
  flex-direction: column;
}

.mobile-menu ul li {
  border-bottom: 1px solid #eee;
  padding: 0.8rem 1.5rem;
  text-align: left;
}

.mobile-menu ul li a {
  color: #0074d9;
  text-decoration: none;
  font-weight: bold;
  display: block;
}

.mobile-menu ul li a:hover {
  background-color: #0074d9;
  color: white;
  border-radius: 4px;
}

/* ========== HERO SECTION ========== */
.hero {
  background: #ffdc00;
  padding: 0.5rem;
  text-align: center;
}


/* ========== DEALS ========== */


.deal-section {
  margin-bottom: 1rem;
}

.deal-section h2 {
  font-size: 1.2rem;
  margin: 1rem 0 0.5rem;
  padding-left: 1rem;
}

.deal-row {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding: 1rem;
  scroll-snap-type: x mandatory;
}

.deal-card {
  flex: 0 0 auto;
  width: 245px;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 10px;
  padding: 10px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  text-align: center;
  scroll-snap-align: start;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.deal-card img {
  width: 100%;
  height: 200px;
  object-fit: contain;
  border-bottom: 0.5px solid #ddd; /* only bottom border */
  border-left: none;
  border-top: none;
  border-right: none;
}

.deal-card h4 {
  font-size: 1.1rem;
  line-height: 1.2;
  min-height: 40px;
  margin: 0 0 10px;
}

.deal-card h5 {
  font-size: 1rem;
  line-height: 1.1;
  min-height: 35px;
  margin: 0 0 10px;
}

.deal-card .btn {
  background-color: #007bff;
  color: white;
  padding: 8px 16px;
  text-decoration: none;
  border-radius: 5px;
  font-size: 0.9rem;
}

.category-slider-wrapper {
  position: relative;
}

.slider-arrow {
  position: absolute;
  top: 35%;
  z-index: 10;
  background: white;
  border: 1px solid #ccc;
  border-radius: 50%;
  width: 35px;
  height: 35px;
  cursor: pointer;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  transition: all 0.2s ease;
}

.slider-arrow.left {
  left: -15px;
}

.slider-arrow.right {
  right: -15px;
}

.slider-arrow:hover {
  background: #007bff;
  color: white;
}

.horizontal-scroll {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 1rem;
  scroll-behavior: smooth;
}

.pagination-controls {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 20px;
}

.page-btn {
  padding: 6px 12px;
  border: none;
  background-color: #ddd;
  cursor: pointer;
  border-radius: 4px;
}

.page-btn.active {
  background-color: #007bff;
  color: white;
}

.modal {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex; justify-content: center; align-items: center;
  z-index: 9999;
}

.modal-content {
  background: white;
  padding: 2rem;
  border-radius: 10px;
  max-width: 600px;
  width: 90%;
  position: relative;
}

.modal .close {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 28px;
  cursor: pointer;
}



/* ========== SIDEBAR & CONTENT LAYOUT ========== */
.main-container {
  display: flex;
  gap: 2rem;
  max-width: 1200px;
  margin: auto;
  padding: 2rem;
}

.content {
  flex: 3;
}

.sidebar {
  flex: 1;
  position: relative;
  max-height: 100%;
}

.sidebar-inner {
  position: sticky;
  top: 1rem;
  overflow-y: auto;
  max-height: 100%;
  padding-right: 0.5rem;
}

/* SIDEBAR WIDGET */
.widget {
  background: #f9f9f9;
  padding: 1rem;
  margin-bottom: 1.5rem;
  border-radius: 6px;
}

.widget h3 {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.widget ul {
  list-style: none;
  padding-left: 0;
}

.widget li {
  margin-bottom: 0.5rem;
}

/* ========== FOOTER ========== */
.footer-main {
  display: flex;
  justify-content: space-around;
  background-color: #0074d9;
  color: white;
  padding: 0.5rem 1.5rem;
  flex-wrap: wrap;
  text-align: left;
}

.footer-column {
  display: flex;
  flex-direction: column;
  margin: 0.1rem;
  min-width: 150px;
}

.footer-column h3 {
  margin-bottom: 0.8rem;
  font-size: 1.5rem;
}

.footer-column a {
  color: white;
  text-decoration: none;
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.footer-column a:hover {
  color: #ffdc00;
}

.footer-bottom {
  background-color: #0074d9;
  text-align: center;
  padding: 0.1rem;
  color: white;
  font-size: 0.95rem;
}

/* ========== RESPONSIVE - MOBILE ONLY ========== */
@media (max-width: 768px) {
  .desktop-menu {
    display: none;
  }

  .hamburger {
    display: block !important;
    font-size: 1.8rem;
    color: white;
    cursor: pointer;
    margin-left: auto;
    z-index: 1001;
  }

  .mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: white;
    z-index: 999;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease-in-out;
  }

  .mobile-menu.show {
    display: block;
    transform: scaleY(1);
  }

  .mobile-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .mobile-menu ul li {
    padding: 0.8rem 1.5rem;
    border-bottom: 1px solid #eee;
    text-align: left;
  }

  .mobile-menu ul li a {
    color: #0074d9;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: bold;
    display: block;
    transition: all 0.3s;
  }

  .mobile-menu ul li a:hover {
    background-color: #0074d9;
    color: white;
    border-radius: 4px;
    padding-left: 1.2rem;
  }

  .logo img {
    max-width: 180px;
  }

  .footer-main {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .main-container {
    flex-direction: column;
  }

  .sidebar {
    max-height: unset;
  }

  .sidebar-inner {
    position: relative;
    max-height: unset;
    overflow: visible;
  }
}

/* ========== RESPONSIVE - DESKTOP ONLY ========== */
/* 👨‍💻 Desktop Only - Hide on mobile and tablet */
.desktop-only {
  display: block;
}

@media (max-width: 991px) {
  .desktop-only {
    display: none !important;
  }
}


@media (max-width: 480px) {
  .deal-card {
    padding: 10px;
  }

  .deal-card h4,
  .deal-card h5 {
    font-size: 0.95rem;
  }

  .deal-card .btn {
    font-size: 0.85rem;
    padding: 6px 12px;
  }
}

@media (max-width: 768px) {
  .deal-row {
    flex-direction: column;
    gap: 1rem;
    overflow-x: unset;
    padding: 1rem 0.5rem;
  }

  .deal-card {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 12px;
    border-radius: 10px;
  }

  .deal-card img {
    height: auto;
    max-height: 180px;
    object-fit: contain;
  }

  .deal-card h4,
  .deal-card h5 {
    font-size: 1rem;
    line-height: 1.2;
    min-height: auto;
  }

  .deal-card .btn {
    font-size: 0.9rem;
    padding: 8px 16px;
    width: 100%;
  }
}


/* ✅ Responsive Breakpoints */

.category-modern-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); /* base min 260px */
  gap: 1.5rem;
  justify-items: center;
  padding: 1rem;
}

.category-card-modern {
  width: 100%; /* grid ke andar 100% hi hona chahiye */
  max-width: 300px; /* limit karta hai max width */
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  background: #fff;
  transition: transform 0.2s ease;
  text-align: center;
}

.category-card-modern:hover {
  transform: translateY(-5px);
}

.category-card-modern .card-top img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  border-bottom: 0.5px solid #ddd; /* only bottom border */
  border-left: none;
  border-top: none;
  border-right: none;
}


.category-card-modern .card-top {
  padding: 0;
  background-color: transparent;
}

.category-card-modern .card-bottom {
  padding: 1rem;
  background-color: #fff;
}

.category-card-modern .card-bottom h3 {
  margin: 0 0 12px;
  font-size: 1rem;
  color: #333;
}

.browse-btn {
  background-color: #007bff;
  color: white;
  border: none;
  padding: 6px 16px;
  font-size: 0.9rem;
  border-radius: 20px;
  text-decoration: none;
  display: inline-block;
  transition: background 0.3s ease;
}

.browse-btn:hover {
  background-color: #0056b3;
}

/* ✅ Responsive Breakpoints */
@media (max-width: 1024px) {
  .category-card-modern .card-top img {
    height: 220px;
  }
}

@media (max-width: 768px) {
  .category-modern-grid {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1rem;
  }

  .category-card-modern {
    max-width: 260px;
  }

  .category-card-modern .card-top img {
    height: 220px;
  }
}

@media (max-width: 480px) {
  .category-modern-grid {
    grid-template-columns: 1fr;
  }

  .category-card-modern {
    max-width: 100%;
  }

  .category-card-modern .card-top img {
    height: 220px;
  }
}
