@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --primary-color: #0284C7;
    --primary-hover: #0369A1;
    --bg-darker: #0B1325;
    --bg-dark: #0F172A;
    --bg-white: #FFFFFF;
    --bg-slate: #F8FAFC;
    --text-main: #0F172A;
    --text-white: #FFFFFF;
    --text-muted: #64748B;
    --text-muted-dark: #94A3B8;
    --border-color: #E2E8F0;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: clip;
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    background-color: var(--bg-white);
    line-height: 1.6;
}

#header-placeholder {
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 9999;
    width: 100%;
    background-color: var(--bg-darker);
}

.site-header {
    box-shadow: none !important;
    background-color: var(--bg-darker);
    color: var(--text-white);
}

#header-placeholder::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    pointer-events: none;
}

* {
    box-sizing: border-box;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-hover);
}

.blog-container, .post-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 60px 24px;
}

.blog-container h1 {
    font-size: 42px;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 40px;
    text-align: center;
    letter-spacing: -1px;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

.blog-card-link {
    display: block;
    color: inherit;
}

.blog-card {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

.blog-card img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
}

.blog-card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 14px;
    font-weight: 500;
}

.card-meta .date {
    color: var(--text-muted);
}

.card-meta .category {
    color: var(--primary-color);
    font-weight: 600;
}

.blog-card-content h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 12px 0;
    line-height: 1.4;
}

.blog-card-content p {
    font-size: 15px;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.6;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-article-btn {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 24px;
    background-color: var(--bg-slate);
    color: var(--text-main);
    font-weight: 600;
    font-size: 14px;
    border-radius: 50px;
    text-align: center;
    transition: var(--transition);
    align-self: flex-start;
    border: 1px solid var(--border-color);
}

.blog-card:hover .read-article-btn,
.read-article-btn:hover {
    background-color: var(--primary-color);
    color: var(--text-white);
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(2, 132, 199, 0.2);
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
    margin-bottom: 60px;
}

.btn-pagination {
    display: inline-block;
    padding: 12px 24px;
    background-color: var(--bg-white);
    color: var(--text-main);
    border: 2px solid var(--border-color);
    border-radius: 50px;
    font-weight: 600;
    font-size: 15px;
    transition: var(--transition);
}

.btn-pagination:hover {
    background-color: var(--primary-color);
    color: var(--text-white);
    border-color: var(--primary-color);
}

.post-container {
    max-width: 800px;
}

.post-subheader {
    margin-bottom: 20px;
    display: block;
}

.post-subheader-link {
    color: var(--primary-color);
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

.back-arrow {
    font-size: 20px;
    display: flex;
    align-items: center;
    line-height: 0;
    transition: var(--transition);
}

@media (min-width: 768px) {
    .back-arrow {
        position: relative;
        top: -2px;
    }
}

.post-subheader-link:hover {
    color: var(--primary-hover);
    transform: translateX(4px);
}

.post-title {
    font-size: 48px;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.2;
    margin: 0 0 20px 0;
    letter-spacing: -1px;
}

.post-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 30px;
}

.post-date {
    font-size: 16px;
    color: var(--text-muted);
    font-weight: 500;
}

.share-btn {
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--bg-slate);
    transition: var(--transition);
}

.share-btn:hover {
    background-color: var(--primary-color);
    color: var(--text-white);
    transform: scale(1.05);
}

.post-featured-image {
    width: 100%;
    height: auto;
    max-height: 500px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 40px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.post-content {
    font-size: 18px;
    color: var(--text-main);
    line-height: 1.8;
}

.post-content h2, .post-content h3, .post-content h4 {
    color: var(--text-main);
    margin-top: 40px;
    margin-bottom: 15px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.post-content h2 { font-size: 32px; }
.post-content h3 { font-size: 26px; }
.post-content h4 { font-size: 22px; }

.post-content p {
    margin-bottom: 25px;
}

.post-content ul, .post-content ol {
    margin-bottom: 25px;
    padding-left: 20px;
}

.post-content li {
    margin-bottom: 10px;
}

.post-content blockquote {
    border-left: 4px solid var(--primary-color);
    background-color: var(--bg-slate);
    margin: 30px 0;
    padding: 20px 25px;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: var(--text-main);
}

.post-footer {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid var(--border-color);
}

.post-footer h3, .recommended-posts h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 30px;
}

.popular-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.popular-card {
    display: flex;
    align-items: center;
    background-color: var(--bg-slate);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    gap: 15px;
    padding: 10px;
}

.popular-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(2, 132, 199, 0.15);
    border-color: var(--primary-color);
}

.popular-img-wrapper {
    flex-shrink: 0;
    width: 140px;
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    overflow: hidden;
}

.popular-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.popular-text {
    flex-grow: 1;
}

.popular-text h4 {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.active-link {
    color: var(--text-white) !important;
}

.desktop-nav a.active-link::after {
    width: 100% !important;
}

.category-filters {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-bottom: 40px;
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 15px 5px;
}

.category-filters::-webkit-scrollbar {
    display: none;
}

.category-pill {
    display: inline-block;
    padding: 8px 20px;
    background-color: var(--bg-white);
    color: var(--text-main);
    border: 1.5px solid var(--border-color);
    border-radius: 50px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.category-pill:hover, .category-pill.active-pill {
    background-color: var(--primary-color);
    color: var(--text-white);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.2);
}

@media (max-width: 1024px) {
    .blog-grid {
        grid-template-columns: 1fr;
    }
    
    .blog-container h1 {
        font-size: 36px;
    }
    
    .post-title {
        font-size: 34px;
    }
}

@media (max-width: 768px) {
    .blog-container, .post-container {
        padding: 40px 20px;
    }
    
    .post-content {
        font-size: 16px;
    }
    
    .post-content h2 { font-size: 26px; }
    .post-content h3 { font-size: 22px; }
    
    .category-filters {
        justify-content: center;
        padding: 15px 5px;
        gap: 8px;
    }

    .category-pill {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    .popular-grid {
        grid-template-columns: 1fr;
    }
    
    .popular-img-wrapper {
        width: 110px;
    }
    
    .popular-text h4 {
        font-size: 14px;
    }
}

.btn-full-width:hover,
.contact-btn:hover,
.hero-btn:hover,
.btn-pill:hover,
.sb-about-pill-btn:hover,
.btn-green:hover {
    color: var(--text-white) !important;
    background-color: var(--primary-hover);
}

.btn-dark {
    background-color: var(--bg-darker);
    color: var(--text-white);
}

.btn-dark:hover {
    background-color: var(--primary-color);
    color: var(--text-white);
}

.btn-light {
    background-color: var(--bg-white);
    color: var(--text-main);
}

.btn-light:hover {
    background-color: var(--bg-white);
    color: var(--text-main);
}
