/* Mobile-specific overrides for styles.css (<=768px) */
/* This file is loaded only on small screens via the link media attribute. */

/* Layout basics */
main {
  margin: 10px auto;
  padding: 0 12px;
}

/* Header */
.header-content {
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  padding: 0 12px;
}
.logo-image {
  height: 100px;
}
.header-right {
  width: 100%;
  justify-content: space-between;
  gap: 10px;
}
.search-container {
  flex: 1;
  margin-right: 0;
  display: flex;
  gap: 8px;
}
#searchInput {
  width: 100%;
  box-sizing: border-box;
  flex: 1 1 auto;
}
#searchButton {
  width: 42px;
  flex-shrink: 0;
}

/* Navigation */
nav ul {
  flex-direction: column;
  align-items: stretch;
}
nav ul li a {
  padding: 12px 16px;
  text-align: center;
}

/* Carousel */
.carousel-slide img {
  height: 220px;
}
.carousel-caption {
  padding: 20px 15px 15px;
}
.carousel-caption h3 { font-size: 1.4em; }
.carousel-caption p { font-size: 0.95em; }
.carousel-control { display: none; }
.carousel-dots { bottom: 8px; }

/* Grids */
.featured-products h2, .featured-artists h2 {
  font-size: 1.6em;
  margin-bottom: 20px;
}
.product-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.product-grid .product-card {
  text-align: left;
}
.product-grid .product-card a {
  padding: 14px 12px 18px;
}
.product-grid .product-card img {
  height: 170px;
  border-radius: 12px;
  margin-bottom: 10px;
}
.product-grid .product-card h3 {
  font-size: 1em;
}
.product-grid .product-card .price {
  font-size: 1.05em;
}
.artist-grid {
  grid-template-columns: 1fr;
  gap: 16px;
}
.artist-card img { height: 120px; width: 120px; }
.product-card .quick-view-btn { display: none !important; }

/* Buttons */
.btn-primary, .btn-secondary, .btn-danger {
  width: 100%;
  margin-left: 0;
  padding: 12px 16px;
  box-sizing: border-box;
}

/* Footer */
.footer-content {
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.footer-section { min-width: 0; text-align: center; }

/* Cart modal */
.modal-content { max-width: 100%; }
.cart-summary { margin-left: 0; font-size: 1.05em; }
.cart-actions .btn-primary, .cart-actions .btn-secondary { width: 100%; }

/* Catalog & Artists */
.catalog-container h1 { font-size: 1.8em; margin-bottom: 20px; }
.alphabet-nav { padding: 12px; gap: 6px; }
.alphabet-nav a, .alphabet-nav span { width: 34px; height: 34px; font-size: 0.95em; }

/* Products listing */
.products-page-container { gap: 20px; }
/* Filter accordion mobile refinements */
.category-toggle { padding: 12px; font-size: 1em; }
.category-panel { padding: 10px 12px 12px; }
.checkbox-list { grid-template-columns: 1fr !important; }
.filter-actions .btn-secondary { width: 100%; }

/* Product detail pages (LP & CD) */
.product-page-container { padding: 20px; gap: 20px; }
.cd-layout { flex-direction: column; gap: 20px; }
.cd-image-left, .cd-image-right { max-width: 260px; flex: 0 0 auto; }
.cd-details-layout { grid-template-columns: 1fr; gap: 24px; }

.cd-purchase-info h1 { font-size: 1.8em; }
.cd-purchase-info h2 { font-size: 1.2em; margin-bottom: 14px; }
.cd-purchase-info .price { font-size: 1.8em; margin-bottom: 18px; }

.quantity-btn { width: 32px; height: 32px; }
#quantity { width: 50px; font-size: 1.1em; }

.product-gallery .main-image { margin-bottom: 10px; }
.thumbnail { width: 64px; height: 64px; }
.thumbnail-images {
  overflow-x: auto;
  flex-wrap: nowrap;
  gap: 8px;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
}
.thumbnail-images::-webkit-scrollbar { height: 6px; }
.thumbnail { flex: 0 0 64px; scroll-snap-align: start; }

.product-details h1 { font-size: 2em; }
.product-details h2 { font-size: 1.3em; margin-bottom: 16px; }
.product-details .price { font-size: 2em; }
.shipping-info { margin-bottom: 20px; }
.size-chips, .color-chips { gap: 6px; }
.selection-summary { font-size: 0.95em; }
.option-helper { font-size: 0.85em; }
.spec-row { grid-template-columns: 120px 1fr; }
.product-page-container.product-hifi {
  grid-template-columns: 1fr;
  padding: 20px;
  gap: 20px;
}
.product-page-container.product-hifi .product-gallery,
.product-page-container.product-hifi .product-details {
  width: 100%;
}
.product-page-container.product-hifi .thumbnail-images {
  flex-wrap: wrap;
  gap: 8px;
}

/* Lightbox */
.lightbox-content { width: 95%; max-width: 95%; }

/* Product rating (Ocjena stanja) */
.product-rating { padding-top: 20px; }
.rating-item {
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.rating-item > span:first-child {
  width: auto;
}
.rating-circles-container {
  flex-wrap: wrap;
  gap: 6px;
}
.rating-circle {
  width: 16px;
  height: 16px;
}
.rating-value {
  margin-left: 0;
  margin-top: 4px;
}
