/* Apple-inspired Minimalist Design */

:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f5f5f7;
    --text-primary: #1d1d1f;
    --text-secondary: #86868b;
    --accent-blue: #0066cc;
    --accent-hover: #004499;
    --border-color: #d2d2d7;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 48px;
}

.nav-logo {
    font-size: 19px;
    font-weight: 600;
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}

.nav-logo:hover {
    color: var(--accent-blue);
}

.nav-links {
    display: flex;
    gap: 32px;
}

.nav-link {
    font-size: 12px;
    color: var(--text-primary);
    text-decoration: none;
    opacity: 0.8;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    opacity: 1;
    color: var(--accent-blue);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -16px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-blue);
    border-radius: 2px;
}

/* Hero Section */
.hero {
    padding: 160px 0 100px;
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
    text-align: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 24px;
}

.hero-title {
    font-size: clamp(24px, 8vw, 56px);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: clamp(14px, 4vw, 24px);
    font-weight: 400;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Section Titles */
.section-title {
    font-size: clamp(24px, 6vw, 40px);
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 48px;
    text-align: center;
}

/* Posts Grid */
.featured {
    padding: 80px 0;
}

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 32px;
}

.post-card {
    background: var(--bg-primary);
    border-radius: var(--radius-lg);
    padding: 32px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid transparent;
    text-decoration: none;
    color: inherit;
    display: block;
}

.post-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-color);
}

.post-date {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    font-weight: 500;
}

.post-title {
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 12px;
    line-height: 1.4;
}

.post-excerpt {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-tags {
    display: flex;
    gap: 8px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.post-tag {
    font-size: 11px;
    padding: 4px 12px;
    background: var(--bg-secondary);
    border-radius: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Post Content Page */
.post-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 120px 24px 80px;
}

.post-header {
    margin-bottom: 48px;
    text-align: center;
}

.post-meta {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.post-body {
    font-size: 17px;
    line-height: 1.8;
    color: var(--text-primary);
}

.post-body h1,
.post-body h2,
.post-body h3 {
    font-weight: 600;
    letter-spacing: -0.01em;
    margin: 48px 0 24px;
}

.post-body h1 { font-size: 40px; }
.post-body h2 { font-size: 32px; }
.post-body h3 { font-size: 24px; }

.post-body p {
    margin-bottom: 24px;
}

.post-body code {
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 14px;
    background: var(--bg-secondary);
    padding: 2px 8px;
    border-radius: 4px;
}

.post-body pre {
    background: var(--bg-secondary);
    padding: 24px;
    border-radius: var(--radius-md);
    overflow-x: auto;
    margin: 32px 0;
}

.post-body pre code {
    background: none;
    padding: 0;
}

.post-body blockquote {
    border-left: 3px solid var(--accent-blue);
    padding-left: 24px;
    margin: 32px 0;
    color: var(--text-secondary);
    font-style: italic;
}

.post-body ul,
.post-body ol {
    margin: 24px 0;
    padding-left: 32px;
}

.post-body li {
    margin-bottom: 12px;
}

/* Footer */
.footer {
    background: var(--bg-secondary);
    padding: 48px 0;
    margin-top: 80px;
    border-top: 1px solid var(--border-color);
}

.footer-text {
    font-size: 12px;
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 8px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 24px;
    background: var(--accent-blue);
    color: white;
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: var(--accent-hover);
    transform: scale(1.02);
}

/* Responsive */
@media (max-width: 768px) {
    .posts-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-links {
        gap: 16px;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.post-card {
    animation: fadeIn 0.6s ease-out forwards;
}

.post-card:nth-child(2) { animation-delay: 0.1s; }
.post-card:nth-child(3) { animation-delay: 0.2s; }
.post-card:nth-child(4) { animation-delay: 0.3s; }
