.product-hero-section {
  padding-top: 8px;
}

.product-page-shell {
  position: relative;
}

.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 292px;
  gap: clamp(16px, 2vw, 24px);
  align-items: start;
}

.product-layout > * {
  min-width: 0;
}

.product-main-column {
  display: grid;
  gap: 14px;
}

.product-overview-grid {
  display: grid;
  grid-template-columns: minmax(360px, 1.08fr) minmax(0, 0.92fr);
  gap: clamp(16px, 2vw, 22px);
  align-items: start;
}

.product-gallery,
.product-panel,
.product-buy-card,
.product-info-card {
  border: 1px solid #d4deec;
  border-radius: 24px;
  background: linear-gradient(180deg, #ffffff 0%, #f6f9fd 100%);
  box-shadow: 0 14px 34px rgba(16, 46, 89, 0.08);
}

.product-gallery {
  position: relative;
  display: grid;
  gap: 14px;
  align-content: start;
  container-type: inline-size;
  padding: clamp(16px, 2vw, 20px);
  overflow: hidden;
  animation: productFadeUp 0.45s ease both;
}

.product-gallery::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 110px;
  background:
    radial-gradient(circle at top left, rgba(108, 150, 216, 0.24), transparent 56%),
    linear-gradient(180deg, rgba(66, 111, 173, 0.1), rgba(66, 111, 173, 0));
  pointer-events: none;
}

.product-gallery::after {
  content: "";
  position: absolute;
  top: -18%;
  right: -16%;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(181, 202, 232, 0.35) 0%, rgba(181, 202, 232, 0) 72%);
  animation: productFloatGlow 6s ease-in-out infinite;
  pointer-events: none;
}

.product-main-image {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: auto;
  min-height: 0;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  object-position: center;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(239, 244, 251, 0.96));
  border: 1px solid #e1e8f2;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  animation: productImageSettle 0.65s ease both;
}

.product-gallery:hover .product-main-image {
  transform: scale(1.02);
  box-shadow: 0 16px 30px rgba(24, 64, 116, 0.12);
}

.product-thumbs {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.product-thumbs:empty {
  display: none;
}

@supports (height: 100cqw) {
  .product-main-image {
    height: 100cqw;
    aspect-ratio: auto;
  }
}

.product-thumb {
  flex: 0 0 78px;
  width: 78px;
  height: 78px;
  padding: 0;
  border: 1px solid #c7d5e6;
  border-radius: 14px;
  background: linear-gradient(180deg, #ffffff 0%, #f0f4f9 100%);
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  animation: productFadeUp 0.45s ease both;
}

.product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 13px;
  background: #f4f7fb;
}

.product-thumb:hover {
  transform: translateY(-2px);
  border-color: #8facd4;
  box-shadow: 0 10px 18px rgba(28, 67, 118, 0.12);
}

.product-thumb.is-active {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(45, 103, 189, 0.14);
}

.product-panel {
  display: grid;
  align-content: start;
  gap: 10px;
  padding: clamp(16px, 2vw, 22px);
  animation: productFadeUp 0.52s ease both;
  animation-delay: 0.05s;
}

.product-panel-head {
  display: grid;
  gap: 10px;
}

.product-panel .product-sku {
  margin: 0;
  color: #59708f;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.product-status-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.product-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eaf7ee;
  border: 1px solid #b7dcc2;
  color: #21603b;
  font-size: 0.72rem;
  font-weight: 800;
}

.product-status-note {
  color: #546d8f;
  font-size: 0.82rem;
  line-height: 1.35;
}

.product-panel .product-name {
  margin: 0;
  color: #16345f;
  font-size: clamp(1.22rem, 1.8vw, 1.72rem);
  line-height: 1.12;
  font-weight: 800;
  min-height: 0;
  overflow: visible;
  display: block;
  -webkit-line-clamp: initial;
  line-clamp: initial;
}

.product-details-card {
  padding: clamp(14px, 1.8vw, 20px);
  animation: productFadeUp 0.58s ease both;
}

.product-details-inline {
  padding: 12px 0 0;
  border: 0;
  border-top: 1px solid rgba(201, 214, 231, 0.9);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  animation: none;
}

.product-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.product-tab-btn {
  appearance: none;
  border: 1px solid #cbd8e8;
  border-radius: 999px;
  padding: 8px 13px;
  background: linear-gradient(180deg, #f8fbff 0%, #edf3fa 100%);
  color: #2a4368;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, background-color 0.18s ease, color 0.18s ease;
}

.product-tab-btn:hover {
  transform: translateY(-1px);
  border-color: #9eb7d7;
  background: linear-gradient(180deg, #f1f7ff 0%, #e7eff9 100%);
}

.product-tab-btn.is-active {
  background: linear-gradient(135deg, #254b7c 0%, #1c3961 100%);
  border-color: #254b7c;
  color: #fff;
}

.product-tab-panel {
  display: none;
  padding: clamp(14px, 1.8vw, 18px);
  border-radius: 20px;
  border: 1px solid #d6e0ec;
  background: linear-gradient(180deg, #ffffff 0%, #f7f9fd 100%);
  color: #324b6e;
}

.product-tab-panel.is-active {
  display: block;
  animation: productTabIn 0.24s ease both;
}

.product-tab-panel p {
  margin: 0;
  max-width: 74ch;
  font-size: 0.94rem;
  line-height: 1.62;
}

.product-specs {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.product-specs li {
  position: relative;
  display: grid;
  grid-template-columns: minmax(110px, 180px) minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 10px 0;
  border: 0;
  border-bottom: 1px solid rgba(199, 211, 227, 0.75);
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  transition: background-color 0.18s ease;
}

.product-specs li::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  border-bottom: 1px dashed #c7d2e1;
  transform: translateY(-50%);
  z-index: 0;
}

.product-specs li:last-child {
  border-bottom: 0;
}

.product-specs li:hover {
  transform: none;
  background: rgba(241, 246, 252, 0.65);
  box-shadow: none;
}

.product-spec-name,
.product-spec-value {
  position: relative;
  z-index: 1;
  background: linear-gradient(180deg, #ffffff 0%, #f7f9fd 100%);
}

.product-spec-name {
  justify-self: start;
  padding-right: 12px;
  color: #4f6787;
  font-weight: 700;
  font-size: 0.86rem;
  line-height: 1.4;
}

.product-spec-value {
  justify-self: stretch;
  width: 100%;
  padding-left: 12px;
  color: #1f3d68;
  font-weight: 700;
  font-size: 0.86rem;
  line-height: 1.4;
  text-align: left;
  word-break: break-word;
  overflow-wrap: break-word;
}

.product-specs-empty {
  display: block;
  padding: 16px;
  border: 1px dashed #cad6e6;
  border-radius: 16px;
  background: linear-gradient(180deg, #f8fbff 0%, #eff4fb 100%);
  color: #6780a1;
}

.product-purchase {
  position: sticky;
  top: 108px;
  display: grid;
  gap: 12px;
}

.product-buy-card,
.product-info-card {
  padding: 16px;
}

.product-buy-card {
  display: grid;
  gap: 12px;
  animation: productFadeUp 0.5s ease both;
  animation-delay: 0.08s;
}

.product-reviews-section {
  margin-top: 50px;
  margin-bottom: 50px;
}

.product-reviews-section .section-head {
  margin-top: 30px;
}

.product-reviews-section .section-title {
  font-family: var(--font-body);
  font-size: 22px;
}

.product-reviews-section .review-form-toggle {
  margin-bottom: 30px;
}

.product-buy-label {
  margin: 0;
  color: #6d819f;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.product-buy-card .product-price {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 10px 12px;
}

.product-buy-card .product-price.has-special {
  align-items: baseline;
}

.product-buy-card .product-price-current {
  color: #132f57;
  font-size: clamp(1.55rem, 2.4vw, 2rem);
  line-height: 1;
}

.product-buy-card .product-price-current.is-regular {
  font-size: 0.98rem;
  color: #7b8aa8;
  font-weight: 600;
}

.product-buy-card .product-price-special-value {
  font-size: clamp(1.55rem, 2.4vw, 2rem);
}

.product-buy-card .product-price-old {
  font-size: 0.82rem;
}

#addToCartBtn {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  font-size: 0.9rem;
  box-shadow: 0 12px 20px rgba(18, 78, 158, 0.2);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  position: relative;
  overflow: hidden;
}

#addToCartBtn::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 -36%;
  width: 28%;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0));
  transform: skewX(-18deg);
  animation: productButtonSheen 3.8s ease-in-out infinite;
  pointer-events: none;
}

#addToCartBtn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 22px rgba(18, 78, 158, 0.26);
}

.product-buy-note {
  margin: 0;
  color: #6a7f9b;
  font-size: 0.8rem;
  line-height: 1.45;
}

.product-info-card {
  display: grid;
  gap: 10px;
  animation: productFadeUp 0.56s ease both;
  animation-delay: 0.12s;
}

.product-info-title {
  margin: 0;
  color: #16345f;
  font-size: 0.92rem;
  font-weight: 800;
}

.product-info-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.product-info-list li {
  position: relative;
  padding-left: 18px;
  color: #4f6786;
  font-size: 0.84rem;
  line-height: 1.5;
}

.product-info-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #6a9254;
  box-shadow: 0 0 0 4px rgba(106, 146, 84, 0.12);
}

@keyframes productFadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes productTabIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes productFloatGlow {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
    opacity: 0.85;
  }

  50% {
    transform: translate3d(-8px, 10px, 0);
    opacity: 1;
  }
}

@keyframes productImageSettle {
  from {
    opacity: 0;
    transform: scale(0.97);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes productButtonSheen {
  0%,
  72%,
  100% {
    left: -36%;
  }

  84% {
    left: 118%;
  }
}

@media (max-width: 1279px) {
  .product-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-purchase {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
}

@media (max-width: 979px) {
  .product-overview-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .product-gallery,
  .product-panel,
  .product-buy-card,
  .product-info-card {
    border-radius: 18px;
  }

  .product-panel,
  .product-buy-card,
  .product-info-card {
    padding: 14px;
  }

  .product-details-inline {
    padding: 12px 0 0;
  }

  .product-purchase {
    grid-template-columns: minmax(0, 1fr);
  }

  .product-tabs {
    gap: 6px;
    margin-bottom: 14px;
  }

  .product-tab-btn {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .product-specs li {
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
    padding: 12px 0;
  }

  .product-specs li::before {
    display: none;
  }

  .product-spec-name,
  .product-spec-value {
    padding: 0;
    background: transparent;
  }

  .product-spec-value {
    justify-self: start;
    text-align: left;
  }
}

@media (max-width: 767px) {
  .product-main-column {
    gap: 12px;
  }
}

@media (min-width: 768px) and (max-width: 979px) {
  .product-layout {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.86fr);
    gap: 14px;
  }

  .product-overview-grid {
    grid-template-columns: minmax(280px, 0.98fr) minmax(0, 1.02fr);
    gap: 14px;
  }

  .product-purchase {
    position: sticky;
    top: 102px;
    grid-template-columns: minmax(0, 1fr);
  }

  .product-gallery,
  .product-panel,
  .product-buy-card,
  .product-info-card {
    border-radius: 20px;
  }

  .product-panel,
  .product-buy-card,
  .product-info-card {
    padding: 14px;
  }

  .product-tab-btn {
    width: auto;
  }
}

@media (max-width: 520px) {
  .product-gallery {
    padding: 10px;
  }

  .product-thumb {
    flex-basis: 68px;
    width: 68px;
    height: 68px;
  }

  .product-panel .product-name {
    font-size: clamp(1.08rem, 6.4vw, 1.34rem);
  }

  .product-buy-card .product-price-current {
    font-size: clamp(1.4rem, 9vw, 1.72rem);
  }

  .product-buy-card .product-price-special-value {
    font-size: clamp(1.4rem, 9vw, 1.72rem);
  }

  #addToCartBtn {
    min-height: 40px;
    font-size: 0.86rem;
  }
}
