/* ========== 基础与变量 ========== */
:root {
    --color-paper: #fdf6e8;          /* 米黄宣传册底色 */
    --color-paper-edge: #f3e7c8;     /* 卡片边缘 */
    --color-ink: #2b2520;            /* 正文墨色 */
    --color-ink-soft: #4a3f36;
    --color-red: #b03531;            /* 朱砂红 */
    --color-red-deep: #8b2520;       /* 深朱砂（题字） */
    --color-red-soft: #d96b5e;
    --color-green: #3d5a3a;          /* 墨绿（点缀） */
    --color-line: #c9b389;           /* 装饰线 */

    --font-kai: "楷体", "STKaiti", "Kaiti SC", "BiauKai", "DFKai-SB", serif;
    --font-song: "宋体", "SimSun", "Songti SC", "STSong", "Source Han Serif SC", serif;
    --font-hei: "黑体", "SimHei", "Heiti SC", "PingFang SC", sans-serif;
    --font-xingkai: "华文行楷", "STXingkai", "STKaiti", "楷体", serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-song);
    color: var(--color-ink);
     /*  background: #e8dcc0;
   古旧纸纹理 - 用渐变模拟 */
    background-image:
        radial-gradient(ellipse at top left, rgba(176, 53, 49, 0.04), transparent 60%),
        radial-gradient(ellipse at bottom right, rgba(61, 90, 58, 0.05), transparent 60%),
        repeating-linear-gradient(45deg, rgba(139, 90, 43, 0.015) 0 2px, transparent 2px 6px);
    line-height: 1.85;
    font-size: 16px;
    min-height: 100vh;
    padding: 0;
}

/* 整页容器 - 模拟宣传册纸张 */
.page {
    max-width: 760px;
    margin: 0 auto;
    background: var(--color-paper);
    box-shadow:
        0 0 1px rgba(0, 0, 0, 0.1),
        0 30px 80px -20px rgba(43, 37, 32, 0.35),
        0 10px 30px -10px rgba(43, 37, 32, 0.25);
    position: relative;
    overflow: hidden;
}

/* 纸张内圈装饰 - 仿宣传册边缘的细微暗角 */
.page::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    box-shadow: inset 0 0 80px rgba(139, 90, 43, 0.12);
    z-index: 5;
}

/* ========== Hero 顶部门面图 ========== */
.hero {
    position: relative;
    width: 100%;
    overflow: hidden;
    background: #1a1a1a;
}

.hero img {
    width: 100%;
    height: auto;
    display: block;
}

/* ========== 通用主标题：医院介绍 ========== */
.title-main {
    font-family: var(--font-kai);
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--color-red-deep);
    text-align: center;
    letter-spacing: 0.4em;
    text-indent: 0.4em;
    padding: 56px 0 40px;
    position: relative;
}

.title-main::after {
    content: "";
    display: block;
    width: 180px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--color-red) 30%, var(--color-red) 70%, transparent);
    margin: 18px auto 0;
}

/* ========== 医院介绍区块 ========== */
.intro {
    padding: 0 56px 40px;
    position: relative;
}

.intro-block {
    margin-bottom: 28px;
    position: relative;
    padding-left: 18px;
}

/* 段落左侧装饰竖线 */
.intro-block::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 6px;
    width: 3px;
    background: var(--color-red);
    opacity: 0.55;
}

.intro-label {
    display: inline-block;
    font-family: var(--font-kai);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--color-red-deep);
    margin-bottom: 6px;
    letter-spacing: 0.15em;
    position: relative;
    padding: 2px 10px 2px 2px;
}

.intro-label::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 6px;
    background: rgba(176, 53, 49, 0.12);
    z-index: -1;
}

.intro-block p {
    text-indent: 2em;
    color: var(--color-ink);
    margin-bottom: 6px;
    text-align: justify;
}

/* ========== 院内环境图 ========== */
.environment {
    padding: 0 56px 50px;
}

.environment img {
    width: 100%;
    height: auto;
    display: block;
    border: 1px solid var(--color-paper-edge);
    box-shadow: 0 4px 14px -6px rgba(43, 37, 32, 0.3);
}

/* ========== 重点科室介绍 ========== */
.departments {
    padding: 0 0 50px;
}

.banner-title {
    font-family: var(--font-kai);
    font-size: 2rem;
    font-weight: 700;
    color: #fff;
    text-align: center;
    letter-spacing: 0.3em;
    text-indent: 0.3em;
    padding: 22px 0;
    background: var(--color-red-deep);
    background-image: linear-gradient(180deg, var(--color-red) 0%, var(--color-red-deep) 100%);
    margin: 0 0 38px;
    position: relative;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-bottom: 1px solid rgba(0, 0, 0, 0.2);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.25),
        inset 0 -1px 0 rgba(0, 0, 0, 0.15);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.banner-title::before,
.banner-title::after {
    content: "❖";
    color: rgba(255, 255, 255, 0.6);
    font-size: 1rem;
    margin: 0 1.5em;
    letter-spacing: 0;
    vertical-align: middle;
}

.dept {
    display: grid;
    grid-template-columns: 1fr 200px;
    gap: 28px;
    align-items: flex-start;
    padding: 0 56px 28px;
    margin-bottom: 4px;
    position: relative;
}

.dept:not(:last-child)::after {
    content: "";
    position: absolute;
    left: 56px;
    right: 56px;
    bottom: 8px;
    height: 1px;
    background: repeating-linear-gradient(90deg, var(--color-line) 0 4px, transparent 4px 10px);
}

.dept-text .dept-name {
    font-family: var(--font-kai);
    font-size: 1.2rem;
    color: var(--color-red-deep);
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: 0.06em;
}

.dept-text p {
    text-indent: 2em;
    color: var(--color-ink);
    text-align: justify;
    margin-bottom: 4px;
    font-size: 0.96rem;
}

.dept-motto {
    color: var(--color-green) !important;
    font-family: var(--font-kai);
    margin-top: 6px !important;
    text-indent: 0 !important;
}

.dept-figure {
    text-align: center;
}

.dept-figure img {
    width: 100%;
    height: auto;
    aspect-ratio: 408 / 233;
    object-fit: cover;
    display: block;
    border: 4px solid #fff;
    box-shadow:
        0 0 0 1px var(--color-paper-edge),
        0 8px 16px -6px rgba(43, 37, 32, 0.3);
}

.dept-figure figcaption {
    margin-top: 10px;
    font-family: var(--font-kai);
    font-size: 0.95rem;
    color: var(--color-red-deep);
    letter-spacing: 0.1em;
    font-weight: 600;
}

/* ========== 地址 & 乘车路线 ========== */
.contact {
    padding: 30px 56px 40px;
    background: rgba(255, 250, 235, 0.6);
    border-top: 2px double var(--color-red);
    border-bottom: 2px double var(--color-red);
    margin: 30px 0 0;
    position: relative;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 36px;
    margin-bottom: 28px;
}

.contact-title {
    font-family: var(--font-kai);
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--color-red-deep);
    margin-bottom: 16px;
    letter-spacing: 0.2em;
    text-align: center;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--color-line);
}

.map-box {
    background: #fffdf6;
    border: 1px solid var(--color-line);
    padding: 14px;
    box-shadow: inset 0 0 20px rgba(139, 90, 43, 0.08);
}

.map-box img {
    width: 100%;
    height: auto;
    display: block;
}

.route-list {
    list-style: none;
    counter-reset: route;
    padding-left: 0;
}

.route-list li {
    counter-increment: route;
    position: relative;
    padding: 8px 0 8px 30px;
    border-bottom: 1px dashed var(--color-line);
    font-size: 0.92rem;
    line-height: 1.75;
    color: var(--color-ink);
}

.route-list li:last-child {
    border-bottom: none;
}

.route-list li::before {
    content: counter(route);
    position: absolute;
    left: 0;
    top: 10px;
    width: 22px;
    height: 22px;
    line-height: 22px;
    text-align: center;
    background: var(--color-red);
    color: #fff;
    font-family: var(--font-hei);
    font-size: 0.78rem;
    border-radius: 50%;
    font-weight: 700;
}

.route-list li strong {
    color: var(--color-red-deep);
    font-weight: 600;
}

.contact-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--color-line);
    font-family: var(--font-kai);
    font-size: 1.05rem;
    color: var(--color-ink);
    flex-wrap: wrap;
}

.contact-item em {
    font-style: normal;
    color: var(--color-red-deep);
    font-weight: 700;
    letter-spacing: 0.1em;
}

.contact-divider {
    width: 1px;
    height: 18px;
    background: var(--color-line);
}

/* ========== Footer ========== */
.page-footer {
    text-align: center;
    padding: 28px 20px 40px;
    background: var(--color-red-deep);
    color: rgba(255, 245, 230, 0.95);
    font-family: var(--font-kai);
    letter-spacing: 0.1em;
}

.page-footer .footer-sub {
    margin-top: 6px;
    font-family: "Georgia", serif;
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    color: rgba(255, 245, 230, 0.6);
}

.page-footer .footer-copyright {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 245, 230, 0.18);
    font-family: var(--font-song);
    font-size: 0.78rem;
    letter-spacing: 0.04em;
    color: rgba(255, 245, 230, 0.7);
}

.page-footer .footer-copyright a {
    color: rgba(255, 245, 230, 0.7);
    text-decoration: none;
    margin-left: 8px;
    transition: color 0.2s ease;
}

.page-footer .footer-copyright a:hover {
    color: #fff;
    text-decoration: underline;
}

/* ========== 响应式 ========== */
@media (max-width: 720px) {
    body {
        background: var(--color-paper);
    }

    .page {
        box-shadow: none;
        max-width: 100%;
    }

    .title-main {
        font-size: 1.8rem;
        padding: 36px 0 26px;
        letter-spacing: 0.3em;
    }

    .intro,
    .environment,
    .contact {
        padding-left: 22px;
        padding-right: 22px;
    }

    .banner-title {
        font-size: 1.4rem;
        padding: 16px 0;
        letter-spacing: 0.2em;
    }

    .banner-title::before,
    .banner-title::after {
        margin: 0 0.6em;
    }

    .dept {
        grid-template-columns: 1fr;
        gap: 16px;
        padding-left: 22px;
        padding-right: 22px;
    }

    .dept:not(:last-child)::after {
        left: 22px;
        right: 22px;
    }

    .dept-figure {
        max-width: 280px;
        margin: 0 auto;
    }

    .dept-figure img {
        aspect-ratio: 408 / 233;
        height: auto;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .contact-bar {
        flex-direction: column;
        gap: 8px;
    }

    .contact-divider {
        display: none;
    }
}

/* 打印优化（部分医院常用） */
@media print {
    body {
        background: #fff;
    }
    .page {
        box-shadow: none;
        max-width: 100%;
    }
}
