@import url('https://fonts.googleapis.com/css2?family=Lexend:wght@100..900&display=swap');

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

html {
    background: linear-gradient(180deg, #030014 0%, #000000 100%);
    min-height: 100%;
    width: 100%;
    overflow-x: hidden;
}

body {
    font-family: "Lexend", sans-serif;
    min-height: 100vh;
    color: white;
    width: 100%;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
    overflow-x: hidden;
}

.container,
.main {
    width: 100%;
    max-width: 480px;
    padding: 16px;
    margin: 0 auto;
}

img,
video,
canvas,
iframe {
    max-width: 100%;
    height: auto;
}

button {
    margin-top: 16px;
    font-weight: 600;
    height: 50px;
    border: none;
    background-color: transparent;
    color: white;
    border-radius: 16px !important;
}

.search-bar {
    padding: 8px 16px;
    border-radius: 16px;
    background-color: #16102B;
    display: flex;
    align-items: center;
    gap: 4px;
    position: relative;
    overflow: hidden;
    z-index: 10;
}

.background-shadow::after {
    content: "";
    position: absolute;
    top: 10px;
    right: 10px;
    height: 80px;
    width: 80px;
    background: rgba(86, 167, 255);
    filter: blur(80px);
    border-radius: 100%;
    z-index: -1;
}

.search-bar input {
    font-size: 16px;
    background-color: transparent;
    border: none;
    color: white;
    font-weight: 500;
    width: 100%;
    padding: 8px 6px;
}

.search-bar input::placeholder {
    color: white;
}

.search-bar input:focus {
    outline: none;
}

.search-empty-state {
    display: none;
    margin-top: 16px;
    text-align: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.search-empty-state.show {
    display: block;
}

.search-bar .icon {
    height: 24px;
    width: 24px;
    padding: 0;
    margin-top: 0;
    border: none;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.search-bar .icon img {
    height: 24px;
    width: 24px;
}

.search-bar .icon:focus-visible {
    outline: 2px solid rgba(74, 210, 78, 0.8);
    outline-offset: 4px;
    border-radius: 8px;
}

/* .ad-container {
    width: 100%;
    max-width: 100%;
    margin: 12px auto 0;
    padding: 0;
    display: grid;
    justify-items: center;
    overflow: hidden;
}

.ad-container .adsbygoogle {
    display: block !important;
    width: 100% !important;
    max-width: 100%;
    margin: 0 auto;
} */
.ad-container {
    margin-top: 5px;
    padding: 10px;
}

.ad-name {
    display: block;
    margin-top: 8px;
    font-size: 10px;
    letter-spacing: 0.08em;
    text-align: center;
    color: rgba(255, 255, 255, 0.65);
}

/* Button */
.coin-part {
    padding: 12px 4px 12px 16px;
    border: 2px solid #413665;
    border-radius: 16px;
    margin-top: 12px;
    background-color: #16102B;
    position: relative;
}

.claim-btn-main {
    display: grid;
}

.total-coin {
    display: flex;
    align-items: center;
    justify-content: center;
}

.coin-part .background-shadow::after {
    right: 45% !important;
    top: 15% !important;
    z-index: 1;
}

.total-coin img {
    height: 100px;
    width: 100px;
    object-fit: cover;
    background-size: cover;
    background-position: center;
}

.total-coin h6 {
    font-size: 22px;
    margin-top: -20px;
}

.claim-btns {
    display: flex;
    gap: 2px;
    align-items: center;
}

.claim-btns .open-btn {
    flex: 1 1 auto;
    min-width: 0;
}

.open-btn {
    padding: 12px 24px;
    background: #2563eb;
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-weight: 600;
    margin-top: 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.open-btn::before,
.open-btn::after {
    content: '';
    position: absolute;
    cursor: pointer;
    top: 0;
    left: -150%;
    height: 100%;
    width: 10%;
    background: linear-gradient(120deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(255, 255, 255, 0.1) 50%,
            rgba(255, 255, 255, 0) 100%);
    animation: shimmer 2s ease-in-out infinite;
    z-index: 0;
    pointer-events: none;
}

@keyframes shimmer {
    0% {
        left: -150%;
    }

    100% {
        left: 150%;
    }
}

.open-btn span {
    width: 100%;
}

.close-btn {
    height: 40px;
    text-align: center;
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 14px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    font-weight: 600;
    margin-top: 0;
}

.watch-btn-wrapper {
    display: flex;
    margin-top: 16px;
    gap: 4px;
}

.watch-btn-wrapper .claim-btn {
    margin-top: 0;
}

.watch-btn-wrapper span {
    font-size: 12px;
}

.open-btn img {
    height: 24px;
    width: 24px;
}

.open-btn:hover {
    background: #1d4ed8;
}

.claim-btns p {
    font-size: 12px;
}

/* Overlay */
.overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s ease;
    z-index: 11;
}

.overlay.active {
    opacity: 1;
    visibility: visible;
}

.toast-message {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%) translateY(16px);
    width: calc(100% - 32px);
    max-width: 420px;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(22, 16, 43, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
    z-index: 20;
}

.toast-message.show {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Dialog */
.dialog {
    background: #16102B;
    padding: 30px 30px 16px;
    width: calc(100% - 32px);
    max-width: 460px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid white;
    transform: scale(0.7) translateY(30px);
    opacity: 0;
    transition: all 0.35s ease;
}

.dialog img {
    height: 90px;
    width: 90px;
}

.dialog p {
    font-size: 14px;
    margin-bottom: 10px;
}

.dialog h4 {
    font-size: 14px;
    margin-bottom: 20px;
}

.overlay.active .dialog {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.claim-btn {
    padding: 8px 16px;
    border: none;
    background: radial-gradient(50% 71.4% at 50% 50%, #348AEF 0%, #263DF3 100%);
    color: white;
    border-radius: 6px;
    cursor: pointer;
    width: 100%;
    text-align: center;
}


/* Game Part */
.select-game-part p {
    font-size: 14px;
    margin: 0 auto;
    margin-top: 16px;
    text-align: center;
}

/* Game Part */
.game-part {
    margin-top: 16px;
    display: grid;
    gap: 16px;
}

.game-select {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.game-select .box {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border-radius: 16px;
    position: relative;
    background-color: #16102B;
    color: white;
    text-decoration: none;
    transition: 0.2s all linear;
    overflow: hidden;
}

.game-select .box:nth-child(1):hover {
    background:
        linear-gradient(180deg, rgba(50, 126, 240, 0) 0%, rgba(50, 126, 240, 0.3) 100%);

}

.game-select .box:nth-child(2):hover {
    background:
        linear-gradient(180deg, rgba(240, 50, 104, 0) 0%, rgba(240, 50, 104, 0.3) 100%);

}

.game-select .box:nth-child(3):hover {
    background:
        linear-gradient(180deg, rgba(50, 240, 56, 0) 0%, rgba(50, 240, 56, 0.3) 100%);

}

.game-select .box:nth-child(4):hover {
    background:
        linear-gradient(180deg, rgba(240, 117, 50, 0) 0%, rgba(240, 117, 50, 0.3) 100%);

}

.game-select .box img {
    height: 40px;
    width: 40px;
}

.game-select .box::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
     background-color: #16102B;
     z-index: -1;
}
.game-select .box::after {
    content: "";
    position: absolute;
    top: 0px;
    right: 5%;
    height: 40px;
    width: 40px;
    object-fit: contain;
    background-size: contain;
    background-repeat: no-repeat;
}

.game-select .action::after {
    background-image: url(../image/icon/action-bg.png);
}

.game-select .puzzle::after {
    background-image: url(../image/icon/puzzle-bg.png);
}

.game-select .racing::after {
    background-image: url(../image/icon/raching-bg.png);
}

.game-select .sports::after {
    background-image: url(../image/icon/sport-bg.png);
}

/* Game Card */
.game-card {
    text-decoration: none;
    color: white;
    display: grid;
    gap: 8px;
}

.card-box {
    background-color: #16102B;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.card-box.is-hidden,
.box.is-hidden {
    display: none;
}

.entry-free {
    position: absolute;
    top: 20%;
    right: 0;
    padding: 2px 4px;
    background-color: white;
    color: #360080;
    border-top-left-radius: 4px;
    border-bottom-left-radius: 4px;
    box-shadow: 0px 8px 10px 0px #00000040;

}

.game-card .game-data {
    padding: 12px 12px 0 12px;
    text-decoration: none;
    display: grid;
    gap: 8px;
    text-align: center;
}

.game-card .user {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.game-card .game-data p {
    color: #00C462;
    font-size: 14px;
    text-align: center;
    text-decoration: none;
}


.game-card .game-data span {
    height: 4px;
    width: 4px;
    border-radius: 100%;
    background-color: #00C462;
}


.game-card .game-data img {
    height: 100%;
    width: 100%;
    background-size: contain;
    background-repeat: no-repeat;
}

.game-card .game-data h4 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
}

.play-btn {
    background-image: url(../image/button-bg.png);
    width: 100%;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: contain;
    background-repeat: no-repeat;
    text-align: center;
    color: white;
    text-decoration: none;
    margin-top: 8px;
    aspect-ratio: 16/9;
    background-position: top center;
    cursor: pointer;
    font-size: 14px;
}

/* Play More */
.play-more button {
    border: none;
    background: linear-gradient(180deg, #4AD24E 0%, #266C28 100%);
    margin-top: 16px;
    border-radius: 16px;
    width: 100%;
    color: white;
    font-weight: 600;
}

.play-more button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Description */
.description {
    display: grid;
    gap: 12px;
    background: #16102B;
    border-radius: 16px;
    border: 1px solid #413665;
    margin-top: 16px;
    padding: 16px;
}

.description h4 {
    text-align: center;
}

.description hr {
    opacity: 0.5;
    margin-top: 0 !important;
    max-width: 100%;
    width: 100%;
}

hr {
    margin: 16px auto 0;
    opacity: 0.5;
    max-width: 90%;
}

.description p {
    font-size: 14px;
    font-weight: 300;
}

/* Page */
.game-page {
    display: grid;
    gap: 16px;
    justify-content: center;
    position: relative;
}

.game-page::after {
    top: 0px;
    right: 50%;
    transform: translateX(50%);
}

.game-page img {
    height: 50px;
    width: 50px;
    margin: 0 auto;
}

.footer-link {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 16px;
}

.footer-link a {
    color: white;
    font-weight: 600;
    transition: 0.2 all ease-in-out;
}

.footer-link a:hover {
    opacity: 0.7;
}

@media (max-width: 520px) {
    body {
        align-items: flex-start;
        min-height: 100dvh;
    }

    .container,
    .main {
        max-width: 100%;
        padding: 16px;
    }
}
