/* CSO ZvsP: motion is decorative and never changes page or control visibility. */
html.china-world { background: #101216; color-scheme: dark; }
body.china-portal { --fx-gold: 255, 204, 25; }
.world-effects-toggle {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 11px;
  border: 1px solid #635534; border-radius: 4px; background: #1e211f;
  color: #ddce9e; font: inherit; font-size: 12px; cursor: pointer;
}
.world-effects-toggle::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #8e9198; }
.world-effects-toggle[aria-pressed="true"]::before { background: #ffcc19; box-shadow: 0 0 9px #ffcc1950; }
.world-effects-toggle:hover { color: #ffe59b; border-color: #b39650; }
.world-effects-toggle:focus-visible { outline: 2px solid #ffcc19; outline-offset: 4px; }
.world-ambience { position: absolute; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; contain: strict; opacity: 0; }
body[data-world-effects="on"] .world-ambience { opacity: 1; }
.world-ambience::before {
  content: ""; position: absolute; inset: -15%;
  background: radial-gradient(ellipse at 74% 43%, #dab44a14, transparent 49%),
              linear-gradient(113deg, transparent 45%, #ffcf5d05 47%, #fff2b413 48%, transparent 51%);
  transform: translate3d(-3%, 0, 0); animation: world-light-drift 18s ease-in-out infinite alternate;
}
.world-ambience::after {
  content: ""; position: absolute; left: 6%; right: 5%; bottom: 0; height: 1px;
  background: linear-gradient(90deg, transparent, #b6933c, #ffe9a3, #b6933c, transparent);
  box-shadow: 0 -2px 22px #ffcc1926; opacity: .8;
}
.world-ember {
  position: absolute; left: var(--ember-x); top: var(--ember-y); width: var(--ember-size); height: var(--ember-size);
  border-radius: 50%; background: #e8cb7f; box-shadow: 0 0 9px #d5b05365;
  animation: world-ember-rise var(--ember-duration) linear infinite;
  animation-delay: var(--ember-delay); opacity: 0;
}
body[data-world-effects="on"] #home-title em { animation: world-title-glow 9s ease-in-out infinite alternate; }
body[data-world-effects="on"] .hero .btn-accent {
  box-shadow: 0 6px 26px #ffcc1920, inset 0 1px #fff2aa66;
  transition: transform .2s ease, box-shadow .2s ease;
}
body[data-world-effects="on"] .hero .btn-accent:hover { transform: translateY(-2px); box-shadow: 0 9px 32px #ffcc1938, inset 0 1px #fff2aa99; }
body[data-world-effects="on"] .nav-inner > a { transition: color .18s ease, background-color .18s ease, border-color .18s ease; }
body[data-world-effects="on"] :is(.quick-card, .news-card, .event-card, .item-card, .roadmap-task) {
  background-image: radial-gradient(220px circle at var(--world-pointer-x, 50%) var(--world-pointer-y, 0%), #ffdc650a, transparent 72%);
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
body[data-world-effects="on"] :is(.quick-card, .item-card):hover { transform: translateY(-3px); box-shadow: 0 9px 24px #00000035, 0 0 0 1px #d4b24c20; }
body[data-world-effects="on"] .page.world-page-enter:not([hidden]) { animation: world-page-enter .42s cubic-bezier(.2,.7,.25,1) both; }
body[data-world-motion="paused"] .world-ambience::before,
body[data-world-motion="paused"] :is(.world-ember, #home-title em) { animation-play-state: paused; }
body[data-world-effects="off"] .world-ambience::before,
body[data-world-effects="off"] :is(.world-ember, #home-title em) { animation: none; }
body[data-world-effects="off"] .world-ambience { display: none; }
@keyframes world-light-drift { to { transform: translate3d(4%, -2%, 0); opacity: .55; } }
@keyframes world-ember-rise {
  0% { transform: translate3d(0, 24px, 0); opacity: 0; }
  18% { opacity: .42; }
  78% { opacity: .2; }
  100% { transform: translate3d(18px, -115px, 0); opacity: 0; }
}
@keyframes world-title-glow { from { text-shadow: 0 0 12px #ffcc1900; } to { text-shadow: 0 0 25px #ffcc1922; } }
@keyframes world-page-enter { from { opacity: .4; transform: translateY(9px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 700px) {
  .world-ember:nth-child(n+7) { display: none; }
  .world-ambience::before { animation-duration: 24s; }
  .world-effects-toggle { padding: 9px 12px; }
}
@media (hover: none), (pointer: coarse) {
  body[data-world-effects="on"] :is(.quick-card, .news-card, .event-card, .item-card, .roadmap-task) { background-image: none; }
}
@media (prefers-reduced-motion: reduce) {
  .world-ambience { display: none !important; }
  body.china-portal :is(.page.world-page-enter, #home-title em, .hero .btn-accent, .quick-card, .news-card, .event-card, .item-card, .roadmap-task) { animation: none !important; transition: none !important; transform: none !important; }
}
@media (forced-colors: active) {
  html.china-world { background: Canvas; color-scheme: light dark; }
  .world-ambience { display: none !important; }
  .world-effects-toggle { color: ButtonText; border-color: ButtonText; background: ButtonFace; }
  .world-effects-toggle::before { background: ButtonText !important; box-shadow: none !important; }
  body[data-world-effects="on"] :is(.quick-card, .news-card, .event-card, .item-card, .roadmap-task) { background-image: none; box-shadow: none; }
}
