/* Cookie Banner Styles */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    padding: 20px;
    z-index: 9999;
    /* Boosted z-index to stay above the loading screen and side panel */

    /* Animation initial state */
    transform: translateY(100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.6s ease;
}

.cookie-banner.is-visible {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.cookie-content {
    max-width: 960px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 15px;
    font-size: 12px;
}

.cookie-content p {
    line-height: 2;
    margin: 0;
}

.cookie-content a {
    color: #fff;
}



.cookie-buttons {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.btn {
    padding: 10px 20px;
    border: none;
    cursor: pointer;
    border-radius: 4px;
    font-size: 12px;
}

.btn-accept {
    background-color: #fff;
    color: #000;
}

.btn-reject {
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.7);
    color: rgba(255, 255, 255, 0.7);
}

@media (min-width: 768px) {
    .cookie-banner {
        padding: 1.5vw 0; /* Vertical liquid padding */
    }

    .cookie-content {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
        max-width: 90vw; /* 水平方向のバウンディングボックスをリキッドへ */
        font-size: 0.96vw; /* ご指定のサイズ */
        gap: 3vw;
    }

    .cookie-buttons {
        gap: 0.78vw; /* ボタン間のリキッド隙間 */
    }

    .btn {
        padding: 0.78vw 1.56vw; /* ボタン内部のパディングも比例 */
        font-size: 0.96vw;
        border-radius: 0.26vw; /* 角丸もリキッド */
    }
}

/* Floating Banner Styles */
.floating-banner-wrapper {
    position: fixed;
    right: 0;
    bottom: 0;
    z-index: 110;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.floating-banner-wrapper.is-visible {
    opacity: 1;
    visibility: visible;
}

.floating-banner {
    position: relative;
    display: block;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    background-color: #fff;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
}

.floating-banner img {
    display: block;
    width: 250px;
    height: 250px;
    transition: width 0.3s ease, height 0.3s ease;
}

.banner-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    background-color: #333;
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    z-index: 10;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    transition: background-color 0.2s;
}

.banner-close:hover {
    background-color: #d24986;
    /* Pink brand color */
}

/* Tab Button (Default hidden, shows when minimized) */
.banner-tab {
    position: absolute;
    bottom: 0;
    right: 0;
    background-color: #d24986;
    /* Pink brand color */
    color: #fff;
    border: none;
    border-radius: 4px 0 0 0;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    gap: 8px;
}

.banner-tab:hover {
    background-color: #9e2b5d;
}

.tab-icon {
    width: 20px;
    height: auto;
    display: block;
}

.floating-banner-wrapper.is-minimized .floating-banner {
    transform: translateY(150%);
    opacity: 0;
    pointer-events: none;
}

.floating-banner-wrapper.is-minimized .banner-tab {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

@media screen and (max-width: 767px) {
    .floating-banner-wrapper {
        right: 0;
        bottom: 0;
    }

    .floating-banner img {
        width: 50vw;
        height: auto;
    }

    .banner-tab {
        font-size: 10px;
        padding: 6px 12px;
    }

    .tab-icon {
        width: 14px;
    }
}