/* =========================
   GLOBAL ANTI-OVERFLOW (cross devices)
========================= */
html, body { max-width: 100%; overflow-x: hidden; }
img, video, iframe { max-width: 100%; height: auto; }
iframe { width: 100% !important; max-width: 100% !important; border: 0; }

/* =========================
   LOGO SIZE (DESKTOP BASE)
========================= */
header .logo img,
.main-header .logo img {
  max-height: 100px !important;
  width: auto !important;
}

@media (max-width: 768px) {
  header .logo img,
  .main-header .logo img {
    max-height: 100px !important;
  }
}

/* =========================
   MOBILE HERO BANNER (ONE CLEAN VERSION + SWIPER FIX)
   - background fully visible (contain)
   - no overlap across devices (iOS/Android/WebView)
========================= */
@media (max-width: 768px) {

  :root{
    --mhero-h: clamp(180px, 32vw, 280px);
  }

  /* Swiper cross-device height stability */
  .banner__slider .swiper-slide{
    height: auto !important;
  }
  .banner__slider .swiper-wrapper{
    align-items: stretch !important;
  }

  /* Banner: top zone for image */
  .banner__slider .banner.banner-style2{
    min-height: 0 !important;

    /* reserve space for the background image */
    padding-top: var(--mhero-h) !important;

    /* small air under image to separate from text */
    padding-bottom: 16px !important;

    padding-left: 0 !important;
    padding-right: 0 !important;

    background-size: contain !important;
    background-position: center top !important;
    background-repeat: no-repeat !important;
    background-color: #0b0f2a !important;
  }

  /* Remove overlays if template adds them */
  .banner__slider .banner.banner-style2::before,
  .banner__slider .banner.banner-style2::after{
    opacity: 0 !important;
  }

  /* Content block BELOW image (force safe flow) */
  .banner__slider .banner.banner-style2 .banner__content{
    position: relative !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    transform: none !important;

    margin: 12px 0 0 !important;   /* ✅ ключевой отступ между картинкой и текстом */
    padding: 22px 16px 28px !important;

    background: #0b0f2a !important;
    text-align: left !important;
    z-index: 2 !important;
  }

  /* Mobile typography */
  .banner__slider .banner.banner-style2 .banner__content h3{
    font-size: 14px;
    line-height: 1.2;
    margin-bottom: 8px;
  }
  .banner__slider .banner.banner-style2 .banner__content h1{
    font-size: 22px;
    line-height: 1.2;
    margin-bottom: 10px;
  }
  .banner__slider .banner.banner-style2 .banner__content h2{
    font-size: 15px;
    line-height: 1.3;
    margin-bottom: 10px;
  }
  .banner__slider .banner.banner-style2 .banner__content p{
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 14px;
  }
}

/* =========================
   FLOATING MESSENGERS
========================= */
.floating-messengers {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  z-index: 9999;
}

.fm-btn {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  color: #fff;
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
  transition: transform .25s ease, box-shadow .25s ease;
  position: relative;
  overflow: visible;
}

.fm-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 15px 35px rgba(0,0,0,0.35);
}

.fm-btn.whatsapp { background: linear-gradient(135deg, #25D366, #1ebe5d); }
.fm-btn.telegram { background: linear-gradient(135deg, #2AABEE, #229ED9); }

@media (max-width: 768px) {
  .fm-btn {
    width: 50px;
    height: 50px;
    font-size: 24px;
  }
}

/* PULSE */
.fm-btn::after {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  opacity: 0;
  animation: fm-pulse 1.8s ease-out infinite;
}

.fm-btn.whatsapp::after { border: 2px solid rgba(37, 211, 102, 0.55); }
.fm-btn.telegram::after { border: 2px solid rgba(42, 171, 238, 0.55); }

@keyframes fm-pulse {
  0%   { transform: scale(0.75); opacity: 0.75; }
  70%  { transform: scale(1.25); opacity: 0; }
  100% { transform: scale(1.25); opacity: 0; }
}

/* =========================
   QUICK SOCIAL GRID (6 icons, 3 per row)
========================= */
.quick-social .section-header{margin-bottom:22px}
.qs-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap:14px;
}
.qs-card{
  display:flex;
  align-items:center;
  justify-content:center;
  flex-direction:column;
  gap:8px;

  padding:16px 10px;
  border-radius:14px;
  text-decoration:none;

  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);

  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.qs-card i{font-size:34px; line-height:1}
.qs-card span{font-weight:700; font-size:13px; letter-spacing:.2px}
.qs-card:hover{
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(0,0,0,.18);
  border-color: rgba(255,255,255,0.18);
}

/* Brand colors */
.qs-wa{color:#25D366}
.qs-tg{color:#2AABEE}
.qs-ig{color:#ff4fd8}
.qs-fb{color:#1877F2}
.qs-tt{color:#ffffff}
.qs-yt{color:#FF0000}

@media (max-width: 576px){
  .qs-card{padding:14px 8px}
  .qs-card i{font-size:30px}
  .qs-card span{font-size:12px}
}

/* Quick social spacing */
.quick-social{
  padding-top: 12px;
  padding-bottom: 8px;
}
.quick-social.padding-top,
.quick-social.padding-bottom{
  padding-top: 12px !important;
  padding-bottom: 8px !important;
}
.quick-social + .banner__slider{
  margin-top: 12px;
}

:root{ --header-offset: 0px; }
.quick-social{
  padding-top: calc(12px + var(--header-offset));
}

/* ===============================
   MAIN CTA BUTTON – SEVA GAMES
=============================== */
.cta-glow{
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: 100%;
  max-width: 320px;
  height: 56px;

  margin-top: 18px;

  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: #fff;
  text-decoration: none;

  border-radius: 14px;
  background: linear-gradient(135deg, #ff2f92, #ff0066, #ff2f92);

  box-shadow:
    0 0 0 rgba(255, 0, 102, 0.0),
    0 8px 24px rgba(255, 0, 102, 0.45);

  position: relative;
  overflow: hidden;

  animation: pulseGlow 2.2s infinite;
}
.cta-glow::before{
  content:"";
  position:absolute;
  inset:-2px;
  background: linear-gradient(120deg, #ff9ad5, #ff0066, #ff9ad5);
  opacity: 0.35;
  filter: blur(18px);
  z-index: -1;
}
.cta-glow:hover{
  transform: translateY(-1px) scale(1.02);
  box-shadow:
    0 0 18px rgba(255, 0, 102, 0.9),
    0 12px 30px rgba(255, 0, 102, 0.6);
}
.cta-glow:active{ transform: scale(0.98); }

@keyframes pulseGlow{
  0%{
    box-shadow:
      0 0 0 rgba(255, 0, 102, 0.0),
      0 8px 24px rgba(255, 0, 102, 0.45);
  }
  50%{
    box-shadow:
      0 0 28px rgba(255, 0, 102, 0.9),
      0 12px 36px rgba(255, 0, 102, 0.75);
  }
  100%{
    box-shadow:
      0 0 0 rgba(255, 0, 102, 0.0),
      0 8px 24px rgba(255, 0, 102, 0.45);
  }
}

/* =========================
   MOBILE LOGO – RESPONSIVE (no "one device" fit)
========================= */
@media (max-width: 768px){

  header.header-section .mobile-logo,
  header.header-section .navbar-brand,
  header.header-section .logo,
  header.header-section .mobile-logo a,
  header.header-section .navbar-brand a,
  header.header-section .logo a{
    height: clamp(84px, 20vw, 104px) !important;
    min-height: clamp(84px, 20vw, 104px) !important;
    max-height: none !important;
    display: flex !important;
    align-items: center !important;
  }

  header.header-section .mobile-logo img,
  header.header-section .navbar-brand img,
  header.header-section .logo img,
  header.header-section.sticky .mobile-logo img,
  header.header-section.fixed .mobile-logo img,
  header.header-section.is-sticky .mobile-logo img,
  header.header-section.header-fixed .mobile-logo img,
  header.header-section.shrink .mobile-logo img,
  header.header-section.affix .mobile-logo img{
    height: clamp(100px, 18vw, 96px) !important;
    width: auto !important;
    max-height: none !important;
    max-width: none !important;
  }

  header.header-section{
    min-height: clamp(84px, 20vw, 104px) !important;
  }
}

/* =========================
   MOBILE HOTLINE – FORCE 2 LINES (FINAL)
========================= */
@media (max-width: 768px){

  header.header-section .mobile-hotline a{
    display: block !important;
    text-align: right !important;
    white-space: normal !important;
    line-height: 1.15 !important;
    text-decoration: none !important;
  }

  header.header-section .mobile-hotline .hotline-label,
  header.header-section .mobile-hotline .hotline-phone{
    display: block !important;
    width: 100% !important;
    white-space: nowrap !important;
  }

  header.header-section .mobile-hotline .hotline-label{
    font-size: 11px !important;
    font-weight: 500 !important;
    opacity: 0.80 !important;
    margin-bottom: 2px !important;
  }

  header.header-section .mobile-hotline .hotline-phone{
    font-size: 15px !important;
    font-weight: 700 !important;
  }
}

/* =========================
   MOBILE: HIDE BURGER + INFO (FINAL, SAFE)
========================= */
@media (max-width: 768px){

  header.header-section.style2 .navbar-toggler,
  header.header-section.style2 .menu-toggle,
  header.header-section.style2 .hamburger,
  header.header-section.style2 .header-bar,
  header.header-section.style2 .header-bar-icon,
  header.header-section.style2 .mobile-menu-btn,
  header.header-section.style2 .meanmenu-reveal{
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  header.header-section.style2 .info-icon,
  header.header-section.style2 .header-info,
  header.header-section.style2 .header-info-btn,
  header.header-section.style2 .icon-info,
  header.header-section.style2 .info,
  header.header-section.style2 .info-btn,
  header.header-section.style2 a.info,
  header.header-section.style2 a.header-info,
  header.header-section.style2 button.info,
  header.header-section.style2 button.header-info{
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  header.header-section.style2 .info-icon i,
  header.header-section.style2 .header-info i,
  header.header-section.style2 .icon-info i{
    display: none !important;
  }
}

/* =========================
   CODE INPUT ABOVE IFRAME (MOBILE ONLY) – PREMIUM
========================= */
.mcode-before-iframe{ display:none; }

@media (max-width: 768px){

  .mcode-before-iframe{
    display:block;
    padding: 14px 16px 8px;
  }

  .mcode-box{
    max-width: 520px;
    margin: 0 auto;
    padding: 16px 16px 14px;
    border-radius: 18px;

    background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
    border: 1px solid rgba(255,255,255,0.14);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.15),
      0 14px 34px rgba(0,0,0,0.35);
  }

  .mcode-title{
    font-weight: 800;
    font-size: 14px;
    letter-spacing: .4px;
    margin-bottom: 10px;
    color:#ffffff;
    opacity:.95;
    text-transform: uppercase;
  }

  .mcode-input{
    width:100%;
    height:56px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.22);

    background: linear-gradient(180deg, rgba(0,0,0,0.55), rgba(0,0,0,0.35));
    color:#fff;
    padding: 0 16px;

    font-size: 16px; /* iOS no zoom */
    font-weight: 700;

    letter-spacing: 1px; /* 20 digits readable */
    text-align: center;

    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
  }

  .mcode-input::placeholder{
    color: rgba(255,255,255,0.55);
    letter-spacing: .6px;
    font-weight: 500;
  }

  .mcode-input:focus{
    border-color: #ff2f92;
    box-shadow:
      0 0 0 3px rgba(255,47,146,0.25),
      0 0 28px rgba(255,47,146,0.45);
  }

  .mcode-hint{
    margin-top: 8px;
    font-size: 12px;
    color: rgba(255,255,255,0.75);
    text-align: center;
  }
}
