/* Custom Mobile Styles for Tractorbumper */

/* ========================================
   Hero Slider Mobile Improvements
   ======================================== */

/* Increase mobile slider height for better visual impact */
@media only screen and (max-width: 767px) {
    .hero-slide-item-two {
        height: 560px !important;
    }
    
    .hero-slide-content {
        padding: 0 20px;
        text-align: left !important;
    }
    
    .hero-slide-content .title {
        font-size: 48px !important;
        line-height: 1.1 !important;
        margin-bottom: 20px !important;
        font-weight: 800 !important;
        color: #ffffff !important;
        text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
        letter-spacing: 1px;
    }
    
    .hero-slide-content p {
        font-size: 16px !important;
        line-height: 1.4 !important;
        margin-bottom: 20px !important;
        max-width: 66%;
        color: #ffffff !important;
        text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.3);
        font-weight: 400;
    }
    
    .hero-slide-content .btn {
        font-size: 14px !important;
        padding: 14px 28px !important;
        white-space: normal;
        display: inline-block;
        border-radius: 50px;
        font-weight: 600;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    }
    
    /* Add semi-transparent overlay for better text readability */
    .hero-slide-bg::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.55));
        z-index: 1;
    }
    
    .hero-slide-content {
        z-index: 2;
        position: relative;
    }
}

/* Extra small mobile devices */
@media only screen and (max-width: 479px) {
    .hero-slide-item-two {
        height: 520px !important;
    }
    
    .hero-slide-content .title {
        font-size: 42px !important;
        margin-bottom: 18px !important;
    }
    
    .hero-slide-content p {
        font-size: 15px !important;
        margin-bottom: 25px !important;
        line-height: 1.5 !important;
    }
    
    .hero-slide-content .btn {
        font-size: 13px !important;
        padding: 12px 24px !important;
    }
}

/* Swiper pagination visibility on mobile */
@media only screen and (max-width: 767px) {
    .hero-slider .swiper-pagination {
        opacity: 1 !important;
        visibility: visible !important;
        bottom: 25px !important;
        z-index: 10;
    }
    
    .swiper-pagination-bullet {
        background: #fff;
        opacity: 0.6;
        width: 10px;
        height: 10px;
        margin: 0 6px !important;
        transition: all 0.3s ease;
    }
    
    .swiper-pagination-bullet-active {
        opacity: 1;
        background: #d4af37;
        transform: scale(1.3);
    }
}

/* ========================================
   Google Translate Mobile Improvements
   ======================================== */

/* Desktop header top visibility */
@media only screen and (min-width: 992px) {
    .header-top {
        display: block !important;
    }
}

/* Hide header top on mobile/tablet */
@media only screen and (max-width: 991px) {
    .header-top {
        display: none !important;
    }
}

/* Dropdown styling for mobile menu */
@media only screen and (max-width: 991px) {
    .offcanvas-lag-curr {
        background: #f8f9fa;
        padding: 20px;
        border-radius: 12px;
        margin-bottom: 25px;
    }
    
    .offcanvas-lag-curr .title {
        font-size: 18px;
        margin-bottom: 15px;
        color: #2e2e2e;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    
    .header-top-lan-curr-link {
        display: block;
        width: 100%;
    }
    
    .header-top-lan.dropdown {
        width: 100%;
    }
    
    .header-top-lan .dropdown-toggle,
    #languageButtonMobile {
        width: 100%;
        padding: 16px 20px;
        background: #fff;
        border: 2px solid #e0e0e0;
        border-radius: 10px;
        font-size: 16px;
        color: #2e2e2e;
        display: flex;
        justify-content: space-between;
        align-items: center;
        transition: all 0.3s ease;
        font-weight: 600;
        cursor: pointer;
    }
    
    .header-top-lan .dropdown-toggle:hover,
    #languageButtonMobile:hover {
        border-color: #d4af37;
        background: #fafafa;
        box-shadow: 0 2px 8px rgba(212, 175, 55, 0.1);
    }
    
    .header-top-lan .dropdown-toggle:focus,
    #languageButtonMobile:focus {
        outline: none;
        border-color: #d4af37;
        box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
    }
    
    .header-top-lan .dropdown-toggle i,
    #languageButtonMobile i {
        margin-left: auto;
        transition: transform 0.3s ease;
        color: #d4af37;
        font-size: 14px;
    }
    
    .header-top-lan.dropdown.show .dropdown-toggle i,
    .offcanvas-lag-curr .dropdown.show #languageButtonMobile i {
        transform: rotate(180deg);
    }
    
    .header-top-lan .dropdown-menu {
        width: 100%;
        max-height: 400px;
        overflow-y: auto;
        border-radius: 10px;
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
        margin-top: 8px !important;
        border: 1px solid #e0e0e0;
        padding: 8px 0;
    }
    
    .header-top-lan .dropdown-menu::-webkit-scrollbar {
        width: 6px;
    }
    
    .header-top-lan .dropdown-menu::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 10px;
    }
    
    .header-top-lan .dropdown-menu::-webkit-scrollbar-thumb {
        background: #d4af37;
        border-radius: 10px;
    }
    
    .header-top-lan .dropdown-item {
        padding: 14px 24px;
        font-size: 15px;
        transition: all 0.2s ease;
        color: #2e2e2e;
        font-weight: 500;
    }
    
    .header-top-lan .dropdown-item:hover,
    .header-top-lan .dropdown-item:focus {
        background: #f5f5f5;
        color: #d4af37;
        padding-left: 30px;
        transform: translateX(2px);
    }
    
    .header-top-lan .dropdown-item:active {
        background: #d4af37;
        color: #fff;
    }
    
    /* Current language highlight */
    #currentLanguage,
    #currentLanguageMobile {
        font-weight: 600;
        color: #2e2e2e;
        flex: 1;
        text-align: left;
    }
}

/* ========================================
   Additional Mobile Enhancements
   ======================================== */

/* Fixed Language Button - Bottom Left (Mobile Only) */
.fixed-lang-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 999;
}

.fixed-lang-toggle {
    min-width: 80px;
    height: 45px;
    background: #fff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid #e0e0e0;
    padding: 8px 12px;
}

.fixed-lang-toggle:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    background: #fafafa;
    border-color: #d4af37;
}

.fixed-lang-toggle:active,
.fixed-lang-toggle:focus {
    background: #fff;
    border-color: #d4af37;
    outline: none;
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.2);
}

.fixed-lang-toggle .flag-icon {
    font-size: 20px;
    line-height: 1;
    display: inline-block;
}

.fixed-lang-toggle .lang-code {
    font-size: 14px;
    font-weight: 600;
    color: #2e2e2e;
    line-height: 1;
}

.fixed-lang-toggle i {
    font-size: 12px;
    color: #666;
    margin-left: 2px;
}

/* Dropdown menu for fixed button */
.fixed-lang-btn .dropdown-menu {
    bottom: 55px !important;
    left: 0 !important;
    top: auto !important;
    transform: none !important;
    position: absolute !important;
    max-height: 350px;
    overflow-y: auto;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    border: 1px solid #e0e0e0;
    padding: 6px 0;
    min-width: 200px;
    width: auto;
    margin: 0 !important;
    display: none;
    list-style: none;
    background: #fff;
}

.fixed-lang-btn .dropdown-menu.show {
    display: block !important;
}

.fixed-lang-btn .dropdown-menu li {
    list-style: none;
    margin: 0;
    padding: 0;
}

.fixed-lang-btn .dropdown-item {
    padding: 10px 16px;
    font-size: 14px;
    transition: all 0.2s ease;
    color: #2e2e2e;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
    border-radius: 0;
    background: transparent;
    width: 100%;
    height: auto;
    margin: 0;
    line-height: 1.5;
    text-decoration: none;
}

.fixed-lang-btn .dropdown-item .flag-emoji {
    font-size: 18px;
    line-height: 1;
    min-width: 24px;
}

.fixed-lang-btn .dropdown-item:hover,
.fixed-lang-btn .dropdown-item:focus {
    background: #f5f5f5;
    color: #2e2e2e;
    text-decoration: none;
}

.fixed-lang-btn .dropdown-item:active {
    background: #e8e8e8;
    color: #2e2e2e;
}

/* Fix for Google Translate font tags */
.fixed-lang-btn .dropdown-item font,
.fixed-lang-btn .dropdown-item span {
    line-height: inherit;
    display: inline-block;
}

/* Mobile Language Button in Header - REMOVED */
.mobile-lang-trigger {
    display: none !important;
}

/* Flag icons in dropdowns */
.lang-select .flag-icon,
#currentFlagMobile {
    font-size: 20px;
    margin-right: 8px;
    display: inline-block;
}

/* Language button in mobile menu */
#languageButtonMobile {
    display: flex;
    align-items: center;
    gap: 10px;
}

#languageButtonMobile .flag-icon {
    font-size: 22px;
}

#currentLanguageMobile {
    flex: 1;
    text-align: left;
    margin-left: 5px;
}

/* Dropdown items with flags */
.dropdown-menu .lang-select {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Header top message - hide on very small screens */
@media only screen and (max-width: 575px) {
    .header-top-message {
        font-size: 12px !important;
        padding: 5px 0 !important;
    }
}

/* Improve mobile menu padding */
@media only screen and (max-width: 991px) {
    .mobile-menu-inner {
        padding: 30px 25px;
    }
    
    .offcanvas-lag-curr {
        margin-bottom: 30px;
    }
}

/* Better button sizing on mobile */
@media only screen and (max-width: 767px) {
    .btn-lg {
        font-size: 15px !important;
        padding: 13px 28px !important;
    }
    
    .btn-primary {
        background-color: #d4af37;
        border-color: #d4af37;
        font-weight: 600;
    }
    
    .btn-primary:hover,
    .btn-hover-dark:hover {
        background-color: #b8992f;
        border-color: #b8992f;
    }
}

/* Features section mobile improvements */
@media only screen and (max-width: 767px) {
    .feature {
        text-align: center;
        padding: 20px 15px;
    }
    
    .feature .content h5 {
        font-size: 16px;
        margin-top: 10px;
    }
    
    .feature .content p {
        font-size: 13px;
    }
}

/* Banner section mobile improvements */
@media only screen and (max-width: 767px) {
    .small-banner-content {
        padding: 15px;
    }
    
    .small-banner-content .sub-title {
        font-size: 14px;
    }
    
    .small-banner-content .title {
        font-size: 22px;
    }
}
