/* ============================================
   MOBILE RESPONSIVE — Universal Spec Site Fix
   ============================================ */

/* ---- GLOBAL MOBILE (max-width: 768px) ---- */
@media (max-width: 768px) {
  /* Hero */
  .hero { min-height: 85vh !important; height: 85vh !important; }
  .hero h1, .hero-content h1 { font-size: 2.2rem !important; line-height: 1.15 !important; }
  .hero p, .hero-content p { font-size: 0.95rem !important; padding: 0 1rem; }
  .hero .eyebrow, .hero-content .eyebrow { font-size: 0.7rem !important; letter-spacing: 3px !important; }
  .hero-content { padding: 0 1.5rem !important; }
  .hero-content .btn, .hero-content .btn-primary, .hero-content .btn-outline,
  .hero-content .cta-button { 
    padding: 12px 24px !important; font-size: 0.85rem !important; 
    display: inline-block !important; margin: 0.3rem !important;
  }

  /* Stats bar */
  .stats-bar {
    position: relative !important;
    width: 100% !important;
    left: 0 !important;
    transform: none !important;
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0 !important;
    padding: 1.5rem 1rem !important;
    bottom: 0 !important;
    margin: 0 !important;
  }
  .stat-item, .stats-bar > div {
    padding: 1rem 0.5rem !important;
    text-align: center !important;
  }
  .stat-value, .stats-bar .stat-value { font-size: 2rem !important; }
  .stat-label, .stats-bar .stat-label { font-size: 0.7rem !important; }

  /* Container */
  .container { padding: 0 1.25rem !important; }

  /* Section padding */
  section, .section, .section-padding, .section-cream, .section-light, .section-dark {
    padding: 50px 0 !important;
  }

  /* Section headers */
  .section-header h2, .section-title, section h2 {
    font-size: 1.8rem !important;
    line-height: 1.2 !important;
  }
  .section-header p, .section-subtitle {
    font-size: 0.9rem !important;
    padding: 0 0.5rem;
  }
  .eyebrow { font-size: 0.7rem !important; letter-spacing: 3px !important; }

  /* Numbered services */
  .service-item, .service-card, .numbered-section {
    padding: 1rem 0 !important;
  }
  .service-number, .number-label, .section-number {
    font-size: 1.5rem !important;
  }
  .service-item h3, .service-card h3, .numbered-section h3 {
    font-size: 1.1rem !important;
  }
  .services-grid { 
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }

  /* Grids → single column */
  .grid-2, .grid-3, .grid-4,
  .communities-grid, .community-grid,
  .listings-grid, .testimonials-grid,
  .footer-grid, .footer-columns {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* Community cards */
  .community-card, .card-overlay {
    min-height: 200px !important;
    height: 200px !important;
  }
  .community-content h3, .card-overlay-title {
    font-size: 1.4rem !important;
  }

  /* Listing cards */
  .listing-card { margin-bottom: 1rem; }
  .listing-image { height: 200px !important; }
  .listing-price { font-size: 1.2rem !important; }

  /* Parallax breaks */
  .parallax-break, .cinematic-break {
    height: 40vh !important;
    min-height: 300px !important;
    background-attachment: scroll !important;
  }
  .parallax-content h2 {
    font-size: 1.8rem !important;
    line-height: 1.2 !important;
  }
  .parallax-content p { font-size: 0.9rem !important; padding: 0 1rem; }

  /* Testimonials */
  .testimonial-card { padding: 1.5rem !important; margin-bottom: 1rem; }
  .testimonial-card p, .testimonial-text { font-size: 0.9rem !important; }

  /* Watermark text */
  .watermark-text, [class*="watermark"] {
    font-size: 80px !important;
    opacity: 0.015 !important;
  }

  /* Nav */
  .nav-links, .main-nav > ul { display: none !important; }
  .mobile-toggle, .hamburger, .menu-toggle, .nav-toggle { display: flex !important; }
  header, .site-header, .header {
    padding: 0.75rem 1rem !important;
  }
  .header-logo img, .site-logo img, .logo img { max-height: 35px !important; }
  .site-logo, .header-logo, .logo { font-size: 1.1rem !important; }
  .logo-subtitle, .logo-tagline { font-size: 0.55rem !important; }

  /* Footer */
  footer, .site-footer {
    padding: 2.5rem 1.25rem !important;
    text-align: center;
  }
  .footer-grid, .footer-columns, footer .container > div {
    grid-template-columns: 1fr !important;
    text-align: center;
  }
  footer h3, footer h4 { font-size: 1rem !important; margin-bottom: 0.5rem; }
  footer p, footer li, footer a { font-size: 0.85rem !important; }

  /* Buttons */
  .btn, .btn-primary, .btn-outline, .cta-button {
    padding: 12px 28px !important;
    font-size: 0.85rem !important;
  }
  .btn + .btn, .cta-button + .cta-button {
    margin-left: 0 !important;
    margin-top: 0.5rem !important;
  }

  /* CTA section */
  .section-dark h2, .cta-section h2 { font-size: 1.8rem !important; }
  .section-dark p { font-size: 0.95rem !important; }

  /* Horizontal overflow prevention */
  body, html { overflow-x: hidden !important; }
  img, video { max-width: 100% !important; }
  .marquee, [class*="marquee"] { display: none !important; }
}

/* ---- SMALL MOBILE (max-width: 480px) ---- */
@media (max-width: 480px) {
  .hero h1, .hero-content h1 { font-size: 1.8rem !important; }
  .hero { min-height: 75vh !important; }
  .section-header h2, .section-title, section h2 { font-size: 1.5rem !important; }
  .parallax-content h2 { font-size: 1.5rem !important; }
  .stat-value { font-size: 1.6rem !important; }
  .community-card, .card-overlay { min-height: 180px !important; height: 180px !important; }
}

/* ---- TABLET (max-width: 1024px) ---- */
@media (max-width: 1024px) and (min-width: 769px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr) !important; }
  .hero h1, .hero-content h1 { font-size: 2.8rem !important; }
  .stats-bar { padding: 1.5rem 2rem !important; }
}

/* Fix Aurora hero text cutoff - hero content needs centering */
@media (max-width: 768px) {
  .hero-content {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
  }
  /* Fix buttons side-by-side overflow */
  .hero-content > div, .hero-content .btn-group {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 0.5rem !important;
    width: 100% !important;
  }
  .hero-content .btn, .hero-content a.btn-primary, .hero-content a.btn-outline {
    width: 80% !important;
    max-width: 280px !important;
    text-align: center !important;
    margin: 0.25rem auto !important;
    box-sizing: border-box !important;
  }
  /* Donald stats bar — only 3 items */
  .stats-bar[style*="grid"] { grid-template-columns: repeat(2, 1fr) !important; }
  /* Ugo stats — already vertical, make 2x2 */
  .stats-grid { grid-template-columns: repeat(2, 1fr) !important; }
}
/* ============================================
   MOBILE ROUND 2 — Overflow + Polish Fixes
   ============================================ */

@media (max-width: 768px) {
  /* Kill ALL horizontal overflow */
  body, html, main, .site-main, .page-content {
    overflow-x: hidden !important;
    max-width: 100vw !important;
  }

  /* Stats bar — force contained layout, kill translateX */
  .stats-bar, .stats-container, [class*="stats-bar"], [class*="stats"] {
    position: relative !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    transform: none !important;
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0 !important;
    padding: 1.2rem !important;
    box-sizing: border-box !important;
    margin: 0 !important;
  }
  .stat-item {
    padding: 0.8rem 0.5rem !important;
    text-align: center !important;
  }
  .stat-value, .stat-item h3 {
    font-size: 1.8rem !important;
    line-height: 1.2 !important;
  }
  .stat-label, .stat-item p {
    font-size: 0.65rem !important;
    letter-spacing: 1px !important;
    margin: 0 !important;
  }

  /* Watermark text — hide or shrink drastically */
  .watermark-text, [class*="watermark"], .footer-watermark {
    display: none !important;
  }

  /* Hero — proper sizing and centering */
  .hero {
    min-height: 100vh !important;
    min-height: 100svh !important;
    padding-top: 80px !important;
  }
  .hero-content {
    padding: 0 1.5rem !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  .hero h1, .hero-content h1 {
    font-size: 2rem !important;
    line-height: 1.15 !important;
    margin-bottom: 0.8rem !important;
  }
  .hero p, .hero-content > p {
    font-size: 0.85rem !important;
    line-height: 1.6 !important;
    max-width: 320px !important;
    margin: 0 auto 1.5rem !important;
    opacity: 0.9;
  }
  .hero .eyebrow, .hero-content .eyebrow {
    font-size: 0.6rem !important;
    letter-spacing: 3px !important;
    margin-bottom: 0.8rem !important;
  }

  /* Hero buttons — stack vertically, reasonable size */
  .hero-content > div,
  .hero-content > div[style*="margin"] {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 0.6rem !important;
    width: 100% !important;
    margin-top: 0 !important;
  }
  .hero .btn, .hero-content .btn,
  .hero .btn-primary, .hero-content .btn-primary,
  .hero .btn-outline, .hero-content .btn-outline,
  .hero .cta-button, .hero-content .cta-button {
    width: auto !important;
    min-width: 200px !important;
    max-width: 260px !important;
    padding: 12px 28px !important;
    font-size: 0.75rem !important;
    letter-spacing: 1.5px !important;
    text-align: center !important;
    display: inline-block !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }
  /* Kill inline margin-left on outline buttons */
  .hero .btn-outline[style*="margin-left"],
  .hero-content .btn-outline[style*="margin-left"] {
    margin-left: 0 !important;
  }

  /* Section headings tighter */
  section h2, .section h2, .section-title {
    font-size: 1.6rem !important;
    line-height: 1.2 !important;
    padding: 0 0.5rem;
  }

  /* Service items — no gold line overflow */
  .service-item, .service-card, .numbered-section {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  .service-item h3, .service-card h3 {
    font-size: 1rem !important;
  }
  .service-item p, .service-card p {
    font-size: 0.85rem !important;
  }

  /* Parallax breaks */
  .parallax-break, .cinematic-break {
    height: 35vh !important;
    min-height: 280px !important;
  }
  .parallax-content h2 {
    font-size: 1.5rem !important;
    padding: 0 1rem;
  }
  .parallax-content p {
    font-size: 0.8rem !important;
    padding: 0 1.5rem;
  }
  .parallax-content .btn, .parallax-content .btn-primary {
    padding: 10px 24px !important;
    font-size: 0.75rem !important;
  }

  /* Community cards — taller for mobile */
  .community-card, .card-overlay {
    min-height: 220px !important;
    border-radius: 8px !important;
    overflow: hidden !important;
  }

  /* Listing cards */
  .listing-card {
    border-radius: 8px !important;
    overflow: hidden !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08) !important;
  }
  .listing-image { height: 200px !important; }
  .listing-content { padding: 1rem !important; }
  .listing-price { font-size: 1.2rem !important; }
  .listing-content h3 { font-size: 1rem !important; }
  .listing-details { font-size: 0.8rem !important; flex-wrap: wrap !important; gap: 0.5rem !important; }

  /* Testimonials */
  .testimonial-card {
    padding: 1.5rem !important;
    border-radius: 8px !important;
  }
  .testimonial-card p { font-size: 0.85rem !important; line-height: 1.6 !important; }
  .testimonial-card .author { font-size: 0.85rem !important; }
  .testimonial-card .location { font-size: 0.75rem !important; }

  /* CTA sections */
  .section-dark h2 { font-size: 1.6rem !important; padding: 0 1rem; }
  .section-dark p { font-size: 0.85rem !important; padding: 0 1rem; }

  /* Footer */
  footer .container, .site-footer .container {
    padding: 0 1.25rem !important;
  }
  footer { padding: 2rem 0 !important; }
  .footer-bottom { font-size: 0.75rem !important; padding: 1rem 0 !important; }

  /* Mobile menu — allow off-canvas without body overflow */
  .mobile-menu {
    position: fixed !important;
    z-index: 9999 !important;
  }

  /* Scroll indicator */
  .scroll-indicator, [class*="scroll-down"], [class*="scroll-to"] {
    display: none !important;
  }
}

/* Small phones */
@media (max-width: 380px) {
  .hero h1, .hero-content h1 { font-size: 1.7rem !important; }
  section h2, .section h2 { font-size: 1.4rem !important; }
  .stat-value, .stat-item h3 { font-size: 1.5rem !important; }
  .hero .btn, .hero-content .btn { min-width: 180px !important; font-size: 0.7rem !important; }
}
/* ============================================
   SITE-SPECIFIC MOBILE FIXES
   ============================================ */

/* DONALD — stats bar absolute inside hero */
@media (max-width: 768px) {
  .stats-bar {
    position: relative !important;
    bottom: auto !important;
    left: auto !important;
    width: 100% !important;
    transform: none !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    padding: 1rem !important;
    box-sizing: border-box !important;
  }
  .stats-container {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .stats-bar .stat-item {
    padding: 0.5rem !important;
    text-align: center !important;
  }
  .stats-bar .stat-item h3 {
    font-size: 1.5rem !important;
    margin: 0 0 0.2rem 0 !important;
  }
  .stats-bar .stat-item p {
    font-size: 0.55rem !important;
    margin: 0 !important;
    letter-spacing: 1px !important;
    text-transform: uppercase !important;
  }

  /* Hero content — centered */
  .hero-content {
    text-align: center !important;
    padding: 0 1.5rem !important;
    width: 100% !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
  }
  .hero-content h1 {
    font-size: 2.2rem !important;
    text-shadow: 1px 2px 4px rgba(0,0,0,0.4) !important;
  }
  .hero-content p {
    font-size: 0.85rem !important;
    max-width: 300px !important;
  }
  .hero-content .cta-button,
  .hero-content .btn,
  .hero-content .btn-primary {
    padding: 12px 28px !important;
    font-size: 0.75rem !important;
    margin: 0 auto !important;
  }

  /* Hero needs more padding at bottom for stats */
  .hero {
    padding-bottom: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    min-height: auto !important;
    height: auto !important;
  }

  /* Service number alignment */
  .section-number {
    font-size: 1.2rem !important;
  }

  /* Listing grid */
  .listings-grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* Footer columns */
  footer .footer-content,
  footer .container > div {
    display: flex !important;
    flex-direction: column !important;
    gap: 1.5rem !important;
    text-align: center !important;
  }
}
