/* =========================================================================
   百香集 · 古今异名（gjym）
   页面级排版：异名总说 / 名词对照（检索）/ 古籍引证 / 名物源流
   ========================================================================= */

/* ---------- 异名总说 ---------- */
.summary {
    display: grid;
    grid-template-columns: 1.12fr 1fr;
    gap: 60px;
    align-items: center;
}

.summary-text .section-head.is-left { margin-bottom: 24px; }

.summary-text .section-head h2 { padding: 0; font-size: 32px; }

.summary-text .section-head h2::before,
.summary-text .section-head h2::after { display: none; }

.summary-text .section-head p { margin-top: 10px; letter-spacing: 1px; }

.summary-text p {
    font-size: 14px;
    line-height: 2.1;
    color: var(--ink-2);
    text-align: justify;
}

.summary-text p + p { margin-top: 16px; }

.summary-text .lead {
    font-size: 15.5px;
    line-height: 2.1;
    color: var(--ink);
}

.summary-figure {
    order: 2;
    position: relative;
    padding: 12px;
    background: var(--card);
    border: 1px solid var(--line);
    overflow: hidden;
    cursor: zoom-in;
    transition: box-shadow .45s var(--ease);
}

.summary-figure:hover { box-shadow: var(--shadow-hover); }

.summary-figure img {
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    transition: transform .9s var(--ease-out);
}

.summary-figure:hover img { transform: scale(1.03); }

.summary-figure figcaption {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid var(--line);
    font-family: var(--font-deco);
    font-size: 12.5px;
    letter-spacing: 2px;
    color: var(--ink-3);
    text-align: center;
}

/* ---------- 古籍引证 ---------- */
.quote-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.quote-card {
    position: relative;
    padding: 30px 26px 24px;
    background: var(--card);
    border: 1px solid var(--line);
    border-top: 2px solid rgba(140, 90, 58, .38);
    overflow: hidden;
    transition: transform .35s var(--ease), box-shadow .35s var(--ease),
                border-color .35s var(--ease);
}

.quote-card:hover {
    transform: translateY(-4px);
    border-color: rgba(140, 90, 58, .45);
    box-shadow: var(--shadow-2);
}

.quote-mark {
    position: absolute;
    right: 12px;
    top: -6px;
    font-family: var(--font-title);
    font-size: 84px;
    line-height: 1;
    color: rgba(140, 90, 58, .10);
    pointer-events: none;
    user-select: none;
}

.quote-card blockquote {
    position: relative;
    margin: 0 0 12px;
    padding-right: 18px;
    font-family: var(--font-deco);
    font-size: 16px;
    line-height: 2;
    color: var(--ink);
}

.quote-source {
    font-size: 12.5px;
    letter-spacing: 1px;
    color: var(--accent);
}

.quote-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 14px;
    padding: 0;
    font-family: var(--font-deco);
    font-size: 12.5px;
    letter-spacing: 3px;
    color: var(--ink-3);
    background: none;
    border: 0;
    cursor: pointer;
    transition: color .22s var(--ease);
}

.quote-toggle::before {
    content: "+";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    font-size: 13px;
    line-height: 1;
    border: 1px solid currentColor;
    border-radius: 50%;
}

.quote-toggle:hover { color: var(--accent-2); }

.quote-card.is-open .quote-toggle { color: var(--accent-2); }
.quote-card.is-open .quote-toggle::before { content: "−"; }

.quote-note {
    max-height: 0;
    margin-top: 0;
    padding-top: 0;
    overflow: hidden;
    font-size: 13px;
    line-height: 1.95;
    color: var(--ink-2);
    text-align: justify;
    border-top: 1px dashed transparent;
    opacity: 0;
    transition: max-height .45s var(--ease), opacity .35s var(--ease),
                margin-top .45s var(--ease), padding-top .45s var(--ease);
}

.quote-card.is-open .quote-note {
    max-height: 260px;
    margin-top: 12px;
    padding-top: 12px;
    border-top-color: var(--line);
    opacity: 1;
}

/* ---------- 名物源流 ---------- */
.flow-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 52px;
    max-width: 1280px;
    margin: 0 auto;
}

.flow-name {
    position: relative;
    margin-bottom: 24px;
    padding-bottom: 14px;
    font-family: var(--font-title);
    font-weight: 400;
    font-size: 26px;
    letter-spacing: 8px;
    text-indent: 8px;
    color: var(--accent-2);
    text-align: center;
}

.flow-name::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 40px;
    height: 2px;
    background: var(--accent);
    transform: translateX(-50%);
}

.flow-list {
    position: relative;
    padding-left: 26px;
}

.flow-list::before {
    content: "";
    position: absolute;
    left: 5px;
    top: 6px;
    bottom: 6px;
    width: 1px;
    background: var(--line);
}

.flow-node {
    position: relative;
    padding-bottom: 24px;
}

.flow-node:last-child { padding-bottom: 0; }

.flow-node::before {
    content: "";
    position: absolute;
    left: -26px;
    top: 7px;
    width: 11px;
    height: 11px;
    background: var(--card);
    border: 2px solid var(--accent);
    border-radius: 50%;
    transition: background .3s var(--ease), transform .3s var(--ease);
}

.flow-node:hover::before {
    background: var(--accent);
    transform: scale(1.15);
}

.flow-era {
    display: inline-block;
    margin-bottom: 5px;
    padding: 1px 11px;
    font-family: var(--font-deco);
    font-size: 12px;
    letter-spacing: 2px;
    color: var(--paper);
    background: var(--accent);
    border-radius: var(--r-sm);
}

.flow-title {
    margin-bottom: 2px;
    font-family: var(--font-title);
    font-size: 15px;
    line-height: 1.7;
    letter-spacing: 1px;
    color: var(--ink);
}

.flow-note {
    font-size: 12.5px;
    line-height: 1.8;
    color: var(--ink-3);
}

/* ---------- 响应式 ---------- */
@media (max-width: 1180px) {
    .summary { gap: 40px; }
    .flow-grid { gap: 36px; }
}

@media (max-width: 980px) {
    .quote-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
    .summary { grid-template-columns: 1fr; gap: 28px; }
    .summary-figure { order: 0; }
    .summary-text .section-head h2 { font-size: 26px; }
    .flow-grid { grid-template-columns: 1fr; gap: 34px; max-width: 560px; }
    .flow-name { text-align: left; padding-bottom: 10px; margin-bottom: 18px; }
    .flow-name::after { left: 0; transform: none; }
}

@media (max-width: 600px) {
    .quote-grid { grid-template-columns: 1fr; }
    .quote-card { padding: 24px 20px 20px; }
    .summary-figure { padding: 9px; }
}
