/* Blog post common styles */

/* Base typography for markdown blog posts */
.post_content {
    font-size: 17px;
    line-height: 1.8;
    color: #3a3a3a;
    max-width: 720px;
}

.post_content p {
    margin-bottom: 20px;
}

.post_content strong {
    color: #263039;
    font-weight: 600;
}

.post_content a {
    color: #4e8c1a;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.post_content a:hover {
    color: #3a6a10;
}

/* Headings */
.post_content h1 {
    margin-top: 48px;
    margin-bottom: 24px;
    font-size: 32px;
    font-weight: 700;
    color: #1a2a1a;
    letter-spacing: -0.02em;
}

.post_content h2 {
    margin-top: 56px;
    margin-bottom: 20px;
    font-size: 28px;
    font-weight: 700;
    color: #1a2a1a;
    letter-spacing: -0.02em;
    border-bottom: none;
    padding-bottom: 0;
}

.post_content h2::after {
    content: "";
    display: block;
    width: 48px;
    height: 3px;
    background: #67aa25;
    margin-top: 10px;
    border-radius: 2px;
}

.post_content h3 {
    margin-top: 32px;
    margin-bottom: 14px;
    font-size: 20px;
    font-weight: 600;
    color: #2c3e2c;
}

.post_content h4 {
    margin-top: 24px;
    margin-bottom: 12px;
    font-size: 18px;
    font-weight: 600;
    color: #2c3e2c;
}

/* First paragraph as lead-in */
.post_content > p:first-of-type {
    font-size: 21px;
    line-height: 1.6;
    color: #2c3e2c;
    font-weight: 400;
}

/* Blockquotes - styled as tips/callouts */
.post_content blockquote {
    margin: 24px 0;
    padding: 18px 24px;
    border-left: 4px solid #87a46e;
    background: #fafcf8;
    border-radius: 0 8px 8px 0;
    font-size: 16px;
    color: #4a4a4a;
}

.post_content blockquote p {
    margin-bottom: 10px;
}

.post_content blockquote p:last-child {
    margin-bottom: 0;
}

.post_content blockquote strong {
    color: #2c4a1c;
    font-weight: 700;
}

/* Pro tip style blockquotes (when starting with "Pro Tip:" or similar) */
.post_content blockquote p:first-child strong:first-child {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #67aa25;
    margin-bottom: 8px;
}

/* Lists */
.post_content ul,
.post_content ol {
    margin: 20px 0 20px 24px;
    padding: 0;
}

.post_content li {
    margin-bottom: 10px;
    line-height: 1.7;
}

.post_content li p {
    margin-bottom: 8px;
}

/* Tables */
.post_content table {
    width: 100%;
    margin: 28px 0;
    border-collapse: collapse;
    font-size: 15px;
}

.post_content table thead {
    background: #f7faf3;
    border-bottom: 2px solid #67aa25;
}

.post_content table th {
    padding: 12px 16px;
    text-align: left;
    font-weight: 600;
    color: #2c3e2c;
    border-bottom: 2px solid #67aa25;
}

.post_content table td {
    padding: 12px 16px;
    border-bottom: 1px solid #e8e8e8;
}

.post_content table tr:last-child td {
    border-bottom: none;
}

.post_content table tr:hover {
    background: #fafcf8;
}

/* Code blocks */
.post_content code {
    background: #f5f5f5;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.9em;
    font-family: 'Courier New', monospace;
    color: #d73a49;
}

.post_content pre {
    background: #f6f8fa;
    padding: 16px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 20px 0;
}

.post_content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

/* Horizontal rules */
.post_content hr {
    border: none;
    border-top: 2px solid #e8e8e8;
    margin: 48px 0;
}

/* Images */
.post_content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 24px 0;
}

/* Lead paragraph styling (legacy support) */
.lead {
    font-size: 1.2em;
    line-height: 1.6;
    margin-bottom: 1.5em;
}

/* Sticky sidebar elements */
.ui.sticky {
    position: sticky;
    top: 20px;
}

/* Responsive adjustments */
@media (max-width: 767px) {
    .post_content {
        font-size: 16px;
    }

    .post_content > p:first-of-type {
        font-size: 19px;
    }

    .post_content h1 {
        font-size: 26px;
        margin-top: 32px;
    }

    .post_content h2 {
        font-size: 23px;
        margin-top: 40px;
    }

    .post_content h3 {
        font-size: 19px;
    }

    .post_content blockquote {
        padding: 14px 18px;
        margin: 20px 0;
    }

    .post_content table {
        font-size: 14px;
    }

    .post_content table th,
    .post_content table td {
        padding: 10px 12px;
    }

    .ui.sticky {
        position: relative;
        top: 0;
    }
}

/* Custom class support for advanced styling */

/* Persona cards (use with {: .persona} in markdown) */
.persona {
    margin-bottom: 16px;
    padding: 20px 24px;
    background: #fafcf8;
    border-left: 4px solid #87a46e;
    border-radius: 0 8px 8px 0;
}

.persona h3 {
    margin-top: 0 !important;
    margin-bottom: 10px !important;
    font-size: 18px !important;
    font-weight: 700;
    color: #2c4a1c;
}

.persona p {
    font-size: 16px;
    margin-bottom: 10px;
    color: #4a4a4a;
}

.persona p:last-child {
    margin-bottom: 0;
}

/* Callout boxes (use with {: .callout} in markdown) */
.callout {
    background: #f0f5eb;
    border-radius: 8px;
    padding: 24px 28px;
    margin: 32px 0;
    font-size: 18px;
    font-weight: 600;
    color: #2c4a1c;
    text-align: center;
    line-height: 1.6;
}

/* Tips (use with {: .tip} in markdown) */
.tip {
    margin-bottom: 16px;
    padding: 14px 18px;
    border-left: 3px solid #c8d8b8;
    background: #fcfdfb;
    border-radius: 0 6px 6px 0;
}

.tip p {
    margin-bottom: 0;
    font-size: 16px;
}

.tip strong {
    color: #1a2a1a;
}

/* CTA sections */
.cta-section {
    margin-top: 56px;
    padding: 40px 32px;
    background: #f0f5eb;
    border-radius: 12px;
    text-align: center;
}

.cta-section h2 {
    margin-top: 0;
    font-size: 26px;
}

.cta-section h2::after {
    margin-left: auto;
    margin-right: auto;
}

.cta-section p {
    font-size: 17px;
    color: #4a5a4a;
    margin-bottom: 24px;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.cta-btn {
    display: inline-block;
    background: #67aa25;
    color: #fff !important;
    padding: 14px 36px;
    border-radius: 8px;
    font-size: 17px;
    font-weight: 600;
    text-decoration: none !important;
    transition: background 0.2s, transform 0.1s;
    box-shadow: 0 2px 8px rgba(103, 170, 37, 0.25);
}

.cta-btn:hover {
    background: #5a9420;
    color: #fff !important;
    text-decoration: none !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(103, 170, 37, 0.3);
}

/* Responsive for custom classes */
@media (max-width: 767px) {
    .persona {
        padding: 16px 18px;
    }

    .callout {
        padding: 20px;
        font-size: 16px;
    }

    .cta-section {
        padding: 28px 20px;
    }

    .cta-section h2 {
        font-size: 22px;
    }
}
