/* ============================================================
   四川高草堂中医医学研究院 - 前端样式
   主色调：中草药绿风格（#8B7355 草药绿 / #6B5A3E 深红 / #C4A46A 橙金 / #FAF5E6 淡绿白）
   辅助色：#A0845A 浅绿 / #fff 背景
   ============================================================ */

/* ---------- Reset & Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
    color: #333; line-height: 1.6; background: #fff; min-height: 100vh; display: flex; flex-direction: column;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
button, input, select, textarea { font: inherit; }
ul, ol { list-style: none; }
table { border-collapse: collapse; width: 100%; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 20px; }

/* ---------- Typography ---------- */
h1, h2, h3, h4 { line-height: 1.3; color: #8B7355; }
h1 { font-size: 2rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.1rem; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-block; padding: 10px 24px; border: 2px solid #8B7355; border-radius: 6px;
    background: #8B7355; color: #fff; font-weight: 600; cursor: pointer; transition: .2s;
    font-size: 0.95rem;
}
.btn:hover { background: #A0845A; border-color: #A0845A; }
.btn-outline { background: transparent; color: #8B7355; }
.btn-outline:hover { background: #8B7355; color: #fff; }
.btn-sm { padding: 6px 14px; font-size: 0.85rem; }
.btn-primary { background: #8B7355; border-color: #8B7355; }
.btn-primary:hover { background: #A0845A; }
.btn-danger { background: #d32f2f; border-color: #d32f2f; }
.btn-danger:hover { background: #b71c1c; }
.btn-success { background: #6B5A3E; border-color: #6B5A3E; }
.btn-block { display: block; width: 100%; text-align: center; }

/* ---------- Top Bar ---------- */
.topbar {
    background: #8B7355; color: #C4A46A; font-size: 0.82rem; padding: 6px 0;
}
.topbar-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.topbar-contact { margin-right: 16px; }
.topbar-right { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.lang-switch a, .lang-switch span { color: #C4A46A; font-size: 0.82rem; }
.lang-switch a.active { color: #fff; font-weight: 700; }
.lang-switch span { margin: 0 4px; color: #A0845A; }
.currency-switch select {
    background: #A0845A; color: #C4A46A; border: 1px solid #A0845A; border-radius: 4px;
    padding: 2px 6px; font-size: 0.82rem; cursor: pointer;
}
.currency-switch select option { background: #8B7355; }

/* ---------- Header / Nav ---------- */
.site-header {
    background: #fff; border-bottom: 1px solid #e0e0e0; position: sticky; top: 0; z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.header-inner {
    display: flex; align-items: center; justify-content: space-between; padding: 12px 0; gap: 24px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo img { height: 48px; }
.logo-text { font-size: 1.4rem; font-weight: 700; color: #8B7355; }
.main-nav { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.main-nav a {
    padding: 8px 14px; border-radius: 6px; font-size: 0.95rem; font-weight: 500;
    color: #444; transition: .2s;
}
.main-nav a:hover, .main-nav a.active { background: #FAF5E6; color: #8B7355; }
.header-actions { display: flex; align-items: center; gap: 12px; }
.cart-btn {
    position: relative; font-size: 1.4rem; padding: 6px 10px; border-radius: 8px; transition: .2s;
}
.cart-btn:hover { background: #FAF5E6; }
.cart-count {
    position: absolute; top: 0; right: 0; background: #C4A46A; color: #fff;
    font-size: 0.7rem; font-weight: 700; min-width: 18px; height: 18px;
    border-radius: 9px; display: flex; align-items: center; justify-content: center;
    padding: 0 4px;
}
.nav-toggle {
    display: none; background: none; border: none; font-size: 1.6rem; cursor: pointer; color: #8B7355;
}

/* ---------- Banner Slider ---------- */
.banner-slider {
    position: relative; width: 100%; overflow: hidden; background: #8B7355;
}
.banner-slide {
    display: none; min-height: 420px; background-size: cover; background-position: center;
    align-items: center;
}
.banner-slide.active { display: flex; }
.banner-slide .container { display: flex; align-items: center; justify-content: center; min-height: 420px; }
.banner-content { text-align: center; color: #fff; max-width: 700px; padding: 60px 20px; }
.banner-content h2 { font-size: 2.4rem; margin-bottom: 16px; text-shadow: 0 2px 8px rgba(0,0,0,0.3); }
.banner-content .btn { margin-top: 20px; font-size: 1.1rem; padding: 12px 36px; }

/* ---------- Sections ---------- */
.section { padding: 60px 0; }
.section-alt { background: #FAF5E6; }
.section-title { text-align: center; margin-bottom: 40px; }
.section-title h2 { font-size: 1.8rem; color: #8B7355; margin-bottom: 8px; }
.section-title p { color: #666; font-size: 1rem; }

/* ---------- Product Grid ---------- */
.product-grid {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}
.product-card {
    background: #fff; border: 1px solid #e8e8e8; border-radius: 12px; overflow: hidden;
    transition: .25s; display: flex; flex-direction: column;
}
.product-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,0.1); transform: translateY(-4px); }
.product-img {
    position: relative; width: 100%; padding-top: 100%; background: #FAF5E6; overflow: hidden;
}
.product-img img { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
.badge {
    position: absolute; top: 10px; left: 10px; padding: 3px 10px; border-radius: 4px;
    font-size: 0.75rem; font-weight: 700; color: #fff; z-index: 2;
}
.badge-hot { background: #e53935; }
.badge-new { background: #8B7355; }
.product-info { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.product-name { font-size: 1rem; font-weight: 600; margin-bottom: 6px; color: #8B7355; }
.product-name a:hover { color: #8B7355; }
.product-spec { font-size: 0.85rem; color: #888; margin-bottom: 10px; }
.product-meta { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.product-price { font-size: 1.2rem; font-weight: 700; color: #d32f2f; }
.product-moq { font-size: 0.8rem; color: #888; }
.product-actions { display: flex; gap: 8px; margin-top: auto; }
.product-actions .btn { flex: 1; text-align: center; }

/* ---------- Advantages ---------- */
.adv-grid {
    display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px;
}
.adv-card {
    text-align: center; padding: 30px 20px; background: #fff; border-radius: 12px;
    border: 1px solid #e8e8e8; transition: .25s;
}
.adv-card:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.08); transform: translateY(-2px); }
.adv-icon { font-size: 2.4rem; margin-bottom: 12px; }
.adv-card h4 { font-size: 1.05rem; margin-bottom: 8px; color: #8B7355; }
.adv-card p { font-size: 0.9rem; color: #666; }

/* ---------- CTA Section ---------- */
.cta-section {
    background: linear-gradient(135deg, #8B7355 0%, #1a5a3a 100%); color: #fff;
    text-align: center; padding: 60px 20px; border-radius: 12px; margin: 40px 0;
}
.cta-section h2 { font-size: 1.8rem; margin-bottom: 12px; }
.cta-section p { font-size: 1.05rem; margin-bottom: 24px; opacity: 0.9; }

/* ---------- Footer ---------- */
.site-footer { background: #8B7355; color: #C4A46A; margin-top: auto; }
.footer-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px; padding: 50px 0 30px;
}
.footer-col h4 { color: #fff; font-size: 1rem; margin-bottom: 16px; }
.footer-col p, .footer-col a { font-size: 0.88rem; line-height: 1.8; color: #C4A46A; }
.footer-col a:hover { color: #fff; }
.footer-bottom {
    border-top: 1px solid #A0845A; padding: 16px 0; text-align: center; font-size: 0.82rem;
}

/* ---------- Forms ---------- */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 0.92rem; color: #444; }
.form-group label .req { color: #d32f2f; }
.form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 10px 14px; border: 1px solid #ccc; border-radius: 6px;
    font-size: 0.95rem; transition: border-color .2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none; border-color: #8B7355; box-shadow: 0 0 0 3px rgba(62,39,35,0.15);
}
.form-row { display: flex; gap: 16px; flex-wrap: wrap; }
.form-row .form-group { flex: 1; min-width: 200px; }
.form-note { font-size: 0.82rem; color: #888; margin-top: 4px; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
table.styled { width: 100%; }
table.styled th {
    background: #FAF5E6; color: #8B7355; padding: 12px 14px; text-align: left;
    font-size: 0.88rem; font-weight: 700; border-bottom: 2px solid #C4A46A;
}
table.styled td { padding: 12px 14px; border-bottom: 1px solid #eee; font-size: 0.92rem; }
table.styled tr:hover td { background: #FAF5E6; }

/* ---------- Badges ---------- */
.badge-status {
    display: inline-block; padding: 3px 10px; border-radius: 4px; font-size: 0.78rem; font-weight: 600;
}
.badge-pending { background: #fff3e0; color: #e65100; }
.badge-confirmed { background: #FAF5E6; color: #6B5A3E; }
.badge-shipped { background: #f3e5f5; color: #7b1fa2; }
.badge-done { background: #FAF5E6; color: #6B5A3E; }
.badge-cancel { background: #ffebee; color: #c62828; }
.badge-paid { background: #FAF5E6; color: #6B5A3E; }

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 6px; justify-content: center; padding: 20px 0; }
.pagination a {
    display: inline-block; padding: 6px 12px; border: 1px solid #ddd; border-radius: 4px;
    font-size: 0.88rem; color: #444; transition: .2s;
}
.pagination a:hover, .pagination a.active { background: #8B7355; color: #fff; border-color: #8B7355; }

/* ---------- Flash Messages ---------- */
.flash {
    padding: 14px 22px 14px 50px; border-radius: 10px; margin: 18px 0; font-size: 0.98rem;
    font-weight: 500; position: relative; box-shadow: 0 3px 12px rgba(139,115,85,0.10);
}
.flash::before {
    position: absolute; left: 18px; top: 50%; transform: translateY(-50%); font-size: 1.15rem;
}
.flash-success { background: #F5EED8; color: #5A7A3E; border: 1px solid #C4A46A; }
.flash-success::before { content: "\2705"; }
.flash-error { background: #FDECEA; color: #B03A2E; border: 1px solid #F5C6C2; }
.flash-error::before { content: "\26A0"; }
.flash-warning { background: #FFF6E0; color: #B9770E; border: 1px solid #F5DFAE; }
.flash-warning::before { content: "\1F514"; }

/* ---------- Cart Page ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 30px; align-items: start; }
.cart-items { }
.cart-summary {
    background: #FAF5E6; border: 1px solid #e8e8e8; border-radius: 12px; padding: 24px;
    position: sticky; top: 100px;
}
.cart-summary h3 { margin-bottom: 16px; color: #8B7355; }
.summary-row { display: flex; justify-content: space-between; padding: 8px 0; font-size: 0.95rem; }
.summary-row.total { font-weight: 700; font-size: 1.15rem; border-top: 2px solid #ddd; padding-top: 12px; margin-top: 8px; }
.qty-control { display: flex; align-items: center; gap: 6px; }
.qty-control input { width: 60px; text-align: center; padding: 6px; border: 1px solid #ccc; border-radius: 4px; }
.qty-control button { width: 28px; height: 28px; border: 1px solid #ccc; border-radius: 4px; background: #f5f5f5; cursor: pointer; font-weight: 700; }

/* ---------- Checkout ---------- */
.checkout-layout { display: grid; grid-template-columns: 1fr 400px; gap: 30px; align-items: start; }
.checkout-form { }
.checkout-summary { background: #FAF5E6; border: 1px solid #e8e8e8; border-radius: 12px; padding: 24px; }
.payment-options { display: flex; flex-direction: column; gap: 12px; }
.payment-option {
    display: flex; align-items: center; gap: 12px; padding: 14px; border: 2px solid #ddd;
    border-radius: 8px; cursor: pointer; transition: .2s;
}
.payment-option:hover, .payment-option.selected { border-color: #8B7355; background: #FAF5E6; }
.payment-option input { accent-color: #8B7355; }

/* ---------- Order Track ---------- */
.track-form { max-width: 500px; margin: 0 auto; }
.track-result { max-width: 700px; margin: 30px auto 0; }

/* ---------- Member Pages ---------- */
.member-layout { max-width: 1000px; margin: 0 auto; }
.member-nav { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 26px; border-bottom: 2px solid #EFE6D2; }
.member-nav a {
    padding: 11px 18px; border-radius: 10px 10px 0 0; font-weight: 600; font-size: 0.93rem; color: #7A6A55;
    text-decoration: none; transition: .2s; white-space: nowrap;
}
.member-nav a:hover { background: #FAF5E6; color: #8B7355; }
.member-nav a.active { background: #8B7355; color: #FFF8E7; }

/* ---------- Admin Shared ---------- */
.admin-login-box {
    max-width: 420px; margin: 80px auto; background: #fff; border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1); padding: 40px 36px;
}
.admin-login-box h1 { text-align: center; color: #8B7355; margin-bottom: 8px; }
.admin-login-box .subtitle { text-align: center; color: #888; margin-bottom: 28px; font-size: 0.92rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .cart-layout, .checkout-layout { grid-template-columns: 1fr; }
    .cart-summary, .checkout-summary { position: static; }
    .product-grid { grid-template-columns: repeat(3, 1fr); }
    .adv-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
    .nav-toggle { display: block; }
    .main-nav {
        display: none; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0;
        background: #fff; border-bottom: 2px solid #e0e0e0; padding: 12px 20px; box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    }
    .main-nav.open { display: flex; }
    .main-nav a { padding: 10px 0; }
    .banner-content h2 { font-size: 1.6rem; }
    .banner-slide .container { min-height: 300px; }
    .banner-slide { min-height: 300px; }
    .product-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .adv-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    .form-row { flex-direction: column; gap: 0; }
    h1 { font-size: 1.6rem; }
    h2 { font-size: 1.3rem; }
    .section { padding: 40px 0; }
}
@media (max-width: 480px) {
    .product-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .adv-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .product-info { padding: 10px; }
    .product-actions { flex-direction: column; }
    .topbar-inner { flex-direction: column; align-items: flex-start; gap: 4px; }
    .header-inner { flex-wrap: wrap; }
}

/* ===========================================
   移动端优化 - 2026-09-01
   =========================================== */

/* --- 汉堡菜单按钮（默认隐藏，768px以下显示）--- */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: #8B7355;
}

/* --- 768px 及以下（平板 + 手机）--- */
@media (max-width: 768px) {
    .mobile-toggle { display: block; }
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        padding: 16px 20px;
        box-shadow: 0 4px 16px rgba(0,0,0,0.1);
        z-index: 200;
    }
    .main-nav.open { display: flex; }
    .main-nav a {
        padding: 12px 0;
        border-bottom: 1px solid #f0f0f0;
    }
    .header-inner {
        flex-wrap: wrap;
    }
    .cart-btn span.cart-count {
        font-size: 0.72rem;
        padding: 1px 5px;
    }
    /* Banner */
    .banner-slide {
        min-height: 280px !important;
    }
    .banner-content h2 {
        font-size: 1.3rem !important;
    }
    .banner-content .btn {
        padding: 8px 18px !important;
        font-size: 0.9rem !important;
    }
    /* 产品网格 */
    .product-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px !important;
    }
    .product-card .product-name {
        font-size: 0.88rem;
    }
    .product-card .product-price {
        font-size: 0.92rem;
    }
    /* 统计卡片 */
    .stat-cards {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    /* 通用容器 */
    .container {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
    section.section {
        padding-top: 36px !important;
        padding-bottom: 36px !important;
    }
    /* 表单 */
    .form-row {
        flex-direction: column !important;
    }
    .form-row .form-group {
        min-width: unset !important;
    }
    input[type="text"],
    input[type="email"],
    input[type="password"],
    select,
    textarea {
        font-size: 16px !important; /* 防止 iOS 自动缩放 */
    }
    /* 联系我们页面 */
    .contact-grid {
        grid-template-columns: 1fr !important;
    }
    .page-hero h1 {
        font-size: 1.6rem !important;
    }
    /* 后台表格 */
    .table-wrap {
        overflow-x: auto;
    }
    .admin-table th,
    .admin-table td {
        padding: 10px 10px !important;
        font-size: 0.82rem;
    }
}

/* --- 480px 及以下（大手机）--- */
@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px !important;
    }
    .banner-slide {
        min-height: 220px !important;
    }
    .banner-content h2 {
        font-size: 1.1rem !important;
    }
    .section-title h2 {
        font-size: 1.3rem !important;
    }
    .stat-cards {
        grid-template-columns: 1fr !important;
    }
    .adv-grid {
        grid-template-columns: 1fr !important;
    }
    /* 会员中心 */
    .member-layout {
        flex-direction: column !important;
    }
    .member-sidebar {
        width: 100% !important;
        flex-direction: row !important;
        overflow-x: auto;
    }
    .member-nav {
        display: flex !important;
        flex-direction: row !important;
        padding: 8px 12px !important;
    }
    .member-nav a {
        white-space: nowrap;
        padding: 8px 14px !important;
        border-left: none !important;
        border-bottom: 3px solid transparent;
    }
    .member-nav a.active {
        border-left: none !important;
        border-bottom-color: #8B7355 !important;
    }
}

/* --- 360px 及以下（小手机）--- */
@media (max-width: 360px) {
    .product-grid {
        grid-template-columns: 1fr !important;
    }
    .logo-text {
        font-size: 1.1rem !important;
    }
}

/* ============================================================
   移动端精致化美化 - 2026-09-01
   ============================================================ */

/* ---------- 全局移动端基础 ---------- */
@media (max-width: 768px) {
    body { font-size: 14px; }
    .container { padding-left: 14px !important; padding-right: 14px !important; }

    /* ---------- 顶部工具栏：只保留语言切换 ---------- */
    .topbar { padding: 4px 0; }
    .topbar-left { display: none !important; }
    .topbar-inner { justify-content: center !important; }
    .topbar-right { gap: 10px; }
    .lang-switch a { font-size: 0.85rem; padding: 2px 6px; border-radius: 12px; }
    .lang-switch a.active { background: rgba(255,255,255,0.18); }
    .currency-switch select { font-size: 0.78rem; padding: 3px 4px; }
    .topbar-right > a { font-size: 0.82rem; padding: 2px 8px; border: 1px solid rgba(255,255,255,0.25); border-radius: 12px; }

    /* ---------- 头部：logo + 汉堡 ---------- */
    .site-header { position: sticky; top: 0; }
    .header-inner { padding: 10px 0; gap: 8px; flex-wrap: nowrap !important; }
    .logo-text { font-size: 1.05rem !important; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 52vw; }
    .logo img { height: 36px; }
    .header-actions { gap: 6px; }
    .cart-btn { font-size: 1.25rem; padding: 4px 8px; }
    .cart-count { min-width: 16px; height: 16px; font-size: 0.62rem; }

    /* ---------- 汉堡菜单按钮美化 ---------- */
    .mobile-toggle {
        display: flex !important;
        width: 38px; height: 38px;
        align-items: center; justify-content: center;
        background: #FAF5E6;
        border: 1px solid #E8D8C8;
        border-radius: 10px;
        font-size: 1.3rem;
        color: #8B7355;
        transition: .25s;
    }
    .mobile-toggle:active { background: #8B7355; color: #fff; transform: scale(0.94); }

    /* ---------- 下拉菜单：卡片式 ---------- */
    .main-nav {
        top: calc(100% + 4px);
        left: 8px !important; right: 8px !important;
        background: #fff;
        border-radius: 14px;
        padding: 8px !important;
        box-shadow: 0 12px 32px rgba(0,0,0,0.16) !important;
        border: 1px solid #f0e8e0 !important;
        animation: navSlideIn .22s ease;
    }
    @keyframes navSlideIn {
        from { opacity: 0; transform: translateY(-8px); }
        to   { opacity: 1; transform: translateY(0); }
    }
    .main-nav a {
        padding: 13px 16px !important;
        border-radius: 10px;
        border-bottom: none !important;
        font-size: 0.98rem;
        font-weight: 500;
        color: #444;
    }
    .main-nav a.active { background: #FAF5E6; color: #8B7355; font-weight: 700; }
    .main-nav a:hover { background: #FAF5E6; }

    /* ---------- Banner：圆角卡片风格 ---------- */
    .banner-slider { margin: 10px 14px 0; border-radius: 16px; overflow: hidden; }
    .banner-slide { min-height: 180px !important; }
    .banner-slide .container { min-height: 180px !important; }
    .banner-content { padding: 24px 16px !important; }
    .banner-content h2 { font-size: 1.15rem !important; margin-bottom: 8px !important; line-height: 1.4; }

    /* ---------- 产品卡片：精致卡片 ---------- */
    .product-grid { gap: 10px !important; }
    .product-card {
        border-radius: 12px !important;
        border: 1px solid #f0ece8 !important;
        box-shadow: 0 2px 8px rgba(0,0,0,0.04) !important;
        overflow: hidden;
    }
    .product-card .product-img-wrap { border-radius: 12px 12px 0 0; }
    .product-card .product-info { padding: 8px 10px 10px !important; }
    .product-name { font-size: 0.85rem !important; line-height: 1.35; }
    .product-price { font-size: 0.9rem !important; }
    .product-card .badge { font-size: 0.62rem !important; padding: 2px 6px !important; border-radius: 8px !important; }

    /* ---------- 区块标题 ---------- */
    .section { padding: 32px 0 !important; }
    .section-title { margin-bottom: 22px !important; }
    .section-title h2 { font-size: 1.25rem !important; }
    .section-title p { font-size: 0.85rem !important; }

    /* ---------- 首页特色区块 ---------- */
    .adv-grid { gap: 10px !important; }
    .adv-card { border-radius: 12px !important; padding: 14px 10px !important; }
    .adv-card .adv-icon { font-size: 1.5rem !important; }

    /* ---------- 留言表单 ---------- */
    .inquiry-form, form[action*="index.php#inquiryForm"] {
        background: #fff; border-radius: 14px; padding: 18px !important;
        box-shadow: 0 2px 12px rgba(0,0,0,0.05) !important;
    }
    input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
    select, textarea {
        border-radius: 10px !important;
        padding: 11px 12px !important;
        border: 1.5px solid #e8e4e0 !important;
        background: #FAFAFA !important;
        font-size: 16px !important;
    }
    input:focus, select:focus, textarea:focus {
        border-color: #8B7355 !important;
        background: #fff !important;
        box-shadow: 0 0 0 3px rgba(139,0,0,0.08) !important;
        outline: none;
    }
    .form-group label { font-size: 0.88rem !important; }

    /* ---------- 按钮 ---------- */
    .btn { border-radius: 10px !important; }
    .btn-primary { box-shadow: 0 3px 10px rgba(139,0,0,0.2) !important; }

    /* ---------- 页脚 ---------- */
    .site-footer { padding: 32px 0 24px !important; }
    .footer-grid { grid-template-columns: 1fr 1fr !important; gap: 20px !important; }
    .footer-col h4 { font-size: 0.95rem !important; margin-bottom: 10px !important; }
    .footer-col p, .footer-col a { font-size: 0.82rem !important; line-height: 1.9 !important; }

    /* ---------- 页面 hero（关于/FAQ/联系） ---------- */
    .page-hero { padding: 36px 0 !important; margin-bottom: 28px !important; }
    .page-hero h1 { font-size: 1.5rem !important; }

    /* ---------- 产品详情 ---------- */
    .detail-grid { gap: 20px !important; }
    .detail-gallery img { border-radius: 12px !important; }
    .detail-info h1 { font-size: 1.25rem !important; }

    /* ---------- 购物车/结算 ---------- */
    .cart-item { padding: 12px !important; border-radius: 12px !important; }
    .qty-input { width: 64px !important; padding: 6px !important; }

    /* ---------- 会员中心 ---------- */
    .welcome-card { padding: 22px !important; border-radius: 14px !important; }
    .welcome-card h2 { font-size: 1.15rem !important; }
    .stat-item { padding: 14px 10px !important; border-radius: 12px !important; }
    .stat-item .num { font-size: 1.5rem !important; }
    .action-btn { padding: 11px 8px !important; font-size: 0.82rem !important; border-radius: 10px !important; }
}

/* ---------- 超小屏（360px以下） ---------- */
@media (max-width: 360px) {
    .logo-text { max-width: 46vw; font-size: 0.95rem !important; }
    .banner-slide { min-height: 150px !important; }
    .banner-content h2 { font-size: 1rem !important; }
    .footer-grid { grid-template-columns: 1fr !important; }
}

/* ========== 首页：名医团队 ========== */
.expert-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.expert-card {
    background: #fff; border: 1px solid #eee; border-radius: 14px; padding: 32px 24px 26px;
    text-align: center; cursor: pointer; transition: .25s; position: relative;
}
.expert-card:hover { box-shadow: 0 10px 30px rgba(139,115,85,.16); transform: translateY(-4px); border-color: #E0D2B4; }
.expert-avatar {
    width: 96px; height: 96px; margin: 0 auto 16px; border-radius: 50%; position: relative;
    background: linear-gradient(135deg,#8B7355,#C4A46A); overflow: visible;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 2.3rem; font-weight: 700;
}
.expert-avatar > span { line-height: 1; }
.expert-avatar img { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; }
.expert-years {
    position: absolute; right: -8px; bottom: -2px; background: #fff; color: #8B7355;
    border: 2px solid #C4A46A; border-radius: 14px; padding: 1px 9px;
    font-size: .72rem; font-weight: 700; white-space: nowrap;
}
.expert-card h3 { margin: 0 0 6px; font-size: 1.15rem; color: #3d3226; letter-spacing: 1px; }
.expert-title { color: #8B7355; font-size: .92rem; font-weight: 600; margin-bottom: 4px; }
.expert-field { color: #a09687; font-size: .82rem; margin-bottom: 14px; }
.expert-intro { list-style: none; padding: 0; margin: 0 0 16px; text-align: left; }
.expert-intro li { position: relative; padding-left: 15px; font-size: .85rem; color: #6b7c8c; line-height: 1.85; }
.expert-intro li:before {
    content: ""; position: absolute; left: 0; top: .75em; width: 5px; height: 5px;
    border-radius: 50%; background: #C4A46A;
}
.expert-more { color: #8B7355; font-size: .85rem; font-weight: 600; }
.expert-card:hover .expert-more { text-decoration: underline; }

/* ========== 首页：经典案例 ========== */
.case-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.case-card {
    background: #fff; border: 1px solid #eee; border-radius: 14px; overflow: hidden;
    cursor: pointer; transition: .25s; display: flex; flex-direction: column;
}
.case-card:hover { box-shadow: 0 10px 30px rgba(139,115,85,.16); transform: translateY(-4px); }
.case-img {
    height: 172px; position: relative; background: linear-gradient(135deg,#8B7355,#A0845A);
    display: flex; align-items: center; justify-content: center;
    color: rgba(255,255,255,.6); font-size: 2.4rem; letter-spacing: 4px;
}
.case-img img { width: 100%; height: 172px; object-fit: cover; display: block; }
.case-tag {
    position: absolute; left: 12px; top: 12px; background: rgba(255,255,255,.95);
    color: #8B7355; font-size: .76rem; padding: 4px 12px; border-radius: 12px; font-weight: 600;
}
.case-body { padding: 20px 22px 22px; flex: 1; display: flex; flex-direction: column; }
.case-body h3 { margin: 0 0 8px; font-size: 1.05rem; color: #3d3226; line-height: 1.5; }
.case-meta { font-size: .8rem; color: #a89a86; margin-bottom: 10px; }
.case-body p { margin: 0 0 14px; font-size: .88rem; color: #6b7c8c; line-height: 1.85; flex: 1; }
.case-more { color: #8B7355; font-size: .85rem; font-weight: 600; }
.case-card:hover .case-more { text-decoration: underline; }
.case-note { text-align: center; font-size: .78rem; color: #a79c8c; margin-top: 28px; line-height: 1.9; }

/* ========== 详情弹窗 ========== */
.hm-mask {
    position: fixed; inset: 0; background: rgba(0,0,0,.6); z-index: 9999;
    display: none; align-items: center; justify-content: center; padding: 20px;
}
.hm-mask.show { display: flex; }
.hm-modal {
    background: #fff; border-radius: 16px; max-width: 620px; width: 100%;
    max-height: 86vh; overflow-y: auto; position: relative; box-shadow: 0 24px 60px rgba(0,0,0,.3);
}
.hm-close {
    position: absolute; right: 16px; top: 10px; background: none; border: 0;
    font-size: 2rem; color: #aaa; cursor: pointer; line-height: 1; z-index: 2;
}
.hm-close:hover { color: #8B7355; }
.hm-modal > #hmBody > *:first-child { margin-top: 0; }
.hm-head {
    display: flex; gap: 18px; align-items: center;
    padding: 32px 38px 20px; background: linear-gradient(135deg,#FAF5E6,#fff);
    border-bottom: 1px solid #F0E8D5;
}
.hm-ava {
    width: 74px; height: 74px; flex-shrink: 0; border-radius: 50%; overflow: hidden;
    background: linear-gradient(135deg,#8B7355,#C4A46A); color: #fff;
    display: flex; align-items: center; justify-content: center; font-size: 1.9rem; font-weight: 700;
}
.hm-ava img { width: 74px; height: 74px; object-fit: cover; }
.hm-head h3 { margin: 0 0 5px; font-size: 1.25rem; color: #3d3226; }
.hm-sub { color: #8B7355; font-weight: 600; font-size: .92rem; }
.hm-sub2 { color: #a09687; font-size: .82rem; margin-top: 3px; }
.hm-list { list-style: none; padding: 22px 38px 6px; margin: 0; }
.hm-list li { position: relative; padding-left: 16px; margin-bottom: 11px; font-size: .92rem; color: #5A4A38; line-height: 1.85; }
.hm-list li:before { content: ""; position: absolute; left: 0; top: .72em; width: 6px; height: 6px; border-radius: 50%; background: #C4A46A; }
.hm-head2 { padding: 30px 38px 16px; }
.hm-tag {
    display: inline-block; background: #F5EFE0; color: #8B7355; font-size: .78rem;
    padding: 4px 13px; border-radius: 12px; font-weight: 600; margin-bottom: 10px;
}
.hm-head2 h3 { margin: 0; font-size: 1.25rem; color: #3d3226; line-height: 1.5; }
.hm-img { width: 100%; max-height: 260px; object-fit: cover; display: block; }
.hm-lead {
    margin: 18px 38px 0; padding: 14px 16px; background: #FAF5E6; border-left: 3px solid #C4A46A;
    border-radius: 0 8px 8px 0; font-size: .92rem; color: #5A4A38; line-height: 1.9;
}
.hm-p { margin: 15px 38px 0; font-size: .92rem; color: #5A4A38; line-height: 2; }
.hm-p b { color: #8B7355; }
.hm-cta {
    display: block; margin: 26px 38px 32px; text-align: center; text-decoration: none;
    background: linear-gradient(135deg,#8B7355,#A0845A); color: #FFF8E7 !important;
    padding: 13px 20px; border-radius: 8px; font-weight: 600; font-size: .95rem;
}
.hm-cta:hover { opacity: .92; }

@media (max-width: 900px) {
    .expert-grid, .case-grid { grid-template-columns: 1fr; gap: 18px; }
    .hm-head, .hm-head2 { padding-left: 22px; padding-right: 22px; }
    .hm-list, .hm-lead, .hm-p { padding-left: 22px; padding-right: 22px; margin-left: 0; margin-right: 0; }
    .hm-cta { margin-left: 22px; margin-right: 22px; }
}

/* ========== 会员中心卡片组件（mc-*） ========== */
.mc-card { background:#fff;border:1px solid #EFE9DC;border-radius:14px;padding:22px 24px;box-shadow:0 2px 10px rgba(139,115,85,.06);margin-bottom:20px; }
.mc-card h3 { margin:0 0 16px;font-size:1.05rem;color:#8B7355;display:flex;align-items:center;gap:8px; }
.mc-head { background:linear-gradient(135deg,#8B7355,#A0845A);color:#FFF8E7;border-radius:16px;padding:26px 28px;margin-bottom:22px;
    display:flex;align-items:center;gap:20px;flex-wrap:wrap;box-shadow:0 10px 28px rgba(139,115,85,.22); }
.mc-ava { width:62px;height:62px;border-radius:50%;background:rgba(255,255,255,.18);border:2px solid rgba(255,255,255,.45);
    display:flex;align-items:center;justify-content:center;font-size:1.7rem;font-weight:700;flex-shrink:0; }
.mc-head-txt { flex:1;min-width:190px; }
.mc-head h2 { margin:0 0 6px;font-size:1.35rem;color:#FFF8E7;letter-spacing:1px; }
.mc-head p { margin:0;color:#E8D5A8;font-size:.9rem; }
.mc-head-btns { display:flex;gap:10px;flex-wrap:wrap; }
.mc-btn { display:inline-block;padding:10px 20px;border-radius:8px;font-weight:600;font-size:.9rem;text-decoration:none;transition:.2s; }
.mc-btn-solid { background:#FFF8E7;color:#8B7355; }
.mc-btn-solid:hover { background:#fff;color:#8B7355; }
.mc-btn-ghost { background:transparent;color:#FFF8E7;border:2px solid rgba(255,255,255,.5); }
.mc-btn-ghost:hover { border-color:#FFF8E7;background:rgba(255,255,255,.12);color:#FFF8E7; }
.mc-welcome-ok { display:flex;align-items:center;gap:16px;background:#EAF7EE;border:1px solid #B7DFC4;border-radius:14px;
    padding:18px 22px;margin-bottom:20px; }
.mc-stats { display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin-bottom:20px; }
.mc-stat { background:#fff;border:1px solid #EFE9DC;border-radius:14px;padding:18px 12px;text-align:center;box-shadow:0 2px 10px rgba(139,115,85,.06); }
.mc-stat .n { font-size:1.7rem;font-weight:800;color:#8B7355;line-height:1.25; }
.mc-stat .l { font-size:.82rem;color:#9A8F6E;margin-top:4px; }
.mc-actions { display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:12px; }
.mc-action { display:flex;flex-direction:column;align-items:center;gap:6px;padding:18px 12px;background:#FAF5E6;border:1px solid #EFE6D2;
    border-radius:12px;text-decoration:none;transition:.22s; }
.mc-action:hover { background:#8B7355;border-color:#8B7355;transform:translateY(-3px);box-shadow:0 8px 20px rgba(139,115,85,.18); }
.mc-action .ic { font-size:1.6rem;line-height:1; }
.mc-action .t { font-size:.92rem;font-weight:600;color:#5A4A38; }
.mc-action .d { font-size:.76rem;color:#A09687;text-align:center; }
.mc-action:hover .t { color:#FFF8E7; }
.mc-action:hover .d { color:rgba(255,248,231,.85); }
.mc-order { display:flex;align-items:center;gap:12px;padding:13px 0;border-bottom:1px dashed #EFE9DC;flex-wrap:wrap; }
.mc-order:last-child { border-bottom:none; }
.mc-order .no { font-family:Consolas,Monaco,monospace;font-size:.86rem;color:#5A4A38;min-width:120px; }
.mc-order .dt { font-size:.82rem;color:#A09687; }
.mc-order .amt { font-weight:700;color:#8B7355;margin-left:auto; }
.mc-badge { display:inline-block;font-size:.75rem;color:#fff;padding:3px 10px;border-radius:11px;line-height:1.5; }
.mc-badge-line { background:transparent;color:#8B7355;border:1px solid #DDD0AF; }
.mc-empty { text-align:center;padding:22px 0;color:#9A8F6E;font-size:.92rem; }

@media (max-width: 768px) {
    .mc-stats { grid-template-columns: repeat(2, 1fr); }
    .mc-head { padding: 20px; gap: 14px; }
    .mc-head-btns { width: 100%; }
    .member-nav { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .member-nav a { padding: 9px 14px; font-size: .88rem; }
    .mc-order .amt { margin-left: 0; }
}
