/* ============================================================
   HENG787 theme clone — HTML + Bootstrap 5
   Rebuilt to match the live site (idea-bet.live/theme/heng787)
   ============================================================ */

:root {
  --hg-orange: #ff8223;
  --hg-orange-2: #ff6a00;
  --hg-gold: #fcd822;
  --hg-red: #8a1216;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Kanit', sans-serif;
  color: #111;
  background-color: #ffe9c7;
  background-image: url('../img/bg-main.webp');
  background-position: center top;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

a { text-decoration: none; }
img { max-width: 100%; }

/* ===================== HERO + NAV OVERLAY ===================== */
.hg-hero { position: relative; width: 100%; line-height: 0; }
.hg-hero > img { width: 100%; height: auto; display: block; }

.hg-navbar {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: transparent;
  padding: 10px 0;
}
.hg-navbar .hg-nav-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 14px;
}
.hg-menu-pill {
  display: flex;
  align-items: center;
  gap: 0;
  background: rgba(0, 0, 0, .46);
  border-radius: 10px;
  padding: 0 8px;
}
.hg-menu-pill a {
  position: relative;
  color: var(--hg-gold);
  font-weight: 600;
  font-size: 16px;
  padding: 13px 12px;
  white-space: nowrap;
  transition: color .2s;
}
/* animated 3px gold underline (matches Elementor e--pointer-underline) */
.hg-menu-pill a::after {
  content: "";
  position: absolute;
  left: 12px; right: 12px; bottom: 4px;
  height: 3px;
  background: var(--hg-gold);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .25s ease;
}
.hg-menu-pill a:hover::after,
.hg-menu-pill a.active::after { transform: scaleX(1); }
.hg-menu-pill .hg-dd { position: relative; }
.hg-menu-pill .hg-dd-menu {
  display: none;
  position: absolute;
  top: 110%; left: 0;
  background: rgba(20, 12, 4, .95);
  border: 1px solid rgba(255, 200, 90, .25);
  border-radius: 12px;
  padding: 6px;
  min-width: 190px;
  flex-direction: column;
  z-index: 60;
}
.hg-menu-pill .hg-dd:hover .hg-dd-menu { display: flex; }
.hg-menu-pill .hg-dd-menu a { font-size: 14px; }

.hg-auth { display: flex; gap: 8px; }
.hg-auth a {
  display: inline-flex; align-items: center; gap: 7px;
  font-weight: 600; font-size: 16px;
  border-radius: 10px;
  padding: 12px 22px;
  white-space: nowrap;
  color: #fff;
}
.btn-login { background: linear-gradient(180deg, #fd5704 0%, #fd1c1b 100%); color: #fff; }
.btn-register { background: linear-gradient(180deg, #fee8a0 0%, #fcb424 100%); color: #fff; text-shadow: 0 1px 2px rgba(150, 90, 0, .55); }
.btn-register i { color: #fff; }
.hg-auth a:hover { filter: brightness(1.06); }

/* hamburger (mobile) */
.hg-burger {
  display: none;
  background: rgba(20, 12, 4, .55);
  border: 1px solid rgba(255, 200, 90, .3);
  color: var(--hg-gold);
  font-size: 22px;
  border-radius: 10px;
  padding: 4px 12px;
  cursor: pointer;
}

/* ===================== SECTION TITLES ===================== */
.hg-sec-title { text-align: center; margin: 34px 0 18px; }
.hg-sec-title img { max-width: min(90%, 640px); height: auto; }

/* ===================== MARQUEE ===================== */
.hg-marquee { overflow: hidden; width: 100%; padding: 6px 0; }
.hg-marquee__track {
  display: flex;
  gap: 18px;
  width: max-content;
  animation: hg-scroll 30s linear infinite;
}
.hg-marquee:hover .hg-marquee__track { animation-play-state: paused; }
@keyframes hg-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.hg-char { flex: 0 0 auto; width: 260px; }
.hg-char img { width: 100%; height: auto; display: block; }

.hg-jp { flex: 0 0 auto; width: 360px; }
.hg-jp img { width: 100%; height: auto; display: block; }

/* ===================== PROMOTION ===================== */
.hg-strip { max-width: 1100px; margin: 10px auto 26px; }
.hg-strip img { width: 100%; height: auto; display: block; }

.hg-promo-grid { max-width: 1100px; margin: 0 auto; }
.hg-promo-grid img {
  width: 100%; height: auto; display: block;
  border-radius: 14px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .18);
  transition: transform .25s;
}
.hg-promo-grid img:hover { transform: translateY(-5px); }

.hg-ranking { text-align: center; margin: 26px auto; }
.hg-ranking img { max-width: min(94%, 660px); height: auto; border-radius: 12px; }

/* ===================== ARTICLE ===================== */
.hg-article { max-width: 1080px; margin: 10px auto 40px; padding: 0 16px; }
.hg-article h2 {
  color: var(--hg-orange);
  text-align: center;
  font-weight: 700;
  font-size: 28px;
  line-height: 1.35;
  margin: 30px 0 16px;
}
.hg-article p { color: #161616; font-size: 16px; line-height: 1.9; margin-bottom: 14px; }
.hg-article strong { color: var(--hg-orange-2); font-weight: 600; }
.hg-article ol, .hg-article ul { color: #161616; font-size: 16px; line-height: 1.9; padding-left: 1.3rem; }
.hg-article li { margin-bottom: 8px; }
.hg-article-banner { margin: 22px auto; }
.hg-article-banner img { width: 100%; height: auto; display: block; border-radius: 12px; }
.hg-side-img { text-align: center; }
.hg-side-img img { max-width: 100%; height: auto; border-radius: 12px; }

/* ===================== FIXED SOCIAL + CONTACT ===================== */
.hg-social {
  position: fixed; top: 30%; right: 0; z-index: 900;
  display: flex; flex-direction: column; gap: 4px;
}
.hg-social a img { width: 50px; height: auto; display: block; transition: transform .2s; }
.hg-social a:hover img { transform: scale(1.12); }

.hg-contact-float { position: fixed; right: 12px; bottom: 12px; z-index: 900; animation: hg-bob 2.4s ease-in-out infinite; }
.hg-contact-float img { width: 115px; height: auto; }
@keyframes hg-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 991.98px) {
  .hg-burger { display: inline-block; order: -1; }
  .hg-menu-pill {
    display: none;
    position: absolute; top: 64px; left: 12px; right: 12px;
    flex-direction: column; align-items: stretch;
    border-radius: 14px;
    background: rgba(20, 12, 4, .96);
  }
  .hg-menu-pill.open { display: flex; }
  .hg-menu-pill .hg-dd-menu { position: static; display: flex; background: rgba(0,0,0,.3); margin: 4px 0 4px 12px; }
  .hg-nav-inner { justify-content: space-between; }
  .hg-article h2 { font-size: 22px; }
}
@media (max-width: 575.98px) {
  .hg-char { width: 170px; }
  .hg-jp { width: 250px; }
  .hg-social a img { width: 40px; }
  .hg-contact-float img { width: 86px; }
  .hg-auth a { padding: 7px 12px; font-size: 13px; }
}

/* ===================== FOOTER (wired CMS — theme 15) ===================== */
.hg-footer {
  background: linear-gradient(180deg, rgba(138,18,22,.95), rgba(70,6,8,.97));
  color: #fff;
  padding: 40px 0 24px;
  margin-top: 30px;
}
.hg-footer .footer-logo { max-width: 180px; height: auto; }
.hg-footer h5 { color: var(--hg-gold); }
.hg-footer .footer-desc { color: #ffe9c7; font-size: 14px; line-height: 1.8; }
.hg-footer .footer-heading { color: var(--hg-gold); }
.hg-footer .footer-menu-btn {
  display: block;
  color: #ffe9c7;
  padding: 6px 0;
  font-weight: 500;
  transition: color .2s;
}
.hg-footer .footer-menu-btn:hover { color: var(--hg-gold); }
.hg-footer .footer-hr { border-color: rgba(255,255,255,.2); }
.hg-footer .copyright-bar { color: #ffd9a0; font-size: 14px; }

/* ==========================================================================
   PAGE-BUILDER content blocks — การ์ดเนื้อหา (พื้นสว่างเข้าธีม FURIOSA)
   ========================================================================== */
.v-content{
  background:rgba(255,255,255,.92);
  border:1px solid rgba(255,130,35,.3);
  border-radius:14px;
  padding:20px 22px;
  box-shadow:0 10px 26px rgba(138,18,22,.18);
}
/* FAQ (block_type 5) — การ์ด Q/A */
.fags .bg-faq{ background:rgba(255,255,255,.92) !important; transition:transform .18s ease, border-color .2s ease; }
.fags .bg-faq:hover{ transform:translateY(-3px); border-color:rgba(255,130,35,.6); }
.fags .bg-faq h3{ display:flex; align-items:flex-start; gap:10px; padding-bottom:12px; margin-bottom:12px; border-bottom:1px dashed rgba(255,130,35,.35); color:var(--hg-orange-2); font-weight:700; }
.fags .bg-faq h3::before{ content:"Q"; flex:0 0 auto; display:inline-grid; place-items:center; width:30px; height:30px; border-radius:50%; background:linear-gradient(180deg,var(--hg-orange),var(--hg-orange-2)); color:#fff; font-weight:800; }
.fags .bg-faq p{ display:flex; align-items:flex-start; gap:10px; margin:0; color:#161616; line-height:1.8; }
.fags .bg-faq p::before{ content:"A"; flex:0 0 auto; display:inline-grid; place-items:center; width:30px; height:30px; border-radius:50%; background:var(--hg-red); color:#fff; font-weight:800; }
/* block ผลบอลสด / ผลหวย (ถ้ามีในหน้า) */
.livescore-block, .lotto-block, .football-block, .lottopage-block{
  background:rgba(255,255,255,.92); border:1px solid rgba(255,130,35,.3);
  border-radius:14px; padding:18px 16px; box-shadow:0 10px 26px rgba(138,18,22,.18);
}
.livescore-block .b-color, .lotto-block .b-color, .football-block .b-color, .lottopage-block .b-color{ color:var(--hg-orange-2); }

/* ==========================================================================
   MOBILE BOTTOM ACTION BAR — ปุ่มเข้าสู่ระบบ/สมัคร ลอยล่างจอ (เฉพาะมือถือ)
   ========================================================================== */
.mobile-actionbar{
  position:fixed; left:0; right:0; bottom:0; z-index:1045;
  display:flex; gap:8px; padding:8px 10px calc(8px + env(safe-area-inset-bottom,0px));
  background:linear-gradient(180deg, rgba(70,6,8,.9), rgba(70,6,8,.99));
  border-top:1px solid rgba(252,216,34,.4);
  box-shadow:0 -6px 20px rgba(0,0,0,.4);
}
.mab-btn{ flex:1; text-align:center; padding:11px 8px; border-radius:10px; font-weight:700; font-size:.95rem; line-height:1.1; box-shadow:0 4px 12px rgba(0,0,0,.3); }
.mab-login{ background:linear-gradient(180deg,var(--hg-gold),#f0b800); color:#3a0608; }
.mab-register{ background:linear-gradient(180deg,var(--hg-orange),var(--hg-orange-2)); color:#fff; }
.mab-btn:active{ transform:translateY(1px); }
@media (min-width:992px){ .mobile-actionbar{ display:none; } }
@media (max-width:991.98px){
  body{ padding-bottom:70px; }
  .hg-contact-float{ bottom:82px; }
}
