@charset "UTF-8";
:root {
  --bg: #fffbef;
  --fg: #3a2c00;
  --muted: #8f7a45;
  --ink: #fece0e;
  --track: rgba(254, 206, 14, .22);
  --card: #fff;
  --size: min(64vw, 42svh, 340px);
  --delay: 2600ms;
  color-scheme: light dark;
}
* { box-sizing: border-box; margin: 0; }
body {
  width: 100%; height: 100vh; height: 100dvh; min-height: 240px;
  display: grid; place-items: center;
  padding: max(24px, env(safe-area-inset-top)) 16px max(56px, env(safe-area-inset-bottom));
  overflow: hidden; background: var(--bg); color: var(--fg);
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent;
}
button { font: inherit; touch-action: manipulation; }
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
body.choosing, body.leaving { cursor: default; }
html:not(.js) .intro { display: none; }
.intro { display: flex; flex-direction: column; align-items: center; gap: 32px; text-align: center; transition: opacity .45s ease-in, transform .45s ease-in; }
.choosing .intro, .leaving .intro { opacity: 0; transform: scale(1.08); pointer-events: none; }
.badge { position: relative; width: var(--size); aspect-ratio: 1; }
.badge::before { content: ""; position: absolute; inset: 1.4%; border-radius: 50%; background: #fff; }
.badge .ring { position: absolute; inset: 0; width: 100%; height: 100%; }
.badge .core { position: absolute; inset: 19%; width: 62%; height: 62%; object-fit: contain; }
.progress { position: absolute; inset: -5.5%; width: 111%; height: 111%; transform: rotate(-90deg); overflow: visible; }
.progress circle { fill: none; stroke-width: 1.1; stroke-linecap: round; }
.progress .track { stroke: var(--track); }
.progress .bar { stroke: var(--ink); stroke-dasharray: 100; stroke-dashoffset: 100; }
.copy { display: flex; flex-direction: column; align-items: center; gap: 10px; }
h1 { font-size: clamp(26px, 7vw, 40px); font-weight: 800; letter-spacing: .12em; padding-left: .12em; }
.status { font-size: clamp(14px, 4vw, 17px); line-height: 1.65; }
.dots i { display: inline-block; width: .3em; height: .3em; margin-left: .18em; border-radius: 50%; background: currentColor; vertical-align: middle; animation: dot 1s ease-in-out infinite; }
.dots i:nth-child(2) { animation-delay: .15s; }
.dots i:nth-child(3) { animation-delay: .3s; }
.hint { border: 0; background: none; padding: 8px 14px; color: var(--muted); font-size: 13px; cursor: pointer; border-radius: 999px; }
.hint:hover, .hint:focus-visible { color: var(--fg); background: var(--track); }
.hint:focus-visible, .about-btn:focus-visible, .about a:focus-visible, .about button:focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; }
.demo-note { font-size: 11px; line-height: 1.5; color: var(--muted); padding-inline: 16px; }

/* Four infinite 90-degree wedges. Their clipping planes extend beyond the viewport. */
.sectors { --period: 160s; --spin-delay: calc(var(--period) * var(--spin-at, 0) * -1); position: fixed; inset: 0; z-index: 1; overflow: hidden; background: #15120a; }
.js .sectors { opacity: 0; visibility: hidden; transition: opacity .6s ease .2s, visibility 0s .8s; }
.choosing .sectors, .leaving .sectors { opacity: 1; visibility: visible; transition: opacity .6s ease .2s, visibility 0s; }
.wheel { position: absolute; inset: 0; }
.choosing .wheel, .leaving .wheel { animation: spin var(--period) linear var(--spin-delay) infinite; }
.sector { position: absolute; inset: 0; color: #fff; text-decoration: none; cursor: pointer; outline: none; transition: opacity .35s; }
.sector.top { clip-path: polygon(50% 50%, calc(50% - 150vmax) calc(50% - 150vmax), calc(50% + 150vmax) calc(50% - 150vmax)); }
.sector.right { clip-path: polygon(50% 50%, calc(50% + 150vmax) calc(50% - 150vmax), calc(50% + 150vmax) calc(50% + 150vmax)); }
.sector.bottom { clip-path: polygon(50% 50%, calc(50% + 150vmax) calc(50% + 150vmax), calc(50% - 150vmax) calc(50% + 150vmax)); }
.sector.left { clip-path: polygon(50% 50%, calc(50% - 150vmax) calc(50% + 150vmax), calc(50% - 150vmax) calc(50% - 150vmax)); }
.sector::before { content: ""; position: absolute; inset: -150vmax; background: #263e45; }
.sector.right::before { background: #4d382a; }
.sector.bottom::before { background: #253c31; }
.sector.left::before { background: #303b4a; }
.sector img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; filter: brightness(.78); transition: filter .35s, scale .9s cubic-bezier(.2, .7, .2, 1); }
.sector.top img { object-position: center 38%; }
.sector.right img { object-position: center 45%; }
.js .sector img { scale: 1.08; }
.choosing .sector img, .leaving .sector img { scale: 1; animation: unspin var(--period) linear var(--spin-delay) infinite; }
.sector:hover img, .sector:focus-visible img { filter: none; scale: 1.03; }
@media (hover: hover) and (pointer: fine) {
  .sectors:hover .sector:not(:hover) img { filter: brightness(.5) saturate(.7); }
}
.sector.image-failed img { visibility: hidden; }
.sector-label { --d: 27vmin; position: absolute; translate: -50% -50%; padding: 10px 20px; border-radius: 14px; text-align: center; white-space: nowrap; background: rgba(20, 16, 5, .68); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); transition: background-color .25s, color .25s, scale .25s; }
.choosing .sector-label, .leaving .sector-label { animation: unspin var(--period) linear var(--spin-delay) infinite; }
.sector-label small { display: block; font-size: clamp(12px, 1vw, 14px); line-height: 1.4; letter-spacing: .08em; opacity: .85; }
.sector-label b { display: block; font-size: clamp(18px, 3vw, 34px); line-height: 1.4; letter-spacing: .08em; }
.sector.top .sector-label { left: 50%; top: calc(50% - var(--d)); }
.sector.right .sector-label { left: calc(50% + var(--d)); top: 50%; }
.sector.bottom .sector-label { left: 50%; top: calc(50% + var(--d)); }
.sector.left .sector-label { left: calc(50% - var(--d)); top: 50%; }
.sector:hover .sector-label, .sector:focus-visible .sector-label, .sector.picked .sector-label { background: var(--ink); color: #3a2c00; scale: 1.06; }
.sector:focus-visible .sector-label { outline: 3px solid #fff; outline-offset: 5px; }
.ray { position: absolute; left: 50%; top: 50%; width: 150vmax; height: 4px; margin-top: -2px; background: var(--ink); box-shadow: 0 0 10px rgba(0, 0, 0, .45); transform-origin: 0 50%; transform: rotate(var(--a)); pointer-events: none; }
.ray-one { --a: 45deg; }.ray-two { --a: 135deg; }.ray-three { --a: 225deg; }.ray-four { --a: 315deg; }
.js .ray { transform: rotate(var(--a)) scaleX(0); }
.choosing .ray, .leaving .ray { animation: ray .7s cubic-bezier(.2, .7, .2, 1) .3s forwards; }
.hub { position: absolute; left: 50%; top: 50%; width: clamp(64px, 11vmin, 96px); aspect-ratio: 1; border: 4px solid var(--ink); border-radius: 50%; pointer-events: none; overflow: hidden; background: #fff; box-shadow: 0 6px 24px rgba(0, 0, 0, .4); transform: translate(-50%, -50%); }
.hub img { width: 100%; height: 100%; object-fit: contain; padding: 1px; }
.js .hub { transform: translate(-50%, -50%) scale(0); }
.choosing .hub, .leaving .hub { animation: hub .5s cubic-bezier(.34, 1.56, .64, 1) .2s forwards; }
.leaving .sector:not(.picked), .leaving .ray, .leaving .hub { opacity: 0; transition: opacity .35s; }
.leaving .sector.picked img { filter: none; scale: 1.1; }
.leaving .wheel, .leaving .sector img, .leaving .sector-label { animation-play-state: paused; }

.about-btn { position: fixed; z-index: 2; right: max(8px, env(safe-area-inset-right)); bottom: max(8px, env(safe-area-inset-bottom)); padding: 8px 10px; border: 0; border-radius: 999px; background: none; color: var(--muted); font-size: 13px; cursor: pointer; text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 3px; transition: color .2s, background-color .2s, opacity .3s; }
.about-btn:hover { color: var(--fg); text-decoration-color: currentColor; }
.choosing .about-btn { padding: 6px 14px; background: rgba(20, 16, 5, .65); color: #fff; }
.leaving .about-btn { opacity: 0; pointer-events: none; }
.about { width: min(390px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); overflow-y: auto; margin: auto; padding: 0; border: 0; border-radius: 16px; background: var(--card); color: var(--fg); box-shadow: 0 18px 50px rgba(0, 0, 0, .25); cursor: auto; user-select: text; }
.about[open] { animation: rise .25s ease-out; }
.about::backdrop { background: rgba(20, 16, 5, .45); backdrop-filter: blur(3px); }
.about-body { padding: 24px 22px 18px; }
.about h2 { font-size: 18px; margin-bottom: 12px; }
.about p { font-size: 14px; line-height: 1.7; }
.about p + p { margin-top: 8px; }
.about a { text-underline-offset: 3px; }
.about form { margin-top: 18px; text-align: right; }
.about button { padding: 8px 18px; border: 0; border-radius: 999px; background: var(--ink); color: #3a2c00; font-size: 14px; font-weight: 700; cursor: pointer; }
.run .badge { animation: pop .7s cubic-bezier(.34, 1.56, .64, 1) backwards; }
.run .ring { animation: spin 4s linear infinite; }
.run .core { animation: breathe 1.8s ease-in-out .7s infinite; }
.run .bar { animation: fill var(--delay) linear forwards; }
.run .copy { animation: rise .5s ease-out .15s backwards; }
.choosing .ring, .leaving .ring { animation-play-state: paused; }
.paused *, .paused *::before, .paused *::after { animation-play-state: paused !important; }
@keyframes pop { from { transform: scale(.55) rotate(-25deg); opacity: 0; } }
@keyframes breathe { 50% { transform: scale(1.03); } }
@keyframes fill { to { stroke-dashoffset: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@keyframes dot { 0%, 100% { opacity: .25; transform: none; } 40% { opacity: 1; transform: translateY(-.25em); } }
@keyframes ray { to { transform: rotate(var(--a)) scaleX(1); } }
@keyframes hub { to { transform: translate(-50%, -50%) scale(1); } }
@keyframes spin { to { rotate: 360deg; } }
@keyframes unspin { to { rotate: -360deg; } }

@media (max-width: 600px), (max-height: 500px) {
  .sector-label { --d: 28vmin; max-width: 112px; padding: 6px 9px; border-radius: 11px; }
  .sector-label small { font-size: 10px; line-height: 1.3; letter-spacing: .02em; }
  .sector-label b { font-size: 15px; line-height: 1.4; letter-spacing: .02em; }
  .sector:hover .sector-label, .sector:focus-visible .sector-label, .sector.picked .sector-label { scale: 1; }
  .hub { width: 56px; border-width: 3px; }
  .ray { height: 3px; margin-top: -1.5px; }
}
@media (max-height: 500px) {
  :root { --size: min(34vh, 180px); }
  body { padding-block: 18px 34px; }
  .intro { gap: 15px; }
  .copy { gap: 4px; }
  h1 { font-size: 26px; }
  .status { font-size: 13px; }
  .hint { padding-block: 5px; }
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #15120a; --fg: #f6edd0; --muted: #a8996c; --track: rgba(254, 206, 14, .16); --card: #221d12; }
}
@media (prefers-reduced-motion: reduce) {
  :root { --delay: 1200ms; }
  .run .badge, .run .ring, .run .core, .run .copy, .dots i, .about[open] { animation: none; }
  .choosing .ray, .leaving .ray { animation: none; transform: rotate(var(--a)); }
  .choosing .hub, .leaving .hub { animation: none; transform: translate(-50%, -50%); }
  .intro, .sectors, .sector, .sector img, .sector-label { transition: none !important; }
  .choosing .wheel, .choosing .sector img, .choosing .sector-label { animation-play-state: paused; }
  .js .sector img, .sector:hover img, .leaving .sector.picked img { scale: none; }
}
@supports not (clip-path: polygon(0 0, 100% 0, 0 100%)) {
  .wheel { display: grid; grid-template-columns: 1fr 1fr; }
  .sector { position: relative; overflow: hidden; }
  .sector-label { left: 50% !important; top: 50% !important; }
  .ray, .hub { display: none; }
}
.error-page { cursor: default; text-align: center; padding: 24px; }
.error-content { display: grid; justify-items: center; gap: 18px; }
.error-content img { width: min(42vh, 230px); height: auto; }
.error-content p { font-size: 14px; color: var(--muted); }
.error-content a { display: inline-block; padding: 10px 20px; border-radius: 999px; background: var(--ink); color: #3a2c00; text-decoration: none; }
