/**
 * PC desktop restore — คืนขนาดต้นฉบับ index.html เท่านั้น
 * โหลดไฟล์นี้ท้ายสุด
 */

html.store-entered #purchaseFeedSection:not(.hidden) {
  display: block !important;
  visibility: visible !important;
}

@media (min-width: 1024px) {
  html.particles-front #storeSnowCanvas,
  html.particles-behind #storeSnowCanvas {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: none !important;
  }
  html.particles-behind #storeSnowCanvas {
    z-index: 1 !important;
  }
  html.particles-front #storeSnowCanvas {
    z-index: 97 !important;
  }
  html.store-entered.particles-behind .store-main {
    isolation: auto !important;
    background: transparent !important;
  }

  html[data-device="desktop"] {
    --pf-card-width: 300px;
    font-size: 16px;
  }

  /* ── แบนเนอร์ ── */
  html[data-device="desktop"] .goatx-inner {
    min-height: 480px !important;
    height: auto !important;
  }

  html[data-device="desktop"] .promo-slider,
  html[data-device="desktop"] .promo-slider-track,
  html[data-device="desktop"] .promo-slide,
  html[data-device="desktop"] .goatx-right {
    height: 100% !important;
    min-height: 100% !important;
  }

  html[data-device="desktop"] .promo-slide img,
  html[data-device="desktop"] .goatx-img {
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: none !important;
    object-fit: cover !important;
  }

  /* ── สถิติ 4 คol. ── */
  html[data-device="desktop"] .live-stats-grid,
  html[data-device="desktop"] #liveStatsGrid {
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 1rem !important;
  }

  /* ── ประวัติซื้อล่าสุด — ตาม index.html ── */
  html[data-device="desktop"] .purchase-feed-section {
    width: 100% !important;
    max-width: none !important;
    margin-top: 1.35rem !important;
  }

  html[data-device="desktop"] .purchase-feed-panel,
  html[data-device="desktop"] .purchase-feed-track-wrap {
    width: 100% !important;
    overflow: hidden !important;
    min-height: 110px !important;
  }

  html[data-device="desktop"] .purchase-feed-marquee,
  html[data-device="desktop"] .purchase-feed-track {
    align-items: stretch !important;
  }

  html[data-device="desktop"] .purchase-feed-card {
    flex: 0 0 300px !important;
    width: 300px !important;
    min-width: 300px !important;
    max-width: 300px !important;
    min-height: 102px !important;
    flex-shrink: 0 !important;
    display: flex !important;
    align-items: stretch !important;
    transform: none !important;
  }

  html[data-device="desktop"] .purchase-feed-thumb {
    flex: 0 0 88px !important;
    width: 88px !important;
    min-width: 88px !important;
    min-height: 102px !important;
    align-self: stretch !important;
    height: auto !important;
  }

  html[data-device="desktop"] .purchase-feed-thumb img {
    width: 100% !important;
    height: 100% !important;
    min-height: 100% !important;
    max-width: none !important;
    object-fit: cover !important;
    display: block !important;
  }

  html[data-device="desktop"] .purchase-feed-body {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    padding: 0.7rem 0.8rem 0.65rem !important;
  }

  html[data-device="desktop"] .purchase-feed-user {
    font-size: 0.98rem !important;
  }

  html[data-device="desktop"] .purchase-feed-product {
    font-size: 0.76rem !important;
  }

  html[data-device="desktop"] .purchase-feed-price {
    font-size: 0.9rem !important;
  }

  /* ── สินค้า 4 col ── */
  html[data-device="desktop"] .store-grid,
  html[data-device="desktop"] #storeGrid,
  html[data-device="desktop"] #categoryStoreGrid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 1.25rem !important;
  }

  html[data-device="desktop"] .sf-card {
    max-width: none !important;
    width: 100% !important;
  }

  html[data-device="desktop"] .sf-img-wrap {
    aspect-ratio: 1 / 1 !important;
    max-height: none !important;
  }

  html[data-device="desktop"] .sf-img {
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    object-fit: var(--sf-img-fit, cover) !important;
  }
}
