/* 南宁宠物网 手机版初始适配（基于 04-导出 390×844 设计稿） */
.mobile-header,
.mobile-tabbar,
.m-home-cats,
.m-info-grid {
    display: none;
}

.mobile-back {
    display: none;
}

.m-card-price,
.m-member-home,
.m-myinfos,
.m-messages,
.m-search-history,
.m-hot-search,
.m-publish-head,
.m-publish-steps,
.m-filter-btn,
.m-filter-sheet,
.m-filter-mask,
.m-detail-desc,
.m-related-grid,
.m-cat-select,
.m-cat-picker,
.m-cat-mask {
    display: none;
}

@media (max-width: 768px) {
    :root {
        --m-bg: #F0EBE4;
        --m-surface: #FBF8F4;
        --m-surface2: #F5EFE7;
        --m-ink: #3B3630;
        --m-ink2: #736A60;
        --m-ink3: #A2988C;
        --m-line: #E7DFD4;
        --m-accent: #C07A55;
        --m-accent-s: #F4E4D8;
        --m-sage: #87977E;
        --m-danger: #B4655B;
        --m-shadow: 0 6px 20px rgba(88, 70, 52, .07);
        --brand: #C07A55;
        --line: #E7DFD4;
    }

    html {
        background: var(--m-bg);
        -webkit-text-size-adjust: 100%;
        overflow-x: hidden;
    }

    body {
        margin: 0;
        background: var(--m-bg);
        color: var(--m-ink);
        font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
        padding-bottom: calc(68px + env(safe-area-inset-bottom));
        -webkit-font-smoothing: antialiased;
        overflow-x: hidden;
        max-width: 100%;
    }

    body.mobile-no-tabbar {
        padding-bottom: 0;
    }

    body.mobile-no-tabbar .mobile-tabbar {
        display: none;
    }

    body.mobile-auth .mobile-search,
    body.mobile-publish .mobile-search,
    body.mobile-detail .mobile-search,
    body.mobile-member .mobile-search,
    body.mobile-help .mobile-search {
        display: none;
    }

    a { color: inherit; }

    .site-header,
    .site-footer {
        display: none !important;
    }

    .site-main {
        margin: 0;
        padding: 0;
    }

    .container {
        width: 100%;
        max-width: 100%;
        padding-left: 14px;
        padding-right: 14px;
    }

    /* ---------- 手机头部 ---------- */
    .mobile-header {
        display: block;
        position: sticky;
        top: 0;
        z-index: 90;
        background: rgba(251, 248, 244, .97);
        backdrop-filter: blur(12px);
        border-bottom: 1px solid var(--m-line);
    }

    .mobile-header-inner {
        display: flex;
        align-items: center;
        gap: 9px;
        padding: 11px 14px 7px;
    }

    body.mobile-has-back .mobile-back {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 28px;
        height: 30px;
        margin-right: -3px;
        border-radius: 9px;
        background: #F7F1EA;
        color: var(--m-ink);
        font-size: 25px;
        line-height: 1;
        text-decoration: none;
        flex: none;
    }

    .mobile-brand {
        display: flex;
        align-items: center;
        gap: 8px;
        min-width: 0;
        text-decoration: none;
        color: var(--m-ink);
    }

    .mobile-brand .logo {
        width: 34px;
        height: 34px;
        border-radius: 11px;
        background: var(--m-accent);
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 18px;
        box-shadow: 0 3px 10px rgba(192, 122, 85, .28);
        flex: none;
    }

    .mobile-brand b {
        display: block;
        font-size: 16px;
        line-height: 1.15;
        letter-spacing: .2px;
        white-space: nowrap;
    }

    .mobile-brand small {
        display: block;
        font-size: 9.5px;
        color: var(--m-ink2);
        letter-spacing: .4px;
        margin-top: 2px;
    }

    .mobile-loc {
        margin-left: auto;
        display: flex;
        align-items: center;
        gap: 3px;
        font-size: 11.5px;
        color: var(--m-ink2);
        background: #F7F1EA;
        padding: 6px 9px;
        border-radius: 16px;
        text-decoration: none;
        flex: none;
    }

    .mobile-post {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        background: var(--m-ink);
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 21px;
        line-height: 1;
        text-decoration: none;
        flex: none;
    }

    .mobile-search {
        display: flex;
        align-items: center;
        gap: 8px;
        margin: 0 14px 10px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 13px;
        padding: 8px 9px;
        box-shadow: var(--m-shadow);
    }

    .mobile-search svg {
        flex: none;
        color: var(--m-ink3);
    }

    .mobile-search input {
        flex: 1;
        min-width: 0;
        border: 0;
        outline: 0;
        background: transparent;
        color: var(--m-ink);
        font-size: 16px;
        padding: 2px 0;
        -webkit-appearance: none;
        appearance: none;
    }

    .mobile-search input::placeholder {
        color: var(--m-ink3);
    }

    .mobile-search button {
        border: 0;
        background: var(--m-accent);
        color: #fff;
        font-size: 11.5px;
        padding: 5px 12px;
        border-radius: 9px;
        flex: none;
    }

    /* ---------- 底部导航 ---------- */
    .mobile-tabbar {
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 100;
        background: rgba(251, 248, 244, .98);
        backdrop-filter: blur(12px);
        border-top: 1px solid var(--m-line);
        padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
        box-shadow: 0 -6px 22px rgba(88, 70, 52, .06);
    }

    .mobile-tabbar .m-tab {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 2px;
        text-decoration: none;
        color: #8B8176;
        font-size: 10px;
        line-height: 1.2;
        padding: 3px 0;
        min-width: 0;
    }

    .mobile-tabbar .m-tab svg {
        width: 21px;
        height: 21px;
        stroke: currentColor;
        fill: none;
        stroke-width: 1.8;
        stroke-linecap: round;
        stroke-linejoin: round;
    }

    .mobile-tabbar .m-tab.on {
        color: var(--m-accent);
        font-weight: 600;
    }

    .mobile-tabbar .m-tab.pub {
        position: relative;
        color: var(--m-accent);
    }

    .mobile-tabbar .m-tab.pub .pubbtn {
        width: 42px;
        height: 42px;
        margin-top: -17px;
        border-radius: 50%;
        background: var(--m-accent);
        color: #fff;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 5px 14px rgba(192, 122, 85, .35);
        border: 3px solid var(--m-surface);
    }

    .mobile-tabbar .m-tab.pub .pubbtn svg {
        width: 23px;
        height: 23px;
        stroke: #fff;
    }

    /* ---------- 公告 / 面包屑 ---------- */
    .site-notice {
        background: var(--m-accent-s);
        color: #8A5C42;
        font-size: 11.5px;
        padding: 8px 14px;
        border: 0;
    }

    .site-notice .container {
        padding: 0;
        display: flex;
        gap: 8px;
        overflow: hidden;
    }

    .site-notice-label {
        flex: none;
        background: var(--m-accent);
        color: #fff;
        border-radius: 4px;
        padding: 1px 5px;
        font-size: 10px;
    }

    .breadcrumb {
        display: none;
    }

    /* ---------- 首页 ---------- */
    .m-home-cats {
        display: block;
        margin: 10px 14px 2px;
        padding: 12px 10px 10px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 17px;
        box-shadow: var(--m-shadow);
    }

    .m-cat-grid {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 12px 4px;
    }

    .m-cat {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
        font-size: 10.5px;
        color: var(--m-ink2);
        text-decoration: none;
        min-width: 0;
        text-align: center;
    }

    .m-cat > span:last-child {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .m-cat-i {
        width: 44px;
        height: 44px;
        border-radius: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #F6E7DB;
        color: #B87A55;
        font-size: 16px;
        font-weight: 700;
    }

    .m-cat:nth-child(4n+2) .m-cat-i {
        background: #E9EEE4;
        color: #7C9072;
    }

    .m-cat:nth-child(4n+3) .m-cat-i {
        background: #F1E6E2;
        color: #B4837A;
    }

    .m-cat:nth-child(4n) .m-cat-i {
        background: #EDE8F0;
        color: #8C7E9B;
    }

    .m-quick {
        display: flex;
        gap: 6px;
        overflow-x: auto;
        padding-top: 11px;
        scrollbar-width: none;
    }

    .m-quick::-webkit-scrollbar {
        display: none;
    }

    .m-quick a {
        flex: none;
        font-size: 10.5px;
        color: var(--m-ink2);
        background: #F7F1EA;
        border: 1px solid var(--m-line);
        border-radius: 13px;
        padding: 5px 10px;
        text-decoration: none;
    }

    .nnp-section {
        margin: 0;
        padding: 14px 0 2px;
    }

    .nnp-sec-head {
        padding: 0 14px;
        margin-bottom: 10px;
    }

    .nnp-sec-title {
        font-size: 17px;
        font-weight: 700;
    }

    .nnp-sec-more {
        font-size: 11.5px;
        color: var(--m-ink2);
    }

    .nnp-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 11px;
        padding: 0 14px;
    }

    .nnp-card {
        border: 1px solid var(--m-line);
        border-radius: 15px;
        box-shadow: var(--m-shadow);
        background: var(--m-surface);
    }

    .nnp-card-img {
        padding-top: 100%;
        border-radius: 14px 14px 0 0;
    }

    .nnp-card-body {
        padding: 8px 9px 10px;
        min-width: 0;
    }

    .nnp-card-badge {
        font-size: 9.5px;
        padding: 2px 6px;
        border-radius: 6px;
        background: var(--m-accent-s);
        color: #9A6548;
    }

    .nnp-card-title {
        font-size: 12.5px;
        line-height: 1.45;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        margin-top: 4px;
    }

    .nnp-card-price {
        font-size: 15px;
        color: var(--m-accent);
        font-weight: 700;
        margin-top: 4px;
    }

    .m-card-price {
        display: block;
        font-size: 15px;
        color: var(--m-accent);
        font-weight: 700;
        margin-top: 4px;
    }

    .nnp-top-badge {
        font-size: 9px;
        padding: 2px 5px;
        border-radius: 5px;
        background: var(--m-accent);
    }

    .nnp-twocol {
        display: block;
        padding: 0 14px;
    }

    .nnp-col {
        margin-bottom: 14px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 15px;
        padding: 12px;
        box-shadow: var(--m-shadow);
    }

    .nnp-col-head {
        margin-bottom: 6px;
    }

    .nnp-col-title {
        font-size: 15px;
    }

    .nnp-list-item {
        padding: 8px 0;
        font-size: 12.5px;
    }

    .nnp-cta {
        border-radius: 18px;
        padding: 20px 16px;
        background: linear-gradient(135deg, #EAD8C8, #F6EEE5);
    }

    .nnp-cta-title {
        font-size: 20px;
    }

    .nnp-cta-sub {
        font-size: 12px;
        line-height: 1.7;
    }

    .nnp-cta-btns {
        display: flex;
        gap: 8px;
    }

    .nnp-cta-btn {
        flex: 1;
        text-align: center;
        padding: 10px;
        border-radius: 12px;
        font-size: 12.5px;
    }

    .nnp-cloud-wrap {
        margin: 0 14px;
        border-radius: 16px;
        padding: 12px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
    }

    .nnp-cloud-title {
        font-size: 15px;
        margin-bottom: 8px;
    }

    .nnp-cloud-row {
        gap: 6px;
        margin-bottom: 6px;
    }

    .nnp-cloud-row a {
        font-size: 11.5px;
        background: #F5EFE7;
        color: var(--m-ink2);
        border-radius: 10px;
        padding: 4px 8px;
    }

    .nnp-cloud-main {
        background: var(--m-accent-s) !important;
        color: #9A6548 !important;
    }

    /* ---------- 通用信息卡 / 分类页 ---------- */
    .section-head {
        padding: 0 14px;
        margin: 14px 0 8px;
        align-items: center;
    }

    .section-head h2 {
        font-size: 21px;
        margin: 0;
    }

    .section-head > a {
        font-size: 11.5px;
        background: var(--m-accent-s);
        color: #9A6548;
        padding: 6px 10px;
        border-radius: 10px;
        white-space: nowrap;
    }

    .category-desc {
        padding: 0 14px;
        font-size: 11.5px;
        line-height: 1.65;
        color: var(--m-ink2);
        margin: 0 0 8px;
    }

    .filter-bar {
        display: flex;
        gap: 7px;
        align-items: center;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding: 7px 14px;
        margin: 0;
        background: transparent;
        border: 0;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .filter-bar::-webkit-scrollbar {
        display: none;
    }

    .filter-bar > a {
        flex: none;
        font-size: 11.5px;
        padding: 6px 11px;
        border-radius: 14px;
        background: #F7F1EA;
        border: 1px solid var(--m-line);
        color: var(--m-ink2);
        white-space: nowrap;
    }

    .filter-bar > a.active {
        background: var(--m-accent);
        color: #fff;
        border-color: var(--m-accent);
    }

    .filter-bar .form-select,
    .filter-bar .form-control {
        flex: none;
        width: auto !important;
        min-width: 96px;
        height: 34px;
        font-size: 11.5px;
        padding: 5px 8px;
        border-radius: 10px;
        background-color: var(--m-surface);
    }

    .filter-bar > span {
        display: none;
    }

    .filter-bar .btn-brand {
        flex: none;
        height: 34px;
        padding: 0 12px;
        font-size: 11.5px;
        border-radius: 10px;
    }

    form.filter-bar {
        display: none;
    }

    .m-filter-btn {
        display: flex;
        align-items: center;
        gap: 6px;
        margin: 2px 14px 4px;
        padding: 9px 12px;
        width: calc(100% - 28px);
        border: 1px solid var(--m-line);
        border-radius: 12px;
        background: var(--m-surface);
        color: var(--m-ink);
        font-size: 12px;
        text-align: left;
    }

    .m-filter-btn:before {
        content: "☰";
        color: var(--m-accent);
        font-size: 14px;
    }

    .m-filter-btn span {
        margin-left: auto;
        color: var(--m-ink3);
        font-size: 10px;
    }

    .m-filter-mask {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(40, 33, 27, .34);
        opacity: 0;
        pointer-events: none;
        transition: opacity .2s;
        z-index: 110;
    }

    .m-filter-sheet {
        display: block;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 111;
        background: var(--m-surface);
        border-radius: 20px 20px 0 0;
        padding: 14px 16px calc(16px + env(safe-area-inset-bottom));
        transform: translateY(105%);
        transition: transform .24s ease;
        max-height: 82vh;
        overflow-y: auto;
    }

    body.m-filter-open .m-filter-mask {
        opacity: 1;
        pointer-events: auto;
    }

    body.m-filter-open .m-filter-sheet {
        transform: translateY(0);
    }

    .m-sheet-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 12px;
    }

    .m-sheet-head b {
        font-size: 17px;
    }

    .m-sheet-head button {
        border: 0;
        background: #F5EFE7;
        border-radius: 50%;
        width: 30px;
        height: 30px;
        font-size: 20px;
        color: var(--m-ink2);
    }

    .m-filter-sheet .form-label {
        font-size: 11.5px;
        margin-bottom: 5px;
    }

    .m-filter-sheet .form-select,
    .m-filter-sheet .form-control {
        font-size: 14px;
        min-height: 40px;
    }

    .m-sheet-actions {
        display: flex;
        gap: 8px;
        margin-top: 15px;
    }

    .m-sheet-actions a {
        flex: 0 0 90px;
        border: 1px solid var(--m-line);
        border-radius: 11px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 12px;
        color: var(--m-ink2);
        text-decoration: none;
    }

    .m-sheet-actions .btn-brand {
        flex: 1;
        min-height: 42px;
    }

    .info-grid {
        grid-template-columns: 1fr;
        gap: 9px;
        padding: 0 14px;
        margin: 8px 0 14px;
    }

    .info-list {
        display: none;
    }

    .m-info-grid {
        display: flex;
        flex-direction: column;
        gap: 9px;
        padding: 8px 14px 14px;
    }

    .m-info-card {
        display: flex;
        gap: 10px;
        padding: 8px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 15px;
        box-shadow: var(--m-shadow);
        text-decoration: none;
        color: var(--m-ink);
        min-height: 106px;
    }

    .m-info-thumb {
        flex: 0 0 100px;
        width: 100px;
        height: 100px;
        border-radius: 11px;
        overflow: hidden;
        background: #E9E1D8;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #A29689;
        font-size: 13px;
    }

    .m-info-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .m-info-body {
        min-width: 0;
        padding: 3px 2px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 4px;
    }

    .m-info-cat {
        width: fit-content;
        font-size: 9.5px;
        padding: 2px 6px;
        border-radius: 6px;
        background: var(--m-accent-s);
        color: #9A6548;
    }

    .m-info-body b {
        font-size: 13px;
        line-height: 1.45;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .m-info-meta {
        display: flex;
        align-items: center;
        gap: 8px;
        font-size: 10.5px;
        color: var(--m-ink2);
    }

    .m-info-meta em {
        font-style: normal;
        font-size: 15px;
        font-weight: 700;
        color: var(--m-accent);
    }

    /* ---------- 全部分类 ---------- */
    .m-cat-groups {
        padding: 4px 14px 12px;
    }

    .m-cat-group {
        margin-bottom: 10px;
        padding: 13px 12px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 16px;
        box-shadow: var(--m-shadow);
    }

    .m-cat-group h3 {
        margin: 0 0 10px;
        font-size: 15px;
    }

    .m-cat-group h3 a {
        color: var(--m-ink);
        text-decoration: none;
    }

    .m-cat-subs {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 10px 4px;
    }

    .m-cat-sub {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
        color: var(--m-ink2);
        font-size: 10.5px;
        text-decoration: none;
        min-width: 0;
        text-align: center;
    }

    .m-cat-sub > span:last-child {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .m-cat-sub-i {
        width: 40px;
        height: 40px;
        border-radius: 13px;
        background: #F6E7DB;
        color: #B87A55;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: 700;
        font-size: 14px;
    }

    .m-cat-sub:nth-child(4n+2) .m-cat-sub-i {
        background: #E9EEE4;
        color: #7C9072;
    }

    .m-cat-sub:nth-child(4n+3) .m-cat-sub-i {
        background: #F1E6E2;
        color: #B4837A;
    }

    .m-cat-sub:nth-child(4n) .m-cat-sub-i {
        background: #EDE8F0;
        color: #8C7E9B;
    }

    .m-cat-foot {
        display: flex;
        gap: 8px;
        padding: 0 14px 14px;
    }

    .m-cat-foot a {
        flex: 1;
        text-align: center;
        font-size: 12px;
        padding: 11px;
        border-radius: 12px;
        text-decoration: none;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        color: var(--m-ink2);
    }

    .m-cat-foot a:first-child {
        background: var(--m-accent);
        border-color: var(--m-accent);
        color: #fff;
    }

    .info-card {
        display: flex;
        align-items: stretch;
        border: 1px solid var(--m-line);
        border-radius: 15px;
        background: var(--m-surface);
        box-shadow: var(--m-shadow);
        overflow: hidden;
        min-height: 112px;
    }

    .info-card .thumb {
        flex: 0 0 112px;
        width: 112px;
        aspect-ratio: 1;
        border-radius: 14px 0 0 14px;
        margin: 0;
    }

    .info-card .body {
        padding: 9px 10px;
        min-width: 0;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .info-card .body h3 {
        font-size: 13px;
        line-height: 1.45;
        margin: 4px 0 6px;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .info-card .badge-cat {
        font-size: 9.5px;
        padding: 2px 6px;
        border-radius: 6px;
        background: var(--m-accent-s);
        color: #9A6548;
        width: fit-content;
    }

    .info-card .meta {
        gap: 8px;
        font-size: 10.5px;
        color: var(--m-ink2);
    }

    .info-card .price {
        font-size: 15px;
        color: var(--m-accent);
    }

    .empty {
        margin: 18px 14px;
        padding: 24px 14px;
        border: 1px dashed var(--m-line);
        border-radius: 15px;
        background: var(--m-surface);
        font-size: 12px;
    }

    .pagination {
        padding: 0 14px 14px;
    }

    /* ---------- 详情页 ---------- */
    .detail-wrap {
        display: flex;
        flex-direction: column;
        gap: 10px;
        margin: 0;
        padding: 0 14px;
    }

    .detail-wrap,
    .detail-right,
    .detail-right > .panel,
    .detail-left > * {
        min-width: 0;
        max-width: 100%;
    }

    .detail-left,
    .detail-right {
        gap: 10px;
    }

    /* 手机端顺序：图片 → 标题/属性/联系 → 描述 */
    .detail-left {
        display: contents;
    }

    .detail-left > .panel:first-child {
        order: 1;
    }

    .detail-right {
        order: 2;
    }

    .detail-left > .breed-intro {
        order: 3;
        display: none !important;
    }

    .detail-left > .detail-main {
        order: 4;
        display: none !important;
    }

    .m-detail-desc {
        display: block;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px solid #F0E9DF;
    }

    .m-detail-desc h3 {
        font-size: 15px;
        margin: 14px 0 7px;
        font-weight: 700;
    }

    .m-detail-desc h3:first-child {
        margin-top: 0;
    }

    .m-detail-desc .description {
        font-size: 13px;
        line-height: 1.8;
        color: var(--m-ink2);
        overflow-wrap: anywhere;
    }

    .m-detail-desc .description img,
    .m-detail-desc .description iframe,
    .m-detail-desc .description video {
        max-width: 100%;
        height: auto;
    }

    .detail-related .info-grid {
        display: none;
    }

    .m-related-grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 9px;
        padding: 0 14px;
    }

    .m-related-card {
        min-width: 0;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 14px;
        overflow: hidden;
        box-shadow: var(--m-shadow);
        text-decoration: none;
        color: var(--m-ink);
    }

    .m-related-img {
        width: 100%;
        aspect-ratio: 1 / 1;
        background: #E9E1D8;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #A29689;
        font-size: 12px;
        overflow: hidden;
    }

    .m-related-img img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .m-related-card > b {
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        font-size: 12px;
        line-height: 1.45;
        padding: 7px 8px 0;
        font-weight: 500;
    }

    .m-related-meta {
        display: flex;
        gap: 5px;
        align-items: center;
        padding: 5px 8px 9px;
        font-size: 9.5px;
        color: var(--m-ink3);
    }

    .m-related-meta em {
        font-style: normal;
        color: var(--m-accent);
        font-size: 13px;
        font-weight: 700;
    }

    .detail-title {
        overflow-wrap: anywhere;
    }

    .detail-right .panel > .d-flex {
        flex-wrap: wrap;
    }

    .report-link {
        white-space: normal;
    }

    .attr-table {
        table-layout: fixed;
        width: 100%;
    }

    .attr-table th,
    .attr-table td {
        word-break: break-word;
        white-space: normal;
    }

    .publisher,
    .publisher > div {
        min-width: 0;
    }

    .detail-wrap .panel {
        border-radius: 16px;
        padding: 14px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
    }

    .gallery-main {
        border-radius: 16px;
        aspect-ratio: 1 / 1;
        background: #E8E0D7;
    }

    .gallery-main img {
        object-fit: cover;
    }

    .gallery-thumbs {
        gap: 6px;
        padding-top: 8px;
    }

    .gallery-thumbs img {
        width: 58px;
        height: 58px;
        border-radius: 9px;
    }

    .detail-title {
        font-size: 20px;
        line-height: 1.35;
        margin-top: 0;
    }

    .detail-price {
        font-size: 24px;
        margin-top: 6px;
    }

    .detail-right .panel > .d-flex {
        gap: 8px !important;
    }

    .detail-right .panel > .d-flex .text-muted {
        font-size: 10.5px;
    }

    .report-link {
        font-size: 10.5px;
    }

    .attr-table {
        margin-top: 10px;
    }

    .attr-table th,
    .attr-table td {
        padding: 8px 6px;
        font-size: 12px;
    }

    .attr-table th {
        width: 82px;
        color: var(--m-ink2);
        background: #F7F1EA;
    }

    .contact-box {
        border-radius: 12px;
        padding: 11px;
        background: #F7F1EA;
        margin-top: 10px;
        position: sticky;
        bottom: 8px;
        z-index: 8;
        box-shadow: 0 6px 18px rgba(88, 70, 52, .10);
    }

    .contact-box .phone {
        font-size: 22px;
    }

    .btn-reveal {
        width: 100%;
        min-height: 42px;
        border-radius: 12px;
        font-size: 13px;
    }

    .detail-left .breed-intro {
        font-size: 11.5px;
        padding: 12px;
        border-radius: 14px;
    }

    .detail-left .breed-intro h2 {
        font-size: 14px;
    }

    .detail-main .description {
        font-size: 13px;
        line-height: 1.8;
    }

    .publisher {
        padding-top: 10px;
        margin-top: 4px;
        border-top: 1px solid var(--m-line);
    }

    .detail-health {
        display: none !important;
    }

    .recommend-reading {
        margin-top: 12px;
    }

    .recommend-single {
        flex-direction: row;
        align-items: center;
    }

    .recommend-thumb {
        width: 84px;
        height: 64px;
        flex: 0 0 84px;
    }

    .recommend-info strong {
        font-size: 12px;
    }

    .detail-wrap + .section {
        margin-top: 14px;
    }

    /* ---------- 表单 / 登录注册 / 发布 ---------- */
    .form-card {
        margin: 12px 14px;
        max-width: none;
        padding: 18px 15px;
        border-radius: 17px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
    }

    .form-card h1 {
        font-size: 22px;
    }

    .form-card .sub {
        font-size: 11.5px;
        line-height: 1.6;
        margin-bottom: 14px;
    }

    .form-label {
        font-size: 12px;
        margin-bottom: 5px;
    }

    .form-control,
    .form-select {
        font-size: 16px;
        min-height: 42px;
        border-radius: 10px;
        padding: 8px 10px;
        border-color: var(--m-line);
        background-color: var(--m-surface);
    }

    textarea.form-control {
        font-size: 14px;
    }

    .btn-brand,
    .btn {
        min-height: 40px;
        border-radius: 11px;
        font-size: 13px;
    }

    .auth-links {
        display: flex;
        justify-content: space-between;
        font-size: 11.5px;
        margin-top: 14px;
    }

    .captcha-row {
        gap: 8px;
    }

    .captcha-row img {
        width: 150px;
        height: 44px;
        flex: 0 0 auto;
    }

    .captcha-row .form-control {
        min-width: 0;
    }

    .alert {
        font-size: 11.5px;
        border-radius: 10px;
        padding: 10px 11px;
    }

    .publish-tips,
    .form-card .alert-warning {
        font-size: 11px;
        line-height: 1.65;
    }

    /* ---------- 搜索历史 ---------- */
    .m-search-history,
    .m-hot-search {
        display: block;
        padding: 12px 14px 0;
    }

    .m-search-history .m-sect-head,
    .m-hot-search .m-sect-head {
        margin-bottom: 7px;
    }

    .m-search-history .m-sect-head button {
        border: 0;
        background: transparent;
        color: var(--m-ink3);
        font-size: 10.5px;
        padding: 0;
    }

    .m-history-chips {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }

    .m-history-chips a,
    .m-history-chips span {
        font-size: 10.5px;
        color: var(--m-ink2);
        background: #F7F1EA;
        border: 1px solid var(--m-line);
        border-radius: 12px;
        padding: 5px 10px;
        text-decoration: none;
    }

    .m-history-empty {
        font-size: 10.5px;
        color: var(--m-ink3);
    }

    /* ---------- 发布 ---------- */
    .publish-category-field > .form-label,
    .publish-category-field > select.form-select {
        display: none;
    }

    .m-cat-select {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        min-height: 44px;
        border: 1px solid var(--m-line);
        border-radius: 11px;
        background: var(--m-surface);
        padding: 9px 12px;
        color: var(--m-ink);
        font-size: 14px;
        text-align: left;
    }

    .m-cat-select em {
        font-style: normal;
        color: var(--m-accent);
        font-size: 11px;
        flex: none;
        margin-left: 8px;
    }

    .m-cat-picker {
        display: block;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 121;
        background: var(--m-surface);
        border-radius: 20px 20px 0 0;
        transform: translateY(105%);
        transition: transform .24s ease;
        max-height: 82vh;
        padding: 14px 14px calc(14px + env(safe-area-inset-bottom));
    }

    .m-cat-mask {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 120;
        background: rgba(40, 33, 27, .34);
        opacity: 0;
        pointer-events: none;
        transition: opacity .2s;
    }

    body.m-cat-open .m-cat-mask {
        opacity: 1;
        pointer-events: auto;
    }

    body.m-cat-open .m-cat-picker {
        transform: translateY(0);
    }

    .m-cat-picker-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 9px;
    }

    .m-cat-picker-head b {
        font-size: 17px;
    }

    .m-cat-picker-head button {
        border: 0;
        background: #F5EFE7;
        border-radius: 50%;
        width: 30px;
        height: 30px;
        font-size: 20px;
        color: var(--m-ink2);
    }

    .m-cat-picker-tabs {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
        padding-bottom: 9px;
        border-bottom: 1px solid #F0E9DF;
    }

    .m-cat-tab {
        border: 1px solid var(--m-line);
        background: #F7F1EA;
        color: var(--m-ink2);
        border-radius: 10px;
        padding: 7px 5px;
        font-size: 11px;
        line-height: 1.2;
        text-align: center;
        white-space: normal;
        word-break: break-all;
    }

    .m-cat-tab.on {
        background: var(--m-accent);
        border-color: var(--m-accent);
        color: #fff;
    }

    .m-cat-picker-body {
        max-height: 60vh;
        overflow-y: auto;
        padding-top: 9px;
    }

    .m-cat-panel {
        display: none;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 7px;
    }

    .m-cat-panel.on {
        display: grid;
    }

    .m-cat-option {
        display: block;
        padding: 10px;
        border: 1px solid var(--m-line);
        border-radius: 10px;
        background: #FBF8F4;
        color: var(--m-ink2);
        font-size: 12px;
        text-decoration: none;
        text-align: center;
    }

    .m-cat-option.on {
        border-color: var(--m-accent);
        color: var(--m-accent);
        background: var(--m-accent-s);
    }

    .m-publish-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        padding: 14px 14px 4px;
    }

    .m-publish-head b {
        display: block;
        font-size: 21px;
    }

    .m-publish-head span {
        display: block;
        font-size: 10.5px;
        color: var(--m-ink2);
        margin-top: 3px;
    }

    .m-publish-head a {
        font-size: 10.5px;
        color: var(--m-accent);
        text-decoration: none;
        background: var(--m-accent-s);
        padding: 5px 9px;
        border-radius: 9px;
        white-space: nowrap;
    }

    .m-publish-steps {
        display: flex;
        gap: 5px;
        padding: 8px 14px 0;
    }

    .m-publish-steps span {
        flex: 1;
        display: flex;
        align-items: center;
        gap: 3px;
        font-size: 9.5px;
        color: var(--m-ink3);
        white-space: nowrap;
    }

    .m-publish-steps i {
        width: 17px;
        height: 17px;
        border-radius: 50%;
        font-style: normal;
        border: 1px solid var(--m-line);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 9px;
        flex: none;
    }

    .m-publish-steps .on {
        color: var(--m-accent);
        font-weight: 600;
    }

    .m-publish-steps .on i {
        background: var(--m-accent);
        border-color: var(--m-accent);
        color: #fff;
    }

    /* ---------- 会员中心 ---------- */
    .member-layout {
        display: block;
        margin: 10px 0 14px;
        padding: 0 14px;
    }

    .m-member-home + .member-layout,
    .m-myinfos + .member-layout,
    .m-messages + .member-layout {
        display: none;
    }

    .member-side {
        display: flex;
        gap: 7px;
        overflow-x: auto;
        padding: 8px;
        border-radius: 15px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
        margin-bottom: 10px;
        scrollbar-width: none;
    }

    .member-side::-webkit-scrollbar {
        display: none;
    }

    .member-side .who {
        display: none;
    }

    .member-side > a {
        flex: none;
        white-space: nowrap;
        font-size: 11.5px;
        padding: 6px 10px;
        border-radius: 12px;
        background: #F7F1EA;
        margin: 0;
        border: 1px solid var(--m-line);
        text-decoration: none;
        color: var(--m-ink2);
    }

    .m-member-home {
        display: block;
        padding: 12px 14px 18px;
    }

    .m-member-profile {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 15px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 17px;
        box-shadow: var(--m-shadow);
    }

    .m-avatar {
        width: 52px;
        height: 52px;
        border-radius: 50%;
        overflow: hidden;
        background: #EAD8C8;
        color: #8A5C42;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 21px;
        font-weight: 700;
        flex: none;
    }

    .m-avatar img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .m-member-name {
        min-width: 0;
        flex: 1;
    }

    .m-member-name b {
        display: block;
        font-size: 17px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .m-member-name span {
        display: block;
        font-size: 11px;
        color: var(--m-ink2);
        margin-top: 3px;
    }

    .m-member-edit {
        border: 1px solid var(--m-line);
        color: var(--m-ink2);
        border-radius: 9px;
        padding: 5px 9px;
        font-size: 11px;
        text-decoration: none;
        flex: none;
    }

    .m-member-stats {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 7px;
        margin-top: 9px;
    }

    .m-member-stats > a,
    .m-member-stats > span {
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 13px;
        padding: 10px 4px;
        text-align: center;
        text-decoration: none;
        color: var(--m-ink);
    }

    .m-member-stats b {
        display: block;
        font-size: 18px;
    }

    .m-member-stats span {
        display: block;
        font-size: 9.5px;
        color: var(--m-ink2);
        margin-top: 2px;
    }

    .m-member-menu {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 7px;
        margin-top: 9px;
        padding: 11px 8px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 16px;
        box-shadow: var(--m-shadow);
    }

    .m-member-menu a {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
        text-decoration: none;
        color: var(--m-ink2);
        font-size: 10.5px;
        padding: 4px 0;
    }

    .m-mi {
        width: 38px;
        height: 38px;
        border-radius: 13px;
        background: #F6E7DB;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 16px;
    }

    .m-member-menu a:nth-child(3n+2) .m-mi { background: #E9EEE4; }
    .m-member-menu a:nth-child(3n) .m-mi { background: #F1E6E2; }

    .m-member-recent {
        margin-top: 10px;
        padding: 12px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 16px;
        box-shadow: var(--m-shadow);
    }

    .m-sect-head {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 8px;
        font-size: 14px;
    }

    .m-sect-head a {
        font-size: 10.5px;
        color: var(--m-ink2);
        text-decoration: none;
    }

    .m-my-card {
        display: flex;
        gap: 9px;
        padding: 8px 0;
        border-top: 1px solid #F0E9DF;
        text-decoration: none;
        color: var(--m-ink);
    }

    .m-my-thumb {
        flex: 0 0 78px;
        width: 78px;
        height: 68px;
        border-radius: 10px;
        overflow: hidden;
        background: #E9E1D8;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #A29689;
        font-size: 11px;
    }

    .m-my-thumb img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .m-my-body {
        min-width: 0;
        display: flex;
        flex-direction: column;
        gap: 3px;
    }

    .m-my-body b {
        font-size: 12.5px;
        line-height: 1.4;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .m-my-meta {
        font-size: 10px;
        color: var(--m-ink2);
    }

    .m-status {
        font-size: 9.5px;
        color: var(--m-accent);
        width: fit-content;
        background: var(--m-accent-s);
        padding: 1px 6px;
        border-radius: 5px;
    }

    .m-empty-mini {
        font-size: 11.5px;
        color: var(--m-ink2);
        padding: 10px 0;
    }

    .m-logout {
        display: block;
        text-align: center;
        font-size: 11.5px;
        color: var(--m-ink2);
        margin: 14px 0 0;
        text-decoration: none;
    }

    /* ---------- 我的发布 / 消息 ---------- */
    .m-myinfos,
    .m-messages {
        display: block;
        padding: 12px 14px 18px;
    }

    .m-page-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin: 2px 0 10px;
    }

    .m-page-head h2 {
        font-size: 22px;
        margin: 0;
    }

    .m-page-head a {
        font-size: 11px;
        background: var(--m-accent);
        color: #fff;
        padding: 6px 10px;
        border-radius: 10px;
        text-decoration: none;
    }

    .m-filter-scroll {
        display: flex;
        gap: 6px;
        overflow-x: auto;
        padding-bottom: 8px;
        scrollbar-width: none;
    }

    .m-filter-scroll::-webkit-scrollbar {
        display: none;
    }

    .m-filter-scroll a {
        flex: none;
        font-size: 10.5px;
        padding: 5px 9px;
        border-radius: 11px;
        background: #F7F1EA;
        border: 1px solid var(--m-line);
        color: var(--m-ink2);
        text-decoration: none;
    }

    .m-filter-scroll a.active {
        background: var(--m-accent);
        border-color: var(--m-accent);
        color: #fff;
    }

    .m-my-list {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .m-my-item {
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 14px;
        padding: 9px;
        box-shadow: var(--m-shadow);
    }

    .m-my-link {
        display: flex;
        gap: 9px;
        text-decoration: none;
        color: var(--m-ink);
    }

    .m-my-actions {
        display: flex;
        gap: 6px;
        justify-content: flex-end;
        margin-top: 8px;
        padding-top: 7px;
        border-top: 1px solid #F0E9DF;
    }

    .m-act {
        font-size: 10px;
        padding: 5px 9px;
        border-radius: 8px;
        background: #F7F1EA;
        border: 1px solid var(--m-line);
        color: var(--m-ink2);
        text-decoration: none;
        line-height: 1.4;
    }

    .m-act.danger { color: var(--m-danger); }

    .m-my-warn {
        font-size: 10px;
        color: var(--m-danger);
        line-height: 1.4;
    }

    .m-msg-list {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .m-msg {
        display: flex;
        gap: 8px;
        background: var(--m-surface);
        border: 1px solid var(--m-line);
        border-radius: 14px;
        padding: 11px;
        box-shadow: var(--m-shadow);
    }

    .m-msg-dot {
        width: 7px;
        height: 7px;
        border-radius: 50%;
        background: var(--m-accent);
        margin-top: 5px;
        flex: none;
    }

    .m-msg-body {
        min-width: 0;
    }

    .m-msg-body b {
        font-size: 12.5px;
    }

    .m-msg-body p {
        font-size: 11.5px;
        line-height: 1.65;
        color: var(--m-ink2);
        margin: 4px 0;
    }

    .m-msg-body span {
        font-size: 9.5px;
        color: var(--m-ink3);
    }

    .m-pager {
        padding: 10px 0 0;
        font-size: 11px;
    }


    .member-side {
        display: flex;
        gap: 7px;
        overflow-x: auto;
        padding: 8px;
        border-radius: 15px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
        margin-bottom: 10px;
        scrollbar-width: none;
    }

    .member-side::-webkit-scrollbar {
        display: none;
    }

    .member-side .who {
        display: none;
    }

    .member-side > a {
        flex: none;
        white-space: nowrap;
        font-size: 11.5px;
        padding: 6px 10px;
        border-radius: 12px;
        background: #F7F1EA;
        margin: 0;
        border: 1px solid var(--m-line);
    }

    .member-side > a:hover,
    .member-side > a.active {
        background: var(--m-accent-s);
        color: #9A6548;
    }

    .stat-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 9px;
        margin-bottom: 10px;
    }

    .stat-card {
        border-radius: 14px;
        padding: 12px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
    }

    .stat-card span {
        font-size: 11px;
    }

    .stat-card strong {
        font-size: 23px;
    }

    .table-card {
        border-radius: 15px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
        padding: 12px;
        overflow: hidden;
    }

    .table-card h5 {
        font-size: 16px;
    }

    .table-card .btn-brand {
        min-height: 34px;
        padding: 5px 10px;
        font-size: 11.5px;
    }

    .table-card .table {
        display: block;
        width: 100%;
        overflow-x: auto;
        white-space: nowrap;
        font-size: 12px;
        margin-bottom: 0;
    }

    .table-card .table th,
    .table-card .table td {
        padding: 8px 7px;
    }

    .table-card .filter-bar {
        padding-left: 0;
        padding-right: 0;
    }

    /* ---------- 内容页 / 帮助 / 举报 ---------- */
    .panel.mt-4 {
        margin: 12px 14px !important;
        border-radius: 16px;
        padding: 16px;
        border: 1px solid var(--m-line);
        box-shadow: var(--m-shadow);
    }

    .panel.mt-4 h1 {
        font-size: 22px !important;
    }

    .panel.mt-4 .description {
        font-size: 13px;
        line-height: 1.8;
    }

    .nnp-section:last-child {
        padding-bottom: 14px;
    }

    body.mobile-no-tabbar .mobile-header {
        margin-bottom: 0;
    }

    body.mobile-no-tabbar .site-main {
        padding-bottom: 16px;
    }
}

@media (max-width: 360px) {
    .mobile-brand b { font-size: 15px; }
    .mobile-loc { display: none; }
    .nnp-grid { gap: 8px; }
    .nnp-card-title { font-size: 12px; }
    .info-card .thumb { flex-basis: 96px; width: 96px; }
    .info-card .body h3 { font-size: 12px; }
    .detail-title { font-size: 19px; }
}
