/* 로컬 폰트 로드 */
@font-face {
    font-family: 'BitcountSingle';
    src: url('./fonts/BitcountSingle-ExtraLight.ttf') format('truetype');
    font-weight: 200;
    font-style: normal;
    font-display: swap;
}

/* 기본 리셋 */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: #1a1a1a;
    background-color: #ffffff;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 컨테이너 */
.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 헤더 */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid #f0f0f0;
    padding: 3rem 0;
    position: static;
}

.header-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
}

.site-info {
    flex: 1;
}

.site-title {
    font-family: 'BitcountSingle', monospace;
    font-size: 3.5rem;
    font-weight: 200;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
    letter-spacing: 0.05em;
}

.site-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.site-title a:hover {
    color: #667eea;
}

.site-description {
    color: #6b7280;
    font-size: 1.125rem;
    font-weight: 400;
}

/* 메인 콘텐츠 */
.main-content {
    flex: 1;
    padding: 4rem 0;
    background-color: #ffffff;
}

.content-wrapper {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* 타임라인 */
.timeline-container {
    position: relative;
    padding-left: 3rem;
}

.timeline-line {
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 1px;
    background: #d1d5db;
}



/* 타임라인 아이템 */
.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.timeline-item.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.timeline-marker {
    position: absolute;
    left: -3rem;
    top: 1.5rem;
    z-index: 10;
}

.marker-dot {
    width: 6px;
    height: 6px;
    background: #9ca3af;
    border-radius: 50%;
    transition: all 0.3s ease;
    margin-left: 12px;
}

.timeline-item:hover .marker-dot {
    transform: scale(1.2);
    background: #667eea;
}

/* 콘텐츠 카드 */
.timeline-content {
    margin-left: 1rem;
}

.content-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 2rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}



.card-header {
    margin-bottom: 1rem;
}

.post-date {
    font-family: 'BitcountSingle', monospace;
    color: #000000;
    font-size: 0.8rem;
    font-weight: 200;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.card-body {
    color: #374151;
    line-height: 1.7;
}

.post-content {
    font-size: 1rem;
}

.post-content p {
    margin-bottom: 1.25rem;
}

.post-content p:last-child {
    margin-bottom: 0;
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
    color: #1a1a1a;
    font-weight: 600;
    margin: 1.5rem 0 1rem 0;
    line-height: 1.3;
}

.post-content h1 { font-size: 1.75rem; }
.post-content h2 { font-size: 1.5rem; }
.post-content h3 { font-size: 1.25rem; }

.post-content code {
    background: #f8f9fa;
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.875rem;
    color: #667eea;
    border: 1px solid #f0f0f0;
}

.post-content pre {
    background: #f8f9fa;
    color: #1a1a1a;
    padding: 1.5rem;
    border-radius: 8px;
    overflow-x: auto;
    margin: 1.5rem 0;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    border: 1px solid #f0f0f0;
}

.post-content pre code {
    background: none;
    padding: 0;
    color: inherit;
    border: none;
}

.post-content blockquote {
    border-left: 4px solid #e5e7eb;
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    color: #6b7280;
    font-style: italic;
    background: #f9fafb;
    padding: 1rem 1.5rem;
    border-radius: 0 8px 8px 0;
}

.post-content ul,
.post-content ol {
    margin: 1rem 0;
    padding-left: 1.5rem;
}

.post-content li {
    margin-bottom: 0.5rem;
}

.post-content a {
    color: #667eea;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: all 0.2s ease;
}

.post-content a:hover {
    border-bottom-color: #667eea;
}

/* 타임라인 끝 */
.timeline-end {
    position: relative;
    text-align: center;
    margin-top: 2rem;
}

.end-marker {
    position: absolute;
    left: -3rem;
    top: 0.5rem;
}

.end-dot {
    width: 6px;
    height: 6px;
    background: #9ca3af;
    border-radius: 50%;
    margin-left: 12px;
}

.end-message {
    margin-left: 1rem;
    padding: 1.5rem;
    color: #9ca3af;
    font-style: italic;
    background: #f9fafb;
    border-radius: 8px;
}

/* 단일 포스트 페이지 */
.single-post {
    background: #ffffff;
    border-radius: 12px;
    padding: 3rem;
    margin-bottom: 2rem;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

.single-post.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.single-post .post-header {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    text-align: center;
}



.post-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: #9ca3af;
    font-size: 0.875rem;
}

.single-post .post-body {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #374151;
}

/* 네비게이션 */
.post-navigation {
    margin-top: 2rem;
}

.nav-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.nav-back:hover {
    background: #f0f0f0;
    transform: translateX(-2px);
}

/* 푸터 */
.site-footer {
    background: #ffffff;
    border-top: 1px solid #f0f0f0;
    padding: 3rem 0;
    margin-top: auto;
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 2rem;
    text-align: center;
    color: #9ca3af;
    font-size: 0.875rem;
    font-family: 'BitcountSingle', monospace;
    font-weight: 200;
}



/* 다크 모드 지원 */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #1a1a1a;
        color: #e5e5e5;
    }

    .site-header {
        background: #1a1a1a;
        border-bottom-color: #2d2d2d;
    }

    .main-content {
        background-color: #1a1a1a;
    }

    .timeline-line {
        background: #404040;
    }

    .site-title {
        color: #ffffff;
        font-family: 'BitcountSingle', monospace;
    }

    .site-description,
    .post-date,
    .post-meta,
    .end-message,
    .footer-content {
        color: #a1a1aa;
    }

    .content-card,
    .single-post,
    .end-message {
        background: #2d2d2d;
    }



    .marker-dot,
    .end-dot {
        background: #6b7280;
    }

    .timeline-item:hover .marker-dot {
        background: #667eea;
    }

    .post-content {
        color: #d1d5db;
    }

    .post-content h1,
    .post-content h2,
    .post-content h3,
    .post-content h4,
    .post-content h5,
    .post-content h6 {
        color: #ffffff;
    }

    .post-content code {
        background: #404040;
        color: #8b5cf6;
        border-color: #525252;
    }

    .post-content pre {
        background: #404040;
        border-color: #525252;
    }

    .post-content blockquote {
        color: #9ca3af;
        background: #2d2d2d;
        border-left-color: #525252;
    }

    .site-footer {
        background: #1a1a1a;
        border-top-color: #2d2d2d;
    }

    .nav-back {
        background: #2d2d2d;
        border-color: #404040;
    }

    .nav-back:hover {
        background: #404040;
    }
}