* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-sans);
    -webkit-tap-highlight-color: transparent;
}

html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-synthesis-weight: none;
    font-synthesis: none;
}

:root {

    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

    --ease-in: cubic-bezier(0.64, 0, 0.78, 0);

    --ease-spring: cubic-bezier(0.34, 1.28, 0.64, 1);

    --ease-std: cubic-bezier(0.4, 0, 0.2, 1);

    --dur-xs: 0.18s;
    --dur-sm: 0.26s;
    --dur-md: 0.38s;
    --dur-lg: 0.52s;

    --font-sans: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Display',
        'PingFang SC', 'HarmonyOS Sans SC', 'MiSans', 'Source Han Sans SC',
        'Noto Sans CJK SC', 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;

    --ls-cjk: 0;

    --ios-blue: #007AFF;
    --ios-blue-hover: #0051D5;
    --ios-gray: #8E8E93;

    --muted: #8E8E93;
    --ios-card: rgba(255, 255, 255, 0.82);
    --ios-border: rgba(0, 0, 0, 0.04);
    --ios-shadow: 0 4px 24px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
    --ios-shadow-hover: 0 12px 40px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(0, 0, 0, 0.04);
}

body {

    min-height: 100vh;
    min-height: 100dvh;
    background: linear-gradient(180deg, #FFFFFF 0%, #F5F5F7 100%);
    overflow-x: hidden;
    position: relative;
    color: #1D1D1F;

    -webkit-touch-callout: none;

    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;

    overscroll-behavior-y: none;
}

.background-elements {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: radial-gradient(circle at 100% 0%, rgba(0, 122, 255, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 0% 100%, rgba(0, 122, 255, 0.02) 0%, transparent 40%);
}

.bg-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
    display: none;
}
.bg-layer.on {
    display: block;
}

.bg-image,
.bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.bg-image {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.bg-image,
.bg-video {
    display: none;
}
.bg-layer.type-image .bg-image {
    display: block;
}
.bg-layer.type-video .bg-video {
    display: block;
}

.bg-mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    opacity: 0;
    pointer-events: none;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem 3rem;
    position: relative;
    z-index: 1;
}

.top-bar {
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: saturate(180%) blur(30px);
    -webkit-backdrop-filter: saturate(180%) blur(30px);
    border-radius: 32px;
    padding: 1rem 1.4rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.06), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.top-avatar {
    width: 56px;
    height: 56px;
    border-radius: 18px;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
}

.music-inline {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    flex-wrap: wrap;
    min-width: 0;
}

.song-name {
    font-weight: 650;
    font-size: 1rem;
    color: #1D1D1F;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 120px;
    letter-spacing: -0.01em;
}

.motto-tag {
    font-size: 0.7rem;
    font-weight: 400;
    font-style: italic;
    letter-spacing: 0.02em;
    white-space: nowrap;
    padding: 0.2rem 0.6rem;
    background: rgba(155, 142, 138, 0.08);
    border-radius: 12px;
    cursor: default;
    user-select: none;
    line-height: 1.4;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.rainbow-text {
    background: linear-gradient(90deg,
            #ff0000, #ff8800, #ffff00,
            #00cc00, #00aaff, #4400ff, #aa00ff);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: rainbowMove 4s linear infinite;
    font-weight: 600;
}

@keyframes rainbowMove {
    0% {
        background-position: 0% center;
    }
    100% {
        background-position: 200% center;
    }
}

.beijing-fulltime {
    font-size: 0.78rem;
    font-weight: 500;
    color: #1D1D1F;
    background: rgba(0, 0, 0, 0.03);
    padding: 0.25rem 0.7rem;
    border-radius: 14px;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    letter-spacing: -0.01em;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.volume-group {
    display: flex;
    align-items: center;
    gap: 0.15rem;
    background: rgba(0, 0, 0, 0.03);
    border-radius: 24px;
    padding: 0.2rem 0.4rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.volume-btn {
    background: transparent;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color .2s, color .2s, transform .2s;
    color: #636366;
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1;
    padding: 0;
}

.volume-btn:hover {
    background: rgba(0, 122, 255, 0.1);
    color: var(--ios-blue);
}
.volume-btn:active {
    transform: scale(0.85);
    background: rgba(0, 122, 255, 0.18);
}

.control-btn-small {
    background: rgba(0, 0, 0, 0.04);
    border: none;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color .2s, transform .2s;
    color: var(--ios-blue);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}
.control-btn-small:hover {
    background: rgba(0, 122, 255, 0.1);
}
.control-btn-small:active {
    transform: scale(0.92);
}

.play-btn-small {
    width: 42px;
    height: 42px;
    background: var(--ios-blue);
    color: white;
    box-shadow: 0 6px 14px rgba(0, 122, 255, 0.35);
}
.play-btn-small:hover {
    background: var(--ios-blue-hover);
}

.music-progress-row {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    width: 100%;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border-radius: 20px;
    padding: 0.5rem 0.9rem;
    margin-top: 0.25rem;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    order: 10;
}

.music-time {
    font-size: 0.8rem;
    font-weight: 600;
    color: #1D1D1F;
    font-variant-numeric: tabular-nums;
    min-width: 38px;
    text-align: center;
    letter-spacing: 0.02em;
    opacity: 0.8;
}

.music-progress-wrap {
    flex: 1;
    height: 5px;
    background: rgba(0, 0, 0, 0.08);
    border-radius: 3px;
    cursor: pointer;
    position: relative;
    overflow: hidden;

}
.music-progress-wrap {

    touch-action: none;
}
.music-progress-wrap::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    height: 44px;
    transform: translateY(-50%);

    background: transparent;
}

@media (min-width: 768px) {
    .music-progress-wrap::after {
        height: 20px;

    }
}

.splash {
    --t-crack: 720ms;
    --t-push: 1500ms;
    --t-flood: 860ms;
    --t-out: 520ms;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 9999;
    background: #05080f;
    overflow: hidden;

    transition: opacity var(--t-out) ease-out, transform var(--t-out) ease-out;
}
.splash.s-out {
    opacity: 0;
    transform: scale(1.03);
    pointer-events: none;
}

.splash-stage {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    perspective: 1400px;
    transform-style: preserve-3d;
}

.splash-sky {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(ellipse 62% 72% at 50% 50%,
        #e8f3ff 0%, #a8cdf5 26%, #4a7cb5 58%, #0d1b2e 100%);
    opacity: .16;
    transition: opacity var(--t-push) ease-out;
}
.splash.s-push .splash-sky { opacity: 1; }

.splash-beam {
    position: absolute;
    left: 50%; top: 50%;
    width: 240vmax; height: 130vmax;
    margin: -65vmax 0 0 -120vmax;
    background: radial-gradient(ellipse at center,
        rgba(255, 255, 255, .98) 0%,
        rgba(228, 241, 255, .72) 22%,
        rgba(163, 206, 255, .32) 46%,
        rgba(120, 180, 255, 0) 70%);
    opacity: 0;
    transform: scaleX(.015);
    filter: blur(8px);
    transition: transform var(--t-push) cubic-bezier(.22, .8, .28, 1),
                opacity calc(var(--t-push) * .55) ease-out;
    will-change: transform, opacity;
}
.splash.s-push .splash-beam {
    transform: scaleX(1);
    opacity: .92;
}

.splash-door {
    position: absolute;
    top: -2%; bottom: -2%;
    width: 50.2%;
    transform-style: preserve-3d;
    transition: transform var(--t-push) cubic-bezier(.32, .72, .26, 1);
    will-change: transform;
}
.splash-door.l { left: 0; transform-origin: left center; }
.splash-door.r { right: 0; transform-origin: right center; }
.splash.s-push .splash-door.l { transform: rotateY(78deg); }
.splash.s-push .splash-door.r { transform: rotateY(-78deg); }

.door-face {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(180deg, #1f2a39 0%, #17212d 46%, #0f1620 100%);
    box-shadow: inset 0 0 70px rgba(0, 0, 0, .55);
    overflow: hidden;
}

.door-panel {
    position: absolute;
    left: 13%; right: 13%;
    height: 32%;
    border: 1px solid rgba(255, 255, 255, .07);
    border-radius: 3px;
    background: linear-gradient(180deg, rgba(255, 255, 255, .05), rgba(0, 0, 0, .18));
}
.door-panel:nth-child(1) { top: 11%; }
.door-panel:nth-child(2) { bottom: 11%; }

.door-knob {
    position: absolute;
    top: 50%;
    width: 10px; height: 10px;
    margin-top: -5px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #dae6f4, #7d8da1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, .5);
}
.splash-door.l .door-knob { right: 9%; }
.splash-door.r .door-knob { left: 9%; }

.splash-seam {
    position: absolute;
    left: 50%; top: 0; bottom: 0;
    width: 3px;
    margin-left: -1.5px;
    background: linear-gradient(to bottom,
        transparent 0%,
        rgba(255, 255, 255, .5) 14%,
        rgba(255, 255, 255, 1) 50%,
        rgba(255, 255, 255, .5) 86%,
        transparent 100%);
    box-shadow: 0 0 18px 4px rgba(180, 220, 255, .7);
    opacity: 0;
    transform: scaleY(.32);
    transition: opacity var(--t-crack) ease-out, transform var(--t-crack) ease-out;
}
.splash.s-crack .splash-seam { opacity: 1; transform: scaleY(1); }
.splash.s-push .splash-seam {
    opacity: 0;
    transition: opacity calc(var(--t-push) * .35) ease-out;
}

.splash-flood {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(circle at 50% 50%,
        rgba(255, 255, 255, .98) 0%,
        rgba(243, 249, 255, .94) 36%,
        rgba(203, 227, 255, .76) 68%,
        rgba(155, 195, 242, .55) 100%);
    opacity: 0;
    transition: opacity var(--t-flood) ease-out;
}
.splash.s-flood .splash-flood { opacity: .92; }

.splash-skip {
    position: absolute;
    right: max(1rem, env(safe-area-inset-right));
    top: max(1rem, env(safe-area-inset-top));
    padding: 0.45rem 1.1rem;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: background-color 0.2s, color 0.2s;
    z-index: 2;
}
.splash-skip:hover { background: rgba(255, 255, 255, 0.16); color: #fff; }
.splash-skip:active { transform: scale(0.95); }

@media (prefers-reduced-motion: reduce) {
    .splash.s-out { transform: none; transition: opacity 0.2s linear; }
    .splash-door { transition: none; }
    .splash-beam { transition: opacity 0.2s linear; }
}

.cards-converge .version-card {
    animation: cardConverge var(--dur-md) var(--ease-out) forwards;
    animation-delay: var(--conv-delay, 0s);
}
@keyframes cardConverge {
    to {
        transform: translateX(var(--conv-x, 0px)) scale(0.94);
        opacity: 0.15;
    }
}

.cards-return .version-card {
    animation: cardReturn var(--dur-md) var(--ease-out) forwards;
    animation-delay: var(--conv-delay, 0s);
}
@keyframes cardReturn {
    from {
        transform: translateX(var(--conv-x, 0px)) scale(0.94);
        opacity: 0.15;
    }
    to {
        transform: translateX(0) scale(1);
        opacity: 1;
    }
}

@media (max-width: 767px) {
    .volume-btn { width: 32px; height: 32px; font-size: .95rem; }
    .control-btn-small { width: 36px; height: 36px; }
    .play-btn-small { width: 44px; height: 44px; }
    .volume-group { gap: .25rem; padding: .2rem .35rem; }
}

.music-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--ios-blue), #5E5CE6);
    border-radius: 3px;
    transition: width 0.1s linear;
    pointer-events: none;
    box-shadow: 0 0 6px rgba(0, 122, 255, 0.3);
}

.version-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.bottom-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1rem;
}

.version-card {
    background: var(--ios-card);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 1px solid var(--ios-border);
    border-radius: 18px;
    padding: 1.25rem;

    transition: transform var(--dur-sm) var(--ease-std),
                box-shadow var(--dur-sm) var(--ease-std),
                background-color var(--dur-sm) var(--ease-std),
                border-color var(--dur-sm) var(--ease-std);
    text-decoration: none;
    display: block;
    position: relative;
    overflow: hidden;
    box-shadow: var(--ios-shadow);
    cursor: pointer;
}
.version-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), transparent);
    opacity: 0.8;
}
.version-card:hover {
    transform: translateY(-2px) scale(1.01);
    box-shadow: var(--ios-shadow-hover);
    background: rgba(255, 255, 255, 0.95);
    border-color: rgba(0, 122, 255, 0.12);
}
.version-card:active {
    transform: scale(0.975);
    transition: transform var(--dur-xs) var(--ease-std);
}
.version-card.expandable {
    cursor: default;
}
.version-card.expandable:hover {
    transform: translateY(-2px) scale(1.01);
}

.rainbow-card {
    border: 2px solid transparent;
    background-clip: padding-box;
    position: relative;
    z-index: 0;
    overflow: visible;
}
.rainbow-card::after {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    background: linear-gradient(45deg,
            #ff0000, #ff8800, #ffff00,
            #00cc00, #00aaff, #4400ff, #aa00ff);
    background-size: 400% 400%;
    border-radius: 20px;
    z-index: -1;
    animation: rainbowBorder 3s linear infinite;
    filter: blur(3px);
    opacity: 0.9;
}
.rainbow-card:hover::after {
    filter: blur(6px);
    opacity: 1;
    animation-duration: 2s;
}
@keyframes rainbowBorder {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.card-header {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    margin-bottom: 0.75rem;
}
.card-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--ios-blue) 0%, #5856D6 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.2);
}
.card-icon.community-icon {
    background: linear-gradient(135deg, #FF9500 0%, #FF5E3A 100%);
}
.card-icon.service-icon {
    background: linear-gradient(135deg, #34C759 0%, #30B350 100%);
}
.card-icon.author-icon {
    background: linear-gradient(135deg, #5E5CE6, #D4508B);
}
.card-icon svg {
    width: 22px;
    height: 22px;
}

.card-title {
    font-size: 1.125rem;

    font-weight: 600;
    color: #1D1D1F;
    line-height: 1.3;

    letter-spacing: var(--ls-cjk);
}
.card-desc {

    color: var(--ios-gray);
    font-size: 0.8125rem;

    line-height: 1.55;
    margin-bottom: 0.875rem;

    letter-spacing: var(--ls-cjk);
}
.card-tag {
    display: inline-block;
    padding: 0.25rem 0.625rem;
    background: rgba(0, 122, 255, 0.08);
    color: var(--ios-blue);
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    margin-top: 0.5rem;
}
.rainbow-tag {
    background: linear-gradient(90deg, #ff0000, #ff8800, #ffff00, #00cc00, #00aaff, #4400ff, #aa00ff);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: rainbowMove 4s linear infinite;
    font-weight: 700;
    font-size: 0.65rem;
    padding: 0.2rem 0.5rem;
    border: 2px solid transparent;
    border-radius: 12px;
    position: relative;
    background-color: rgba(255, 255, 255, 0.9);
}
.rainbow-tag::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: inherit;
    background-size: inherit;
    border-radius: inherit;
    z-index: -1;
    filter: blur(4px);
    opacity: 0.8;
}

.version-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    font-size: 0.6875rem;
    color: #007AFF;
    background: rgba(0, 122, 255, 0.08);
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
    opacity: 0;
    transition: opacity 0.3s;
}
.version-badge.loaded {
    opacity: 1;
}

.history-section {
    margin-top: 0.75rem;
    width: 100%;
    display: none;
}
.history-section.visible {
    display: block;
}
.history-divider {
    height: 1px;
    background: rgba(0, 0, 0, 0.06);
    margin: 0.75rem 0;
}
.history-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--ios-blue);
    font-size: 0.8125rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.375rem 0;
    user-select: none;
    transition: opacity 0.2s;
}
.history-toggle:hover {
    opacity: 0.8;
}
.toggle-icon {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
    color: var(--ios-blue);
}
.history-toggle.expanded .toggle-icon {
    transform: rotate(180deg);
}
.history-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--dur-md) var(--ease-std);
}
.history-content.expanded {
    max-height: 350px;
    overflow-y: auto;
    margin-top: 0.5rem;
    padding-right: 0.25rem;
}
.history-list {
    padding: 0.25rem 0;
}
.history-item {
    padding: 0.875rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}
.history-item:last-child {
    border-bottom: none;
}
.history-version {
    font-size: 0.9375rem;
    font-weight: 700;
    color: #1D1D1F;
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.history-date {
    font-size: 0.75rem;
    color: var(--ios-gray);
    font-weight: 500;
    background: rgba(142, 142, 147, 0.1);
    padding: 0.125rem 0.5rem;
    border-radius: 6px;
}
.history-body {
    font-size: 0.8125rem;
    color: #3C3C43;
    line-height: 1.6;
    margin-top: 0.5rem;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 1.5rem;
}
.modal.active {
    display: flex;

    animation: modalBackdropIn var(--dur-md) var(--ease-out) forwards;
}

@keyframes modalBackdropIn {

    from { background: rgba(0, 0, 0, 0); }
    to   { background: rgba(0, 0, 0, 0.4); }
}

@keyframes modalBackdropOut {

    from { background: rgba(0, 0, 0, 0.4); }
    to   { background: rgba(0, 0, 0, 0); }
}

@keyframes modalContentOut {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(10px) scale(0.97);
    }
}

.modal.active.closing {
    animation: modalBackdropOut var(--dur-sm) var(--ease-in) forwards;
}
.modal.active.closing .modal-content {
    animation: modalContentOut var(--dur-sm) var(--ease-in) forwards;
}
.modal-content {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: saturate(180%) blur(24px);
    -webkit-backdrop-filter: saturate(180%) blur(24px);
    border-radius: 24px;
    width: 100%;
    max-width: 420px;
    max-height: 90vh;

    max-height: 90dvh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.6);

    animation: modalAppear var(--dur-lg) var(--ease-out);
}
.modal-content.wider {
    max-width: 500px;
}
.modal-content.author-wide {
    max-width: 560px;
}

@keyframes modalAppear {
    0% {
        opacity: 0;
        transform: translateY(12px) scale(0.92);
    }
    60% {
        opacity: 1;
        transform: translateY(0) scale(1.02);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes modalAppearAndroid {
    from {
        opacity: 0;
        transform: translateY(48px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes modalAppearHarmony {
    from {
        opacity: 0;
        transform: scale(0.9);
        border-radius: 48px;
    }
    to {
        opacity: 1;
        transform: scale(1);
        border-radius: 24px;
    }
}

@keyframes modalAppearZoom {
    0% {
        opacity: 0;
        transform: scale(0.72);
    }
    70% {
        opacity: 1;
        transform: scale(1.015);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}
@keyframes modalContentOutZoom {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.88);
    }
}

@keyframes modalContentOutAndroid {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(24px) scale(0.98);
    }
}
@keyframes modalContentOutHarmony {
    from {
        opacity: 1;
        transform: scale(1);
        border-radius: 24px;
    }
    to {
        opacity: 0;
        transform: scale(0.93);
        border-radius: 44px;
    }
}

body[data-modal-anim="ios"] .modal.active .modal-content {
    animation: modalAppear var(--dur-lg) var(--ease-out);
}
body[data-modal-anim="ios"] .modal.active.closing .modal-content {
    animation: modalContentOut var(--dur-sm) var(--ease-in) forwards;
}

body[data-modal-anim="android"] .modal.active .modal-content {
    animation: modalAppearAndroid var(--dur-md) cubic-bezier(0.05, 0.7, 0.1, 1.0);
}
body[data-modal-anim="android"] .modal.active.closing .modal-content {
    animation: modalContentOutAndroid var(--dur-xs) var(--ease-in) forwards;
}

body[data-modal-anim="harmony"] .modal.active .modal-content {
    animation: modalAppearHarmony var(--dur-lg) cubic-bezier(0.2, 0.0, 0.1, 1.0);
}
body[data-modal-anim="harmony"] .modal.active.closing .modal-content {

    animation: modalContentOutHarmony var(--dur-xs) var(--ease-in) forwards;
}

.modal-header {
    padding: 1.75rem;
    text-align: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
}
.modal-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: -0.02em;
    color: #1D1D1F;
    padding-right: 2rem;
}
.modal-subtitle {
    font-size: 0.8125rem;
    color: var(--ios-gray);
    margin-top: 0.25rem;
}
.close-btn {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    background: rgba(142, 142, 147, 0.12);
    border: none;
    border-radius: 50%;
    font-size: 1.25rem;
    color: #8E8E93;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color .2s ease, color .2s ease;
    z-index: 10;
}
.close-btn:hover {
    background: rgba(142, 142, 147, 0.2);
    color: #636366;
}

.close-btn::after {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    width: 44px;
    height: 44px;
    transform: translate(-50%, -50%);
    background: transparent;
}
.modal-body {
    padding: 1.25rem;
    flex: 1;
    overflow-y: auto;
}
.modal-footer {
    padding: 1rem 1.25rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.four-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.875rem;
}
.grid-btn {
    background: rgba(0, 122, 255, 0.06);
    border: 1px solid rgba(0, 122, 255, 0.15);
    color: #1D1D1F;
    padding: 1.25rem 0.75rem;
    border-radius: 16px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    gap: 0.5rem;
}
.grid-btn:hover {
    background: rgba(0, 122, 255, 0.1);
    border-color: rgba(0, 122, 255, 0.25);
    transform: translateY(-1px);
}
.grid-btn:active {
    transform: scale(0.97);
}
.grid-btn svg {
    width: 28px;
    height: 28px;
    color: var(--ios-blue);
}
.grid-label {
    font-size: 0.8125rem;
    text-align: center;
    line-height: 1.3;
}
.tag-query {
    background: rgba(0, 122, 255, 0.08);
    color: #007AFF;
    font-size: 0.6875rem;
    padding: 0.125rem 0.5rem;
    border-radius: 10px;
    font-weight: 500;
}

.option-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.option-btn {
    background: rgba(0, 122, 255, 0.06);
    border: 1px solid rgba(0, 122, 255, 0.15);
    color: #1D1D1F;
    padding: 1rem;
    border-radius: 14px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
}
.option-btn:hover {
    background: rgba(0, 122, 255, 0.1);
    border-color: rgba(0, 122, 255, 0.25);
    transform: translateX(2px);
}
.option-btn:active {
    transform: scale(0.98);
}
.option-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.tag-community {
    background: rgba(255, 149, 0, 0.1);
    color: #FF9500;
    font-size: 0.6875rem;
    padding: 0.125rem 0.5rem;
    border-radius: 10px;
    font-weight: 500;
}
.tag-service {
    background: rgba(52, 199, 89, 0.1);
    color: #34C759;
    font-size: 0.6875rem;
    padding: 0.125rem 0.5rem;
    border-radius: 10px;
    font-weight: 500;
}
.arrow-icon {
    width: 20px;
    height: 20px;
    color: var(--ios-gray);
}

.btn-secondary {
    background: rgba(142, 142, 147, 0.12);
    color: var(--ios-blue);
    border: none;
    padding: 0.875rem;
    border-radius: 14px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .2s ease, transform .12s ease-out;
    text-align: center;
    -webkit-tap-highlight-color: transparent;
}
.btn-secondary:hover {
    background: rgba(142, 142, 147, 0.18);
}

.btn-secondary:active {
    transform: scale(0.97);
    background: rgba(142, 142, 147, 0.24);
}

.authors-duo {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    max-width: 420px;
    margin: 0 auto;
}

.author-liquid {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
    border-radius: 28px;
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.05);
    transition: transform var(--dur-md) var(--ease-std),
                box-shadow var(--dur-md) var(--ease-std),
                border-color var(--dur-md) var(--ease-std);
    position: relative;
    overflow: hidden;
}
.author-liquid:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.1);
    border-color: rgba(255, 255, 255, 0.9);
}
.author-liquid::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9), transparent);
    opacity: 0.6;
}

.author-liquid.accent-theme {
    background: rgba(255, 255, 255, 0.45);
    box-shadow: 0 12px 32px rgba(0, 122, 255, 0.06), 0 4px 12px rgba(94, 92, 230, 0.04);
}
.author-liquid.accent-theme:hover {
    box-shadow: 0 20px 48px rgba(0, 122, 255, 0.12), 0 8px 20px rgba(94, 92, 230, 0.08);
}

.author-avatar {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
    transition: transform 0.3s ease;
    flex-shrink: 0;
}
.author-liquid:hover .author-avatar {
    transform: scale(1.05);
}

.author-avatar-placeholder {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.02em;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    transition: transform 0.3s ease;
    flex-shrink: 0;
    user-select: none;
    background: linear-gradient(135deg, #5E5CE6 0%, #D4508B 100%);
}
.author-liquid:hover .author-avatar-placeholder {
    transform: scale(1.05);
}

.author-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #1D1D1F;
    letter-spacing: -0.01em;
}
.author-role {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--ios-gray);
    margin-top: -0.4rem;
    letter-spacing: 0.02em;
}

.author-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.author-tag-item {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    color: #1D1D1F;
    font-size: 0.75rem;
    font-weight: 500;
    padding: 0.2rem 0.7rem;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.7);
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    transition: background-color .2s, border-color .2s, transform .2s;
    white-space: nowrap;
    letter-spacing: -0.01em;
}
.author-tag-item:hover {
    background: rgba(255, 255, 255, 0.85);
    border-color: rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}
.author-tag-item svg {
    flex-shrink: 0;
    opacity: 0.65;
    width: 12px;
    height: 12px;
}

.author-tag-item.blue-highlight {
    background: rgba(0, 122, 255, 0.08);
    border-color: rgba(0, 122, 255, 0.2);
    color: #007AFF;
    font-weight: 600;
}
.author-tag-item.blue-highlight svg {
    opacity: 0.9;
    color: #007AFF;
}

.author-tg {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--ios-blue);
    text-decoration: none;
    background: rgba(0, 122, 255, 0.08);
    padding: 0.3rem 1rem;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: background-color .2s, transform .2s;
    letter-spacing: -0.01em;
}
.author-tg:hover {
    background: rgba(0, 122, 255, 0.15);
    transform: translateY(-1px);
}
.author-tg svg {
    width: 16px;
    height: 16px;
}

.toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 12px;
    font-size: 0.875rem;
    opacity: 0;
    pointer-events: none;

    transition: opacity var(--dur-sm) var(--ease-out), transform var(--dur-sm) var(--ease-spring);
    z-index: 2000;
    backdrop-filter: blur(10px);
}
.toast.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.dynamic-island {
    position: fixed;
    top: 40px;
    left: 50%;
    transform: translateX(-50%) translateY(-120px);
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(28px) saturate(200%);
    -webkit-backdrop-filter: blur(28px) saturate(200%);
    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: 36px;
    padding: 0.9rem 1.8rem 0.7rem;
    color: #1D1D1F;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
    z-index: 3000;
    pointer-events: none;
    transition: transform var(--dur-lg) var(--ease-spring);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    min-width: 220px;
    white-space: nowrap;
}
.dynamic-island.show {
    transform: translateX(-50%) translateY(0);
}

.island-password {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: #1D1D1F;
    position: relative;
}
.island-password .island-icon {
    font-size: 1rem;
    opacity: 0.8;
    margin-right: 2px;
}
.password-label {
    font-size: 0.75rem;
    font-weight: 500;
    color: #8E8E93;
    background: rgba(0, 0, 0, 0.04);
    padding: 2px 8px;
    border-radius: 10px;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}
.password-digits {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: #1D1D1F;
    text-shadow: 0 0 12px rgba(0, 122, 255, 0.15);
    font-variant-numeric: tabular-nums;
    position: relative;
}
.password-digits::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: radial-gradient(ellipse at center, rgba(0, 122, 255, 0.4) 0%, transparent 70%);
    filter: blur(2px);
    opacity: 0;
    animation: digitGlow 2s ease-in-out infinite;
}
@keyframes digitGlow {
    0%,
    100% {
        opacity: 0;
    }
    50% {
        opacity: 0.9;
    }
}
.island-progress {
    width: 100%;
    height: 4px;
    background: rgba(0, 0, 0, 0.06);
    border-radius: 4px;
    overflow: hidden;
}
.island-progress-bar {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, var(--ios-blue), #5E5CE6);
    border-radius: 4px;

    transform-origin: left center;
}

@keyframes shrinkProgress {
    from {
        transform: scaleX(1);
    }
    to {
        transform: scaleX(0);
    }
}

.island-progress-bar.animate {
    animation: shrinkProgress 3s linear forwards;
}

@media (max-width: 767px) {
    .container {
        padding: 1.5rem 1rem;
    }
    .top-bar {
        padding: 0.9rem 1rem;
        gap: 0.8rem;
    }
    .music-inline {
        gap: 0.5rem;
    }
    .song-name {
        max-width: 80px;
        font-size: 0.9rem;
    }
    .motto-tag {
        font-size: 0.65rem;
        padding: 0.15rem 0.5rem;
    }
    .beijing-fulltime {
        font-size: 0.72rem;
        padding: 0.2rem 0.6rem;
    }
    .volume-group {
        gap: 0.1rem;
        padding: 0.15rem 0.3rem;
    }
    .volume-btn {
        width: 26px;
        height: 26px;
        font-size: 0.8rem;
    }
    .control-btn-small {
        width: 30px;
        height: 30px;
    }
    .play-btn-small {
        width: 38px;
        height: 38px;
    }
    .music-progress-row {
        padding: 0.4rem 0.7rem;
    }
    .music-time {
        font-size: 0.7rem;
        min-width: 32px;
    }

    .version-grid,
    .bottom-cards {
        grid-template-columns: 1fr;
        gap: 0.7rem;
    }

    .version-card {
        padding: 0.9rem 0.95rem;
        border-radius: 16px;
    }

    .card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
        margin-bottom: 0.5rem;
    }
    .card-icon {
        width: 48px;
        height: 48px;
        min-width: 48px;
        border-radius: 14px;
        font-size: 22px;
    }
    .card-title {
        font-size: 1.1rem;
        line-height: 1.3;

        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    .card-desc {
        font-size: 0.78rem;
        line-height: 1.5;
        margin-bottom: 0.5rem;
    }
    .card-tag {
        font-size: 0.7rem;
        padding: 0.16rem 0.5rem;
        margin-top: 0.25rem;
    }

    .version-badge {
        font-size: 0.66rem;
        padding: 2px 8px;
        top: 0.7rem;
        right: 0.8rem;
    }
    .four-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .modal-content {
        max-width: 92vw;
    }
    .modal-content.author-wide {
        max-width: 94vw;
    }
    .authors-duo {
        max-width: 100%;
        gap: 1rem;
    }
    .author-liquid {
        padding: 1.5rem 1rem 1.25rem;
        gap: 0.7rem;
    }
    .author-avatar,
    .author-avatar-placeholder {
        width: 68px;
        height: 68px;
        font-size: 1.8rem;
    }
    .author-name {
        font-size: 1.15rem;
    }
    .author-role {
        font-size: 0.7rem;
    }
    .author-tag-item {
        font-size: 0.65rem;
        padding: 0.15rem 0.5rem;
    }
    .author-tg {
        font-size: 0.8rem;
        padding: 0.25rem 0.8rem;
    }
    .dynamic-island {
        padding: 0.75rem 1.5rem 0.6rem;
        border-radius: 28px;
        min-width: 190px;
    }
    .island-password {
        font-size: 0.85rem;
    }
    .password-digits {
        font-size: 1.3rem;
    }
    .password-label {
        font-size: 0.65rem;
    }
    .island-progress {
        height: 3px;
    }
}

@media (max-width: 380px) {
    .version-card { padding: 0.9rem 0.95rem; border-radius: 16px; }
    .card-icon { width: 48px; height: 48px; min-width: 48px; border-radius: 14px; font-size: 22px; }
    .card-title { font-size: 1.1rem; }
    .card-desc { font-size: 0.78rem; }
}

@media (max-width: 380px) {
    .authors-duo {
        gap: 0.75rem;
    }
    .author-liquid {
        padding: 1.25rem 0.75rem 1rem;
        border-radius: 20px;
    }
    .author-avatar,
    .author-avatar-placeholder {
        width: 56px;
        height: 56px;
        font-size: 1.5rem;
    }
    .author-name {
        font-size: 1.05rem;
    }
    .author-tags {
        gap: 0.3rem;
    }
    .author-tag-item {
        font-size: 0.6rem;
        padding: 0.12rem 0.4rem;
        border-radius: 10px;
    }
}

@keyframes cardStaggerIn {
    from {
        opacity: 0;
        transform: translate3d(0, var(--st-y, 16px), 0) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }
}
.version-card.stagger-in {

    animation: cardStaggerIn var(--dur-lg) var(--ease-out) backwards;
    animation-delay: var(--st-delay, 0s);
}

.version-card.nojump.stagger-in {
    animation: none;
    opacity: 0.6;
}

@media (prefers-reduced-motion: reduce) {
    .version-card.stagger-in {
        animation: fadeIn 0.3s ease both;
        animation-delay: var(--st-delay, 0s);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
.fade-in {
    animation: fadeIn var(--dur-md) var(--ease-std) both;
}

.version-card.nojump.fade-in {
    animation: none;
    opacity: 0.6;
}

.card-icon {
    font-size: 20px;
}
.card-icon img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    border-radius: 5px;
}

.card-icon.style-orange {
    background: linear-gradient(135deg, #FF9500 0%, #FF5E3A 100%);
    box-shadow: 0 2px 8px rgba(255, 94, 58, 0.2);
}
.card-icon.style-green {
    background: linear-gradient(135deg, #34C759 0%, #30B350 100%);
    box-shadow: 0 2px 8px rgba(52, 199, 89, 0.2);
}
.card-icon.style-purple {
    background: linear-gradient(135deg, #5E5CE6 0%, #D4508B 100%);
    box-shadow: 0 2px 8px rgba(94, 92, 230, 0.2);
}
.card-icon.style-red {
    background: linear-gradient(135deg, #FF3B30 0%, #FF2D55 100%);
    box-shadow: 0 2px 8px rgba(255, 59, 48, 0.2);
}
.card-icon.style-teal {
    background: linear-gradient(135deg, #32ADE6 0%, #5E5CE6 100%);
    box-shadow: 0 2px 8px rgba(50, 173, 230, 0.2);
}
.card-icon.style-pink {
    background: linear-gradient(135deg, #FF2D55 0%, #D4508B 100%);
    box-shadow: 0 2px 8px rgba(255, 45, 85, 0.2);
}
.card-icon.style-indigo {
    background: linear-gradient(135deg, #5856D6 0%, #AF52DE 100%);
    box-shadow: 0 2px 8px rgba(88, 86, 214, 0.2);
}

.version-card.nojump {
    opacity: 0.6;
}
.version-card.nojump .card-icon {
    filter: grayscale(0.65);
}
.version-card.nojump .card-tag {
    background: rgba(142, 142, 147, 0.12);
    color: #8E8E93;
}
.version-card.nojump .card-tag.rainbow-tag {
    background: none;
    -webkit-text-fill-color: #8E8E93;
    animation: none;
    border-color: rgba(142, 142, 147, 0.2);
}
.version-card.nojump .card-tag.rainbow-tag::after {
    display: none;
}
.grid-btn.nojump,
.option-btn.nojump {
    opacity: 0.5;
}
.grid-btn.nojump:hover,
.option-btn.nojump:hover {
    transform: none;
}

.grid-btn .emoji-icon {
    font-size: 26px;
    line-height: 1;
}
.grid-btn img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.site-footer {
    margin-top: 2.25rem;
    text-align: center;
    font-size: 0.75rem;
    color: var(--ios-gray);
    line-height: 1.8;
}
.site-notice {
    color: #86868B;
    margin-bottom: 0.35rem;
}
.site-footer a {
    color: var(--ios-blue);
    text-decoration: none;
}

.card-classic {

}

.tone-blue   { --tone-1: #007AFF; --tone-2: #5856D6; }
.tone-orange { --tone-1: #FF9500; --tone-2: #FF5E3A; }
.tone-green  { --tone-1: #34C759; --tone-2: #30B350; }
.tone-purple { --tone-1: #5E5CE6; --tone-2: #D4508B; }
.tone-red    { --tone-1: #FF3B30; --tone-2: #FF2D55; }
.tone-teal   { --tone-1: #32ADE6; --tone-2: #5E5CE6; }
.tone-pink   { --tone-1: #FF2D55; --tone-2: #D4508B; }
.tone-indigo { --tone-1: #5856D6; --tone-2: #AF52DE; }

.card-banner {
    padding: 0;
    overflow: hidden;
    border: none;
}
.card-banner::before { display: none; }
.card-banner .version-badge {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}
.card-banner .bn-row {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 1.15rem 1.25rem;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
    color: #fff;
}
.card-banner .bn-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.card-banner .bn-icon svg { width: 22px; height: 22px; color: #fff; }
.card-banner .bn-icon img { width: 22px; height: 22px; border-radius: 5px; object-fit: contain; }
.card-banner .bn-icon .emoji-icon { font-size: 22px; }
.card-banner .bn-text { flex: 1; min-width: 0; }
.card-banner .bn-title {
    font-size: 1.0625rem;
    font-weight: 600;
    line-height: 1.25;
    color: #fff;
}
.card-banner .bn-desc {
    font-size: 0.8125rem;
    line-height: 1.45;
    margin-top: 0.15rem;
    color: rgba(255, 255, 255, 0.88);
}
.card-banner .bn-tag {
    flex-shrink: 0;
    padding: 0.25rem 0.7rem;
    background: rgba(255, 255, 255, 0.95);
    color: var(--tone-1, #007AFF);
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

.card-banner .bn-tag.rainbow-tag {
    background: rgba(255, 255, 255, 0.95);
}

.card-compact {
    padding: 0.85rem 1.15rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}
.card-compact .cp-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--ios-blue) 0%, #5856D6 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0, 122, 255, 0.18);
}
.card-compact .cp-icon svg { width: 17px; height: 17px; color: #fff; }
.card-compact .cp-icon img { width: 17px; height: 17px; border-radius: 4px; object-fit: contain; }
.card-compact .cp-icon .emoji-icon { font-size: 17px; }
.card-compact .cp-icon.style-orange { background: linear-gradient(135deg, #FF9500 0%, #FF5E3A 100%); box-shadow: 0 2px 6px rgba(255, 94, 58, 0.18); }
.card-compact .cp-icon.style-green  { background: linear-gradient(135deg, #34C759 0%, #30B350 100%); box-shadow: 0 2px 6px rgba(52, 199, 89, 0.18); }
.card-compact .cp-icon.style-purple { background: linear-gradient(135deg, #5E5CE6 0%, #D4508B 100%); box-shadow: 0 2px 6px rgba(94, 92, 230, 0.18); }
.card-compact .cp-icon.style-red    { background: linear-gradient(135deg, #FF3B30 0%, #FF2D55 100%); box-shadow: 0 2px 6px rgba(255, 59, 48, 0.18); }
.card-compact .cp-icon.style-teal   { background: linear-gradient(135deg, #32ADE6 0%, #5E5CE6 100%); box-shadow: 0 2px 6px rgba(50, 173, 230, 0.18); }
.card-compact .cp-icon.style-pink   { background: linear-gradient(135deg, #FF2D55 0%, #D4508B 100%); box-shadow: 0 2px 6px rgba(255, 45, 85, 0.18); }
.card-compact .cp-icon.style-indigo { background: linear-gradient(135deg, #5856D6 0%, #AF52DE 100%); box-shadow: 0 2px 6px rgba(88, 86, 214, 0.18); }
.card-compact .cp-main { flex: 1; min-width: 0; }
.card-compact .cp-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #1D1D1F;
    line-height: 1.3;
}
.card-compact .cp-desc {
    font-size: 0.75rem;
    color: var(--ios-gray);
    line-height: 1.4;
    margin-top: 0.1rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.card-compact .cp-tag {
    flex-shrink: 0;
    padding: 0.15rem 0.5rem;
    background: rgba(0, 122, 255, 0.08);
    color: var(--ios-blue);
    border-radius: 10px;
    font-size: 0.6875rem;
    font-weight: 500;
    white-space: nowrap;
}
.card-compact .cp-arrow {
    width: 17px;
    height: 17px;
    color: #C7C7CC;
    flex-shrink: 0;
}

.card-cover { padding: 0; overflow: hidden; }
.card-cover .cv-img {
    width: 100%;
    height: 140px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: rgba(0, 0, 0, 0.04);
}

.card-cover .cv-img.cv-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0, 122, 255, 0.08) 0%, rgba(94, 92, 230, 0.08) 100%);
}
.card-cover .cv-empty svg { width: 34px; height: 34px; color: var(--ios-blue); opacity: 0.5; }
.card-cover .cv-empty img { width: 34px; height: 34px; opacity: 0.5; }
.card-cover .cv-empty .emoji-icon { font-size: 32px; opacity: 0.5; }
.card-cover .cv-body { padding: 1rem 1.25rem 1.15rem; }
.card-cover .version-badge {
    background: rgba(255, 255, 255, 0.9);
    top: 152px;
}

.card-minimal {
    background: transparent;
    border: 1px solid transparent;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    padding: 0.6rem 0.25rem;
}
.card-minimal::before { display: none; }
.card-minimal:hover {
    background: rgba(255, 255, 255, 0.5);
    border-color: transparent;
    box-shadow: none;
    transform: none;
}
.card-minimal .mn-row { display: flex; align-items: center; gap: 0.7rem; }
.card-minimal .mn-icon {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 9px;
    background: rgba(0, 122, 255, 0.1);
}
.card-minimal .mn-icon svg { width: 16px; height: 16px; color: var(--ios-blue); }
.card-minimal .mn-icon img { width: 16px; height: 16px; border-radius: 4px; object-fit: contain; }
.card-minimal .mn-icon .emoji-icon { font-size: 16px; }
.card-minimal .mn-text { flex: 1; min-width: 0; }
.card-minimal .mn-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #1D1D1F;
    line-height: 1.3;
}
.card-minimal .mn-desc {
    font-size: 0.78rem;
    color: var(--ios-gray);
    line-height: 1.45;
    margin-top: 0.1rem;
}
.card-minimal .mn-tag {
    display: inline-block;
    margin-top: 0.5rem;
    padding: 0.2rem 0.55rem;
    background: rgba(0, 122, 255, 0.08);
    color: var(--ios-blue);
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 500;
}

.card-glass {
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: saturate(180%) blur(30px);
    -webkit-backdrop-filter: saturate(180%) blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    text-align: center;
    padding: 1.75rem 1.25rem 1.5rem;
}
.card-glass .gs-icon {
    width: 58px;
    height: 58px;
    margin: 0 auto 0.875rem;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}
.card-glass .gs-icon svg { width: 28px; height: 28px; color: #fff; }
.card-glass .gs-icon img { width: 28px; height: 28px; border-radius: 7px; object-fit: contain; }
.card-glass .gs-icon .emoji-icon { font-size: 28px; }
.card-glass .gs-title {
    font-size: 1.125rem;
    font-weight: 650;
    color: #1D1D1F;
    line-height: 1.3;
}
.card-glass .gs-desc {
    font-size: 0.8125rem;
    color: var(--ios-gray);
    line-height: 1.55;
    margin-top: 0.4rem;
}
.card-glass .gs-tag {
    display: inline-block;
    margin-top: 0.875rem;
    padding: 0.3rem 0.9rem;
    border-radius: 14px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
}

.card-spotlight {
    text-align: center;
    padding: 2rem 1.25rem 1.6rem;
}
.card-spotlight::before { display: none; }
.card-spotlight .sp-icon {
    width: 76px;
    height: 76px;
    margin: 0 auto 1.1rem;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16);
    position: relative;
}

.card-spotlight .sp-icon::after {
    content: '';
    position: absolute;
    top: -8px; left: -8px; right: -8px; bottom: -8px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--tone-1, #007AFF) 0%, transparent 70%);
    opacity: 0.18;
    filter: blur(8px);
    z-index: -1;
}
.card-spotlight .sp-icon svg { width: 34px; height: 34px; color: #fff; }
.card-spotlight .sp-icon img { width: 34px; height: 34px; border-radius: 8px; object-fit: contain; }
.card-spotlight .sp-icon .emoji-icon { font-size: 34px; }
.card-spotlight .sp-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #1D1D1F;
    line-height: 1.25;
    letter-spacing: -0.01em;
}
.card-spotlight .sp-desc {
    font-size: 0.8125rem;
    color: var(--ios-gray);
    line-height: 1.6;
    margin-top: 0.5rem;
}
.card-spotlight .sp-tag {
    display: inline-block;
    margin-top: 1rem;
    padding: 0.35rem 1.1rem;
    border-radius: 16px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
}
.card-spotlight .sp-tag.rainbow-tag {
    background: linear-gradient(90deg, #ff0000, #ff8800, #ffff00, #00cc00, #00aaff, #4400ff, #aa00ff);
    -webkit-text-fill-color: #fff;
}
.card-spotlight .version-badge { top: 14px; right: 14px; }

.card-neon {
    background: linear-gradient(160deg, #1C1C1E 0%, #2C2C2E 100%);
    border: 1px solid var(--tone-1, #007AFF);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04) inset,
                0 0 16px -2px var(--tone-1, #007AFF),
                0 0 32px -8px var(--tone-1, #007AFF);
}
.card-neon::before { display: none; }
.card-neon:hover {
    background: linear-gradient(160deg, #232325 0%, #333336 100%);
    border-color: var(--tone-1, #007AFF);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06) inset,
                0 0 22px 0px var(--tone-1, #007AFF),
                0 0 44px -6px var(--tone-1, #007AFF);
}
.card-neon .ne-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 0 14px -2px var(--tone-1, #007AFF);
}
.card-neon .ne-icon svg { width: 22px; height: 22px; color: #fff; }
.card-neon .ne-icon img { width: 22px; height: 22px; border-radius: 5px; object-fit: contain; }
.card-neon .ne-icon .emoji-icon { font-size: 22px; }
.card-neon .ne-title {
    font-size: 1.125rem;
    font-weight: 650;
    color: #fff;
    line-height: 1.25;
}
.card-neon .ne-desc {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.62);
    line-height: 1.6;
    margin-top: 0.5rem;
}
.card-neon .ne-tag {
    display: inline-block;
    margin-top: 0.75rem;
    padding: 0.25rem 0.8rem;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--tone-1, #007AFF);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--tone-1, #007AFF);
}

.card-neon .history-divider { background: rgba(255, 255, 255, 0.1); }
.card-neon .history-toggle { color: var(--tone-1, #007AFF); }
.card-neon .history-version { color: #fff; }
.card-neon .history-date { background: rgba(255, 255, 255, 0.1); color: rgba(255, 255, 255, 0.7); }
.card-neon .history-body { color: rgba(255, 255, 255, 0.66); }
.card-neon .version-badge {
    background: rgba(255, 255, 255, 0.12);
    color: var(--tone-1, #007AFF);
}

.card-neon.nojump { box-shadow: none; border-color: rgba(255, 255, 255, 0.16); }

.card-ticket {
    display: flex;
    align-items: stretch;
    padding: 0;
    overflow: hidden;
}
.card-ticket::before { display: none; }
.card-ticket .tk-left {
    flex: 1;
    min-width: 0;
    padding: 1.1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.85rem;
}
.card-ticket .tk-icon {
    width: 42px;
    height: 42px;
    border-radius: 11px;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}
.card-ticket .tk-icon svg { width: 21px; height: 21px; color: #fff; }
.card-ticket .tk-icon img { width: 21px; height: 21px; border-radius: 5px; object-fit: contain; }
.card-ticket .tk-icon .emoji-icon { font-size: 21px; }
.card-ticket .tk-text { flex: 1; min-width: 0; }
.card-ticket .tk-title {
    font-size: 1rem;
    font-weight: 650;
    color: #1D1D1F;
    line-height: 1.3;
}
.card-ticket .tk-desc {
    font-size: 0.78rem;
    color: var(--ios-gray);
    line-height: 1.5;
    margin-top: 0.25rem;
}

.card-ticket .tk-stub {
    flex: 0 0 auto;
    min-width: 96px;
    padding: 1.1rem 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    border-left: 2px dashed rgba(0, 0, 0, 0.12);
    background: rgba(0, 0, 0, 0.02);
}
.card-ticket .tk-stub-val {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--tone-1, #007AFF);
    line-height: 1.2;
    text-align: center;
    word-break: break-all;
}
.card-ticket .tk-stub-label {
    font-size: 0.68rem;
    color: var(--ios-gray);
    text-align: center;
}

.card-ticket .tk-stub.tk-empty { display: none; }
.card-ticket .version-badge { top: 10px; right: 10px; }

.card-stat {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.4rem;
}
.card-stat .st-icon {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    background: linear-gradient(135deg, var(--tone-1, #007AFF) 0%, var(--tone-2, #5856D6) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);
}
.card-stat .st-icon svg { width: 23px; height: 23px; color: #fff; }
.card-stat .st-icon img { width: 23px; height: 23px; border-radius: 6px; object-fit: contain; }
.card-stat .st-icon .emoji-icon { font-size: 23px; }
.card-stat .st-main { flex: 1; min-width: 0; }
.card-stat .st-title {
    font-size: 1rem;
    font-weight: 650;
    color: #1D1D1F;
    line-height: 1.3;
}
.card-stat .st-desc {
    font-size: 0.78rem;
    color: var(--ios-gray);
    line-height: 1.5;
    margin-top: 0.25rem;
}

.card-stat .st-value {
    flex: 0 0 auto;
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--tone-1, #007AFF);
    line-height: 1;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.02em;
}
.card-stat .st-value.st-empty { display: none; }
.card-stat .version-badge { display: none; }

@media (max-width: 767px) {
    .card-banner .bn-row { padding: 1rem; gap: 0.75rem; }
    .card-banner .bn-icon { width: 40px; height: 40px; }
    .card-banner .bn-icon svg { width: 20px; height: 20px; }
    .card-banner .bn-title { font-size: 1rem; }
    .card-banner .bn-desc { font-size: 0.75rem; }

    .card-banner .bn-row { flex-wrap: wrap; }
    .card-banner .bn-text { flex: 1 1 60%; }
    .card-banner .bn-tag { margin-left: calc(40px + 0.75rem); }

    .card-compact { padding: 0.75rem 1rem; gap: 0.7rem; }
    .card-compact .cp-icon { width: 32px; height: 32px; }
    .card-compact .cp-title { font-size: 0.9rem; }
    .card-compact .cp-desc { font-size: 0.7rem; }

    .card-cover .cv-img { height: 120px; }
    .card-cover .cv-body { padding: 0.9rem 1rem 1rem; }

    .card-glass { padding: 1.4rem 1rem 1.2rem; }
    .card-glass .gs-icon { width: 50px; height: 50px; }
    .card-glass .gs-title { font-size: 1.05rem; }

    .card-spotlight { padding: 1.6rem 1rem 1.3rem; }
    .card-spotlight .sp-icon { width: 64px; height: 64px; }
    .card-spotlight .sp-icon svg { width: 29px; height: 29px; }
    .card-spotlight .sp-icon img { width: 29px; height: 29px; }
    .card-spotlight .sp-icon .emoji-icon { font-size: 29px; }
    .card-spotlight .sp-title { font-size: 1.15rem; }

    .card-ticket .tk-left { padding: 0.9rem 1rem; gap: 0.7rem; }
    .card-ticket .tk-icon { width: 38px; height: 38px; }
    .card-ticket .tk-icon svg { width: 19px; height: 19px; }
    .card-ticket .tk-stub { min-width: 78px; padding: 0.9rem 0.7rem; }
    .card-ticket .tk-stub-val { font-size: 0.95rem; }

    .card-stat { padding: 1rem 1.1rem; gap: 0.8rem; }
    .card-stat .st-icon { width: 40px; height: 40px; }
    .card-stat .st-icon svg { width: 20px; height: 20px; }
    .card-stat .st-value { font-size: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
    .version-card, .bg-layer,
    .modal.active, .modal.active.closing,
    .modal-content, .modal.active.closing .modal-content {
        animation: none !important;
        transition: none !important;
    }

    body[data-modal-anim] .modal.active .modal-content,
    body[data-modal-anim] .modal.active.closing .modal-content {
        animation: none !important;
    }
}

.version-card:focus-visible,
.modal a:focus-visible,
.modal button:focus-visible,
.top-bar button:focus-visible,
.music-progress-wrap:focus-visible {
    outline: 3px solid #007AFF;
    outline-offset: 3px;
    border-radius: 18px;
}
.version-card:focus-visible {

    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(0, 122, 255, .18), 0 0 0 6px rgba(0, 122, 255, .10);
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 9999;
    padding: 10px 18px;
    background: #007AFF;
    color: #fff;
    border-radius: 0 0 12px 0;
    font-size: 14px;
    text-decoration: none;
}
.skip-link:focus {
    left: 0;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
        scroll-behavior: auto !important;
    }

    .rainbow-text,
    .rainbow-tag,
    .rainbow-card::after {
        animation: none !important;
    }
    .version-card:hover {
        transform: none;
    }

    .island-progress-bar.animate {
        animation-duration: 3s !important;
    }
}

@media (prefers-contrast: more) {
    .version-card {
        background: #fff;
        border: 2px solid #000;
    }
    .card-desc {
        color: #1D1D1F;
    }
    .card-tag {
        background: #fff;
        border: 1px solid #007AFF;
    }
    .top-bar {
        background: #fff;
        border: 2px solid #000;
    }
}

@media print {
    .top-bar,
    .background-elements,
    .bg-layer,
    .dynamic-island,
    .modal,
    .toast,
    .site-footer a {
        display: none !important;
    }
    body {
        background: #fff !important;
    }
    .version-card {
        background: #fff !important;
        border: 1px solid #999 !important;
        box-shadow: none !important;
        break-inside: avoid;
        page-break-inside: avoid;
    }
    .container {
        max-width: 100%;
        padding: 0;
    }
}

.card-title, .card-desc, .history-body, .history-version,
.grid-label, .option-label, .author-name, .author-role,
.song-name, .card-tag, .version-badge {
    overflow-wrap: break-word;
    word-wrap: break-word;
    word-break: break-word;
}

img, video, svg {
    max-width: 100%;
}

.version-card.has-bg {
    background-repeat: no-repeat;
}

@media (prefers-reduced-transparency: reduce) {
    .top-bar,
    .version-card,
    .modal-content,
    .author-liquid,
    .music-progress-row,
    .dynamic-island,
    .author-tag-item,
    .motto-tag,
    .beijing-fulltime,
    .volume-group,
    .control-btn-small {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
    .top-bar, .version-card, .modal-content, .author-liquid {
        background: #fff;
    }
}

@supports (padding: env(safe-area-inset-bottom)) {
    .container {
        padding-left: max(1.5rem, env(safe-area-inset-left));
        padding-right: max(1.5rem, env(safe-area-inset-right));
        padding-bottom: calc(3rem + env(safe-area-inset-bottom));
    }

    .modal-footer {
        padding-bottom: calc(1.25rem + env(safe-area-inset-bottom));
    }

    .dynamic-island {
        top: calc(40px + env(safe-area-inset-top));
    }
}
@media (max-width: 767px) {
    @supports (padding: env(safe-area-inset-left)) {
        .container {
            padding-left: max(1rem, env(safe-area-inset-left));
            padding-right: max(1rem, env(safe-area-inset-right));
        }
    }
}

@media (max-width: 767px) {
    .volume-btn,
    .control-btn-small {
        position: relative;
    }
    .volume-btn::after,
    .control-btn-small::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 44px;
        height: 44px;
        transform: translate(-50%, -50%);

    }

    .volume-btn::after {
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 900px) and (orientation: landscape) and (max-height: 500px) {
    .container {
        padding-top: 1rem;
        padding-bottom: 1.5rem;
    }
    .top-bar {
        padding: 0.6rem 0.9rem;
        margin-bottom: 1rem;
        border-radius: 22px;
    }
    .top-avatar {
        width: 44px;
        height: 44px;
        border-radius: 14px;
    }
    .music-progress-row {
        padding: 0.3rem 0.6rem;
    }

}

.version-card.has-bg {
    background-image:
        linear-gradient(rgba(0, 0, 0, var(--cbgdim, 0)), rgba(0, 0, 0, var(--cbgdim, 0))),
        var(--cbg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-color: rgba(255, 255, 255, .18);
}

.version-card.has-bg .card-title,
.version-card.has-bg .bn-title,
.version-card.has-bg .cp-title,
.version-card.has-bg .gs-title,
.version-card.has-bg .mn-title,
.version-card.has-bg .ne-title,
.version-card.has-bg .sp-title,
.version-card.has-bg .st-title,
.version-card.has-bg .tk-title {
    color: #fff;
    text-shadow: 0 1px 3px rgba(0, 0, 0, .35);
}
.version-card.has-bg .card-desc,
.version-card.has-bg .bn-desc,
.version-card.has-bg .cp-desc,
.version-card.has-bg .gs-desc,
.version-card.has-bg .mn-desc,
.version-card.has-bg .ne-desc,
.version-card.has-bg .sp-desc,
.version-card.has-bg .st-desc,
.version-card.has-bg .tk-desc {
    color: rgba(255, 255, 255, .88);
    text-shadow: 0 1px 2px rgba(0, 0, 0, .3);
}

.version-card.has-bg .card-tag {
    background: rgba(255, 255, 255, .22);
    color: #fff;
}

.version-card.has-bg .cp-arrow {
    color: rgba(255, 255, 255, .7);
}

.card-bg-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
    border-radius: inherit;
}

.version-card.has-bg > .card-header,
.version-card.has-bg > .card-desc,
.version-card.has-bg > .card-tag,
.version-card.has-bg > .history-section,
.version-card.has-bg > .version-badge,
.version-card.has-bg > .cv-body,
.version-card.has-bg > .sp-icon,
.version-card.has-bg > .st-body,
.version-card.has-bg > .bn-body,
.version-card.has-bg > .cp-body,
.version-card.has-bg > .gs-body,
.version-card.has-bg > .mn-body,
.version-card.has-bg > .ne-body,
.version-card.has-bg > .tk-body,
.version-card.has-bg > .tk-stub {
    position: relative;
    z-index: 2;
}

.version-card.has-bg {
    isolation: isolate;
}

.version-card.has-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, var(--cbgdim, 0));
    z-index: 1;
    pointer-events: none;
    border-radius: inherit;
}

@media (prefers-reduced-motion: reduce) {

    .card-bg-video {
        display: none;
    }
}

body.page-hidden .rainbow-text,
body.page-hidden .rainbow-card::after,
body.page-hidden .rainbow-tag,
body.page-hidden .rainbow-tag::after,
body.page-hidden .password-digits::after,
body.page-hidden .music-unmute {
    animation-play-state: paused;
}

body.page-hidden[data-perf="high"] .version-card,
body.page-hidden[data-perf="high"] .modal-content {
    animation-play-state: paused;
}

body.modal-open .rainbow-text,
body.modal-open .rainbow-card::after,
body.modal-open .rainbow-tag,
body.modal-open .rainbow-tag::after,
body.modal-open .password-digits::after,
body.modal-open .music-unmute {
    animation-play-state: paused;
}
body.modal-open[data-perf="high"] .version-card,
body.modal-open[data-perf="high"] .modal-content {
    animation-play-state: paused;
}

.card-offscreen {
    animation-play-state: paused !important;
}

.card-offscreen .rainbow-text,
.card-offscreen .rainbow-card::after,
.card-offscreen .rainbow-tag::after {
    animation-play-state: paused !important;
}

.bg-layer.bg-fixed {
    position: fixed;
}

.version-card,
.modal-content,
.top-bar {
    contain: layout style;
}

.version-card,
.modal-content {
    will-change: transform;
}

.version-card.fade-in {
    animation-fill-mode: backwards;
}

.bg-layer {
    transform: translateZ(0);
    backface-visibility: hidden;
}

@supports (transform: translateX(0)) {
    .rainbow-card::after {
        will-change: background-position;
    }
}

.bg-image,
.card-icon img,
.cv-img {

    content-visibility: visible;
}

@media (prefers-reduced-motion: reduce) {
    .bg-layer,
    .rainbow-card::after {
        animation: none !important;
    }
}

body[data-perf="save"] .version-card {
    content-visibility: auto;
    contain-intrinsic-size: auto 200px;
}

body[data-perf="high"] .version-card {
    backdrop-filter: blur(30px) saturate(220%) !important;
    -webkit-backdrop-filter: blur(30px) saturate(220%) !important;
}
body[data-perf="high"] .modal-content {
    backdrop-filter: blur(36px) saturate(220%) !important;
    -webkit-backdrop-filter: blur(36px) saturate(220%) !important;
}

body[data-perf="high"] .version-card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.1), 0 6px 16px rgba(0, 0, 0, 0.05) !important;
}

@media (prefers-reduced-motion: reduce) {
    body[data-perf] .rainbow-card::after,
    body[data-perf] .rainbow-text {
        animation: none !important;
    }
}

.music-unmute {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.6rem;
    border: 1px solid rgba(0, 122, 255, 0.3);
    border-radius: 999px;
    background: rgba(0, 122, 255, 0.08);
    color: var(--ios-blue);
    font-size: 0.72rem;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;

    animation: unmutePulse 2s ease-in-out infinite;
    transition: background-color 0.2s, transform 0.15s;
}
.music-unmute:hover { background: rgba(0, 122, 255, 0.16); }
.music-unmute:active { transform: scale(0.95); }
.music-unmute[hidden] { display: none; }

@keyframes unmutePulse {
    0%, 100% { opacity: 0.75; }
    50%      { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
    .music-unmute { animation: none; }
}

.version-card,
.modal-content,
.top-bar,
.author-liquid,
.author-card {

    box-shadow:
        var(--glass-outer, 0 4px 24px rgba(0, 0, 0, 0.04)),

        inset 0 1px 0 rgba(255, 255, 255, 0.9),

        inset 0 3px 8px -3px rgba(255, 255, 255, 0.75),

        inset 1px 0 0 rgba(255, 255, 255, 0.4),
        inset -1px 0 0 rgba(255, 255, 255, 0.4),

        inset 0 -1px 3px -1px rgba(0, 0, 0, 0.07);
}

.version-card,
.modal-content,
.author-liquid {
    background-image:
        radial-gradient(130% 90% at 50% -10%, rgba(255, 255, 255, 0.6), transparent 62%),
        radial-gradient(110% 100% at 50% 110%, rgba(255, 255, 255, 0.3), transparent 58%);
    background-repeat: no-repeat;
}

body[data-perf="high"] .version-card,
body[data-perf="high"] .modal-content {
    background-image:
        radial-gradient(130% 90% at 50% -10%, rgba(255, 255, 255, 0.6), transparent 62%),
        radial-gradient(110% 100% at 50% 110%, rgba(255, 255, 255, 0.3), transparent 58%),

        linear-gradient(115deg,
            transparent 30%,
            rgba(120, 200, 255, 0.10) 42%,
            rgba(180, 160, 255, 0.13) 50%,
            rgba(120, 220, 240, 0.10) 58%,
            transparent 70%);
    background-size: 100% 100%, 100% 100%, 260% 260%;
    animation: liquidFlow 12s ease-in-out infinite;
}

@keyframes liquidFlow {
    0%, 100% { background-position: 0% 0%, 0% 0%, 0% 40%; }
    50%      { background-position: 0% 0%, 0% 0%, 100% 60%; }
}

.version-card.has-bg { background-image: none; }

@media (prefers-reduced-motion: reduce) {
    body[data-perf="high"] .version-card,
    body[data-perf="high"] .modal-content {
        animation: none;
    }
}

.version-card:active {
    transform: scale(0.975);
    box-shadow:
        0 1px 6px rgba(0, 0, 0, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.5),
        inset 0 2px 10px -2px rgba(0, 0, 0, 0.10),
        inset 0 -1px 2px -1px rgba(255, 255, 255, 0.3);
}

.top-bar {
    box-shadow:
        var(--glass-outer, 0 10px 34px rgba(0, 0, 0, 0.07)),
        inset 0 1.5px 0 rgba(255, 255, 255, 0.95),
        inset 0 4px 12px -4px rgba(255, 255, 255, 0.8),
        inset 1.5px 0 0 rgba(255, 255, 255, 0.45),
        inset -1.5px 0 0 rgba(255, 255, 255, 0.45),
        inset 0 -1.5px 4px -1px rgba(0, 0, 0, 0.09);
}

@keyframes modalAppearZoomV2 {
    0% {
        opacity: 0;
        transform: scale(0.68);
    }
    55% {
        opacity: 1;
        transform: scale(1.02);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes modalFocusIn {
    from {
        opacity: 0;
        filter: blur(8px);
        transform: translateY(14px) scale(0.97);
    }
    to {
        opacity: 1;
        filter: blur(0);
        transform: none;
    }
}

body[data-modal-anim="zoom"] .modal.active .modal-content {
    animation: modalAppearZoomV2 var(--dur-lg) var(--ease-out);
}
body[data-modal-anim="zoom"] .modal.active .modal-content > * {
    animation: modalFocusIn var(--dur-lg) var(--ease-out) 0.06s backwards;
}
body[data-modal-anim="zoom"] .modal.active.closing .modal-content {
    animation: modalContentOutZoom var(--dur-xs) var(--ease-in) forwards;
}

body[data-modal-anim="zoom"] .modal.active.closing .modal-content > * {
    animation: none;
}

.modal.flipping .modal-content {
    animation: none !important;
    will-change: transform, opacity;
}
.modal.flipping .modal-content > * {
    animation: none !important;
}

.card-morphing {
    opacity: 0 !important;
    transition: opacity 0.12s ease;
}

.ripple-host { position: relative; overflow: hidden; }
.ripple {
    position: absolute;
    border-radius: 50%;

    background: currentColor;
    opacity: 0.16;
    transform: scale(0);
    pointer-events: none;
    animation: rippleOut 0.5s cubic-bezier(0.22, 0.61, 0.36, 1) forwards;
    z-index: 0;
}
@keyframes rippleOut {
    to { transform: scale(1); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .ripple { display: none; }
}

body[data-layout="list"] .version-grid,
body[data-layout="list"] .bottom-cards {

    grid-template-columns: 1fr;
    gap: 0.5rem;
}

body[data-layout="list"] .version-card {
    min-height: 0;
    justify-content: flex-start;
}

body[data-layout="list"] .version-card {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas:
        "ic ti tg"
        "ic de tg";
    align-items: center;
    column-gap: 0.8rem;
    row-gap: 0.1rem;
    padding: 0.7rem 0.9rem;
    border-radius: 14px;
}

body[data-layout="list"] .card-header { display: contents; }

body[data-layout="list"] .card-icon {
    grid-area: ic;
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 11px;
    margin: 0;
}
body[data-layout="list"] .card-icon svg,
body[data-layout="list"] .card-icon img { width: 22px; height: 22px; }
body[data-layout="list"] .card-icon .emoji-icon { font-size: 1.25rem; }

body[data-layout="list"] .card-title {
    grid-area: ti;
    margin: 0;
    font-size: 0.98rem;

    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body[data-layout="list"] .card-desc {
    grid-area: de;
    margin: 0;
    font-size: 0.8rem;

    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

body[data-layout="list"] .card-tag {
    grid-area: tg;
    flex: 0 0 auto;
    font-size: 0.68rem;
    padding: 0.15rem 0.45rem;
    max-width: 6.5rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

body[data-layout="list"] .version-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.6rem;
}

body[data-layout="list"] .history-toggle,
body[data-layout="list"] .history-content {
    grid-column: 1 / -1;
}
body[data-layout="list"] .history-toggle { margin-top: 0.2rem; }

body[data-layout="list"] .version-card.has-bg .card-desc {
    color: rgba(255, 255, 255, 0.88);
}

body[data-layout="list"] .bottom-card {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0.8rem;
    padding: 0.7rem 0.9rem;
}

@media (max-width: 480px) {
    body[data-layout="list"] .version-card {
        padding: 0.6rem 0.75rem;
        column-gap: 0.65rem;
    }
    body[data-layout="list"] .card-icon {
        width: 38px; height: 38px; min-width: 38px;
    }
    body[data-layout="list"] .card-icon svg,
    body[data-layout="list"] .card-icon img { width: 20px; height: 20px; }
    body[data-layout="list"] .card-title { font-size: 0.92rem; }
    body[data-layout="list"] .card-desc { font-size: 0.76rem; }
}
