/* ===================================
   MOBILE FIXES - ALL PAGES
   =================================== */

/* ===================================
   GLOBAL MOBILE IMPROVEMENTS
   =================================== */

@media (max-width: 968px) {
    /* Better touch targets */
    .btn {
        min-height: 48px;
        padding: 15px 35px;
    }
    
    /* Improved spacing */
    section {
        padding: 60px 0 !important;
    }
    
    /* Better card spacing */
    .overview-card,
    .value-card,
    .category-card {
        padding: 50px 25px !important;
    }
}

@media (max-width: 768px) {
    /* Typography improvements */
    h1 {
        font-size: 36px !important;
        line-height: 1.2 !important;
    }
    
    h2 {
        font-size: 28px !important;
        line-height: 1.3 !important;
    }
    
    h3 {
        font-size: 22px !important;
    }
    
    p {
        font-size: 16px !important;
        line-height: 1.7 !important;
    }
    
    /* Container padding */
    .container {
        padding: 0 20px !important;
    }
    
    /* Section spacing */
    section {
        padding: 50px 0 !important;
    }
    
    /* Card improvements */
    .card-inner-white,
    .value-inner-white,
    .category-inner-card {
        padding: 40px 25px !important;
    }
    
    /* Button improvements */
    .btn {
        width: 100%;
        max-width: 300px;
        margin: 10px auto;
        display: block;
    }
}

@media (max-width: 480px) {
    /* Even smaller devices */
    h1 {
        font-size: 28px !important;
    }
    
    h2 {
        font-size: 24px !important;
    }
    
    h3 {
        font-size: 20px !important;
    }
    
    p {
        font-size: 15px !important;
    }
    
    .container {
        padding: 0 15px !important;
    }
    
    section {
        padding: 40px 0 !important;
    }
}

/* ===================================
   HOMEPAGE MOBILE FIXES
   =================================== */

@media (max-width: 968px) {
    /* Hero section */
    .hero {
        min-height: 600px;
        padding: 100px 20px 40px;
    }
    
    .hero-title {
        font-size: 42px;
    }
    
    .chicken-image {
        display: none; /* Hide side chickens on mobile */
    }
    
    /* Product overview grid */
    .overview-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .overview-card {
        min-height: 300px;
    }
    
    /* Mission card content */
    .mission-card {
        padding: 40px 25px;
    }
    
    .mission-card h2 {
        font-size: 24px;
    }
    
    .mission-card p {
        font-size: 14px;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 36px;
    }
    
    .hero-subtitle,
    .hero-description {
        font-size: 16px;
    }
    
    /* Products slider */
    .products-slider {
        padding: 0 10px;
    }
    
    .product-card {
        flex: 0 0 280px;
    }
    
    /* Details section */
    .details-container {
        grid-template-columns: 1fr;
        padding: 0 20px;
    }
    
    .quality-badge-large {
        width: 120px;
        height: 120px;
        right: 20px;
        bottom: 20px;
    }
}

/* ===================================
   ABOUT PAGE MOBILE FIXES
   =================================== */

@media (max-width: 968px) {
    /* Hero */
    .about-hero {
        height: 60vh;
        min-height: 500px;
    }
    
    /* Mission/Vision */
    .mission-vision-grid {
        grid-template-columns: 1fr;
    }
    
    .mv-card {
        padding: 50px 25px;
    }
    
    .mv-card h2 {
        font-size: 32px;
    }
    
    .mv-image {
        min-height: 350px;
    }
    
    .central-badge {
        width: 120px;
        height: 120px;
        position: relative;
        margin: 30px auto;
        top: auto;
        left: auto;
        bottom: auto;
        transform: none;
    }
    
    /* Values */
    .values-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .value-card {
        min-height: auto;
        padding: 40px 25px;
    }
}

@media (max-width: 768px) {
    .our-story {
        padding: 50px 0;
    }
    
    .story-content p {
        font-size: 16px;
        margin-bottom: 20px;
    }
    
    .mv-card h2 {
        font-size: 28px;
    }
    
    .mv-card p {
        font-size: 15px;
    }
}

/* ===================================
   PRODUCTS PAGE MOBILE FIXES
   =================================== */

@media (max-width: 968px) {
    /* Hero */
    .products-hero {
        height: 60vh;
        min-height: 500px;
    }
    
    .products-hero-title {
        font-size: 48px;
    }
    
    /* Categories */
    .categories-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .category-card {
        min-height: 350px;
        padding: 50px 25px;
    }
    
    .category-inner-card {
        max-width: 100%;
        padding: 50px 30px;
    }
    
    .category-inner-card h2 {
        font-size: 28px;
    }
    
    .category-content h2 {
        font-size: 32px;
    }
    
    .category-content p {
        font-size: 15px;
    }
    
    /* Frozen section */
    .frozen-container {
        grid-template-columns: 1fr;
    }
    
    .frozen-text {
        padding: 50px 25px;
    }
    
    .frozen-text h2 {
        font-size: 32px;
    }
    
    .frozen-image {
        min-height: 300px;
    }
}

@media (max-width: 768px) {
    .products-hero-title {
        font-size: 38px;
    }
    
    .intro-content p,
    .quality-content p,
    .freshness-content p {
        font-size: 16px;
        margin-bottom: 20px;
    }
    
    .category-inner-card h2 {
        font-size: 24px;
    }
    
    .frozen-text h2 {
        font-size: 28px;
    }
}

/* ===================================
   POS PAGE MOBILE FIXES
   =================================== */

@media (max-width: 968px) {
    /* Hero */
    .pos-hero {
        height: 70vh;
        min-height: 500px;
    }
    
    .pos-hero-title {
        font-size: 72px;
        padding-bottom: 80px;
    }
    
    /* Intro box */
    .pos-intro-box {
        position: relative;
        transform: none;
        margin-top: 0;
        padding: 50px 25px;
    }
    
    .pos-intro-box p {
        font-size: 16px;
    }
    
    /* Map section */
    .map-section {
        padding: 60px 0;
    }
    
    .map-section .section-title {
        font-size: 28px;
        padding: 0 20px;
    }
    
    .map-pos {
        height: 400px;
    }
    
    /* Location slider */
    .slider-wrapper {
        padding: 0 50px;
    }
    
    .location-card {
        flex: 0 0 calc(100vw - 100px);
        max-width: 600px;
    }
    
    .location-header {
        padding: 40px 30px 20px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .location-hours {
        text-align: left;
    }
    
    .location-name h3 {
        font-size: 28px;
    }
    
    .location-body {
        padding: 0 30px 20px;
    }
    
    .location-body p {
        font-size: 15px;
    }
    
    .location-footer {
        padding: 20px 30px 40px;
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }
    
    .location-footer .btn {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .pos-hero-title {
        font-size: 56px;
    }
    
    .pos-intro-box {
        padding: 40px 20px;
    }
    
    .location-card {
        flex: 0 0 calc(100vw - 80px);
    }
    
    .location-name h3 {
        font-size: 24px;
    }
    
    .location-hours p {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .pos-hero {
        height: 60vh;
        min-height: 450px;
    }
    
    .pos-hero-title {
        font-size: 42px;
        padding-bottom: 60px;
    }
    
    .pos-intro-box {
        padding: 30px 15px;
    }
    
    .pos-intro-box p {
        font-size: 15px;
    }
    
    .map-section .section-title {
        font-size: 22px;
    }
    
    .slider-wrapper {
        padding: 0 40px;
    }
    
    .location-card {
        flex: 0 0 calc(100vw - 80px);
    }
    
    .location-header,
    .location-body,
    .location-footer {
        padding-left: 20px;
        padding-right: 20px;
    }
    
    .location-name h3 {
        font-size: 20px;
    }
    
    .location-slider-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

/* ===================================
   NAVIGATION MOBILE IMPROVEMENTS
   =================================== */

@media (max-width: 968px) {
    .navbar {
        padding: 12px 0;
    }
    
    .logo img {
        height: 40px;
    }
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 65px;
        flex-direction: column;
        background: var(--burgundy);
        width: 100%;
        padding: 30px 20px;
        transition: left 0.3s ease;
        gap: 15px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.3);
        max-height: calc(100vh - 65px);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-link {
        font-size: 18px;
        padding: 12px 0;
        display: block;
        text-align: center;
    }
    
    .nav-right {
        gap: 15px;
    }
    
    .social-icon {
        font-size: 20px;
    }
    
    .hamburger {
        display: flex;
        flex-direction: column;
        gap: 5px;
        cursor: pointer;
        z-index: 100;
    }
    
    .hamburger span {
        width: 25px;
        height: 3px;
        background: var(--yellow);
        transition: var(--transition);
        display: block;
    }
    
    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(7px, 7px);
    }
    
    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }
    
    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }
}

/* ===================================
   FOOTER MOBILE IMPROVEMENTS
   =================================== */

@media (max-width: 968px) {
    .footer-container {
        flex-direction: column;
        gap: 20px;
        text-align: center;
        padding: 20px 0;
    }
    
    .footer-social {
        order: -1;
        margin-bottom: 10px;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .copyright {
        font-size: 13px;
    }
}

/* ===================================
   GENERAL MOBILE OPTIMIZATIONS
   =================================== */

@media (max-width: 768px) {
    /* Ensure images don't overflow */
    img {
        max-width: 100%;
        height: auto;
    }
    
    /* Better button spacing */
    .btn + .btn {
        margin-top: 15px;
    }
    
    /* Improved card spacing */
    .product-card,
    .overview-card,
    .value-card,
    .category-card,
    .location-card {
        margin-bottom: 20px;
    }
    
    /* Better text readability */
    body {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
    
    /* Prevent text overflow */
    h1, h2, h3, h4, h5, h6 {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    /* Touch-friendly links */
    a {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }
    
    /* Scroll to top button */
    .scroll-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}

/* ===================================
   LANDSCAPE MOBILE FIX
   =================================== */

@media (max-width: 968px) and (orientation: landscape) {
    .hero,
    .about-hero,
    .products-hero,
    .pos-hero {
        min-height: 500px;
        height: auto;
        padding: 100px 20px 50px;
    }
}

/* ===================================
   TABLET OPTIMIZATIONS
   =================================== */

@media (min-width: 769px) and (max-width: 968px) {
    /* Better use of tablet space */
    .overview-grid {
        grid-template-columns: 1fr;
        max-width: 700px;
        margin: 0 auto;
    }
    
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
        max-width: 800px;
        margin: 0 auto;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
        max-width: 700px;
        margin: 0 auto;
    }
}

/* ===================================
   ACCESSIBILITY IMPROVEMENTS
   =================================== */

@media (max-width: 968px) {
    /* Better focus states for keyboard navigation */
    a:focus,
    button:focus,
    input:focus,
    select:focus,
    textarea:focus {
        outline: 3px solid var(--yellow);
        outline-offset: 2px;
    }
    
    /* Larger tap targets */
    .nav-link,
    .btn,
    .social-icon,
    .map-pin {
        min-width: 44px;
        min-height: 44px;
    }
}
