:root {
    --cp-bg: #070706;
    --cp-card: #14130f;
    --cp-line: rgba(255, 226, 72, 0.18);
    --cp-yellow: #ffe348;
    --cp-yellow-soft: #ffec86;
    --cp-text: #f6f4e9;
    --cp-sub: #aaa793;
}

body.candy-pop-page {
    color: var(--cp-text);
    background:
        radial-gradient(circle at 80% 10%, rgba(255, 211, 48, 0.10), transparent 30%),
        linear-gradient(180deg, #070706 0%, #0b0a07 48%, #060605 100%);
}

.candy-pop-page nav a:hover,
.candy-pop-page nav a:focus-visible {
    color: var(--cp-yellow);
}

.candy-pop-main {
    overflow: hidden;
}

/* Hero */

.cp-hero {
    position: relative;
    min-height: 100vh;
    display: grid;
    place-items: center;
    overflow: hidden;
    isolation: isolate;
    padding: 120px 28px 70px;
}

.cp-hero-background {
    position: absolute;
    inset: 0;
    z-index: -3;
}

.cp-hero-background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 36%;
    filter: brightness(0.46) saturate(0.92) contrast(1.05);
    transform: scale(1.02);
}

.cp-hero-overlay {
    position: absolute;
    inset: 0;
    z-index: -2;
    background:
        linear-gradient(
            90deg,
            rgba(5, 5, 3, 0.90) 0%,
            rgba(5, 5, 3, 0.64) 42%,
            rgba(5, 5, 3, 0.28) 72%,
            rgba(5, 5, 3, 0.50) 100%
        ),
        linear-gradient(
            180deg,
            rgba(5, 5, 3, 0.16) 0%,
            rgba(5, 5, 3, 0.15) 58%,
            rgba(5, 5, 3, 0.90) 100%
        );
}

.cp-hero-inner {
    width: min(1180px, 100%);
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(300px, 1.15fr);
    align-items: center;
    gap: 64px;
}

.cp-hero-copy {
    max-width: 610px;
}

.cp-eyebrow {
    margin: 0 0 18px;
    color: var(--cp-yellow);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 4px;
    text-transform: uppercase;
}

.cp-hero h1 {
    margin: 0;
    font-size: clamp(64px, 10vw, 138px);
    line-height: 0.88;
    letter-spacing: -5px;
}

.cp-hero-copy h2 {
    margin: 25px 0 20px;
    color: var(--cp-yellow-soft);
    font-size: clamp(18px, 2.5vw, 31px);
    font-weight: 500;
    letter-spacing: 1.5px;
}

.cp-hero-copy > p:not(.cp-eyebrow) {
    max-width: 600px;
    margin: 0 0 32px;
    color: #d0ccba;
    font-size: 14px;
    line-height: 2;
    letter-spacing: 0.5px;
}

.cp-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.cp-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 176px;
    min-height: 48px;
    padding: 0 24px;
    border: 1px solid var(--cp-yellow);
    color: #101007;
    background: var(--cp-yellow);
    text-decoration: none;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    cursor: pointer;
    transition:
        transform 0.25s ease,
        background 0.25s ease,
        color 0.25s ease,
        border-color 0.25s ease;
}

.cp-button:hover,
.cp-button:focus-visible {
    transform: translateY(-3px);
    background: #fff2a8;
}

.cp-button-secondary {
    color: var(--cp-yellow-soft);
    background: rgba(0, 0, 0, 0.22);
    border-color: rgba(255, 226, 72, 0.46);
}

.cp-audio-status {
    min-width: 164px;
}

.cp-audio-status[aria-pressed="true"]::before {
    content: "■";
    margin-right: 10px;
    font-size: 8px;
}

.cp-audio-status[aria-pressed="false"]::before {
    content: "▶";
    margin-right: 10px;
    font-size: 9px;
}

/* Content sections */

.cp-section {
    width: min(1180px, calc(100% - 48px));
    margin: 0 auto;
    padding: 110px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.cp-section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 48px;
}

.cp-section-heading p {
    margin: 0;
    color: var(--cp-yellow);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.cp-section-heading h2 {
    margin: 8px 0 0;
    font-size: clamp(34px, 5vw, 65px);
    letter-spacing: -2px;
}

.cp-section-summary {
    max-width: 440px;
    color: var(--cp-sub);
    font-size: 12px;
    line-height: 2;
}

/* 1st single */

.cp-single {
    position: relative;
    display: grid;
    grid-template-columns: minmax(320px, 0.9fr) minmax(0, 1.1fr);
    align-items: center;
    gap: 62px;
    overflow: hidden;
    padding: 46px;
    border: 1px solid var(--cp-line);
    background: #0b0a08;
}

.cp-single::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(8, 8, 5, 0.92), rgba(8, 8, 5, 0.58)),
        url("../images/CandyPop_Hands.png") center / cover no-repeat;
    opacity: 0.54;
}

.cp-single > * {
    position: relative;
    z-index: 1;
}

.cp-single-cover img {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid var(--cp-line);
}

.cp-single-info .number {
    color: var(--cp-yellow);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 3px;
}

.cp-single-info h3 {
    margin: 14px 0 8px;
    font-size: clamp(38px, 6vw, 76px);
    line-height: 1;
}

.cp-jp-title {
    color: var(--cp-yellow-soft);
    font-size: 18px;
    letter-spacing: 2px;
}

.cp-release-date {
    margin: 28px 0 0;
    padding: 20px 0;
    border-top: 1px solid var(--cp-line);
    border-bottom: 1px solid var(--cp-line);
    color: #ded9c3;
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Members */

.cp-members {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.cp-member {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: var(--cp-card);
    transition:
        transform 0.3s ease,
        border-color 0.3s ease;
}

.cp-member:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 226, 72, 0.5);
}

.cp-member img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    object-position: center top;
}

.cp-member-info {
    padding: 23px 22px 27px;
}

.cp-member-role {
    color: var(--cp-yellow);
    font-size: 9px;
    font-weight: 800;
    line-height: 1.7;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.cp-member-info h3 {
    margin: 11px 0 13px;
    font-size: 22px;
    line-height: 1.25;
}

.cp-member-meta {
    display: grid;
    gap: 7px;
    margin: 0;
}

.cp-member-meta div {
    display: grid;
    grid-template-columns: 74px 1fr;
    gap: 10px;
}

.cp-member-meta dt {
    color: #686658;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.cp-member-meta dd {
    margin: 0;
    color: #c5c1ae;
    font-size: 11px;
    line-height: 1.6;
}

/* Story */

.cp-story-box {
    position: relative;
    max-width: 900px;
    padding: 50px;
    border-left: 2px solid var(--cp-yellow);
    background: rgba(255, 255, 255, 0.025);
}

.cp-story-box p {
    margin: 0 0 22px;
    color: #b7b3a2;
    font-size: 15px;
    line-height: 2.2;
}

.cp-story-box p:last-child {
    margin-bottom: 0;
}

.cp-story-core {
    color: var(--cp-text) !important;
    font-size: clamp(22px, 3vw, 34px) !important;
    font-weight: 600;
    line-height: 1.5 !important;
}

/* Return to Formula Ace */

.cp-formula-return {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 30px;
    padding: 40px;
    border: 1px solid var(--cp-line);
    background:
        linear-gradient(
            135deg,
            rgba(255, 226, 72, 0.08),
            rgba(255, 255, 255, 0.02)
        );
}

.cp-formula-return h2 {
    margin: 0 0 10px;
    font-size: 32px;
}

.cp-formula-return p {
    margin: 0;
    color: var(--cp-sub);
    font-size: 12px;
    line-height: 1.8;
}

@media (max-width: 860px) {
    .cp-hero-inner,
    .cp-single {
        grid-template-columns: 1fr;
    }

    .cp-hero-copy {
        text-align: center;
        margin: 0 auto;
    }

    .cp-hero-actions {
        justify-content: center;
    }

    .cp-hero-overlay {
        background:
            linear-gradient(
                180deg,
                rgba(5, 5, 3, 0.44) 0%,
                rgba(5, 5, 3, 0.58) 58%,
                rgba(5, 5, 3, 0.94) 100%
            );
    }

    .cp-members {
        grid-template-columns: 1fr;
    }

    .cp-member {
        display: grid;
        grid-template-columns: minmax(180px, 0.75fr) minmax(0, 1.25fr);
    }

    .cp-member img {
        height: 100%;
        aspect-ratio: auto;
    }
}

@media (max-width: 560px) {
    .cp-hero {
        padding: 110px 18px 58px;
    }

    .cp-hero h1 {
        font-size: 62px;
        letter-spacing: -3px;
    }

    .cp-section {
        width: min(100% - 32px, 1180px);
        padding: 84px 0;
    }

    .cp-section-heading {
        display: block;
    }

    .cp-section-summary {
        margin-top: 20px;
    }

    .cp-single {
        padding: 24px;
    }

    .cp-member {
        display: block;
    }

    .cp-member img {
        aspect-ratio: 4 / 5;
    }

    .cp-story-box {
        padding: 30px 24px;
    }

    .cp-formula-return {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .cp-member,
    .cp-button {
        transition: none;
    }
}
