@font-face {
    font-family: 'VHSIcons';
    src: url('vcrosdmonorus_vhsicons.ttf') format('truetype');
}

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

body {
    --page-padding-block: 16px;
    --page-padding-inline: 16px;
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    justify-items: center;
    grid-template-rows: auto auto;
    align-content: start;
    gap: var(--eye-gap);
    font-family: 'VHSIcons', Arial, sans-serif;
}

.page-shell {
    display: grid;
    justify-items: center;
    gap: 14px;
    width: 100%;
}

.release-card {
    --content-inset: 20px;
    position: relative;
    isolation: isolate;
    display: grid;
    grid-template-areas: 'platforms' 'title';
    grid-template-rows: 1fr auto;
    gap: 16px;
    width: min(100%, 360px);
    aspect-ratio: 4 / 5;
    padding: var(--content-inset) var(--content-inset) 24px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.78);
    border-radius: 20px;
    background: #22130c;
    box-shadow:
        0 18px 34px rgba(0, 0, 0, 0.22),
        0 0 0 6px rgba(255, 255, 255, 0.46);
}

.release-art {
    position: absolute;
    inset: 0;
    z-index: -2;
    background: url('tpk-bg.png') center 32% / cover no-repeat;
}

.release-card::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(180deg, transparent 35%, rgba(12, 8, 6, 0.66));
    pointer-events: none;
}

.release-card--spovid .release-art {
    inset: 0 -5%;
    background-image: url('spovid-bg.png?v=20261203');
    background-position: right top;
    transform-origin: 75% 100%;
    animation: flower-sway 5.6s ease-in-out infinite;
}

@keyframes flower-sway {
    0%, 100% { transform: skewX(-1.6deg); }
    50% { transform: skewX(1.6deg); }
}

.song-title {
    grid-area: title;
    margin: 0;
    color: #fff6d8;
    font-size: 36px;
    font-weight: normal;
    line-height: 0.98;
    text-align: center;
    text-shadow: 0 3px 0 #2c1508, 0 8px 16px rgba(0, 0, 0, 0.62);
    animation: title-drift 5.8s ease-in-out infinite;
}

.platform-list {
    grid-area: platforms;
    align-self: start;
    justify-self: start;
    display: grid;
    list-style: none;
    gap: 4px;
    max-width: 100%;
    animation: platform-drift 6.7s ease-in-out infinite;
}

.platform-item {
    --icon-size: 44px;
    display: grid;
    grid-template-columns: var(--icon-size) minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    color: #fff;
    font-size: 19px;
    line-height: 1.05;
    text-decoration: none;
    text-shadow: 2px 2px 0 #321102, 4px 4px 10px rgba(0, 0, 0, 0.58);
}

a.platform-item:hover .platform-name {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.platform-icon {
    width: var(--icon-size);
    height: var(--icon-size);
    object-fit: contain;
    filter: grayscale(var(--platform-grayscale, 0)) drop-shadow(3px 3px 0 rgba(0, 0, 0, 0.28));
    image-rendering: pixelated;
}

.platform-item:not([href]) {
    --platform-grayscale: 1;
}

.home-button {
    color: #111;
    font-size: 17px;
    text-underline-offset: 4px;
}

.home-button:hover {
    color: #a64e15;
}

.marketing-settings,
.marketing-actions button {
    font: inherit;
    cursor: pointer;
    color: #191919;
}

.marketing-settings {
    border: 0;
    background: transparent;
    min-height: 44px;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.marketing-consent {
    position: fixed;
    z-index: 2;
    bottom: calc(12px + env(safe-area-inset-bottom, 0px));
    left: 50%;
    transform: translateX(-50%);
    width: min(440px, calc(100% - 32px));
    max-height: calc(100dvh - 24px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
    overflow: auto;
    padding: 14px;
    border: 1px solid #b9b9b9;
    border-radius: 8px;
    background: #fff;
    color: #191919;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18);
    font: 15px/1.35 Arial, sans-serif;
}

.marketing-consent h2 {
    font-size: 17px;
}

.marketing-consent p {
    margin: 6px 0 12px;
}

.marketing-consent a {
    color: inherit;
    text-underline-offset: 2px;
}

.marketing-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.marketing-actions button {
    min-height: 44px;
    border: 1px solid #555;
    border-radius: 4px;
    background: #f5f5f5;
}

.marketing-actions button:hover {
    background: #e8e8e8;
}

:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 3px;
}

@keyframes title-drift {
    50% { transform: translate(2px, -4px); }
}

@keyframes platform-drift {
    50% { transform: translate(3px, 3px); }
}

@media (min-width: 481px) and (max-height: 700px) {
    .release-card {
        width: min(100%, clamp(280px, 80dvh - 192px, 360px));
    }
}

@media (max-width: 480px) {
    body {
        --page-padding-block: 12px;
    }

    .page-shell {
        gap: 18px;
    }

    .release-card {
        --content-inset: 28px;
        width: min(100%, 350px);
        padding-bottom: 36px;
        border-radius: 16px;
    }

    .song-title {
        font-size: 32px;
    }

    .platform-item {
        --icon-size: 52px;
        gap: 18px;
        font-size: 18px;
    }
}

@media (max-width: 360px) {
    .release-card {
        --content-inset: 22px;
        padding-bottom: 26px;
    }

    .platform-item {
        --icon-size: 44px;
        gap: 14px;
        font-size: 17px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .release-card--spovid .release-art,
    .song-title,
    .platform-list {
        animation: none;
    }
}
