@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700&display=swap');

/* ========== 기본 스타일 ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    list-style-type: none;
    font-size: 14px;
}

body {
    background-color: #000;
    margin: 0;
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
    color: #fff;
    background-image: 
        radial-gradient(circle at 50% 10%, rgba(18, 39, 130, 0.3) 0%, rgba(0, 0, 0, 0) 60%),
        linear-gradient(180deg, #080226 0%, #000 100%);
    overflow: hidden; /* 이 부분을 확인 */
}

/* 모달이 열렸을 때 스크롤 방지 */
body.modal-open {
    overflow: hidden !important;
    position: fixed !important;
    width: 100% !important;
}

/* ========== 공지사항 띠 스타일 ========== */
.notice-banner {
    background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
    color: white;
    padding: 8px 0;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(255, 65, 108, 0.3);
    border-bottom: 2px solid #e63946;
}

.notice-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    animation: slideIn 0.5s ease-out;
}

/* 공지사항 텍스트 영역 (제목 + 힌트) */
.notice-text-area {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    cursor: pointer;
    transition: background-color 0.3s ease;
    padding: 8px 12px;
    border-radius: 6px;
    margin: 0 10px;
}

.notice-text-area:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* 닫기 버튼 영역 */
.notice-close-area {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
}

@keyframes slideIn {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.notice-content:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* 공지사항이 없을 때는 클릭 불가능하게 */
.notice-content:not([onclick]) {
    cursor: default;
}

.notice-content:not([onclick]):hover {
    background-color: transparent;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.notice-text {
    font-weight: 600;
    font-size: 13px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
    letter-spacing: 0.5px;
    width: 90%;
    text-align: center;
    padding-right: 5%;
}

.notice-text.clickable {
    text-decoration: underline;
    user-select: none;
}

/* 공지사항 힌트 스타일 */
.notice-hint {
    color: white;
    font-size: 0.75rem;
    animation: blink 2s infinite;
    white-space: nowrap;
    text-decoration: underline; /* 밑줄 추가 */
    text-align: center;
    width: 10%;
}

.notice-close {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
    font-weight: bold;
}

.notice-close:hover {
    background-color: rgba(255,255,255,0.4);
    transform: rotate(90deg);
}

@keyframes blink {
    0%, 50% { opacity: 0.9; }
    25% { opacity: 0.5; }
}

/* 모바일에서는 힌트 텍스트 크기 조정 - 900px 이하로 변경 */
@media (max-width: 900px) {
    .notice-hint {
        font-size: 0.65rem;
        margin-left: 6px;
    }
    
    .notice-text-area {
        margin: 0 5px;
        padding: 6px 8px;
    }
    
    /* 모바일에서 body overflow 허용 */
    body {
        overflow-y: auto !important;
    }
    
    /* 공지사항 배너 모바일 최적화 */
    .notice-content {
        padding: 0 10px;
    }
    
    .notice-text {
        font-size: 12px;
        padding-left: 5%;
        width: 95%;
    }
    
    /* 모달 모바일 최적화 */
    .notice-modal-content {
        width: 95%;
        margin: 10px;
    }
    
    .notice-modal-header {
        padding: 15px 20px 10px;
    }
    
    .notice-modal-title {
        font-size: 1.3rem;
    }
    
    .notice-modal-body {
        padding: 20px;
    }
    
    .notice-detail-content h3 {
        font-size: 1.2rem;
    }
    
    .notice-detail-text {
        font-size: 0.95rem;
    }
}

/* 데스크톱에서만 body overflow hidden - 901px 이상으로 변경 */
@media (min-width: 901px) {
    body {
        overflow: hidden;
    }
}

/* ========== 공지사항 모달 스타일 ========== */
.notice-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.notice-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.notice-modal-content {
    position: relative;
    background: linear-gradient(135deg, rgba(3, 13, 53, 0.95), rgba(8, 2, 38, 0.95));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.notice-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 25px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.notice-modal-title {
    color: #73ec9c;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    background: linear-gradient(to right, #73ec9c, #8cf0f0);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.notice-modal-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
    font-weight: bold;
}

.notice-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

.notice-modal-body {
    padding: 25px;
}

.notice-detail-content h3 {
    color: white;
    font-size: 1.3rem;
    font-weight: 600;
    margin: 0 0 15px 0;
    line-height: 1.4;
}

.notice-detail-meta {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.notice-detail-meta span {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

.notice-detail-text {
    color: #eaf0ff;
    font-size: 1rem;
    line-height: 1.6;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.notice-modal-footer {
    padding: 15px 25px 25px;
    text-align: center;
}

.notice-modal-btn {
    background: linear-gradient(135deg, rgba(255, 40, 70, 0.8), rgba(180, 20, 50, 0.8));
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 40, 70, 0.3);
}

.notice-modal-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 40, 70, 0.4);
    background: linear-gradient(135deg, rgba(255, 40, 70, 0.9), rgba(180, 20, 50, 0.9));
}

/* ========== 푸터 스타일 ========== */
.footer {
    background: rgba(3, 13, 53, 0.8);
    color: white;
    text-align: center; /* 중앙 정렬 추가 */
    padding: 20px 0;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 100;
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer p {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.8;
    text-align: center; /* 명시적으로 중앙 정렬 */
}