@import url('https://fonts.googleapis.com/css2?family=Noto+Naskh+Arabic:wght@400;500;600;700&family=Noto+Sans+Arabic:wght@300;400;500;700&display=swap');

:root{
  --ink:#000000;
  --paper:#ffffff;
  --line:#000000;
  --rail:15rem;
  --gut:clamp(1.25rem,5vw,5.5rem);
  --font:'Noto Sans Arabic','Noto Naskh Arabic',system-ui,-apple-system,'PingFang SC','Hiragino Sans GB','Microsoft YaHei',sans-serif;
  --ease:cubic-bezier(.2,.7,.25,1);
}

*,*::before,*::after{box-sizing:border-box}

html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}

body{
  margin:0;
  background:var(--paper);
  color:var(--ink);
  font-family:var(--font);
  font-size:1.0625rem;
  line-height:1.65;
  letter-spacing:.012em;
  overflow-x:hidden;
}

a{color:inherit}
img{max-width:100%;display:block}
:focus-visible{outline:2px solid var(--ink);outline-offset:3px}

/* ---------- 左侧竖排栏 ---------- */
.rail{
  position:fixed;
  top:0;left:0;bottom:0;
  width:var(--rail);
  display:flex;
  flex-direction:column;
  gap:2.5rem;
  padding:1.6rem 1.1rem;
  border-right:1px solid var(--line);
  background:var(--paper);
  z-index:30;
  overflow-y:auto;
}

.brand{
  display:inline-flex;
  align-items:center;
  min-height:2.75rem;
  text-decoration:none;
  font-weight:900;
  font-size:1.15rem;
  line-height:1.1;
  letter-spacing:-.045em;
}

.brand-img{width:2.75rem;height:2.75rem;object-fit:contain}

.brand-txt{display:block;padding:.2rem 0;word-break:break-word}

.rail-nav ul{list-style:none;margin:0;padding:0;display:grid;gap:.1rem}

.rail-nav a{
  display:flex;
  align-items:center;
  gap:.6rem;
  min-height:2.75rem;
  padding:.55rem .4rem;
  text-decoration:none;
  font-size:1rem;
  line-height:1.25;
  letter-spacing:0;
  border-radius:.55rem;
  transition:background .2s var(--ease),color .2s var(--ease),transform .25s var(--ease);
}

.ico{
  width:.6rem;height:.6rem;flex:none;
  border:1.5px solid currentColor;
  transition:transform .3s var(--ease),background .2s var(--ease),border-color .2s var(--ease);
}

.rail-nav li:nth-child(2n) .ico{border-radius:50%}

.rail-nav a:hover,
.rail-nav a:focus-visible{
  background:var(--ink);
  color:var(--paper);
  transform:translateX(.2rem);
}

.rail-nav a:hover .ico,
.rail-nav a:focus-visible .ico{background:var(--paper);border-color:var(--paper);transform:rotate(45deg)}

@keyframes rise{from{opacity:0;transform:translateY(.7rem)}to{opacity:1;transform:none}}
.rail-nav li{animation:rise .5s var(--ease) both}
.rail-nav li:nth-child(1){animation-delay:.04s}
.rail-nav li:nth-child(2){animation-delay:.09s}
.rail-nav li:nth-child(3){animation-delay:.14s}
.rail-nav li:nth-child(4){animation-delay:.19s}
.rail-nav li:nth-child(5){animation-delay:.24s}
.rail-nav li:nth-child(6){animation-delay:.29s}
.rail-nav li:nth-child(7){animation-delay:.34s}

/* ---------- 主体骨架 ---------- */
.shell{padding-left:var(--rail)}
main{padding:0 var(--gut)}

.hero{
  min-height:45vh;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
  gap:clamp(1.5rem,5vh,3rem);
  padding:clamp(1.75rem,7vh,4.5rem) 0 clamp(1.5rem,4vh,2.5rem);
  border-bottom:1px solid var(--line);
}

.hero h1{
  margin:0;
  font-weight:900;
  font-size:clamp(2.6rem,8.5vw,7.5rem);
  line-height:.92;
  letter-spacing:-.055em;
  max-width:16ch;
  text-wrap:balance;
}

.hero-media{
  margin:0;
  overflow:hidden;
  border:1px solid var(--line);
  border-radius:18px;
  background:#f2f2f2;
}

.hero-media:empty{display:none}

.hero-img{
  width:100%;
  height:clamp(9rem,30vh,20rem);
  object-fit:cover;
  filter:grayscale(1) contrast(1.08);
  transition:transform .6s var(--ease);
}

.hero-media:hover .hero-img{transform:scale(1.02)}

/* ---------- 正文区块 ---------- */
main > div:not(.hero){
  padding:clamp(3rem,10vh,8rem) 0;
  border-bottom:1px solid var(--line);
  scroll-margin-top:5.5rem;
}

main > div:not(.hero):last-child{border-bottom:0}

main h2{
  font-size:clamp(1.9rem,5.2vw,3.6rem);
  line-height:1.02;
  letter-spacing:-.045em;
  font-weight:900;
  margin:0 0 1rem;
  max-width:22ch;
}

main h3{
  font-size:clamp(1.25rem,2.6vw,1.6rem);
  font-weight:700;
  letter-spacing:-.02em;
  margin:2.5rem 0 .6rem;
  max-width:40ch;
}

main p{max-width:64ch;margin:0 0 1.15rem}

hr{
  border:0;
  border-top:1px solid var(--ink);
  margin:2rem 0;
}

main h2 + hr,
main h3 + hr{
  margin:0 0 2rem;
  border-top:2px solid var(--ink);
  width:min(100%,10rem);
}

main ul,main ol{max-width:64ch;padding-left:1.3rem;margin:0 0 1.3rem}
main li{margin:.45rem 0}

main a{
  text-decoration:underline;
  text-decoration-thickness:2px;
  text-underline-offset:3px;
}

main a:hover{background:var(--ink);color:var(--paper);text-decoration:none}

main blockquote{
  margin:2rem 0;
  padding-left:1.25rem;
  border-left:4px solid var(--ink);
  font-size:1.15rem;
  max-width:56ch;
}

main figure:not(.hero-media){
  margin:2rem 0;
  border:1px solid var(--ink);
  border-radius:18px;
  overflow:hidden;
}

main aside{
  border:1px solid var(--ink);
  border-radius:18px;
  padding:1.25rem 1.35rem;
  margin:2rem 0;
  max-width:60ch;
}

main code{font-size:.95em;background:#f1f1f1;padding:.1em .35em;border-radius:.3em}

main table{width:100%;border-collapse:collapse;font-size:1rem;margin:0 0 1.3rem}
main th,main td{border-bottom:1px solid var(--ink);padding:.6rem .5rem;text-align:left}
main th{font-weight:700}

/* ---------- 页脚 ---------- */
.colophon{
  background:var(--ink);
  color:var(--paper);
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);
  gap:clamp(2rem,6vw,5rem);
  padding:clamp(3rem,9vw,7rem) var(--gut) clamp(2rem,5vw,3.5rem);
  border-top:1px solid var(--line);
}

.colophon h2{
  margin:0 0 .8rem;
  font-size:1rem;
  font-weight:500;
  letter-spacing:.24em;
}

.colophon hr{
  border:0;
  border-top:1px solid rgba(255,255,255,.45);
  width:3rem;
  margin:0 0 1.25rem;
}

.foot-word{
  margin:0 0 1rem;
  font-weight:900;
  font-size:clamp(2.4rem,9vw,6rem);
  line-height:.86;
  letter-spacing:-.06em;
  word-break:break-word;
}

.foot-desc{
  margin:0;
  max-width:38ch;
  font-size:1rem;
  line-height:1.6;
  color:rgba(255,255,255,.74);
}

.foot-links ul{list-style:none;margin:0;padding:0;display:grid;gap:0}
.foot-links a{
  display:inline-flex;
  align-items:center;
  min-height:2.75rem;
  padding:.35rem 0;
  width:100%;
  text-decoration:none;
  border-bottom:1px solid rgba(255,255,255,.18);
  transition:padding-left .25s var(--ease),color .2s var(--ease);
}
.foot-links a:hover{padding-left:.55rem;color:#fff;text-decoration:underline;text-underline-offset:3px}

.foot-base{
  grid-column:1 / -1;
  margin-top:1rem;
  padding-top:1.5rem;
  border-top:1px solid rgba(255,255,255,.25);
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:center;
  gap:1rem;
  text-align:center;
  font-size:1rem;
}

.foot-base .copy{margin:0}

.to-top{
  display:inline-flex;
  align-items:center;
  min-height:2.75rem;
  text-decoration:none;
  border-bottom:1px solid currentColor;
}

.to-top:hover{background:var(--paper);color:var(--ink)}

/* ---------- 窄屏 ---------- */
@media (max-width:900px){
  .rail{
    position:sticky;
    top:0;right:0;bottom:auto;
    width:auto;
    flex-direction:row;
    align-items:center;
    gap:.9rem;
    padding:.45rem .8rem;
    border-right:0;
    border-bottom:1px solid var(--line);
    overflow:visible;
  }

  .brand{flex:none;font-size:1rem;min-height:2.75rem}
  .brand-img{width:2.25rem;height:2.25rem}

  .rail-nav{flex:1 1 auto;min-width:0;overflow-x:auto;scrollbar-width:none}
  .rail-nav::-webkit-scrollbar{display:none}
  .rail-nav ul{display:flex;gap:.15rem}
  .rail-nav a{white-space:nowrap;padding:.5rem .55rem;font-size:1rem}
  .rail-nav a:hover{transform:none}

  .shell{padding-left:0}
  .hero{min-height:0;padding-top:2rem}
  .hero h1{font-size:clamp(2.3rem,10vw,3.4rem)}
  .hero-img{height:clamp(8rem,26vh,14rem)}

  main > div:not(.hero){padding:clamp(2.25rem,7vh,3.5rem) 0;scroll-margin-top:6rem}

  .colophon{grid-template-columns:1fr;padding-inline:1.1rem}
  .foot-word{font-size:clamp(2.2rem,12vw,3.4rem)}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{
    animation-duration:.001ms !important;
    animation-delay:0ms !important;
    transition-duration:.001ms !important;
  }
}
</｜DSML｜ parameter>
</｜DSML｜ invoke>
</｜DSML｜ calls>

button[aria-expanded]{min-width:44px;min-height:44px}
