/* ========================================
   MOBILEBET - Responsive Stylesheet
   Mobile-first approach
   ======================================== */

/* === Base: Small screens (up to 480px) === */
@media (max-width: 480px) {
    body { font-size: 14px; padding-bottom: 65px; }
    .container { padding: 0 10px; }

    /* Header */
    .header-top { flex-wrap: wrap; padding: 8px 0; gap: 8px; }
    .logo img { height: 32px; }
    .header-time { display: none; }
    .header-btn-group { gap: 5px; }
    .btn-login, .btn-register, .btn-demo {
        padding: 8px 12px;
        font-size: 11px;
        min-height: 36px;
    }

    /* Navigation */
    .mobile-menu-toggle { display: block; }
    .main-navigation .container { display: flex; align-items: center; justify-content: space-between; }
    .nav-menu {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0; right: 0;
        background: #03A9F4;
        z-index: 999;
        padding: 10px 0;
        box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    }
    .nav-menu.active { display: flex; }
    .nav-link { padding: 12px 20px; font-size: 14px; }

    /* Hero */
    .mobilebet-hero { min-height: auto; margin: 10px 0; border-radius: 16px; }
    .hero-inner-content {
        flex-direction: column;
        padding: 30px 20px;
        gap: 25px;
    }
    .hero-text-side { max-width: 100%; text-align: center; }
    .hero-brand { font-size: 28px; }
    .hero-tagline { font-size: 15px; }
    .hero-description { font-size: 13px; }
    .hero-stats-row {
        flex-wrap: wrap;
        gap: 10px;
        justify-content: center;
    }
    .hero-stat { padding: 10px 12px; }
    .hero-stat-number { font-size: 18px; }
    .hero-download-ctas { justify-content: center; }
    .store-btn { padding: 10px 16px; min-height: 48px; }
    .store-btn i { font-size: 22px; }
    .store-btn-big { font-size: 14px; }

    /* Phone Mockup */
    .phone-frame { width: 200px; height: 400px; border-radius: 28px; border-width: 3px; }
    .phone-notch { width: 80px; height: 18px; }
    .phone-notch::before { width: 35px; height: 4px; top: 6px; }
    .phone-screen { top: 18px; bottom: 15px; }
    .app-header-mock { padding: 10px 8px 6px; }
    .app-logo-mock { width: 28px; height: 28px; font-size: 10px; }
    .balance-amount { font-size: 11px; }
    .app-game-tile { padding: 7px 3px; }
    .app-game-tile i { font-size: 14px; }
    .app-game-tile span { font-size: 8px; }

    /* Section titles */
    .section-title { font-size: 20px; }
    .section-subtitle { font-size: 13px; margin-bottom: 25px; }

    /* Features */
    .app-features { padding: 30px 0; }
    .features-row { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .feature-card { padding: 20px 12px; border-radius: 12px; }
    .feature-icon { width: 60px; height: 60px; }
    .feature-icon i { font-size: 24px; }
    .feature-card h3 { font-size: 12px; }
    .feature-card p { font-size: 11px; }

    /* Game Grid */
    .mobile-games { padding: 30px 0; }
    .games-grid { grid-template-columns: 1fr; gap: 12px; }
    .game-card { padding: 16px 14px; gap: 12px; }
    .game-card-icon { width: 48px; height: 48px; border-radius: 12px; }
    .game-card-icon i { font-size: 20px; }
    .game-card-info h3 { font-size: 14px; }
    .game-card-info p { font-size: 12px; }

    /* Bonuses */
    .mobile-bonuses { padding: 30px 0; }
    .bonus-card-body { padding: 16px; }
    .bonus-amount { font-size: 36px; }
    .bonus-card-body h3 { font-size: 15px; }

    /* Download Section */
    .download-section { padding: 30px 0; margin: 20px 0; border-radius: 16px; }
    .download-inner {
        flex-direction: column;
        padding: 0 20px;
        gap: 25px;
    }
    .download-text-side h2 { font-size: 22px; }
    .download-phone-side { display: none; }
    .download-buttons { flex-direction: column; }

    /* Reviews */
    .user-reviews { padding: 30px 0; }
    .reviews-grid { grid-template-columns: 1fr; gap: 12px; }
    .review-card { padding: 16px; }
    .review-text { font-size: 13px; }

    /* Footer CTA */
    .footer-cta-section { padding: 30px 20px; margin: 20px 0; border-radius: 16px; }
    .footer-cta-section h2 { font-size: 20px; }
    .cta-features { flex-direction: column; gap: 10px; align-items: center; }
    .btn-primary-cta { padding: 14px 30px; font-size: 14px; }

    /* News */
    .home-news-grid { grid-template-columns: 1fr; gap: 12px; }
    .home-news-placeholder { grid-template-columns: 1fr; }
    .article-card-thumb { height: 150px; }

    /* Bottom Tab */
    .bottom-tab-nav { padding: 6px 0; padding-bottom: calc(6px + env(safe-area-inset-bottom)); }
    .bottom-tab { padding: 4px 8px; font-size: 10px; }
    .bottom-tab i { font-size: 18px; }

    /* Footer */
    .site-footer { padding: 30px 0 15px; }
    .footer-columns-grid { grid-template-columns: 1fr; gap: 20px; }
    .footer-col h4 { font-size: 14px; }
    .license-icons { gap: 15px; }
    .license-item i { font-size: 20px; }

    /* Sidebar */
    .floating-sidebar { right: 5px; }
    .sidebar-btn { width: 40px; height: 40px; font-size: 15px; }

    /* Single/Category */
    .single-article, .page-article { padding: 16px; border-radius: 12px; }
    .article-title, .page-title { font-size: 20px; }
    .related-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .related-item-thumb { height: 90px; }
    .article-content { font-size: 14px; }

    /* Announcement */
    .announcement-content { padding: 30px 20px; max-width: 95%; }
    .announcement-title { font-size: 15px; }
    .announcement-item { padding: 10px 8px; }
}

/* === Tablet: 481px - 768px === */
@media (min-width: 481px) and (max-width: 768px) {
    .container { padding: 0 15px; }

    /* Header */
    .btn-login, .btn-register, .btn-demo { padding: 8px 14px; font-size: 12px; }
    .mobile-menu-toggle { display: block; }
    .nav-menu {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0; right: 0;
        background: #03A9F4;
        z-index: 999;
    }
    .nav-menu.active { display: flex; }

    /* Hero */
    .mobilebet-hero { min-height: auto; }
    .hero-inner-content { flex-direction: column; padding: 35px 25px; gap: 30px; }
    .hero-text-side { max-width: 100%; text-align: center; }
    .hero-brand { font-size: 34px; }
    .hero-tagline { font-size: 17px; }
    .hero-stats-row { justify-content: center; }
    .hero-download-ctas { justify-content: center; }

    /* Phone Mockup */
    .phone-frame { width: 240px; height: 480px; border-radius: 34px; }

    /* Features */
    .features-row { grid-template-columns: repeat(2, 1fr); gap: 16px; }

    /* Games */
    .games-grid { grid-template-columns: repeat(2, 1fr); }

    /* Reviews */
    .reviews-grid { grid-template-columns: repeat(2, 1fr); }

    /* Download */
    .download-inner { flex-direction: column; gap: 30px; }
    .download-phone-side { display: none; }

    /* News */
    .home-news-grid { grid-template-columns: repeat(2, 1fr); }
    .home-news-placeholder { grid-template-columns: repeat(2, 1fr); }

    /* Footer */
    .footer-columns-grid { grid-template-columns: repeat(2, 1fr); }

    /* Related */
    .related-grid { grid-template-columns: repeat(2, 1fr); }
}

/* === Tablet Landscape: 769px - 1024px === */
@media (min-width: 769px) and (max-width: 1024px) {
    .hero-inner-content { padding: 40px 30px; }
    .hero-brand { font-size: 36px; }
    .phone-frame { width: 240px; height: 480px; }
    .features-row { grid-template-columns: repeat(2, 1fr); }
    .games-grid { grid-template-columns: repeat(2, 1fr); }
    .reviews-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-columns-grid { grid-template-columns: repeat(2, 1fr); }
    .download-inner { gap: 30px; }
    .download-phone .phone-frame { width: 180px; height: 360px; }
    .related-grid { grid-template-columns: repeat(3, 1fr); }
}

/* === Desktop: 1025px+ === */
@media (min-width: 1025px) {
    .mobile-menu-toggle { display: none; }
    .nav-menu { display: flex !important; }
}

/* === Large Desktop: 1400px+ === */
@media (min-width: 1400px) {
    .container { max-width: 1320px; }
    .hero-brand { font-size: 48px; }
    .phone-frame { width: 320px; height: 640px; border-radius: 48px; }
    .phone-notch { width: 140px; height: 30px; }
    .section-title { font-size: 32px; }
}

/* === Print Styles === */
@media print {
    .site-header, .site-footer, .floating-sidebar, .bottom-tab-nav,
    .pull-to-refresh, .announcement-modal { display: none !important; }
    body { background: #fff; color: #000; padding: 0; }
    .container { max-width: 100%; }
}

/* === Accessibility: Reduced Motion === */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* === Touch-friendly enhancements === */
@media (hover: none) and (pointer: coarse) {
    .btn-login, .btn-register, .btn-demo { min-height: 48px; }
    .nav-link { padding: 14px 18px; }
    .bottom-tab { min-height: 48px; min-width: 48px; }
    .provider-tab { min-height: 48px; }
    .sidebar-btn { width: 52px; height: 52px; }
    .game-card { min-height: 80px; }
    .announcement-close { width: 48px; height: 48px; }
}

/* === Dark Mode Support === */
@media (prefers-color-scheme: dark) {
    /* Optional: Future dark mode support */
}

/* === Mobile Optimization Additions === */
@media (max-width: 768px) {
  .nav-link, .btn-login, .btn-register, .btn-demo,
  a, button, .sidebar-btn {
    min-height: 44px;
    min-width: 44px;
  }
  html, body {
    overflow-x: hidden;
    max-width: 100vw;
  }
  body {
    font-size: 16px;
    line-height: 1.6;
    -webkit-text-size-adjust: 100%;
  }
  img {
    max-width: 100%;
    height: auto;
  }
  .site-footer {
    padding-bottom: env(safe-area-inset-bottom, 20px);
  }
  .site-header {
    padding-top: env(safe-area-inset-top, 0px);
  }
  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
    }
  }
  .article-card {
    margin-bottom: 20px;
  }
  .content-area {
    padding: 10px;
  }
}
@media (max-width: 360px) {
  .container {
    padding: 0 10px;
  }
  h1, .hero-title {
    font-size: 24px !important;
  }
  h2 {
    font-size: 20px !important;
  }
}
