/*
* 庐山市宏泽石业 - 响应式样式
* 适配手机、平板、电脑
*/

/* 平板设备 */
@media screen and (max-width: 992px) {
    .header-main .container {
        flex-wrap: wrap;
    }

    .logo {
        width: 100%;
        text-align: center;
        margin-bottom: 15px;
    }

    .main-nav {
        order: 3;
        margin: 15px 0 0;
        width: 100%;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        width: 100%;
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu > li {
        margin: 0;
        border-top: 1px solid #eee;
    }

    .nav-menu > li > a {
        padding: 15px;
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        padding-left: 20px;
        display: none;
    }

    .has-dropdown.open .dropdown-menu {
        display: block;
    }

    .hero-slider {
        height: 400px;
    }

    .slide-content h2 {
        font-size: 32px;
    }

    .slide-content p {
        font-size: 16px;
    }

    .about-content {
        flex-direction: column;
    }

    .about-image,
    .about-text {
        width: 100%;
    }

    .case-item-large a {
        flex-direction: column;
    }

    .case-item-large .case-image,
    .case-item-large .case-info {
        width: 100%;
    }

    .news-item-large a {
        flex-direction: column;
    }

    .news-item-large .news-date {
        border-right: none;
        border-bottom: 2px solid #006633;
        margin-bottom: 20px;
        padding-bottom: 10px;
    }

    .contact-form-map {
        flex-direction: column;
    }

    .timeline:before {
        left: 20px;
    }

    .timeline-item,
    .timeline-item:nth-child(even) {
        justify-content: flex-start;
        padding-left: 50px;
    }

    .timeline-item .desc {
        width: 100%;
    }

    .timeline-item:before {
        left: 20px;
    }
}

/* 手机设备 */
@media screen and (max-width: 768px) {
    .header-top {
        display: none;
    }

    .header-placeholder {
        height: 80px;
    }

    .hero-slider {
        height: 350px;
    }

    .slide-content h2 {
        font-size: 24px;
    }

    .section-header h2 {
        font-size: 28px;
    }

    section {
        padding: 50px 0;
    }

    .product-categories {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
    }

    .category-image {
        height: 150px;
    }

    .cases-grid {
        grid-template-columns: 1fr;
    }

    .news-grid {
        grid-template-columns: 1fr;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .cta-buttons .btn {
        width: 100%;
        max-width: 300px;
        margin-bottom: 10px;
    }

    .page-banner h1 {
        font-size: 28px;
    }

    .category-tabs li {
        margin: 3px;
    }

    .category-tabs li a {
        padding: 5px 12px;
        font-size: 14px;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }

    .about-detail {
        flex-direction: column;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-contact i {
        width: auto;
    }

    .back-to-top {
        bottom: 15px;
        right: 15px;
    }
}

/* 小手机 */
@media screen and (max-width: 480px) {
    .slide-content h2 {
        font-size: 20px;
    }

    .slide-content p {
        font-size: 14px;
    }

    .btn {
        padding: 10px 20px;
    }

    .btn-large {
        padding: 12px 30px;
    }

    .product-categories {
        grid-template-columns: 1fr;
    }

    .news-item a {
        flex-direction: column;
    }

    .news-date {
        width: 100%;
        margin-bottom: 15px;
        border-bottom: 1px solid #eee;
    }
}

/* ===== 移动端面包屑导航完整修复 ===== */

/* 移动端样式覆盖 */
@media screen and (max-width: 992px) {

    /* 修复头部导航布局 */
    .header-main .container {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        position: relative;
    }

    /* Logo 区域 - 放在最左边 */
    .logo {
        width: auto;
        margin: 0;
        order: 1;
    }

    .logo h1 {
        font-size: 18px;
        margin-bottom: 2px;
    }

    .logo span {
        font-size: 10px;
    }

    /* 移动菜单按钮 - 放在中间 */
    .mobile-menu-toggle {
        display: flex;
        order: 2;
        margin: 0 5px;
    }

    /* 搜索按钮 - 放在最右边，独立一行 */
    .header-search {
        order: 3;
        position: relative;
        width: auto;
        margin-left: auto;
    }

    .search-toggle {
        padding: 5px 8px;
    }

    /* 搜索表单下拉位置调整 */
    .search-form {
        position: absolute;
        top: 40px;
        right: 0;
        width: 250px;
        z-index: 1000;
    }

    /* 导航菜单 - 占满整个宽度 */
    .main-nav {
        order: 4;
        width: 100%;
        margin: 10px 0 0;
        flex: none;
    }

    /* ===== 页面横幅修复 ===== */
    .page-banner {
        position: relative;
        padding: 100px 15px 60px !important;
        min-height: 180px;
        z-index: 1;
    }

    .page-banner .container {
        position: relative;
        z-index: 10;
        padding: 0;
        width: 100%;
    }

    /* 标题区域 */
    .page-banner h1 {
        font-size: 24px;
        margin-bottom: 10px;
        line-height: 1.3;
        word-break: break-word;
        padding-right: 0; /* 移除之前的 padding */
        position: relative;
        z-index: 15;
    }

    /* 面包屑导航 - 确保可点击 */
    .page-banner .breadcrumb {
        display: inline-block;
        position: relative;
        z-index: 20;
        background-color: rgba(0,0,0,0.3);
        backdrop-filter: blur(5px);
        -webkit-backdrop-filter: blur(5px);
        padding: 6px 15px;
        border-radius: 30px;
        font-size: 13px;
        pointer-events: auto; /* 确保可以点击 */
        cursor: pointer;
    }

    .page-banner .breadcrumb a {
        color: #fff;
        text-decoration: none;
        pointer-events: auto;
        display: inline-block;
        padding: 2px 0;
    }

    .page-banner .breadcrumb a:hover {
        text-decoration: underline;
    }

    .page-banner .breadcrumb span {
        color: #fff;
        opacity: 0.9;
    }

    /* 返回首页按钮区域 */
    .page-nav-section {
        position: relative;
        z-index: 15;
        padding: 12px 0;
        background-color: #f8f9fa;
    }

    .page-nav-bar {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .back-to-home-btn {
        width: auto;
        min-width: 120px;
        padding: 8px 16px;
        font-size: 14px;
        pointer-events: auto;
        z-index: 20;
    }

    .current-location {
        width: 100%;
        font-size: 13px;
        padding: 6px 12px;
        white-space: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        background: white;
        border-radius: 30px;
        pointer-events: auto;
    }

    .current-location a {
        pointer-events: auto;
        color: #006633;
    }

    /* 确保所有链接可点击 */
    a, button, .btn, .breadcrumb a, .back-to-home-btn, .current-location a {
        pointer-events: auto !important;
        cursor: pointer !important;
        z-index: 100;
    }
}

/* 小屏幕手机优化 */
@media screen and (max-width: 480px) {
    .page-banner {
        padding: 90px 12px 50px !important;
    }

    .page-banner h1 {
        font-size: 20px;
    }

    .page-banner .breadcrumb {
        font-size: 12px;
        padding: 5px 12px;
    }

    .back-to-home-btn {
        width: 100%;
        justify-content: center;
    }

    .logo h1 {
        font-size: 16px;
    }

    .logo span {
        font-size: 9px;
    }
}

/* 确保没有元素遮挡链接 */
.header-search .search-form {
    z-index: 1000;
}

.header-search .search-toggle {
    z-index: 50;
}

/* 强制所有链接可点击 */
a, button, [onclick], .btn, .breadcrumb a, .back-to-home-btn {
    pointer-events: auto !important;
    position: relative;
    z-index: 999 !important;
}