/* V106 Fix All Content Text Visibility
   แก้ตัวหนังสือขาว/หายบนพื้นขาวในหน้าบทความ หน้าเพจ หมวดหมู่ และการ์ดบทความ
   ทำแบบปลอดภัย: เพิ่ม CSS override อย่างเดียว ไม่แก้ HTML/PHP ด้วย regex
*/

/* ===============================
   1) White content cards/readers
================================ */
.v71-content-card,
.v71-page-card,
.v71-post-content,
.v71-page-content,
.post-content,
.entry-content,
.article-content,
.content-card,
.reader-card,
.page-content,
.post-body,
.article-body,
main article,
main .article,
main .post{
  background:#ffffff!important;
  color:#102033!important;
  -webkit-text-fill-color:initial!important;
  text-shadow:none!important;
  opacity:1!important;
  filter:none!important;
  mix-blend-mode:normal!important;
}

/* heading ในเนื้อหาบทความ/หน้า */
.v71-content-card h1,
.v71-content-card h2,
.v71-content-card h3,
.v71-content-card h4,
.v71-content-card h5,
.v71-content-card h6,
.v71-page-card h1,
.v71-page-card h2,
.v71-page-card h3,
.v71-page-card h4,
.v71-page-card h5,
.v71-page-card h6,
.v71-post-content h1,
.v71-post-content h2,
.v71-post-content h3,
.v71-post-content h4,
.v71-post-content h5,
.v71-post-content h6,
.v71-page-content h1,
.v71-page-content h2,
.v71-page-content h3,
.v71-page-content h4,
.v71-page-content h5,
.v71-page-content h6,
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6,
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4,
.entry-content h5,
.entry-content h6,
.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6,
.post-body h1,
.post-body h2,
.post-body h3,
.post-body h4,
.post-body h5,
.post-body h6,
.article-body h1,
.article-body h2,
.article-body h3,
.article-body h4,
.article-body h5,
.article-body h6,
.reader-card h1,
.reader-card h2,
.reader-card h3,
.reader-card h4,
.reader-card h5,
.reader-card h6,
.page-content h1,
.page-content h2,
.page-content h3,
.page-content h4,
.page-content h5,
.page-content h6{
  color:#071b35!important;
  -webkit-text-fill-color:#071b35!important;
  background:none!important;
  text-shadow:none!important;
  opacity:1!important;
  filter:none!important;
  mix-blend-mode:normal!important;
  font-weight:1000!important;
  position:relative!important;
  z-index:5!important;
}

/* ปิด pseudo heading ที่สร้างเงา/ข้อความซ้อน */
.v71-content-card h1::before,
.v71-content-card h1::after,
.v71-content-card h2::before,
.v71-content-card h2::after,
.v71-content-card h3::before,
.v71-content-card h3::after,
.v71-page-card h1::before,
.v71-page-card h1::after,
.v71-page-card h2::before,
.v71-page-card h2::after,
.v71-page-card h3::before,
.v71-page-card h3::after,
.v71-post-content h1::before,
.v71-post-content h1::after,
.v71-post-content h2::before,
.v71-post-content h2::after,
.v71-post-content h3::before,
.v71-post-content h3::after,
.post-content h1::before,
.post-content h1::after,
.post-content h2::before,
.post-content h2::after,
.post-content h3::before,
.post-content h3::after,
.entry-content h1::before,
.entry-content h1::after,
.entry-content h2::before,
.entry-content h2::after,
.entry-content h3::before,
.entry-content h3::after{
  content:none!important;
  display:none!important;
  opacity:0!important;
  visibility:hidden!important;
}

/* paragraph/list/table ในเนื้อหา */
.v71-content-card p,
.v71-content-card li,
.v71-content-card td,
.v71-content-card th,
.v71-content-card div,
.v71-content-card span,
.v71-page-card p,
.v71-page-card li,
.v71-page-card td,
.v71-page-card th,
.v71-page-card div,
.v71-page-card span,
.v71-post-content p,
.v71-post-content li,
.v71-post-content td,
.v71-post-content th,
.v71-post-content div,
.v71-post-content span,
.v71-page-content p,
.v71-page-content li,
.v71-page-content td,
.v71-page-content th,
.v71-page-content div,
.v71-page-content span,
.post-content p,
.post-content li,
.post-content td,
.post-content th,
.post-content div,
.post-content span,
.entry-content p,
.entry-content li,
.entry-content td,
.entry-content th,
.entry-content div,
.entry-content span,
.article-content p,
.article-content li,
.article-content td,
.article-content th,
.article-content div,
.article-content span,
.post-body p,
.post-body li,
.post-body td,
.post-body th,
.post-body div,
.post-body span,
.article-body p,
.article-body li,
.article-body td,
.article-body th,
.article-body div,
.article-body span,
.reader-card p,
.reader-card li,
.reader-card td,
.reader-card th,
.reader-card div,
.reader-card span,
.page-content p,
.page-content li,
.page-content td,
.page-content th,
.page-content div,
.page-content span{
  color:#2b3e53!important;
  -webkit-text-fill-color:#2b3e53!important;
  background:transparent!important;
  text-shadow:none!important;
  opacity:1!important;
  filter:none!important;
  mix-blend-mode:normal!important;
}

/* ลิงก์ในเนื้อหา */
.v71-content-card a,
.v71-page-card a,
.v71-post-content a,
.v71-page-content a,
.post-content a,
.entry-content a,
.article-content a,
.post-body a,
.article-body a,
.reader-card a,
.page-content a{
  color:#156cc4!important;
  -webkit-text-fill-color:#156cc4!important;
  text-shadow:none!important;
  opacity:1!important;
  font-weight:900!important;
}

/* strong/em */
.v71-content-card strong,
.v71-page-card strong,
.v71-post-content strong,
.v71-page-content strong,
.post-content strong,
.entry-content strong,
.article-content strong,
.post-body strong,
.article-body strong,
.reader-card strong,
.page-content strong{
  color:#071b35!important;
  -webkit-text-fill-color:#071b35!important;
  text-shadow:none!important;
}

/* ===============================
   2) Article/category cards
================================ */
.v71-archive-card,
.v71-post-card,
.article-card,
.post-card,
.articles-card,
.blog-card,
.c89-post,
.c89-card{
  background:#fff!important;
  color:#071b35!important;
  text-shadow:none!important;
  isolation:isolate!important;
}

.v71-archive-card h1,
.v71-archive-card h2,
.v71-archive-card h3,
.v71-archive-card h1 *,
.v71-archive-card h2 *,
.v71-archive-card h3 *,
.v71-post-card h1,
.v71-post-card h2,
.v71-post-card h3,
.v71-post-card h1 *,
.v71-post-card h2 *,
.v71-post-card h3 *,
.article-card h1,
.article-card h2,
.article-card h3,
.article-card h1 *,
.article-card h2 *,
.article-card h3 *,
.post-card h1,
.post-card h2,
.post-card h3,
.post-card h1 *,
.post-card h2 *,
.post-card h3 *,
.articles-card h1,
.articles-card h2,
.articles-card h3,
.blog-card h1,
.blog-card h2,
.blog-card h3,
.c89-post h1,
.c89-post h2,
.c89-post h3,
.c89-card h1,
.c89-card h2,
.c89-card h3{
  color:#071b35!important;
  -webkit-text-fill-color:#071b35!important;
  background:none!important;
  text-shadow:none!important;
  opacity:1!important;
  filter:none!important;
  mix-blend-mode:normal!important;
}

.v71-archive-card p,
.v71-post-card p,
.article-card p,
.post-card p,
.articles-card p,
.blog-card p,
.c89-post p,
.c89-card p{
  color:#445b73!important;
  -webkit-text-fill-color:#445b73!important;
  text-shadow:none!important;
  opacity:1!important;
  filter:none!important;
}

/* ===============================
   3) กัน selector เก่าจาก V92/V93/V100
   ที่บังคับ main section:last-of-type h2/p เป็นสีขาว
================================ */
main section:last-of-type .v71-content-card h1,
main section:last-of-type .v71-content-card h2,
main section:last-of-type .v71-content-card h3,
main section:last-of-type .v71-page-card h1,
main section:last-of-type .v71-page-card h2,
main section:last-of-type .v71-page-card h3,
main section:last-of-type .v71-post-content h1,
main section:last-of-type .v71-post-content h2,
main section:last-of-type .v71-post-content h3,
main section:last-of-type .post-content h1,
main section:last-of-type .post-content h2,
main section:last-of-type .post-content h3,
main section:last-of-type .entry-content h1,
main section:last-of-type .entry-content h2,
main section:last-of-type .entry-content h3,
main section:last-of-type .article-content h1,
main section:last-of-type .article-content h2,
main section:last-of-type .article-content h3,
main section:last-of-type .v71-archive-card h1,
main section:last-of-type .v71-archive-card h2,
main section:last-of-type .v71-archive-card h3,
main section:last-of-type .v71-post-card h1,
main section:last-of-type .v71-post-card h2,
main section:last-of-type .v71-post-card h3{
  color:#071b35!important;
  -webkit-text-fill-color:#071b35!important;
  text-shadow:none!important;
}

main section:last-of-type .v71-content-card p,
main section:last-of-type .v71-page-card p,
main section:last-of-type .v71-post-content p,
main section:last-of-type .post-content p,
main section:last-of-type .entry-content p,
main section:last-of-type .article-content p,
main section:last-of-type .v71-archive-card p,
main section:last-of-type .v71-post-card p{
  color:#2b3e53!important;
  -webkit-text-fill-color:#2b3e53!important;
  text-shadow:none!important;
}

/* ===============================
   4) Mobile
================================ */
@media(max-width:760px){
  .v71-content-card,
  .v71-page-card,
  .v71-post-content,
  .post-content,
  .entry-content,
  .article-content,
  .post-body,
  .article-body,
  .reader-card{
    padding:20px!important;
  }

  .v71-content-card h1,
  .v71-page-card h1,
  .v71-post-content h1,
  .post-content h1,
  .entry-content h1,
  .article-content h1{
    font-size:30px!important;
    line-height:1.2!important;
  }

  .v71-content-card h2,
  .v71-page-card h2,
  .v71-post-content h2,
  .post-content h2,
  .entry-content h2,
  .article-content h2{
    font-size:24px!important;
    line-height:1.28!important;
  }
}
