@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #6366f1;
    --secondary: #a855f7;
    --dark: #0f172a;
    --light: #f8fafc;
    --card-bg: rgba(15, 23, 42, 0.9);
    --hover-bg: rgba(99, 102, 241, 0.1);
}

/* Base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
}

body {
    background: var(--dark);
    color: var(--light);
    min-height: 100vh;
    padding: 1rem;
}

/* Navigation styles */
.blog-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1000;
}

.nav-back {
    color: var(--light);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
}

.nav-back:hover {
    background: var(--hover-bg);
    transform: translateX(-5px);
}

/* Blog Container */
.blog-container {
    max-width: 1200px;
    margin: 80px auto 2rem;
    background: var(--card-bg);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(16px);
    padding: 2rem;
}

.blog-content {
    padding: 2rem;
}

.blog-content h1 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.blog-intro {
    text-align: center;
    color: #94a3b8;
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

/* Categories */
.blog-categories {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.category-btn {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: var(--light);
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-btn.active,
.category-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
}

/* Blog Grid */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.blog-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.blog-card:hover {
    transform: translateY(-5px);
    background: var(--hover-bg);
}

.blog-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-card:hover .blog-image img {
    transform: scale(1.1);
}

.category {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    background: rgba(99, 102, 241, 0.9);
    color: var(--light);
    font-size: 0.8rem;
}

.blog-info {
    padding: 1.5rem;
}

.blog-meta {
    display: flex;
    gap: 1rem;
    color: #94a3b8;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.blog-info h3 {
    margin-bottom: 1rem;
    line-height: 1.4;
}

.blog-info p {
    color: #94a3b8;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.read-more {
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.3s ease;
}

.read-more:hover {
    gap: 1rem;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 3rem 0;
}

.page-btn {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--light);
    text-decoration: none;
    transition: all 0.3s ease;
}

.page-btn.active,
.page-btn:hover {
    background: var(--primary);
}

/* Newsletter Section */
.newsletter-section {
    text-align: center;
    padding: 3rem 0 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.newsletter-form {
    display: flex;
    gap: 1rem;
    max-width: 500px;
    margin: 2rem auto 0;
}

.newsletter-form input {
    flex: 1;
    padding: 1rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--light);
}

.newsletter-form button {
    padding: 1rem 2rem;
    border-radius: 8px;
    background: linear-gradient(45deg, var(--primary), var(--secondary));
    color: var(--light);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.newsletter-form button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .blog-container {
        margin: 60px 1rem 1rem;
        padding: 1rem;
    }

    .blog-content {
        padding: 1rem;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }

    .newsletter-form {
        flex-direction: column;
        padding: 0 1rem;
    }
}
