/* Nút trên thẻ sản phẩm: giữ kích thước ngay cả khi cột hẹp. */
.custom-atc-box .we-product-actions {
  --we-action-size: 40px;
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
.custom-atc-box .we-product-actions__details,
.custom-atc-box .we-product-actions__details:visited {
  display: inline-flex;
  flex: 1 1 0;
  align-items: center;
  justify-content: center;
  min-width: 0;
  height: var(--we-action-size);
  margin: 0;
  padding: 0 12px;
  border: 1px solid #8d0b28;
  border-radius: 999px;
  color: #fff;
  background: #8d0b28;
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  text-transform: none;
  white-space: nowrap;
  box-sizing: border-box;
}
.custom-atc-box .we-product-actions__details:hover {
  color: #fff;
  background: #5c0718;
  border-color: #5c0718;
}
.custom-atc-box button.we-tasting-toggle {
  display: inline-flex;
  flex: 0 0 var(--we-action-size);
  align-items: center;
  justify-content: center;
  width: var(--we-action-size);
  min-width: var(--we-action-size);
  max-width: var(--we-action-size);
  height: var(--we-action-size);
  min-height: var(--we-action-size);
  max-height: var(--we-action-size);
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid rgba(26, 20, 16, .24);
  border-radius: 50% !important;
  color: #8d0b28;
  background: transparent;
  box-shadow: none;
  font-family: inherit;
  font-size: 21px;
  font-weight: 600;
  line-height: 1;
  text-transform: none;
  cursor: pointer;
  box-sizing: border-box;
}
.custom-atc-box button.we-tasting-toggle:hover,
.custom-atc-box button.we-tasting-toggle.is-added {
  color: #fff;
  background: #8d0b28;
  border-color: #8d0b28;
}
.custom-atc-box button.we-tasting-toggle.is-added {
  font-size: 16px;
}
.custom-atc-box .we-product-actions__details:focus-visible,
.custom-atc-box button.we-tasting-toggle:focus-visible,
.we-tasting-drawer button:focus-visible,
.we-tasting-drawer a:focus-visible,
.we-tasting-selected button:focus-visible,
.we-tasting-selected a:focus-visible {
  outline: 2px solid #cfa96a;
  outline-offset: 2px;
}

/* Nút trên trang chi tiết sản phẩm Flatsome. */
button.button.we-tasting-single-button.we-tasting-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: none;
  min-height: 42px;
  height: auto;
  margin: 0;
  padding: 10px 15%;
  border-radius: 99px;
  font-family: inherit;
  line-height: 1.4;
  text-align: center;
  text-transform: none;
  white-space: normal;
  cursor: pointer;
}
button.button.we-tasting-single-button:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

/* Bảng danh sách thử vang ở góc màn hình. */
.we-tasting-drawer,
.we-tasting-selected { box-sizing: border-box; }
.we-tasting-drawer *,
.we-tasting-selected * { box-sizing: border-box; }
.we-tasting-drawer[hidden],
.we-tasting-drawer__body[hidden],
.we-tasting-drawer__notice[hidden],
.we-tasting-selected__empty[hidden] { display: none !important; }
.we-tasting-drawer {
  position: fixed;
  z-index: 9900;
  right: 24px;
  bottom: 24px;
  width: min(420px, calc(100vw - 32px));
  max-height: calc(100dvh - 48px);
  padding: 16px;
  border: 1px solid rgba(245,239,229,.15);
  border-radius: 22px;
  color: #f5efe5;
  background: #18120f;
  box-shadow: 0 28px 72px rgba(0,0,0,.34);
  font-family: inherit;
  animation: we-tasting-in .25s ease-out both;
}
.we-tasting-drawer.is-collapsed { width: auto; padding: 12px 14px 12px 18px; }
.we-tasting-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 14px;
}
.we-tasting-drawer.is-collapsed .we-tasting-drawer__head { margin-bottom: 0; }
.we-tasting-drawer__head strong {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #f5efe5;
  font-size: 16px;
  line-height: 1.2;
  letter-spacing: 0;
  text-transform: none;
}
.we-tasting-drawer__count {
  min-width: 29px;
  padding: 5px 9px;
  border-radius: 99px;
  color: #fff;
  background: #8d0b28;
  font-size: 11px;
  text-align: center;
}
.we-tasting-drawer__toggle,
.we-tasting-item__remove {
  display: grid;
  flex: none;
  place-items: center;
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #f5efe5;
  background: rgba(245,239,229,.12);
  font-size: 18px;
  font-weight: 400;
  line-height: 1;
  cursor: pointer;
}
.we-tasting-drawer__toggle:hover,
.we-tasting-drawer .we-tasting-item__remove:hover { color: #fff; background: #8d0b28; }
.we-tasting-drawer__body { display: grid; gap: 10px; max-height: calc(100dvh - 130px); overflow-y: auto; }
.we-tasting-drawer__notice { margin: 0; color: #f5efe5; font-size: 14px; }
.we-tasting-drawer__items { display: grid; gap: 8px; }
.we-tasting-drawer__item {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 12px;
  min-height: 76px;
  padding: 10px;
  border-radius: 14px;
}
.we-tasting-drawer__item { background: rgba(245,239,229,.07); }
.we-tasting-item__swatch {
  width: 48px;
  height: 54px;
  display: block;
  overflow: hidden;
  border: 1px solid rgba(26, 20, 16, .1);
  border-radius: 7px;
  background: #f5efe5;
}
.we-tasting-item__swatch img {
  display: block;
  width: 100%;
  height: 100%;
  margin: 0;
  object-fit: contain;
  object-position: center;
}
.we-tasting-item__info { display: grid; gap: 4px; min-width: 0; }
.we-tasting-drawer .we-tasting-item__name,
.we-tasting-drawer .we-tasting-item__name:visited {
  overflow: hidden;
  color: #f5efe5;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-decoration: none;
}
.we-tasting-drawer .we-tasting-item__name:hover { color: #fff; text-decoration: underline; }
.we-tasting-drawer .we-tasting-item__origin {
  overflow: hidden;
  color: rgba(245,239,229,.66);
  font-size: 12px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.we-tasting-drawer .we-tasting-item__remove { width: 27px; height: 27px; font-size: 16px; }
.we-tasting-drawer__book,
.we-tasting-drawer__book:visited {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 50px;
  padding: 10px 16px;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, #8d0b28, #aa2143);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
}
.we-tasting-drawer__book:hover { color: #fff; box-shadow: 0 9px 25px rgba(141,11,40,.35); }
.we-tasting-drawer__continue {
  width: 100%;
  margin: 0;
  padding: 7px 0;
  border: 0;
  color: rgba(245,239,229,.72);
  background: transparent;
  font-size: 12px;
  font-weight: 400;
  text-transform: none;
  cursor: pointer;
}
.we-tasting-drawer__continue:hover { color: #fff; background: transparent; }

/* Danh sách vang đã chọn trong biểu mẫu đặt lịch. */
.we-tasting-selected {
  margin: 16px 0;
  color: inherit;
  font-family: inherit;
}
.we-tasting-selected__title { margin: 0 0 6px; color: inherit; font-family: inherit; font-size: inherit; font-weight: 600; line-height: inherit; }
.we-tasting-selected__empty { margin: 0; opacity: .7; }
.we-tasting-selected__names { display: block; color: inherit; font: inherit; overflow-wrap: anywhere; }

@media (max-width: 549px) {
  .custom-atc-box .we-product-actions { --we-action-size: 38px; gap: 8px; }
  .custom-atc-box .we-product-actions__details { padding: 0 6px; font-size: 12px; }
  .we-tasting-drawer { right: 12px; bottom: 12px; width: calc(100vw - 24px); max-height: calc(100dvh - 24px); }
  .we-tasting-drawer__body { max-height: calc(100dvh - 110px); }
}
@media (prefers-reduced-motion: reduce) {
  .we-tasting-drawer { animation: none; }
}
@keyframes we-tasting-in {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: none; }
}
