@charset "utf-8";

/* ========== 1. 核心重置与背景 ========== */
*, *:before, *:after { box-sizing: border-box !important; }
body {
    margin: 0; padding: 0; background-color: #d1e4dd; color: #333;
    font-size: 15px; line-height: 1.6;
    font-family: "Helvetica Neue", Helvetica, Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
}

/* ========== 全局超链接美化 (彻底消除原始蓝色下划线) ========== */
a {
    text-decoration: none !important; /* 强制去除所有下划线 */
    color: #334155; /* 默认使用高级灰蓝色，不再是刺眼的纯蓝 */
    transition: color 0.3s ease; /* 增加鼠标悬浮时的平滑渐变动画 */
}

a:hover {
    color: #c5653e !important; /* 鼠标悬浮时统一变成中医特色暖橙色 */
}

/* --- 针对面包屑导航（如：中药方剂 > 安中散）的精细微调 --- */
.zd-path a {
    color: #64748b !important; 
    font-weight: normal;
}
.zd-path a:hover {
    color: #c5653e !important;
}

/* --- 针对底部区域（备案号、免责声明）的精细微调 --- */
.zd-footer a {
    color: #94a3b8 !important; /* 底部链接颜色再浅一点，避免喧宾夺主 */
    border-bottom: 1px solid transparent; /* 预留一个透明的底边框 */
    padding-bottom: 1px;
}
.zd-footer a:hover {
    color: #c5653e !important;
    border-bottom: 1px solid #c5653e; /* 悬浮时出现一条精致的下划线，显得很正规 */
}

/* ========== 2. 头部 Logo ========== */
.zd-header { background: #fff; padding: 20px 0; margin: 0 auto 20px auto; width: 1100px !important; border-bottom: 1px solid #e0e0e0; border-radius: 0 0 8px 8px; }
@media (min-width: 1081px) { .zd-nav { display: none !important; } }
.zd-logo { text-align: center; margin-bottom: 15px; height: 120px; }
.zd-logo-site { display: block; width: 210px; height: 120px; margin: 0 auto; background: transparent url(../image/logo-big-news.png) no-repeat center center; background-size: contain; font-size: 0; color: transparent; text-indent: -9999px; }

/* ========== 3. 搜索框 ========== */
.zd-search-box { max-width: 600px; margin: 10px auto 10px; padding: 0 15px; }
.zd-search-text { display: flex; height: 44px; border-radius: 22px; overflow: hidden; background: #fff; border: 2px solid #fcc800; transition: all 0.3s ease; }
.zd-search-text:hover { box-shadow: 0 2px 8px rgba(252, 200, 0, 0.3); }
.zd-text-input { flex: 1; border: none; outline: none; padding: 0 20px; font-size: 15px; background: transparent; }
.zd-s-btnw { width: 90px; background: #fcc800; }
.zd-s-btn { width: 100%; height: 100%; background: #fcc800; border: none; font-weight: 700; cursor: pointer; color: #333; font-size: 16px; letter-spacing: 2px; }
.zd-s-btn:hover { background: #fdb900; }

/* ========== 4. 主体布局 (PC默认) ========== */
.zd-main { display: grid !important; grid-template-columns: 755px 336px !important; grid-template-areas: "content sidebar" !important; justify-content: space-between !important; width: 1100px !important; margin: 0 auto 30px !important; align-items: start; }
.zd-content { grid-area: content; min-width: 0; }
.zd-sidebar { grid-area: sidebar; min-width: 0; }
.zd-path { display: flex !important; align-items: center; background: #f8fafb; padding: 12px 20px; border-bottom: 1px solid #edf2f7; }
.zd-path i:after { content: ">"; margin: 0 10px; color: #cbd5e1; font-weight: bold; }
.zd-path h1 { font-size: 16px; margin: 0; color: #333; font-weight: 700; display: inline-block !important; }
.zd-mcon { padding: 20px; }

/* ========== 5. 文章页单栏居中排版 (PC默认) ========== */
.article-single-layout { display: block !important; width: 1100px !important; margin: 0 auto 30px !important; }
.article-single-layout .zd-content { width: 900px !important; margin: 0 auto !important; float: none !important; background: #f0f4f8 !important; padding: 30px !important; border-radius: 10px !important; box-shadow: inset 0 0 10px rgba(0,0,0,0.02) !important; }

/* ========== 6. 药方卡片美化 ========== */
.article-single-layout .zd-mcon h2, .article-single-layout .zd-mcon h3, .article-single-layout .zd-mcon p strong, .article-single-layout .zd-mcon b {
    display: block !important; background: #ffffff !important; color: #1a56a8 !important; font-size: 20px !important; padding: 16px 20px !important; margin: 40px 0 0 0 !important; border: 1px solid #e2e8f0 !important; border-bottom: none !important; border-top: 4px solid #1a56a8 !important; border-radius: 8px 8px 0 0 !important; font-weight: bold !important; box-shadow: 0 2px 4px rgba(0,0,0,0.02) !important;
}
.article-single-layout .zd-mcon .item { background: #ffffff !important; border: 1px solid #e2e8f0 !important; border-top: 1px dashed #e2e8f0 !important; margin-bottom: 0 !important; border-radius: 0 !important; box-shadow: 0 2px 4px rgba(0,0,0,0.02) !important; display: flex; transition: all 0.3s ease; }
.article-single-layout .zd-mcon .item:last-child { border-radius: 0 0 8px 8px !important; margin-bottom: 40px !important; }
.zd-mcon .item-name { width: 100px; min-width: 100px; padding: 15px 10px; font-weight: 700; display: flex; align-items: center; justify-content: center; border-right: 1px solid #e7eaec; }
.zd-mcon .item-content { flex: 1; padding: 15px; line-height: 1.8; color: #444; word-break: break-all; }
.item.prescription .item-name { background: #f0f7ff; color: #1565c0; }
.item.functional_indications .item-name { background: #fff7ed; color: #c2410c; }
.item.usage .item-name { background: #f0fdf4; color: #15803d; }

/* ========== 7. 侧边栏与页脚 ========== */
.zd-sdc { padding: 15px; }
.zd-sdc h3 { color: #c5653e; font-size: 18px; margin-bottom: 15px; font-weight: bold; }
.zd-btn { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 0; list-style: none; }
.zd-btn li a { display: block; padding: 10px; background: #f1f5f9; text-align: center; border-radius: 6px; font-size: 14px; color: #333; }
.zd-btn li a:hover { background: #c5653e; color: #fff; }
.zd-footer { width: 1100px !important; margin: 40px auto 20px !important; text-align: center; border-top: 1px solid #e2e8f0; padding: 20px 0; color: #64748b; }

/* ========== 8. 移动端兼容 (必须放在文件最底部) ========== */
@media (max-width: 1080px) {
    /* 取消所有写死的PC端宽度，强行设置为 100% */
    body { background-color: #f5f7fa !important; }
    .zd-header, .zd-main, .zd-footer { width: 100% !important; padding: 10px !important; margin: 0 auto !important; box-sizing: border-box !important; }
    .article-single-layout { width: 100% !important; padding: 0 !important; margin: 0 auto 15px !important; }
    .article-single-layout .zd-content, .zd-content { width: 100% !important; padding: 10px !important; margin: 0 !important; border-radius: 6px !important; box-sizing: border-box !important; }
    .zd-search-box { width: 100% !important; padding: 0 10px !important; }
    
    /* 调整布局结构 */
    .zd-main { display: flex !important; flex-direction: column !important; }
    .zd-sidebar { display: none !important; } /* 移动端隐藏侧边栏 */
    .zd-nav { display: block !important; }
    .zd-logo { display: none !important; }
    
    /* 移动端卡片内部排列（处方、主治变上下结构） */
    .article-single-layout .zd-mcon .item, .zd-mcon .item { flex-direction: column !important; }
    .zd-mcon .item-name { width: 100% !important; border-right: none !important; border-bottom: 1px solid #f0f0f0 !important; padding: 10px !important; text-align: left !important; justify-content: flex-start !important; }
    
    /* 移动端标题字号和间距收缩防撑破 */
    .article-single-layout .zd-mcon h2, .article-single-layout .zd-mcon h3, .article-single-layout .zd-mcon p strong, .article-single-layout .zd-mcon b {
        font-size: 17px !important; padding: 12px 15px !important; margin: 20px 0 0 0 !important;
    }
    
    .zd-mcon { padding: 5px !important; }
    .zd-path { flex-wrap: wrap; }
}

/* ========== 恢复卡片悬浮浮动特效 ========== */
.article-single-layout .zd-mcon .item:hover,
.zd-mcon .item:hover {
    transform: translateY(-4px) !important; /* 向上浮动 4px */
    box-shadow: 0 10px 25px rgba(0,0,0,0.08) !important; /* 增加高级阴影 */
    border-color: #c5653e !important; /* 边框变成中医暖橙色 */
    position: relative !important; 
    z-index: 99 !important; /* 保证浮动时覆盖住周围的卡片，不会被遮挡 */
}