/* ===== Base & Typography ===== */
body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    line-height: 1.7;
}

/* ===== Navbar depth ===== */
.navbar {
    box-shadow: 0 2px 20px rgba(0,0,0,0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* ===== Cards with depth ===== */
.card {
    border: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}
.card:hover {
    box-shadow: 0 10px 40px rgba(0,0,0,0.08), 0 4px 12px rgba(0,0,0,0.05);
}

/* Article cards */
.article-card {
    border: none;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: var(--bs-card-bg, #fff);
}
.article-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 60px rgba(0,0,0,0.1), 0 8px 20px rgba(0,0,0,0.06);
}
.article-card .card-img-top {
    height: 200px;
    object-fit: cover;
    transition: transform 0.4s ease;
}
.article-card:hover .card-img-top {
    transform: scale(1.03);
}
.article-card .card-body {
    padding: 1.25rem;
}

/* ===== Sidebar ===== */
.sidebar-categories {
    position: sticky;
    top: 1rem;
}
.category-link {
    transition: all 0.15s;
    border-radius: 8px;
}
.category-link:hover {
    background-color: rgba(13, 110, 253, 0.06);
    padding-left: 12px !important;
}

/* ===== Article detail ===== */
.article-detail {
    font-size: 1.05rem;
    line-height: 1.8;
}
.article-detail img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 1.5rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}
.article-detail h2 {
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}
.article-detail h3 {
    margin-top: 1.5rem;
    font-weight: 600;
}
.article-detail blockquote {
    border-left: 4px solid var(--bs-primary);
    padding: 1rem 1.25rem;
    margin: 1.5rem 0;
    background: rgba(13, 110, 253, 0.04);
    border-radius: 0 8px 8px 0;
    color: #555;
    font-style: italic;
}
.article-detail table {
    width: 100%;
    margin: 1.5rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.article-detail table th,
.article-detail table td {
    padding: 0.75rem 1rem;
    border: 1px solid #e9ecef;
}
.article-detail table th {
    background: #f8f9fa;
    font-weight: 600;
}
.article-detail ul, .article-detail ol {
    padding-left: 1.5rem;
    margin: 1rem 0;
}
.article-detail li {
    margin-bottom: 0.35rem;
}

/* ===== Hero section ===== */
.hero-section {
    padding: 5rem 0;
    margin: 1rem 0 2.5rem;
    position: relative;
    overflow: hidden;
}
.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at 30% 50%, rgba(255,255,255,0.08) 0%, transparent 60%);
    pointer-events: none;
}

/* ===== Footer ===== */
.site-footer {
    box-shadow: 0 -2px 20px rgba(0,0,0,0.05);
}
.site-footer a {
    opacity: 0.75;
    transition: all 0.2s;
}
.site-footer a:hover {
    opacity: 1;
    text-decoration: none;
}

/* ===== Category badges ===== */
.category-badge {
    display: inline-block;
    padding: 0.35em 0.75em;
    font-size: 0.75em;
    font-weight: 600;
    border-radius: 50rem;
    text-decoration: none;
    transition: all 0.2s;
}
.category-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ===== Breadcrumbs ===== */
.breadcrumb {
    background: transparent;
    padding: 0;
    margin-bottom: 0.5rem;
}

/* ===== Animations ===== */
.fade-in {
    animation: fadeIn 0.4s ease-in;
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ===== Search highlight ===== */
mark {
    padding: 0.1em 0.3em;
    border-radius: 4px;
    background: #fff3cd;
}

/* ===== Pagination ===== */
.pagination {
    margin-top: 2.5rem;
}
.page-link {
    border-radius: 8px !important;
    margin: 0 2px;
    border: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: all 0.2s;
}
.page-link:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* ===== Comments ===== */
.card.bg-light {
    border-radius: 8px;
}

/* ===== Section dividers ===== */
hr {
    opacity: 0.15;
    margin: 2rem 0;
}

/* ===== About section on homepage ===== */
.bg-white.rounded.shadow-sm {
    box-shadow: 0 4px 20px rgba(0,0,0,0.05) !important;
    border-radius: 12px !important;
}

/* ===== Responsive tweaks ===== */
@media (max-width: 768px) {
    .hero-section { padding: 3rem 0; }
    .hero-section h1 { font-size: 1.75rem; }
    .article-card .card-img-top { height: 160px; }
}
