/* ===== COMPREHENSIVE MOBILE RESPONSIVE DESIGN ===== */

/* Fixed Mobile Search Bar - Always Visible, Never Scrolls */
.mobile-search-bar {
  position: fixed !important;
  top: 60px !important; /* Position under navbar */
  left: 0 !important;
  right: 0 !important;
  z-index: 1040 !important;
  background-color: white !important;
  border-bottom: 1px solid #e9ecef !important;
  padding: 0.75rem 1rem !important;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
  transform: translateY(0) !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Allow hide functionality - search bar hides on scroll */
.mobile-search-bar.hidden {
  transform: translateY(-100%) !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* Mobile Search Container - Single Line with Icon */
.mobile-search-container {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.mobile-search-input {
  border: 1px solid #1baaae;
  border-radius: 2rem;
  font-size: 0.9rem;
  padding: 0.75rem 3.5rem 0.75rem 1rem;
  color: #333;
  background-color: white;
  height: 48px;
  width: 100%;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.mobile-search-icon {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background-color: #40B0A0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.1rem;
  pointer-events: auto;
  cursor: pointer;
  z-index: 2;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(64, 176, 160, 0.3), 
              0 0 0 1px rgba(255, 255, 255, 0.1);
}

.mobile-search-icon:hover {
  background-color: #36A092;
  transform: translateY(-50%) scale(1.05);
  box-shadow: 0 4px 12px rgba(64, 176, 160, 0.4), 
              0 0 0 1px rgba(255, 255, 255, 0.2);
}

.mobile-search-icon:active {
  transform: translateY(-50%) scale(0.95);
}

/* Show Search Button */
.mobile-show-search {
  position: fixed;
  top: 70px;
  right: 1rem;
  z-index: 1030;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.3s ease;
}

.mobile-show-search.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-show-search .btn {
  border-radius: 2rem;
  padding: 0.5rem 1rem;
  font-size: 0.8rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.mobile-search-input:focus {
  border-color: #1baaae;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  color: #333;
  background-color: white;
  outline: none;
}

.mobile-search-input:focus + .mobile-search-icon {
  color: #159a9e;
}

.mobile-search-input::placeholder {
  color: #999;
  font-weight: 400;
}

/* Adjust body and navbar for fixed search bar */
@media (max-width: 991.98px) {
  body {
    padding-top: 125px !important; /* Space for navbar + search bar (60px + 65px) */
  }
  
  /* Fixed Navbar - Always at top */
  .navbar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 1050 !important;
    background-color: white !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08) !important;
    padding: 0.75rem 1rem !important;
  }
  
  /* Fixed Search Bar - Always visible, never scrolls */
  .mobile-search-bar {
    position: fixed !important;
    top: 60px !important; /* Under navbar */
    left: 0 !important;
    right: 0 !important;
    z-index: 1040 !important;
    background-color: white !important;
    transform: translateY(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
  
  /* Allow hide functionality - search bar hides on scroll */
  .mobile-search-bar.hidden {
    transform: translateY(-100%) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }
  
  /* Keep search bar styled consistently with single line and icon */
  .mobile-search-container {
    position: relative !important;
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
  }
  
  .mobile-search-input {
    font-size: 0.9rem;
    padding: 0.75rem 3.5rem 0.75rem 1rem !important;
    color: #333 !important;
    background-color: white !important;
    height: 48px;
    width: 100% !important;
    border: 1px solid #1baaae !important;
    border-radius: 2rem !important;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
  }
  
  .mobile-search-icon {
    position: absolute !important;
    right: 0.5rem !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 40px !important;
    height: 40px !important;
    background-color: #40B0A0 !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: white !important;
    font-size: 1.1rem !important;
    pointer-events: auto !important;
    cursor: pointer !important;
    z-index: 2 !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 2px 8px rgba(64, 176, 160, 0.3), 
                0 0 0 1px rgba(255, 255, 255, 0.1) !important;
  }
  
  .mobile-search-icon:hover {
    background-color: #36A092 !important;
    transform: translateY(-50%) scale(1.05) !important;
    box-shadow: 0 4px 12px rgba(64, 176, 160, 0.4), 
                0 0 0 1px rgba(255, 255, 255, 0.2) !important;
  }
  
  .mobile-search-icon:active {
    transform: translateY(-50%) scale(0.95) !important;
  }
}

/* Critical mobile fixes */
@media (max-width: 768px) {
  /* Ensure all content is visible on mobile */
  .page-hero {
    display: block !important;
  }
  
  main {
    display: block !important;
    min-height: 50vh;
  }
  
  /* Fix mobile viewport */
  body {
  overflow-x: hidden;
  }
  
  /* Mobile-specific container fixes */
  .container-fluid {
    width: 100%;
    max-width: 100%;
  }
}

/* Mobile First Approach - Base styles for mobile */
@media (max-width: 575.98px) {
  /* Mobile Container Fixes */
  .container-fluid {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
  
  .container {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }
  
  /* Ensure content is visible on mobile */
  .page-hero {
    display: block !important;
    padding: 1rem 0 !important;
  }
  
  main {
    display: block !important;
    min-height: 50vh;
  }
  
  /* Mobile Navigation */
  .navbar {
    padding: 0.5rem 0.75rem;
  }
  
  .navbar-brand {
    font-size: 1.1rem;
  }
  
  .navbar-toggler {
    border: none;
    padding: 0.25rem 0.5rem;
  }
  
  .navbar-toggler:focus {
    box-shadow: none;
  }
  
  /* Mobile navbar toggler - ensure it's clickable */
  .navbar-toggler {
    position: relative;
    z-index: 1070;
    cursor: pointer;
    padding: 0.5rem;
    border: none !important;
    background: transparent;
  }
  
  .navbar-collapse {
    background: white;
    border-radius: 0.5rem;
    margin-top: 0.5rem;
    padding: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1060;
  }
  
  .navbar-collapse.collapsing {
    height: auto;
    transition: height 0.35s ease;
  }
  
  .navbar-nav {
    flex-direction: column;
  }
  
  .navbar-nav .nav-item {
    margin: 0.25rem 0;
  }
  
  .navbar-nav .nav-link {
    padding: 0.75rem 0;
    font-weight: 500;
    font-size: 0.9rem;
  }
  
  /* Mobile Search */
  .nav-search {
    margin: 0.5rem 0;
    order: -1;
  }
  
  .nav-search-group {
    border-radius: 0.5rem;
  }
  
  .nav-search-input {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }
  
  .nav-search-btn {
    padding: 0.5rem 0.75rem;
  }
  
  /* Mobile Hero */
  .hero-slide {
    min-height: 250px;
    border-radius: 0.5rem;
  }
  
  /* Make hero section full width on mobile */
  #hero {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: -1rem !important;
    margin-right: -1rem !important;
    width: calc(100% + 2rem) !important;
  }
  
  .hero-slider {
    margin-left: -1rem;
    margin-right: -1rem;
    width: calc(100% + 2rem);
  }
  
  .hero-slide {
    border-radius: 0 !important;
  }
  
  .hero-slider {
    margin-bottom: 1rem;
  }
  
  .hero-control {
    display: none; /* Hide carousel controls on mobile */
  }
  
  .carousel-indicators {
    bottom: 0.5rem;
  }
  
  .carousel-indicators [data-bs-target] {
    width: 8px;
    height: 8px;
    border-radius: 50%;
  }
  
  .hero-copy {
    padding: 1rem;
  }
  
  .hero-copy h1 {
    font-size: 1.5rem;
    line-height: 1.2;
  }
  
  .hero-copy p {
    font-size: 0.9rem;
  }
  
  /* Mobile Product Cards */
  .product-card {
    margin-bottom: 1rem;
    border-radius: 0.75rem;
    background-color: white !important;
    border: 1px solid #dee2e6 !important;
  }
  
  .product-image {
    height: 180px;
    border-radius: 0.75rem 0.75rem 0 0;
    object-fit: cover;
    width: 100%;
  }
  
  .product-card .card-body {
    padding: 0.75rem;
    background-color: white !important;
  }
  
  /* Fix text truncation - allow text to wrap properly */
  .product-card .card-title {
    font-size: 0.85rem;
    min-height: 2.4rem;
    max-height: 3.6rem;
    line-height: 1.2;
    color: #212529 !important;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
  }
  
  .product-card .card-title a {
    color: #212529 !important;
    text-decoration: none;
  }
  
  /* Fix product description truncation */
  .product-card .product-desc,
  .product-card .card-text {
    font-size: 0.75rem;
    line-height: 1.3;
    color: #6c757d !important;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-wrap: break-word;
    word-break: break-word;
    margin-bottom: 0.5rem;
  }
  
  /* Fix price section */
  .product-card .price-section {
    margin-bottom: 0.75rem;
    min-height: 2rem;
  }
  
  .product-card .price-section .h6 {
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
  }
  
  .product-card .btn {
    font-size: 0.75rem;
    padding: 0.5rem 0.75rem;
    min-height: 36px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  
  /* Add to cart button styling */
  .btn-outline-dark {
    border-color: #1baaae !important;
    color: #1baaae !important;
  }
  
  .btn-outline-dark:hover {
    background-color: #1baaae !important;
    border-color: #1baaae !important;
    color: white !important;
  }
  
  /* Ensure all card elements have proper colors on mobile */
  .card {
    background-color: white !important;
    border: 1px solid #dee2e6 !important;
  }
  
  .card-body {
    background-color: white !important;
  }
  
  .card-title {
    color: #212529 !important;
  }
  
  .card-text {
    color: #6c757d !important;
  }
  
  /* Mobile Product Sections */
  .section-title {
    font-size: 1.5rem;
  }
  
  .section-subtitle {
    font-size: 0.85rem;
  }
  
  /* Mobile Product Grid */
  .col-6 {
    padding-left: 0.375rem;
    padding-right: 0.375rem;
  }
  
  /* Mobile Product Images */
  .product-image {
    height: 180px;
    object-fit: cover;
  }
  
  /* Mobile Product Badges */
  .badge {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
  }
  
  /* Mobile Background and Text Colors */
  body {
    background-color: #f8f9fa !important;
  }
  
  .container-fluid {
    background-color: #f8f9fa !important;
  }
  
  main {
    background-color: #f8f9fa !important;
  }
  
  section {
    background-color: transparent !important;
  }
  
  /* Mobile Text Colors */
  .text-dark {
    color: #212529 !important;
  }
  
  .text-muted {
    color: #6c757d !important;
  }
  
  .text-success {
    color: #198754 !important;
  }
  
  .text-danger {
    color: #dc3545 !important;
  }
  
  /* Mobile Product Grid */
  .col-6 {
    padding-left: 0.375rem;
    padding-right: 0.375rem;
  }
  
  /* Mobile Forms */
  .form-control, .form-select {
    font-size: 16px; /* Prevents zoom on iOS */
    padding: 0.75rem;
    border-radius: 0.5rem;
  }
  
  .btn {
    min-height: 44px; /* Touch-friendly */
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
  }
  
  /* Mobile Typography */
  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }
  h4 { font-size: 1.1rem; }
  h5 { font-size: 1rem; }
  h6 { font-size: 0.9rem; }
  
  /* Mobile Spacing */
  .py-5 {
    padding-top: 2rem !important;
    padding-bottom: 2rem !important;
  }
  
  .my-5 {
    margin-top: 2rem !important;
    margin-bottom: 2rem !important;
  }
  
  /* Mobile Page Header */
  .page-hero {
    padding: 1.5rem 0;
  }
  
  .page-hero h1 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
  }
  
  /* Mobile Footer */
  .footer-gradient .container {
    padding: 1rem;
  }
  
  .footer-gradient .col-12 {
    margin-bottom: 1.5rem;
  }
  
  .footer-gradient h6 {
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
  }
  
  .footer-gradient .list-unstyled li {
    margin-bottom: 0.5rem;
  }
  
  .footer-gradient .form-control {
    font-size: 0.9rem;
    padding: 0.75rem;
  }
  
  .footer-gradient .btn {
    font-size: 0.9rem;
    padding: 0.75rem 1rem;
  }
  
  /* Mobile Category Cards */
  .category-card {
    min-height: 80px;
    padding: 0.75rem;
  }
  
  .category-icon i {
    font-size: 1.5rem;
  }
  
  .category-name h6 {
    font-size: 0.8rem;
  }
  
  /* Mobile Sections */
  .section-title {
    font-size: 1.5rem;
  }
  
  .section-subtitle {
    font-size: 0.85rem;
  }
  
  /* Mobile Auth Forms */
  .auth-split {
    margin: 0.5rem;
    border-radius: 0.75rem;
  }
  
  .auth-left-card {
    padding: 1.5rem;
  }
  
  .auth-form .form-control {
    padding: 0.75rem;
    font-size: 0.9rem;
  }
  
  .auth-form .btn {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }
  
  /* Mobile Cart */
  .cart-item {
    padding: 0.75rem;
  }
  
  .cart-item img {
    width: 60px;
    height: 60px;
  }
  
  /* Mobile Buttons */
  .btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
  }
  
  .btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
  }
  
  /* Mobile Grid Improvements */
  .row {
    margin-left: -0.375rem;
    margin-right: -0.375rem;
  }
  
  .row > * {
    padding-left: 0.375rem;
    padding-right: 0.375rem;
  }
  
  /* Mobile Mega Menu */
  .mega-menu {
    position: static !important;
    box-shadow: none !important;
    border: 1px solid #dee2e6 !important;
    margin-top: 0.5rem;
    border-radius: 0.5rem;
  }
  
  /* Mobile Dropdown - Keep position absolute for user dropdown */
  .dropdown-menu {
    float: none;
    margin-top: 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
  }
  
  /* Only make mega menu static on mobile */
  .mega-menu {
    position: static !important;
    width: 100%;
  }
  
  /* Mobile Alerts */
  .alert {
    font-size: 0.9rem;
    padding: 0.75rem;
    margin: 0.5rem 0;
    border-radius: 0.5rem;
  }
  
  /* Mobile Tables */
  .table-responsive {
    border: none;
  }
  
  .table {
    font-size: 0.85rem;
  }
  
  .table th,
  .table td {
    padding: 0.5rem 0.25rem;
  }
  
  /* Mobile Modals */
  .modal-dialog {
    margin: 0.5rem;
  }
  
  .modal-content {
    border-radius: 0.5rem;
  }
  
  /* Mobile Carousel */
  .carousel-control-prev,
  .carousel-control-next {
    display: none;
  }
  
  .carousel-indicators {
    bottom: 0.5rem;
  }
  
  .carousel-indicators [data-bs-target] {
    width: 8px;
    height: 8px;
    border-radius: 50%;
  }
  
  /* Mobile Breadcrumbs */
  .breadcrumb {
    font-size: 0.8rem;
    padding: 0.5rem 0;
  }
  
  .breadcrumb-item {
    padding: 0.25rem 0;
  }
  
  /* Mobile Badges */
  .badge {
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
  }
  
  /* Mobile Cards */
  .card {
    border-radius: 0.75rem;
    margin-bottom: 1rem;
  }
  
  .card-body {
    padding: 1rem;
  }
  
  /* Mobile Input Groups */
  .input-group {
    flex-wrap: wrap;
  }
  
  .input-group .form-control {
    border-radius: 0.5rem 0.5rem 0 0;
  }
  
  .input-group .btn {
    border-radius: 0 0 0.5rem 0.5rem;
    width: 100%;
  }
  
  /* Mobile List Groups */
  .list-group-item {
    padding: 0.75rem;
    font-size: 0.9rem;
  }
  
  /* Mobile Pagination */
  .pagination {
    justify-content: center;
    flex-wrap: wrap;
  }
  
  .page-link {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }
  
  /* Mobile Touch Improvements */
  button, a, input, select, textarea {
    min-height: 44px;
    min-width: 44px;
  }
  
  /* Mobile Form Improvements */
  .form-control:focus {
    border-color: var(--mint-dark);
    box-shadow: 0 0 0 0.2rem rgba(73, 185, 171, 0.25);
  }
  
  /* Mobile Button Improvements */
  .btn:active {
    transform: scale(0.98);
  }
  
  /* Mobile Navigation Improvements */
  .navbar-toggler-icon {
    width: 1.2em;
    height: 1.2em;
  }
  
  /* Mobile Search Improvements */
  .nav-search-group {
    border-radius: 0.5rem;
    overflow: hidden;
  }
  
  .nav-search-input {
    border: none;
    outline: none;
  }
  
  .nav-search-input:focus {
    box-shadow: none;
  }
  
  /* Mobile Product Card Improvements */
  .product-card:hover {
    transform: none; /* Disable hover effects on mobile */
  }
  
  /* Mobile Category Card Improvements */
  .category-card:hover {
    transform: none; /* Disable hover effects on mobile */
  }
  
  /* Mobile Footer Improvements */
  .footer-gradient {
    padding: 2rem 0;
  }
  
  /* Mobile Alert Improvements */
  .alert-dismissible .btn-close {
    padding: 0.75rem 1rem;
  }
  
  /* Mobile Modal Improvements */
  .modal-backdrop {
    background-color: rgba(0, 0, 0, 0.5);
  }
  
  /* Mobile Dropdown Improvements */
  .dropdown-toggle::after {
    margin-left: 0.5em;
  }
  
  /* Mobile Pagination Improvements */
  .pagination .page-link {
    padding: 0.5rem 0.75rem;
    margin: 0 0.125rem;
  }
  
  /* Mobile Table Improvements */
  .table-responsive {
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
  }
  
  /* Mobile List Group Improvements */
  .list-group {
    border-radius: 0.5rem;
  }
  
  .list-group-item {
    border-radius: 0;
  }
  
  .list-group-item:first-child {
    border-top-left-radius: 0.5rem;
    border-top-right-radius: 0.5rem;
  }
  
  .list-group-item:last-child {
    border-bottom-left-radius: 0.5rem;
    border-bottom-right-radius: 0.5rem;
  }
}

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) and (max-width: 767.98px) {
  .hero-slide {
    min-height: 300px;
  }
  
  /* Make hero section full width on small tablets */
  #hero {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: -2rem !important;
    margin-right: -2rem !important;
    width: calc(100% + 4rem) !important;
  }
  
  .hero-slider {
    margin-left: -2rem;
    margin-right: -2rem;
    width: calc(100% + 4rem);
  }
  
  .hero-slide {
    border-radius: 0 !important;
  }
  
  .product-image {
    height: 220px;
  }
  
  .category-card {
    min-height: 90px;
  }
  
  .nav-search {
    max-width: 400px;
    margin: 0 auto;
  }
  
  /* Tablet Navigation */
  .navbar-collapse {
    background: white;
    border-radius: 0.5rem;
    margin-top: 0.5rem;
    padding: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  }
  
  .navbar-nav {
    flex-direction: column;
  }
  
  .navbar-nav .nav-item {
    margin: 0.25rem 0;
  }
  
  .navbar-nav .nav-link {
    padding: 0.75rem 0;
    font-weight: 500;
  }
  
  /* Tablet Forms */
  .form-control, .form-select {
    font-size: 16px;
    padding: 0.75rem;
  }
  
  .btn {
    min-height: 44px;
    padding: 0.75rem 1rem;
  }
  
  /* Tablet Product Cards */
  .product-card .card-body {
    padding: 1rem;
  }
  
  .product-card .card-title {
    font-size: 0.9rem;
  }
  
  /* Tablet Typography */
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.5rem; }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) and (max-width: 991.98px) {
  .hero-slide {
    min-height: 350px;
  }
  
  /* Make hero section full width on tablets */
  #hero {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: -3rem !important;
    margin-right: -3rem !important;
    width: calc(100% + 6rem) !important;
  }
  
  .hero-slider {
    margin-left: -3rem;
    margin-right: -3rem;
    width: calc(100% + 6rem);
  }
  
  .hero-slide {
    border-radius: 0 !important;
  }
  
  .product-image {
    height: 250px;
  }
  
  .product-card-xl .product-image {
    height: 300px;
  }
  
  .category-card {
    min-height: 100px;
  }
  
  .mega-menu {
    max-width: 600px;
  }
  
  .nav-search {
    max-width: 500px;
  }
  
  /* Tablet Navigation */
  .navbar-nav .nav-link {
    padding: 0.5rem 0.75rem;
  }
  
  /* Tablet Forms */
  .form-control, .form-select {
    padding: 0.75rem;
  }
  
  /* Tablet Product Cards */
  .product-card .card-body {
    padding: 1rem;
  }
  
  .product-card .card-title {
    font-size: 1rem;
  }
  
  /* Tablet Typography */
  h1 { font-size: 2.25rem; }
  h2 { font-size: 2rem; }
  h3 { font-size: 1.75rem; }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
  .hero-slide {
    min-height: 520px;
  }
  
  /* Make hero section full width on desktop */
  #hero {
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-left: -100px !important;
    margin-right: -100px !important;
    width: calc(100% + 200px) !important;
  }
  
  .hero-slider {
    margin-left: -100px;
    margin-right: -100px;
    width: calc(100% + 200px);
  }
  
  .hero-slide {
    border-radius: 0 !important;
  }
  
  .product-image {
    height: 320px;
  }
  
  .product-card-xl .product-image {
    height: 420px;
  }
  
  .category-card {
    min-height: 120px;
  }
  
  .mega-menu {
    max-width: 800px;
  }
  
  .nav-search {
    max-width: 600px;
  }
  
  .navbar-nav .nav-link {
    padding: 0.5rem 1rem;
  }
  
  .product-card:hover {
    transform: translateY(-8px);
  }
  
  .category-card:hover {
    transform: translateY(-5px);
  }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
  .container {
    max-width: 1140px;
  }
  
  .hero-slide {
    min-height: 600px;
  }
  
  .product-image {
    height: 350px;
  }
  
  .product-card-xl .product-image {
    height: 450px;
  }
}

/* Ultra wide screens (1400px and up) */
@media (min-width: 1400px) {
  .container {
    max-width: 1320px;
  }
  
  .hero-slide {
    min-height: 700px;
  }
}

/* Mobile landscape orientation */
@media (max-width: 768px) and (orientation: landscape) {
  .hero-slide {
    min-height: 200px;
  }
  
  .navbar {
    padding: 0.25rem 0;
  }
  
  .page-hero {
    padding: 1rem 0;
  }
}

/* High DPI mobile devices */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .product-image {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* Dark mode support for mobile */
@media (prefers-color-scheme: dark) and (max-width: 768px) {
  .card {
    background-color: #1a1a1a;
    border-color: #333;
  }
  
  .form-control {
    background-color: #2a2a2a;
    border-color: #444;
    color: #fff;
  }
  
  .btn-outline-dark {
    border-color: #666;
    color: #fff;
  }
}

/* Reduced motion for mobile */
@media (prefers-reduced-motion: reduce) and (max-width: 768px) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .product-card:hover,
  .category-card:hover {
    transform: none !important;
  }
}

/* Print styles */
@media print {
  .navbar,
  .footer-gradient,
  .btn,
  .carousel-control-prev,
  .carousel-control-next {
    display: none !important;
  }
  
  .container {
    max-width: none !important;
  }
  
  .product-card {
    break-inside: avoid;
    margin-bottom: 1rem;
  }
}
