/*
 * Toddy's Toys V5.2
 * Shared premium storefront product card
 */

.product-card-v2 {
  position: relative;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none;
  text-align: left;
  background:
    linear-gradient(
      155deg,
      rgba(18, 35, 59, .98),
      rgba(7, 18, 34, .98)
    );
  border: 1px solid rgba(143, 181, 231, .16);
  border-radius: 22px;
  box-shadow:
    0 18px 45px rgba(0, 0, 0, .24),
    inset 0 1px 0 rgba(255, 255, 255, .035);
  transform: translateZ(0);
  transition:
    transform .28s ease,
    border-color .28s ease,
    box-shadow .28s ease;
}

.product-card-v2:hover {
  transform: translateY(-7px);
  border-color: rgba(79, 158, 255, .58);
  box-shadow:
    0 30px 70px rgba(0, 0, 0, .38),
    0 0 0 1px rgba(74, 156, 255, .08);
}

.product-card-v2 .product-image {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background:
    radial-gradient(
      circle at 50% 35%,
      #ffffff 0,
      #f0f3f7 60%,
      #dfe4eb 100%
    );
}

.product-card-v2 .product-image::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 34%;
  pointer-events: none;
  background:
    linear-gradient(
      to top,
      rgba(5, 14, 27, .22),
      transparent
    );
}

.product-card-v2 .product-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: center;
  transition:
    transform .48s cubic-bezier(.2, .75, .25, 1),
    filter .35s ease;
}

.product-card-v2:hover .product-image img {
  transform: scale(1.06);
  filter: saturate(1.04) contrast(1.025);
}

.product-card-v2 .product-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 3;
  max-width: calc(100% - 70px);
  padding: 8px 12px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 999px;
  color: #fff;
  background:
    linear-gradient(135deg, #258fff, #086ed7);
  box-shadow: 0 9px 24px rgba(8, 110, 215, .3);
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: .1em;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}

.product-card-v2 .product-badge.is-best-seller {
  color: #211500;
  background:
    linear-gradient(135deg, #ffe07a, #f4ad12);
  box-shadow: 0 9px 24px rgba(244, 173, 18, .3);
}

.product-card-v2 .product-badge.is-sale {
  background:
    linear-gradient(135deg, #ff5067, #c91e3b);
  box-shadow: 0 9px 24px rgba(201, 30, 59, .28);
}

.product-card-v2 .product-badge.is-new {
  background:
    linear-gradient(135deg, #319cff, #0873df);
}

.product-card-v2 .product-badge.is-low-stock {
  color: #241800;
  background:
    linear-gradient(135deg, #ffd66a, #ef9e0b);
}

.product-card-v2 .product-badge.is-sold-out {
  color: #fff;
  background:
    linear-gradient(135deg, #687385, #343e4d);
  box-shadow: 0 9px 24px rgba(0, 0, 0, .25);
}

.product-card-view-icon {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 3;
  width: 37px;
  height: 37px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .4);
  border-radius: 50%;
  color: #fff;
  background: rgba(5, 14, 27, .62);
  box-shadow: 0 8px 22px rgba(0, 0, 0, .22);
  font-size: 16px;
  opacity: 0;
  transform: translateY(5px);
  backdrop-filter: blur(8px);
  transition:
    opacity .24s ease,
    transform .24s ease,
    background .24s ease;
}

.product-card-v2:hover .product-card-view-icon {
  opacity: 1;
  transform: translateY(0);
}

.product-card-v2 .product-info {
  min-height: 0 !important;
  padding: 20px;
  display: flex !important;
  flex: 1 1 auto;
  flex-direction: column;
}

.product-card-v2 .product-type {
  color: #69adff;
  font-size: 10px;
  font-weight: 900;
  line-height: 1.3;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.product-card-v2 .product-info h3 {
  height: auto !important;
  min-height: 48px !important;
  max-height: 48px !important;
  margin: 9px 0 9px !important;
  overflow: hidden;
  color: #f7faff;
  font-size: 19px;
  font-weight: 850;
  line-height: 24px !important;
  letter-spacing: -.025em;
  display: -webkit-box !important;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.product-card-v2 .product-card-rating {
  min-height: 24px;
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.product-card-v2 .product-card-stars {
  color: #ffc94f;
  font-size: 15px;
  letter-spacing: 1px;
  line-height: 1;
}

.product-card-v2 .product-card-rating small {
  color: #aab8ca;
  font-size: 11px;
  font-weight: 750;
}

.product-card-v2 .product-description {
  min-height: 42px;
  margin: 0 0 14px;
  overflow: hidden;
  color: #aeb9c9;
  font-size: 13px;
  line-height: 21px;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.product-card-stock {
  min-height: 22px;
  margin: 1px 0 12px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #9eadc0;
  font-size: 11px;
  font-weight: 750;
}

.product-card-stock > span {
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: #58a6ff;
  box-shadow: 0 0 0 4px rgba(88, 166, 255, .1);
}

.product-card-stock.is-ready {
  color: #76dca7;
}

.product-card-stock.is-ready > span {
  background: #39ca7c;
  box-shadow: 0 0 0 4px rgba(57, 202, 124, .11);
}

.product-card-stock.is-low {
  color: #f8ca65;
}

.product-card-stock.is-low > span {
  background: #f0af25;
  box-shadow: 0 0 0 4px rgba(240, 175, 37, .11);
}

.product-card-stock.is-out {
  color: #ff8594;
}

.product-card-stock.is-out > span {
  background: #ec4057;
  box-shadow: 0 0 0 4px rgba(236, 64, 87, .11);
}

.product-card-stock.is-made {
  color: #9fb3cc;
}

.product-card-v2 .product-card-footer {
  margin-top: auto;
}

.product-card-v2 .home-product-price {
  min-height: 34px;
  margin-top: 0 !important;
  display: flex;
  align-items: baseline;
  gap: 9px;
}

.product-card-v2 .home-product-price strong {
  color: #fff;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: -.025em;
}

.product-card-v2 .home-product-price .compare-price {
  color: #7f8da1;
  font-size: 13px;
  font-weight: 700;
  text-decoration: line-through;
}

.product-card-v2 .home-product-price .quote-price {
  color: #dceaff;
  font-size: 15px;
}

.product-card-v2 .product-card-button {
  width: 100% !important;
  min-width: 0 !important;
  min-height: 50px !important;
  margin-top: 15px !important;
  padding: 0 16px;
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid rgba(75, 158, 255, .58);
  border-radius: 12px;
  color: #fff;
  background:
    linear-gradient(135deg, #238fff, #086ed8);
  box-shadow: 0 10px 24px rgba(8, 110, 216, .22);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .035em;
  transition:
    transform .22s ease,
    box-shadow .22s ease,
    filter .22s ease;
}

.product-card-v2:hover .product-card-button {
  transform: translateY(-1px);
  box-shadow: 0 14px 29px rgba(8, 110, 216, .31);
  filter: brightness(1.07);
}

.product-card-v2 .product-card-button.is-disabled {
  color: #c0c8d4;
  border-color: rgba(180, 190, 205, .2);
  background: #344052;
  box-shadow: none;
}

@media (max-width: 1050px) {
  .product-card-v2 .product-info h3 {
    min-height: 48px !important;
    max-height: 48px !important;
  }
}

@media (max-width: 767px) {
  .product-card-v2 {
    border-radius: 18px;
  }

  .product-card-v2:hover {
    transform: translateY(-3px);
  }

  .product-card-v2 .product-image {
    aspect-ratio: 16 / 11;
  }

  .product-card-view-icon {
    opacity: 1;
    transform: none;
  }

  .product-card-v2 .product-info {
    padding: 18px;
  }

  .product-card-v2 .product-info h3 {
    min-height: auto !important;
    max-height: 48px !important;
    font-size: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .product-card-v2,
  .product-card-v2 *,
  .product-card-v2 *::before,
  .product-card-v2 *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Shared-card article mode */
.product-card-v2 article,
article.product-card-v2 {
  margin: 0;
}

.product-card-v2 .product-card-image-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  color: inherit;
  text-decoration: none;
}

.product-card-v2 .product-card-image-link img {
  position: relative;
  z-index: 0;
}

.product-card-v2 .product-card-image-link .product-badge,
.product-card-v2 .product-card-image-link .product-card-view-icon {
  pointer-events: none;
}

.product-card-v2 .product-info h3 a {
  color: inherit;
  text-decoration: none;
}

.product-card-v2 .product-info h3 a:hover {
  color: #77b6ff;
}

.product-card-v2 button.product-card-button {
  cursor: pointer;
  font-family: inherit;
}

.shop-product-grid,
.related-grid {
  align-items: stretch;
}

.shop-product-grid .product-card-v2,
.related-grid .product-card-v2 {
  height: 100%;
}

.related-grid .product-card-v2 .product-info {
  min-height: 248px !important;
}

@media (max-width: 767px) {
  .related-grid .product-card-v2 .product-info {
    min-height: 0 !important;
  }
}

/*
 * Toddy's Toys V5.2
 * Compact cards for related products and recommendation sections
 */

.related-products {
  padding: 76px 24px 92px;
}

.related-products .container {
  width: min(1180px, 100%);
  margin: 0 auto;
}

.related-products-heading {
  margin: 0 0 30px;
  text-align: center;
}

.related-products-heading h2 {
  margin: 7px 0 0;
}

.related-products-eyebrow {
  margin: 0;
  color: #65adff;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.related-products .related-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: stretch;
  gap: 20px;
}

.related-products .product-card--compact {
  min-width: 0;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(
      155deg,
      rgba(17, 34, 57, .98),
      rgba(6, 17, 32, .99)
    );
  border: 1px solid rgba(130, 174, 229, .18);
  border-radius: 18px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, .24);
}

.related-products .product-card--compact:hover {
  transform: translateY(-5px);
  border-color: rgba(74, 156, 255, .5);
  box-shadow: 0 25px 56px rgba(0, 0, 0, .34);
}

.related-products .product-card--compact .product-image {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3 !important;
  min-height: 0 !important;
  overflow: hidden;
  background: #eef1f5;
}

.related-products
.product-card--compact
.product-card-image-link {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
}

.related-products
.product-card--compact
.product-image img {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  display: block;
  object-fit: cover !important;
  object-position: center !important;
}

.related-products
.product-card--compact:hover
.product-image img {
  transform: scale(1.045);
}

.related-products
.product-card--compact
.product-badge {
  top: 12px !important;
  left: 12px !important;
  z-index: 5;
  max-width: calc(100% - 24px);
  padding: 7px 10px;
  border-radius: 999px;
  font-size: 9px;
  line-height: 1;
}

.related-products
.product-card--compact
.product-card-view-icon {
  display: none !important;
}

.related-products
.product-card--compact
.product-info {
  min-height: 244px !important;
  padding: 17px !important;
  display: flex !important;
  flex: 1 1 auto;
  flex-direction: column;
}

.related-products
.product-card--compact
.product-type {
  min-height: 14px;
  color: #65adff;
  font-size: 9px;
  line-height: 14px;
  letter-spacing: .15em;
}

.related-products
.product-card--compact
.product-info h3 {
  height: 44px !important;
  min-height: 44px !important;
  max-height: 44px !important;
  margin: 8px 0 8px !important;
  overflow: hidden !important;
  font-size: 16px !important;
  line-height: 22px !important;
  display: -webkit-box !important;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.related-products
.product-card--compact
.product-card-rating {
  min-height: 20px;
  margin: 0 0 7px;
}

.related-products
.product-card--compact
.product-card-stars {
  font-size: 13px;
}

.related-products
.product-card--compact
.product-card-rating small {
  font-size: 10px;
}

.related-products
.product-card--compact
.product-card-stock {
  min-height: 19px;
  margin: 0 0 8px;
  font-size: 10px;
}

.related-products
.product-card--compact
.product-card-stock > span {
  width: 6px;
  height: 6px;
  flex-basis: 6px;
}

.related-products
.product-card--compact
.product-card-footer {
  margin-top: auto;
}

.related-products
.product-card--compact
.home-product-price {
  min-height: 29px;
}

.related-products
.product-card--compact
.home-product-price strong {
  font-size: 18px;
}

.related-products
.product-card--compact
.home-product-price .compare-price {
  font-size: 12px;
}

.related-products
.product-card--compact
.product-card-button {
  width: 100% !important;
  min-height: 44px !important;
  margin-top: 12px !important;
  border-radius: 10px;
  font-size: 11px;
}

@media (max-width: 1000px) {
  .related-products .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .related-products {
    padding: 56px 14px 70px;
  }

  .related-products .related-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .related-products .product-card--compact {
    display: grid;
    grid-template-columns: 42% 58%;
    border-radius: 16px;
  }

  .related-products
  .product-card--compact
  .product-image {
    height: 100%;
    min-height: 220px !important;
    aspect-ratio: auto !important;
  }

  .related-products
  .product-card--compact
  .product-info {
    min-width: 0;
    min-height: 220px !important;
    padding: 15px !important;
  }

  .related-products
  .product-card--compact
  .product-info h3 {
    height: 66px !important;
    min-height: 66px !important;
    max-height: 66px !important;
    -webkit-line-clamp: 3;
    line-clamp: 3;
  }

  .related-products
  .product-card--compact
  .product-card-button {
    min-height: 42px !important;
    padding: 0 10px;
  }
}
