/* ========================================
   手机端响应式适配样式 - 前台页面
   适用于：首页、订单查询、工具下载、关于我们、支付页面
   ======================================== */

/* ========== 移动端导航菜单 ========== */
/* 汉堡菜单按钮 - 默认隐藏 */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 18px;
    cursor: pointer;
    padding: 5px;
}

.mobile-menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background-color: #333;
    transition: all 0.3s ease;
}

/* 移动端菜单遮罩 */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
}

.mobile-menu-overlay.active {
    display: block;
}

/* ========== 通用适配 (768px) ========== */
@media screen and (max-width: 768px) {
    /* 容器 */
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }

    /* 显示汉堡菜单按钮 */
    .mobile-menu-toggle {
        display: flex;
    }

    /* 导航栏布局调整 */
    .navbar {
        position: relative;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .brand-logo {
        display: flex;
        align-items: center;
    }

    /* 导航菜单 - 移动端变为侧边抽屉 */
    .site-menu-main {
        position: fixed !important;
        top: 0;
        right: -280px;
        width: 280px;
        height: 100vh;
        background: #fff;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
        padding: 60px 20px 20px;
        z-index: 999;
        transition: right 0.3s ease;
        overflow-y: auto;
        display: flex !important;
        flex-direction: column;
        align-items: flex-start;
        margin: 0;
    }

    [data-theme="dark"] .site-menu-main {
        background: #1e1e2d;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.3);
    }

    .site-menu-main.active {
        right: 0;
    }

    .site-menu-main li {
        margin: 0 0 15px 0;
        width: 100%;
    }

    .site-menu-main a {
        display: block;
        padding: 12px 15px;
        font-size: 16px;
        border-radius: 8px;
    }

    .site-menu-main a:hover,
    .site-menu-main a.active {
        background-color: #f5f5f5;
    }

    [data-theme="dark"] .site-menu-main a:hover,
    [data-theme="dark"] .site-menu-main a.active {
        background-color: #2d2d3a;
    }

    /* 关闭按钮 */
    .mobile-menu-close {
        display: block;
        position: absolute;
        top: 15px;
        right: 15px;
        width: 30px;
        height: 30px;
        cursor: pointer;
        text-align: center;
        line-height: 30px;
        font-size: 28px;
        color: #333;
    }

    [data-theme="dark"] .mobile-menu-close {
        color: #fff;
    }

    .brand-logo img {
        height: 40px !important;
        width: 40px !important;
    }

    /* 隐藏分隔线 */
    .vertical-divider {
        display: none;
    }

    /* 欢迎区域标题 */
    .welcome-content--l3__title span,
    .welcome-content--l3__sub-title span {
        font-size: 28px !important;
        line-height: 1.3 !important;
    }

    .welcome-content--l3__title p {
        line-height: 36px !important;
    }

    .welcome-content--l3__descriptions span {
        font-size: 14px !important;
    }

    /* 欢迎区域按钮 */
    .welcome-btn-group--l3 {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    .welcome-btn-group--l3 .custom-btn {
        margin-left: 0 !important;
        width: 100%;
        text-align: center;
        padding: 12px 20px;
        font-size: 14px;
    }

    /* 欢迎区域图片 */
    .welcome-image-group-wrapper--l3 {
        margin-top: 30px;
    }

    /* 卡片区域 */
    .containera {
        flex-direction: column;
        align-items: center;
        padding: 15px;
        gap: 15px;
    }

    .carda {
        width: 100% !important;
        max-width: 100%;
    }

    /* 圆角卡片 */
    .cardd {
        border-radius: 20px;
        padding: 15px;
    }

    .cardd .col-md-4 {
        margin-bottom: 20px;
    }

    /* 按钮行 */
    .row.mt-4 .col-md-4 {
        margin-bottom: 10px;
    }

    .row.mt-4 .btn-block {
        margin-bottom: 10px;
    }

    /* 特性列表 */
    .feature-list li {
        margin-bottom: 30px;
    }

    /* 页脚 */
    .footer-section .row {
        flex-direction: column;
    }

    .footer-section .col-lg-4,
    .footer-section .col-lg-8 {
        width: 100%;
        text-align: center;
    }

    .footer-brand-block--l3__text {
        text-align: center !important;
    }

    .footer-list-block {
        margin-bottom: 20px;
    }

    .footer {
        padding: 15px;
        font-size: 12px;
        text-align: center;
    }

    /* 区块间距 */
    section {
        padding: 30px 0;
    }

    .section-intro h2,
    .section-intro .display-4 {
        font-size: 24px !important;
    }

    .section-intro .lead {
        font-size: 14px;
    }

    /* 图文并排区域 */
    .bg-white .row {
        flex-direction: column;
    }

    .bg-white .col-md-6,
    .bg-white .col-lg-5,
    .bg-white .col-lg-4 {
        width: 100%;
        text-align: center;
        margin-bottom: 20px;
    }

    .bg-white .text-md-left {
        text-align: center !important;
    }

    /* 搜索头部 - 订单查询页 */
    .page-header {
        padding: 2rem 1rem !important;
    }

    .page-header .project-name {
        font-size: 1.5rem !important;
    }

    .page-header .col-lg-6 {
        width: 100%;
        padding: 0 10px;
    }

    .page-header .input-group {
        flex-direction: column;
    }

    .page-header .input-group .form-control {
        border-radius: 5px !important;
        margin-bottom: 10px;
    }

    .page-header .input-group-append {
        width: 100%;
    }

    .page-header .input-group-append .btn {
        width: 100%;
        border-radius: 5px !important;
    }

    /* 订单详情 */
    .clearfix .float-left,
    .clearfix .float-right {
        float: none !important;
        text-align: center;
    }

    .float-sm-right {
        float: none !important;
    }

    /* 表格响应式 */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .table {
        font-size: 12px;
    }

    .table th,
    .table td {
        padding: 8px 5px;
        white-space: nowrap;
    }

    /* 工具卡片 */
    .card .media {
        flex-direction: column;
        text-align: center;
    }

    .card .avatar {
        margin-bottom: 15px;
    }

    .card .media-body {
        margin-left: 0 !important;
    }

    .card .media-body h5 {
        font-size: 14px;
    }

    .card .media-body small {
        font-size: 12px;
    }

    .card-footer {
        flex-direction: column;
        gap: 10px;
    }

    .card-footer > div:first-child {
        text-align: center;
    }

    .card-footer .badge {
        display: inline-block;
        margin-bottom: 5px;
    }

    /* 关于我们页面 */
    section[style*="margin-top: 100px"] {
        margin-top: 80px !important;
    }

    section .col-md-10 {
        padding: 0 15px;
    }

    section article {
        font-size: 14px;
        line-height: 1.8;
    }

    section article ul {
        padding-left: 20px;
    }

    section article li {
        margin-bottom: 8px;
    }

    /* 支付页面 - 用户信息卡片 */
    .card-body.profile-user-box .media {
        flex-direction: column;
        text-align: center;
    }

    .card-body.profile-user-box .media .float-left {
        float: none !important;
        margin: 0 auto 15px !important;
    }

    .card-body.profile-user-box .media .float-left img {
        height: 80px !important;
        width: 80px !important;
    }

    .card-body.profile-user-box .media-body {
        text-align: center;
    }

    .card-body.profile-user-box .media-body h4 {
        font-size: 18px;
    }

    .card-body.profile-user-box .col-sm-8 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    /* 商品选择卡片 */
    .inpit .li > div[name][value],
    .inpit .li > div.add {
        float: none !important;
        width: 100% !important;
        margin: 0 0 15px 0;
        padding: 20px;
        box-sizing: border-box;
    }

    .inpit .li > div[name][value] h2 {
        font-size: 16px;
        margin-bottom: 8px;
    }

    .inpit .li > div[name][value] p {
        font-size: 14px;
        margin: 5px 0;
    }

    /* 价格区域 */
    .col-sm-6 .float-right {
        float: none !important;
        text-align: center;
        margin-top: 15px;
    }

    .col-sm-6 .clearfix.pt-3 {
        text-align: center;
    }

    #money_h3 {
        font-size: 24px;
        text-align: center;
    }

    /* 支付按钮 */
    .d-print-none .text-right {
        text-align: center !important;
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .d-print-none .text-right .btn {
        width: 100%;
        padding: 12px 20px;
        font-size: 16px;
        margin: 0 !important;
    }

    /* 卡片内边距 */
    .card-body {
        padding: 15px;
    }
}

/* ========== 超小屏幕适配 (480px) ========== */
@media screen and (max-width: 480px) {
    /* 标题更小 */
    .welcome-content--l3__title span,
    .welcome-content--l3__sub-title span {
        font-size: 22px !important;
    }

    .section-intro h2,
    .section-intro .display-4 {
        font-size: 20px !important;
    }

    /* 卡片 */
    .carda {
        padding: 12px;
    }

    .card-icona {
        font-size: 28px;
    }

    .card-titlea h2 {
        font-size: 16px;
    }

    .card-descriptiona {
        font-size: 12px;
    }

    /* 支付页面 */
    .card-body.profile-user-box .media .float-left img {
        height: 60px !important;
        width: 60px !important;
    }

    .card-body.profile-user-box .media-body h4 {
        font-size: 16px;
    }

    .card-body.profile-user-box .font-13 {
        font-size: 12px;
    }

    .inpit .li > div[name][value] {
        padding: 15px;
    }

    .inpit .li > div[name][value] h2 {
        font-size: 14px;
    }

    #money_h3 {
        font-size: 20px;
    }

    .d-print-none .text-right .btn {
        padding: 10px 15px;
        font-size: 14px;
    }

    /* 表格 */
    .table {
        font-size: 11px;
    }

    .table th,
    .table td {
        padding: 6px 4px;
    }
}
