
:root {
    --bg-outer: #000000;
    --bg-stage: #0d0d0f;
    --btn-bg: rgba(0, 0, 0, 0.65);
    --btn-hover: rgba(255, 255, 255, 0.25);
    --ease-focus: cubic-bezier(0.25, 1, 0.3, 1);
    --card-width: 62.5vw;

    --badge-gold-bg: #caa97f;
    --item-card-bg: #ffffff;
    --item-card-border: #caa97f;
    --text-dark: #2d241e;
    --text-body: #554a41;
    --img-placeholder: #e0e0e0;

    --card-dark-bg: #141a21;
    --card-label-bg: #9e7a57;
    --card-label-hover: #b58d68;
    --pill-bg: #111111;
    --text-white: #ffffff;
    --font-main: "Noto Sans TC", "Microsoft JhengHei", sans-serif;
}

#section-1 {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 0 0 3cqw;
    width: 100%;
    height: auto;
    align-items: center;
    overflow: hidden;
}

#section-2,
#section-3,
#section-4,
#section-5 {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: auto;
}

#section-2 {
    padding-bottom: 2cqw;
}
#section-3 {
    padding: 2cqw 0;
}
#section-4 {
    padding-top: 3cqw;
}
#section-5 {
    padding-top: 2cqw;
    padding-bottom: 9cqw;
}


.gogo {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    width: 90vw;
    max-width: 600px;
    background-color: #1c1714cf;
    color: #fff;
    z-index: 97;
    font-size: 1rem;
    letter-spacing: 1px;
    padding: 10px 24px;
    margin-top: 10px;
    border-radius: 999px;
    animation: gogoFadeOut 0.6s ease 20s forwards;
}

.gogo-track {
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}

.gogo-text {
    display: inline-block;
    white-space: nowrap;
    padding-left: 100%;
    animation: marqueeRun 10s linear 2 forwards;
    will-change: transform;
    transform: translateZ(0);
}

.gogo-name {
    color: #e9c8a8;
    font-weight: 700;
}

.carousel-stage {
    position: relative;
    width: 100vw;
    height: calc(var(--card-width) * 1 / 2);
    overflow: hidden;
    background-color: var(--bg-stage);
    display: flex;
    justify-content: center;
    align-items: center;
    touch-action: pan-y;
    user-select: none;
    cursor: grab;
    margin-top: 1cqw;
}

.carousel-stage:active {
    cursor: grabbing;
}

.carousel-track {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-card {
    position: absolute;
    top: 0;
    left: 50%;
    width: var(--card-width);
    height: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    transition: transform 0.5s var(--ease-focus), filter 0.5s var(--ease-focus), opacity 0.5s var(--ease-focus);
    will-change: transform, filter;
    transform: translateX(-50%);
}

.carousel-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.carousel-card.is-active {
    transform: translateX(-50%);
    filter: brightness(1) blur(0px);
    opacity: 1;
    z-index: 10;
}

.carousel-card.is-prev {
    transform: translateX(-110%);
    filter: brightness(0.2) blur(8px);
    opacity: 0.85;
    z-index: 5;
}

.carousel-card.is-next {
    transform: translateX(10%);
    filter: brightness(0.2) blur(8px);
    opacity: 0.85;
    z-index: 5;
}

.carousel-card.is-hidden {
    transform: translateX(-50%);
    filter: brightness(0) blur(12px);
    opacity: 0;
    z-index: 1;
    pointer-events: none;
}

.nav-btn {
position: absolute;
    top: 45%;
    width: 5.75cqw;
    height: auto;
    background: #c6aa81b0;
    padding: 0.625cqw 2cqw;
    border: none;
    cursor: pointer;
    z-index: 20;
    transition: transform 0.2s ease-in-out;
    border-radius: 0.625cqw;
}

.nav-btn.prev {
    transform: rotate(-90deg);
    left: 20vw;
}
.nav-btn.prev:hover {
    transform: rotate(-90deg) scale(0.95);
}
.nav-btn.next {
    transform: rotate(90deg);
    right: 20vw;
}
.nav-btn.next:hover {
    transform: rotate(90deg) scale(0.95);
}

.gk-h1 {
    margin-top: 0.7cqw;
    color: #caa97f;
    font-size: 2.4rem;
    letter-spacing: 1px;
    flex-shrink: 0;
    font-weight: 900;
}

.gk-h2 {
    color: #fff;
    font-size: 1.5rem;
    letter-spacing: 2px;
    flex-shrink: 0;
    font-weight: 600;
}

.activity-rules {
    display: flex;
    flex-direction: column;
    gap: 0.5cqw;
}
.rule-row {
    display: flex;
    align-items: flex-start;
    gap: 0.5cqw;
    font-size: 1.02rem;
    line-height: 1.7;
}
.rule-label {
    color: var(--label-gold);
    font-weight: 500;
    letter-spacing: 1.5px;
    white-space: nowrap;
    flex-shrink: 0;
}
.rule-divider {
    color: var(--divider-color);
    font-weight: 300;
    user-select: none;
    flex-shrink: 0;
    opacity: 0.8;
}

.rule-subtext {
    display: block;
    margin-top: 4px;
    opacity: 0.9;
}

.is-warning-link {
        color: #e9c8a8;
    font-weight: bold;
    transition: 0.2s ease;
}


.is-warning-link:hover {
    text-decoration: none;
        color: #fadfc5;
}


.rule-content {
    color: #fff;
    flex: 1;
    letter-spacing: 0.3px;
}
.rule-steps {
    list-style: auto;
    display: flex;
    flex-direction: column;
    gap: 0.5cqw;
    padding-left: 1cqw;
}
.rule-steps li {
    text-align: justify;
    word-break: break-word;
}

.npc02 {
    position: absolute;
    width: 15.801cqw;
    height: auto;
    top: 4cqw;
    right: 11cqw;
    z-index: 3;
    pointer-events: none;
}

.featured-rewards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5cqw;
    width: 82%;
    margin: 0 auto 1.5cqw;
}

.white-card {
    background-color: var(--item-card-bg);
    border: 2px solid var(--item-card-border);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.featured-card-single .card-banner {
    background-color: var(--badge-gold-bg);
    color: #ffffff;
    font-weight: 400;
    text-align: center;
    padding: 0.2cqw 0;
    font-size: 1.2rem;
    letter-spacing: 2px;
}

.featured-card-single .card-content {
    padding: 1cqw 1.5cqw;
    display: grid;
    grid-template-columns: 7.8745cqw 1fr;
    gap: 0cqw;
    align-items: center;
    flex: 1;
    container-type: inline-size;
    align-content: start;
}

.single-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
    color: var(--text-dark);
    min-width: 0;
}
.single-info .item-title {
    font-size: 1.15rem;
    font-weight: 800;
}
.single-info .item-desc {
    font-size: 0.82rem;
    color: var(--text-body);
    line-height: 1.45;
}
.single-info .item-weight {
    font-size: 0.82rem;
    color: var(--text-dark);
}

.featured-card-combo .card-content {
    padding: 1cqw;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.7cqw;
    height: 100%;
}

.combo-images {
    display: flex;
    align-items: center;
    gap: 16px;
}
.combo-plus {
    font-size: 1.5rem;
    font-weight: 800;
    color: #8c7a6b;
}
.combo-info {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 2px;
}


.combo-info .combo-sub {
    font-size: 0.82rem;
    font-weight: 400;
    color: var(--text-dark);
}

.combo-info .combo-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
}



.combo-info-sp {
    font-size: 0.8rem;
    color: #c06e48;
    margin-top: .5cqw;
}



.rewards-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1cqw;
    width: 98%;
    list-style: none;
    margin: 0 auto;
}

.reward-item {
    padding: 1.5cqw 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    text-align: center;
}

.img-box-sps {
    width: 100%;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
}
.img-box-sps img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.img-box-sm {
    width: 7.8745cqw;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}
.reward-item .img-box-sm {
    width: 4.515cqw;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.75cqw;
}
.reward-item .img-box-sm img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}
.reward-item .item-name {
    font-size: 0.82rem;
    font-weight: 400;
    color: var(--text-dark);
    line-height: 1.4;
    word-break: break-word;
}

#box-ro-login {
    position: relative;
    display: flex;
    gap: 1cqw;
    font-size: 0.8vw;
    font-weight: 400;
    letter-spacing: 0.1vw;
    line-height: 1.75;
    color: #fff;
    width: auto;
    height: auto;
    z-index: 1;
    flex-direction: column;
    align-items: center;
}

#box-ro-logout {
    display: none;
    position: relative;
    font-size: 0.8vw;
    font-weight: 400;
    letter-spacing: 0.1vw;
    line-height: 1.75;
    color: #fff;
    width: 42.7vw;
    height: auto;
    z-index: 1;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1vw;
}

.login-btn-box {
    display: flex;
    z-index: 1;
    bottom: 3cqw;
    gap: 2cqw;
}

.login-btn,
.notice01 {
    background-color: #937558;
    color: #fff;
    width: 12.5cqw;
    height: 2.75cqw;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 400;
    letter-spacing: 1px;
    border-bottom: 4px solid #6f5236;
    cursor: pointer;
    transition: 0.2s ease;
}

.login-btn:hover,
.notice01:hover {
    transform: scale(0.975);
}
.box-option.t1 {
    text-align: center;
}
.login-text {
    font-size: 1.2rem;
    font-weight: 500;
    color: #fff;
    letter-spacing: 2px;
}
.login-text.ye {
    font-size: 1.4rem;
    font-weight: 600;
    color: #dbba9a;
    letter-spacing: 2px;
}
.login-id {
    font-size: 1.3rem;
    line-height: 1;
    font-weight: 500;
    color: #fff;
    letter-spacing: 2px;
}


/* .awakening-stage {
    width: 63%;
    border: 3px solid #6f5236;
    overflow: hidden;
    transform: translateZ(0);
    -webkit-mask-image: -webkit-radial-gradient(white, black);
}

@keyframes brighten-effect {
    0% {
        filter: brightness(1); 
    }
    20% {
        filter: brightness(1.5); 
    }
    100% {
        filter: brightness(1);
    }
}

.awakening-stage.is-brightening {
    animation: brighten-effect 2s ease-out; 
} */


.awakening-stage {
    position: relative;
    z-index: 1; 
    width: 63%;
    border: 3px solid #6f5236;
    overflow: hidden;
    transform: translateZ(0);
    -webkit-mask-image: -webkit-radial-gradient(white, black);

}


.awakening-stage::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url(../img/eventbg.jpg);
    background-size: cover; 
    background-position: center; 
    background-repeat: no-repeat;
    z-index: -1;
}


@keyframes brighten-bg-effect {
    0% {
        filter: brightness(1);
    }
    25% {
        filter: brightness(1.5);
    }
    100% {
        filter: brightness(1);
    }
}


.awakening-stage.is-brightening::before {
    animation: brighten-bg-effect 2s ease-out;
}



.hero-card-btn {
    padding: 0;
    margin: 0;
    border: none;
    outline: none;
    background: transparent;
    display: flex;
    flex-direction: column;
    width: 9cqw;
    cursor: pointer;
    overflow: hidden;
    appearance: none;
    -webkit-appearance: none;
    transition: 0.2s ease;
}

.hero-card-btn:hover {
    transform: translateY(-2px);
}





.card-avatar-box {
    width: 4cqw;
    height: 6.5cqw;
    padding: 0.5cqw 2.5cqw;
    background-color: #000000d1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.25s ease;
}
.card-avatar-box:hover {
    background-color: #000000f3;
}
.card-avatar-box img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.card-label-bar {
    background-color: #937558;
    color: var(--text-white);
    font-size: 1rem;
    font-weight: 400;
    text-align: center;
    padding: 0.4cqw 0;
    letter-spacing: 1.5px;
    border-bottom: 3px solid #6f5236;
    transition: background-color 0.25s ease;
}
.hero-card-btn:hover .card-label-bar {
    background-color: #a88769;
}

.energy-pill {
    background-color: #000000e3;
    color: var(--text-white);
    font-size: 1rem;
    font-weight: 700;
    padding: 0.3cqw 3cqw;
    border-radius: 999px;
    letter-spacing: 1.5px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    user-select: none;
}

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

@keyframes gogoFadeOut {
    0% {
        opacity: 1;
        visibility: visible;
    }
    100% {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    }
}

@media (min-width: 861px) {
    .awakening-stage {
        width: 57%;
        background-color: #000000;
        background-image: url("../img/eventbg.jpg");
        background-position: center center;
        background-size: cover;
        background-repeat: no-repeat;
        padding: 3%;
        display: grid;
        align-items: center;
        justify-content: space-between;
    }

    .hero-column.left-column {
        grid-column: 1;
        grid-row: 1;
        display: flex;
        flex-direction: column;
        gap: 2cqw;
    }
    .stage-header-area {
        grid-column: 2;
        grid-row: 1;
        display: flex;
        justify-content: center;
        align-items: flex-end;
        height: 100%;
        padding-bottom: 12cqw;
    }
    .stage-buttons-area {
        display: contents;
    }
    .hero-column.right-column {
        grid-column: 3;
        grid-row: 1;
        display: flex;
        flex-direction: column;
        gap: 2cqw;
    }
}

@media (max-width: 1024px) {
    .rewards-card {
        width: 90%;
    }
}

@media (max-width: 860px) {
    .featured-rewards {
        grid-template-columns: 1fr;
        width: 100%;
    }
    .rewards-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
    }
    .stage-buttons-area {
        width: 100%;
        background-color: #5b7c9e;
        background-image: url("../img/eventbg.jpg");
        background-position: center center;
        background-size: cover;
        background-repeat: no-repeat;
        padding: 16px 12px;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    .hero-column {
        display: contents;
    }
    .energy-pill {
        font-size: 0.88rem;
        padding: 8px 24px;
    }
    .card-label-bar {
        font-size: 0.85rem;
        padding: 6px 0;
    }
}

@media screen and (max-width: 768px) {
    :root {
        --card-width: 86vw;
    }

    #section-1 {
        padding: 0 0 8vw;
    }
    #section-4 {
        padding: 3vw 0 6vw;
    }

    .gogo {
        width: 80vw;
        top: 1vw;
        padding: 6px 16px;
        font-size: 0.85rem;
    }
    .carousel-stage {
        width: 100vw;
        height: 48vw;
        margin-top: 2vw;
    }
    .carousel-card {
        width: 100%;
    }
    .carousel-card.is-prev {
        transform: translateX(-104%);
    }
    .carousel-card.is-next {
        transform: translateX(4%);
    }

    .nav-btn {
        width: 72px;
        height: 36px;
        padding: 6px 24px;
    }
    .nav-btn.prev {
        left: 0px;
        top: 40%;
    }
    .nav-btn.next {
        right: 0px;
        top: 40%;
    }

    .gk-h1 {
        font-size: 1.25rem;
        text-align: center;
        margin-top: 3vw;
        padding: 0 4vw;
        line-height: 1.4;
    }
    .gk-h2 {
        font-size: 0.95rem;
        text-align: center;
        margin-top: 1vw;
        padding: 0 4vw;
        line-height: 1.4;
    }

    .activity-rules {
        gap: 12px;
    }
    .rule-row {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        gap: 10px !important;
        font-size: 0.88rem;
    }
    .rule-label {
        font-size: 0.88rem !important;
        white-space: nowrap !important;
        width: auto !important;
        border-bottom: none !important;
        padding-bottom: 0 !important;
        flex-shrink: 0 !important;
    }
    .rule-divider {
        display: inline-block !important;
        flex-shrink: 0 !important;
    }
    .rule-content {
        flex: 1 !important;
        min-width: 0 !important;
        word-break: break-word !important;
    }
    .rule-steps {
        gap: 8px;
        padding-left: 18px;
    }

    .npc02 {
        display: none;
    }
    .featured-rewards {
        grid-template-columns: 1fr;
        width: 100%;
        gap: 5vw;
        margin-bottom: 5vw;
    }
    .featured-card-single .card-banner {
        padding: 1.5vw 0;
        font-size: 1rem;
        letter-spacing: 2px;
    }
    .featured-card-single .card-content {
        grid-template-columns: 25vw 1fr;
        gap: 12px;
        padding: 4vw;
        align-items: start;
    }
    .img-box-sps {
        width: 25vw;
        height: auto;
    }
    .single-info .item-title {
        font-size: 1.05rem;
    }
    .single-info .item-desc,
    .single-info .item-weight {
        font-size: 0.8rem;
    }

    .featured-card-combo .card-content {
        padding: 6vw 0;
        gap: 2.5vw;
    }
    .img-box-sm {
        width: 30vw;
        height: auto;
    }


    .combo-info .combo-sub {
        font-size: 0.8rem;
    }

    .combo-info .combo-title {
        font-size: 1.1rem;
        font-weight: 500;
    }



    .rewards-grid {
        grid-template-columns: repeat(2, 1fr);
        width: 100%;
        gap: 6vw;
    }
    .reward-item {
        padding: 4vw 0;
    }
    .reward-item .img-box-sm {
        width: 17vw;
        height: auto;
        margin-bottom: 0;
    }
    .reward-item .item-name {
        font-size: 0.78rem;
        line-height: 1.35;
    }

    #box-ro-login,
    #box-ro-logout {
        width: 100%;
        padding: 0 4vw;
        box-sizing: border-box;
    }
    .login-text {
        font-size: 0.95rem;
        text-align: center;
        line-height: 1.5;
    }
    .login-text.ye {
        font-size: 1.05rem;
    }
    .login-id {
        font-size: 1.1rem;
        text-align: center;
        margin-bottom: 4px;
    }

    .login-btn-box {
        width: 100%;
        flex-direction: row;
        justify-content: center;
        gap: 10px;
        flex-wrap: wrap;
        margin-top: 2vw;
    }
    .login-btn,
    .notice01 {
        width: 42vw;
        max-width: 160px;
        height: 42px;
        font-size: 0.88rem;
        border-bottom-width: 3px;
    }

    .awakening-stage {
        width: 90%;
        margin: 0 auto 4vw;
        border-width: 2px;
    }
    /* .stage-header-area {
        width: 100%;
        min-height: 47vw;
        background-image: url("../img/eventbg.jpg");
        background-position: center center;
        background-size: cover;
        background-repeat: no-repeat;
        padding-bottom: 6vw;
        display: flex;
        justify-content: center;
        align-items: flex-end;
    } */


    .stage-header-area {
        position: relative;
        z-index: 1;
        width: 100%;
        min-height: 47vw;
        padding-bottom: 6vw;
        display: flex;
        justify-content: center;
        align-items: flex-end;
    }


    .stage-header-area::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-image: url(../img/eventbg.jpg);
        background-position: center center;
        background-size: cover;
        background-repeat: no-repeat;
        z-index: -1;
    }

    .awakening-stage.is-brightening .stage-header-area::before {
        animation: brighten-bg-effect 2s ease-out !important;
    }


    .energy-pill {
        font-size: 0.88rem;
        padding: 6px 20px;
    }
    .stage-buttons-area {
        background: #2e251c;
        padding: 5vw;
        gap: 5vw;
        width: 90%;
    }
    .hero-card-btn {
        width: 100%;
    }
    .card-avatar-box {
        width: 40%;
        height: auto;
        padding: 10% 30%;
    }
    .card-label-bar {
        font-size: 0.85rem;
        padding: 6px 0;
        border-bottom-width: 2px;
    }

    .popup-box {
        width: 92vw;
    }
    #popup-content-gift,
    #popup-content-notice {
        width: 100%;
        box-sizing: border-box;
        padding: 4vw;
        max-height: 65vh;
    }
    .history-log-wrapper {
        gap: 12px;
    }
    .record-card {
        border-width: 1px;
    }
    .log-header {
        font-size: 0.85rem;
        padding: 8px 10px;
    }
    .log-cell {
        font-size: 0.82rem;
        padding: 10px;
    }
}

@media (max-width: 520px) {
    .rewards-card {
        width: 100%;
    }
    .rewards-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    .reward-item {
        min-height: 135px;
    }
}

@media screen and (max-width: 480px) {
    .rule-row {
        flex-direction: column !important;
        gap: 6px !important;
    }
    .rule-divider {
        display: none !important;
    }
    .rule-label {
        width: 100% !important;
        border-bottom: 1px solid rgba(212, 163, 115, 0.4) !important;
        padding-bottom: 4px !important;
    }
}


@supports (-webkit-touch-callout: none) {
    .hero-card-btn,
    .login-btn,
    .nav-btn,
    .notice01,
    .reward-item {
        -webkit-tap-highlight-color: transparent;
        -webkit-touch-callout: none;
    }
    .carousel-card,
    .carousel-stage,
    .hero-card-btn {
        -webkit-transform: translateZ(0);
    }
}
