/* ============================================================
   大衍 DAYAN · 首页视觉系统
   主色：玄黑 / 鎏金 / 朱砂 / 青灰
   ============================================================ */
:root {
  --dy-bg:        #050607;
  --dy-bg-2:      #080A0D;
  --dy-panel:     #0A0C0E;
  --dy-gold:      #C8A96A;
  --dy-gold-hi:   #E7D3A1;
  --dy-gold-dim:  #8C7443;
  --dy-cinnabar:  #B33A2B;
  --dy-cinnabar-2:#D24B3A;
  --dy-cyan:      #6E7B82;
  --dy-cyan-dim:  #3E4A50;
  --dy-text:      #E9E6E0;
  --dy-text-2:    #A9A49B;
  --dy-text-3:    #6F6B65;
  --dy-line:      rgba(200,169,106,.16);
  --dy-line-soft: rgba(200,169,106,.09);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--dy-bg);
  color: var(--dy-text);
  overflow: hidden;
  font-family: "PingFang SC", "HarmonyOS Sans SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  cursor: default;
}

#dayanCanvas { position: fixed; inset: 0; width: 100%; height: 100%; display: block; z-index: 0; }
.dy-vignette {
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 44%, transparent 34%, rgba(0,0,0,.55) 100%),
    linear-gradient(180deg, rgba(0,0,0,.35) 0%, transparent 18%, transparent 82%, rgba(0,0,0,.45) 100%);
}

/* ---------------- 顶栏 ---------------- */
.dy-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 6;
  display: flex; align-items: center; justify-content: space-between;
  padding: 26px clamp(20px, 4vw, 52px);
}
.dy-brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; color: var(--dy-text); }
.dy-brand-mark {
  font-family: "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
  font-size: 19px; letter-spacing: .32em; text-indent: .32em;
  background: linear-gradient(180deg, #F1E3C2, #C8A96A 55%, #8C7443);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.dy-brand-sub {
  font-size: 10px; letter-spacing: .38em; color: var(--dy-text-3);
  text-transform: uppercase;
}
.dy-nav { display: flex; gap: clamp(14px, 2.4vw, 30px); }
.dy-nav a {
  position: relative; font-size: 12.5px; letter-spacing: .18em;
  color: var(--dy-text-2); text-decoration: none; padding: 4px 0;
  transition: color .35s ease;
}
.dy-nav a::after {
  content: ""; position: absolute; left: 0; right: .18em; bottom: -2px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--dy-gold), transparent);
  transform: scaleX(0); transform-origin: center; transition: transform .4s ease;
}
.dy-nav a:hover { color: var(--dy-gold-hi); }
.dy-nav a:hover::after { transform: scaleX(1); }

/* ---------------- 中央主视觉 ---------------- */
.dy-center {
  position: fixed; inset: 0; z-index: 4; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; transform: translateY(-2vh);
}
.dy-eyebrow {
  font-size: 11px; letter-spacing: .42em; text-indent: .42em;
  color: var(--dy-text-3); margin-bottom: clamp(20px, 3.4vh, 36px);
  opacity: 0; animation: dyFade 1.6s ease .5s forwards;
}
.dy-title {
  margin: 0; font-weight: 600;
  font-family: "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
  font-size: clamp(76px, 15vw, 188px);
  line-height: 1; letter-spacing: .34em; text-indent: .34em;
  background: linear-gradient(178deg, #F6ECD2 6%, #D9BE85 34%, #C8A96A 52%, #927A48 78%, #6E5A34 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 36px rgba(200,169,106,.18)) drop-shadow(0 2px 0 rgba(0,0,0,.5));
  opacity: 0; transform: translateY(18px) scale(.985);
  animation: dyTitleIn 2.6s cubic-bezier(.16,.84,.24,1) .25s forwards;
}
.dy-slogan {
  margin: clamp(22px, 3.6vh, 36px) 0 0;
  font-family: "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
  font-size: clamp(12px, 1.35vw, 15px);
  letter-spacing: .34em; text-indent: .34em;
  color: var(--dy-text-2);
  opacity: 0; animation: dyFade 1.8s ease 1.1s forwards;
}
.dy-center::before {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: min(58vw, 620px); height: min(58vw, 620px);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(200,169,106,.06), transparent 62%);
  filter: blur(6px); pointer-events: none; z-index: -1;
}

@keyframes dyTitleIn {
  0%   { opacity: 0; transform: translateY(22px) scale(.975); filter: blur(8px) drop-shadow(0 0 0 rgba(200,169,106,0)); }
  45%  { opacity: .85; filter: blur(1px) drop-shadow(0 0 42px rgba(200,169,106,.25)); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0) drop-shadow(0 0 36px rgba(200,169,106,.18)); }
}
@keyframes dyFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ---------------- 入局推演 ---------------- */
.dy-enter {
  position: fixed; left: 50%; bottom: clamp(96px, 17vh, 180px);
  transform: translateX(-50%); z-index: 7;
  display: inline-flex; align-items: center; gap: 16px;
  padding: 12px 2px; text-decoration: none;
  color: var(--dy-text); font-size: 14px; letter-spacing: .3em; text-indent: .3em;
  border-bottom: 1px solid rgba(200,169,106,.28);
  transition: color .4s ease, border-color .4s ease;
  opacity: 0; animation: dyFade 1.6s ease 1.7s forwards;
}
.dy-enter em {
  font-style: normal; font-size: 10px; letter-spacing: .34em;
  color: var(--dy-gold); opacity: .65; transition: opacity .4s, transform .4s;
}
.dy-enter::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--dy-gold-hi), transparent);
  transform: scaleX(0); transition: transform .5s cubic-bezier(.2,.7,.2,1);
}
.dy-enter:hover { color: var(--dy-gold-hi); border-color: rgba(200,169,106,.5); }
.dy-enter:hover::after { transform: scaleX(1); }
.dy-enter:hover em { opacity: 1; transform: translateX(3px); }

/* ---------------- 阶段字幕 ---------------- */
.dy-phase {
  position: fixed; left: 50%; bottom: clamp(40px, 8vh, 84px); transform: translateX(-50%);
  z-index: 5; display: inline-flex; align-items: center; gap: 10px;
  font-family: "Songti SC", "STSong", "Noto Serif SC", serif;
  font-size: 12px; letter-spacing: .26em; color: var(--dy-text-3);
  transition: opacity .8s ease; white-space: nowrap;
}
.dy-phase .dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--dy-gold); box-shadow: 0 0 10px rgba(200,169,106,.8);
  animation: dyPulse 2.4s ease-in-out infinite;
}
.dy-phase.breathe { opacity: .55; }
@keyframes dyPulse { 0%,100% { opacity: .35; transform: scale(.85); } 50% { opacity: 1; transform: scale(1.15); } }

/* ---------------- 角落 ---------------- */
.dy-citation {
  position: fixed; left: clamp(20px, 4vw, 52px); bottom: clamp(24px, 5vh, 48px); z-index: 7;
  display: inline-flex; align-items: center; gap: 10px;
  background: none; border: none; padding: 6px 0; cursor: pointer;
  color: var(--dy-text-3); font-size: 12px; letter-spacing: .2em;
  transition: color .35s ease;
}
.dy-citation::before {
  content: ""; width: 26px; height: 1px; background: rgba(200,169,106,.4);
  transition: width .4s ease, background .4s ease;
}
.dy-citation:hover { color: var(--dy-gold-hi); }
.dy-citation:hover::before { width: 40px; background: var(--dy-gold); }
.dy-meta {
  position: fixed; right: clamp(20px, 4vw, 52px); bottom: clamp(24px, 5vh, 48px); z-index: 7;
  font-size: 10.5px; letter-spacing: .22em; color: var(--dy-text-3);
  font-family: "Songti SC", serif;
}

/* ---------------- 哲学引子抽屉 ---------------- */
.dy-drawer {
  position: fixed; inset: 0; z-index: 30;
  display: flex; justify-content: flex-end;
  opacity: 0; pointer-events: none; transition: opacity .45s ease;
}
.dy-drawer.open { opacity: 1; pointer-events: auto; }
.dy-mask { position: absolute; inset: 0; background: rgba(3,4,5,.7); backdrop-filter: blur(7px); }
.dy-panel {
  position: relative; width: min(580px, 94vw); height: 100%;
  background: linear-gradient(180deg, #0A0C0E, #070809);
  border-left: 1px solid var(--dy-line);
  padding: clamp(30px, 5vh, 56px) clamp(26px, 4vw, 52px);
  overflow-y: auto;
  transform: translateX(36px); transition: transform .55s cubic-bezier(.16,.84,.24,1);
  box-shadow: -40px 0 120px rgba(0,0,0,.6);
  scrollbar-width: thin; scrollbar-color: rgba(200,169,106,.25) transparent;
}
.dy-drawer.open .dy-panel { transform: translateX(0); }
.dy-panel::-webkit-scrollbar { width: 5px; }
.dy-panel::-webkit-scrollbar-thumb { background: rgba(200,169,106,.25); border-radius: 3px; }
.dy-close {
  position: absolute; top: 18px; right: 20px;
  width: 34px; height: 34px; border: 1px solid var(--dy-line);
  background: none; color: var(--dy-text-2); font-size: 18px; line-height: 1;
  cursor: pointer; transition: .3s;
}
.dy-close:hover { color: var(--dy-gold-hi); border-color: rgba(200,169,106,.45); }
.dy-panel-eyebrow { font-size: 10px; letter-spacing: .4em; color: var(--dy-gold-dim); margin-bottom: 12px; }
.dy-panel h2 {
  margin: 0; font-family: "Songti SC", serif; font-weight: 600;
  font-size: 30px; letter-spacing: .22em; color: var(--dy-gold-hi);
}
.dy-intro { margin: 14px 0 30px; font-size: 13px; line-height: 2; color: var(--dy-text-2); }
.dy-panel section { padding-top: 26px; border-top: 1px solid var(--dy-line-soft); margin-top: 26px; }
.dy-panel section:first-of-type { border-top: none; margin-top: 0; padding-top: 0; }
.dy-panel h3 {
  margin: 0 0 14px; font-size: 12px; font-weight: 500; letter-spacing: .3em; color: var(--dy-text-2);
}
.dy-panel blockquote {
  margin: 0; padding: 16px 0 16px 20px;
  border-left: 1px solid rgba(200,169,106,.45);
  font-family: "Songti SC", "STSong", "Noto Serif SC", serif;
  font-size: clamp(16px, 2vw, 19px); line-height: 2.05; letter-spacing: .06em;
  color: var(--dy-gold-hi);
  background: linear-gradient(90deg, rgba(200,169,106,.05), transparent 70%);
}
.dy-note { margin: 14px 0 0; font-size: 13px; line-height: 2; color: var(--dy-text-2); }
.dy-steps { list-style: none; margin: 6px 0 0; padding: 0; }
.dy-steps li {
  display: grid; grid-template-columns: 1fr; gap: 3px;
  padding: 12px 0; border-bottom: 1px dashed var(--dy-line-soft);
}
.dy-steps b {
  font-size: 13px; font-weight: 500; letter-spacing: .16em; color: var(--dy-gold);
}
.dy-steps span { font-size: 12.5px; line-height: 1.9; color: var(--dy-text-2); }
.dy-panel-foot {
  margin-top: 34px; padding-top: 18px; border-top: 1px solid var(--dy-line-soft);
  font-family: "Songti SC", serif; font-size: 11px; letter-spacing: .34em;
  color: var(--dy-text-3); text-align: right;
}

/* ---------------- 悬浮提示 ---------------- */
.dy-tooltip {
  position: fixed; z-index: 12; pointer-events: none;
  padding: 7px 11px; font-size: 11px; letter-spacing: .14em;
  color: var(--dy-gold-hi);
  background: rgba(8,10,13,.92);
  border: 1px solid var(--dy-line);
  opacity: 0; transform: translateY(6px);
  transition: opacity .25s ease, transform .25s ease;
  white-space: nowrap;
}
.dy-tooltip.on { opacity: 1; transform: translateY(0); }

/* ---------------- 巨「道」水印 ---------------- */
.dy-ink {
  position: fixed; inset: 0; z-index: 1; display: flex;
  align-items: center; justify-content: center;
  pointer-events: none; overflow: hidden; mix-blend-mode: screen;
}
.dy-ink span {
  font-family: "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
  font-size: min(76vh, 76vw); line-height: .86; font-weight: 500;
  color: transparent;
  -webkit-text-stroke: 1px rgba(200,169,106,.11);
  background: linear-gradient(180deg, rgba(231,211,161,.10), rgba(200,169,106,.02) 60%, rgba(200,169,106,0));
  -webkit-background-clip: text; background-clip: text;
  filter: blur(.4px) drop-shadow(0 0 70px rgba(200,169,106,.10));
  transform: translateY(-1vh) scale(1);
  opacity: .7;
  animation: dyInkBreathe 16s ease-in-out infinite;
  will-change: transform, opacity;
}
.dy-ink::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 50% 52%, transparent 38%, rgba(5,6,7,.4) 100%);
}
@keyframes dyInkBreathe {
  0%, 100% { transform: translateY(-1vh) scale(.985); opacity: .45; }
  50%      { transform: translateY(-1vh) scale(1.05);  opacity: .85; }
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 760px) {
  .dy-header { padding: 20px 20px; }
  .dy-nav { gap: 14px; }
  .dy-nav a { font-size: 11.5px; letter-spacing: .12em; }
  .dy-brand-sub { display: none; }
  .dy-title { letter-spacing: .26em; text-indent: .26em; }
  .dy-slogan { font-size: 11.5px; letter-spacing: .2em; text-indent: .2em; }
  .dy-enter { bottom: 15vh; font-size: 13px; }
  .dy-phase { bottom: 9vh; font-size: 11px; letter-spacing: .16em; }
  .dy-citation { left: 20px; bottom: 18px; font-size: 11px; letter-spacing: .1em; }
  .dy-meta { display: none; }
  .dy-center { transform: translateY(-4vh); }
}
@media (prefers-reduced-motion: reduce) {
  .dy-title, .dy-eyebrow, .dy-slogan, .dy-enter { animation: none !important; opacity: 1 !important; transform: none !important; }
  .dy-phase .dot { animation: none; }
}