/* ============================================
   common.css  公共样式
   reset + header + 双层导航 + 广告位 + 横幅 + footer
   ============================================ */

/* ----- Reset ----- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box
}

html, body {
    height: 100%;
    /*background:#e3edf7;*/
    color: #333;
    font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.6;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color .15s
}

/*a:hover {*/
/*    color: #e63838*/
/*}*/

ul, ol {
    list-style: none
}

img {
    display: block;
    max-width: 100%;
    border: 0
}

button {
    font-family: inherit;
    cursor: pointer;
    border: 0;
    background: none
}

body.noscroll {
    overflow: hidden
}


/* ----- Header ----- */
.site-header {
    position: relative;
    height: 140px;
    background: url(../images/header-bg.png) center top / 100% 100% no-repeat;
}

.header-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    height: 140px;
    padding: 0 40px;
}

.header-center {
    position: absolute;
    left: 38%;
    top: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    cursor: pointer;
    flex: 0 0 auto;
    margin-right: 16px
}

.logo img {
    display: block
}

.header-title {
    flex: 0 0 auto;
    text-align: center;
    color: #010F55;
    margin-left: 60px;
    padding-top: 15px;
}

.header-title h1 {
    font-size: 33px;
    font-weight: 700;
    letter-spacing: 2px;
}

.header-title h2 {
    font-size: 18px;
    font-weight: 400;
    color: #3B6FB4;
    line-height: 1.5;
    margin-top: 2px
}

.header-slogan {
    font-size: 16px;
    font-weight: 700;
    color: #010F55;
    letter-spacing: 4px;
    /*margin-top: 6px*/
}

.header-search {
    display: flex;
    align-items: center;
    position: absolute;
    right: 150px;
    top: 50%;
    transform: translateY(-50%)
}

.header-search input {
    width: 300px;
    height: 47px;
    padding: 0 18px;
    border: 0;
    background: #fff;
    color: #333;
    font-size: 15px;
    outline: none;
    border-radius: 4px 0 0 4px;
}

.header-search input::placeholder {
    color: #999
}

.header-search button {
    width: 110px;
    height: 47px;
    background: #0036A2;
    color: #fff;
    font-size: 15px;
    border-radius: 0 4px 4px 0;
    letter-spacing: 2px;
}

/* ----- Navigation (双层) ----- */
.site-nav {
    background: #0036A2;
    border-bottom: 1px solid #0a3a8a;
}

.nav-row {
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    padding: 0 200px;
    display: grid;
    grid-template-columns:repeat(8, auto);
    align-items: center;
}

.nav-row-1 {
    height: 96px
}

.nav-row-2 {
    height: 42px;
    background: rgba(255, 255, 255, .06);
    border-top: 1px solid rgba(255, 255, 255, .12);
}

.nav-row a {
    text-align: center;
    color: #fff;
    font-size: 15px;
    position: relative;
    letter-spacing: 2px;
    line-height: 1;
}

.nav-row-1 a {
    line-height: 48px
}

.nav-row-2 a {
    line-height: 42px;
    opacity: .92
}

.nav-row a:hover, .nav-row a.active {
    background: #164CB3;
    /*color: #ffd24d;*/
    opacity: 1
}

/* ----- Layout (左广告 + 主内容 + 右广告) ----- */
.layout {
    flex: 1;
    width: 100%;
    max-width: 1920px;
    margin: 20px auto 0;
    display: grid;
    grid-template-columns: 140px 1fr 140px;
    gap: 20px;
    align-items: start;
    padding: 0 40px;
}

.ad {
    visibility: hidden;
}

.ad-card {
    background: linear-gradient(180deg, #6cb0ee 0%, #3c87d8 50%, #2566bb 100%);
    border-radius: 4px;
    color: #fff;
    padding: 22px 10px;
    text-align: center;
    height: 780px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(40, 80, 160, .15);
}

.ad-card .ad-title {
    font-size: 18px;
    font-weight: bold;
    letter-spacing: 3px;
    line-height: 1.5;
    margin-bottom: 8px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}

.ad-card .ad-sub {
    font-size: 12px;
    opacity: .9;
    margin-bottom: 16px;
    letter-spacing: 2px
}

.ad-doctor {
    width: 84px;
    height: 104px;
    margin: 16px auto;
    position: relative
}

.ad-doctor::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #ffd9b8;
    transform: translateX(-50%);
    box-shadow: inset -4px -4px 0 rgba(0, 0, 0, .08);
}

.ad-doctor::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 30px;
    width: 68px;
    height: 66px;
    background: #fff;
    border-radius: 34px 34px 4px 4px;
    transform: translateX(-50%);
    box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .05);
}

.ad-monitor {
    width: 96px;
    height: 68px;
    margin: 12px auto;
    background: #fff;
    border-radius: 4px;
    position: relative;
    padding: 6px;
}

.ad-monitor::before {
    content: "";
    position: absolute;
    left: 8px;
    right: 8px;
    top: 8px;
    bottom: 18px;
    background: #0a1530;
    border-radius: 2px;
}

.ad-monitor::after {
    content: "♥";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 2px;
    text-align: center;
    color: #e63838;
    font-size: 12px;
    line-height: 1;
}

.ad-dots {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-top: 8px
}

.ad-dots span {
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, .5);
    border-radius: 50%
}

.ad-card.product {
    background: linear-gradient(180deg, #e0eefb 0%, #a4ccef 100%);
    color: #0036A2
}

.ad-card.product .ad-title {
    color: #0036A2;
    text-shadow: none
}

.ad-card.product .ad-sub {
    color: #3a6ba8
}

.ad-bottle {
    width: 60px;
    height: 126px;
    margin: 20px auto;
    background: #fff;
    border-radius: 24px 24px 6px 6px;
    position: relative;
    border: 2px solid #d0e2f5;
}

.ad-bottle::before {
    content: "";
    position: absolute;
    left: 50%;
    top: -8px;
    width: 32px;
    height: 10px;
    background: #0036A2;
    border-radius: 4px 4px 0 0;
    transform: translateX(-50%);
}

.ad-bottle::after {
    content: "";
    position: absolute;
    left: 6px;
    right: 6px;
    top: 30px;
    bottom: 14px;
    background: linear-gradient(180deg, #7ab8f0 0%, #2a6cc4 100%);
    border-radius: 4px;
}

.main-content {
    min-width: 0
}

/* ----- 通用 Panel ----- */
.panel {
    background: #fff;
    border: 1px solid #d4e2f1;
    border-radius: 6px;
    overflow: hidden
}

.panel-head {
    height: 40px;
    padding: 0 16px;
    background: linear-gradient(180deg, #eaf3fc 0%, #d4e6f7 100%);
    border-bottom: 1px solid #c4d8ed;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.panel-head h3 {
    font-size: 16px;
    color: #0036A6;
    font-weight: bold;
    line-height: 1;
    padding-left: 4px;
    letter-spacing: 1px;
    margin-bottom: 0;
}

.panel-head .more {
    color: #333333;
    font-size: 12px;
    display: inline-flex;
    align-items: center;
}

.panel-head .more:hover {
    /*color: #e63838*/
}

.panel-head .more .more-icon {
    width: 8px;
    height: 8px;
    position: relative;
}

.panel-head .more .more-icon:first-of-type {
    z-index: 1;
    margin-left: 16px;
}

.panel-head .more .more-icon + .more-icon {
    margin-left: -4px;
}

/* ----- 蓝色横幅(首页用) ----- */
.banner {
    margin-top: 16px;
    height: 96px;
    border-radius: 4px;
    color: #fff;
    background: linear-gradient(135deg, #5a9de6 0%, #3a7fce 50%, #2a6cc4 100%);
    display: flex;
    align-items: center;
    padding: 0 30px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(40, 80, 160, .12);
}

.banner::before {
    content: "";
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 40%;
    background: radial-gradient(circle at 70% 50%, rgba(255, 255, 255, .18) 0 30%, transparent 32%),
    radial-gradient(circle at 90% 30%, rgba(255, 255, 255, .12) 0 25%, transparent 27%);
}

.banner-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 18px;
    flex: 0 0 60px;
    position: relative;
    z-index: 1;
}

.banner-icon::before, .banner-icon::after {
    content: "";
    position: absolute;
    background: #fff;
    border-radius: 2px;
}

.banner-icon::before {
    width: 28px;
    height: 6px;
    left: 16px;
    top: 27px
}

.banner-icon::after {
    width: 6px;
    height: 28px;
    left: 27px;
    top: 16px
}

.banner-text {
    flex: 1;
    position: relative;
    z-index: 1
}

.banner-text h3 {
    font-size: 24px;
    font-weight: bold;
    letter-spacing: 3px;
    margin-bottom: 4px
}

.banner-text .meta {
    font-size: 13px;
    opacity: .95;
    letter-spacing: 1px
}

.banner-text .meta span {
    margin-right: 18px
}

.banner-doctor {
    width: 90px;
    height: 96px;
    position: relative;
    z-index: 1;
    margin-right: 10px;
    align-self: flex-end;
}

.banner-doctor::before {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #ffd9b8;
    transform: translateX(-50%);
    box-shadow: inset -4px -4px 0 rgba(0, 0, 0, .08);
}

.banner-doctor::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 64px;
    height: 42px;
    background: #fff;
    border-radius: 32px 32px 0 0;
    transform: translateX(-50%);
}

/* ----- Footer ----- */
.site-footer {
    margin-top: 20px;
    background: #164CB3;
    padding: 18px 0;
    color: #cfdcef;
    font-size: 12px;
}

.footer-nav {
    text-align: center;
    padding-bottom: 10px;
    color: #fff
}

.footer-nav a {
    margin: 0 10px
}

.footer-info {
    text-align: center;
    line-height: 1.9;
    color: #a8c2e6
}

/* ============================================
   Mobile / Tablet (≤1024)
   ============================================ */

/* ----- 汉堡按钮(默认隐藏,≤1024 显示) ----- */
.header-burger {
    display: none;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    background: transparent;
    border-radius: 4px;
    position: relative;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    margin-left: 12px;
}

.header-burger span {
    display: block;
    position: absolute;
    left: 8px;
    right: 8px;
    height: 2px;
    background: #0036A2;
    border-radius: 2px;
    transition: all .25s;
}

.header-burger span:nth-child(1) {
    top: 12px
}

.header-burger span:nth-child(2) {
    top: 19px
}

.header-burger span:nth-child(3) {
    top: 26px
}

/* ----- 抽屉遮罩 ----- */
.mobile-drawer-mask {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all .25s;
}

.mobile-drawer-mask.open {
    opacity: 1;
    visibility: visible
}

/* ----- 抽屉主体 ----- */
.mobile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    background: #fff;
    z-index: 999;
    box-shadow: -2px 0 12px rgba(0, 0, 0, .18);
    transform: translateX(100%);
    transition: transform .3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mobile-drawer.open {
    transform: translateX(0)
}

.drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: linear-gradient(180deg, #eaf3fc 0%, #d4e6f7 100%);
    border-bottom: 1px solid #c4d8ed;
}

.drawer-head .drawer-logo {
    display: flex;
    align-items: center;
    gap: 8px
}

.drawer-head .drawer-logo img {
    /*border-radius: 50%*/
}

.drawer-head .drawer-logo .name {
    color: #0036A2;
    font-weight: bold;
    font-size: 16px;
    letter-spacing: 2px
}

.drawer-close {
    width: 32px;
    height: 32px;
    position: relative;
    flex: 0 0 32px;
    border-radius: 4px;
}

.drawer-close::before, .drawer-close::after {
    content: "";
    position: absolute;
    left: 6px;
    right: 6px;
    top: 50%;
    height: 2px;
    background: #0036A2;
    border-radius: 2px;
}

.drawer-close::before {
    transform: rotate(45deg)
}

.drawer-close::after {
    transform: rotate(-45deg)
}

.drawer-search {
    display: flex;
    padding: 12px 16px;
    border-bottom: 1px solid #e7eef6;
    background: #f4f8fc;
}

.drawer-search input {
    flex: 1;
    height: 36px;
    padding: 0 12px;
    border: 1px solid #d4e2f1;
    border-right: 0;
    background: #fff;
    color: #888;
    font-size: 13px;
    outline: none;
    border-radius: 2px 0 0 2px;
}

.drawer-search button {
    width: 64px;
    height: 36px;
    background: #0036A2;
    color: #fff;
    font-size: 13px;
    border-radius: 0 2px 2px 0;
    letter-spacing: 2px;
}

.drawer-nav {
    flex: 1;
    overflow-y: auto;
}

.drawer-nav .group-title {
    padding: 10px 16px 6px;
    font-size: 12px;
    color: #888;
    letter-spacing: 2px;
    background: #f4f8fc;
    border-top: 1px solid #e7eef6;
}

.drawer-nav .group-title:first-child {
    border-top: 0
}

.drawer-nav a {
    display: block;
    padding: 12px 20px;
    font-size: 15px;
    color: #333;
    border-left: 3px solid transparent;
    transition: all .15s;
}

.drawer-nav a:hover, .drawer-nav a.active {
    background: #f4f8fc;
    border-left-color: #0036A2;
    color: #0036A2;
}

/* ============================================
   媒体查询 - Tablet (≤1024)
   ============================================ */
@media (max-width: 1024px) {
    /* body 字号保持 14px,移除旧的 min-width */
    html, body {
        font-size: 14px
    }

    /* Header 收折 */
    .site-header {
        height: 100px;
        background: url(../images/header-bg.png) center top / auto 100% no-repeat;
    }

    .header-inner {
        height: 100px;
        padding: 0 16px;
        display: flex;
        align-items: center;
        justify-content: flex-start
    }

    .header-center {
        position: static;
        transform: none;
        left: auto;
        top: auto;
        display: flex;
        align-items: center;
        gap: 50px;
        margin-left: 25%
    }

    .logo {
        margin-right: 0;
        background: none;
        border-radius: 0;
        padding: 0;
        flex: 0 0 auto
    }

    .logo img {
        height: 56px
    }

    .header-title {
        display: block;
        color: #010F55;
        text-align: left;
        margin-left: 0;
        padding-top: 15px;
        flex: 0 0 auto
    }

    .header-title h1 {
        font-size: 18px;
        letter-spacing: 1px;
        white-space: nowrap
    }

    .header-slogan {
        font-size: 12px;
        letter-spacing: 2px
    }

    .header-search {
        display: none
    }

    .header-burger {
        display: flex;
        position: absolute;
        right: 16px;
        top: 50%;
        transform: translateY(-50%);
        margin-left: 0
    }

    /* 桌面导航整块隐藏 */
    .site-nav {
        display: none
    }

    /* 挂件 / 侧边广告隐藏 */
    .ad {
        display: none
    }

    /* Layout 变单列 */
    .layout {
        width: 100%;
        max-width: 100%;
        margin: 12px auto 0;
        padding: 0 12px;
        gap: 0;
        display: block;
    }

    .main-content {
        width: 100%
    }

    /* Footer 间距缩 */
    .site-footer {
        margin-top: 14px;
        padding: 14px 0
    }

    .footer-nav a {
        margin: 0 6px
    }
}

/* ============================================
   媒体查询 - Small Desktop / Tablet Landscape (1025-1500)
   隐藏侧边广告位,主内容撑满,避免轮播图/法律咨询挤占新闻/监督权
   ============================================ */
@media (min-width: 1025px) and (max-width: 1500px) {
    .ad {
        display: none
    }

    .layout {
        grid-template-columns: 1fr;
        gap: 0
    }

    .main-content {
        width: 100%
    }
}

/* ============================================
   媒体查询 - Mobile (≤768)
   ============================================ */
@media (max-width: 768px) {
    /* body 字号略缩 */
    html, body {
        font-size: 13px
    }

    /* Header 再紧凑 */
    .site-header {
        height: 80px
    }

    .header-inner {
        height: 80px;
        padding: 0 10px
    }

    .header-center {
        gap: 30px;
        margin-left: 12%
    }

    .header-burger {
        right: 10px
    }

    .logo img {
        height: 44px
    }

    .header-title h1 {
        font-size: 14px;
        letter-spacing: 0
    }

    .header-slogan {
        font-size: 10px;
        letter-spacing: 1px
    }

    /* 抽屉内搜索隐藏 */
    .drawer-search {
        display: none
    }

    /* Layout padding 再缩 */
    .layout {
        padding: 0 10px;
        margin: 10px auto 0
    }

    /* Footer 链接换行友好 */
    .footer-nav {
        padding: 0 8px 8px;
        line-height: 2
    }

    .footer-nav a {
        margin: 0 6px
    }

    .footer-info {
        padding: 0 8px
    }
}

.footer-info p {
    margin: 2px 0
}
