/* ==========================================================================
   Blog Styles — sitorakarimi.com
   Extends the site's design system (navy-900 #0a2a3d, coral #ff6b4a)
   ========================================================================== */

/* ---------- AI Translation Banner ---------- */
.ai-translation-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 55; /* above navbar (z-50) */
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #92400e;
    font-size: 0.875rem;
    font-weight: 400;
    padding: 10px 16px;
    text-align: center;
    border-bottom: 1px solid #f59e0b33;
}

.ai-translation-banner a {
    color: #92400e;
    font-weight: 500;
}

/* Push navbar down when banner is present */
.ai-translation-banner ~ #navbar {
    top: 38px; /* banner height */
}

/* Push article header down to clear banner + navbar */
.ai-translation-banner ~ #navbar ~ .blog-post > header {
    padding-top: 10rem; /* 38px banner + 80px navbar + breathing room */
}

/* ---------- Blog Card Grid ---------- */
.blog-card {
    display: flex;
    flex-direction: column;
    border: 1px solid #f3f4f6;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-4px);
}

.blog-card-image img {
    transition: transform 0.4s ease;
}

.blog-card:hover .blog-card-image img {
    transform: scale(1.05);
}

.blog-category {
    letter-spacing: 0.08em;
}

/* ---------- Blog Post Content (Prose) ---------- */
.blog-content {
    font-size: 1.0625rem;
    line-height: 1.85;
    color: #374151;
}

.blog-content h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #0a2a3d;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.blog-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #0a2a3d;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
}

.blog-content p {
    margin-bottom: 1.25rem;
}

.blog-content ul,
.blog-content ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.blog-content ul {
    list-style-type: disc;
}

.blog-content ol {
    list-style-type: decimal;
}

.blog-content li {
    margin-bottom: 0.5rem;
    padding-left: 0.25rem;
}

.blog-content strong {
    font-weight: 600;
    color: #1f2937;
}

.blog-content em {
    font-style: italic;
}

.blog-content a {
    color: #ff6b4a;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
}

.blog-content a:hover {
    color: #0a2a3d;
}

.blog-content blockquote {
    border-left: 3px solid #ff6b4a;
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    background: #f9fafb;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: #4b5563;
}

.blog-content hr {
    border: none;
    border-top: 1px solid #e5e7eb;
    margin: 2rem 0;
}

.blog-content img {
    border-radius: 8px;
    margin: 1.5rem 0;
    max-width: 100%;
    height: auto;
}

.blog-content code {
    background: #f3f4f6;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    color: #0a2a3d;
}

/* ---------- Tags ---------- */
.blog-tag {
    display: inline-block;
    padding: 4px 12px;
    background: #f3f4f6;
    color: #6b7280;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 400;
    transition: background 0.2s, color 0.2s;
}

.blog-tag:hover {
    background: #0a2a3d;
    color: #fff;
}

/* ---------- Share Buttons ---------- */
.blog-share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f3f4f6;
    color: #6b7280;
    border: none;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, transform 0.2s;
}

.blog-share-btn:hover {
    background: #0a2a3d;
    color: #fff;
    transform: scale(1.1);
}

/* ---------- Line Clamp ---------- */
.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .ai-translation-banner {
        font-size: 0.75rem;
        padding: 6px 12px;
    }

    .ai-translation-banner ~ #navbar {
        top: 30px; /* smaller banner on mobile */
    }

    .blog-content {
        font-size: 1rem;
        line-height: 1.75;
    }

    .blog-content h2 {
        font-size: 1.3rem;
        margin-top: 2rem;
    }

    .blog-content h3 {
        font-size: 1.1rem;
    }

    .blog-content blockquote {
        padding: 0.75rem 1rem;
        margin: 1rem 0;
    }
}

/* ---------- Print ---------- */
@media print {
    .ai-translation-banner,
    .blog-share-btn,
    nav,
    footer {
        display: none !important;
    }

    .blog-content {
        font-size: 12pt;
        line-height: 1.6;
    }
}
