/* ===== Ghost CMS Styling ===== */

/* Ghost Post Content Styling */
.ghost-post-content {
    max-width: 800px;
    margin: 0 auto;
}

.ghost-post-content h1,
.ghost-post-content h2,
.ghost-post-content h3,
.ghost-post-content h4 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    margin: 30px 0 15px 0;
    line-height: 1.3;
}

.ghost-post-content h1 {
    font-size: 2em;
}

.ghost-post-content h2 {
    font-size: 1.6em;
}

.ghost-post-content h3 {
    font-size: 1.3em;
}

.ghost-post-content p {
    margin: 15px 0;
    line-height: 1.8;
}

.ghost-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 25px 0;
}

.ghost-post-content ul,
.ghost-post-content ol {
    margin: 15px 0;
    padding-left: 30px;
}

.ghost-post-content li {
    margin: 8px 0;
    line-height: 1.7;
}

.ghost-post-content blockquote {
    border-left: 4px solid var(--accent);
    padding-left: 20px;
    margin: 25px 0;
    font-style: italic;
    color: var(--text-muted);
}

.ghost-post-content a {
    color: var(--accent);
    text-decoration: none;
    border-bottom: 1px solid var(--accent);
    transition: all 0.2s ease;
}

.ghost-post-content a:hover {
    color: var(--accent-secondary);
    border-bottom-color: var(--accent-secondary);
}

.ghost-post-content code {
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.ghost-post-content pre {
    background: rgba(255, 255, 255, 0.05);
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 20px 0;
}

.ghost-post-content pre code {
    background: none;
    padding: 0;
}

/* Responsive Ghost Post Content */
@media (max-width: 768px) {
    .ghost-post-content {
        font-size: 0.95em;
    }

    .ghost-post-content h1 {
        font-size: 1.6em;
    }

    .ghost-post-content h2 {
        font-size: 1.3em;
    }

    .ghost-post-content h3 {
        font-size: 1.1em;
    }
}

/* Image Captions */
.ghost-post-content figure {
    margin: 30px 0;
    text-align: center;
}

.ghost-post-content figure img {
    margin-bottom: 10px;
    /* Tighter spacing for caption */
}

.ghost-post-content figcaption {
    font-size: 0.9em;
    color: var(--text-muted);
    font-style: italic;
    line-height: 1.4;
    text-align: center;
    padding: 0 10px;
}

/* Responsive Embeds & Cards */
.kg-embed-card,
.kg-width-full,
.kg-width-wide {
    width: 100%;
    margin: 20px 0;
}

/* Force iframes to be responsive */
.ghost-post-content iframe {
    width: 100%;
    height: auto;
    min-height: 400px;
}

/* Video specific handling */
.kg-video-card video {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

/* Ensure wide images don't break layout on mobile */
.kg-image-card img {
    width: 100%;
    height: auto;
}