/* ==========================================================================
   Product-card sale countdown (CountdownOtp): one solid tile per unit.
   Loaded after offers.css. Layout rules (row / column switch) stay in offers.css;
   this file only restyles the tiles and re-declares sizes per container width.
   Days / hours / minutes = deep slate, seconds = the sale badge's orange-red.
   ========================================================================== */

.cd-otp {
  gap: 0.2rem;
}
.cd-otp .cd-otp-ico {
  color: #e11d48;
}
.cd-otp .cd-otp-cell {
  min-width: 26px;
  height: 24px;
  padding: 0 4px;
  border-radius: 6px;
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #fff;
  background: linear-gradient(180deg, #273449 0%, #0f172a 100%);
  border: 0;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 2px 6px -2px rgba(15, 23, 42, 0.55);
  animation: cd-tile-tick 0.35s ease-out;
}
@keyframes cd-tile-tick {
  from { opacity: 0.7; transform: translateY(-1px); }
  to { opacity: 1; transform: none; }
}
.cd-otp .cd-otp-days .cd-otp-cell {
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  line-height: 24px;
}
.cd-otp .cd-otp-group--secs .cd-otp-cell {
  background: linear-gradient(135deg, #f97316 0%, #e11d48 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    0 3px 8px -3px rgba(225, 29, 72, 0.7);
}
.cd-otp .cd-otp-unit {
  margin-left: 1px;
  font-size: 0.68rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.72);
}
.cd-otp .cd-otp-sep {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 800;
  color: #e11d48;
  transform: translateY(-1px);
}
.cd-otp.cd-otp--idle .cd-otp-cell {
  color: rgba(255, 255, 255, 0.45);
}
.pcard-deal .pcard-deal-off {
  padding: 0.36rem 0.5rem;
  font-size: 0.72rem;
}
.pcard-thumb .pcard-deal {
  padding: 0.3rem 0.36rem 0.3rem 0.3rem;
  border-radius: 13px;
}

/* Narrower cards: step the sizes down so the bar never overflows. */
@container pthumb (max-width: 300px) {
  .cd-otp { gap: 0.16rem; }
  .cd-otp .cd-otp-cell { min-width: 24px; height: 23px; padding: 0 3px; font-size: 0.82rem; }
  .cd-otp .cd-otp-days .cd-otp-cell { line-height: 23px; }
  .cd-otp .cd-otp-sep { font-size: 0.84rem; }
  .cd-otp .cd-otp-unit { font-size: 0.64rem; }
  .pcard-deal .pcard-deal-off { padding: 0.32rem 0.44rem; font-size: 0.68rem; }
  .pcard-thumb .pcard-deal { gap: 0.3rem; padding: 0.28rem 0.3rem 0.28rem 0.28rem; }
}
@container pthumb (max-width: 270px) {
  .cd-otp .cd-otp-cell { min-width: 22px; height: 22px; font-size: 0.78rem; }
  .cd-otp .cd-otp-days .cd-otp-cell { line-height: 22px; }
  .cd-otp .cd-otp-sep { font-size: 0.8rem; }
  .cd-otp .cd-otp-unit { font-size: 0.62rem; }
  .pcard-deal .pcard-deal-off { padding: 0.3rem 0.4rem; font-size: 0.64rem; }
}
@container pthumb (max-width: 235px) {
  .cd-otp { gap: 0.12rem; }
  .cd-otp .cd-otp-cell { min-width: 20px; height: 20px; padding: 0 2px; border-radius: 5px; font-size: 0.72rem; }
  .cd-otp .cd-otp-days .cd-otp-cell { line-height: 20px; }
  .cd-otp .cd-otp-sep { font-size: 0.74rem; }
  .cd-otp .cd-otp-unit { font-size: 0.58rem; }
  .pcard-deal .pcard-deal-off { padding: 0.28rem 0.38rem; font-size: 0.6rem; }
}
/* <=205px: offers.css stacks badge above the timer (full width) - tiles can grow again. */
@container pthumb (max-width: 205px) {
  .pcard-thumb .pcard-deal { gap: 0.28rem; padding: 0.3rem; border-radius: 11px; }
  .pcard-deal .pcard-deal-off { align-self: flex-start; padding: 0.28rem 0.4rem; font-size: 0.62rem; }
  .cd-otp { justify-content: flex-start; gap: 0.14rem; }
  .cd-otp .cd-otp-cell { min-width: 22px; height: 21px; padding: 0 3px; font-size: 0.76rem; }
  .cd-otp .cd-otp-days .cd-otp-cell { line-height: 21px; }
  .cd-otp .cd-otp-sep { font-size: 0.78rem; }
  .cd-otp .cd-otp-unit { font-size: 0.6rem; }
}
@container pthumb (max-width: 150px) {
  .cd-otp { gap: 0.08rem; }
  .cd-otp .cd-otp-cell { min-width: 17px; height: 18px; padding: 0 2px; font-size: 0.64rem; border-radius: 4px; }
  .cd-otp .cd-otp-days .cd-otp-cell { line-height: 18px; }
  .cd-otp .cd-otp-sep { font-size: 0.66rem; }
  .cd-otp .cd-otp-unit { font-size: 0.54rem; }
}

/* Deal bar pinned flush to the bottom edge of the image (all widths, consistent):
   frosted, semi-transparent glass so the photo shows through; tiles stay solid for legibility. */
.pcard-thumb .pcard-deal {
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 0;
  background: rgba(255, 255, 255, 0.58);
  -webkit-backdrop-filter: blur(10px) saturate(1.5);
  backdrop-filter: blur(10px) saturate(1.5);
  border-top: 1px solid rgba(255, 255, 255, 0.75);
  box-shadow: 0 -8px 18px -14px rgba(15, 23, 42, 0.45);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .pcard-thumb .pcard-deal { background: rgba(255, 255, 255, 0.86); }
}

/* Phones: no floating wishlist / quick-view icons on the card image (desktop hover unchanged). */
@media (max-width: 640px) {
  .pcard .pcard-float {
    display: none;
  }
}
