/* 폰트 */
@font-face {
    font-family: 'Moneygraphy-Rounded';
    src: url('./font/Moneygraphy-Rounded.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: 'SGangwonEduPowerExtraBoldA';
    src: url('https://fastly.jsdelivr.net/gh/projectnoonnu/noonfonts_2201-2@1.0/GangwonEduPowerExtraBoldA.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}
@font-face {
    font-family: 'Pretendard-Regular';
    src: url('https://fastly.jsdelivr.net/gh/Project-Noonnu/noonfonts_2107@1.1/Pretendard-Regular.woff') format('woff');
    font-weight: 400;
    font-style: normal;
}
body{
    font-family: 'Pretendard-Regular', "Source Sans Pro", sans-serif !important;
}

.stApp > .stAppHeader .stDecoration{
    height:1rem;
    background-image: linear-gradient(90deg, #82f3ff, #2751e7);

}

/* 사이드바 */
.stSidebar{
    top: 1.125rem !important;
}
a[data-testid="stPageLink-NavLink"] > span{
    color:#fff !important;
    font-size: 1.2rem !important;
    padding:0.5rem !important;
}

div[data-testid="stMarkdownContainer"] {
    font-family: 'Pretendard-Regular', "Source Sans Pro", sans-serif !important;
    font-size: 16px !important;
}

/* Bottom */
.stAppViewContainer section>.stBottom> div{
    background-color: #1C2237 !important;
}


/* 서버접속상태 로그인버튼에 중복, 숨김 */
.stAppToolbar {
    display: none !important;
}

.stStatusWidget {
    /*display: none;*/
    z-index: 1;
}

a.unset {
    text-decoration: none !important;
}

section.stMain > div.stMainBlockContainer.block-container > div > div > div > div:nth-child(1) {
    background: red;
    display: none;
}


/* 로그인, 로그아웃 */
#header {
    background: #2D3140;
    position: fixed;
    width: 100%;
    height: 70px;
    top: 0;
    z-index: 1;
}
#sign-in-out {
    position: fixed;
    right: 33px;
    top: 25px;
    z-index: 999990;
}
#sign-in-out span {
    display: flex;
    align-items: center;
    color: #e4e4e6 !important;
    cursor: pointer;
}
#sign-in-out span:hover {
    color: #4195ff !important;
}
#sign-in-out a {
    display: flex;
    align-items: center;
    color: #e4e4e6 !important;
    cursor: pointer;
}
#sign-in-out a:hover {
    color: #4195ff !important;
}
#sign-in-out i { /*로그인 앞 아이콘 (Google Material Icons 사용)*/
    margin-right: 8px;
    font-size: 24px; /* 아이콘 크기 조정 */
}


/* 이용 약관 등 */
#side-bottom {
    position: fixed;
    /*bottom: 80px;*/
    left: 0px;
    margin: 30px;
    padding-left: 10px;
    border-left: 3px solid #9097b0;
}
#side-bottom > div:nth-child(n+2) { /*2번째 div 항목 부터*/
    margin-top: 6px;
}
#side-bottom span {
    color: #c6cada;
    cursor: pointer;
}
#side-bottom span:hover {
    color:#4195ff
}


/* 개발자 메뉴, 커스텀 메뉴 숨김 */
header[data-testid="stHeader"] {
    height:0;
}

/* 각 페이지 title */
body .stHeading h1{
    font-family: 'SGangwonEduPowerExtraBoldA',"Source Sans Pro", sans-serif;
    font-size: 45px;
    font-weight: bolder;
    background: linear-gradient(to right bottom, #82f3ff, #2751e7);
    color: transparent;
    -webkit-background-clip: text;
    text-align: center;
    padding-bottom: 34px;
    margin-top: -30px; /* 메뉴숨김으로 간격 넓어보임, 위 간격 조정 */
}


/* 번호 생성 로딩(일단 가운데로 옮김) */
.stSpinner {
    position: fixed;
    top: 50%;
    height: 100px;
    margin-top: -70px;
    display: flex;
    background: linear-gradient(to right, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 1) 50%, rgba(0, 0, 0, 0) 100%);
    z-index: 1;
}
.stSpinner > div{
    justify-content: center;
}


/* 클릭된 버튼 색 (ex. 역대 1등 제외) */
button[data-testid="stBaseButton-pillsActive"] {
    color:white;
    background: #4195ff;
}

/* 중복 메시지 */
div[data-testid="stToast"] {
    width:400px;
}

/* 공 색 */
.num-ball { /* 공통 */
    display:inline-block;
    color:white;
    border-radius:50%;
    width:30px;
    height:30px;
    line-height:30px;
    text-align:center;
    margin:2px;
}
.one_ten { /* 1~10 */
    background-color: #F4B400; /* yellow */
}
.eleven_twenty { /* 11~20 */
    background-color: #4285F4; /* blue */
}
.twentyone_thirty { /* 21~30 */
    background-color: #DB4437; /* red */
}
.thirtyone_forty { /* 31~40 */
    background-color: #C8C8C8; /* gray */
}
.fortyone_fortyfive { /* 41~45 */
    background-color: #0F9D58; /* green */
}

/* html과 streamlit 연결하는 숨겨야할 obj 숨김 */
[class*='st-key-hidden-obj-'] {
    display: none;
}
[id*="obj-link-"] {
    cursor: pointer;
}

.copyright {
    position: fixed;
    bottom: 0;
    right: 30px;
    z-index: 200;
}

/* iframe부분 */
[srcdoc*='</privacy-policy>'] {
    height: 80vh !important;
    border-bottom: 1px solid #dddddd !important;
}

/* iframe cookie 관련부분 */
div[data-testid="stElementContainer"]:has([srcdoc*='document.cookie']) {
    display:none;
}

/* modal부분 */
div[aria-label="dialog"]:has([srcdoc*='</privacy-policy>']) {
    width: 80vw !important;
    background: white;
}

div[aria-label="dialog"]:has([srcdoc*='</privacy-policy>']) > div:nth-child(1) {
    color: #1c2237;
    margin-left: 20px !important;
}

div[aria-label="dialog"]:has([srcdoc*='</privacy-policy>']) > button {
    color: #1c2237;
}

/* 선택저장 버튼 정렬 */
[class*='flex-end'] {
    display: flex !important;
    flex-direction: row !important;
    justify-content: flex-end;
    align-items: center;
}

[class*='flex-end'] div {
    width: fit-content !important;
}

[class*='flex-end'] a button {
    background-color: rgb(65 149 255); color: white; cursor: pointer; display: inline-flex; -webkit-box-align: center; align-items: center; -webkit-box-pack: center; justify-content: center; font-weight: 400; padding: 0.25rem 0.75rem; border-radius: 0.5rem; min-height: 2.5rem; margin-top: -1px; line-height: 1.6; text-transform: none; font-size: inherit; font-family: inherit; width: auto; user-select: none; border: 1px solid #4195FF;
}

.police-package {
    color: #c6cada !important;
    cursor: pointer;
}
.police-package:hover {
    color:#4195ff !important;;
}

/* 내 번호 조회 모바일 */
@media all and (max-width: 800px) {
    .basic-custom-table {
        width: 100%;
    }
    .basic-custom-table {
        border: 0;
    }

    .basic-custom-table thead {
        border: none;
        clip: rect(0 0 0 0);
        height: 1px;
        margin: -1px;
        overflow: hidden;
        padding: 0;
        position: absolute;
        width: 1px;
    }

    .basic-custom-table th {
        display: flex;
        justify-content: space-evenly;
    }

    .basic-custom-table tr {
        border-top: 3px solid gray;
        border-bottom: 3px solid #ddd;
        display: block;
        margin-bottom: .625em;
    }

    .basic-custom-table td {
        border-bottom: 1px solid #ddd;
        display: block;
        font-size: .8em;
        text-align: right;
    }

    .basic-custom-table td::before {
        content: attr(data-label); /*data-label을 가상요소 표출*/
        float: left;
        font-weight: bold;
        text-transform: uppercase;
    }

    .basic-custom-table td:last-child {
        border-bottom: 0;
    }
}




@media screen and (max-width: 728px) {
    :root {
        --mobile-ad-height: 100px;
    }

    .adsbygoogle {
        width: 300px;
        height: var(--mobile-ad-height);
    }
    .stApp {
        height: calc(100% - var(--mobile-ad-height));
    }
    #ad-bottom {
        height: var(--mobile-ad-height);

    }
    #ad-bottom > div {
        height: var(--mobile-ad-height);
        overflow: hidden;
        /*width:100%;*/
    }

    #side-bottom {
        bottom: var(--mobile-ad-height);
    }
}

@media screen and (min-width: 729px) {
    :root {
        --pc-ad-height: 90px;
    }

    .adsbygoogle {
        width: 728px;
        height: var(--pc-ad-height);
    }
    .stApp {
        height: calc(100% - var(--pc-ad-height));
    }
    #ad-bottom {
        height: var(--pc-ad-height);
    }

    #ad-bottom > div {
        height: var(--pc-ad-height);
        overflow: hidden;
    }

    #side-bottom {
        bottom: var(--pc-ad-height);
    }

}
