/**
* Averbest - Article Custom CSS
* Path: assets/css/style_faq.css
*/

/* ==========================================================================
   1. Fixed Background ช่วยทำให้เมนูทึบแสงขึ้น
   ========================================================================== */
body {
  background-image: url('../img/article/article-bg.webp');
  background-position: top center;
  background-repeat: no-repeat;
  background-size: 100% auto;
  background-color: #ffffff;
}

/* ==========================================================================
   2. Article Container
   ========================================================================== */
.article-premium {
  font-family: "Sarabun", sans-serif;
  font-size: 17px;  
  font-weight: 300;
  color: #333;  
  line-height: 1.75;
  background-color: #ffffff !important;
  padding: 30px !important;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  margin-bottom: 40px;
}

/* ==========================================================================
   3. Header & Entry Meta
   ========================================================================== */
.article-premium .category-badge {
  font-family: "Kanit", sans-serif;
  color: #B48200;
  font-weight: 300;
  font-size: 14px;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  display: inline-block;
}

.article-premium h1.entry-title {
  font-family: "Kanit", sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.4;
  color: #111;
  margin: 5px 0 0 0;
}

.article-premium p.entry-subtitle {
  font-size: 14px;
}

.article-premium .entry-meta {
  display: block !important;
  width: 100% !important;
  font-size: 14px;
  color: #777;
  padding-bottom: 15px !important;
  margin-top: 0;
  margin-bottom: 35px !important;
  border-bottom: 2px solid #B48200 !important;
}

/* ==========================================================================
   4. Article Body Typography
   ========================================================================== */
.article-premium p.text-p {
  margin-bottom: 18px;
}

/* ==========================================================================
   5. Reader's Digest / SEO Box & Quote Box / Checklist Box
   ========================================================================== */
.seo-intent-box {
  background-color: rgba(252, 250, 246, 0.95);
  border-left: 4px solid #B48200;
  padding: 15px 20px;
  margin: 25px 0;
  border-radius: 0 8px 8px 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);

}

.seo-intent-box p {
  font-size: 16px;
  line-height: 1.7;
  margin: 0 0 14px 0;
}

.seo-intent-box p:last-child {
  margin-bottom: 0;
}

/* ==========================================================================
   6. Table of Contents
   ========================================================================== */
.toc-box {
  background-color: rgba(244, 244, 244, 0.95);
  border: 1px solid #eef0f2;
  border-radius: 8px;
  padding: 20px;
  margin: 30px 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.toc-title {
  font-family: "Kanit", sans-serif;
  font-weight: 500;
  font-size: 16px;
  color: #111;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

.toc-list {
  padding-left: 15px;
  margin: 0;
  font-size: 15px;
}

.toc-list li {
  color: #B48200;
  margin-bottom: 10px;
}

.toc-list a {
  color: #B48200;
  transition: all 0.3s ease;
  border-bottom: 1px solid rgba(180, 130, 0, 0.1);
}

.toc-list a:hover {
  color: #8c6500;
  border-bottom: 2px solid rgba(180, 130, 0, 0.1);
}

/* ==========================================================================
   7. FAQ Accordion
   ========================================================================== */
.faq-list {
  margin: 20px 0 10px 0;
}

.faq-item-title {
  background-color: rgba(200, 175, 120, 0.5);
  border: 1px solid #eef0f2;
  border-radius: 8px;
  margin-bottom: 3px;
  overflow: hidden;
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.faq-item {
  background-color: rgba(252, 250, 246, 0.95);
  border: 1px solid #eef0f2;
  border-radius: 8px;
  margin-bottom: 3px;
  overflow: hidden;
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.faq-item.active {
  border-color: rgba(180, 130, 0, 0.35);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  background: none;
  border: none;
  text-align: left;
  padding: 8px 16px;
  cursor: pointer;
  font-family: "Sarabun", sans-serif;
}

.faq-number {
  font-family: "Sarabun", sans-serif;
  font-size: 16px;
  font-weight: 300;
  color: #B48200;
  min-width: 24px;
}

.faq-question-text {
  flex: 1;
  font-size: 16px;
  font-weight: 300;
  color: #222;
  line-height: 1.5;
}

.faq-icon {
  color: #B48200;
  font-size: 16px;
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.faq-answer-inner {
  background-color: #ffffff;
  border-top: 1px solid #eef0f2;
  padding: 16px 18px 18px 58px;
  margin: 0 1px 1px 1px;
  font-size: 15px;
  color: #555;
  line-height: 1.7;
}

.faq-answer-inner p {
  margin: 8px 0 0 0;
}

.faq-answer-inner p.caption {
  font-weight:500;
  margin: 10px 0 0 0;
}

.faq-answer-inner p:last-child {
  margin-bottom: 0;
}

.faq-answer-inner ul,
.faq-answer-inner ol {
  margin: 0 0 10px 0;
  padding-left: 20px;
}

.faq-answer-inner ul:last-child,
.faq-answer-inner ol:last-child {
  margin-bottom: 0;
}

.faq-answer-inner li {
  margin-bottom: 2px;
}

.faq-answer-inner li:last-child {
  margin-bottom: 0;
}

/* ==========================================================================
   8. Related Products
   ========================================================================== */
.article-premium .related-products {
  margin-top: 60px !important;
  padding-top: 30px !important;
  border-top: 1px solid #eef0f2 !important;
}

.article-premium .related-products h4 {
  font-family: "Kanit", sans-serif !important;
  font-size: 16px !important;
  font-weight: 500 !important;
  color: #111 !important;
  margin-bottom: 20px !important;
}

.article-premium .product-links-list {
  list-style: none !important;
  padding-left: 15px !important;
  margin: 0 !important;
}

.article-premium .product-links-list li {
  font-size: 14px !important;
  line-height: 1.0 !important;
  margin-bottom: 14px !important;
  position: relative !important;     /* ปักหมุดให้ไอคอนยึดตำแหน่ง */
  padding-left: 26px !important;     /* [พื้นที่รวมด้านซ้าย] */
}

.article-premium .product-links-list li::before {
  content: "\F45B" !important;  /* รหัส Unicode ของไอคอน */
  font-family: "bootstrap-icons" !important;
  font-size: 15px !important;
  color: #B48200 !important;  
  position: absolute !important;
  left: 6px !important;
  top: 0px !important;               /* ขยับลงมาเพื่อให้ไอคอนบาลานซ์กับตัวอักษร */
}

.article-premium .product-links-list a {
  color: #B48200 !important;
  text-decoration: none !important;
  transition: all 0.3s ease !important;
  display: inline-block !important;
}

.article-premium .product-links-list a:hover {
  color: #B48200 !important;
  padding-left: 6px !important;
}

/* ==========================================================================
   9. Tag Items Restoration (กู้คืนสไตล์กรอบที่หายไป)
   ========================================================================== */
.article-premium .article-tags {
  margin-top: 35px !important;
  padding-top: 15px !important;
}

.article-premium .article-tags .tag-item {
  display: inline-block !important;
  font-size: 12px !important;
  color: #555 !important;
  background-color: #f7f7f7 !important;
  border: 1px solid #e0e0e0 !important;
  padding: 6px 14px !important;
  margin: 0 8px 10px 0 !important;
  border-radius: 4px !important;
  text-decoration: none !important;
  transition: all 0.3s ease !important;
}

.article-premium .article-tags .tag-item:hover {
  color: #ffffff !important;
  background-color: #B48200 !important;
  border-color: #B48200 !important;
}

/* ==========================================================================
   10. Mobile Responsive
   ========================================================================== */
@media (max-width: 768px) {
  .article-premium h1.entry-title {
    font-size: 22px !important;
    font-weight: 500 !important;
  }
}

@media (max-width: 576px) {
  .article-premium {
    padding: 15px !important;
  }

  .faq-question {
    padding: 14px;
    gap: 10px;
  }

  .faq-question-text {
    font-size: 15px;
  }

  .faq-answer-inner {
    padding-left: 14px;
    padding-right: 14px;
  }
}