:root {
    --ink: #f4eef3;
    --ink-dim: #b7a8b4;
    --surface: #141018;
    --panel: rgba(36, 28, 38, 0.82);
    --panel-solid: #241c26;
    --line: rgba(255, 255, 255, 0.1);
    --rose: #ff4f8b;
    --rose-soft: #ff7aa8;
    --rose-deep: #e02f6c;
    --violet: #c084fc;
    --glow: rgba(255, 79, 139, 0.28);
    --radius: 16px;
    --radius-sm: 12px;
    --radius-icon: 20px;
    --shell: 700px;
    --mast-h: 68px;
    --dock-h: 86px;
    --gutter: 15px;
    --block-gap: 20px;
    --caption-gap: 0.5rem;
    --matrix-gap: 0.7rem;
    --caption-size: 0.78rem;
    --type: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --lift: 0 16px 40px rgba(255, 79, 139, 0.22);
    --soft: 0 10px 28px rgba(0, 0, 0, 0.35);
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

html, body {
    min-height: 100%;
}

body {
    font-family: var(--type);
    font-size: 0.9375rem;
    line-height: 1.45;
    color: var(--ink);
    background: var(--surface);
    overflow-x: hidden;
    padding-bottom: calc(var(--dock-h) + env(safe-area-inset-bottom, 0px));
    -webkit-tap-highlight-color: transparent;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.canvas-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(900px 420px at 50% -8%, rgba(255, 79, 139, 0.22), transparent 55%),
        radial-gradient(640px 320px at 100% 30%, rgba(192, 132, 252, 0.12), transparent 50%),
        radial-gradient(520px 280px at 0% 70%, rgba(255, 79, 139, 0.08), transparent 45%),
        linear-gradient(180deg, #1a1218 0%, #100d12 48%, #0c0a0e 100%);
}

/* Masthead */
.portal-mast {
    position: sticky;
    top: 0;
    z-index: 20;
    width: min(var(--shell), 100%);
    margin: 0 auto;
    border-radius: 0 0 1rem 1rem;
    background: linear-gradient(125deg, #ff6b9d 0%, var(--rose) 46%, #b91c5c 100%);
    box-shadow: 0 12px 30px rgba(255, 79, 139, 0.32);
    overflow: hidden;
}

.portal-mast::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0%, transparent 45%);
    pointer-events: none;
}

.mast-row {
    position: relative;
    z-index: 1;
    width: 100%;
    min-height: var(--mast-h);
    padding: 11px var(--gutter);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.brand-mark {
    flex: 0 0 auto;
    width: min(34vw, 132px);
    line-height: 0;
    transition: transform 0.28s var(--ease), filter 0.28s ease;
}

.brand-mark img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.25)) brightness(1.05);
}

.quick-links {
    flex: 0 0 auto;
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.quick-chip {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 0.32rem;
    color: #fff;
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    white-space: nowrap;
    line-height: 1;
    padding: 0.42rem 0.68rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.26);
    transition: background 0.25s ease, transform 0.25s var(--ease), box-shadow 0.25s ease;
}

.quick-chip-ico {
    display: block;
    width: 1.05rem;
    height: 1.05rem;
    flex: 0 0 auto;
    transition: transform 0.25s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
    .brand-mark:hover {
        transform: scale(1.04);
    }

    .quick-chip:hover,
    .quick-chip:focus-visible {
        background: rgba(255, 255, 255, 0.26);
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
        transform: translateY(-1px);
    }

    .quick-chip:hover .quick-chip-ico {
        transform: scale(1.08);
    }
}

/* Stage */
.stage-main {
    width: min(var(--shell), 100%);
    margin: 0 auto;
    padding: 16px var(--gutter) 12px;
    display: flex;
    flex-direction: column;
    gap: var(--block-gap);
}

/* Alert */
.alert-strip {
    width: 100%;
    margin: calc(var(--block-gap) * -0.4) 0;
}

.alert-track {
    width: 100%;
    height: 30px;
    line-height: 30px;
    background: linear-gradient(90deg, rgba(255, 79, 139, 0.16) 0%, rgba(36, 28, 38, 0.95) 45%, rgba(192, 132, 252, 0.14) 100%);
    color: var(--ink);
    border-radius: 999px;
    overflow: hidden;
    white-space: nowrap;
    border: 1px solid rgba(255, 79, 139, 0.28);
    box-shadow: 0 4px 16px rgba(255, 79, 139, 0.12);
}

.alert-track p {
    display: inline-block;
    margin: 0;
    padding-left: 0.75rem;
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
    animation: alert-scroll 18s linear infinite;
}

@keyframes alert-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

/* Icon matrix */
.icon-rack {
    margin: 0;
}

.icon-matrix {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    column-gap: var(--matrix-gap);
    row-gap: 0;
    width: 100%;
    align-items: start;
}

.icon-cell {
    display: flex;
    min-width: 0;
    container-type: inline-size;
}

.icon-cell a {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    text-align: center;
}

.icon-thumb {
    width: 100%;
    aspect-ratio: 1;
    border-radius: var(--radius-icon);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--line);
    box-shadow: var(--soft);
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.3s ease;
}

.icon-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s var(--ease);
}

.icon-caption {
    width: 100%;
    margin: var(--caption-gap) 0;
    min-height: 1.3em;
    font-size: var(--caption-size);
    font-weight: 700;
    line-height: 1.3;
    color: var(--ink);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.25s ease, transform 0.3s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
    .icon-cell a:hover .icon-thumb,
    .icon-cell a:focus-visible .icon-thumb {
        transform: translateY(-5px) scale(1.04);
        box-shadow: var(--lift);
        border-color: rgba(255, 79, 139, 0.45);
    }

    .icon-cell a:hover .icon-thumb img,
    .icon-cell a:focus-visible .icon-thumb img {
        transform: scale(1.06);
    }

    .icon-cell a:hover .icon-caption,
    .icon-cell a:focus-visible .icon-caption {
        color: var(--rose-soft);
        transform: translateY(-1px);
    }
}

@supports (font-size: 1cqi) {
    .icon-caption {
        font-size: min(var(--caption-size), calc(100cqi / 6));
    }
}

/* Promo slider */
.promo-stage {
    width: 100%;
}

.promo-slider {
    position: relative;
    width: 100%;
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--panel-solid);
    border: 1px solid var(--line);
    box-shadow: var(--soft);
    transition: box-shadow 0.35s var(--ease), transform 0.35s var(--ease);
}

.promo-slider.swiper-autoheight .swiper-wrapper {
    align-items: flex-start;
}

.promo-slider .swiper-slide {
    height: auto;
    width: 100%;
}

.promo-slider .swiper-slide a {
    display: block;
    width: 100%;
    line-height: 0;
    overflow: hidden;
}

.promo-slider img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
    transition: transform 0.55s var(--ease);
}

.promo-slider .swiper-pagination {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0.6rem;
    z-index: 2;
    display: flex;
    justify-content: center;
    gap: 0.35rem;
}

.promo-slider .swiper-pagination-bullet {
    width: 0.4rem;
    height: 0.4rem;
    margin: 0 !important;
    background: rgba(255, 255, 255, 0.4);
    opacity: 1;
    border-radius: 999px;
    transition: width 0.25s ease, background 0.25s ease;
}

.promo-slider .swiper-pagination-bullet-active {
    width: 1.05rem;
    background: var(--rose-soft);
    box-shadow: 0 0 10px var(--glow);
}

@media (hover: hover) and (pointer: fine) {
    .promo-slider:hover {
        box-shadow: var(--lift);
        transform: translateY(-2px);
    }

    .promo-slider .swiper-slide a:hover img {
        transform: scale(1.03);
    }
}

/* Play list */
.play-board {
    margin: 0;
    padding-bottom: 8px;
}

.board-heading {
    margin: 0 0 14px;
    padding-left: 0.75rem;
    font-size: clamp(17px, 4vw, 21px);
    font-weight: 800;
    letter-spacing: 0.03em;
    color: #fff;
    position: relative;
}

.board-heading::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.18em;
    bottom: 0.18em;
    width: 0.2rem;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--rose-soft), var(--rose) 45%, var(--violet));
    box-shadow: 0 0 14px var(--glow);
}

.play-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.play-row {
    display: grid;
    grid-template-columns: 80px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 11px;
    border-radius: var(--radius);
    background: var(--panel);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--line);
    box-shadow: var(--soft);
    color: var(--ink);
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.3s ease, background 0.3s ease;
}

.play-cover {
    width: 80px;
    height: 80px;
    border-radius: 18px;
    overflow: hidden;
    background: #2a2230;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.play-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s var(--ease);
}

.play-meta {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.play-name {
    font-size: 16px;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.25s ease;
}

.play-score {
    font-size: 12px;
    color: var(--rose-soft);
    letter-spacing: 0.04em;
}

.play-score em {
    margin-left: 6px;
    font-style: normal;
    font-size: 12px;
    letter-spacing: 0;
    color: var(--ink-dim);
}

.play-blurb {
    font-size: 12px;
    color: var(--ink-dim);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.play-action {
    width: 82px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.get-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    min-width: 4.6rem;
    height: 2.1rem;
    padding: 0 0.65rem;
    border-radius: 999px;
    background: linear-gradient(180deg, #ff7aa8 0%, var(--rose) 55%, var(--rose-deep) 100%);
    box-shadow: 0 2px 0 rgba(160, 30, 80, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.28);
    color: #fff;
    font-size: 0.84rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    line-height: 1;
    white-space: nowrap;
    transition: transform 0.3s var(--ease), box-shadow 0.3s ease, filter 0.25s ease;
}

.get-btn-ico {
    width: 1rem;
    height: 1rem;
    flex: 0 0 auto;
    display: block;
    transition: transform 0.3s var(--ease);
}

@media (hover: hover) and (pointer: fine) {
    .play-row:hover,
    .play-row:focus-visible {
        transform: translateY(-3px);
        background: rgba(48, 36, 52, 0.92);
        border-color: rgba(255, 79, 139, 0.4);
        box-shadow: var(--lift);
    }

    .play-row:hover .play-cover,
    .play-row:focus-visible .play-cover {
        transform: scale(1.03);
        box-shadow: 0 8px 22px rgba(255, 79, 139, 0.28);
    }

    .play-row:hover .play-cover img,
    .play-row:focus-visible .play-cover img {
        transform: scale(1.08);
    }

    .play-row:hover .play-name,
    .play-row:focus-visible .play-name {
        color: var(--rose-soft);
    }

    .play-row:hover .get-btn,
    .play-row:focus-visible .get-btn {
        transform: translateY(-1px) scale(1.04);
        filter: brightness(1.08);
        box-shadow: 0 8px 18px rgba(255, 79, 139, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.28);
    }

    .play-row:hover .get-btn-ico,
    .play-row:focus-visible .get-btn-ico {
        transform: translateY(1px);
    }
}

/* Dock */
.dock-bar {
    position: fixed;
    left: 50%;
    bottom: 0;
    z-index: 30;
    transform: translateX(-50%);
    width: min(var(--shell), 100%);
    padding: 13px var(--gutter) calc(13px + env(safe-area-inset-bottom, 0px));
    display: flex;
    align-items: center;
    gap: 0;
    border-radius: 1.05rem 1.05rem 0 0;
    background: linear-gradient(120deg, #ff6b9d 0%, #ff3d7a 48%, #a21caf 100%);
    box-shadow: 0 -12px 34px rgba(255, 60, 130, 0.35);
}

.dock-logo {
    width: 3.6rem;
    height: 3.6rem;
    flex-shrink: 0;
    transition: transform 0.3s var(--ease);
}

.dock-logo img {
    width: 100%;
    height: 100%;
    border-radius: 15px;
    object-fit: cover;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    border: 2px solid rgba(255, 255, 255, 0.35);
}

.dock-copy {
    flex: 1;
    min-width: 0;
    padding: 0 12px;
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.dock-copy strong {
    font-size: 15px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dock-copy span {
    font-size: 12px;
    opacity: 0.95;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dock-cta {
    flex-shrink: 0;
    padding: 10px 16px;
    border-radius: 999px;
    background: #fff;
    color: #be123c;
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.16);
    transition: transform 0.3s var(--ease), box-shadow 0.3s ease, color 0.25s ease;
}

@media (hover: hover) and (pointer: fine) {
    .dock-bar:hover .dock-logo {
        transform: scale(1.05);
    }

    .dock-cta:hover,
    .dock-cta:focus-visible {
        transform: translateY(-2px) scale(1.04);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.22);
        color: var(--rose-deep);
    }
}

/* Entrance */
@keyframes fade-rise {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stage-main > * {
    animation: fade-rise 0.55s var(--ease) both;
}

.stage-main > *:nth-child(1) { animation-delay: 0.02s; }
.stage-main > *:nth-child(2) { animation-delay: 0.08s; }
.stage-main > *:nth-child(3) { animation-delay: 0.14s; }
.stage-main > *:nth-child(4) { animation-delay: 0.2s; }

@media (prefers-reduced-motion: reduce) {
    .stage-main > *,
    .icon-thumb,
    .icon-thumb img,
    .icon-caption,
    .play-row,
    .play-cover,
    .play-cover img,
    .get-btn,
    .promo-slider,
    .promo-slider img,
    .brand-mark,
    .quick-chip,
    .dock-logo,
    .dock-cta {
        animation: none !important;
        transition: none !important;
    }

    .alert-track p {
        animation: none;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        vertical-align: top;
    }
}

@media screen and (max-width: 768px) {
    :root {
        --mast-h: 60px;
        --dock-h: 80px;
        --gutter: 0.8rem;
        --block-gap: 1.05rem;
        --radius: 14px;
        --radius-icon: 17px;
        --caption-gap: 0.45rem;
        --matrix-gap: 0.55rem;
        --caption-size: 0.78rem;
    }

    .portal-mast {
        border-radius: 0 0 0.85rem 0.85rem;
    }

    .mast-row {
        min-height: var(--mast-h);
        padding: 0.55rem var(--gutter);
    }

    .brand-mark {
        width: min(30vw, 112px);
    }

    .stage-main {
        padding: 0.8rem var(--gutter) 0.8rem;
    }

    .alert-track {
        height: 26px;
        line-height: 26px;
    }

    .alert-track p {
        font-size: 0.72rem;
        animation-duration: 16s;
    }

    .board-heading {
        margin-bottom: 0.8rem;
        font-size: 1.05rem;
    }

    .play-stack {
        gap: 0.7rem;
    }

    .play-row {
        grid-template-columns: 4.25rem minmax(0, 1fr) 4.25rem;
        gap: 0.7rem;
        padding: 0.6rem;
    }

    .play-cover {
        width: 4.25rem;
        height: 4.25rem;
        border-radius: 1rem;
    }

    .play-name {
        font-size: 0.95rem;
    }

    .play-score {
        font-size: 0.72rem;
    }

    .play-blurb {
        font-size: 0.72rem;
        -webkit-line-clamp: 1;
    }

    .play-action {
        width: 4.25rem;
    }

    .get-btn {
        min-width: 4rem;
        height: 1.9rem;
        font-size: 0.78rem;
    }

    .dock-bar {
        width: 100%;
        max-width: none;
        left: 0;
        transform: none;
        border-radius: 0.95rem 0.95rem 0 0;
        padding: 0.7rem var(--gutter) calc(0.7rem + env(safe-area-inset-bottom, 0px));
    }

    .dock-logo {
        width: 3.1rem;
        height: 3.1rem;
    }

    .dock-copy {
        padding: 0 0.7rem;
    }

    .dock-copy strong {
        font-size: 0.9rem;
    }

    .dock-copy span {
        font-size: 0.68rem;
    }

    .dock-cta {
        padding: 0.58rem 0.8rem;
        font-size: 0.78rem;
        white-space: nowrap;
    }
}

@media screen and (max-width: 480px) {
    :root {
        --gutter: 0.7rem;
        --block-gap: 0.95rem;
        --mast-h: 56px;
        --dock-h: 76px;
        --radius-icon: 15px;
        --matrix-gap: 0.45rem;
    }

    .brand-mark {
        width: min(28vw, 100px);
    }

    .quick-chip span {
        display: none;
    }

    .quick-chip {
        padding: 0.45rem;
        border-radius: 999px;
    }

    .play-row {
        grid-template-columns: 3.85rem minmax(0, 1fr) 3.85rem;
        gap: 0.55rem;
        padding: 0.55rem;
    }

    .play-cover {
        width: 3.85rem;
        height: 3.85rem;
    }

    .play-name {
        font-size: 0.9rem;
    }

    .play-action {
        width: 3.85rem;
    }

    .get-btn {
        min-width: 3.6rem;
        height: 1.8rem;
        font-size: 0.72rem;
    }
}

@media screen and (max-width: 360px) {
    :root {
        --gutter: 0.6rem;
        --matrix-gap: 0.35rem;
    }

    .play-blurb {
        display: none;
    }

    .dock-copy span {
        display: none;
    }
}

@media screen and (min-width: 768px) {
    :root {
        --gutter: 1.15rem;
        --block-gap: 1.4rem;
        --caption-gap: 0.6rem;
        --matrix-gap: 0.9rem;
        --caption-size: 0.95rem;
    }

    .play-row {
        padding: 0.8rem 0.95rem;
    }

    .play-name {
        font-size: 1.05rem;
    }
}

@media screen and (min-width: 960px) {
    :root {
        --shell: 740px;
        --caption-size: 0.95rem;
    }

    .stage-main {
        padding-top: 1.25rem;
    }

    .icon-thumb {
        border-radius: 22px;
    }
}
