*,
body,
html {
    margin: 0;
    padding: 0
}

.feature,
.func-btn,
.hero__inner {
    text-align: center
}

.btn,
.func-btn {
    text-decoration: none
}

* {
    box-sizing: border-box
}

body {
    font-family: 'Press Start 2P', sans-serif;
    background: #0d0d0d;
    color: #fff;
    line-height: 1.6
}

.btn {
    display: inline-block;
    padding: .9rem 1.6rem;
    border-radius: 10px;
    border: 2px solid #fff;
    font-size: .85rem;
    transition: transform .2s, box-shadow .2s
}

.btn--primary {
    background: linear-gradient(45deg, #4f46e5, #6b5df0)
}

.btn--secondary {
    background: linear-gradient(45deg, #e03e2d, #991818)
}

.btn--outline {
    background: 0 0;
    border-color: #4f46e5
}

.btn:hover {
    transform: translateY(-4px) scale(1.05)
}

.hero {
    height: 100vh;
    position: relative;
    overflow: hidden
}

.hero__mask {
    inset: 0;
    background: rgba(0, 0, 0, .55);
    backdrop-filter: blur(2px)
}

.hero__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%
}

.hero__logo {
    width: 280px;
    filter: drop-shadow(0 0 10px #4f46e5)
}

.hero__title {
    margin-top: 1.5rem;
    font-size: 1.5rem;
    text-shadow: 0 0 8px #4f46e5
}

.hero__subtitle {
    margin: 1rem 0 1rem;
    font-size: .9rem;
    max-width: 28rem
}

.hero__cta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center
}

.features {
    display: grid;
    gap: 2rem;
    margin: 4rem auto
}

@media(min-width: 768px) {
    .hero__title {
        font-size: 2rem
    }

    .features {
        grid-template-columns: repeat(3, 1fr)
    }
}

.feature img {
    width: 120px;
    height: auto;
    margin-bottom: 1rem
}

.feature h3 {
    margin: .5rem 0
}

body,
html {
    overflow-x: hidden;
    height: 100%
}

.hero,
.hero__bg,
.hero__inner,
.hero__mask,
body.site {
    width: 100%;
    min-height: 100vh;
    box-sizing: border-box
}

.hero__bg,
.hero__mask {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none
}

.hero__bg {
    inset: 0;
    object-fit: cover;
    object-fit: cover;
    z-index: 0;
    background: #000;
    transition: opacity .6s
}

#video-intro {
    z-index: 1;
    opacity: 1
}

#video-loop {
    z-index: 2;
    opacity: 0
}

.hero__mask {
    background: linear-gradient(to bottom, rgba(0, 0, 0, .38) 0, rgba(0, 0, 0, .85) 90%);
    z-index: 3
}

.hero__inner {
    position: relative;
    z-index: 10;
    padding-top: 11vh
}

.hero__cta-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.6rem;
    margin-bottom: 2.6rem;
    width: 100%;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto
}

.hero__cta--main {
    width: 100%;
    display: flex;
    justify-content: center
}

.hero__cta-main-btn {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    font-size: 1.16em;
    font-weight: 700;
    letter-spacing: 2px;
    border-radius: 18px;
    border: 2.5px solid #f6d07e;
    background: linear-gradient(90deg, #f2ac3c 0, #c8541a 100%);
    color: #fff6e3;
    text-shadow: 0 2px 0 #5a2a01, 0 0 8px #fae59b99;
    box-shadow: 0 4px 24px #80450630, 0 0 2px #a3762d;
    position: relative;
    transition: transform .14s, box-shadow .18s, background .28s;
    padding: 1.05em .5em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .75em
}

.hero__cta-main-btn:hover {
    background: linear-gradient(90deg, #ffe1a0 0, #ad4c00 100%);
    box-shadow: 0 10px 40px #c19b5a70, 0 0 24px #ce963a33;
    color: #fff3c2;
    transform: scale(1.03) translateY(-2px);
    border-color: #ffe1a0
}

.hero__cta--download {
    display: flex;
    gap: 1.2rem;
    width: 100%;
    justify-content: center
}

.hero__cta--download .btn--secondary {
    flex: 1 1 0;
    border-radius: 14px;
    min-width: 0;
    background: linear-gradient(90deg, #2d2c6d 0, #3995c7 100%);
    border: 2.2px solid #87e1fc;
    color: #ffe;
    font-size: 1.06em;
    font-weight: 700;
    letter-spacing: 1px;
    text-shadow: 0 2px 0 #183666, 0 0 8px #aaf7ff33;
    box-shadow: 0 4px 18px #3a79ae20, 0 0 2px #2d3d6d44;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .6em;
    padding: .96em .5em;
    transition: transform .14s, box-shadow .16s, background .28s
}

.hero__cta--download .btn--secondary:hover {
    background: linear-gradient(100deg, #4865b7 0, #73e6ff 100%);
    color: #fff;
    box-shadow: 0 8px 28px #4cddf755;
    border-color: #fff7cd;
    transform: scale(1.05) translateY(-2px)
}

.hero__cta--download .btn--secondary svg,
.hero__cta-main-btn svg {
    height: 1.2em;
    width: 1.2em;
    margin-bottom: -2px;
    flex-shrink: 0;
    filter: drop-shadow(0 1px 0 #fff2) drop-shadow(0 0 4px #fffd)
}

@media (max-width: 700px) {

    .hero__cta--download,
    .hero__cta--main,
    .hero__cta-group {
        max-width: 99vw
    }

    .hero__cta-group {
        gap: 1rem
    }

    .hero__cta--download {
        flex-direction: column;
        gap: .7rem
    }

    .hero__cta--download .btn {
        width: 100%
    }
}

.hero__bg--desktop {
    display: none
}

.hero__bg--mobile {
    display: block;
    width: 100%;
    height: auto
}

@media (min-width: 768px) {
    .hero__bg--desktop {
        display: block
    }

    .hero__bg--mobile {
        display: none
    }
}

.game-functions {
    background: #15121d;
    padding: 48px 0 36px
}

.game-functions__container {
    display: flex;
    flex-wrap: wrap;
    gap: 2.2rem;
    justify-content: center;
    align-items: stretch;
    max-width: 1200px;
    margin: 0 auto
}

.func-btn {
    width: 210px;
    min-height: 188px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    background: linear-gradient(120deg, #232034 70%, #28203a 100%);
    border: 2.5px solid #f9d072;
    border-radius: 22px;
    box-shadow: 0 2px 16px #0a0a1c88, 0 6px 32px #f7cc7b15;
    padding: 32px 18px 20px;
    margin-bottom: 0;
    color: #f6d391;
    transition: box-shadow .15s, border-color .15s, transform .11s;
    cursor: pointer;
    position: relative
}

.func-btn__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px
}

.func-btn__icon img,
.func-btn__icon svg {
    width: 56px;
    height: 56px;
    display: block;
    filter: drop-shadow(0 3px 8px #ffb70055) drop-shadow(0 0 10px #fff6a599)
}

.func-btn__title {
    font-size: 1.13em;
    font-weight: 700;
    margin-bottom: .3em;
    color: #ffe6bb;
    letter-spacing: 1px;
    text-shadow: 0 2px 0 #583d0c, 0 0 6px #ffde7f55
}

.func-btn__desc {
    font-size: .99em;
    color: #ffe6bbcc;
    text-shadow: 0 1px 0 #1e1c1b;
    line-height: 1.5
}

.func-btn:focus,
.func-btn:hover {
    box-shadow: 0 8px 28px #ffc65166, 0 0 18px #fff3;
    border-color: #fff3c1;
    background: linear-gradient(115deg, #3b2612 35%, #e5a13d 110%);
    color: #fff6dc;
    transform: scale(1.045) translateY(-3px);
    z-index: 2
}

@media (max-width: 1200px) {
    .func-btn {
        width: 30vw;
        min-width: 168px;
        max-width: 270px
    }
}

@media (max-width: 900px) {
    .game-functions__container {
        gap: 1.2rem
    }

    .func-btn {
        width: 43vw;
        min-width: 140px
    }
}

@media (max-width: 600px) {
    .game-functions__container {
        flex-direction: column;
        align-items: center;
        gap: .8rem
    }

    .func-btn {
        width: 92vw;
        max-width: 99vw
    }
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.2em
}

.gamex123-link img {
    height: 68px;
    width: auto;
    display: block;
    border-radius: 9px;
    box-shadow: 0 2px 14px #ffecad44;
    transition: box-shadow .18s, transform .15s
}

.gamex123-link img:hover {
    box-shadow: 0 6px 24px #ffd70088, 0 0 10px #fff0;
    transform: scale(1.07)
}

@media (max-width: 700px) {
    .gamex123-link img {
        width: 100%;
        max-width: 95%;
        height: auto;
    }
}

.footer {
    width: 100%;
    padding: 30px 0 16px;
    background: 0 0;
    text-align: center;
    /* ← 關鍵*/
}

.footer h1 {
    display: inline-block;
    font-size: 2.4em;
    font-family: 'Noto Sans TC', Arial, sans-serif;
    font-weight: 900;
    letter-spacing: 0.13em;
    margin: 0 auto 18px auto;
    padding: 0.08em 0.55em;
    /* 魔塔主題：淡金+深金漸層*/
    background: linear-gradient(95deg, #fffbe1 0%, #ffe2a0 32%, #ffd047 60%, #caa658 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    /* 柔和金色光暈+黑色描邊*/
    text-shadow: 0 1.5px 3.5px #2d222288, 0 0 14px #ffd047a5, 0 0 30px #eec55344, 0 0 1px #fffbe188;
    filter: brightness(1.15);
    transition: color 0.17s, text-shadow 0.19s;
    /* 金光呼吸動畫*/
   /* animation: motower-footer-glow 3.1s cubic-bezier(.51, 1.22, .22, 1) infinite alternate;*/
}

/*@keyframes motower-footer-glow {
    0% {
        filter: brightness(1.11) drop-shadow(0 0 8px #ffefb1cc);
    }

    50% {
        filter: brightness(1.24) drop-shadow(0 0 23px #fff9cf);
    }

    100% {
        filter: brightness(1.11) drop-shadow(0 0 8px #ffefb1cc);
    }
}*/

.server-badge {
    background: #fffbe8;
    color: #b44b00;
    box-shadow: 0 2px 8px #ffdd8850;
    border: 2px solid #ffd670;
    transition: background 0.25s, box-shadow 0.25s;
}

.badge-upcoming {
    background: linear-gradient(90deg, #fff7d1 0%, #ffe19a 100%);
    color: #b48309;
    border: 2px solid #ffdd70;
    box-shadow: 0 2px 12px #ffe8aa80;
    position: relative;
    overflow: hidden;
    font-weight: bold;
    padding: 8px 28px;
    border-radius: 18px;
    font-size: 1.07em;
    letter-spacing: 1px;
}

.badge-upcoming::after {
    content: '';
    position: absolute;
    left: -40%;
    top: 0;
    width: 40%;
    height: 100%;
    background: linear-gradient(120deg, rgba(255, 220, 100, 0.12) 0%, rgba(255, 255, 255, 0.55) 55%, rgba(255, 220, 100, 0.18) 100%);
    transform: skewX(-25deg);
    /*animation: shine 2.1s infinite;*/
    pointer-events: none;
}

/*@keyframes shine {
    from {
        left: -40%;
    }

    to {
        left: 120%;
    }
}*/

.badge-online {
    background: #ecfff4;
    color: #098245;
    border: 2px solid #9ee4ba;
    font-weight: bold;
    padding: 8px 28px;
    border-radius: 18px;
    font-size: 1.07em;
    letter-spacing: 1px;
    box-shadow: 0 2px 8px #adf1cb90, 0 0 0 0 #75e7a470;
   /* animation: online-breath 2.6s ease-in-out infinite;*/
}

/* @keyframes online-breath {

    0%,
    100% {
        box-shadow: 0 2px 8px #adf1cb90, 0 0 0 0 #75e7a470;
    }

    50% {
        box-shadow: 0 2px 16px #adf1cbcc, 0 0 14px 8px #75e7a470;
    }
} */

.server-badge-area span {
    font-size: 1.07em;
    display: inline-block;
    padding: 6px 16px;
    border-radius: 16px;
    font-weight: 600;
    letter-spacing: 1px;
}

@media (max-width: 600px) {
    .server-badge-area span {
        font-size: 0.60em;
        padding-left: 1vw;
        padding-right: 1vw;
    }
}