/* ===== RESET & BASE ===== */
@import url('https://fonts.googleapis.com/css2?family=Michroma&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

:root {
  --primary-color: #ff7400;
  --primary-hover: #142551;
  --navy: #142551;
  --navy-light: #142551ed;
  --navy-dark: #0d1936;
  --cream: #f5f6f1;
  --white: #ffffff;
  --text-dark: #21194d;
  --text-navy: #142551;
  --orange: #ff7301;
  --border-color: #e9e9e8;
  --gray-light: #818181;
  --body-bg: #ffffff;
  --font-heading: 'Michroma', sans-serif;
}

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 13px;
  background-color: var(--body-bg);
  color: var(--text-navy);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

h1, h2, h3, h4, .section-title, .text-section-title, .nav-links a {
  font-family: var(--font-heading) !important;
  letter-spacing: 1.5px;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 15px;
}

main .container {
  max-width: none;
  width: calc(100% - 2px);
  margin: 0 auto;
  padding: 0 10px;
}

/* ===== ANNOUNCEMENT BAR ===== */
.announcement-bar {
  background-color: var(--cream);
  height: 36px;
  display: flex;
  align-items: center;
  overflow: hidden;
  position: relative;
  white-space: nowrap;
}

.announcement-slider {
  display: flex;
  width: max-content;
  animation: marquee 25s linear infinite;
}

.announcement-slider:hover {
  animation-play-state: paused;
}

.marquee-content {
  display: flex;
  align-items: center;
  gap: 50px;
  padding-right: 50px;
}

.announcement-slide {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: #201848;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-25%); }
}

.announcement-slide:nth-child(1) { color: #201848; }
.announcement-slide:nth-child(2) { color: #21194b; }
.announcement-slide:nth-child(3) { color: var(--primary-color); }
.announcement-slide:nth-child(4) { color: #21194d; }

/* ===== HEADER ===== */
.header {
  background-color: var(--navy);
  position: sticky;
  top: 0;
  z-index: 1000;
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 68px;
  padding: 4px 15px;
  gap: 5px;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cream);
  margin-right: 12px;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  padding: 8px;
  -webkit-tap-highlight-color: transparent;
  position: relative;
  z-index: 5;
}

.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.logo a {
  display: flex;
  align-items: center;
}

.logo img,
.header-logo-img {
  max-width: 100%;
  max-height: 60px;
  width: auto;
  object-fit: contain;
}

/* Navigation */
.nav-links {
  display: flex;
  justify-content: flex-start;
  margin-left: 0;
  flex: 1;
}

.nav-links > ul {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
}

.nav-links > ul > li {
  position: relative;
  padding: 0;
  display: flex;
  align-items: center;
  height: 68px; /* Matches header-inner min-height */
}

.nav-links > ul > li > a {
  color: var(--cream);
  font-size: 13px;
  font-weight: 500;
  padding: 10px 10px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: linear-gradient(0deg, var(--cream), var(--cream)) no-repeat right bottom / 0 1.5px;
  transition: background-size 0.3s ease, color 0.3s ease;
  white-space: nowrap;
}

.nav-links > ul > li > a:hover {
  color: #e1e2e1 !important;
  background-size: 100% 1.5px;
  background-position: left bottom;
}

.nav-links > ul > li > a .arrow-icon {
  width: 16px;
  height: 16px;
  transition: transform 0.3s ease;
}

.nav-links > ul > li:hover > a .arrow-icon,
.nav-links > ul > li.active > a .arrow-icon {
  transform: rotate(180deg);
}

/* Dropdown Submenu */
.nav-dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--navy);
  min-width: 240px;
  padding: 4px 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(0);
  transition: opacity 0.2s ease, visibility 0.2s ease;
  z-index: 999;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  border-radius: 0 0 4px 4px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-top: none;
}

.nav-links > ul > li:hover .nav-dropdown,
.nav-links > ul > li.active .nav-dropdown {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.nav-dropdown a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 20px;
  color: var(--cream);
  font-size: 14px;
  transition: background-color 0.2s ease, padding-left 0.2s ease;
}

.nav-dropdown a:hover {
  background-color: rgba(255, 255, 255, 0.08);
  padding-left: 24px;
  color: #fff;
}

.nav-dropdown a svg {
  width: 16px;
  height: 16px;
}

/* Header Icons */
.header-icons {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
}

.header-icons li {
  display: flex;
  align-items: center;
  position: relative;
  cursor: pointer;
}

.header-icons svg {
  width: 25px;
  height: 25px;
  color: var(--cream);
  fill: var(--cream);
}

.header-icons .cart-count {
  position: absolute;
  top: -6px;
  right: -8px;
  background-color: var(--primary-color);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== HERO SLIDER ===== */
.hero-slider {
  position: relative;
  overflow: hidden;
  max-width: none;
  width: calc(100% - 2px);
  margin: 4px auto 0 auto;
  border-radius: 14px;
}

.hero-slide {
  position: relative;
  width: 100%;
  display: none;
}

.hero-slide.active {
  display: block;
}

.hero-slide img {
  width: 100%;
  aspect-ratio: 1920 / 600;
  height: auto;
  max-height: 600px;
  display: block;
  object-fit: contain; /* Ensures no cropping */
  object-position: center;
  background-color: #0f172a; /* Fallback background to match site if needed */
}

@media (max-width: 768px) {
  /* Removed hardcoded height to allow aspect-ratio to scale the image */
}

.hero-content {
  position: absolute;
  bottom: 15%;
  left: 8%;
  z-index: 10;
}

.hero-content .hero-number {
  color: var(--primary-color);
  font-size: 5vh;
  font-weight: 500;
  line-height: 1.1;
}

.hero-content .hero-subtitle {
  color: var(--primary-color);
  font-size: 2vh;
  font-weight: 500;
  margin-bottom: 20px;
}

.hero-content .hero-cta {
  display: inline-block;
  background-color: var(--navy-light);
  color: var(--cream);
  padding: 10px 20px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.hero-content .hero-cta:hover {
  background-color: var(--navy);
}

/* Hero Pagination */
.hero-pagination {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.hero-pagination .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.hero-pagination .dot.active {
  background-color: var(--primary-color);
}

.promo-container-wide {
  max-width: none;
  width: calc(100% - 2px);
  margin: 24px auto;
}

.promo-banners-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

@media (max-width: 1200px) {
  .promo-banners-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .promo-banners-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== PRODUCT SECTIONS ===== */
.section-products {
  padding: 32px 0;
  background-color: var(--white);
}

.section-title {
  font-size: 37px;
  font-weight: 500;
  color: var(--navy);
  margin-bottom: 24px;
}

/* Product Slider Container */
.products-slider-container {
  position: relative;
}

.products-slider {
  display: flex;
  gap: 0;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 0 12px;
}

.products-slider::-webkit-scrollbar {
  display: none;
}

/* Slider Arrows */
.slider-arrow {
  position: absolute;
  top: 40%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background-color: rgba(20, 37, 81, 0.77);
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: background-color 0.3s ease;
}

.slider-arrow:hover {
  background-color: var(--navy);
}

.slider-arrow svg {
  color: var(--cream);
  fill: var(--cream);
  width: 20px;
  height: 20px;
}

.slider-arrow.prev {
  left: 5px;
}

.slider-arrow.next {
  right: 5px;
}

/* Product Card */
.product-card {
  flex: 0 0 20%;
  padding: 12px;
}

.product-card-inner {
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px;
  transition: box-shadow 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.product-card-inner:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.product-image-container {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  margin-bottom: 12px;
  background-color: #f8f8f8;
}

.product-image-container > img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
}

.product-card-carousel-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.carousel-track img {
  object-position: top center;
}

.product-card-inner:hover .product-image-container > img {
  transform: scale(1.05);
}

/* Add to Cart Overlay */
.add-to-cart-overlay {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s ease;
  z-index: 10;
}

.product-card-inner:hover .add-to-cart-overlay {
  opacity: 1;
  transform: translateY(0);
}

.add-to-cart-btn {
  width: 100%;
  height: 44px;
  background-color: var(--navy);
  color: var(--cream);
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.add-to-cart-btn:hover {
  background-color: var(--navy-dark);
}

/* Product Info */
.product-info {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-brand {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.product-name {
  font-family: 'Poppins', sans-serif !important;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: normal !important;
  color: var(--navy);
  margin-bottom: 8px;
  line-height: 1.4;
  text-transform: capitalize;
  /* Standart görünüm için uzun yazıları 2 satırda sınırla */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  min-height: 36px;
}

/* Product Price */
.product-price-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  margin-bottom: 8px;
}

.discount-badge {
  background-color: var(--primary-color);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 6px;
  border-radius: 4px;
}

.original-price {
  font-size: 14px;
  color: var(--gray-light);
  text-decoration: line-through;
}

.sale-price {
  font-size: 18px;
  font-weight: 700;
  color: var(--navy);
}

/* Color Variants */
.color-variants {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  min-height: 34px;
  margin-top: 8px;
}

.color-swatch {
  width: 27px;
  height: 30px;
  border-radius: 3px;
  border: 1px solid var(--border-color);
}

.color-more {
  font-size: 13px;
  color: #9ca3af;
}

/* ===== CATEGORY GRID ===== */
.category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin: 0;
}

.category-card {
  position: relative;
  background-color: #e8eadf;
  padding: 40px 30px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 200px;
  overflow: hidden;
}

.category-card-title {
  font-size: 40px;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 5px;
  text-transform: uppercase;
}

.category-card-subtitle {
  font-size: 14px;
  color: var(--navy);
  margin-bottom: 20px;
  opacity: 0.7;
}

.category-card-btn {
  display: inline-block;
  background-color: var(--navy);
  color: var(--cream);
  padding: 10px 20px;
  border-radius: 5px;
  font-size: 12px;
  font-weight: 500;
  transition: background-color 0.3s ease;
  text-transform: uppercase;
}

.category-card-btn:hover {
  background-color: var(--navy-dark);
}

.category-card-image {
  position: absolute;
  bottom: 0;
  right: 10px;
  max-height: 80%;
  object-fit: contain;
}

/* ===== TEXT SECTION ===== */
.text-section {
  padding: 60px 0;
  text-align: center;
  background-color: var(--white);
}

.text-section-title {
  font-size: 36px;
  font-weight: 400;
  color: var(--primary-color);
  margin-bottom: 20px;
  font-style: italic;
}

.text-section-desc {
  font-size: 15px;
  color: var(--text-dark);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.8;
}

/* ===== BRAND GRID ===== */
.brand-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: none;
  width: calc(100% - 2px);
  margin: 32px auto;
  padding: 0;
}

.brand-card {
  position: relative;
  overflow: hidden;
  background-color: #eceee5;
  aspect-ratio: 4 / 5;
  border-radius: 6px;
}

.brand-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.brand-card:hover img {
  transform: scale(1.05);
}

.brand-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: linear-gradient(transparent, rgba(0,0,0,0.5));
  color: #fff;
}

.brand-card-name {
  font-size: 14px;
  font-weight: 700;
}

.brand-card-title {
  font-size: 16px;
  font-weight: 400;
}

.brand-card-price {
  font-size: 18px;
  font-weight: 700;
  margin-top: 5px;
}

/* ===== FOOTER ===== */
.footer {
  background-color: var(--cream);
  padding-top: 50px;
}

.footer-logo {
  text-align: center;
  margin-bottom: 40px;
}

.footer-logo img {
  max-height: 60px;
  width: auto;
  margin: 0 auto;
  filter: none;
}

.footer-columns {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 30px;
  padding-bottom: 40px;
}

.footer-col-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 18px;
}

.footer-col ul li {
  margin-bottom: 10px;
}

.footer-col ul li a {
  font-size: 14px;
  color: var(--navy);
  transition: color 0.3s ease;
}

.footer-col ul li a:hover {
  color: var(--primary-color);
}

/* Newsletter */
.footer-newsletter-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--navy);
  margin-bottom: 15px;
}

.newsletter-form {
  display: flex;
  gap: 0;
}

.newsletter-input {
  flex: 1;
  padding: 10px 15px;
  border: 1px solid var(--navy);
  border-right: none;
  border-radius: 0;
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  color: var(--navy);
  outline: none;
}

.newsletter-input::placeholder {
  color: var(--gray-light);
}

.newsletter-btn {
  padding: 10px 20px;
  background-color: var(--navy);
  color: var(--cream);
  border: 1px solid var(--navy);
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.newsletter-btn:hover {
  background-color: var(--navy-dark);
}

/* Footer Bottom */
.footer-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  border-top: 1px solid rgba(20, 37, 81, 0.1);
}

.social-icons {
  display: flex;
  gap: 15px;
}

.social-icons a {
  color: var(--navy);
  transition: color 0.3s ease;
}

.social-icons a:hover {
  color: var(--primary-color);
}

.social-icons svg {
  width: 28px;
  height: 28px;
}

.payment-icons {
  display: flex;
  gap: 10px;
  align-items: center;
}

.payment-icons img {
  height: 28px;
}

/* Copyright */
.footer-copyright {
  background-color: var(--navy);
  color: rgba(245, 246, 241, 0.6);
  text-align: left;
  padding: 15px 0;
  font-size: 13px;
}

/* ===== SEARCH OVERLAY ===== */
.search-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 65%;
  background-color: var(--white);
  z-index: 2000;
  display: none;
  flex-direction: column;
  padding: 20px;
}

.search-overlay.active {
  display: flex;
}

.search-overlay-bg {
  position: fixed;
  top: 65%;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0,0,0,0.5);
  z-index: 1999;
  display: none;
}

.search-overlay-bg.active {
  display: block;
}

.search-bar {
  display: flex;
  align-items: center;
  gap: 15px;
  max-width: 650px;
  margin: 0 auto;
  width: 100%;
  position: relative;
  flex-wrap: wrap;
}

.search-bar .logo img {
  filter: none;
  max-height: 60px;
  width: auto;
}

.search-bar input {
  flex: 1;
  padding: 14px 18px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  outline: none;
  transition: border-color 0.2s;
}
.search-bar input:focus {
  border-color: #0f172a;
}

.search-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
}

.live-search-results {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
  max-height: 420px;
  overflow-y: auto;
  z-index: 10000;
  border: 1px solid #e2e8f0;
  padding: 8px;
  display: none;
}
.live-search-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.2s;
  border-bottom: 1px solid #f1f5f9;
}
.live-search-item:last-child {
  border-bottom: none;
}
.live-search-item:hover {
  background: #f8fafc;
}
.live-search-item img {
  width: 48px;
  height: 60px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #f1f5f9;
}

/* ===== MOBILE MENU ===== */
.mobile-nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0,0,0,0.5);
  z-index: 3000;
  display: none;
}

.mobile-nav-overlay.active {
  display: block;
}

.mobile-nav {
  position: fixed;
  top: 0;
  left: -300px;
  width: 300px;
  height: 100%;
  background-color: var(--navy);
  z-index: 3001;
  transition: left 0.3s ease;
  overflow-y: auto;
  padding: 20px;
}

.mobile-nav.active {
  left: 0;
}

.mobile-nav-close {
  text-align: right;
  margin-bottom: 20px;
}

.mobile-nav-close button {
  background: none;
  border: none;
  color: var(--cream);
  cursor: pointer;
}

.mobile-nav ul li a {
  display: block;
  color: var(--cream);
  padding: 12px 0;
  font-size: 16px;
}

.mobile-nav > ul > li {
  border-bottom: 1px solid rgba(245,246,241,0.1);
}

.mobile-nav-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mobile-submenu-toggle {
  background: none;
  border: none;
  color: var(--cream);
  font-size: 12px;
  padding: 10px;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.mobile-has-dropdown.active .mobile-submenu-toggle {
  transform: rotate(180deg);
}

.mobile-submenu {
  display: none;
  padding-left: 15px;
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
  margin-bottom: 8px;
}

.mobile-has-dropdown.active .mobile-submenu {
  display: block;
}

.mobile-submenu li a {
  font-size: 14px;
  padding: 8px 10px;
  color: #d1d5db;
}

/* ===== COOKIE BANNER ===== */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: var(--navy);
  color: var(--cream);
  padding: 20px 25px;
  border-radius: 8px;
  max-width: 350px;
  font-size: 13px;
  line-height: 1.6;
  z-index: 5000;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.cookie-banner a {
  color: var(--primary-color);
  text-decoration: underline;
}

.cookie-banner-btn {
  display: inline-block;
  margin-top: 10px;
  float: right;
  background: none;
  border: none;
  color: var(--cream);
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  text-decoration: underline;
}

.cookie-banner.hidden {
  display: none;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
  .product-card {
    flex: 0 0 20%;
  }
  
  /* Fix header layout squeeze on mid-size laptops */
  .logo img, .header-logo-img {
    max-width: 220px !important;
  }
  .nav-links > ul > li > a {
    padding: 10px 10px;
    font-size: 12px;
  }
  .header-inner {
    gap: 10px;
  }
}

@media (max-width: 992px) {
  .nav-links {
    display: none;
  }

  .mobile-menu-btn {
    display: flex;
  }

  .product-card {
  flex: 0 0 33.333%;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .footer-columns {
    grid-template-columns: repeat(2, 1fr);
  }

  .section-title {
    font-size: 28px;
  }
}

@media (max-width: 768px) {
  .product-card {
    flex: 0 0 50%;
  }

  .footer-columns {
    grid-template-columns: 1fr;
  }

  .header-inner {
    min-height: 56px;
  }

  .logo img,
  .header-logo-img {
    max-width: 240px;
    height: 48px;
  }

  .hero-content .hero-number {
    font-size: 32px;
  }

  .hero-content .hero-subtitle {
    font-size: 14px;
  }

  .brand-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .text-section-title {
    font-size: 26px;
  }

  .section-title {
    font-size: 24px;
  }
}

@media (max-width: 480px) {
  .product-card {
    flex: 0 0 50%;
  }

  .hero-content {
    left: 5%;
    bottom: 10%;
  }

  .brand-grid {
    grid-template-columns: 1fr;
  }

  .announcement-slide {
    font-size: 10px;
    padding: 0 5%;
  }
}

/* Cart notification animation */
@keyframes slideInRight {
  from { transform: translateX(120%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Cart badge pulse on update */
.cart-count {
  transition: transform 0.3s ease;
}

.card-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: all 0.2s;
}
.card-dot.active {
  background: #fff;
  transform: scale(1.4);
}


/* Ensure logo fits on screen */
.logo img, .header-logo-img { max-width: 100%; height: auto; }

/* Unified Product Grid */
.product-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

/* ============================================================
   COMPREHENSIVE MOBILE RESPONSIVE
   ============================================================ */

/* --- TABLET (max-width: 992px) --- */
@media (max-width: 992px) {
  .product-card { flex: 0 0 33.333%; }
  .product-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }

  /* Category page: sidebar collapses above products */
  .category-page-container {
    flex-direction: column !important;
    gap: 20px !important;
    padding: 0 12px !important;
    margin: 20px auto !important;
  }
  .category-sidebar {
    width: 100% !important;
    order: -1;
  }
  .category-products {
    width: 100% !important;
  }

  /* Product detail modal: single column */
  .product-detail-modal-card {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
    padding: 20px !important;
    max-height: 95vh !important;
    border-radius: 14px !important;
  }
}

/* --- MOBILE (max-width: 768px) --- */
@media (max-width: 768px) {
  .product-card { flex: 0 0 50%; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }

  /* Container padding */
  .container { padding: 0 10px; }
  main .container { padding: 0 8px; }

  /* Header */
  .header-inner {
    min-height: 52px;
    padding: 4px 10px;
    gap: 0;
  }
  .mobile-menu-btn {
    width: 36px;
    height: 36px;
    padding: 6px;
    margin-right: 8px;
  }
  .mobile-menu-btn svg {
    width: 20px;
    height: 20px;
  }
  .logo {
    margin-right: 8px;
    min-width: 0;
    overflow: hidden;
  }
  .logo img, .header-logo-img {
    max-width: 140px !important;
    height: 34px !important;
    width: auto !important;
  }
  .header-icons { gap: 10px; margin-left: auto; flex-shrink: 0; }
  .header-icons svg { width: 21px; height: 21px; }
  .header-icons .cart-count {
    width: 16px; height: 16px;
    font-size: 9px;
    top: -5px; right: -6px;
  }

  /* Announcement bar */
  .announcement-bar { height: 30px; }
  .announcement-slide { font-size: 10px; }

  /* Hero slider */
  .hero-slider {
    border-radius: 8px;
    margin-top: 2px;
  }
  /* Removed hardcoded .hero-slide img height */
  .hero-content {
    left: 5%;
    bottom: 10%;
  }
  .hero-content .hero-number { font-size: 24px; }
  .hero-content .hero-subtitle { font-size: 12px; margin-bottom: 10px; }
  .hero-content .hero-cta { padding: 8px 14px; font-size: 11px; }

  /* Promo banners */
  .promo-banners-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px;
  }
  .promo-container-wide { margin: 12px auto; }

  /* Section titles */
  .section-title { font-size: 20px; margin-bottom: 16px; }
  .section-products { padding: 20px 0; }

  /* Slider arrows */
  .slider-arrow { width: 32px; height: 32px; }
  .slider-arrow svg { width: 16px; height: 16px; }
  .slider-arrow.prev { left: 2px; }
  .slider-arrow.next { right: 2px; }

  /* Product cards in slider */
  .products-slider { padding: 0 6px; }

  /* Product card text */
  .product-brand { font-size: 10px; }
  .product-name { font-size: 12px; line-height: 1.4; margin-bottom: 4px; }
  .product-card { padding: 6px; }
  .product-card-inner { padding: 8px; border-radius: 8px; }
  .sale-price { font-size: 14px; }
  .original-price { font-size: 11px; }

  /* Add-to-cart overlay: always visible on mobile (touch) */
  .add-to-cart-overlay {
    opacity: 1 !important;
    transform: translateY(0) !important;
    bottom: 6px; left: 6px; right: 6px;
  }
  .add-to-cart-btn {
    height: 36px;
    font-size: 11px;
    border-radius: 8px;
  }

  /* Category grid (homepage) */
  .category-grid {
    grid-template-columns: 1fr !important;
  }
  .category-card {
    min-height: 140px;
    padding: 20px 16px;
  }
  .category-card-title { font-size: 24px; }
  .category-card-subtitle { font-size: 12px; }
  .category-card-image { max-height: 70%; }

  /* Brand grid */
  .brand-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin: 16px auto;
  }

  /* Text section */
  .text-section { padding: 30px 0; }
  .text-section-title { font-size: 22px; }
  .text-section-desc { font-size: 13px; }

  /* Footer */
  .footer { padding-top: 30px; }
  .footer-logo { margin-bottom: 24px; }
  .footer-logo img { max-height: 44px; }
  .footer-columns {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 20px;
    padding-bottom: 24px;
  }
  .footer-col-title { font-size: 14px; margin-bottom: 12px; }
  .footer-col ul li a { font-size: 13px; }
  .footer-bottom-row {
    flex-direction: column;
    gap: 16px;
    padding: 16px 0;
    text-align: center;
  }
  .footer-copyright { font-size: 11px; padding: 10px 0; }

  /* Search overlay: full screen on mobile */
  .search-overlay {
    height: 100% !important;
    padding: 12px;
  }
  .search-overlay-bg { display: none !important; }
  .search-bar {
    max-width: 100%;
    flex-wrap: nowrap;
  }
  .search-bar input {
    padding: 12px 14px;
    font-size: 14px;
    border-radius: 8px;
  }
  .live-search-results {
    max-height: calc(100vh - 80px);
    border-radius: 10px;
  }

  /* Mobile nav */
  .mobile-nav { width: 280px; left: -280px; }

  /* Cookie banner */
  .cookie-banner {
    left: 10px;
    right: 10px;
    bottom: 10px;
    max-width: none;
    padding: 14px 16px;
    font-size: 12px;
    border-radius: 10px;
  }

  /* Product detail modal */
  .product-detail-modal-backdrop {
    padding: 0 !important;
    align-items: flex-end !important;
  }
  .product-detail-modal-card {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
    padding: 16px !important;
    max-height: 96vh !important;
    border-radius: 16px 16px 0 0 !important;
    max-width: 100% !important;
  }

  /* Modal image gallery */
  #pDetailMainImgWrapper {
    height: 320px !important;
    border-radius: 10px !important;
  }

  /* Modal text sizing */
  #pDetailTitle { font-size: 18px !important; }
  #pDetailAddToCartBtn,
  #pDetailBuyNowBtn {
    padding: 14px 16px !important;
    font-size: 13px !important;
    border-radius: 10px !important;
  }
  #pDetailWhatsAppBtn {
    padding: 12px 14px !important;
    font-size: 13px !important;
  }

  /* Review form grid */
  #pDetailReviewFormBox [style*="grid-template-columns:1fr 1fr"] {
    grid-template-columns: 1fr !important;
  }

  /* Cross-sell grid */
  #pDetailCrossSellGrid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  /* Quick size modal */
  #quickSizeSelectModal > div {
    max-width: 100% !important;
    border-radius: 16px 16px 0 0 !important;
    max-height: 80vh;
    overflow-y: auto;
  }

  /* Stock alert modal */
  #stockAlertModal > div {
    max-width: 100% !important;
    border-radius: 16px 16px 0 0 !important;
  }

  /* Corporate/policy modal */
  #corporatePolicyModal > div {
    max-width: 100% !important;
    max-height: 95vh !important;
    border-radius: 14px !important;
  }

  /* Category page specific */
  .category-page-container {
    flex-direction: column !important;
    gap: 16px !important;
    padding: 0 10px !important;
    margin: 16px auto !important;
  }
  .category-sidebar {
    width: 100% !important;
    padding: 14px !important;
    border-radius: 10px !important;
  }
  #pageCategoryTitle { font-size: 20px !important; }
  #sortSelect {
    padding: 8px 10px !important;
    font-size: 12px !important;
  }

  /* Category showcase section */
  #categoryShowcaseSection { padding: 20px 0 !important; }
  #categoryShowcaseTitle { font-size: 20px !important; }
  #categoryShowcaseGrid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
  }
}

/* --- SMALL MOBILE (max-width: 480px) --- */
@media (max-width: 480px) {
  .product-card { flex: 0 0 50%; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }

  /* Header even more compact */
  .header-inner { min-height: 46px; padding: 2px 6px; }
  .mobile-menu-btn {
    width: 32px;
    height: 32px;
    padding: 5px;
    margin-right: 6px;
  }
  .mobile-menu-btn svg { width: 18px; height: 18px; }
  .logo img, .header-logo-img {
    max-width: 110px !important;
    height: 28px !important;
  }
  .header-icons { gap: 8px; }
  .header-icons svg { width: 19px; height: 19px; }

  /* Hero */
  /* Removed hardcoded .hero-slide img height */

  /* Promo banners stack on very small screens */
  .promo-banners-grid {
    grid-template-columns: 1fr !important;
    gap: 8px;
  }

  /* Section title */
  .section-title { font-size: 17px; margin-bottom: 12px; }

  /* Product info text */
  .product-name { font-size: 11px; }
  .sale-price { font-size: 13px; }
  .product-brand { font-size: 9px; }
  .add-to-cart-btn { height: 32px; font-size: 10px; }

  /* Footer */
  .footer-columns {
    grid-template-columns: 1fr !important;
    gap: 16px;
  }
  .newsletter-form { flex-direction: column; gap: 8px; }
  .newsletter-input {
    border-right: 1px solid var(--navy) !important;
    border-radius: 6px !important;
  }
  .newsletter-btn { border-radius: 6px !important; }

  /* Brand grid */
  .brand-grid { grid-template-columns: 1fr; }

  /* Text section */
  .text-section-title { font-size: 18px; }

  /* Product detail modal */
  #pDetailMainImgWrapper { height: 260px !important; }
  #pDetailTitle { font-size: 16px !important; }

  /* Category showcase */
  #categoryShowcaseTitle { font-size: 17px !important; }
}

/* --- TOUCH DEVICE IMPROVEMENTS --- */
@media (hover: none) and (pointer: coarse) {
  /* Show add-to-cart on touch devices since hover doesn't work */
  .add-to-cart-overlay {
    opacity: 1 !important;
    transform: translateY(0) !important;
  }

  /* Bigger tap targets */
  .nav-dropdown a { padding: 14px 20px; }
  .mobile-nav ul li a { padding: 14px 0; }
  .footer-col ul li { margin-bottom: 12px; }
  .footer-col ul li a { font-size: 14px; }

  /* Disable hover zoom on product images for touch */
  .product-card-inner:hover .product-image-container > img {
    transform: none;
  }
}
