
/* ========================================================================= */
/* GLOBAL RESPONSIVE FIXES (Appended to ensure no horizontal scroll)         */
/* ========================================================================= */

html, body {
  overflow-x: hidden !important;
  width: 100% !important;
  max-width: 100vw !important;
  box-sizing: border-box;
  background-color: #000000 !important;
  background-image: none !important;
}

*, *::before, *::after {
  box-sizing: border-box !important;
}

img, picture, video, canvas, svg, iframe {
  max-width: 100% !important;
  height: auto;
}

/* Ensure headings wrap and do not overflow */
h1, h2, h3, h4, h5, h6, .page-title, .hero-title, .section-title {
  word-wrap: break-word !important;
  overflow-wrap: break-word !important;
  hyphens: auto;
}

/* Prevent containers from breaking viewport */
.section-container, .hero-content, .hero-visual, .nav-container, .auth-container, .wiki-content {
  max-width: 100% !important;
  overflow-x: hidden !important;
}

/* Base flex/grid items */
.categories-grid, .contact-grid, .daily-grid, .features-grid, .tools-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)) !important;
}

/* Ensure flex containers wrap properly */
.hero-stats, .dsb-inner, .dsb-text, .auth-options {
  flex-wrap: wrap !important;
}

/* ========================================================================= */
/* SPECIFIC BREAKPOINTS */
/* 1440px, 1024px, 768px, 480px, 412px, 390px, 375px, 360px, 320px */
/* ========================================================================= */

@media (max-width: 1440px) {
  .hero { padding-top: 3.5rem; padding-bottom: 2rem; }
}

@media (max-width: 1024px) {
  .hero-stats { gap: 1.25rem; }
  .dsb-inner { padding: 0.4rem 2%; }
  .section { padding-top: 2rem !important; padding-bottom: 2rem !important; }
}

@media (max-width: 768px) {
  .hero {
    flex-direction: column !important;
    text-align: center;
    padding-top: 2.5rem !important;
    padding-bottom: 2rem !important;
  }
  .page-header {
    padding-top: 2rem !important;
    padding-bottom: 1rem !important;
  }
  .hero-buttons {
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 1.25rem !important;
  }
  .btn { width: auto; }
  .stat-divider { display: none !important; }
}

@media (max-width: 480px) {
  .hero-buttons { flex-direction: column; width: 100%; }
  .btn, .btn-primary, .btn-secondary, .btn-social, .btn-submit, .btn-daily-special {
    width: 100% !important;
    max-width: 100%;
    margin-bottom: 0.5rem;
  }
  .section, .hero, .auth-wrapper { padding-left: 0.85rem !important; padding-right: 0.85rem !important; padding-top: 1.5rem !important; padding-bottom: 1.5rem !important; }
  
  /* Badges and tags */
  .badge { white-space: normal; height: auto; text-align: center; }
}

@media (max-width: 412px) {
  .hero-title, .page-title { font-size: clamp(1.8rem, 7.5vw, 2.25rem) !important; }
  .section-title { font-size: clamp(1.35rem, 5.5vw, 1.75rem) !important; }
}

@media (max-width: 390px) {
  .dsb-text { font-size: 0.8rem !important; }
  .dsb-btn { width: 100% !important; margin-top: 0.5rem; text-align: center; }
}

@media (max-width: 375px) {
  .auth-container { padding: 1.25rem !important; }
  .input-wrapper input { padding: 0.5rem 0.85rem 0.5rem 2.25rem !important; }
}

@media (max-width: 360px) {
  .feature-card { padding: 1.25rem !important; }
}

@media (max-width: 320px) {
  body { font-size: 14px !important; }
  .nav-logo span { font-size: 1.15rem !important; }
  .section { padding-left: 0.5rem !important; padding-right: 0.5rem !important; }
}
