/* Custom overrides for live-theme.css */

/* Search toggle: show search bar when .open class is added by JS */
#nav-search.open { display: block !important; }

/* Ensure static page's item-post-wrap doesn't break float layout */
.item-post-wrap { overflow: hidden; }
.item-post { display: block; }

/* Force sidebar to right on static pages (theme's float sometimes fails here) */
@media screen and (min-width: 981px) {
  body.static_page #main-wrapper,
  body.item #main-wrapper {
    float: left !important;
    width: calc(100% - 350px) !important;
    box-sizing: border-box;
  }
  body.static_page #sidebar-wrapper,
  body.item #sidebar-wrapper {
    float: right !important;
    width: 320px !important;
    margin-top: 0 !important;
    box-sizing: border-box;
  }
  body.static_page #content-wrapper::after,
  body.item #content-wrapper::after {
    content: "";
    display: table;
    clear: both;
  }
}




/* FIX: Live theme uses lazy-yard JS that sets opacity:1 on scroll.
   Without that JS, images stay hidden (opacity:0). Force visible. */
.post-thumb,
.index-post .post-thumb,
.PopularPosts .post-thumb,
.related-posts .post-thumb,
img.post-thumb,
.item-post .post-body img,
.post-body img,
.post-content img { opacity: 1 !important; }


/* Ad slot labels */
.ad-slot { margin: 24px 0; text-align: center; min-height: 100px; }
.ad-slot::before {
  content: "Advertisement"; display: block;
  font-size: 10px; color: #999; text-transform: uppercase; letter-spacing: .5px;
  margin-bottom: 4px;
}

/* Breadcrumbs */
.breadcrumbs { font-size: 13px; color: #6b7280; margin: 12px 0; padding: 0 15px; }
.breadcrumbs a { color: #27ae60; }
.breadcrumbs span { color: #333; }

/* Share buttons on posts */
.share-buttons {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  margin: 20px 0; padding: 12px 0; border-top: 1px solid #eee; border-bottom: 1px solid #eee;
}
.share-label { font-size: 13px; color: #6b7280; font-weight: 600; margin-right: 4px; }
.share { padding: 6px 14px; border-radius: 3px; font-size: 13px; font-weight: 500; color: #fff !important; text-decoration: none; }
.share:hover { opacity: .9; text-decoration: none; }
.share.whatsapp { background: #25D366; }
.share.facebook { background: #1877F2; }
.share.twitter { background: #000; }
.share.telegram { background: #0088cc; }
.share.copy { background: #6b7280; }

/* You may also like */
.you-may-like { background: #f0faf3; border-left: 4px solid #27ae60; padding: 16px 20px; margin: 30px 0; border-radius: 4px; }
.you-may-like h3 { margin: 0 0 12px; font-size: 16px; color: #1a8a2f; }
.you-may-like-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.you-may-like-grid a { display: block; background: #fff; border-radius: 4px; overflow: hidden; color: #1a1a1a; border: 1px solid #eee; text-decoration: none; }
.you-may-like-grid a:hover { text-decoration: none; box-shadow: 0 4px 10px rgba(0,0,0,.08); }
.you-may-like-grid img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.you-may-like-grid span { display: block; padding: 8px 10px; font-size: 13px; font-weight: 500; line-height: 1.3; }

/* Related posts on single */
.related { margin: 40px 0 0; }
.related h2 { font-size: 20px; margin-bottom: 14px; }
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.related-card { background: #fff; border-radius: 4px; overflow: hidden; border: 1px solid #eee; display: block; color: #1a1a1a; text-decoration: none; }
.related-card:hover { text-decoration: none; box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.related-card img { width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.related-body { padding: 10px 12px 12px; }
.related-title { display: block; font-size: 14px; font-weight: 600; line-height: 1.35; color: #1a1a1a; }
.related-body small { display: block; color: #888; font-size: 11px; margin-top: 4px; }

.back-link { margin: 20px 0 0; }

.updated-badge { background: #10b981; color: #fff; padding: 2px 10px; border-radius: 999px; font-size: 11px; font-weight: 600; }
.read-time { color: #6b7280; font-size: 12px; }
.tag { background: #eef4fb; color: #0b66c3; padding: 2px 10px; border-radius: 999px; font-size: 11px; font-weight: 600; text-decoration: none; }
.tag:hover { background: #0b66c3; color: #fff; text-decoration: none; }

/* Static pages */
.static-page { background: #fff; padding: 30px; border: 1px solid #eee; border-radius: 4px; }
.static-page h1 { margin: 0 0 16px; color: #222; }
.static-page h2 { font-size: 18px; margin-top: 24px; color: #333; border-bottom: 2px solid #e8f5ec; padding-bottom: 6px; }

/* Contact form */
.contact-form { display: flex; flex-direction: column; gap: 12px; margin-top: 12px; }
.contact-form label { display: flex; flex-direction: column; font-size: 13px; color: #555; font-weight: 600; }
.contact-form input, .contact-form textarea { padding: 10px 12px; border: 1px solid #d0d5da; border-radius: 4px; font-size: 14px; font-family: inherit; margin-top: 4px; }
.contact-form input:focus, .contact-form textarea:focus { outline: none; border-color: #27ae60; }
.btn { display: inline-block; padding: 10px 24px; background: #27ae60; color: #fff !important; border: 0; border-radius: 4px; font-weight: 600; cursor: pointer; font-size: 14px; text-decoration: none; }
.btn:hover { background: #1a8a2f; }

/* Sticky mobile bottom ad */
.sticky-ad-bar { position: fixed; bottom: 0; left: 0; right: 0; background: #fff; box-shadow: 0 -2px 8px rgba(0,0,0,.15); padding: 4px; z-index: 999; text-align: center; min-height: 60px; }
.sticky-close { position: absolute; top: -14px; right: 6px; width: 28px; height: 28px; border-radius: 50%; background: #333; color: #fff; border: 2px solid #fff; cursor: pointer; font-size: 16px; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 4px rgba(0,0,0,.2); }
@media (min-width: 901px) { .sticky-ad-bar { display: none; } }
body { padding-bottom: 70px; }

/* 404 */
.notfound { text-align: center; padding: 60px 20px; background: #fff; border-radius: 4px; border: 1px solid #eee; }
.notfound h1 { font-size: 80px; margin: 0; color: #27ae60; letter-spacing: -3px; }
.notfound .lead { font-size: 20px; color: #555; margin: 10px 0 20px; }

/* FA5 -> FA6 Brands alias so live theme's font-family works */
@font-face {
  font-family: "Font Awesome 5 Brands";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.1/webfonts/fa-brands-400.woff2") format("woff2");
}
@font-face {
  font-family: "Font Awesome 5 Free";
  font-style: normal;
  font-weight: 900;
  font-display: block;
  src: url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.2.1/webfonts/fa-solid-900.woff2") format("woff2");
}

/* Social plugin colors (sidebar big buttons) */
.social-color .facebook a { background: #3b5998; }
.social-color .twitter a { background: #1da1f2; }
.social-color .instagram a { background: #e4405f; }
.social-color .pinterest a { background: #bd081c; }
.social-color .skype a { background: #00aff0; }
.social-color .youtube a { background: #ff0000; }
.social-color .whatsapp a { background: #25d366; }

/* WhatsApp icon (not in theme by default) */
.social .whatsapp a:before {
  content: "\f232";
  font-family: "Font Awesome 5 Brands", "Font Awesome 6 Brands";
  font-weight: 400;
}

/* Footer JOIN US buttons (WhatsApp/Telegram) */
.footer .button {
  border: none; color: white; padding: 12px 28px;
  text-align: center; text-decoration: none;
  display: inline-block; cursor: pointer; font-weight: 600; font-size: 14px;
  border-radius: 3px;
}
.footer .button1 { background-color: #4CAF50; }
.footer .button2 { background-color: #008CBA; }
.footer .rox { border: 2px solid #4CAF50; padding: 3px; margin: 8px 0; width: 100%; border-collapse: separate; }
.footer .hsrox {
  font-size: 18px; padding: 10px; background-color: #e0ffff;
  color: #4CAF50; font-weight: 600;
}
.footer .hsrox2 {
  font-size: 18px; padding: 10px; background-color: #e0ffff;
  color: #008CBA; font-weight: 600;
}
.footer .rox td { padding: 8px; }
.footer .rox td:last-child { text-align: right; }

/* Copyright area link color override */
.copyright-area { text-align: center; padding: 15px 0; color: #ccc; font-size: 13px; }
.copyright-area a { color: #ff00ba; text-decoration: none; }

/* Sidebar Search form */
.sidebar-search-form { display: flex; padding: 15px; }
.sidebar-search-form input {
  flex: 1; padding: 10px 12px; border: 1px solid #eaeaea;
  border-right: 0; border-radius: 3px 0 0 3px;
  font-size: 14px; outline: none;
}
.sidebar-search-form input:focus { border-color: #27ae60; }
.sidebar-search-form button {
  padding: 10px 16px; border: 0; background: #27ae60;
  color: #fff; cursor: pointer; border-radius: 0 3px 3px 0; font-size: 14px;
}
.sidebar-search-form button:hover { background: #1a8a2f; }

/* Sidebar Contact form */
.sidebar-contact-form { display: flex; flex-direction: column; gap: 8px; padding: 15px; }
.sidebar-contact-form input,
.sidebar-contact-form textarea {
  padding: 10px 12px; border: 1px solid #eaeaea;
  border-radius: 3px; font-size: 13px; font-family: inherit; outline: none;
}
.sidebar-contact-form input:focus,
.sidebar-contact-form textarea:focus { border-color: #27ae60; }
.sidebar-contact-form textarea { resize: vertical; min-height: 90px; }
.sidebar-contact-form button {
  padding: 10px; background: #27ae60; color: #fff;
  border: 0; border-radius: 3px; cursor: pointer; font-weight: 600; font-size: 14px;
}
.sidebar-contact-form button:hover { background: #1a8a2f; }

/* Total Pageviews counter */
.counter-wrapper { text-align: center; padding: 25px 15px; }
.pageview-count {
  display: inline-block;
  font-size: 32px; font-weight: 700; color: #27ae60;
  letter-spacing: 1px;
  font-family: 'Fira Sans', sans-serif;
}

/* Tags/Label cloud - override in case theme's not applied */
.widget-content.cloud-label { padding: 15px; overflow: hidden; }
.widget-content.cloud-label ul { list-style: none; margin: 0; padding: 0; }
.widget-content.cloud-label ul::after { content: ""; display: table; clear: both; }
.widget-content.cloud-label li {
  float: left; margin: 0 5px 5px 0; list-style: none;
}
.widget-content.cloud-label li::before { display: none; }
.widget-content.cloud-label li a {
  display: block; height: 26px; line-height: 26px;
  background: #fdfdff; color: #253137;
  font-size: 12px; font-weight: 400;
  padding: 0 10px; border: 1px solid #f2f2f6; border-radius: 3px;
  text-decoration: none; transition: all .17s ease;
}
.widget-content.cloud-label li a:hover {
  color: #fff !important; background: #31942e; border-color: #31942e;
}
.widget-content.cloud-label .label-count { display: none; }

/* ============================================
   READING PROGRESS BAR
   Slim bar at top showing article scroll depth
   ============================================ */
.reading-progress {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: transparent;
  z-index: 10000;
  pointer-events: none;
}
.reading-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #31942e 0%, #4bcf47 100%);
  transition: width 0.05s linear;
  box-shadow: 0 0 8px rgba(49,148,46,0.5);
}

/* ============================================
   TABLE OF CONTENTS
   Collapsible box before article body
   ============================================ */
.toc-box {
  background: #f7faf7;
  border: 1px solid #dbe8db;
  border-left: 4px solid #31942e;
  border-radius: 6px;
  padding: 14px 18px;
  margin: 20px 0 24px;
}
.toc-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  user-select: none;
}
.toc-title {
  font-size: 16px;
  font-weight: 700;
  color: #253137;
}
.toc-toggle {
  font-size: 14px;
  color: #31942e;
  transition: transform 0.2s;
}
.toc-collapsed .toc-toggle { transform: rotate(-90deg); }
.toc-collapsed .toc-list { display: none; }
.toc-list {
  list-style: decimal inside;
  padding: 0;
  margin: 10px 0 0;
  columns: 2;
  column-gap: 24px;
}
.toc-list li {
  margin: 4px 0;
  padding: 2px 0;
  break-inside: avoid;
}
.toc-list a {
  color: #253137;
  text-decoration: none;
  font-size: 14px;
  line-height: 1.4;
}
.toc-list a:hover {
  color: #31942e;
  text-decoration: underline;
}
@media (max-width: 700px) {
  .toc-list { columns: 1; }
}
/* Smooth-scroll offset so H2 isn't hidden under any sticky header */
.post-content h2 { scroll-margin-top: 80px; }

/* ============================================
   FLOATING STICKY SHARE BUTTONS (Left side)
   ============================================ */
.sticky-share {
  position: fixed;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 998;
}
.sticky-share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transition: transform 0.15s, box-shadow 0.15s;
}
.sticky-share-btn:hover {
  transform: scale(1.12);
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
  color: #fff;
}
.sticky-share-btn.ss-whatsapp { background: #25D366; }
.sticky-share-btn.ss-facebook { background: #1877F2; }
.sticky-share-btn.ss-twitter  { background: #000; }
.sticky-share-btn.ss-telegram { background: #0088cc; }
.sticky-share-btn.ss-copy     { background: #6c757d; }
.sticky-share-copied::after {
  content: 'Copied!';
  position: absolute;
  left: 50px;
  top: 50%;
  transform: translateY(-50%);
  background: #253137;
  color: #fff;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
}
/* Hide on smaller screens where sticky bar would overlap content */
@media (max-width: 1200px) {
  .sticky-share { display: none; }
}

/* ============================================
   STICKY ANCHOR AD (MOBILE + DESKTOP)
   High-CTR bottom bar with dismiss button
   ============================================ */
.sticky-ad-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: #fff;
  border-top: 1px solid #e4e6ea;
  box-shadow: 0 -4px 16px rgba(0,0,0,0.12);
  padding: 8px 40px 4px;
  z-index: 9999;
  text-align: center;
  min-height: 70px;
  max-height: 100px;
  overflow: hidden;
}
.sticky-ad-bar .sticky-close {
  position: absolute;
  top: 4px; right: 6px;
  width: 26px; height: 26px;
  background: rgba(0,0,0,0.65);
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 18px;
  font-weight: 700;
  line-height: 26px;
  padding: 0;
  cursor: pointer;
  z-index: 2;
  transition: background 0.2s;
}
.sticky-ad-bar .sticky-close:hover { background: #000; }
.sticky-ad-bar .sticky-ad-label {
  position: absolute;
  top: 2px; left: 8px;
  font-size: 9px;
  color: #999;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  z-index: 1;
}
.sticky-ad-bar .sticky-ad-ins { max-height: 90px; }
/* Add bottom padding to body so sticky ad doesn't cover content */
body { padding-bottom: 80px; }
@media (max-width: 600px) {
  .sticky-ad-bar { min-height: 60px; padding: 6px 32px 2px; }
  body { padding-bottom: 70px; }
}

/* ============================================
   IN-FEED AD CARD (Homepage between posts)
   ============================================ */
.in-feed-ad {
  grid-column: 1 / -1;
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 12px;
  margin: 12px 0;
  text-align: center;
  min-height: 250px;
}
.in-feed-ad-label {
  display: block;
  font-size: 10px;
  color: #999;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

/* ============================================
   STICKY SIDEBAR AD (Desktop only)
   Follows scroll for higher viewability = higher CPM
   ============================================ */
@media (min-width: 981px) {
  .sidebar-sticky-ad {
    position: sticky;
    top: 20px;
    margin-top: 20px;
  }
}
.sidebar-sticky-ad-label {
  display: block;
  font-size: 10px;
  color: #999;
  text-transform: uppercase;
  text-align: center;
  margin-bottom: 4px;
}

/* ============================================
   MULTIPLEX / MATCHED CONTENT AD
   Full-width, breaks out of any floated layout
   ============================================ */
.multiplex-ad-wrap {
  clear: both;
  display: block;
  width: 100%;
  max-width: 1200px;
  margin: 30px auto;
  padding: 20px 15px;
  border-top: 1px solid #eee;
  border-bottom: 1px solid #eee;
  box-sizing: border-box;
  overflow: hidden;
}
.multiplex-ad-title {
  font-size: 18px;
  font-weight: 700;
  color: #253137;
  margin: 0 0 15px;
  text-align: center;
}
.multiplex-ad-wrap .adsbygoogle { min-height: 200px; }

/* ============================================
   MODERN SEO-FRIENDLY PAGINATION
   ============================================ */
#blog-pager {
  width: 100%;
  text-align: center;
  padding: 40px 15px 30px !important;
  margin: 30px 0 0 !important;
  border-top: 1px solid #eee !important;
  clear: both;
}

/* Numbered pagination wrapper */
.pagination-nav {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  align-items: center;
  padding: 0;
}

.pagination-nav a,
.pagination-nav span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  font-size: 15px;
  font-weight: 600;
  color: #253137;
  background: #fff;
  border: 1px solid #e4e6ea;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
  box-sizing: border-box;
  line-height: 1;
}

.pagination-nav a:hover {
  background: #31942e;
  color: #fff !important;
  border-color: #31942e;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(49,148,46,0.25);
}

.pagination-nav .current {
  background: #31942e;
  color: #fff;
  border-color: #31942e;
  cursor: default;
  box-shadow: 0 2px 8px rgba(49,148,46,0.3);
}

.pagination-nav .dots {
  background: transparent;
  border: none;
  cursor: default;
  color: #999;
}

.pagination-nav .prev-link,
.pagination-nav .next-link {
  padding: 0 18px;
  font-weight: 700;
}

.pagination-nav .disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #f5f5f5;
}

/* Legacy Load More button (fallback) */
#blog-pager .load-more {
  display: inline-block !important;
  height: auto !important;
  line-height: 1 !important;
  padding: 14px 40px !important;
  background: linear-gradient(135deg, #31942e 0%, #26761f 100%) !important;
  color: #fff !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  border-radius: 8px !important;
  border: none !important;
  box-shadow: 0 4px 14px rgba(49,148,46,0.35) !important;
  text-decoration: none !important;
  letter-spacing: 0.3px;
  transition: all 0.25s ease !important;
  cursor: pointer;
}

#blog-pager .load-more:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(49,148,46,0.45) !important;
  background: linear-gradient(135deg, #26761f 0%, #1e5c18 100%) !important;
}

#blog-pager .load-more.no-more {
  background: #f5f5f5 !important;
  color: #999 !important;
  box-shadow: none !important;
  cursor: default;
}

#blog-pager .load-more.no-more:hover {
  transform: none;
  background: #f5f5f5 !important;
}

/* Page info text */
.page-info {
  display: block;
  margin-top: 14px;
  font-size: 13px;
  color: #888;
  font-weight: 400;
}

/* Mobile responsive */
@media (max-width: 600px) {
  .pagination-nav a,
  .pagination-nav span {
    min-width: 36px;
    height: 36px;
    font-size: 13px;
    padding: 0 10px;
  }
  .pagination-nav .prev-link,
  .pagination-nav .next-link {
    padding: 0 12px;
  }
  #blog-pager .load-more {
    padding: 12px 30px !important;
    font-size: 14px !important;
  }
}

