/* ============================================================
   NeverBe Blog - 공통 스타일
   ============================================================ */

body {
    font-family: 'Noto Sans KR', 'Malgun Gothic', sans-serif;
}

/* 세션 사이드바 */
.session-item:hover {
    background: rgba(255, 255, 255, 0.1) !important;
}
.session-item.active {
    background: rgba(255, 255, 255, 0.15) !important;
    color: #fff !important;
}

/* 채팅 메시지 */
.message-bubble {
    word-break: break-word;
    line-height: 1.6;
}
.ai-content h2, .ai-content h3 { font-size: 1rem; font-weight: 700; margin-top: 1rem; }
.ai-content p  { margin-bottom: 0.5rem; }
.ai-content ul { padding-left: 1.2rem; }

/* 스트리밍 커서 */
.streaming-cursor::after {
    content: '▋';
    animation: blink 0.8s infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

/* 작은 버튼 */
.btn-xs {
    padding: 0.15rem 0.4rem;
    font-size: 0.72rem;
    border-radius: 0.25rem;
}

/* 카드 호버 */
.card { transition: box-shadow 0.15s; }
.card:hover { box-shadow: 0 2px 12px rgba(0,0,0,0.08); }

/* ── 글로벌 로딩 오버레이 ── */
#globalLoadingBar {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(15, 15, 25, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    pointer-events: all;
    user-select: none;
}
#globalLoadingBar.loading {
    display: flex;
    animation: overlayFadeIn 0.18s ease;
}
@keyframes overlayFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* 로딩 카드 */
.loading-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
    background: #ffffff;
    border-radius: 1.25rem;
    padding: 2.2rem 3rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35), 0 4px 16px rgba(0, 0, 0, 0.15);
}

/* 링 스피너 */
.loading-spinner {
    position: relative;
    width: 52px;
    height: 52px;
}
.spinner-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 3px solid transparent;
    animation: spinnerRing 1.1s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}
.spinner-ring:nth-child(1) {
    border-top-color: #0d6efd;
    animation-delay: -0.3s;
}
.spinner-ring:nth-child(2) {
    border-top-color: #6ea8fe;
    animation-delay: -0.15s;
    inset: 8px;
}
.spinner-ring:nth-child(3) {
    border-top-color: #cfe2ff;
    inset: 16px;
}
@keyframes spinnerRing {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 로딩 텍스트 */
.loading-text {
    margin: 0;
    font-size: 0.875rem;
    font-weight: 600;
    color: #495057;
    letter-spacing: 0.02em;
}

/* 스크롤바 */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: #f1f1f1; }
::-webkit-scrollbar-thumb { background: #ccc; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #aaa; }

