product-template.product-template {
  display: block;
  background: var(--ivory-surface, #faf9f9);
  color: var(--ivory-text, #1a1c1c);
}

product-template .product-template__media-wrapper {
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
}

product-template .product-template__media-slider,
product-template .product-template__media-stack {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

product-template .product-template__media-slide,
product-template .product-template__stack-item,
product-template .ivory-product-detail__image-frame {
  aspect-ratio: 1 / 1;
  background: #f7f2e9;
}

product-template .product-template__media-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain !important;
}

product-template .product-template__media-thumbs {
  width: 100%;
  max-width: 100%;
  margin-top: 16px;
  overflow: hidden;
}

product-template .product-template__media-thumb {
  width: 82px !important;
  height: 82px;
  flex: 0 0 82px;
  aspect-ratio: 1 / 1;
  border: 1px solid rgba(202, 185, 154, 0.32);
  border-radius: var(--ivory-radius, 4px);
  overflow: hidden;
  background: #f7f2e9;
  opacity: 0.7;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(99, 79, 20, 0.04);
}

product-template .product-template__media-thumb.swiper-slide-thumb-active {
  border-color: var(--ivory-gold, #735c00);
  opacity: 1;
}

product-template .product-template__media-thumb-image {
  width: 100%;
  height: 100%;
  object-fit: cover !important;
}

product-template .product-template__title {
  margin: 0 0 18px;
}

product-template .product-template__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
  color: var(--ivory-muted, #4d4635);
  font-size: 13px;
  line-height: 1.4;
}

product-template .product-template__meta-item {
  display: inline-flex;
  gap: 8px;
  align-items: baseline;
}

product-template .product-template__meta-label {
  color: rgba(26, 28, 28, 0.7);
}

product-template .product-template__meta strong,
product-template .product-template__meta a {
  color: var(--ivory-text, #1a1c1c);
  font-weight: 600;
  text-decoration: none;
}

product-template .product-template__price-box {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 28px;
}

product-template .product-template__price-current {
  color: var(--ivory-gold, #735c00);
  font-size: clamp(24px, 2.2vw, 36px);
  font-weight: 600;
  line-height: 1;
}

product-template .product-template__price-compare {
  display: none;
  color: rgba(26, 28, 28, 0.7);
  font-size: 15px;
  text-decoration: line-through;
}

product-template .product-template__price-sale {
  display: none;
  padding: 5px 8px;
  border-radius: var(--ivory-radius, 4px);
  background: var(--ivory-gold, #735c00);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
}

product-template .product-template__price-compare.is-visible,
product-template .product-template__price-sale.is-visible {
  display: block;
}

product-template .product-template__variant-picker,
product-template .product-template__commitments,
product-template .product-template__sharing {
  margin-top: 24px;
}

product-template .product-template__actions {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 56px;
  gap: 12px;
  align-items: end;
  margin-top: 24px;
}

product-template .product-template__quantity-group {
  display: grid;
  grid-column: 1;
  grid-row: 1;
  gap: 10px;
  margin: 0;
}

product-template .product-template__quantity-group .quantity-selector {
  width: 100%;
}

product-template .product-template__quantity-label,
product-template .variant-picker__label {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  color: var(--ivory-text, #1a1c1c);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.05em;
  line-height: 1;
  text-transform: uppercase;
}

product-template .variant-picker__size-guide-btn {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  gap: 6px;
  margin-left: 4px;
  padding: 0 10px;
  border: 1px solid rgba(161, 125, 22, 0.28);
  border-radius: var(--ivory-radius, 4px);
  background: rgba(255, 255, 255, 0.76);
  color: var(--ivory-gold, #735c00);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1;
  text-transform: none;
}

product-template .variant-picker__size-guide-btn:hover,
product-template .variant-picker__size-guide-btn:focus-visible {
  border-color: var(--ivory-text, #1a1c1c);
  background: var(--ivory-text, #1a1c1c);
  color: #ffffff;
  outline: none;
}

product-template .variant-picker__items,
product-template .product-template__variant-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

product-template .variant-picker__item-label,
product-template .product-template__variant-option,
product-template quantity-selector,
product-template .quantity-selector,
product-template .quantity-selector__btn,
product-template .quantity-selector__input {
  border-radius: var(--ivory-radius, 4px);
}

product-template .variant-picker__item-label,
product-template .product-template__variant-option {
  min-height: 44px;
  border: 1px solid rgba(202, 185, 154, 0.38);
  background: rgba(255, 255, 255, 0.68);
  color: var(--ivory-text, #1a1c1c);
  transition: border-color 180ms ease, color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

product-template input:checked + .variant-picker__item-label,
product-template .product-template__variant-option.active {
  border-color: var(--ivory-gold, #735c00);
  background: rgba(255, 250, 236, 0.82);
  color: var(--ivory-gold, #735c00);
  box-shadow: 0 12px 28px rgba(115, 92, 0, 0.04);
}

product-template .product-template__buttons {
  display: contents;
}

product-template .product-template__add-btn,
product-template .product-template__buy-btn {
  height: 56px;
  min-width: 0;
  min-height: 56px;
  padding-inline: 16px;
  white-space: normal;
}

product-template .product-template__add-btn {
  grid-column: 2 / -1;
  grid-row: 1;
}

product-template .product-template__buy-btn {
  grid-column: 1 / 3;
  grid-row: 3;
}

product-template .product-template__add-btn .button-content,
product-template .product-template__buy-btn .button-content {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}

product-template .product-template__wishlist-btn,
product-template .product-template__compare-btn {
  display: inline-flex;
  width: 56px;
  min-width: 56px;
  height: 56px;
  min-height: 56px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(202, 185, 154, 0.34);
  border-radius: var(--ivory-radius, 4px);
  background: rgba(255, 255, 255, 0.72);
  color: var(--ivory-text, #1a1c1c);
  flex: 0 0 56px;
  grid-row: 3;
}

product-template .product-template__wishlist-btn {
  grid-column: 3;
}

product-template .product-template__compare-btn {
  grid-column: 3;
}

product-template .product-template__actions:has(.product-template__compare-btn) {
  grid-template-columns: auto minmax(0, 1fr) 56px 56px;
}

product-template .product-template__actions:has(.product-template__compare-btn) .product-template__buy-btn {
  grid-column: 1 / 3;
}

product-template .product-template__actions:has(.product-template__compare-btn) .product-template__wishlist-btn {
  grid-column: 4;
}

product-template .product-template__actions:not(:has(.product-template__wishlist-btn)):not(:has(.product-template__compare-btn)) .product-template__buy-btn {
  grid-column: 1 / -1;
}

product-template .coupon-preview {
  display: grid;
  grid-column: 1 / -1;
  grid-row: 2;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 12px 18px;
  align-items: center;
  width: 100%;
  margin: 0;
  padding: 14px 16px;
  border: 0;
  border-radius: var(--ivory-radius, 4px);
  background: rgba(246, 241, 232, 0.78);
  color: var(--ivory-text, #1a1c1c);
}

product-template .coupon-preview:focus-visible {
  outline: 2px solid var(--ivory-gold, #735c00);
  outline-offset: 3px;
}

product-template .coupon-preview__label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ivory-muted, #4d4635);
  font-size: 13px;
  line-height: 1.2;
  white-space: nowrap;
}

product-template .coupon-preview__label .icon {
  width: 20px;
  height: 20px;
  color: var(--ivory-gold, #735c00);
  flex: 0 0 auto;
}

product-template .coupon-preview__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, max-content));
  gap: 8px;
  justify-content: end;
  min-width: 0;
}

product-template .coupon-preview__item {
  display: inline-flex;
  min-width: 96px;
  min-height: 32px;
  align-items: center;
  justify-content: center;
  padding: 0 11px;
  border: 1px solid rgba(161, 125, 22, 0.24);
  border-radius: var(--ivory-radius, 4px);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ivory-gold, #735c00);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.03em;
  line-height: 1;
}

product-template .coupon-preview__code {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

product-template .coupon-preview__overlay {
  display: none;
}

product-template .product-template__commitments {
  display: grid;
  gap: 10px;
  padding-top: 24px;
  border-top: 1px solid rgba(202, 185, 154, 0.24);
}

product-template .product-template__commitment-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  color: var(--ivory-muted, #4d4635);
  font-size: 13px;
  line-height: 1.5;
}

product-template .product-template__commitment-item img {
  width: 42px;
  height: 42px;
  padding: 7px;
  border: 1px solid rgba(202, 185, 154, 0.32);
  border-radius: 50%;
  background: rgba(246, 241, 232, 0.9);
  object-fit: contain;
}

product-template .product-template__tabs {
  border: 0;
  border-radius: var(--ivory-radius, 4px);
  background: transparent;
  box-shadow: none;
}

product-template .product-template__tabs-nav {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(18px, 2vw, 34px);
  border-bottom: 1px solid rgba(202, 185, 154, 0.22);
}

product-template .product-template__tab-btn {
  min-height: 54px;
  padding: 0 0 14px;
  border: 0;
  border-bottom: 1px solid transparent;
  background: transparent;
  color: var(--ivory-muted, #4d4635);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

product-template .product-template__tab-btn.active {
  border-bottom-color: var(--ivory-gold-bright, #d4af37);
  color: var(--ivory-gold, #735c00);
}

product-template .product-template__tab-panel {
  display: none;
  padding: clamp(24px, 3vw, 44px) 0 0;
}

product-template .product-template__tab-panel.active {
  display: block;
}

product-template .product-template__description-content {
  color: var(--ivory-muted, #4d4635);
  font-size: 16px;
  line-height: 1.85;
}

product-template .product-template__description-content h2,
product-template .product-template__description-content h3 {
  color: var(--ivory-text, #1a1c1c);
  font-family: var(--font-family-heading, "Playfair Display", serif);
  font-weight: 500;
}

product-template .product-template__relate {
  display: block;
  margin-top: clamp(40px, 6vw, 96px);
}

product-template .swiper-button-next,
product-template .swiper-button-prev {
  color: var(--ivory-text, #1a1c1c);
}

.product-sticky-add {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 260;
  display: block;
  border-top: 1px solid rgba(202, 185, 154, 0.24);
  background: rgba(251, 250, 247, 0.96);
  color: var(--ivory-text, #1a1c1c);
  box-shadow: 0 -18px 44px rgba(115, 92, 0, 0.08);
  opacity: 0;
  pointer-events: none;
  transform: translateY(calc(100% + 18px));
  transition: transform 220ms ease, opacity 220ms ease, visibility 0s linear 220ms;
  visibility: hidden;
}

.product-sticky-add.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  transition: transform 220ms ease, opacity 220ms ease, visibility 0s linear 0s;
  visibility: visible;
}

body.product-sticky-visible .float-social,
body.product-sticky-visible .back-to-top {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

body.product-sticky-visible .float-social__panel {
  max-height: calc(100vh - 228px);
}

.product-sticky-add__container {
  display: flex;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
  min-height: 84px;
  padding-block: 12px calc(12px + env(safe-area-inset-bottom));
}

.product-sticky-add__product {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 12px;
}

.product-sticky-add__image {
  width: 60px;
  height: 60px;
  border: 1px solid rgba(202, 185, 154, 0.3);
  border-radius: var(--ivory-radius, 4px);
  background: #fff;
  flex: 0 0 60px;
  object-fit: cover;
}

.product-sticky-add__info {
  min-width: 0;
}

.product-sticky-add__title {
  display: block;
  margin: 0 0 4px;
  overflow: hidden;
  color: var(--ivory-text, #1a1c1c);
  font-family: var(--font-family-heading, "Playfair Display", serif);
  font-size: 18px;
  font-weight: 500;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-sticky-add__variant {
  margin-bottom: 4px;
  overflow: hidden;
  color: var(--ivory-muted, #4d4635);
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.product-sticky-add__price {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: baseline;
  color: var(--ivory-gold, #735c00);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}

.product-sticky-add__price .price-compare {
  color: rgba(26, 28, 28, 0.7);
  font-weight: 400;
  text-decoration: line-through;
}

.product-sticky-add__actions {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
  align-items: center;
}

.product-sticky-add__btn {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding-inline: 18px;
  border-radius: var(--ivory-radius, 4px);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.product-sticky-add__btn--add {
  border: 1px solid var(--ivory-gold-bright, #d4af37);
  background: #fff;
  color: var(--ivory-gold, #735c00);
}

.product-sticky-add__btn--add,
.product-sticky-add__btn--buy {
  border-radius: var(--ivory-radius, 4px);
}

.product-lightbox {
  position: fixed;
  inset: 0;
  z-index: 320;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.product-lightbox.is-active {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
}

.product-lightbox .lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26, 28, 28, 0.82);
}

.product-lightbox .lightbox-content {
  position: relative;
  z-index: 1;
  width: min(92vw, 1180px);
  height: min(86vh, 920px);
}

.product-lightbox .lightbox-image-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
}

.product-lightbox .lightbox-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.product-lightbox .lightbox-close,
.product-lightbox .lightbox-prev,
.product-lightbox .lightbox-next {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: var(--ivory-radius, 4px);
  background: rgba(255, 255, 255, 0.92);
  color: var(--ivory-text, #1a1c1c);
}

.product-lightbox .lightbox-close {
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
}

.product-lightbox .lightbox-prev,
.product-lightbox .lightbox-next {
  top: 50%;
  width: 44px;
  height: 54px;
  margin: 0;
  transform: translateY(-50%);
}

.product-lightbox .lightbox-prev {
  left: 16px;
}

.product-lightbox .lightbox-next {
  right: 16px;
}

.product-lightbox .lightbox-close::after,
.product-lightbox .lightbox-prev::after,
.product-lightbox .lightbox-next::after {
  font-size: 18px;
}

coupon-modal.coupon-modal-wrapper,
size-guide-modal.size-guide-modal-wrapper {
  position: fixed;
  inset: 0;
  z-index: 310;
  display: block !important;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0s linear 0.3s;
}

coupon-modal.coupon-modal-wrapper.show,
size-guide-modal.size-guide-modal-wrapper.show {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.3s ease, visibility 0s linear 0s;
}

coupon-modal.coupon-modal-wrapper.hidden,
size-guide-modal.size-guide-modal-wrapper.hidden {
  display: block !important;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

coupon-modal .coupon-modal-overlay,
size-guide-modal .size-guide-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: -1;
  border: 0;
  background: rgba(26, 28, 28, 0.58);
  opacity: 0;
  transition: opacity 0.3s ease;
}

coupon-modal .coupon-modal-panel,
size-guide-modal .size-guide-modal-panel {
  position: fixed;
  top: 1rem;
  right: 1rem;
  bottom: 1rem;
  left: auto;
  width: 100%;
  max-width: 42rem;
  max-height: none;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--ivory-border-soft, rgba(208, 197, 175, 0.58));
  border-radius: var(--ivory-radius, 4px);
  background: #fff;
  box-shadow: var(--ivory-shadow, 0 18px 44px rgba(115, 92, 0, 0.04));
  color: var(--ivory-text, #1a1c1c);
  overflow: hidden;
  transform: translateX(110%);
  transition: transform 0.3s ease-in-out;
  visibility: hidden;
  will-change: transform;
}

coupon-modal.coupon-modal-wrapper.show .coupon-modal-panel,
size-guide-modal.size-guide-modal-wrapper.show .size-guide-modal-panel {
  transform: none;
  visibility: visible;
  transition: transform 0.3s ease-in-out;
}

coupon-modal.coupon-modal-wrapper.show .coupon-modal-overlay,
size-guide-modal.size-guide-modal-wrapper.show .size-guide-modal-overlay {
  opacity: 1;
}

coupon-modal.coupon-modal-wrapper.hidden .coupon-modal-panel,
size-guide-modal.size-guide-modal-wrapper.hidden .size-guide-modal-panel {
  transform: translateX(110%);
  visibility: hidden;
}

coupon-modal .coupon-modal-header,
size-guide-modal .size-guide-modal-header {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--ivory-border-soft, rgba(208, 197, 175, 0.58));
}

coupon-modal .coupon-modal-title,
size-guide-modal .size-guide-modal-title {
  margin: 0;
  color: var(--ivory-text, #1a1c1c);
  font-family: var(--font-family-heading, "Playfair Display", serif);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
}

coupon-modal .coupon-modal-close,
size-guide-modal .size-guide-modal-close {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  padding: 0.375rem;
  border: 0;
  border-radius: var(--ivory-radius, 4px);
  background: transparent;
  color: var(--ivory-text, #1a1c1c);
  cursor: pointer;
  transition: background-color 0.2s;
}

coupon-modal .coupon-modal-close svg,
size-guide-modal .size-guide-modal-close svg {
  width: 1.25rem;
  height: 1.25rem;
}

coupon-modal .coupon-modal-close:hover,
coupon-modal .coupon-modal-close:focus-visible,
size-guide-modal .size-guide-modal-close:hover,
size-guide-modal .size-guide-modal-close:focus-visible {
  background: var(--ivory-surface-2, #f4f3f3);
  outline: none;
}

coupon-modal .coupon-modal-content,
size-guide-modal .size-guide-modal-content {
  min-height: 0;
  overflow-y: auto;
  padding: 22px;
  overscroll-behavior: contain;
}

size-guide-modal .size-guide-modal-content > *:first-child {
  margin-top: 0;
}

size-guide-modal .size-guide-modal-content > *:last-child {
  margin-bottom: 0;
}

size-guide-modal .size-guide-modal-content table {
  width: 100%;
  border-collapse: collapse;
}

size-guide-modal .size-guide-modal-content th,
size-guide-modal .size-guide-modal-content td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(202, 185, 154, 0.34);
  text-align: left;
}

coupon-modal .coupon-modal-list {
  display: grid;
  gap: 12px;
}

coupon-modal .coupon-modal-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--ivory-border-soft, rgba(208, 197, 175, 0.58));
  border-radius: var(--ivory-radius, 4px);
  background: var(--ivory-surface, #faf9f9);
}

coupon-modal .coupon-modal-title-text {
  margin-bottom: 6px;
  font-weight: 600;
}

coupon-modal .coupon-modal-code {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  margin-bottom: 8px;
  padding: 0 10px;
  border: 1px dashed rgba(115, 92, 0, 0.42);
  border-radius: var(--ivory-radius, 4px);
  color: var(--ivory-gold, #735c00);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

coupon-modal .coupon-modal-desc,
coupon-modal .coupon-modal-expire {
  color: var(--ivory-muted, #4d4635);
  font-size: 13px;
  line-height: 1.55;
}

coupon-modal .coupon-modal-copy {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--ivory-text, #1a1c1c);
  border-radius: var(--ivory-radius, 4px);
  background: var(--ivory-text, #1a1c1c);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

product-template .product-template__relate-wrap .swiper-wrapper,
.product-viewed__wrap .swiper-wrapper {
  display: flex !important;
  flex-wrap: nowrap;
  align-items: flex-start;
  grid-template-columns: none !important;
}

product-template .product-template__relate-wrap .swiper-slide,
.product-viewed__wrap .swiper-slide,
product-template .product-template__relate-wrap .product-cards__item,
.product-viewed__wrap .product-cards__item {
  height: auto;
  min-width: 0;
}

@media (max-width: 767px) {
  product-template .product-template__title {
    font-size: 38px;
    line-height: 1.08;
  }

  product-template .product-template__relate .ivory-product-card__title,
  .product-viewed .ivory-product-card__title {
    font-size: 13px;
    line-height: 1.24;
  }

  product-template .product-template__tabs-nav {
    flex-wrap: nowrap;
    gap: 0;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  product-template .product-template__tabs-nav::-webkit-scrollbar {
    display: none;
  }

  product-template .product-template__tab-btn {
    flex: 0 0 auto;
    padding-right: 24px;
    white-space: nowrap;
  }

  .ivory-product-detail__media {
    gap: 0;
  }

  product-template .product-template__media-thumbs {
    margin-top: 0;
  }

  product-template .product-template__actions {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  product-template .product-template__buttons {
    order: 3;
    grid-column: 1;
    grid-row: 3;
  }

  product-template .coupon-preview {
    order: 2;
    grid-row: 2;
  }

  product-template .product-template__buttons {
    display: grid;
    grid-template-columns: 1fr 56px;
    gap: 8px;
  }

  product-template .product-template__wishlist-btn,
  product-template .product-template__compare-btn {
    width: 56px;
  }

  product-template .product-template__add-btn,
  product-template .product-template__buy-btn {
    grid-column: 1 / -1;
    min-width: 0;
  }

  product-template .product-template__add-btn {
    order: 1;
    grid-row: 1;
  }

  product-template .product-template__buy-btn {
    grid-column: 1;
    grid-row: 2;
    order: 2;
  }

  product-template .product-template__wishlist-btn,
  product-template .product-template__compare-btn {
    grid-column: 2;
    grid-row: 2;
    order: 3;
  }

  product-template .product-template__quantity-group .quantity-selector {
    width: auto;
    min-width: 0;
  }

  product-template .coupon-preview {
    grid-template-columns: 1fr;
  }

  product-template .coupon-preview__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    justify-content: start;
  }

  product-template .coupon-preview__item {
    min-width: 0;
    padding-inline: 8px;
  }

  product-template .coupon-preview__code {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  product-template .product-template__tabs-nav {
    display: flex;
  }

  product-template .product-template__tab-btn {
    border-right: 0;
    border-bottom: 1px solid var(--ivory-border-soft, rgba(208, 197, 175, 0.58));
  }
}

/* Resilient Quantity Selector Layout Fix */
product-template quantity-selector,
product-template .quantity-selector {
  display: inline-flex;
  justify-self: start;
  align-items: center;
  border: 1px solid var(--ivory-border, rgba(127, 118, 99, 0.24));
  border-radius: var(--ivory-radius, 4px);
  background: #fff;
  height: 44px;
}

product-template .quantity-selector__button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 100%;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--ivory-text, #1a1c1c);
  cursor: pointer;
  transition: background-color 150ms ease;
}

product-template .quantity-selector__button:hover {
  background-color: var(--ivory-surface-2, #f4f3f3);
}

product-template .quantity-selector__input {
  width: 50px;
  height: 100%;
  border: none;
  border-left: 1px solid var(--ivory-border, rgba(127, 118, 99, 0.24));
  border-right: 1px solid var(--ivory-border, rgba(127, 118, 99, 0.24));
  background: transparent;
  color: var(--ivory-text, #1a1c1c);
  text-align: center;
  font-family: var(--font-family-body, "Montserrat", sans-serif);
  font-size: 14px;
  font-weight: 500;
  padding: 0;
  margin: 0;
  -moz-appearance: textfield;
}

product-template .quantity-selector__input::-webkit-outer-spin-button,
product-template .quantity-selector__input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Coupon Preview Widget */
.coupon-preview {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border: 1px dashed var(--ivory-border, rgba(127, 118, 99, 0.24));
  border-radius: var(--ivory-radius, 4px);
  background: var(--ivory-surface-1, #ffffff);
  cursor: pointer;
  margin-block: 20px;
  transition: border-color 150ms ease, background-color 150ms ease;
}

.coupon-preview:hover {
  border-color: var(--ivory-gold, #735c00);
  background-color: var(--ivory-surface, #faf9f9);
}

.coupon-preview__label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ivory-gold, #735c00);
  font-family: var(--font-family-body, "Montserrat", sans-serif);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.coupon-preview__label svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.coupon-preview__list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.coupon-preview__item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border: 1px solid var(--ivory-gold-bright, #d4af37);
  border-radius: var(--ivory-radius, 4px);
  background: rgba(212, 175, 55, 0.06);
  color: var(--ivory-gold, #735c00);
  font-family: var(--font-family-body, "Montserrat", sans-serif);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

@media (max-width: 767px) {
  .product-sticky-add__container {
    flex-direction: column;
    align-items: stretch;
    min-height: 0;
    padding-block: 10px calc(10px + env(safe-area-inset-bottom));
  }

  .product-sticky-add__image {
    display: block;
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
  }

  .product-sticky-add__title {
    font-size: 16px;
  }

  .product-sticky-add__product {
    width: 100%;
  }

  .product-sticky-add__actions {
    flex: 0 0 auto;
    width: 100%;
  }

  .product-sticky-add__btn {
    flex: 1 1 0;
    min-width: 0;
    padding-inline: 12px;
  }

  .product-sticky-add__btn .icon {
    display: none;
  }

  coupon-modal .coupon-modal-panel,
  size-guide-modal .size-guide-modal-panel {
    right: 0.5rem;
    left: 0.5rem;
    top: 0.5rem;
    bottom: 0.5rem;
    width: calc(100% - 1rem);
    max-width: none;
    max-height: none;
  }

  coupon-modal .coupon-modal-item {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .product-sticky-add__container {
    gap: 10px;
  }

  .product-sticky-add__title {
    font-size: 15px;
  }
}

@media (max-width: 360px) {
  product-template .product-template__title {
    font-size: 34px;
    line-height: 1.06;
  }

  product-template .product-template__price-box {
    flex-wrap: wrap;
    gap: 8px 10px;
    align-items: center;
  }

  product-template .product-template__price-current {
    flex: 1 1 100%;
    font-size: 28px;
  }

  product-template .product-template__price-compare {
    font-size: 14px;
    line-height: 1.2;
  }

  product-template .product-template__price-sale {
    padding: 4px 7px;
    font-size: 11px;
    line-height: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .product-sticky-add,
  .product-lightbox {
    transition: none;
  }
}
