@charset "utf-8";

/* -------------------- */
/* PCSP共通 */
/* -------------------- */

.gooad_close {
    display: none !important;
}

/* オーバーレイ共通 */
#gooad-pc_overlay,
#gooad-sp_overlay {
    position: fixed;
    z-index: 1010;
    bottom: 0;
    left: 0;
    width: 100%;
    margin: 0;
    background: #FFF;
    text-align: center;
}

/* -------------------- */
/* PC */
/* -------------------- */

#gooad-badge300_1 {
    min-height: 250px;
    margin: 0 0 1em;
    line-height: 0;
    text-align: center;
}

#gooad-badge300_2 {
    min-height: 250px;
    line-height: 0;
    text-align: center;
}

/* ダブレク親要素1～3 */
[id^="gooad-wrec"] {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1em;
    margin: 0 auto;
    line-height: 0;
    text-align: center;
}

/* ダブレク */
#gooad-badge300_3,
#gooad-badge300_4,
#gooad-badge300_5,
#gooad-badge300_6,
#gooad-badge300_7,
#gooad-badge300_8 {
    min-height: 250px;
    width: 300px;
}

/* オーバーレイ */
#gooad-pc_overlay {
    height: 90px;
}

/* オーバーレイ閉じるボタン */
.gooad_close_button_pc {
    position: absolute;
    right: 0px;
    top: -25px;
    cursor: pointer;
    height: 20px;
    width: 20px;
    background-color: #fff;
    border-radius: 10px 10px 0 0;
    padding: 5px 5px 0;
    z-index: 1010;
    opacity: 0.8;
}

.gooad_close_button_pc::before,
.gooad_close_button_pc::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 4px;
    height: 23px;
    background: #999;
}

.gooad_close_button_pc::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.gooad_close_button_pc::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

/* フッター調整 */
/* gam_event_listenersで追加 */
.gooad_footer_bottom_pc {
    padding-bottom: 90px;
}

/* オーバーレイが閉じられたときフッターの余白をデフォルトにする */
.gooad_footer_default_pc {
    padding-bottom: 24px;
}


/* -------------------- */
/* SP */
/* -------------------- */

#gooad-spbadge300_1 {
    min-height: min(360px, calc(100vw / 300 * 250));
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 8px auto;
    line-height: 0;
    text-align: center;
}

#gooad-spbadge300_2,
#gooad-spbadge300_3,
#gooad-spbadge300_4,
#gooad-spbadge300_5,
#gooad-spbadge300_6,
#gooad-spbadge300_7 {
    min-height: 250px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 8px auto;
    line-height: 0;
    text-align: center;
}

/* インフィード共通 */
[id^="gooad-spinfeed"] {
    margin-bottom: 10px;
}

/* iPhone safe-area */
@supports (padding-bottom: constant(safe-area-inset-bottom)) {
    #gooad-sp_overlay {
        padding-bottom: constant(safe-area-inset-bottom)
    }
}

@supports (padding-bottom: env(safe-area-inset-bottom)) {
    #gooad-sp_overlay {
        padding-bottom: env(safe-area-inset-bottom)
    }
}

/* オーバーレイ閉じるボタン */
.gooad_close_button_sp {
    position: absolute;
    right: 4px;
    top: -29px;
    cursor: pointer;
    height: 20px;
    width: 20px;
    background-color: #666;
    border-radius: 16px;
    padding: 4px;
    z-index: 1010;
    opacity: 0.8;
}

.gooad_close_button_sp::before,
.gooad_close_button_sp::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2px;
    height: 15px;
    background: #fff;
}

.gooad_close_button_sp::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.gooad_close_button_sp::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

/* フッター調整 */
/* オーバーレイがあるときフッターに余白追加 */
body:has(#gooad-sp_overlay) #NR-footer:not(.gooad_footer_default_sp) {
    padding-bottom: max(100px, calc(100vw / 320 * 100));
}

/* gam_event_listenersで追加 */
/* .gooad_footer_bottom_sp {
    padding-bottom: max(100px, calc(100vw / 320 * 100));
} */

/* オーバーレイが閉じられたときフッターの余白をデフォルトにする */
.gooad_footer_default_sp {
    padding-bottom: 24px;
}

/* トップへ戻るボタン */
body:has(#gooad-sp_overlay) #page-top-fix {
    bottom: min(240px, calc(100vw / 320 * 100) + 48px);
}
