/* Earth Online — a quiet, personal collection. */
@property --accent-r { syntax: '<number>'; inherits: true; initial-value: 114; }
@property --accent-g { syntax: '<number>'; inherits: true; initial-value: 153; }
@property --accent-b { syntax: '<number>'; inherits: true; initial-value: 213; }
:root {
    color-scheme: light;
    --bg: #f4f6fa;
    --text: #292e39;
    --muted: #626d80;
    --faint: #687286;
    --surface: rgba(255, 255, 255, .68);
    --surface-card: rgba(255, 255, 255, .72);
    --surface-solid: #f8f9fc;
    --surface-hover: rgba(255, 255, 255, .9);
    --glass-border: rgba(255, 255, 255, .85);
    --line: rgba(63, 77, 102, .08);
    --control: rgba(73, 91, 124, .055);
    --shadow: 0 12px 44px rgba(36, 51, 82, .055), 0 2px 6px rgba(36, 51, 82, .025);
    --hover-shadow: 0 18px 42px rgba(36, 51, 82, .085), 0 3px 10px rgba(36, 51, 82, .025);
    --accent-rgb: var(--accent-r), var(--accent-g), var(--accent-b);
    --accent: #416da6;
    --on-accent: #fff;
    --atmosphere: .55;
    --ease: cubic-bezier(.2, .75, .25, 1);
    --spring: cubic-bezier(.2, 1.25, .4, 1);
    --nav-clearance: 112px;
    --text-primary: var(--text);
    --text-desc-color: var(--muted);
    transition: --accent-r 600ms ease, --accent-g 600ms ease, --accent-b 600ms ease;
}

:root[data-theme="dark"] {
    color-scheme: dark;
    --bg: #10131c;
    --text: #e9edf5;
    --muted: #a0a9bd;
    --faint: #8d98ad;
    --surface: rgba(30, 35, 49, .74);
    --surface-card: rgba(30, 35, 49, .66);
    --surface-solid: #202636;
    --surface-hover: rgba(38, 45, 63, .9);
    --glass-border: rgba(211, 225, 255, .08);
    --line: rgba(214, 226, 255, .08);
    --control: rgba(195, 211, 246, .055);
    --shadow: 0 12px 44px rgba(0, 0, 0, .1), 0 2px 6px rgba(0, 0, 0, .05);
    --hover-shadow: 0 18px 42px rgba(0, 0, 0, .18), 0 3px 10px rgba(0, 0, 0, .07);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-gutter: stable; scroll-padding-top: 176px; }
body { margin: 0; min-width: 320px; background: var(--bg); color: var(--text); font: 14px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; -webkit-font-smoothing: antialiased; transition: background-color 450ms ease, color 350ms ease; }
button, input, select { font: inherit; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
button { color: inherit; cursor: pointer; }
button, input, select, a { outline-offset: 4px; }
:focus-visible { outline: 2px solid var(--accent); }
button:disabled { cursor: default; }
button, a { touch-action: manipulation; }
a { color: var(--accent); text-decoration: none; }
h1, h2, h3, p { margin: 0; }
svg { display: block; }
[hidden] { display: none !important; }
::selection { background: rgba(var(--accent-rgb), .24); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: -100px; left: 20px; z-index: 300; background: var(--surface-solid); padding: 12px 20px; border-radius: 12px; }
.skip-link:focus { top: 12px; }
.main-content { position: relative; padding-top: var(--nav-clearance); }
.home-page, .source-page, .cooperation-page { max-width: 1160px; margin: 0 auto; padding: 36px 0 0; }
.eyebrow { display: inline-block; color: var(--faint); font-size: 10px; font-weight: 650; letter-spacing: .17em; line-height: 1.5; }
.accent-text { color: var(--accent); transition: color 350ms ease; }
.intro-reveal { animation: intro-reveal 850ms var(--ease) var(--intro-delay, 0ms) both; }

/* Soft atmosphere: only three large, composited color fields. */
.ambient-background { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: -1; opacity: var(--atmosphere); transition: opacity 450ms ease; }
.ambient-orb { position: absolute; width: 65vw; height: 65vw; min-width: 560px; min-height: 560px; max-width: 1100px; max-height: 1100px; border-radius: 50%; background: radial-gradient(ellipse, rgba(var(--accent-rgb), .24), rgba(var(--accent-rgb), .1) 32%, transparent 68%); animation: ambient-drift 28s ease-in-out infinite alternate; }
.orb-one { left: -22%; top: -35%; }
.orb-two { right: -27%; top: -13%; background: radial-gradient(ellipse, rgba(182, 169, 220, .22), transparent 65%); animation-delay: -11s; animation-duration: 33s; }
.orb-three { left: 16%; bottom: -75%; background: radial-gradient(ellipse, rgba(var(--accent-rgb), .16), transparent 67%); animation-delay: -18s; animation-duration: 37s; }
.ambient-grain { position: absolute; inset: 0; opacity: .075; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' opacity='.18' filter='url(%23n)'/%3E%3C/svg%3E"); }
[data-theme="dark"] .ambient-orb { opacity: .65; }
.is-page-hidden .ambient-orb { animation-play-state: paused; }

/* Floating navigation. */
.nav-bar { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); width: calc(100% - 64px); max-width: 1184px; z-index: 20; padding: 10px 13px 10px 18px; border: 1px solid var(--glass-border); border-radius: 23px; background: var(--surface); box-shadow: var(--shadow), inset 0 1px 0 var(--glass-border); backdrop-filter: blur(26px) saturate(150%); -webkit-backdrop-filter: blur(26px) saturate(150%); transition: box-shadow 400ms ease, background 400ms ease, top 400ms var(--ease); }
.nav-bar.is-scrolled { box-shadow: var(--hover-shadow); background: var(--surface-hover); top: 12px; }
.nav-container { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.nav-brand { color: var(--text); display: inline-flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-mark { display: grid; place-items: center; width: 34px; height: 34px; background: rgba(var(--accent-rgb), .1); color: var(--accent); border: 1px solid rgba(var(--accent-rgb), .1); border-radius: 11px; transition: transform 600ms var(--spring), background 300ms ease; }
.brand-mark svg { width: 28px; height: 28px; stroke: currentColor; stroke-width: 1.25; }
.nav-brand:hover .brand-mark { transform: rotate(-10deg); }
.brand-wordmark { font-size: 17px; letter-spacing: -.6px; font-weight: 650; }
.brand-wordmark > span { font-weight: 450; margin-left: 4px; }
.nav-right { display: flex; align-items: center; gap: 15px; }
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-btn { font-size: 12px; color: var(--muted); border-radius: 12px; padding: 9px 16px; transition: background 250ms ease, color 250ms ease, transform 250ms var(--spring); white-space: nowrap; }
.nav-btn:hover { color: var(--text); background: var(--control); }
.nav-btn.active { color: var(--text); background: var(--surface-hover); box-shadow: 0 2px 8px rgba(32, 46, 76, .04), inset 0 0 0 1px var(--line); }
.nav-btn:active { transform: scale(.96); }
.appearance-trigger { display: flex; align-items: center; justify-content: center; gap: 7px; height: 37px; border: 1px solid var(--line); padding: 0 14px; background: var(--control); border-radius: 12px; font-size: 12px; transition: background 200ms ease, transform 250ms var(--spring); white-space: nowrap; }
.appearance-trigger:hover { background: rgba(var(--accent-rgb), .1); }
.appearance-trigger:active { transform: scale(.95); }
.appearance-trigger svg { width: 17px; height: 17px; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.nav-stats { display: flex; align-items: center; gap: 6px; max-width: 0; opacity: 0; overflow: hidden; white-space: nowrap; font-size: 11px; font-variant-numeric: tabular-nums; color: var(--muted); transition: max-width 450ms var(--ease), opacity 350ms ease; }
.nav-stats.visible { max-width: 100px; opacity: 1; }
.status-dot { display: inline-block; flex-shrink: 0; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }

/* Introduction & progress. */
.hero { display: grid; grid-template-columns: 1.4fr .9fr; gap: 86px; align-items: center; padding: 18px 12px 0; margin-bottom: 70px; }
.hero-eyebrow { color: var(--accent); display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px; border: 1px solid rgba(var(--accent-rgb), .1); border-radius: 7px; background: rgba(var(--accent-rgb), .055); font-size: 9px; letter-spacing: .13em; }
.tiny-star { font-size: 11px; }
.hero h1 { font-size: clamp(42px, 4.5vw, 61px); line-height: 1.24; letter-spacing: -.055em; font-weight: 650; margin: 21px 0 17px; }
.hero-subtitle { color: var(--muted); font-size: 14px; line-height: 1.9; }
.hero-footnote { display: flex; align-items: center; gap: 10px; margin-top: 26px; font-size: 11px; color: var(--faint); }
.fine-line { width: 23px; height: 1px; background: rgba(var(--accent-rgb), .6); }
.journey-card { border: 1px solid var(--glass-border); border-radius: 28px; padding: 25px 27px 18px; background: linear-gradient(135deg, rgba(var(--accent-rgb), .035), transparent 65%), var(--surface); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px); box-shadow: var(--shadow), inset 0 1px 0 var(--glass-border); }
.journey-heading { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 12px; }
.journey-heading svg { width: 17px; height: 17px; color: var(--faint); stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.journey-main { display: flex; align-items: center; gap: 24px; padding: 19px 0 21px; }
.progress-ring { position: relative; width: 120px; height: 120px; flex-shrink: 0; }
.progress-ring > svg { width: 100%; height: 100%; transform: rotate(-90deg); fill: none; stroke-width: 5px; }
.ring-track { stroke: rgba(var(--accent-rgb), .1); }
.ring-fill { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 307.876; stroke-dashoffset: calc(307.876 * (1 - var(--progress) / 100)); transition: stroke-dashoffset 1000ms var(--ease), stroke 400ms ease; animation: ring-entrance 1400ms var(--ease) both; }
.ring-caption { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; }
.ring-caption > span:first-child { color: var(--text); font-size: 25px; line-height: 1.3; letter-spacing: -.8px; font-weight: 550; font-variant-numeric: tabular-nums; }
.ring-caption small { font-size: 11px; margin-left: 1px; font-weight: 450; }
.ring-caption > span:last-child { font-size: 9px; color: var(--faint); letter-spacing: 1px; }
.journey-numbers .number-label { display: block; color: var(--muted); font-size: 11px; margin-bottom: 3px; }
.journey-numbers > div { display: flex; align-items: baseline; gap: 8px; }
.journey-numbers strong { font-size: 36px; font-weight: 550; letter-spacing: -1.4px; line-height: 1.5; font-variant-numeric: tabular-nums; }
.journey-numbers > div > span { color: var(--faint); font-size: 12px; }
.journey-numbers p { color: var(--faint); font-size: 10px; margin-top: 4px; }
.journey-bottom { display: flex; align-items: center; gap: 7px; border-top: 1px solid var(--line); padding-top: 15px; color: var(--muted); font-size: 10px; }
.journey-arrow { margin-left: auto; font-size: 16px; color: var(--faint); }

/* Collection toolbar. */
.collection-heading { display: flex; align-items: flex-end; justify-content: space-between; padding: 0 5px; margin-bottom: 23px; }
.collection-heading h2 { font-size: 25px; letter-spacing: -.7px; font-weight: 600; display: flex; align-items: center; gap: 11px; margin-top: 4px; }
.collection-total { display: inline-block; font-size: 10px; color: var(--muted); background: var(--control); border: 1px solid var(--line); border-radius: 7px; padding: 2px 7px; line-height: 1.6; font-weight: 500; letter-spacing: 0; }
.collection-heading > p { color: var(--faint); font-size: 11px; margin-bottom: 6px; }
.filter-bar { position: sticky; top: 95px; z-index: 10; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 9px; border: 1px solid var(--glass-border); border-radius: 18px; background: var(--surface); box-shadow: 0 4px 24px rgba(31, 45, 77, .035); backdrop-filter: blur(26px) saturate(150%); -webkit-backdrop-filter: blur(26px) saturate(150%); scroll-margin-top: 96px; }
.segmented-control { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: center; gap: 3px; padding: 4px; background: var(--control); border-radius: 12px; }
.segmented-control > button:focus-visible { outline-offset: -3px; }
.segmented-control::before { content: ''; position: absolute; top: 4px; bottom: 4px; left: 4px; width: var(--segment-width, 0px); transform: translateX(var(--segment-x, 0px)); border-radius: 9px; background: var(--surface-hover); box-shadow: 0 2px 6px rgba(31, 45, 77, .06), inset 0 0 0 1px var(--line); opacity: 0; transition: transform 450ms var(--spring), width 400ms var(--ease), background 250ms ease; }
.segmented-control.has-indicator::before { opacity: 1; }
.segmented-control.has-indicator > button { position: relative; z-index: 1; }
.segmented-control.has-indicator > button[aria-pressed="true"] { background: transparent; box-shadow: none; }
.segmented-control > button { border: 0; border-radius: 9px; background: transparent; font-size: 12px; line-height: 1.4; color: var(--muted); padding: 8px 18px; white-space: nowrap; transition: background 300ms ease, color 250ms ease, box-shadow 300ms ease, transform 300ms var(--spring); }
.segmented-control > button:hover { color: var(--text); }
.segmented-control > button[aria-pressed="true"] { background: var(--surface-hover); color: var(--text); box-shadow: 0 2px 6px rgba(31, 45, 77, .06), inset 0 0 0 1px var(--line); }
.segmented-control > button:active { transform: scale(.96); }
.filter-tools { display: flex; align-items: center; gap: 7px; }
.search-wrapper { position: relative; display: flex; align-items: center; width: 236px; height: 37px; background: var(--control); border-radius: 11px; border: 1px solid transparent; transition: border-color 250ms ease, background 250ms ease, box-shadow 250ms ease; }
.search-wrapper:focus-within { border-color: rgba(var(--accent-rgb), .5); background: var(--surface-hover); box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .09); }
.search-wrapper > svg { position: absolute; left: 11px; width: 15px; height: 15px; color: var(--faint); stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.search-wrapper input { min-width: 0; width: 100%; border: 0; outline: 0; padding: 9px 30px 9px 34px; background: transparent; color: var(--text); font-size: 11px; }
.search-wrapper input::placeholder { color: var(--faint); }
.search-wrapper kbd { position: absolute; right: 10px; border: 1px solid var(--line); color: var(--faint); font: 10px/16px inherit; width: 17px; height: 18px; border-radius: 4px; text-align: center; pointer-events: none; }
.search-wrapper:focus-within kbd, .search-wrapper:has(input:not(:placeholder-shown)) kbd { opacity: 0; }
.select-wrapper { position: relative; }
.select-wrapper select { appearance: none; -webkit-appearance: none; max-width: 150px; border: 1px solid transparent; border-radius: 10px; background: transparent; color: var(--muted); padding: 9px 27px 9px 12px; cursor: pointer; font-size: 11px; transition: background 250ms ease; }
.select-wrapper select:hover { background: var(--control); }
.select-wrapper select:focus-visible { outline-offset: 0; }
.select-wrapper option { color: var(--text); background: var(--surface-solid); }
.select-wrapper > svg { position: absolute; top: 50%; right: 9px; transform: translateY(-50%); width: 12px; height: 12px; pointer-events: none; stroke: var(--faint); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.select-wrapper > .compact-select-icon { display: none; }
.select-wrapper.has-selection select { color: var(--accent); }
.collection-meta { display: flex; align-items: center; justify-content: space-between; padding: 20px 5px 16px; font-size: 10px; color: var(--faint); }
.collection-hint { display: flex; align-items: center; gap: 6px; }
.collection-hint svg { width: 13px; height: 13px; stroke: currentColor; stroke-width: 1; }

/* Quiet glass cards; rarity remains an independent, readable cue. */
.achievements-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 17px; transition: opacity 220ms ease; }
.achievements-list[aria-busy="true"] { opacity: .45; pointer-events: none; }
.achievement-card { --rarity-rgb: 134, 151, 179; --rarity-ink: #65738c; position: relative; min-width: 0; display: flex; flex-direction: column; padding: 21px 22px 17px; border: 1px solid var(--glass-border); border-radius: 22px; background: var(--surface-card); box-shadow: 0 4px 14px rgba(31, 45, 77, .018), inset 0 1px 0 var(--glass-border); cursor: pointer; transition: transform 450ms var(--spring), box-shadow 450ms var(--ease), border-color 350ms ease, background 350ms ease; isolation: isolate; }
.achievement-card[data-rarity="gold"] { --rarity-rgb: 181, 140, 65; --rarity-ink: #8b692f; }
.achievement-card[data-rarity="copper"] { --rarity-rgb: 176, 119, 84; --rarity-ink: #936348; }
.achievement-card::before { content: ''; pointer-events: none; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: radial-gradient(ellipse at 90% 0%, rgba(var(--accent-rgb), .07), transparent 70%); opacity: 0; transition: opacity 400ms ease; }
.achievement-card:hover { transform: translateY(-4px); box-shadow: var(--hover-shadow); border-color: rgba(var(--accent-rgb), .26); }
.achievement-card:hover::before { opacity: 1; }
.achievement-card:active:not(:has(.card-checkbox:active)) { transform: translateY(-1px) scale(.99); }
.achievement-card:focus-within { border-color: rgba(var(--accent-rgb), .5); }
.achievement-card.completed { background: linear-gradient(145deg, rgba(var(--accent-rgb), .06), transparent 70%), var(--surface-card); border-color: rgba(var(--accent-rgb), .2); }
.achievement-card.is-pending { cursor: progress; opacity: .7; }
.card-top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 19px; }
.card-icon { position: relative; display: grid; place-items: center; width: 54px; height: 54px; border-radius: 16px; background: linear-gradient(145deg, rgba(var(--rarity-rgb), .11), rgba(var(--rarity-rgb), .035)); border: 1px solid rgba(var(--rarity-rgb), .08); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18); transition: transform 500ms var(--spring), background 350ms ease; }
.card-icon > svg { width: 36px; height: 36px; opacity: .82; filter: saturate(.7); transition: filter 350ms ease, opacity 350ms ease; }
.achievement-card:hover .card-icon { transform: translateY(-1px) rotate(-3deg); }
.achievement-card.completed .card-icon > svg { opacity: 1; filter: saturate(.95); }
.card-icon::after { content: ''; pointer-events: none; position: absolute; inset: -5px; border: 1px solid var(--accent); border-radius: 20px; opacity: 0; }
.card-icon::before { content: '✦'; position: absolute; right: -9px; top: -10px; color: var(--accent); font-size: 17px; opacity: 0; pointer-events: none; }
.card-checkbox { position: relative; display: inline-flex; align-items: center; gap: 5px; padding: 3px 0 6px 10px; cursor: pointer; color: var(--faint); }
.check-text { font-size: 10px; line-height: 1.5; transition: color 250ms ease; }
.checkmark { display: grid; place-items: center; width: 17px; height: 17px; border: 1px solid var(--line); border-radius: 50%; background: var(--control); transition: border-color 250ms ease, background 250ms ease, transform 300ms var(--spring); }
.checkmark svg { width: 14px; height: 14px; stroke: var(--accent); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.checkmark path { stroke-dasharray: 16; stroke-dashoffset: 16; transition: stroke-dashoffset 350ms var(--ease); }
.card-checkbox input:checked + .checkmark { border-color: rgba(var(--accent-rgb), .3); background: rgba(var(--accent-rgb), .13); }
.card-checkbox input:checked + .checkmark path { stroke-dashoffset: 0; }
.card-checkbox input:checked ~ .check-text { color: var(--accent); }
.card-checkbox:hover .checkmark { transform: scale(1.1); border-color: rgba(var(--accent-rgb), .5); }
.card-checkbox input:focus-visible + .checkmark { outline: 2px solid var(--accent); outline-offset: 4px; }
.card-content { flex: 1; }
.card-title { font-size: 16px; font-weight: 600; letter-spacing: -.35px; line-height: 1.5; margin-bottom: 7px; overflow-wrap: anywhere; }
.card-desc { color: var(--muted); font-size: 13px; line-height: 1.75; min-height: 45.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 20px; padding-top: 13px; border-top: 1px solid var(--line); }
.rarity-tag { display: inline-flex; align-items: center; gap: 5px; color: var(--rarity-ink); font-size: 10px; }
.rarity-tag > span { display: inline-block; width: 4px; height: 4px; border-radius: 50%; background: currentColor; }
.card-rate { color: var(--faint); font-size: 10px; font-variant-numeric: tabular-nums; white-space: nowrap; }
[data-theme="dark"] .rarity-tag { color: rgb(var(--rarity-rgb)); filter: brightness(1.25); }
.is-celebrating .card-icon { animation: medal-pop 850ms var(--spring); }
.is-celebrating .card-icon::after { animation: ring-bloom 1000ms var(--ease); }
.is-celebrating .card-icon::before { animation: sparkle 900ms var(--ease) 100ms; }
.empty-state { padding: 80px 20px; text-align: center; color: var(--muted); }
.empty-symbol { display: block; font-size: 48px; line-height: 1.5; color: var(--accent); }
.empty-state h3 { color: var(--text); font-size: 19px; font-weight: 550; margin: 10px 0 8px; }
.empty-state p { font-size: 12px; }
.quiet-button { padding: 9px 17px; margin-top: 22px; border: 1px solid var(--line); border-radius: 12px; color: var(--accent); background: var(--surface); font-size: 12px; transition: transform 300ms var(--spring), background 250ms ease; }
.quiet-button:hover { background: var(--surface-hover); transform: translateY(-2px); }
.pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px; padding: 34px 0 14px; }
.page-button { display: grid; place-items: center; min-width: 32px; height: 32px; border: 1px solid transparent; border-radius: 10px; padding: 0 9px; background: transparent; color: var(--muted); font-size: 11px; transition: color 250ms ease, background 250ms ease, transform 250ms var(--spring); }
.page-button:hover:not(:disabled) { background: var(--control); color: var(--text); transform: translateY(-2px); }
.page-button.active { background: var(--surface-hover); color: var(--accent); border-color: var(--line); box-shadow: 0 2px 6px rgba(31, 45, 77, .04); }
.page-button:disabled { opacity: .25; }
.page-step { background: var(--control); font-size: 14px; }
.pagination-ellipsis { color: var(--faint); font-size: 11px; padding: 0 4px; }
.page-summary { margin-left: 14px; font-size: 10px; color: var(--faint); font-variant-numeric: tabular-nums; }

/* Appearance popover. Native dialog handles focus and keyboard containment. */
body:has(dialog[open]) { overflow: hidden; }
.appearance-panel { color: var(--text); position: fixed; top: 94px; right: max(24px, calc((100vw - 1184px) / 2)); left: auto; width: 362px; max-width: calc(100% - 24px); margin: 0; max-height: calc(100dvh - 115px); padding: 25px; border: 1px solid var(--glass-border); border-radius: 26px; background: var(--surface-solid); background: color-mix(in srgb, var(--surface-solid) 88%, transparent); backdrop-filter: blur(36px) saturate(140%); -webkit-backdrop-filter: blur(36px) saturate(140%); box-shadow: 0 28px 90px rgba(20, 30, 50, .15), inset 0 1px 0 var(--glass-border); scrollbar-width: thin; }
.appearance-panel[open] { animation: panel-enter 420ms var(--spring) both; }
.appearance-panel::backdrop { background: rgba(20, 28, 45, .1); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); animation: backdrop-enter 350ms ease both; }
.appearance-panel.is-closing { animation: panel-leave 180ms ease both; }
.appearance-panel.is-closing::backdrop { animation: backdrop-enter 180ms ease reverse both; }
.panel-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 15px; margin-bottom: 25px; }
.panel-heading h2 { font-size: 22px; font-weight: 600; letter-spacing: -.6px; margin-top: 7px; }
.panel-heading .eyebrow { font-size: 8px; }
.icon-button { display: grid; place-items: center; flex-shrink: 0; width: 28px; height: 28px; border-radius: 50%; border: 0; background: var(--control); color: var(--muted); transition: transform 250ms var(--spring), background 200ms ease; }
.icon-button:hover { transform: rotate(90deg); background: rgba(var(--accent-rgb), .12); }
.icon-button svg { width: 16px; height: 16px; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.appearance-group { min-width: 0; padding: 0; margin: 0 0 23px; border: 0; }
.appearance-group legend, .range-label { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 0; margin-bottom: 11px; font-size: 12px; font-weight: 550; }
.appearance-group legend > span, .range-label output { float: right; margin-left: auto; font-weight: 400; color: var(--faint); font-size: 10px; }
.mode-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.mode-options button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 13px 4px 10px; border: 1px solid var(--line); border-radius: 13px; background: var(--control); color: var(--muted); font-size: 10px; transition: border-color 250ms ease, background 250ms ease, transform 250ms var(--spring); }
.mode-options button[aria-pressed="true"] { color: var(--accent); background: rgba(var(--accent-rgb), .09); border-color: rgba(var(--accent-rgb), .35); }
.mode-options button:hover { transform: translateY(-2px); }
.mode-options svg { width: 21px; height: 21px; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.color-options { display: flex; align-items: center; justify-content: space-between; padding: 3px; gap: 8px; }
.color-swatch { width: 32px; height: 32px; flex-shrink: 0; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .04); background: var(--swatch); position: relative; transition: box-shadow 250ms ease, transform 300ms var(--spring); }
.color-swatch[aria-pressed="true"] { box-shadow: 0 0 0 3px var(--surface-solid), 0 0 0 4.5px var(--swatch); }
.color-swatch[aria-pressed="true"]::after { content: ''; position: absolute; width: 6px; height: 10px; border-right: 1.6px solid white; border-bottom: 1.6px solid white; left: 12px; top: 8px; transform: rotate(45deg); }
.color-swatch:hover { transform: scale(1.1); }
.custom-color { position: relative; display: grid; place-items: center; width: 32px; height: 32px; flex-shrink: 0; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); background: var(--control); overflow: hidden; cursor: pointer; }
.custom-color:focus-within { outline: 2px solid var(--accent); outline-offset: 4px; }
.custom-color input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.custom-color svg { width: 16px; height: 16px; stroke: currentColor; stroke-width: 1.5; pointer-events: none; }
.appearance-group input[type="range"] { width: 100%; height: 5px; margin: 7px 0 4px; border-radius: 10px; cursor: pointer; accent-color: var(--accent); }
.setting-hint { font-size: 10px; line-height: 1.7; color: var(--faint); margin-top: 9px; }
.motion-options { width: 100%; }
.motion-options button { flex: 1; padding: 8px 4px; font-size: 10px; }
.appearance-preview { display: flex; align-items: center; gap: 11px; padding: 13px; background: linear-gradient(125deg, rgba(var(--accent-rgb), .13), rgba(var(--accent-rgb), .025)); border: 1px solid rgba(var(--accent-rgb), .13); border-radius: 15px; }
.preview-mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; color: var(--accent); background: rgba(var(--accent-rgb), .12); font-size: 22px; }
.appearance-preview span { display: block; font-size: 11px; }
.appearance-preview small { display: block; color: var(--muted); font-size: 9px; margin-top: 3px; }
.appearance-preview .preview-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-left: auto; }
.panel-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 17px; margin-top: 19px; border-top: 1px solid var(--line); color: var(--faint); font-size: 9px; }
.panel-footer button { border: 0; color: var(--muted); background: transparent; font-size: 10px; padding: 4px 0 4px 10px; }
.panel-footer button:hover { color: var(--accent); }

/* Feedback. */
.toast-region { position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%); z-index: 100; width: max-content; max-width: calc(100vw - 32px); pointer-events: none; }
.toast { display: flex; align-items: center; gap: 11px; padding: 14px 22px 14px 14px; border-radius: 18px; border: 1px solid var(--glass-border); background: var(--surface-hover); backdrop-filter: blur(25px); -webkit-backdrop-filter: blur(25px); box-shadow: var(--hover-shadow); animation: toast-enter 450ms var(--spring) both; }
.toast-symbol { display: grid; place-items: center; width: 30px; height: 30px; flex-shrink: 0; border-radius: 50%; background: rgba(var(--accent-rgb), .12); color: var(--accent); font-size: 14px; }
.toast strong { display: block; font-size: 12px; font-weight: 550; line-height: 1.5; }
.toast small { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }
.toast.is-leaving { animation: toast-leave 220ms ease both; }

/* Shared language for the source and service pages. */
.source-page, .cooperation-page { max-width: 1040px; }
.page-header { padding: 15px 4px 30px; }
.page-title { font-size: 43px; font-weight: 600; letter-spacing: -1.8px; line-height: 1.35; margin-bottom: 13px; }
.page-subtitle { color: var(--muted); font-size: 14px; line-height: 1.8; }
.repository-links { display: flex; align-items: center; gap: 12px; margin-top: 13px; font-size: 11px; }
.repository-links > span { color: var(--faint); }
.repository-links a:hover { text-decoration: underline; text-underline-offset: 4px; }
.source-tabs { display: inline-flex; gap: 4px; padding: 5px; border: 1px solid var(--line); border-radius: 15px; background: var(--control); margin-bottom: 26px; max-width: 100%; overflow-x: auto; }
.source-tab { padding: 9px 23px; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font-size: 12px; white-space: nowrap; transition: background 250ms ease, color 250ms ease; }
.source-tab.active { background: var(--surface-hover); color: var(--text); box-shadow: 0 2px 8px rgba(31, 45, 77, .04); }
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: intro-reveal 450ms var(--ease) both; }
.intro-card, .explain-card, .coop-intro-card, .coop-card, .contact-card { min-width: 0; padding: 32px; background: var(--surface-card); border: 1px solid var(--glass-border); border-radius: 23px; box-shadow: var(--shadow); }
.section-title { font-size: 22px; font-weight: 600; letter-spacing: -.5px; margin-bottom: 17px; }
.section-desc, .coop-card-desc { color: var(--muted); line-height: 1.9; font-size: 13px; }
.section-desc + .section-desc { margin-top: 12px; }
.sub-title { font-size: 16px; font-weight: 550; margin: 30px 0 15px; }
.feature-list, .coop-list { color: var(--muted); font-size: 13px; padding-left: 19px; line-height: 1.9; margin: 15px 0; }
.feature-list li, .coop-list li { margin-bottom: 6px; }
.feature-list li::marker, .coop-list li::marker { color: var(--accent); }
.tech-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.tech-item { background: var(--control); border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.tech-indicator { width: 18px; height: 3px; background: var(--accent); border-radius: 3px; margin-bottom: 15px; transition: width 350ms var(--spring); }
.tech-item:hover .tech-indicator { width: 32px; }
.tech-name { font-weight: 600; font-size: 13px; margin-bottom: 7px; }
.tech-desc { font-size: 11px; color: var(--muted); line-height: 1.7; }
.code-block-wrapper { position: relative; min-width: 0; margin: 20px 0; }
.code-block { margin: 0; padding: 26px; border: 1px solid rgba(201, 217, 248, .08); border-radius: 15px; background: #171d2a; color: #c4cfe2; font: 12px/1.9 "Cascadia Code", Consolas, monospace; overflow-x: auto; tab-size: 4; }
.code-block code { background: transparent; padding: 0; font: inherit; color: inherit; }
.copy-btn { position: absolute; top: 12px; right: 12px; z-index: 1; display: grid; place-items: center; min-width: 28px; min-height: 28px; padding: 6px 9px; border: 1px solid rgba(255, 255, 255, .12); border-radius: 7px; color: #b5c2d9; background: #252d3d; font-size: 10px; transition: background 200ms ease; }
.copy-btn:hover { background: #34405a; }
.copy-btn.copied { color: #bbdfcc; }
.explain-item + .explain-item { margin-top: 32px; }
.explain-title { font-size: 16px; font-weight: 550; }
.tip-box { padding: 16px 18px; border-left: 2px solid rgba(var(--accent-rgb), .7); background: rgba(var(--accent-rgb), .055); border-radius: 0 12px 12px 0; }
.tip-label { display: block; font-size: 10px; font-weight: 600; color: var(--accent); margin-bottom: 7px; }
.tip-content { color: var(--muted); font-size: 12px; line-height: 1.9; }
.rarity-list { list-style: none; padding: 0; margin: 18px 0 0; }
.rarity-list li { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; font-size: 12px; color: var(--muted); }
.rarity-badge { padding: 4px 8px; border-radius: 7px; background: var(--control); font-size: 10px; white-space: nowrap; }
.rarity-badge.gold { color: #ae843c; }
.rarity-badge.silver { color: #8595ad; }
.rarity-badge.bronze { color: #b17d5a; }
.coop-intro-card { margin-bottom: 35px; }
.coop-section { margin-bottom: 35px; }
.coop-section > .section-title { padding-left: 4px; }
.coop-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; }
.coop-card { padding: 28px; transition: transform 450ms var(--spring), box-shadow 350ms ease; }
.coop-card:hover { transform: translateY(-4px); box-shadow: var(--hover-shadow); }
.coop-icon { color: var(--accent); display: grid; place-items: center; width: 44px; height: 44px; background: rgba(var(--accent-rgb), .08); border-radius: 13px; margin-bottom: 20px; }
.coop-icon svg { width: 22px; height: 22px; }
.coop-card-title { font-size: 17px; font-weight: 550; margin-bottom: 10px; }
.timeline { margin-top: 26px; padding-left: 26px; position: relative; }
.timeline::before { content: ''; position: absolute; left: 4px; top: 8px; bottom: 12px; width: 1px; background: var(--line); }
.timeline-item { position: relative; padding-bottom: 22px; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-dot { position: absolute; left: -25px; top: 8px; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .08); }
.timeline-title { font-size: 13px; font-weight: 550; margin-bottom: 7px; }
.timeline-desc { color: var(--muted); font-size: 12px; line-height: 1.8; }
.contact-card { text-align: center; padding: 43px 28px; }
.contact-grid { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.contact-item { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 18px; color: var(--text); background: var(--control); font-size: 12px; transition: background 250ms ease, transform 300ms var(--spring); }
.contact-item:hover { background: rgba(var(--accent-rgb), .12); transform: translateY(-2px); }
.contact-item svg { width: 17px; height: 17px; }
.site-footer { position: relative; max-width: 1160px; margin: 46px auto 0; padding: 25px 4px 32px; border-top: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; gap: 20px; color: var(--faint); font-size: 10px; }
.site-footer > div { display: flex; align-items: center; gap: 15px; }
.footer-brand { color: var(--muted); font-size: 11px; font-weight: 550; }
.visitor-stats span { padding: 0 7px; }

@keyframes ambient-drift { from { transform: translate3d(-2%, -2%, 0) scale(1); } to { transform: translate3d(7%, 6%, 0) scale(1.06); } }
@keyframes intro-reveal { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
@keyframes ring-entrance { from { stroke-dashoffset: 307.876; } }
@keyframes panel-enter { from { opacity: 0; transform: translateY(-10px) scale(.97); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes panel-leave { to { opacity: 0; transform: translateY(-7px) scale(.98); } }
@keyframes backdrop-enter { from { opacity: 0; } to { opacity: 1; } }
@keyframes medal-pop { 0%, 100% { transform: scale(1) rotate(0); } 35% { transform: scale(1.16) rotate(-7deg); } 65% { transform: scale(.98) rotate(3deg); } }
@keyframes ring-bloom { 0% { opacity: .6; transform: scale(.85); } 100% { opacity: 0; transform: scale(1.5); } }
@keyframes sparkle { 0% { opacity: 0; transform: scale(.3) rotate(-35deg); } 35% { opacity: .9; transform: scale(1.1) rotate(0); } 100% { opacity: 0; transform: translate(5px, -7px) scale(.6) rotate(30deg); } }
@keyframes toast-enter { from { opacity: 0; transform: translateY(16px) scale(.96); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes toast-leave { to { opacity: 0; transform: translateY(8px) scale(.98); } }

@media (min-width: 1700px) { .hero { padding-top: 36px; margin-bottom: 82px; } }
@media (max-width: 1260px) { .home-page, .source-page, .cooperation-page, .site-footer { margin-left: 40px; margin-right: 40px; } .hero { gap: 48px; } .filter-tools { gap: 3px; } .search-wrapper { width: 205px; } }
@media (max-width: 1050px) { .hero { grid-template-columns: 1.15fr 1fr; gap: 30px; } .hero h1 { font-size: 46px; } .journey-card { padding: 23px 21px 17px; } .journey-main { gap: 18px; } .achievements-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } .filter-bar { gap: 8px; } .segmented-control > button { padding: 8px 12px; } .search-wrapper { width: 190px; } .select-wrapper select { max-width: 130px; padding-left: 8px; } .tech-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) { .nav-bar { width: calc(100% - 40px); } .nav-btn { padding: 8px 12px; } .nav-right { gap: 10px; } .home-page, .source-page, .cooperation-page, .site-footer { margin-left: 28px; margin-right: 28px; } .filter-bar { flex-wrap: wrap; padding: 10px; } .collection-filters { width: 100%; } .collection-filters > button { flex: 1; } .filter-tools { width: 100%; justify-content: space-between; } .search-wrapper { flex: 1; width: auto; } .hero { gap: 22px; padding-left: 0; padding-right: 0; margin-bottom: 48px; } .hero h1 { font-size: 40px; } .hero-eyebrow { font-size: 8px; letter-spacing: .07em; } .hero-footnote { font-size: 10px; } .journey-main { gap: 14px; } .progress-ring { width: 106px; height: 106px; } .journey-numbers strong { font-size: 31px; } .nav-stats { display: none; } }
@media (max-width: 680px) {
    :root { --nav-clearance: 134px; }
    html { scroll-padding-top: 230px; }
    .nav-bar, .nav-bar.is-scrolled { top: 10px; width: calc(100% - 24px); padding: 10px 12px; border-radius: 21px; }
    .nav-container { flex-wrap: wrap; gap: 9px; }
    .nav-brand { flex: 1; gap: 8px; padding-left: 3px; }
    .brand-mark { width: 29px; height: 29px; border-radius: 9px; }
    .brand-mark svg { width: 25px; height: 25px; }
    .brand-wordmark { font-size: 16px; }
    .nav-right { display: contents; }
    .nav-links { order: 3; width: 100%; gap: 4px; background: var(--control); padding: 3px; border-radius: 12px; }
    .nav-btn { flex: 1; text-align: center; font-size: 11px; padding: 6px 10px; border-radius: 9px; }
    .appearance-trigger { height: 31px; font-size: 11px; padding: 0 10px; border-radius: 10px; }
    .home-page, .source-page, .cooperation-page, .site-footer { margin-left: 22px; margin-right: 22px; }
    .home-page, .source-page, .cooperation-page { padding-top: 20px; }
    .hero { grid-template-columns: 1fr; gap: 28px; padding-top: 3px; margin-bottom: 42px; }
    .hero h1 { font-size: clamp(36px, 8.5vw, 49px); margin-top: 19px; }
    .hero-eyebrow { font-size: 8px; }
    .hero-subtitle { font-size: 12px; }
    .hero-footnote { font-size: 10px; margin-top: 18px; }
    .journey-card { border-radius: 24px; padding: 20px 23px 16px; }
    .journey-main { padding: 15px 0 17px; justify-content: center; gap: 35px; }
    .progress-ring { width: 112px; height: 112px; }
    .journey-numbers strong { font-size: 36px; }
    .journey-bottom { padding-top: 12px; }
    .collection-heading { margin-bottom: 18px; padding: 0 2px; }
    .collection-heading h2 { font-size: 23px; }
    .collection-heading > p { display: none; }
    .filter-bar { top: 124px; border-radius: 17px; padding: 8px; scroll-margin-top: 128px; gap: 7px; }
    .filter-tools { flex-wrap: nowrap; gap: 5px; }
    .search-wrapper { flex: 1; min-width: 0; height: 38px; }
    .select-wrapper { flex: 0 0 38px; width: 38px; height: 38px; background: var(--control); border-radius: 10px; }
    .select-wrapper select { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; max-width: none; padding: 0; opacity: 0; }
    .select-wrapper:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
    .select-wrapper > .select-chevron { display: none; }
    .select-wrapper > .compact-select-icon { display: block; width: 16px; height: 16px; right: 11px; }
    .select-wrapper.has-selection::after { content: ''; position: absolute; top: 5px; right: 5px; width: 4px; height: 4px; border-radius: 50%; background: var(--accent); }
    .search-wrapper kbd { display: none; }
    .collection-meta { font-size: 9px; padding: 17px 2px 14px; }
    .collection-hint { font-size: 8px; gap: 2px; }
    .collection-hint svg { display: none; }
    .achievements-list { grid-template-columns: 1fr; gap: 13px; }
    .achievement-card { padding: 20px 22px 17px; border-radius: 21px; }
    .card-top { margin-bottom: 15px; }
    .card-desc { font-size: 13px; min-height: auto; }
    .card-bottom { margin-top: 17px; }
    .page-summary { display: none; }
    .page-button { min-width: 30px; height: 32px; padding: 0 7px; }
    .pagination { gap: 4px; }
    .appearance-panel { inset: auto 12px 12px; width: calc(100% - 24px); max-height: calc(100dvh - 24px); padding: 24px; border-radius: 25px; }
    .appearance-panel[open] { animation-name: toast-enter; }
    .appearance-panel.is-closing { animation-name: toast-leave; }
    .appearance-group { margin-bottom: 20px; }
    .color-options { justify-content: space-between; gap: 0; }
    .page-header { padding-top: 3px; }
    .page-title { font-size: 35px; }
    .page-subtitle { font-size: 12px; }
    .source-tab { font-size: 11px; padding: 8px 13px; }
    .intro-card, .explain-card, .coop-intro-card, .contact-card { padding: 23px; border-radius: 21px; }
    .section-title { font-size: 20px; }
    .section-desc, .coop-card-desc, .feature-list, .coop-list { font-size: 12px; }
    .tech-grid { gap: 9px; }
    .tech-item { padding: 15px; }
    .coop-grid { grid-template-columns: 1fr; gap: 13px; }
    .coop-card { padding: 24px; }
    .code-block { font-size: 10px; padding: 22px 18px; }
    .rarity-list li { font-size: 11px; }
    .site-footer { flex-direction: column; align-items: flex-start; gap: 14px; margin-top: 30px; padding-bottom: 25px; font-size: 9px; }
    .site-footer > div { gap: 12px; }
    .toast-region { bottom: 18px; }
}
@media (max-width: 360px) { .home-page, .source-page, .cooperation-page, .site-footer { margin-left: 16px; margin-right: 16px; } .collection-hint { display: none; } .journey-main { gap: 22px; } }

[data-motion="subtle"] .ambient-orb { animation: none; }
[data-motion="subtle"] .intro-reveal { animation-duration: 450ms; animation-delay: 0ms; }
[data-motion="subtle"] .is-celebrating .card-icon::before,
[data-motion="subtle"] .is-celebrating .card-icon::after { animation: none; }
[data-motion="subtle"] .is-celebrating .card-icon { animation-duration: 450ms; }
[data-motion="none"] *, [data-motion="none"] *::before, [data-motion="none"] *::after { animation: none !important; transition-duration: 0ms !important; scroll-behavior: auto !important; }
[data-motion="none"] { scroll-behavior: auto; transition: none; }
[data-motion="none"] .achievement-card:hover, [data-motion="none"] .achievement-card:active, [data-motion="none"] .achievement-card:hover .card-icon, [data-motion="none"] .coop-card:hover { transform: none; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition-duration: 0ms !important; scroll-behavior: auto !important; } html { scroll-behavior: auto; } }
