/* Responsive Adjustments beyond Bootstrap */

/* Extra small devices (phones, 600px and down) */
@media only screen and (max-width: 576px) {
  .hero-section {
    padding: 4rem 0;
  }
  
  .hero-section h1 {
    font-size: 2.25rem;
  }
  
  .hero-visual-card {
    padding: 1.5rem;
  }
  
  .visual-amount {
    font-size: 2.25rem;
  }
  
  .calculator-header {
    padding: 1rem 1.5rem;
  }
  
  .calculator-body {
    padding: 1.5rem;
  }
  
  .results-panel {
    padding: 1.5rem;
  }
  
  .main-result-value {
    font-size: 2.5rem;
  }
  
  .blog-header {
    padding: 3rem 0;
  }
  
  .featured-content {
    padding: 1.5rem;
  }
  
  .featured-content h2 {
    font-size: 1.5rem;
  }
  
  .featured-image-container, 
  .article-featured-image {
    height: 250px;
  }
  
  .article-header h1 {
    font-size: 1.75rem;
  }
}

/* Small devices (portrait tablets and large phones, 600px and up) */
@media only screen and (min-width: 576px) and (max-width: 767px) {
  .hero-section h1 {
    font-size: 2.5rem;
  }
  
  .visual-amount {
    font-size: 2.5rem;
  }
  
  .featured-image-container, 
  .article-featured-image {
    height: 300px;
  }
}

/* Medium devices (landscape tablets, 768px and up) */
@media only screen and (min-width: 768px) and (max-width: 991px) {
  .hero-section h1 {
    font-size: 3rem;
  }
  
  .featured-image-container, 
  .article-featured-image {
    height: 350px;
  }
}

/* Large devices (laptops/desktops, 992px and up) */
@media only screen and (min-width: 992px) {
  /* Fix sticky sidebar on desktop */
  .sticky-top-sidebar {
    position: sticky;
    top: 2rem;
    z-index: 1020;
  }
}

/* Extra large devices (large laptops and desktops, 1200px and up) */
@media only screen and (min-width: 1200px) {
  /* Additional spacing if needed */
}

/* Print Styles */
@media print {
  .navbar, .footer, .calculator-header, .btn, .sidebar {
    display: none !important;
  }
  
  body {
    background-color: white;
  }
  
  .calculator-wrapper {
    box-shadow: none;
    border: 1px solid #ddd;
  }
  
  .results-panel {
    background-color: white !important;
    color: black !important;
    border: 1px solid #ddd;
  }
  
  .results-panel h3, .main-result-value {
    color: black !important;
  }
  
  .result-label {
    color: #333 !important;
  }
}


/* ==========================================================================
   Mobile Fixes (Blogs, Header Utilities, Footer)
   ========================================================================== */
@media (max-width: 991px) {
    /* Ensure Header utilities are visible outside hamburger */
    .mobile-utilities {
        display: flex !important;
        align-items: center;
        gap: 10px;
        margin-right: 15px;
    }
    .desktop-utilities {
        display: none !important;
    }
    
    /* Blog Image and text responsiveness */
    .article-featured-image img {
        height: auto !important;
        max-height: 250px !important;
        object-fit: cover;
    }
    .display-5 {
        font-size: 2rem !important;
    }
    .article-body p {
        font-size: 1.05rem;
        line-height: 1.6;
    }
    
    /* Fix Footer visibility */
    .footer {
        padding: 40px 15px 20px !important;
        text-align: center;
        overflow: hidden; /* prevent horizontal scroll */
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
    .footer .row {
        display: flex;
        flex-direction: column;
        gap: 30px;
    }
    .footer .col-lg-4, .footer .col-md-4, .footer .col-lg-2 {
        width: 100%;
        margin-bottom: 0;
    }
    .footer .d-flex {
        justify-content: center;
    }
}
@media (min-width: 992px) {
    .mobile-utilities {
        display: none !important;
    }
    .desktop-utilities {
        display: flex !important;
    }
}
