/* ============================================================
   最安値で買いたい — Mobile-First Stylesheet
   Font: Noto Sans JP / Design: bakayasu.com-inspired overlay cards
   ============================================================ */

/* --- Reset & Variables --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:        #e53e3e;
  --primary-dark:   #c53030;
  --primary-light:  #fff5f5;
  --green:          #38a169;
  --green-bg:       #f0fff4;
  --yellow:         #d69e2e;
  --yellow-bg:      #fffff0;
  --text-main:      #1a1a1a;
  --text-muted:     #718096;
  --text-light:     #a0aec0;
  --bg-body:        #f7fafc;
  --bg-card:        #ffffff;
  --border:         #e2e8f0;
  --font-base:      'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Meiryo', sans-serif;
  --shadow-sm:      0 1px 3px rgba(0,0,0,0.06);
  --shadow-md:      0 4px 12px rgba(0,0,0,0.10);
  --shadow-lg:      0 8px 24px rgba(0,0,0,0.14);
  --radius-sm:      4px;
  --radius-md:      8px;
  --radius-lg:      12px;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: var(--font-base);
  color: var(--text-main);
  background: var(--bg-body);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: #2b6cb0; text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }
ul, ol { list-style: none; }

/* --- Focus indicators (WCAG 2.4.7) --- */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
[role="button"]:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: 2px;
}
.card-link:focus-visible {
  outline: 3px solid #fc8181;
  outline-offset: -3px;
}

/* --- Skip navigation (WCAG 2.4.1) --- */
.skip-link {
  position: absolute !important;
  top: -9999px !important;
  left: -9999px !important;
  background: var(--primary);
  color: #ffffff;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 700;
  z-index: 200;
  text-decoration: none;
}
.skip-link:focus {
  top: 8px !important;
  left: 16px !important;
}

/* --- Screen reader only --- */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* --- Layout --- */
.site-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.main-container {
  display: flex;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 12px;
  gap: 24px;
  flex: 1;
}

.content {
  flex: 1;
  min-width: 0;
}

.pc-only { display: none; }

/* --- Header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 16px;
  min-height: 52px;
}

.logo a {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
}
.logo a:hover { text-decoration: none; }
.logo-img { height: 40px; width: auto; display: block; }
.logo-tagline {
  font-size: 0.7rem;
  color: var(--text-muted);
  white-space: nowrap;
  margin-left: 12px;
}

.header-search { flex: 1; max-width: 360px; margin-left: 16px; }
.header-search .pagefind-ui { --pagefind-ui-scale: 0.8; }

/* Mobile category tabs */
.category-tabs {
  display: flex;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  background: #ffffff;
  border-top: 1px solid var(--border);
  position: relative;
  scroll-behavior: smooth;
}
.category-tabs::-webkit-scrollbar { display: none; }
.category-tabs::after {
  content: '';
  position: sticky;
  right: 0;
  top: 0;
  flex-shrink: 0;
  width: 32px;
  background: linear-gradient(to right, transparent, #ffffff);
  pointer-events: none;
}

.category-tab {
  flex: 0 0 auto;
  padding: 10px 14px;
  min-height: 44px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  display: flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
}
.category-tab:hover { color: var(--primary); text-decoration: none; }
.category-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
  font-weight: 700;
}

.cat-count {
  background: #edf2f7;
  color: var(--text-muted);
  font-size: 0.65rem;
  padding: 1px 5px;
  border-radius: 10px;
}

/* --- Product Grid (Mobile First: 2 columns) --- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

/* --- Product Card --- */
.product-card {
  position: relative;
  background: #fff;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 3 / 4;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}

.product-card:active {
  transform: scale(0.98);
}

.card-link {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  color: inherit;
  text-decoration: none;
}
.card-link:hover { text-decoration: none; }

/* Image area */
.card-image-area {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-bg-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  padding: 16px;
  transition: transform 0.4s ease;
}

.card-no-image {
  width: 100%;
  height: 100%;
  background: #f7f7f7;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #a0aec0;
  font-size: 2rem;
}

/* Card badges: top-left */
.card-badges {
  position: absolute;
  top: 8px; left: 8px;
  z-index: 2;
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.badge {
  padding: 3px 7px;
  border-radius: var(--radius-sm);
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1.2;
  color: #ffffff;
}
.badge-discount { background: var(--primary); }
.badge-lowest { background: #f6ad55; color: #1a202c; }

/* Sakura badge: top-right */
.card-sakura-badge {
  position: absolute;
  top: 0px; right: 8px;
  z-index: 2;
}


/* Card text area (fixed height) */
.card-info {
  padding: 10px 12px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-top: 1px solid #f0f0f0;
  flex-shrink: 0;
}

.card-title {
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.4;
  margin: 0;
  color: #1a202c;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-price-row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 2px;
}

.card-price-current {
  font-size: 1.05rem;
  font-weight: 700;
  color: #e53e3e;
}

.card-price-currency {
  font-size: 0.75rem;
  margin-right: 1px;
}

.card-price-original {
  font-size: 0.85rem;
  text-decoration: line-through;
  color: #2d3748;
}
.badge-trust-good { color: #276749; background: #c6f6d5; }
.badge-trust-caution { color: #744210; background: #fefcbf; }
.badge-trust-danger { color: #9b2c2c; background: #fed7d7; }
.badge-trust-unknown { color: #4a5568; background: #edf2f7; }

/* --- Page Header --- */
.page-header { margin-bottom: 16px; }
.page-title { font-size: 1.25rem; font-weight: 700; }
.page-description { font-size: 0.8125rem; color: var(--text-muted); margin-top: 4px; }

/* --- Sort Controls --- */
.sort-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.sort-label { font-size: 0.8125rem; color: var(--text-muted); }
.sort-btn {
  padding: 8px 14px;
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--bg-card);
  font-size: 0.8125rem;
  font-family: var(--font-base);
  cursor: pointer;
  color: var(--text-muted);
  transition: all 0.15s;
}
.sort-btn:hover { border-color: var(--primary); color: var(--primary); }
.sort-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  font-weight: 700;
}

/* --- Subcategory Tags --- */
.subcategory-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}
.subcategory-tag {
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.8125rem;
  color: var(--text-muted);
  background: var(--bg-card);
  transition: all 0.15s;
  cursor: pointer;
}
.subcategory-tag:hover,
.subcategory-tag.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  text-decoration: none;
}

/* --- Sidebar (Desktop) --- */
.sidebar {
  width: 220px;
  flex-shrink: 0;
}

.sidebar-inner {
  position: sticky;
  top: 72px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}

.sidebar-title {
  font-size: 0.9375rem;
  font-weight: 700;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--primary);
}

.sidebar-nav { list-style: none; }
.sidebar-nav li { margin-bottom: 2px; }

.sidebar-nav a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  color: var(--text-main);
  text-decoration: none;
  font-size: 0.8125rem;
  border-radius: 6px;
  transition: background-color 0.15s;
}
.sidebar-nav a:hover {
  background: #edf2f7;
  text-decoration: none;
}
.sidebar-nav a.active {
  background: var(--primary-light);
  color: var(--primary);
  font-weight: 700;
}
.sidebar-nav .count {
  font-size: 0.7rem;
  color: var(--text-light);
}

/* ============================================================
   Single Product Page
   ============================================================ */

.product-single { max-width: 960px; margin: 0 auto; }

/* Breadcrumb */
.breadcrumb {
  font-size: 0.8125rem;
  color: var(--text-light);
  margin-bottom: 16px;
}
.breadcrumb a { color: var(--text-light); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb-sep { margin: 0 6px; }

/* Product layout */
.product-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 32px;
}

.product-image-wrap {
  position: relative;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
}
.product-image { width: 100%; object-fit: contain; max-height: 320px; margin: 0 auto; }

.badge-lowest-large {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--primary);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  box-shadow: 0 2px 4px rgba(229,62,62,0.4);
}

.keepa-section { margin-top: 12px; }
.section-label {
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.product-info-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.product-brand {
  font-size: 0.8125rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.product-title {
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.5;
}

/* Price block */
.price-block {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

/* Price hero: large current price */
.price-hero {
  background: var(--primary-light);
  border-bottom: 1px solid #fed7d7;
  padding: 20px 16px;
  text-align: center;
  position: relative;
}
.price-hero-value {
  display: block;
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.2;
  letter-spacing: -0.02em;
}
.price-hero-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
}
.price-lowest-tag {
  display: inline-block;
  background: var(--primary);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  margin-bottom: 8px;
  letter-spacing: 0.05em;
}

/* Price history table */
.price-history {
  padding: 12px 16px;
}
.price-history-table {
  width: 100%;
  border-collapse: collapse;
}
.price-history-table td {
  padding: 7px 0;
  font-size: 0.8125rem;
  border-bottom: 1px solid var(--border);
}
.price-history-table tr:last-child td {
  border-bottom: none;
}
.ph-label {
  color: var(--text-muted);
  font-weight: 500;
}
.ph-value {
  text-align: right;
  font-weight: 700;
  color: var(--text-main);
}
.ph-value-lowest {
  color: var(--primary);
}

/* Discount from reference price */
.discount-from-ref {
  text-align: center;
  margin-top: 10px;
}
.discount-ref-badge {
  display: inline-block;
  background: var(--primary);
  color: #ffffff;
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 20px;
}

/* Keep existing discount-badge for other uses */
.discount-badge {
  background: var(--primary);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
}

/* Trust section */
.trust-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 14px;
}
.trust-title { font-size: 0.8125rem; font-weight: 700; margin-bottom: 8px; }
.trust-result {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius-sm);
}
.trust-icon { font-size: 1.2rem; flex-shrink: 0; }
.trust-text strong { display: block; font-size: 0.8125rem; margin-bottom: 2px; }
.trust-text p { font-size: 0.75rem; color: var(--text-muted); }
.trust-grade-a, .trust-grade-b { background: var(--green-bg); }
.trust-grade-c { background: var(--yellow-bg); }
.trust-grade-d { background: var(--primary-light); }
.trust-source-link { font-size: 0.75rem; color: var(--text-light); display: inline-block; margin-top: 8px; }

/* Amazon CTA */
.amazon-cta { margin: 4px 0; }
.amazon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 20px;
  background: #ff9900;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 700;
  font-family: var(--font-base);
  border-radius: var(--radius-md);
  text-decoration: none;
  transition: background 0.15s, transform 0.15s;
  box-shadow: 0 2px 8px rgba(255,153,0,0.4);
}
.amazon-btn:hover {
  background: #e68a00;
  transform: translateY(-1px);
  text-decoration: none;
  color: #ffffff;
}
.amazon-btn-icon { display: flex; align-items: center; }
.cta-note { font-size: 0.7rem; color: var(--text-light); margin-top: 6px; text-align: center; }

/* Price comparison */
.price-comparison { margin-top: 4px; }
.price-compare-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8125rem;
}
.price-compare-table th,
.price-compare-table td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}
.price-compare-table th {
  font-weight: 700;
  color: var(--text-muted);
  background: var(--bg-body);
  font-size: 0.75rem;
}
.price-compare-table .price-cell {
  font-weight: 700;
  color: var(--primary);
  white-space: nowrap;
}
.price-compare-table .effective-price {
  color: #e53e3e;
  font-weight: 700;
}
.price-compare-table .price-breakdown {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 0.75rem;
}
.compare-link {
  font-size: 0.8125rem;
  color: #2b6cb0;
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: inline-block;
}
.compare-link:hover { border-color: #2b6cb0; text-decoration: none; }
.price-note {
  font-size: 0.7rem;
  color: var(--text-light);
  margin-top: 6px;
}

/* Article dates */
.article-dates { font-size: 0.8125rem; color: var(--text-light); }
.article-dates p { margin-bottom: 2px; }
.published-date { color: var(--text-muted); }
.updated-date { font-size: 0.7rem; color: var(--text-light); }

/* Product details */
.product-details { display: flex; flex-direction: column; gap: 20px; }
.detail-section {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-sm);
}
.section-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--border);
}

/* Pros / Cons */
.pros-cons { display: grid; grid-template-columns: 1fr; gap: 12px; }
.pros-title, .cons-title { font-size: 1rem; font-weight: 700; margin-bottom: 10px; }
.pros-title { color: var(--green); }
.cons-title { color: var(--primary); }
.pros-list li, .cons-list li {
  font-size: 0.9375rem;
  padding: 8px 0 8px 22px;
  border-bottom: 1px solid var(--border);
  position: relative;
  line-height: 1.7;
}
.pros-list li::before { content: "✓"; position: absolute; left: 0; color: var(--green); font-weight: 700; }
.cons-list li::before { content: "✗"; position: absolute; left: 0; color: var(--primary); font-weight: 700; }

/* Review summary */
.review-summary p { font-size: 0.9375rem; line-height: 1.8; color: #333; }
.review-sources li { padding: 4px 0; }
.review-sources a { font-size: 0.8125rem; color: #2b6cb0; }

/* Keepa graph */
.keepa-graph { width: 100%; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.keepa-link { font-size: 0.8125rem; color: var(--text-light); display: inline-block; margin-top: 6px; }

/* Product body (markdown) */
.product-body h2 { font-size: 1rem; font-weight: 700; margin: 20px 0 10px; }
.product-body h3 { font-size: 0.9375rem; font-weight: 700; margin: 16px 0 8px; }
.product-body p { margin-bottom: 10px; line-height: 1.8; }
.product-body ul, .product-body ol { margin: 10px 0; padding-left: 20px; }
.product-body ul { list-style: disc; }
.product-body ol { list-style: decimal; }
.product-body li { margin-bottom: 5px; font-size: 0.8125rem; }

/* --- Footer --- */
.site-footer {
  background: #1a202c;
  color: #a0aec0;
  padding: 32px 0 16px;
  margin-top: 40px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 24px;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 16px;
}
.footer-logo {
  color: #ffffff;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  display: block;
  margin-bottom: 6px;
}
.footer-logo:hover { text-decoration: none; color: #ffffff; }
.footer-logo-img { height: 32px; width: auto; display: block; }
.footer-desc { font-size: 0.8125rem; color: #cbd5e0; line-height: 1.7; }
.footer-links h3 { color: #ffffff; font-size: 0.8125rem; font-weight: 700; margin-bottom: 8px; }
.footer-links ul li { margin-bottom: 4px; }
.footer-links a { font-size: 0.8125rem; color: #cbd5e0; }
.footer-links a:hover { color: #ffffff; }
.footer-bottom {
  border-top: 1px solid #2d3748;
  padding-top: 16px;
  max-width: 1280px;
  margin: 0 auto;
  padding-left: 16px;
  padding-right: 16px;
}
.affiliate-notice { font-size: 0.7rem; color: #a0aec0; margin-bottom: 6px; line-height: 1.7; }
.copyright { font-size: 0.8125rem; color: #a0aec0; }

/* --- Pagination --- */
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 24px; }
.pagination a, .pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-size: 0.8125rem;
  color: var(--text-muted);
  background: var(--bg-card);
}
.pagination .active, .pagination a:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  text-decoration: none;
}

/* --- Filter page --- */
.filter-page { }
.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
}
.filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 20px;
  border: 1px solid #feb2b2;
}
.filter-tag-remove {
  background: none;
  border: none;
  color: var(--primary);
  cursor: pointer;
  font-size: 0.875rem;
  padding: 0 2px;
}
.filter-hint { font-size: 0.8125rem; color: var(--text-light); }
.filter-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 8px;
}
.product-count { font-size: 0.8125rem; color: var(--text-muted); }
.sort-buttons { display: flex; gap: 6px; }
.no-results { text-align: center; padding: 40px 0; color: var(--text-light); font-size: 1rem; }
.loading-msg { text-align: center; padding: 40px 0; color: var(--text-light); }

/* --- Empty state --- */
.empty-state { text-align: center; padding: 40px 0; color: var(--text-light); font-size: 1rem; }

/* ============================================================
   Breakpoints (Mobile First)
   ============================================================ */

/* Tablet small */
@media (min-width: 560px) {
  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
  .card-title { font-size: 0.875rem; }
  .card-price-current { font-size: 1.1rem; }
  .pros-cons { grid-template-columns: 1fr 1fr; }
}

/* Tablet */
@media (min-width: 768px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
  }
  .main-container { padding: 20px; }
  .product-layout {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }
  .product-title { font-size: 1.25rem; }
  .price-hero-value { font-size: 2.75rem; }
  .detail-section { padding: 20px; }
  .footer-inner { grid-template-columns: 2fr 1fr 1fr; }
}

/* Desktop — sidebar appears */
@media (min-width: 1024px) {
  .pc-only { display: block; }
  .mobile-only { display: none; }

  .product-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }

  .main-container { padding: 24px; gap: 28px; }

  /* Card hover effects (desktop only) */
  .product-card:hover .card-bg-img {
    transform: scale(1.05);
  }
  .product-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
  }
  .product-card:active {
    transform: none;
  }

  .header-search { display: block; }
}

/* Wide desktop */
@media (min-width: 1280px) {
  .product-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* --- Related Products --- */
.related-products {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 2px solid var(--border);
}
.related-products .section-title {
  font-size: 1.1rem;
  margin-bottom: 16px;
}
.related-grid {
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 768px) {
  .related-grid { grid-template-columns: repeat(4, 1fr); }
}
