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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: #ffffff;
    color: #1a1e24;
    line-height: 1.5;
    scroll-behavior: smooth;
}

img {
    max-width: 100%;
    display: block;
}

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

ul,
ol {
    list-style: none;
}

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

/* ========== TYPOGRAPHY ========== */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 {
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

h2 {
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    border-left: 4px solid #e11d48;
    padding-left: 1rem;
}

h3 {
    font-size: 1.3rem;
    margin: 1.2rem 0 0.75rem;
}

/* ========== HEADER & NAV (with scroll effect) ========== */
.site-header {
    position: sticky;
    top: 0;
    background: #ffffff;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    transition: background 0.3s ease, box-shadow 0.3s ease;
    border-bottom: 1px solid #eef2f6;
}

.site-header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border-bottom-color: rgba(0, 0, 0, 0.05);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    flex-wrap: wrap;
}

.logo a {
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, #1e293b, #e11d48);
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    letter-spacing: -0.02em;
}

.nav-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    font-weight: 500;
    color: #2d3a48;
    transition: 0.2s;
}

.nav-menu a:hover,
.nav-menu a.active-nav {
    color: #e11d48;
}

.hamburger {
    display: none;
    font-size: 1.8rem;
    cursor: pointer;
    background: none;
    border: none;
    color: #1e293b;
}

/* ========== BREADCRUMB ========== */
.breadcrumb {
    background: #f9fafb;
    padding: 0.75rem 0;
    margin-top: 0.5rem;
    border-radius: 40px;
    margin-bottom: 2rem;
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: #4b5563;
}

.breadcrumb li {
    display: inline-flex;
    align-items: center;
}

.breadcrumb li:not(:last-child)::after {
    content: "›";
    margin-left: 0.5rem;
    color: #9ca3af;
}

.breadcrumb a {
    color: #e11d48;
    font-weight: 500;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

/* ========== CARD STYLES ========== */
.card {
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.2, 0, 0, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02), 0 1px 2px rgba(0, 0, 0, 0.03);
    border: 1px solid #f0f2f5;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
}

.card-inner {
    display: flex;
    flex-direction: row;
    gap: 1rem;
}

.card-flex {
    display: flex;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -12px rgba(0, 0, 0, 0.1);
    border-color: #e2e8f0;
}

.card-img {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    flex: 0 0 30%;
}

.card-flex .card-img {
    flex: 0 0 40%;
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.card:hover .card-img img {
    transform: scale(1.03);
}

.card-content {
    padding: 1.25rem;
}

.card-category {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    color: #e11d48;
    margin-bottom: 0.5rem;
}

.card-title {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-desc {
    color: #4a5568;
    font-size: 0.85rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

.card-meta {
    font-size: 0.75rem;
    color: #718096;
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

/* ========== GRID LAYOUTS ========== */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.feature-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.two-columns {
    display: grid;
    grid-template-columns: 70% 28%;
    gap: 3rem;
    margin: 2rem 0 3rem;
}

.main-content {
    flex: 70%;
}

.sidebar {
    flex: 30%;
}

/* ========== SPECIAL COMPONENTS ========== */
.topic-card {
    background: #f8fafc;
    border-radius: 24px;
    padding: 1.25rem;
    text-align: center;
    transition: all 0.2s;
    border: 1px solid #eef2ff;
}

.topic-card:hover {
    background: #ffffff;
    border-color: #e11d48;
    transform: scale(1.02);
}

.topic-emoji {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.topic-card h4 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.topic-card p {
    font-size: 0.8rem;
    color: #5a6874;
}

.special-card {
    background: #fef2f2;
    border-radius: 24px;
    padding: 1.5rem;
    border-left: 5px solid #e11d48;
}

/* ========== AUTHOR PAGE STYLES ========== */
.author-profile {
    max-width: 900px;
    margin: 0 auto 3rem;
}

.profile-header {
    display: flex;
    gap: 2rem;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    background: #ffffff;
    border-radius: 32px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
    border: 1px solid #f0f2f5;
}

.profile-avatar {
    flex-shrink: 0;
    width: 160px;
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #e11d48;
}

.profile-info {
    flex: 1;
}

.profile-title {
    font-size: 1.1rem;
    color: #e11d48;
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.profile-bio-short {
    font-size: 1rem;
    color: #4b5563;
    margin-bottom: 1rem;
}

.profile-meta {
    display: flex;
    gap: 1.5rem;
    font-size: 0.85rem;
    color: #718096;
    border-top: 1px solid #eef2f6;
    padding-top: 1rem;
    margin-top: 0.5rem;
}

.author-details {
    background: #fefaf5;
    border-radius: 28px;
    padding: 2rem;
    margin-bottom: 3rem;
    border: 1px solid #feeed6;
}

.author-details p {
    font-size: 1rem;
    line-height: 1.7;
    color: #2d3a48;
    margin-bottom: 1rem;
}

.author-details blockquote {
    border-left: 4px solid #e11d48;
    padding-left: 1.2rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #4a5b6e;
    background: #fff7ef;
    padding: 0.75rem 1.2rem;
    border-radius: 16px;
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

/* ========== ARTICLE DETAIL STYLES ========== */
.article-header {
    margin-bottom: 1.5rem;
}

.article-subtitle {
    font-size: 1.2rem;
    color: #4b5563;
    font-weight: 400;
    margin-top: -0.5rem;
    margin-bottom: 1rem;
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    align-items: center;
    border-top: 1px solid #eef2f6;
    border-bottom: 1px solid #eef2f6;
    padding: 0.75rem 0;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    color: #5a6874;
}

.author-mini {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.author-mini img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.article-stats {
    display: flex;
    gap: 1rem;
}

.article-body {
    font-size: 0.985rem;
    line-height: 1.7;
    letter-spacing: 0.2px;
    color: #171717;
    margin-bottom: 2rem;
}

.article-body img {
    margin: 0 auto;
}

.article-body p {
    margin-bottom: 1.25rem;
}

.article-body blockquote {
    border-left: 4px solid #e11d48;
    padding-left: 1.2rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #2d3a48;
    background: #fef9f5;
    padding: 0.75rem 1.2rem;
    border-radius: 16px;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.tag {
    background: #f1f5f9;
    padding: 0.25rem 1rem;
    border-radius: 40px;
    font-size: 0.75rem;
    font-weight: 500;
    color: #1e293b;
}

.author-card {
    background: #f8fafc;
    border-radius: 24px;
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    margin: 2rem 0;
}

.author-card img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
}

.author-card h4 {
    margin-bottom: 0.25rem;
}

.share-section {
    margin: 1.5rem 0;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
    border-top: 1px solid #eef2f6;
    padding-top: 1.5rem;
}

.share-btn {
    background: #f1f5f9;
    border: none;
    padding: 0.5rem 1.2rem;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 500;
    transition: 0.2s;
}

.share-btn:hover {
    background: #e11d48;
    color: white;
}

.comments-section {
    margin: 2rem 0;
}

.comment {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #edf2f7;
}

.comment-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #e2e8f0;
    flex-shrink: 0;
    overflow: hidden;
}

.comment-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.comment-content p {
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.comment-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    font-family: inherit;
    margin-bottom: 0.75rem;
}

.comment-form button {
    background: #e11d48;
    color: white;
    border: none;
    padding: 0.5rem 1.5rem;
    border-radius: 40px;
    cursor: pointer;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 1rem;
}

.related-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #f0f2f5;
    transition: 0.2s;
}

.related-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 15px -8px rgba(0, 0, 0, 0.1);
}

.related-card img {
    aspect-ratio: 4 / 3;
    object-fit: cover;
    width: 100%;
}

.related-card .card-content {
    padding: 0.75rem;
}

.related-card h4 {
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ========== SIDEBAR COMPONENTS ========== */
.sidebar-card {
    background: #ffffff;
    border-radius: 24px;
    border: 1px solid #f0f2f5;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.author-info {
    text-align: center;
}

.author-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 1rem;
    border: 3px solid #e11d48;
}

.author-name {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.author-bio {
    font-size: 0.85rem;
    color: #4b5563;
    line-height: 1.4;
}

.sidebar-list {
    margin-top: 1rem;
}

.sidebar-list li {
    margin-bottom: 1rem;
    border-bottom: 1px solid #f0f2f5;
    padding-bottom: 0.75rem;
}

.sidebar-list li:last-child {
    border-bottom: none;
}

.sidebar-list a {
    font-weight: 500;
    display: block;
}

.sidebar-list a:hover {
    color: #e11d48;
}

.sidebar-date {
    font-size: 0.7rem;
    color: #8a99aa;
    margin-top: 0.25rem;
}

.category-badge {
    display: inline-block;
    background: #f1f5f9;
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    font-size: 0.7rem;
    margin: 0.25rem 0.25rem 0 0;
}

.category-badge a {
    color: #1f2937;
}

.category-badge a:hover {
    color: #e11d48;
}

/* ========== PAGINATION ========== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 3rem 0 2rem;
    flex-wrap: wrap;
}

.page-item {
    padding: 0.5rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 40px;
    transition: 0.2s;
    background: white;
    font-weight: 500;
    display: inline-block;
}

.page-item.active {
    background: #e11d48;
    color: white;
    border-color: #e11d48;
}

.page-item:hover:not(.active) {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

/* ========== TOP BANNER ========== */
.top-banner {
    background: #fef9e8;
    border-bottom: 1px solid #f0e5d2;
    padding: 10px 0;
    font-size: 0.9rem;
    text-align: center;
    color: #b45309;
    font-weight: 500;
}

.top-banner a {
    text-decoration: underline;
    color: #b45309;
}

/* ========== BUTTONS ========== */
.btn-outline {
    border: 1px solid #e11d48;
    padding: 0.5rem 1.2rem;
    border-radius: 40px;
    display: inline-block;
    font-weight: 500;
    transition: 0.2s;
    background: white;
}

.btn-outline:hover {
    background: #e11d48;
    color: white;
}

/* ========== FOOTER ========== */
.site-footer {
    background: #0f172a;
    color: #cbd5e6;
    padding: 3rem 0 2rem;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.footer-col h3 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.footer-col p,
.footer-col ul li {
    margin-bottom: 0.5rem;
}

.footer-col ul li a:hover {
    color: #e11d48;
}

.copyright {
    text-align: center;
    font-size: 0.8rem;
    color: #cbd5e6;
}

/* ========== BACK TO TOP ========== */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: #e11d48;
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: 0.2s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 99;
    border: none;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {

    .grid-3,
    .grid-4,
    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .two-columns {
        flex-direction: column;
    }

    .main-content,
    .sidebar {
        flex: 100%;
    }

    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .two-columns {
        grid-template-columns: 100%;
    }

    .card-inner{
        display: block;
    }

    .card-flex {
        display: block;
    }

    .article-title {
        font-size: 1.4rem;
    }

    .article-meta {
        gap: 0.5rem;
        font-size: 0.75rem;
    }

    .site-header {
        position: relative;
    }

    .hamburger {
        display: block;
    }

    .nav-menu {
        display: none;
        width: 100%;
        flex-direction: column;
        gap: 1rem;
        padding: 1rem 0;
        background: white;
    }

    .nav-menu.active {
        display: flex;
    }

    h1 {
        font-size: 1.6rem;
    }

    .article-subtitle {
        font-size: 1rem;
    }

    .grid-3,
    .grid-4,
    .feature-grid,
    .articles-grid,
    .related-grid {
        grid-template-columns: 1fr;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
    }

    .profile-meta {
        justify-content: center;
    }

    .author-card {
        flex-direction: column;
        text-align: center;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .container {
        padding: 0 20px;
    }
}