@import url("https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.9/dist/web/static/pretendard.min.css");

@font-face {
    font-family: Logo;
    src: url('../fonts/logo.woff') format('woff');
    font-weight: normal;
    font-style: normal;
}

body { 
    margin: 0; 
    overflow: hidden; 
    font-family: Pretendard, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* 로딩 화면 */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #111111;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease;
}

#loading-screen.hidden {
    opacity: 0;
    pointer-events: none;
}

.loading-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 모바일 안내 화면 */
#mobile-warning {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: black;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1.7;

}

.mobile-content {
    text-align: center;
    color: white;
    font-family: Pretendard, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.mobile-content p {
    font-size: 1rem;
    padding: 1rem;
    font-weight: 400;
    word-break: keep-all;
}

#keymapping {
    position: fixed;
    bottom: 3.5rem;
    right: 1rem;
    display: flex;
    flex-direction: row;
    gap: 12px;
    font-family: Pretendard, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    user-select: none;
    opacity: 0;
    transition: opacity 0.5s ease 0.3s;
}

#keymapping.visible {
    opacity: 1;
}

.key-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.5;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.key-item:hover {
    opacity: 0.8;
}

.key-item.active {
    opacity: 1.0;
}

.key-item.active:hover {
    opacity: 1.0;
}

.key-item.active .key-label {
    background-color: white;
    color: black;
}

.key-label {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 0.5rem;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    backdrop-filter: blur(10px);
    line-height: 1;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.key-desc {
    color: white;
    font-size: 1rem;
    font-weight: 700;
}

.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex: 0 0 auto;
    padding: .5rem 1rem;
    font-size: .75rem;
    text-align: right;
    color: white;
}

.header a,
.footer a {
    opacity: .3;
    text-decoration: none;
    color: white;
}

.header a:hover,
.footer a:hover {
    opacity: 1;
}

.logo {
    display: inline-flex;
    align-items: center;
    position: relative;
    font-family: Logo, sans-serif;
    font-size: 1rem;
}

.logo span:last-child {
    display: none;
}

@media screen and (max-width: 900px) {
    .logo span:first-child {
        display: none;
    }
    .logo span:last-child {
        display: inline-block;
    }
}