@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;600;700&display=swap");

/* Use one readable typeface across the storefront; preserve icon font glyphs. */
body,
body button,
body input,
body select,
body textarea,
body .mirror-page *:not(i):not(.fa):not([class^="icon-"]):not([class*=" icon-"]) {
  font-family: "Roboto", sans-serif !important;
}

.mirror-page,
.mirror-page * {
  font-family: "Roboto", sans-serif !important;
}

/* ===============================
   Header và Footer
   =============================== */

.mirror-page header,
.mirror-page .header,
.mirror-page .site-header,
.mirror-page footer,
.mirror-page .footer {
  background-color: #9b942f !important;
  color: #ffffff !important;
}

.mirror-page header a,
.mirror-page header span,
.mirror-page header p,
.mirror-page .header a,
.mirror-page .site-header a,
.mirror-page footer a,
.mirror-page footer span,
.mirror-page footer p,
.mirror-page .footer a {
  color: #ffffff !important;
}

.mirror-page header a:hover,
.mirror-page .header a:hover,
.mirror-page .site-header a:hover,
.mirror-page footer a:hover,
.mirror-page .footer a:hover {
  color: #f4f1d7 !important;
}

.mirror-page header svg,
.mirror-page .header svg,
.mirror-page .site-header svg,
.mirror-page footer svg,
.mirror-page .footer svg {
  color: #ffffff !important;
  fill: currentColor !important;
  stroke: currentColor !important;
}

/* ===============================
   Linery storefront overrides
   =============================== */

.mirror-page .home-slider {
  position: relative !important;
  display: block !important;
  overflow: hidden !important;
  border-radius: 24px !important;
}

.mirror-page .home-slider > a {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  height: auto !important;
  overflow: hidden !important;
  border-radius: inherit !important;
}

.mirror-page .home-slider > a::before,
.mirror-page .home-slider > a::after {
  display: none !important;
}

.mirror-page .home-slider > a > img {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  height: auto !important;
  max-width: none !important;
  object-fit: cover !important;
  transform: none !important;
  border-radius: inherit !important;
}

/* Khung ảnh bìa sách cố định tỷ lệ 2:3 */
.mirror-page .tsq-product-image {
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  aspect-ratio: 2 / 3 !important;
  background: #ffffff !important;
}

.mirror-page .tsq-product-image::before,
.mirror-page .tsq-product-image::after {
  display: none !important;
}

.mirror-page .tsq-product-image > img {
  position: relative !important;
  inset: auto !important;
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  object-fit: contain !important;
  transform: translateZ(0) !important;
  transition: transform 0.25s ease !important;
}

.mirror-page .item_product_main:hover .tsq-product-image > img {
  transform: scale(1.04) translateZ(0) !important;
  transform-origin: center !important;
}

/* Header icons */
.mirror-page .header-right.ega-d--flex {
  display: flex !important;
  align-items: center !important;
}

.mirror-page .header-right__icons {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
}

.mirror-page .header-right__icons > .header-icon,
.mirror-page .header-right__icons > .mini-cart {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 40px !important;
  min-width: 40px !important;
  height: 40px !important;
}

.mirror-page .header-right__icons > .header-icon,
.mirror-page .header-right__icons > .mini-cart > .header-icon {
  border: 1px solid rgba(255, 255, 255, 0.55) !important;
  border-radius: 999px !important;
  background: transparent !important;
  color: #ffffff !important;
}

.mirror-page .header-right__icons .header-icon img {
  display: block !important;
  width: 18px !important;
  height: 18px !important;
  max-width: 18px !important;
  object-fit: contain !important;
}

.mirror-page .header-right__icons .header-icon .tsq-header-svg-icon {
  display: block !important;
  flex: 0 0 20px !important;
  width: 20px !important;
  height: 20px !important;
  margin: 0 !important;
  color: #ffffff !important;
  overflow: visible !important;
}

.mirror-page .header-right__icons .header-icon.cart-count {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.mirror-page .header-right__icons .count_item {
  top: -6px !important;
  right: -5px !important;
}

/* Product group panels */
.mirror-page .section_index_prd {
  width: min(1240px, calc(100% - 40px)) !important;
  margin: 28px auto !important;
  padding: 30px 28px 34px !important;
  border: 1px solid rgba(31, 42, 36, 0.07) !important;
  border-radius: 24px !important;
  background: #ffffff !important;
  box-shadow: 0 16px 38px rgba(31, 42, 36, 0.07) !important;
}

.mirror-page .section_index_prd + .section_index_prd {
  margin-top: 34px !important;
}

.mirror-page .section_index_prd .container {
  width: 100% !important;
  max-width: none !important;
  padding: 0 !important;
}

.mirror-page .section_index_prd .heading-bar {
  margin-bottom: 24px !important;
  padding-bottom: 14px !important;
  border-bottom: 1px solid var(--linery-line) !important;
}

/* Mobile layout */
@media (max-width: 991px) {
  .mirror-page .section_index_prd {
    width: calc(100% - 28px) !important;
    margin: 20px auto !important;
    padding: 24px 14px 26px !important;
    border-radius: 18px !important;
  }

  .mirror-page .section_prd_feature {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 18px 10px !important;
    margin: 0 !important;
  }

  .mirror-page .section_prd_feature:not(.slick-slider) > .product-col,
  .mirror-page .section_prd_feature > .product-col {
    width: auto !important;
    min-width: 0 !important;
    min-height: 0 !important;
    max-width: none !important;
    flex: none !important;
    grid-column: auto !important;
    grid-row: auto !important;
    padding: 0 !important;
  }

  .mirror-page .section_prd_feature .item_product_main {
    min-width: 0 !important;
    padding: 6px !important;
  }

  .mirror-page .tsq-product-image {
    aspect-ratio: 2 / 3 !important;
  }
}

@media (max-width: 390px) {
  .mirror-page .section_prd_feature {
    column-gap: 8px !important;
  }

  .mirror-page .section_prd_feature .item_product_main {
    padding: 4px !important;
  }

  .mirror-page .tsq-product-image {
    aspect-ratio: 2 / 3 !important;
  }
}