/* ============================================================
   COSMOCHEM — Product Detail Page Stylesheet
   ============================================================ */

.breadcrumb-section {
  padding: 24px 0 12px;
  background-color: var(--bg);
}

.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: 'Sora', sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-3);
  margin: 0;
  padding: 0;
  list-style: none;
}

.breadcrumb-item a {
  color: var(--blue-dark);
  transition: color 0.15s ease;
}

.breadcrumb-item a:hover {
  color: var(--pink);
}

.breadcrumb-separator {
  color: var(--border-2);
  user-select: none;
}

.breadcrumb-item.active {
  color: var(--ink-2);
  pointer-events: none;
}

/* --- Product Detail Section --- */
.product-detail-section {
  padding: 20px 0 60px;
  background-color: var(--bg);
}

/* Gallery Layout */
.product-gallery {
  display: flex;
  flex-direction: column-reverse;
  gap: 16px;
}

@media (min-width: 992px) {
  .product-gallery {
    flex-direction: row;
  }
}

/* Thumbnails */
.gallery-thumbs {
  display: flex;
  flex-direction: row;
  gap: 10px;
  overflow-x: auto;
  padding: 4px 0;
  scroll-behavior: smooth;
  scrollbar-width: none; /* Firefox */
  -webkit-overflow-scrolling: touch;
}

.gallery-thumbs::-webkit-scrollbar {
  display: none; /* Safari & Chrome */
}

@media (min-width: 992px) {
  .gallery-thumbs {
    flex-direction: column;
    overflow-y: auto;
    overflow-x: visible;
    width: 88px;
    max-height: 480px;
    flex-shrink: 0;
  }
}

.thumb-item {
  width: 70px;
  height: 70px;
  flex-shrink: 0;
  border-radius: var(--radius-sm);
  border: 2px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  overflow: hidden;
  position: relative;
  transition: all 0.2s ease-in-out;
}

@media (min-width: 992px) {
  .thumb-item {
    width: 80px;
    height: 80px;
  }
}

.thumb-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s ease;
}

.thumb-item:hover {
  border-color: var(--blue-dark);
}

.thumb-item:hover img {
  transform: scale(1.05);
}

.thumb-item.active {
  border-color: var(--blue-dark);
  box-shadow: 0 0 0 3px oklch(75.5% 0.12 212deg / 0.25);
}

/* Main Display Box */
.gallery-main {
  flex-grow: 1;
  position: relative;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #ffffff;
  aspect-ratio: 1;
  max-height: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-main img.loaded {
  opacity: 1;
}

/* --- Product Info Column --- */
.product-info-col {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.product-meta-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.meta-badge {
  font-family: 'Sora', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 6px 12px;
  border-radius: 50px;
  background: var(--surface-2);
  color: var(--ink-2);
  border: 1px solid var(--border);
}

.meta-badge.category {
  background: var(--blue-tint);
  color: var(--blue-dark);
  border-color: oklch(75.5% 0.12 212deg / 0.3);
}

.meta-badge.subcategory {
  background: var(--pink-tint);
  color: var(--pink);
  border-color: oklch(54% 0.25 350deg / 0.15);
}

.product-title-detail {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.025em;
  line-height: 1.15;
  color: var(--ink);
  margin-bottom: 14px;
}

.product-tagline {
  font-size: 1.1rem;
  line-height: 1.5;
  color: var(--ink-2);
  margin-bottom: 24px;
  font-weight: 500;
}

/* Key details card */
.quick-specs-card {
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 28px;
}

.quick-specs-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.q-spec-item {
  display: flex;
  flex-direction: column;
}

.q-spec-label {
  font-family: 'Sora', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-3);
  margin-bottom: 4px;
}

.q-spec-val {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
}

/* Packaging Options selector */
.sizes-selection {
  margin-bottom: 30px;
}

.sizes-label {
  font-family: 'Sora', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-2);
  margin-bottom: 12px;
}

.sizes-tags-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.size-select-tag {
  display: inline-block;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--border-2);
  background: var(--bg);
  font-family: 'Sora', sans-serif;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--ink-2);
  cursor: pointer;
  transition: all 0.18s ease;
  user-select: none;
}

.size-select-tag:hover {
  border-color: var(--blue-dark);
  color: var(--blue-dark);
}

.size-select-tag.active {
  background-color: var(--blue-tint);
  border-color: var(--blue-dark);
  color: var(--blue-dark);
  box-shadow: 0 2px 8px oklch(75.5% 0.12 212deg / 0.15);
}




/* Quantity Selector styling matching theme and layout image */
.quantity-section {
  margin-bottom: 20px !important;
}

.quantity-selector {
  display: inline-flex;
  align-items: center;
  border: 1.5px solid var(--border-2);
  border-radius: var(--radius);
  background-color: var(--surface);
  overflow: hidden;
  max-width: 150px;
  height: 40px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.quantity-selector:focus-within {
  border-color: var(--blue-dark);
  box-shadow: 0 0 0 3px oklch(75.5% 0.12 212deg / 0.15);
}

.qty-btn {
  background: none;
  border: none;
  width: 46px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--ink-2);
  transition: background-color 0.2s ease, color 0.2s ease;
  padding: 0;
}

.qty-btn:hover {
  background-color: var(--surface-2);
  color: var(--blue-dark);
}

.qty-btn svg {
  width: 14px;
  height: 14px;
}

.quantity-select {
  border: none !important;
  background: transparent !important;
  width: 58px !important;
  height: 100% !important;
  text-align: center !important;
  font-family: 'Sora', sans-serif !important;
  font-size: 1.05rem !important;
  font-weight: 700 !important;
  color: var(--ink) !important;
  padding: 0 !important;
  margin: 0 !important;
  -moz-appearance: textfield; /* Hide default spinner Firefox */
}

/* Hide default spinner Chrome/Safari */
.quantity-select::-webkit-outer-spin-button,
.quantity-select::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}





/* Action CTAs */
.detail-actions {
  display: flex;
  flex-direction: column;
  align-items: center;   /* centres button horizontally on small screens */
  gap: 12px;
  margin-top: auto;
}

@media (min-width: 576px) {
  .detail-actions {
    flex-direction: row;
    align-items: stretch;
  }
  .detail-actions .btn {
    flex: 1;
    justify-content: center;
    text-align: center;
  }
}

.detail-actions .btn {
  padding: 14px 28px;
  font-size: 0.95rem;
}

.detail-actions .btn-wa {
  font-size: 0.95rem;
}

/* --- Info Tabs Section --- */
.product-tabs-section {
  padding: 40px 0 60px;
  border-top: 1px solid var(--border);
  background-color: var(--surface);
}

.product-tabs-section img{
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: cover !important;
  
}

.tabs-nav {
  display: flex;
  border-bottom: 2px solid var(--border);
  margin-bottom: 30px;
  overflow-x: auto;
  scrollbar-width: none;
  gap: 24px;
}

.tabs-nav::-webkit-scrollbar {
  display: none;
}

.tab-nav-btn {
  font-family: 'Sora', sans-serif;
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--ink-3);
  padding: 12px 4px;
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  transition: all 0.18s ease;
  margin-bottom: -2px;
}

.tab-nav-btn:hover {
  color: var(--blue-dark);
}

.tab-nav-btn.active {
  color: var(--blue-dark);
  border-bottom-color: var(--blue-dark);
}

.tab-content-pane {
  display: none;
  animation: fadeIn 0.3s ease;
}

.tab-content-pane.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Tab descriptions styling */
.tab-rich-text h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--ink);
}

.tab-rich-text p {
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--ink-2);
  margin-bottom: 20px;
}


.tab-rich-text ul {
  list-style-type: disc !important;
  padding-left: 2rem !important;
  margin-bottom: 1.25rem !important;
}

.tab-rich-text ol {
  list-style-type: decimal !important;
  padding-left: 2rem !important;
  margin-bottom: 1.25rem !important;
}

.tab-rich-text li {
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--ink-2);
  margin-bottom: 0.5rem !important;
  display: list-item !important;
}

.tab-rich-text ul ul {
  list-style-type: circle !important;
  margin-bottom: 0 !important;
  margin-top: 0.25rem !important;
}

.tab-rich-text ol ol,
.tab-rich-text ul ol,
.tab-rich-text ol ul {
  margin-bottom: 0 !important;
  margin-top: 0.25rem !important;
}




/* Bullet list checkmarks */
.benefits-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: 24px;
}

@media (min-width: 768px) {
  .benefits-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

.benefit-li-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--ink-2);
}

.benefit-li-icon {
  color: oklch(52% 0.18 148deg);
  flex-shrink: 0;
  margin-top: 2px;
}

/* Applications badge grids */
.app-tags-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.app-tag-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.app-tag-icon {
  color: var(--blue-dark);
}

/* Tech Spec Table */
.tech-spec-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 24px;
  background: var(--bg);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.tech-spec-table tr {
  border-bottom: 1px solid var(--border);
}

.tech-spec-table tr:last-child {
  border-bottom: none;
}

.tech-spec-table tr:nth-child(even) {
  background-color: var(--surface-2);
}

.tech-spec-table th,
.tech-spec-table td {
  padding: 14px 20px;
  text-align: left;
  font-size: 0.92rem;
}

.tech-spec-table th {
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  color: var(--ink);
  width: 35%;
  background-color: var(--surface);
  border-right: 1px solid var(--border);
}

.tech-spec-table td {
  color: var(--ink-2);
  font-weight: 500;
}

@media (max-width: 575px) {
  .tech-spec-table th,
  .tech-spec-table td {
    padding: 10px 14px;
    font-size: 0.85rem;
  }
}

/* Related section */
.related-products-section {
  padding: 60px 0 80px;
  background-color: var(--bg);
}

.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-eyebrow {
  display: block;
  font-family: 'Sora', sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--pink);
  margin-bottom: 8px;
}

.section-title {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 12px;
}

.section-subtitle {
  color: var(--ink-2);
  max-width: 50ch;
  margin: 0 auto;
  font-size: 0.95rem;
}
