/* ============================================================
   京华五境 · 北京旅游景点推荐
   画幅：1350 × 1340（首屏），正文 ≥ 22px
   ============================================================ */
:root {
  --paper: #f5efe1;
  --paper-2: #efe6d1;
  --card: #fffdf6;
  --ink: #2b241b;
  --ink-2: #6d6250;
  --ink-3: #8a7a5f;
  --red: #a12a28;
  --red-deep: #7e1f1e;
  --gold: #b98a2f;
  --gold-soft: #d8b46a;
  --line: #e2d7c2;
  --dark: #1d1712;
  --serif: "STZhongsong", "华文中宋", "SimSun", "宋体", serif;
  --sans: "Microsoft YaHei", "微软雅黑", "PingFang SC", "Segoe UI", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 108px;
}

body {
  background: #171310;
  color: var(--ink);
  font: 400 22px/1.85 var(--sans);
  min-width: 1350px;
}

img { display: block; max-width: 100%; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
b { font-weight: 700; }

::selection { background: rgba(161, 42, 40, .85); color: #fff6e8; }

:focus-visible { outline: 3px solid var(--gold-soft); outline-offset: 2px; }

main, .hero, .topbar { width: 1350px; margin-inline: auto; }

/* ---------------- 顶部导航 ---------------- */
.topbar {
  position: fixed;
  top: 0; left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  height: 92px;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 0 40px;
  background: linear-gradient(180deg, rgba(18, 12, 8, .82), rgba(18, 12, 8, .62));
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(216, 180, 106, .25);
}

.brand { display: flex; align-items: center; gap: 14px; white-space: nowrap; }
.seal {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  background: var(--red);
  border: 2px solid var(--gold-soft);
  border-radius: 10px;
  color: #f9ecd4;
  font: 700 28px/1 var(--serif);
  box-shadow: 0 4px 14px rgba(0, 0, 0, .35);
}
.brand-name { font: 700 28px/1 var(--serif); color: #f3e7cf; letter-spacing: .06em; }

.nav-links { display: flex; gap: 2px; margin-left: auto; }
.nav-links a {
  display: block;
  padding: 8px 13px 10px;
  font-size: 23px;
  white-space: nowrap;
  color: rgba(244, 235, 220, .82);
  border-bottom: 3px solid transparent;
  transition: color .25s, border-color .25s;
}
.nav-links a:hover { color: #fff; }
.nav-links a.active { color: #f7d99a; border-color: #c9a44e; }

.trip-toggle {
  font: 700 22px/1 var(--sans);
  color: #f7d99a;
  background: rgba(161, 42, 40, .55);
  border: 1px solid rgba(216, 180, 106, .6);
  border-radius: 999px;
  padding: 12px 22px;
  cursor: pointer;
  transition: background .25s;
}
.trip-toggle:hover { background: rgba(161, 42, 40, .85); }
.trip-toggle b { font-size: 24px; }
.trip-total { color: rgba(247, 217, 154, .6); }

/* ---------------- 首屏（1350 × 1340） ---------------- */
.hero {
  position: relative;
  height: 1340px;
  overflow: hidden;
  background: url("../images/gugong-hero.jpg") center 38% / cover no-repeat #26201a;
  color: #f7eeda;
}

.hero-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(18, 12, 8, .48) 0%, rgba(18, 12, 8, .10) 26%,
                    rgba(18, 12, 8, .04) 46%, rgba(18, 12, 8, .30) 68%, rgba(18, 12, 8, .78) 100%),
    linear-gradient(90deg, rgba(18, 12, 8, .30) 0%, rgba(18, 12, 8, 0) 42%);
}

.hero-inner { position: relative; padding: 196px 96px 0; }

.kicker {
  display: inline-block;
  font-size: 24px;
  letter-spacing: .34em;
  color: var(--gold-soft);
  border-left: 4px solid var(--red);
  padding-left: 18px;
}

.hero h1 {
  margin-top: 26px;
  font: 700 132px/1.16 var(--serif);
  letter-spacing: .07em;
  color: #f9efd9;
  text-shadow: 0 6px 34px rgba(0, 0, 0, .5);
}

.hero-sub {
  margin-top: 18px;
  font-size: 30px;
  line-height: 1.9;
  color: rgba(249, 239, 217, .92);
  text-shadow: 0 2px 14px rgba(0, 0, 0, .5);
}

.hero-cta { display: flex; gap: 22px; margin-top: 40px; }
.btn {
  display: inline-block;
  padding: 16px 46px;
  border-radius: 999px;
  font: 700 24px/1.4 var(--sans);
  transition: transform .25s, box-shadow .25s, background .25s;
}
.btn:hover { transform: translateY(-3px); }
.btn-primary {
  background: linear-gradient(180deg, #b23431, var(--red-deep));
  color: #ffe9c4;
  border: 1px solid rgba(216, 180, 106, .8);
  box-shadow: 0 10px 26px rgba(126, 31, 30, .45);
}
.btn-ghost {
  color: #f4ead2;
  border: 1.5px solid rgba(244, 234, 210, .6);
  background: rgba(18, 12, 8, .25);
}
.btn-ghost:hover { background: rgba(18, 12, 8, .45); }

.hero-stats { display: flex; margin-top: 52px; }
.hero-stats li {
  padding: 0 40px;
  border-left: 1px solid rgba(249, 239, 217, .28);
}
.hero-stats li:first-child { padding-left: 0; border-left: none; }
.hero-stats b {
  display: block;
  font: 700 46px/1.3 var(--serif);
  color: var(--gold-soft);
}
.hero-stats span { font-size: 22px; color: rgba(249, 239, 217, .78); }

.hero-vert {
  position: absolute;
  top: 210px; right: 54px;
  writing-mode: vertical-rl;
  font: 500 26px/1 var(--serif);
  letter-spacing: .5em;
  color: rgba(249, 239, 217, .55);
}

.hero-credit {
  position: absolute;
  right: 56px; bottom: 336px;
  font-size: 22px;
  color: rgba(249, 239, 217, .52);
}

.spot-cards {
  position: absolute;
  left: 48px; right: 48px; bottom: 48px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}
.spot-card {
  background: rgba(20, 14, 10, .58);
  border: 1px solid rgba(249, 239, 217, .16);
  border-radius: 18px;
  padding: 12px 14px 16px;
  color: #f7eeda;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: transform .3s, border-color .3s, box-shadow .3s;
}
.spot-card:hover {
  transform: translateY(-8px);
  border-color: rgba(216, 180, 106, .8);
  box-shadow: 0 16px 34px rgba(0, 0, 0, .4);
}
.sc-img { display: block; border-radius: 12px; overflow: hidden; height: 148px; }
.sc-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.spot-card:hover .sc-img img { transform: scale(1.06); }
.spot-card b { display: block; margin-top: 12px; font-size: 25px; }
.spot-card > span { display: block; font-size: 22px; color: rgba(247, 238, 218, .72); line-height: 1.6; }

/* ---------------- 景点区块 ---------------- */
.spot {
  padding: 92px 72px 80px;
  background: var(--paper);
  border-top: 1px solid var(--line);
}
.spot.flip { background: var(--paper-2); }

.spot-head { display: flex; align-items: flex-end; gap: 26px; }
.spot-no {
  font: 700 118px/0.9 var(--serif);
  color: rgba(161, 42, 40, .16);
  letter-spacing: 0;
  user-select: none;
}
.spot-title h2 {
  font: 700 52px/1.3 var(--serif);
  letter-spacing: .04em;
}
.spot-tags {
  margin-top: 6px;
  font-size: 22px;
  letter-spacing: .06em;
  color: var(--ink-3);
}
.trip-add {
  margin-left: auto;
  flex: none;
  align-self: center;
  font: 700 22px/1 var(--sans);
  color: var(--red);
  background: transparent;
  border: 2px solid var(--red);
  border-radius: 999px;
  padding: 14px 28px;
  cursor: pointer;
  transition: background .25s, color .25s, transform .2s;
}
.trip-add:hover { transform: translateY(-2px); background: rgba(161, 42, 40, .08); }
.trip-add.added {
  background: var(--red);
  color: #ffedd0;
}

.spot-body {
  display: grid;
  grid-template-columns: 620px 1fr;
  gap: 52px;
  margin-top: 44px;
  align-items: start;
}
.spot.flip .spot-body { grid-template-columns: 1fr 620px; }
.spot.flip .spot-photo { order: 2; }

.spot-photo { position: relative; }
.spot-photo img {
  width: 100%;
  height: 470px;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 22px 46px rgba(43, 36, 27, .22);
  cursor: zoom-in;
}
.spot-photo figcaption,
.gal-thumbs figcaption,
.gal-wide figcaption {
  margin-top: 14px;
  font-size: 22px;
  color: var(--ink-3);
  padding-left: 18px;
  position: relative;
}
.spot-photo figcaption::before,
.gal-thumbs figcaption::before,
.gal-wide figcaption::before {
  content: "";
  position: absolute;
  left: 0; top: 14px;
  width: 8px; height: 8px;
  background: var(--gold);
  transform: rotate(45deg);
}

.spot-desc {
  font-size: 24px;
  line-height: 2.05;
  color: #3a3227;
  text-align: justify;
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 30px;
}
.info-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px 24px 18px;
  box-shadow: 0 6px 18px rgba(43, 36, 27, .06);
}
.info-card.wide { grid-column: 1 / -1; }
.info-card h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 700;
  color: var(--red);
  letter-spacing: .04em;
}
.info-card h3 svg {
  width: 26px; height: 26px;
  fill: none;
  stroke: var(--red);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.info-main {
  margin-top: 8px;
  font: 700 29px/1.5 var(--serif);
  color: var(--ink);
}
.info-sub {
  margin-top: 6px;
  font-size: 22px;
  line-height: 1.78;
  color: var(--ink-2);
}
.info-sub b { color: var(--red-deep); }

/* 图库 */
.spot-gallery { margin-top: 42px; }
.gal-wide img {
  width: 100%;
  height: 296px;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 16px 34px rgba(43, 36, 27, .16);
  cursor: zoom-in;
}
.gal-thumbs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 24px;
}
.gal-thumbs.two { grid-template-columns: 1fr 1fr; }
.gal-thumbs.three { grid-template-columns: repeat(3, 1fr); }
.gal-thumbs figure img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0 12px 26px rgba(43, 36, 27, .14);
  cursor: zoom-in;
  transition: transform .45s;
}
.gal-thumbs.three figure img { height: 264px; }

/* ---------------- 行程参考 ---------------- */
.route {
  background: #241c13;
  color: #f0e6d0;
  padding: 92px 72px 96px;
  border-top: 4px solid var(--gold);
}
.sec-head h2 {
  font: 700 46px/1.4 var(--serif);
  letter-spacing: .05em;
}
.sec-head p { margin-top: 10px; font-size: 22px; color: rgba(240, 230, 208, .72); }
.route .sec-head h2 { color: #f3e7cf; }

.route-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  margin-top: 48px;
}
.route-card {
  background: rgba(255, 251, 240, .045);
  border: 1px solid rgba(214, 178, 106, .35);
  border-radius: 20px;
  padding: 34px 32px 28px;
}
.route-day {
  display: inline-block;
  font: 700 40px/1 var(--serif);
  color: var(--gold-soft);
  border-bottom: 3px solid rgba(216, 180, 106, .5);
  padding-bottom: 12px;
}
.route-card h3 {
  margin-top: 18px;
  font: 700 30px/1.5 var(--serif);
  color: #f7eeda;
}
.route-card ol { margin-top: 14px; }
.route-card li {
  position: relative;
  padding-left: 26px;
  margin-top: 12px;
  font-size: 22px;
  line-height: 1.8;
  color: rgba(240, 233, 216, .88);
}
.route-card li::before {
  content: "";
  position: absolute;
  left: 2px; top: 15px;
  width: 8px; height: 8px;
  background: var(--gold);
  transform: rotate(45deg);
}
.route-card li b { color: #f7d99a; margin-right: 8px; }
.route-note {
  margin-top: 20px;
  font-size: 22px;
  color: #b99e66;
  border-top: 1px dashed rgba(214, 178, 106, .4);
  padding-top: 14px;
}

/* ---------------- 实用贴士 ---------------- */
.tips { padding: 92px 72px 60px; background: var(--paper); }
.tips-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 44px;
}
.tip-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 5px solid var(--red);
  border-radius: 16px;
  padding: 26px 30px;
  box-shadow: 0 8px 20px rgba(43, 36, 27, .07);
}
.tip-card h3 {
  font: 700 27px/1.5 var(--serif);
  color: var(--red-deep);
}
.tip-card p { margin-top: 10px; font-size: 22px; line-height: 1.85; color: #4a4133; }
.tip-card b { color: var(--red-deep); }

/* ---------------- 页脚 ---------------- */
.foot {
  background: var(--dark);
  color: rgba(240, 230, 208, .82);
  padding: 66px 72px;
  text-align: center;
}
.foot-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-size: 26px;
}
.foot-brand b { font: 700 30px/1 var(--serif); color: #f3e7cf; letter-spacing: .06em; }
.foot-brand .seal { width: 46px; height: 46px; font-size: 24px; }
.foot p { margin-top: 16px; font-size: 22px; line-height: 1.8; color: rgba(240, 230, 208, .66); }
.foot a { color: var(--gold-soft); text-decoration: underline; text-underline-offset: 5px; }

/* ---------------- 行程单 ---------------- */
.trip-bar { position: fixed; right: 36px; bottom: 36px; z-index: 70; }
.trip-pill {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
  font: 700 23px/1 var(--sans);
  color: #ffedd0;
  background: var(--red-deep);
  border: 2px solid var(--gold-soft);
  border-radius: 999px;
  padding: 16px 28px;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .35);
}
.trip-pill svg {
  width: 26px; height: 26px;
  fill: none; stroke: #ffedd0; stroke-width: 1.8;
  stroke-linejoin: round;
}
.trip-pill b { font-size: 26px; color: #ffe9a8; }

.trip-panel {
  width: 480px;
  margin-bottom: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
  padding: 26px 28px 22px;
}
.trip-panel h3 { font: 700 28px/1.4 var(--serif); color: var(--ink); }
.trip-hint { margin-top: 6px; font-size: 22px; color: var(--ink-3); }
#tripList { margin-top: 14px; }
#tripList li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px dashed var(--line);
  font-size: 24px;
}
#tripList .seq {
  flex: none;
  width: 34px; height: 34px;
  display: grid; place-items: center;
  background: rgba(161, 42, 40, .1);
  color: var(--red);
  border-radius: 50%;
  font: 700 22px/1 var(--serif);
}
#tripList .arrow { color: var(--gold); font-size: 22px; margin-left: auto; }
#tripList .rm {
  flex: none;
  width: 34px; height: 34px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  border-radius: 50%;
  font-size: 22px;
  cursor: pointer;
}
#tripList .rm:hover { color: var(--red); border-color: var(--red); }
.trip-empty { margin-top: 14px; font-size: 22px; color: var(--ink-3); line-height: 1.7; }
.trip-actions { display: flex; gap: 12px; margin-top: 18px; }
.trip-actions button {
  font: 700 22px/1 var(--sans);
  padding: 12px 24px;
  border-radius: 999px;
  cursor: pointer;
}
#tripClear { color: var(--red); background: rgba(161, 42, 40, .07); border: 1px solid rgba(161, 42, 40, .4); }
#tripClose { color: var(--ink-2); background: transparent; border: 1px solid var(--line); }

/* ---------------- 回到顶部 ---------------- */
.totop {
  position: fixed;
  right: 44px; bottom: 128px;
  z-index: 65;
  width: 58px; height: 58px;
  border-radius: 50%;
  border: 2px solid var(--gold-soft);
  background: rgba(29, 23, 18, .85);
  color: #f7d99a;
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(0, 0, 0, .3);
  transition: transform .2s;
}
.totop:hover { transform: translateY(-4px); }

/* ---------------- 灯箱 ---------------- */
.lightbox {
  position: fixed; inset: 0;
  z-index: 90;
  background: rgba(12, 8, 5, .92);
  display: grid;
  place-items: center;
}
.lightbox img {
  max-width: 1240px;
  max-height: 1080px;
  border-radius: 10px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6);
}
.lightbox figcaption {
  text-align: center;
  margin-top: 18px;
  font-size: 24px;
  color: #f0e6d0;
}
.lb-close {
  position: absolute;
  top: 30px; right: 40px;
  width: 58px; height: 58px;
  border-radius: 50%;
  border: 2px solid rgba(240, 230, 208, .5);
  background: rgba(12, 8, 5, .5);
  color: #f0e6d0;
  font-size: 26px;
  cursor: pointer;
}
.lb-close:hover { border-color: var(--gold-soft); color: var(--gold-soft); }

/* ---------------- 动效 ---------------- */
.js .reveal { opacity: 0; transform: translateY(28px); }
.js .reveal.on {
  opacity: 1;
  transform: none;
  transition: opacity .75s ease, transform .75s ease;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  * { transition: none !important; }
}
