/* 크립토 카페 - 2025 한국 최고의 암호화폐 커뮤니티 */

/* 기본 설정 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* 네이버 그린 컬러 시스템 */
    --naver-green: #03c75a;
    --naver-green-dark: #02b350;
    --naver-green-light: #e8f5ee;
    
    /* 배경색 */
    --bg-main: #f2f4f7;
    --bg-white: #ffffff;
    --bg-gray: #fafafa;
    
    /* 텍스트 컬러 */
    --text-dark: #1a1a1a;
    --text-base: #333333;
    --text-gray: #666666;
    --text-light: #999999;
    --text-lighter: #cccccc;
    
    /* 테두리 */
    --border-color: #e5e5e5;
    --border-dark: #d1d1d1;
    
    /* 상태 색상 */
    --hover-bg: #f8f9fa;
    --notice-yellow: #fff8e1;
    --hot-red: #ff4444;
    --success-green: #28a745;
    --warning-orange: #ff9800;
    
    /* 2025 타이포그래피 시스템 */
    --font-base-size: 16px;
    --font-scale-ratio: 1.25;
    
    /* 폰트 크기 (rem 기반) */
    --font-xs: 0.75rem;      /* 12px */
    --font-sm: 0.875rem;     /* 14px */
    --font-base: 1rem;       /* 16px */
    --font-md: 1.125rem;     /* 18px */
    --font-lg: 1.25rem;      /* 20px */
    --font-xl: 1.5rem;       /* 24px */
    --font-2xl: 2rem;        /* 32px */
    
    /* 줄간격 (한글 최적화) */
    --line-height-tight: 1.3;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.7;
    --line-height-loose: 1.9;
    
    /* 자간 */
    --letter-spacing-tight: -0.02em;
    --letter-spacing-normal: 0em;
    --letter-spacing-wide: 0.03em;
}

/* 2025 타이포그래피: Pretendard Variable */
body {
    font-family: "Pretendard Variable", -apple-system, BlinkMacSystemFont, system-ui, Roboto, "Helvetica Neue", "Segoe UI", "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", sans-serif;
    font-size: var(--font-base);
    background-color: var(--bg-main);
    color: var(--text-base);
    line-height: var(--line-height-relaxed);
    letter-spacing: var(--letter-spacing-normal);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    word-break: keep-all;
    overflow-wrap: break-word;
}

/* 2025 타이포그래피 - 제목 시스템 */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: var(--line-height-tight);
    letter-spacing: var(--letter-spacing-tight);
    color: var(--text-dark);
    margin-bottom: 0.5em;
}

h1 { font-size: var(--font-2xl); }
h2 { font-size: var(--font-xl); }
h3 { font-size: var(--font-lg); }
h4 { font-size: var(--font-md); }
h5 { font-size: var(--font-base); }
h6 { font-size: var(--font-sm); }

p {
    margin-bottom: 1em;
}

/* 링크 스타일 */
a {
    color: var(--naver-green);
    text-decoration: none;
    transition: all 0.2s ease;
}

a:hover {
    color: var(--naver-green-dark);
}

/* 헤더 - 네이버 그린 */
.site-header {
    background: linear-gradient(135deg, var(--naver-green) 0%, var(--naver-green-dark) 100%);
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: white;
    font-size: var(--font-xl);
    font-weight: 800;
    letter-spacing: var(--letter-spacing-tight);
}

.logo-icon {
    font-size: 2rem;
    margin-right: 0.6rem;
    animation: pulse 2s ease-in-out infinite;
}

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

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.main-nav a {
    color: white;
    text-decoration: none;
    font-size: var(--font-sm);
    font-weight: 600;
    transition: all 0.2s ease;
    padding: 0.5rem 1rem;
    border-radius: 20px;
}

.main-nav a:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

/* 네이버 카페 스타일 3단 레이아웃 */
.cafe-layout {
    max-width: 1400px;
    margin: 20px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 200px 1fr 240px;
    gap: 20px;
    min-height: calc(100vh - 200px);
}

/* 좌측 사이드바 */
.sidebar-left {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 15px;
    height: fit-content;
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
}

.sidebar-section {
    margin-bottom: 20px;
}

.sidebar-section:last-child {
    margin-bottom: 0;
}

.sidebar-title {
    font-size: var(--font-sm);
    font-weight: 800;
    color: var(--text-dark);
    padding-bottom: 12px;
    margin-bottom: 14px;
    border-bottom: 2px solid var(--naver-green);
    letter-spacing: var(--letter-spacing-tight);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* 카페 메뉴 */
.cafe-menu ul {
    list-style: none;
}

.menu-item {
    margin-bottom: 4px;
}

.menu-link {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    text-decoration: none;
    color: var(--text-base);
    border-radius: 6px;
    transition: all 0.2s ease;
    font-size: var(--font-sm);
    font-weight: 500;
}

.menu-link:hover {
    background: var(--naver-green-light);
    color: var(--naver-green-dark);
    transform: translateX(2px);
}

.menu-icon {
    font-size: 1.2rem;
    margin-right: 10px;
    width: 22px;
    text-align: center;
}

.menu-text {
    font-size: var(--font-sm);
    line-height: var(--line-height-normal);
}

/* 인기글/최신글 */
.popular-posts, .recent-posts {
    font-size: var(--font-xs);
}

.popular-item, .recent-item {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.popular-item:last-child, .recent-item:last-child {
    border-bottom: none;
}

.popular-item a, .recent-item a {
    color: var(--text-dark);
    text-decoration: none;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.popular-badge {
    background: var(--hot-red);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.7rem;
    margin-right: 5px;
    font-weight: 700;
}

.popular-date, .recent-date {
    color: var(--text-light);
    font-size: 0.75rem;
    margin-left: 5px;
}

/* 우측 사이드바 */
.sidebar-right {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 15px;
    height: fit-content;
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
}

/* 공지사항 박스 */
.notice-box {
    background: var(--notice-yellow);
    border: 1px solid #ffd54f;
    border-radius: 6px;
    padding: 12px;
}

.notice-item {
    margin-bottom: 8px;
    font-size: 0.85rem;
}

.notice-item:last-child {
    margin-bottom: 0;
}

.notice-badge {
    background: var(--hot-red);
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.7rem;
    margin-right: 5px;
    font-weight: 700;
}

/* 관리자 박스 */
.manager-profile {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.manager-avatar {
    width: 50px;
    height: 50px;
    background: var(--hover-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-right: 10px;
}

.manager-name {
    font-weight: 700;
    color: var(--text-dark);
}

.manager-role {
    font-size: 0.8rem;
    color: var(--text-gray);
}

.manager-desc p {
    font-size: 0.85rem;
    margin: 5px 0;
    color: var(--text-gray);
}

/* 실시간 가격 위젯 */
.price-widget {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: none;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.price-widget .sidebar-title {
    color: white;
    border-bottom-color: rgba(255,255,255,0.2);
}

.price-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.price-item {
    background: rgba(255,255,255,0.08);
    padding: 14px;
    border-radius: 10px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.1);
}

.price-item:hover {
    background: rgba(255,255,255,0.12);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.price-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.price-name {
    font-size: var(--font-sm);
    font-weight: 700;
    color: white;
}

.price-change {
    font-size: var(--font-xs);
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
}

.price-change.up {
    background: rgba(255, 82, 82, 0.2);
    color: #ff5252;
}

.price-change.down {
    background: rgba(82, 82, 255, 0.2);
    color: #5252ff;
}

.price-value {
    font-size: var(--font-md);
    font-weight: 800;
    color: white;
    margin-bottom: 4px;
    font-family: 'SF Mono', 'Consolas', monospace;
}

.price-usd {
    font-size: var(--font-xs);
    color: rgba(255,255,255,0.6);
    font-family: 'SF Mono', 'Consolas', monospace;
}

.price-update {
    text-align: center;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.price-update small {
    color: rgba(255,255,255,0.5);
    font-size: var(--font-xs);
}

/* 통계 박스 */
.stat-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
    font-size: var(--font-sm);
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-label {
    color: var(--text-gray);
    font-weight: 500;
}

.stat-value {
    font-weight: 800;
    color: var(--naver-green);
    font-size: var(--font-md);
}

/* 도움말 박스 */
.help-content {
    font-size: var(--font-sm);
    color: var(--text-gray);
    line-height: var(--line-height-relaxed);
}

.help-link {
    display: inline-block;
    margin-top: 8px;
    color: var(--naver-green);
    text-decoration: none;
    font-weight: 600;
}

.help-link:hover {
    text-decoration: underline;
}

/* 중앙 콘텐츠 */
.content-main {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
}

/* 게시판 헤더 */
.board-header {
    border-bottom: 2px solid var(--naver-green);
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.board-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 5px;
}

.board-description {
    font-size: 0.9rem;
    color: var(--text-gray);
}

/* 게시판 헤더 (기존) */
.board-header {
    padding-bottom: 20px;
    border-bottom: 2px solid var(--naver-green);
    margin-bottom: 20px;
}

.board-title {
    font-size: 1.5rem;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.board-description {
    color: var(--text-gray);
    font-size: 0.95rem;
}

.board-stats {
    margin-top: 10px;
    display: flex;
    gap: 15px;
}

.board-stats .stat {
    font-size: 0.85rem;
    color: var(--text-gray);
}

/* 게시판 테이블 */
.board-table {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.board-table-header {
    background: linear-gradient(to bottom, #fafafa, #f5f5f5);
    display: grid;
    grid-template-columns: 1fr 120px 120px 100px;
    padding: 14px 18px;
    font-size: var(--font-sm);
    font-weight: 700;
    color: var(--text-base);
    border-bottom: 2px solid var(--border-dark);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-dark);
    border-bottom: 2px solid var(--border-dark);
}

.board-row {
    display: grid;
    grid-template-columns: 1fr 120px 120px 100px;
    padding: 18px 18px;
    border-bottom: 1px solid var(--border-color);
    align-items: center;
    transition: all 0.2s ease;
    min-height: 56px;
}

.board-row:hover {
    background: var(--naver-green-light);
    transform: translateX(2px);
}

.board-row:last-child {
    border-bottom: none;
}

.col-title {
    display: flex;
    align-items: center;
}

.post-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-base);
    font-size: var(--font-base);
    font-weight: 500;
    line-height: var(--line-height-normal);
}

.post-link:hover {
    color: var(--naver-green-dark);
    font-weight: 600;
}

.post-badge {
    background: var(--naver-green);
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: var(--font-xs);
    margin-right: 10px;
    font-weight: 700;
    letter-spacing: var(--letter-spacing-wide);
}

.col-author, .col-date, .col-coin {
    font-size: var(--font-sm);
    color: var(--text-gray);
}

.author-badge {
    margin-left: 3px;
}

.coin-badge {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 700;
}

.coin-badge.coin-bitcoin {
    background: #f7931a;
    color: white;
}

.coin-badge.coin-ethereum {
    background: #627eea;
    color: white;
}

/* 빈 게시판 */
.board-empty {
    text-align: center;
    padding: 60px 20px;
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 20px;
}

.empty-text {
    font-size: 1.2rem;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.empty-subtext {
    color: var(--text-gray);
}

/* 거래소 비교 섹션 */
.exchange-box {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 2px solid var(--naver-green);
    border-radius: 10px;
    padding: 16px;
}

.exchange-content {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.exchange-item {
    background: white;
    padding: 12px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.exchange-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.exchange-top {
    border: 2px solid var(--naver-green);
}

.exchange-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.exchange-name {
    font-size: var(--font-sm);
    font-weight: 700;
    color: var(--text-dark);
}

.exchange-share {
    font-size: var(--font-md);
    font-weight: 800;
    color: var(--naver-green);
}

.exchange-bar {
    background: #e9ecef;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 8px;
}

.exchange-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 1s ease;
    box-shadow: 0 0 10px rgba(3, 199, 90, 0.3);
}

.exchange-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.exchange-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: var(--font-xs);
    font-weight: 700;
}

.exchange-badge.best {
    background: var(--naver-green);
    color: white;
}

.exchange-badge.second {
    background: #4a90e2;
    color: white;
}

.exchange-detail {
    font-size: var(--font-xs);
    color: var(--text-gray);
}

.exchange-note {
    text-align: center;
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

.exchange-note small {
    color: var(--text-light);
    font-size: var(--font-xs);
}

/* 푸터 */
.site-footer {
    background: var(--text-dark);
    color: white;
    padding: 30px 20px 20px;
    margin-top: 40px;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 20px;
}

.footer-section h3, .footer-section h4 {
    margin-bottom: 10px;
    font-size: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section a {
    color: #cbd5e0;
    text-decoration: none;
    font-size: 0.9rem;
}

.footer-section a:hover {
    color: white;
}

.footer-disclaimer {
    background: rgba(255, 152, 0, 0.1);
    border: 2px solid #ff9800;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    text-align: center;
    font-size: 0.95rem;
    line-height: 1.6;
}

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.85rem;
    color: #a0aec0;
}

/* 모바일 반응형 */
@media (max-width: 1024px) {
    .cafe-layout {
        grid-template-columns: 1fr;
        grid-template-areas: 
            "main"
            "left"
            "right";
    }
    
    .content-main {
        grid-area: main;
    }
    
    .sidebar-left {
        grid-area: left;
        position: static;
    }
    
    .sidebar-right {
        grid-area: right;
        position: static;
    }
    
    .board-table-header,
    .board-row {
        grid-template-columns: 1fr 80px;
    }
    
    .col-author, .col-coin {
        display: none;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 10px;
    }
    
    .main-nav ul {
        gap: 1rem;
    }
}
