/* ========================================
   SEO Enhancement Sections - Table of Contents, Gallery, Usage Guide
   ======================================== */

/* ========================================
   Table of Contents
   ======================================== */

.table-of-contents {
  background: linear-gradient(135deg, #f8fafc 0%, #e8eef1 100%);
  padding: 3rem 0;
  border-bottom: 1px solid var(--gray-lighter);
}

.toc-title {
  text-align: center;
  font-size: 1.5rem;
  color: var(--primary);
  margin-bottom: 2rem;
}

.toc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  max-width: 1200px;
  margin: 0 auto;
}

.toc-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  background: var(--white);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--primary);
  font-weight: 600;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-sm);
}

.toc-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  background: var(--gradient-soft);
  color: var(--highlight);
}

.toc-item svg {
  color: var(--highlight);
  flex-shrink: 0;
}

/* ========================================
   Product Gallery Section
   ======================================== */

.product-gallery-section {
  background: var(--white);
}

/* Before & After Section */
.before-after-section {
  margin-bottom: 4rem;
  padding: 3rem 0;
}

.before-after-section .section-heading {
  text-align: center;
  margin-bottom: 3rem;
}

.before-after-section .section-heading h3 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
  margin: 0 0 1rem 0;
}

.before-after-section .section-heading .lead {
  font-size: 1.1rem;
  color: var(--gray);
  max-width: 600px;
  margin: 0 auto;
}

.before-after-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

.before-after-item {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.before-after-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

.before-after-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
}

.split-side {
  position: relative;
  overflow: hidden;
}

.split-before {
  border-right: 2px solid var(--white);
}

.split-after {
  border-left: 2px solid var(--white);
}

.before-after-label {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: linear-gradient(135deg, #0ea5e9 0%, #06b6d4 100%);
  color: var(--white);
  padding: 0.5rem 1.25rem;
  border-radius: 2rem;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 2;
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.3);
}

.split-after .before-after-label {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.split-image-wrapper {
  width: 100%;
  height: 100%;
  overflow: hidden;
  position: relative;
}

.split-image-left {
  width: 200%;
  height: 100%;
  object-fit: cover;
  object-position: left center;
  display: block;
}

.split-image-right {
  width: 200%;
  height: 100%;
  object-fit: cover;
  object-position: right center;
  display: block;
  margin-left: -100%;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.gallery-item {
  background: var(--white);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
}

.gallery-item:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
}

.gallery-item.main-item {
  grid-column: span 2;
}

.gallery-item img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  display: block;
}

.gallery-caption {
  padding: 1.5rem;
  background: var(--gray-lighter);
}

.gallery-caption h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--primary);
}

.gallery-caption p {
  font-size: 0.9rem;
  color: var(--gray);
  margin: 0;
}

.gallery-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
  padding: 3rem;
  background: var(--gray-lighter);
  border-radius: var(--radius-xl);
}

.gallery-feature-item {
  text-align: center;
}

.gallery-feature-item svg {
  color: var(--highlight);
  margin-bottom: 1rem;
}

.gallery-feature-item h4 {
  font-size: 1.125rem;
  margin-bottom: 0.5rem;
  color: var(--primary);
}

.gallery-feature-item p {
  color: var(--gray);
  font-size: 0.95rem;
  margin: 0;
}

/* ========================================
   Usage Guide Section
   ======================================== */

.usage-guide-section {
  background: var(--gray-lighter);
}

.usage-guide-content {
  max-width: 1200px;
  margin: 0 auto;
  margin-bottom: 3rem;
}

.usage-steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  align-items: stretch;
}

/* Removed dosage guidance card - integrated into steps */

.usage-step {
  display: flex;
  flex-direction: column;
  padding: 1.75rem;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
  border: 1px solid #e5e7eb;
  height: 100%;
}
.usage-step:hover {
  border-color: #0ea5e9;
  box-shadow: 0 4px 16px rgba(14, 165, 233, 0.12);
  transform: translateY(-2px);
}

.step-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.step-number-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gradient-accent);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 800;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(243, 156, 18, 0.25);
}

.step-header h3 {
  font-size: 1.25rem;
  margin: 0;
  color: var(--primary);
  font-weight: 700;
  line-height: 1.3;
}

.step-description {
  color: var(--dark-light);
  line-height: 1.6;
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.step-tips {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  width: 100%;
  margin-top: auto;
}

.step-tips li {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.625rem 0.875rem;
  background: rgba(243, 156, 18, 0.06);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  color: var(--dark);
  line-height: 1.4;
}

.step-tips li svg {
  color: var(--accent);
  flex-shrink: 0;
  width: 16px;
  height: 16px;
}

.step-tips li span {
  flex: 1;
}

.usage-tips-box {
  background: var(--white);
  padding: 3rem;
  border-radius: var(--radius-xl);
  margin-bottom: 3rem;
  box-shadow: var(--shadow-md);
}

.usage-tips-box h3 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2.5rem;
  color: var(--primary);
}

.tips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.tip-item {
  text-align: center;
  padding: 1.5rem;
  background: var(--gray-lighter);
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
}

.tip-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.tip-item svg {
  color: var(--highlight);
  margin-bottom: 1rem;
}

.tip-item h4 {
  font-size: 1.125rem;
  margin-bottom: 0.75rem;
  color: var(--primary);
}

.tip-item p {
  font-size: 0.9rem;
  color: var(--gray);
  margin: 0;
}

.what-to-expect {
  background: var(--white);
  padding: 3rem;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
}

.what-to-expect h3 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 3rem;
  color: var(--primary);
}

.timeline {
  position: relative;
  padding-left: 3rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 30px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--gradient-primary);
}

.timeline-item {
  position: relative;
  padding-bottom: 3rem;
}

.timeline-marker {
  position: absolute;
  left: -2.3rem;
  top: 0;
  background: var(--highlight);
  color: var(--white);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.85rem;
  box-shadow: var(--shadow-md);
  white-space: nowrap;
}

.timeline-content {
  background: var(--gray-lighter);
  padding: 1.5rem 2rem;
  border-radius: var(--radius-lg);
  margin-left: 1rem;
}

.timeline-content h4 {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--primary);
}

.timeline-content p {
  line-height: 1.7;
  color: var(--dark-light);
  margin: 0;
}

/* ========================================
   Ingredient Visuals
   ======================================== */

.ingredient-visual {
  width: 100%;
  height: 200px;
  overflow: hidden;
  border-bottom: 1px solid var(--gray-lighter);
}

.ingredient-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.ingredient-card:hover .ingredient-visual img {
  transform: scale(1.05);
}

/* Specific Ingredient Styles */
.ingredient-content {
  padding: 2rem;
}

/* ========================================
   Responsive Adjustments
   ======================================== */

@media (max-width: 768px) {
  .toc-grid {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }

  .before-after-section {
    margin-bottom: 2.5rem;
    padding: 2rem 0;
  }

  .before-after-section .section-heading h3 {
    font-size: 1.75rem;
  }

  .before-after-section .section-heading .lead {
    font-size: 1rem;
  }

  .before-after-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .before-after-split {
    min-height: 400px;
  }

  .split-image-wrapper {
    min-height: 400px;
  }

  .split-image-left,
  .split-image-right {
    min-height: 400px;
  }

  .before-after-label {
    font-size: 0.8rem;
    padding: 0.4rem 1rem;
  }

  .gallery-item.main-item {
    grid-column: span 1;
  }

  .usage-guide-content {
    margin-bottom: 2rem;
  }

  .usage-steps {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .usage-step {
    padding: 1.5rem;
  }

  .step-header {
    gap: 0.875rem;
    margin-bottom: 0.875rem;
  }

  .step-number-circle {
    width: 44px;
    height: 44px;
    font-size: 1.375rem;
  }

  .step-header h3 {
    font-size: 1.125rem;
  }

  .step-description {
    font-size: 0.9rem;
    margin-bottom: 0.875rem;
  }

  .timeline {
    padding-left: 2rem;
  }

  .timeline-marker {
    font-size: 0.75rem;
    padding: 0.4rem 0.8rem;
  }
}
