/*
Theme Name: thaiSeo
Theme URI: https://line.me/ti/p/~thaiseo
Author: thaiSeo
Author URI: https://line.me/ti/p/~thaiseo
Description: ธีมเว็บไซต์ระดับพรีเมียม ศูนย์รวมข้อมูลกีฬา ผลบอลสด ตารางคะแนน ไฮไลท์ และการตลาดครบวงจร พัฒนาโดย thaiSeo
Version: 3.0.0
Text Domain: thaiseo
*/

:root {
  --primary: #0284c7;
  --primary-light: #38bdf8;
  --primary-dark: #0369a1;
  --primary-subtle: #e0f2fe;
  --primary-50: #f0f9ff;
  --secondary: #0f172a;
  --accent-gold: #f59e0b;
  --accent-gold-light: #fef3c7;
  --accent-emerald: #10b981;
  --accent-coral: #f43f5e;
  --bg-page: #f8fafc;
  --bg-surface: #ffffff;
  --border-color: #cbd5e1;
  --border-focus: #38bdf8;
  --text-main: #0f172a;       /* คมชัด สีเข้มอ่านง่ายมาก */
  --text-muted: #334155;      /* คมชัด ไม่ซีดจาง */
  --text-light: #64748b;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;
  --shadow-sm: 0 2px 4px rgba(2, 132, 199, 0.04);
  --shadow-md: 0 8px 20px -4px rgba(2, 132, 199, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 20px 30px -10px rgba(2, 132, 199, 0.16), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Base & Typography */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'IBM Plex Sans Thai', 'Prompt', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.8;
  letter-spacing: 0.01em;
  margin: 0;
  padding: 0;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Prompt', 'IBM Plex Sans Thai', sans-serif;
  color: #0f172a;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.015em;
}

p, li, span, small {
  color: #1e293b;
}

.text-muted {
  color: #475569 !important; /* คมชัด ไม่ซีด */
}

/* Standard Bootstrap Container Max-Width */
.container {
  max-width: 1200px;
  padding-left: 15px;
  padding-right: 15px;
  margin-left: auto;
  margin-right: auto;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Prompt', 'Kanit', sans-serif;
  color: var(--secondary);
  font-weight: 600;
  letter-spacing: -0.01em;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-dark);
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
}

/* Top Announcement Bar */
.top-notice-bar {
  background: linear-gradient(90deg, #0284c7, #0ea5e9, #38bdf8);
  color: #ffffff;
  padding: 6px 0;
  font-size: 0.86rem;
  font-weight: 400;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* Header & Standard Navigation Bar (Non-overflowing) */
.site-header {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid #e0f2fe;
  position: sticky;
  top: 0;
  z-index: 1020;
  box-shadow: 0 4px 15px rgba(2, 132, 199, 0.05);
  transition: var(--transition);
}

.site-navbar {
  padding: 8px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  flex-wrap: nowrap;
}

.site-brand {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.site-brand img.custom-logo,
.site-brand .brand-logo-img {
  max-height: 40px;
  width: auto;
  object-fit: contain;
  transition: var(--transition);
}

.site-brand:hover img {
  transform: scale(1.02);
}

/* Header Nav Menu - Clean & Compact */
.main-navigation {
  flex-shrink: 0;
}

.main-navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
}

.main-navigation ul li {
  position: relative;
  white-space: nowrap;
}

.main-navigation ul li a {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  color: var(--text-main);
  font-weight: 500;
  font-size: 0.92rem;
  border-radius: var(--radius-pill);
  transition: var(--transition);
  white-space: nowrap;
}

.main-navigation ul li a:hover,
.main-navigation ul li.current-menu-item > a {
  background: var(--primary-50);
  color: var(--primary);
}

/* Header Search & Actions */
.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.header-search-form {
  position: relative;
  display: flex;
  align-items: center;
}

.header-search-input {
  border: 1.5px solid var(--border-color);
  background: var(--primary-50);
  border-radius: var(--radius-pill);
  padding: 6px 14px 6px 34px;
  font-size: 0.85rem;
  color: var(--text-main);
  outline: none;
  width: 160px;
  transition: var(--transition);
}

.header-search-input:focus {
  width: 200px;
  border-color: var(--primary);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.12);
}

.header-search-icon {
  position: absolute;
  left: 12px;
  color: var(--primary);
  font-size: 0.82rem;
  pointer-events: none;
}

.btn-header-badge {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #ffffff;
  padding: 6px 15px;
  border-radius: var(--radius-pill);
  font-weight: 500;
  font-size: 0.86rem;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: none;
  white-space: nowrap;
  box-shadow: 0 3px 8px rgba(2, 132, 199, 0.25);
  transition: var(--transition);
}

.btn-header-badge:hover {
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 5px 12px rgba(2, 132, 199, 0.35);
}

/* Mobile Toggle */
.mobile-nav-toggle {
  background: none;
  border: 1.5px solid var(--primary-subtle);
  color: var(--primary);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  font-size: 1.15rem;
  cursor: pointer;
  transition: var(--transition);
}

.mobile-nav-toggle:hover {
  background: var(--primary-50);
}

/* Mobile Offcanvas Drawer */
.mobile-menu-drawer {
  position: fixed;
  top: 0;
  right: -320px;
  width: 300px;
  height: 100vh;
  background: #ffffff;
  z-index: 1050;
  box-shadow: -5px 0 25px rgba(0, 0, 0, 0.15);
  padding: 24px 20px;
  overflow-y: auto;
  transition: right 0.35s ease;
}

.mobile-menu-drawer.open {
  right: 0;
}

.mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 16px;
  margin-bottom: 20px;
}

.mobile-drawer-close {
  background: none;
  border: none;
  font-size: 1.4rem;
  color: var(--text-muted);
  cursor: pointer;
}

.mobile-menu-drawer ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.mobile-menu-drawer ul li {
  margin-bottom: 8px;
}

.mobile-menu-drawer ul li a {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  color: var(--text-main);
  font-weight: 500;
  border-radius: var(--radius-sm);
}

.mobile-menu-drawer ul li a:hover {
  background: var(--primary-50);
  color: var(--primary);
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(2px);
  z-index: 1040;
  display: none;
}

.drawer-backdrop.active {
  display: block;
}

/* Hero Section */
.hero-education-section {
  background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 50%, #f8fafc 100%);
  border-bottom: 1px solid #bae6fd;
  padding: 45px 0 50px;
  position: relative;
  overflow: hidden;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #bae6fd;
  color: var(--primary-dark);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
  margin-bottom: 16px;
}

.hero-title {
  font-size: 2.3rem;
  font-weight: 700;
  color: var(--secondary);
  line-height: 1.3;
  margin-bottom: 16px;
}

.hero-title span.text-gradient {
  background: linear-gradient(135deg, var(--primary) 0%, #0284c7 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-description {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 24px;
  max-width: 600px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn-primary-custom {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #ffffff;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.3);
  transition: var(--transition);
  border: none;
}

.btn-primary-custom:hover {
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(2, 132, 199, 0.4);
}

.btn-outline-custom {
  background: #ffffff;
  color: var(--primary-dark);
  border: 1.5px solid #bae6fd;
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.btn-outline-custom:hover {
  background: var(--primary-50);
  border-color: var(--primary);
  color: var(--primary);
}

.hero-stat-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

.hero-stat-box {
  background: #ffffff;
  border: 1px solid #e0f2fe;
  border-radius: var(--radius-md);
  padding: 18px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.hero-stat-box:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: #bae6fd;
}

.hero-stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--primary-50);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.hero-stat-number {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--secondary);
  line-height: 1.2;
}

.hero-stat-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Standard Game Grid Section (กราดเกม) */
.game-topics-section {
  padding: 45px 0 35px;
}

.section-header-wrap {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 35px;
}

.section-badge {
  background: var(--primary-50);
  border: 1px solid #bae6fd;
  color: var(--primary);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 4px 14px;
  border-radius: var(--radius-pill);
  display: inline-block;
  margin-bottom: 8px;
}

.section-main-title {
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--secondary);
  margin-bottom: 10px;
}

.section-subtitle {
  font-size: 0.98rem;
  color: var(--text-muted);
}

/* 4-Column Standard Game Cards Grid (กราดเกม) */
.knowledge-category-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 40px;
}

.knowledge-category-card {
  background: #ffffff;
  border: 1px solid #e0f2fe;
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.knowledge-category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: #7dd3fc;
}

.cat-card-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.cat-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.icon-blue { background: #e0f2fe; color: #0284c7; }
.icon-gold { background: #fef3c7; color: #d97706; }
.icon-emerald { background: #d1fae5; color: #059669; }
.icon-purple { background: #ede9fe; color: #7c3aed; }
.icon-coral { background: #ffe4e6; color: #e11d48; }
.icon-cyan { background: #cffafe; color: #0891b2; }

.cat-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 0;
  color: var(--secondary);
}

.cat-card-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  flex-grow: 1;
  line-height: 1.55;
}

.cat-card-features {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  font-size: 0.82rem;
  color: var(--text-main);
}

.cat-card-features li {
  margin-bottom: 5px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.cat-card-features li i {
  color: var(--accent-emerald);
  font-size: 0.72rem;
}

.cat-card-link {
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: auto;
}

.cat-card-link:hover {
  gap: 9px;
}

/* Articles Section / 3-Column Standard Grid */
.articles-section {
  padding: 35px 0 60px;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.article-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #bae6fd;
}

.article-card-thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #e0f2fe;
  overflow: hidden;
}

.article-card-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.article-card:hover .article-card-thumb-wrap img {
  transform: scale(1.05);
}

.article-category-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(2, 132, 199, 0.9);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(4px);
  z-index: 2;
}

.article-card-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.article-meta-info {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-light);
  margin-bottom: 8px;
}

.article-card-title {
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 10px;
}

.article-card-title a {
  color: var(--secondary);
}

.article-card-title a:hover {
  color: var(--primary);
}

.article-card-excerpt {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
  flex-grow: 1;
}

.article-card-footer {
  border-top: 1px solid #f1f5f9;
  padding-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.article-author-info {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-main);
}

.article-author-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e0f2fe;
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
}

.btn-read-more {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-read-more:hover {
  gap: 8px;
}

/* Pagination */
.nigoal-pagination {
  margin-top: 35px;
  display: flex;
  justify-content: center;
  gap: 6px;
}

.nigoal-pagination a,
.nigoal-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border-radius: var(--radius-sm);
  background: #ffffff;
  border: 1.5px solid #e0f2fe;
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.9rem;
  transition: var(--transition);
}

.nigoal-pagination a:hover,
.nigoal-pagination span.current {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 3px 8px rgba(2, 132, 199, 0.25);
}

/* Footer - Clean Light Theme */
.site-footer {
  background: #f8fafc;
  color: #475569;
  padding-top: 60px;
  border-top: 1px solid #e2e8f0;
}

.footer-brand {
  margin-bottom: 18px;
}

.footer-brand img {
  max-height: 90px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.06));
}

.footer-desc {
  font-size: 0.88rem;
  line-height: 1.7;
  color: #64748b;
  margin-bottom: 16px;
}

.footer-title {
  color: #0f172a;
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 18px;
  position: relative;
  padding-bottom: 8px;
}

.footer-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 28px;
  height: 2px;
  background: var(--primary);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-links li a {
  color: #475569;
  font-size: 0.88rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.footer-links li a:hover {
  color: var(--primary);
  transform: translateX(3px);
  text-decoration: none;
}

.footer-disclaimer-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #f59e0b;
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin-top: 35px;
  margin-bottom: 25px;
  font-size: 0.85rem;
  color: #475569;
  line-height: 1.7;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.02), 0 2px 4px -1px rgba(0,0,0,0.02);
}

.footer-disclaimer-card strong {
  color: #0369a1;
}

.footer-bottom {
  border-top: 1px solid #e2e8f0;
  padding: 24px 0;
  font-size: 0.85rem;
  text-align: center;
  color: #64748b;
  background: transparent;
}

/* Responsive Grid Adjustments */
@media (max-width: 1200px) {
  .knowledge-category-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 991px) {
  .knowledge-category-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .articles-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero-title {
    font-size: 1.9rem;
  }
}

@media (max-width: 576px) {
  .knowledge-category-grid {
    grid-template-columns: 1fr;
  }
  .articles-grid {
    grid-template-columns: 1fr;
  }
  .hero-stat-cards {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 1.6rem;
  }
}

/* Social Icon Links */
.social-icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #ffffff !important;
  font-size: 1.15rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  text-decoration: none !important;
}

.social-icon-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15) !important;
  color: #ffffff !important;
}

/* Partner Logos */
.partner-logo-link {
  display: inline-block;
  transition: transform 0.3s ease, filter 0.3s ease;
}
.partner-logo-link:hover {
  transform: translateY(-4px);
  filter: drop-shadow(0 6px 10px rgba(0,0,0,0.1));
}
.partner-logo-link img {
  max-height: 55px;
  width: auto;
  object-fit: contain;
}

/* =========================================================
   🔥 FLOATING SIDE ADS (แบนเนอร์ลอยติดขอบจอด้านข้าง ซ้าย-ขวา)
   ========================================================= */
.floating-side-ad-wrap {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1040;
  width: 155px;
  max-width: 165px;
}

.floating-ad-left {
  left: 14px;
}

.floating-ad-right {
  right: 14px;
}

.floating-ad-inner {
  position: relative;
}

/* Close Button (✕) */
.floating-ad-close-btn {
  position: absolute;
  top: -9px;
  right: -9px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #ffffff;
  color: #64748b;
  border: 1.5px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(0,0,0,0.18);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 15;
  padding: 0;
  outline: none;
}

.floating-ad-close-btn:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
  transform: scale(1.15) rotate(90deg);
}

/* Glassmorphism Ad Card */
.floating-ad-demo-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 16px;
  padding: 14px 10px 14px;
  text-align: center;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(0, 0, 0, 0.04);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
}

.floating-ad-demo-card.line-theme {
  border: 1.5px solid #86efac;
}

.floating-ad-demo-card.vip-theme {
  border: 1.5px solid #fde047;
  background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(254,243,199,0.95) 100%);
}

.floating-ad-demo-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
}

/* Badge & Pulse Animation */
.floating-ad-badge {
  font-size: 9.5px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 999px;
  background: #00c300;
  color: #ffffff;
  display: inline-block;
  margin-bottom: 6px;
  letter-spacing: 0.3px;
}

.floating-ad-badge.vip-badge {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

@keyframes adPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}
.pulse-anim {
  animation: adPulse 2.2s infinite ease-in-out;
}

/* Icon & Logos */
.floating-ad-icon-wrap {
  font-size: 28px;
  color: #00c300;
  margin-bottom: 3px;
  line-height: 1;
}

.floating-ad-icon-wrap.vip-icon {
  color: #f59e0b;
}

/* Titles */
.floating-ad-title {
  font-size: 12.5px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 2px;
  line-height: 1.25;
}

.floating-ad-subtitle {
  font-size: 10px;
  color: #64748b;
  margin: 0 0 8px;
  line-height: 1.3;
}

/* QR Box */
.floating-ad-qr-box {
  background: #ffffff;
  padding: 5px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  display: inline-block;
  margin-bottom: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.floating-ad-qr-img {
  width: 82px;
  height: 82px;
  display: block;
  margin: 0 auto 3px;
  border-radius: 4px;
}

.floating-ad-qr-label {
  font-size: 9px;
  font-weight: 700;
  color: #00c300;
  display: block;
}

/* Promo Box (VIP) */
.floating-ad-promo-box {
  background: #ffffff;
  border: 1px dashed #f59e0b;
  border-radius: 10px;
  padding: 6px 4px;
  margin-bottom: 8px;
}

.floating-ad-promo-tag {
  font-size: 9px;
  font-weight: 700;
  color: #d97706;
}

.floating-ad-promo-val {
  font-size: 13.5px;
  font-weight: 900;
  color: #b45309;
  line-height: 1.2;
}

.floating-ad-promo-desc {
  font-size: 8.5px;
  color: #78350f;
}

/* Action Buttons */
.floating-ad-btn {
  display: block;
  width: 100%;
  padding: 6px 6px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  text-decoration: none !important;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.floating-ad-btn.line-btn {
  background: #00c300;
  color: #ffffff !important;
  box-shadow: 0 4px 10px rgba(0, 195, 0, 0.3);
}

.floating-ad-btn.line-btn:hover {
  background: #00a300;
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(0, 195, 0, 0.45);
}

.floating-ad-btn.vip-btn {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff !important;
  box-shadow: 0 4px 10px rgba(2, 132, 199, 0.3);
}

.floating-ad-btn.vip-btn:hover {
  background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 14px rgba(2, 132, 199, 0.45);
}

/* Responsive Hide for Floating Ads (ซ่อนอัตโนมัติเมื่อจอเล็กกว่า 1360px เพื่อไม่ให้บังเนื้อหาเว็บ) */
@media (max-width: 1350px) {
  .floating-side-ad-wrap {
    display: none !important;
  }
}

/* =========================================================
   💬 LINE OFFICIAL & QR CODE CONTACT BAR (รูปแบบที่ 3)
   ========================================================= */

/* 1. Mobile Sticky Candy Capsule Bar */
.line-mobile-sticky-bar {
  display: none;
  position: fixed;
  bottom: 12px;
  left: 12px;
  right: 12px;
  z-index: 1048;
  animation: lineSlideUp 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.line-capsule-card {
  background: linear-gradient(135deg, #064e3b 0%, #047857 50%, #059669 100%);
  border: 1.5px solid rgba(167, 243, 208, 0.5);
  border-radius: 50px;
  padding: 7px 12px 7px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  box-shadow: 0 10px 25px rgba(6, 78, 59, 0.45), 0 4px 10px rgba(0,0,0,0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: relative;
}

.line-capsule-left {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow: hidden;
}

.line-icon-badge {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #00c300;
  color: #ffffff;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 195, 0, 0.4);
}

.line-text-wrap {
  overflow: hidden;
  text-align: left;
}

.line-text-title {
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.line-text-sub {
  color: #a7f3d0;
  font-size: 9.5px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.line-capsule-right {
  flex-shrink: 0;
}

.line-cta-btn {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff !important;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 13px;
  border-radius: 999px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-decoration: none !important;
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.45);
  border: 1px solid rgba(255,255,255,0.4);
  transition: transform 0.2s ease;
}

.line-cta-btn:active {
  transform: scale(0.96);
}

.pulse-glow {
  animation: pulseGlowAnim 2s infinite ease-in-out;
}

@keyframes pulseGlowAnim {
  0% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7); }
  70% { box-shadow: 0 0 0 10px rgba(245, 158, 11, 0); }
  100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0); }
}

.line-bar-close-btn {
  position: absolute;
  top: -7px;
  right: 6px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #ffffff;
  color: #64748b;
  border: 1px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  z-index: 10;
  padding: 0;
}

.line-bar-close-btn:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
}

/* 2. Desktop Floating Pill */
.line-desktop-floating-pill {
  display: none;
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1045;
  animation: lineSlideUp 0.4s ease-out;
}

.line-pill-body {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 2px solid #86efac;
  border-radius: 50px;
  padding: 6px 12px 6px 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 10px 28px rgba(0, 195, 0, 0.2), 0 4px 8px rgba(0,0,0,0.06);
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.line-pill-body:hover {
  transform: translateY(-3px) scale(1.02);
  border-color: #00c300;
  box-shadow: 0 14px 36px rgba(0, 195, 0, 0.3);
}

.line-pill-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #00c300;
  color: #ffffff;
  font-size: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 195, 0, 0.35);
}

.line-pill-info {
  text-align: left;
}

.line-pill-title {
  font-size: 12px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.25;
}

.line-pill-id {
  font-size: 10px;
  color: #475569;
  line-height: 1.2;
}

.line-pill-qr-trigger {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 12px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 3px 8px rgba(2, 132, 199, 0.3);
  transition: all 0.2s ease;
}

.line-pill-qr-trigger:hover {
  background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
  transform: scale(1.05);
}

.line-pill-close-btn {
  position: absolute;
  top: -8px;
  right: -6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #ffffff;
  color: #64748b;
  border: 1px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  z-index: 10;
  padding: 0;
}

.line-pill-close-btn:hover {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
}

/* 3. Desktop QR Code Modal Pop-up */
.line-qr-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.line-qr-modal-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.line-qr-modal-card {
  background: #ffffff;
  border-radius: 24px;
  padding: 26px 22px 22px;
  max-width: 350px;
  width: 100%;
  text-align: center;
  position: relative;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45);
  transform: scale(0.92);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.line-qr-modal-backdrop.active .line-qr-modal-card {
  transform: scale(1);
}

.line-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f1f5f9;
  color: #64748b;
  border: none;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.line-modal-close:hover {
  background: #ef4444;
  color: #ffffff;
  transform: rotate(90deg);
}

.line-modal-brand-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #00c300;
  color: #ffffff;
  font-size: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 10px;
  box-shadow: 0 4px 14px rgba(0, 195, 0, 0.35);
}

.line-modal-title {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 3px;
  line-height: 1.3;
}

.line-modal-sub {
  font-size: 11px;
  color: #64748b;
  margin: 0 0 12px;
}

.line-modal-qr-frame {
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 16px;
  padding: 10px;
  display: inline-block;
  margin-bottom: 12px;
  box-shadow: inset 0 2px 6px rgba(0,0,0,0.04);
}

.line-modal-qr-img {
  width: 150px;
  height: 150px;
  display: block;
  margin: 0 auto 6px;
  border-radius: 8px;
}

.line-modal-qr-badge {
  font-size: 10.5px;
  font-weight: 700;
  color: #00c300;
}

.line-modal-id-box {
  background: #f1f5f9;
  border-radius: 10px;
  padding: 7px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: #334155;
  margin-bottom: 12px;
}

.line-copy-btn {
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 10.5px;
  font-weight: 700;
  color: #0284c7;
  cursor: pointer;
  transition: all 0.2s ease;
}

.line-copy-btn:hover {
  background: #0284c7;
  color: #ffffff;
  border-color: #0284c7;
}

.line-modal-open-btn {
  display: block;
  width: 100%;
  background: #00c300;
  color: #ffffff !important;
  font-size: 13px;
  font-weight: 800;
  padding: 10px;
  border-radius: 12px;
  text-decoration: none !important;
  box-shadow: 0 4px 14px rgba(0, 195, 0, 0.35);
  transition: all 0.2s ease;
}

.line-modal-open-btn:hover {
  background: #00a300;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 195, 0, 0.45);
}

/* Breakpoint visibility */
@media (max-width: 991px) {
  .line-mobile-sticky-bar {
    display: block;
  }
  .line-desktop-floating-pill {
    display: none !important;
  }
}

@media (min-width: 992px) {
  .line-mobile-sticky-bar {
    display: none !important;
  }
  .line-desktop-floating-pill {
    display: block;
  }
}

/* --- Mobile Layout Overflow Fixes --- */
@media (max-width: 768px) {
  html, body {
    overflow-x: hidden !important;
    width: 100%;
    position: relative;
  }
  
  /* Fix images and media overflowing */
  img, iframe, video, canvas, svg {
    max-width: 100%;
    height: auto;
  }

  /* Fix tables breaking layout */
  table, .table, table.dataTable {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-collapse: collapse;
  }
  
  /* Fix long URLs or strings breaking layout */
  p, h1, h2, h3, h4, h5, h6, a, div, span, * {
    word-break: break-word;
  }
  
  /* Reset bootstrap row margins on mobile if causing overflow */
  .row {
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
  
  /* Ensure container doesn't exceed screen */
  .container, .container-fluid {
    width: 100%;
    max-width: 100%;
    padding-left: 15px;
    padding-right: 15px;
  }
  
  /* --- Live Match Center Mobile Fixes --- */
  .hp-section-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px;
  }
  .hp-section-title {
    font-size: 1.15rem !important;
    line-height: 1.4 !important;
    align-items: flex-start !important;
  }
  .hp-section-title .hp-icon-box {
    flex-shrink: 0;
  }
  .hp-view-all-btn {
    align-self: flex-start !important;
    padding-left: 52px;
  }
  
  .hp-mc-btn {
    font-size: 0.75rem !important;
    padding: 8px 4px !important;
    white-space: normal !important;
    line-height: 1.2 !important;
  }
  
  .hp-mc-hero .col-4 {
    padding-left: 5px !important;
    padding-right: 5px !important;
  }
  .hp-mc-hero .font-weight-bold {
    font-size: 11px !important;
  }
  
  /* --- Global Rule: Prevent Horizontal Scrolling on Mobile --- */
  html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
    width: 100%;
    position: relative;
  }
  
  /* Prevent child elements from breaking out of the viewport */
  img, iframe, video, object, embed {
    max-width: 100% !important;
    height: auto !important;
  }
  
  /* --- Hide Ugly Scrollbars on Mobile (Allow swipe but no visual scrollbar) --- */
  *::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
  }
  * {
    -ms-overflow-style: none !important;
    scrollbar-width: none !important;
  }

  /* --- Force Calendar Strip to fit screen perfectly --- */
  .hp-calendar-strip {
    justify-content: space-between !important;
    gap: 2px !important;
    padding: 6px 2px !important;
  }
  .hp-date-pill {
    flex: 1 !important;
    min-width: 0 !important;
    padding: 6px 0 !important;
    border-radius: 6px !important;
  }
  .hp-date-pill .day-name {
    font-size: 9px !important;
    letter-spacing: -0.5px !important;
  }
  .hp-date-pill .day-date {
    font-size: 9px !important;
    letter-spacing: -0.5px !important;
    white-space: nowrap;
  }
  .hp-date-picker-wrap {
    gap: 2px !important;
    margin-left: 2px !important;
  }
  .thai-date-custom-box .btn {
    padding: 4px !important;
  }

  /* --- Highlight Cards 2x2 Grid Mobile Adjustments --- */
  .hp-highlight-card .hp-highlight-title {
    font-size: 12px !important;
    line-height: 1.4 !important;
    white-space: normal !important;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    margin-bottom: 2px !important;
  }
  .hp-highlight-body {
    padding: 10px !important;
  }
  .hp-highlight-body .small {
    font-size: 10px !important;
  }
  .hp-play-circle {
    width: 32px !important;
    height: 32px !important;
    font-size: 12px !important;
  }

  /* --- Predictions Cards 2x2 Grid Mobile Adjustments --- */
  .hp-pred-card {
    padding: 8px !important;
    border-radius: 12px !important;
  }
  .hp-pred-team-name-compact {
    font-size: 9px !important;
  }
  .hp-pred-team-logo-compact {
    width: 20px !important;
    height: 20px !important;
  }
  .hp-pred-vs-compact {
    font-size: 10px !important;
    margin: 0 4px !important;
  }
  .hp-pred-prob-wrap-compact .text-muted span {
    font-size: 8px !important;
    letter-spacing: -0.5px !important;
  }
  .hp-pred-insight-compact {
    font-size: 9px !important;
  }
  
  /* --- Post/News Cards 2x2 Grid Mobile Adjustments --- */
  .hp-post-card .hp-post-title {
    font-size: 11px !important;
    line-height: 1.3 !important;
    white-space: normal !important;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    margin-bottom: 2px !important;
  }
  .hp-post-body {
    padding: 8px 10px !important;
  }
  .hp-post-body .badge {
    font-size: 9px !important;
    padding: 3px 6px !important;
  }
  .hp-post-body small {
    font-size: 9px !important;
  }
  
  /* --- Reduce Gap Between Sections and Footer on Mobile --- */
  .site-footer {
    padding-top: 30px !important;
  }
  .mb-5 {
    margin-bottom: 1.5rem !important;
  }
  
  /* --- Footer Links 2-Column Mobile Adjustments --- */
  .footer-title {
    font-size: 13px !important;
    margin-bottom: 15px !important;
  }
  .footer-links li {
    margin-bottom: 10px !important;
  }
  .footer-links li a {
    font-size: 11px !important;
    line-height: 1.3 !important;
    white-space: normal !important;
    word-break: break-word;
  }
  .footer-links i {
    font-size: 10px !important;
    margin-right: 4px !important;
  }

  /* --- Footer Disclaimer & SEO Box Mobile Adjustments --- */
  .footer-disclaimer-card {
    padding: 12px 15px !important;
    font-size: 10px !important;
    margin-bottom: 15px !important;
  }
  .footer-disclaimer-card i {
    font-size: 1.2rem !important;
    margin-right: 10px !important;
  }
  .footer-seo-box {
    padding: 15px !important;
    font-size: 10px !important;
    line-height: 1.5 !important;
    border-radius: 10px !important;
  }
  .footer-seo-box h1, 
  .footer-seo-box h2, 
  .footer-seo-box h3, 
  .footer-seo-box strong {
    font-size: 12px !important;
    line-height: 1.4 !important;
    margin-bottom: 8px !important;
  }
  
  /* --- INNER PAGES MOBILE STANDARD 2-COLUMN OVERRIDES --- */
  /* Predictions Page Grid */
  .pred-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }
  .pred-card {
    padding: 8px !important;
    border-radius: 12px !important;
  }
  .pred-team-logo {
    width: 20px !important;
    height: 20px !important;
  }
  .pred-team-name {
    font-size: 9px !important;
  }
  .pred-score-vs {
    font-size: 10px !important;
    margin: 2px 4px !important;
  }
  .pred-insight {
    font-size: 9px !important;
    line-height: 1.3 !important;
  }
  .pred-win-bar {
    height: 4px !important;
  }
  
  /* Highlights Page Grid */
  .hl-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }
  .hl-card-body {
    padding: 8px !important;
  }
  .hl-card-title {
    font-size: 11px !important;
    line-height: 1.3 !important;
    white-space: normal !important;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }
  .hl-meta {
    font-size: 9px !important;
  }
  .hl-play-btn {
    width: 32px !important;
    height: 32px !important;
    font-size: 12px !important;
  }
}

/* --- Footer SEO Box --- */
.footer-seo-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 24px 28px;
  margin-bottom: 24px;
  color: #475569;
  font-size: 13.5px;
  line-height: 1.7;
}