/* ========================================
   BLOG POST — DESIGN SYSTEM PREMIUM
   Herda variáveis de ../style.css
   ======================================== */

/* BREADCRUMB */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: .8rem;
    color: var(--text3);
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.breadcrumb a {
    color: var(--text3);
    transition: color .2s;
}

.breadcrumb a:hover {
    color: var(--gold-light);
}

.breadcrumb svg {
    width: 14px;
    height: 14px;
    color: var(--text3);
    flex-shrink: 0;
}

.breadcrumb .current {
    color: var(--text2);
}

/* POST HERO */
.post-hero {
    padding: calc(var(--header-h) + 56px) 0 56px;
    position: relative;
    overflow: hidden;
    background: var(--bg);
}

.post-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 50% at 50% 0%, rgba(59, 130, 246, .06) 0%, transparent 70%);
    pointer-events: none;
}

.post-hero-grid {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(59, 130, 246, .02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59, 130, 246, .02) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, black, transparent);
    -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, black, transparent);
}

.post-hero-inner {
    position: relative;
    z-index: 2;
    max-width: 860px;
}

.post-category {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 18px;
    border-radius: 100px;
    background: rgba(59, 130, 246, .08);
    border: 1px solid rgba(59, 130, 246, .18);
    font-size: .75rem;
    font-weight: 700;
    color: var(--gold-light);
    letter-spacing: .08em;
    text-transform: uppercase;
    margin-bottom: 24px;
}

.post-hero h1 {
    font-family: var(--font-h);
    font-size: clamp(1.9rem, 4.5vw, 3rem);
    font-weight: 900;
    line-height: 1.12;
    letter-spacing: -.025em;
    margin-bottom: 24px;
    color: var(--text);
}

.post-hero h1 .highlight {
    background: linear-gradient(135deg, var(--gold-light), var(--gold));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.post-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 32px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--border);
}

.post-meta-item {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: .83rem;
    color: var(--text3);
}

.post-meta-item svg {
    width: 15px;
    height: 15px;
    color: var(--gold);
    flex-shrink: 0;
}

.post-meta-item strong {
    color: var(--text2);
    font-weight: 600;
}

.post-excerpt {
    font-size: 1.12rem;
    color: var(--text2);
    line-height: 1.8;
    max-width: 760px;
}

/* LAYOUT PRINCIPAL */
.post-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 56px;
    align-items: start;
    padding: 64px 0 100px;
}

/* ARTICLE BODY */
.post-body {
    min-width: 0;
    /* prevent overflow */
}

.post-body h2 {
    font-family: var(--font-h);
    font-size: clamp(1.35rem, 3vw, 1.75rem);
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -.02em;
    color: var(--text);
    margin: 52px 0 18px;
    padding-top: 8px;
}

.post-body h2:first-child {
    margin-top: 0;
}

.post-body h3 {
    font-family: var(--font-h);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin: 36px 0 14px;
}

.post-body h4 {
    font-family: var(--font-h);
    font-size: 1rem;
    font-weight: 700;
    color: var(--gold-light);
    margin: 28px 0 10px;
}

.post-body p {
    font-size: 1rem;
    color: var(--text2);
    line-height: 1.85;
    margin-bottom: 20px;
}

.post-body p strong {
    color: var(--text);
    font-weight: 600;
}

.post-body ul,
.post-body ol {
    margin: 0 0 24px 0;
    padding-left: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.post-body ul li,
.post-body ol li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: .97rem;
    color: var(--text2);
    line-height: 1.7;
}

.post-body ul li::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--gold);
    margin-top: 8px;
    flex-shrink: 0;
}

.post-body ol {
    counter-reset: ol-counter;
}

.post-body ol li {
    counter-increment: ol-counter;
}

.post-body ol li::before {
    content: counter(ol-counter);
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: #0a0a0a;
    font-size: .75rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.post-body li strong {
    color: var(--text);
    font-weight: 600;
}

.post-body a {
    color: var(--gold-light);
    text-decoration: underline;
    text-decoration-color: rgba(96, 165, 250, .3);
    text-underline-offset: 3px;
    transition: all .2s;
}

.post-body a:hover {
    color: var(--gold);
    text-decoration-color: var(--gold);
}

.post-body blockquote {
    margin: 32px 0;
    padding: 24px 28px;
    background: rgba(59, 130, 246, .05);
    border-left: 3px solid var(--gold);
    border-radius: 0 var(--r) var(--r) 0;
}

.post-body blockquote p {
    font-size: 1.05rem;
    font-style: italic;
    color: var(--text);
    margin: 0;
    line-height: 1.7;
}

.post-body blockquote cite {
    display: block;
    margin-top: 12px;
    font-size: .83rem;
    color: var(--text3);
    font-style: normal;
}

/* HIGHLIGHT BOX */
.post-highlight {
    background: rgba(59, 130, 246, .06);
    border: 1px solid rgba(59, 130, 246, .15);
    border-radius: var(--r-lg);
    padding: 28px 32px;
    margin: 32px 0;
}

.post-highlight-title {
    font-family: var(--font-h);
    font-size: .9rem;
    font-weight: 700;
    color: var(--gold-light);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.post-highlight-title svg {
    width: 18px;
    height: 18px;
}

.post-highlight p {
    margin-bottom: 0;
    font-size: .97rem;
}

.post-highlight ul {
    margin-bottom: 0;
}

/* WARNING / TIP boxes */
.post-warning {
    background: rgba(239, 68, 68, .06);
    border: 1px solid rgba(239, 68, 68, .18);
    border-radius: var(--r-lg);
    padding: 24px 28px;
    margin: 28px 0;
}

.post-warning .label {
    font-size: .8rem;
    font-weight: 700;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 10px;
}

.post-warning p {
    margin: 0;
    font-size: .95rem;
}

/* TABLE */
.post-table-wrap {
    overflow-x: auto;
    margin: 28px 0;
    border-radius: var(--r);
}

.post-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
}

.post-table th {
    background: rgba(59, 130, 246, .1);
    color: var(--gold-light);
    font-family: var(--font-h);
    font-weight: 700;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    padding: 14px 18px;
    text-align: left;
    border-bottom: 1px solid rgba(59, 130, 246, .15);
}

.post-table td {
    padding: 14px 18px;
    color: var(--text2);
    border-bottom: 1px solid rgba(255, 255, 255, .04);
    vertical-align: top;
    line-height: 1.6;
}

.post-table tr:last-child td {
    border-bottom: none;
}

.post-table tr:hover td {
    background: rgba(255, 255, 255, .02);
}

.post-table td strong {
    color: var(--text);
}

/* SUMMARY BOX (TL;DR / Pontos-chave) */
.post-summary {
    background: rgba(20, 20, 20, .7);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 28px 32px;
    margin-bottom: 48px;
}

.post-summary h4 {
    font-family: var(--font-h);
    font-size: .85rem;
    font-weight: 700;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: .1em;
    margin: 0 0 16px;
}

.post-summary ul {
    margin: 0;
}

/* INLINE CTA */
.post-cta-inline {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    background: linear-gradient(135deg, rgba(59, 130, 246, .08), rgba(30, 58, 138, .1));
    border: 1px solid rgba(59, 130, 246, .2);
    border-radius: var(--r-lg);
    padding: 28px 32px;
    margin: 44px 0;
}

.post-cta-inline-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.post-cta-inline-icon svg {
    width: 24px;
    height: 24px;
    color: #0a0a0a;
}

.post-cta-inline-text h4 {
    font-family: var(--font-h);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 8px;
}

.post-cta-inline-text p {
    font-size: .9rem;
    color: var(--text2);
    margin: 0 0 16px;
    line-height: 1.6;
}

.post-cta-inline-text .btn-gold {
    font-size: .88rem;
    padding: 12px 24px;
}

/* POST TAGS */
.post-tags {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 48px 0 0;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}

.post-tags-label {
    font-size: .82rem;
    color: var(--text3);
    font-weight: 600;
}

.post-tag {
    padding: 5px 14px;
    border-radius: 6px;
    background: rgba(255, 255, 255, .04);
    border: 1px solid var(--border);
    font-size: .78rem;
    color: var(--text3);
    transition: all .2s;
}

.post-tag:hover {
    border-color: var(--gold);
    color: var(--gold-light);
    background: var(--gold-glow);
}

/* RELATED POSTS */
.related-posts {
    margin-top: 64px;
    padding-top: 48px;
    border-top: 1px solid var(--border);
}

.related-posts h3 {
    font-family: var(--font-h);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 28px;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.related-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 22px;
    transition: all .4s cubic-bezier(.16, 1, .3, 1);
    text-decoration: none !important;
    display: block;
}

.related-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-gold);
}

.related-card-cat {
    font-size: .7rem;
    font-weight: 700;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 10px;
}

.related-card h4 {
    font-family: var(--font-h);
    font-size: .95rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.4;
    margin-bottom: 8px;
    text-decoration: none !important;
}

.related-card p {
    font-size: .82rem;
    color: var(--text3);
    line-height: 1.5;
    text-decoration: none !important;
    margin: 0;
}

/* SIDEBAR */
.post-sidebar {
    position: sticky;
    top: calc(var(--header-h) + 24px);
}

.sidebar-author {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 28px;
    margin-bottom: 24px;
    text-align: center;
}

.sidebar-author-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-family: var(--font-h);
    font-size: 1.5rem;
    font-weight: 800;
    color: #0a0a0a;
}

.sidebar-author-avatar img {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    object-position: top;
}

.sidebar-author-name {
    font-family: var(--font-h);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 4px;
}

.sidebar-author-role {
    font-size: .8rem;
    color: var(--gold);
    margin-bottom: 12px;
}

.sidebar-author-bio {
    font-size: .85rem;
    color: var(--text3);
    line-height: 1.6;
    margin-bottom: 20px;
}

.sidebar-cta {
    background: linear-gradient(135deg, rgba(59, 130, 246, .1), rgba(30, 58, 138, .12));
    border: 1px solid rgba(59, 130, 246, .2);
    border-radius: var(--r-lg);
    padding: 28px;
    margin-bottom: 24px;
}

.sidebar-cta h4 {
    font-family: var(--font-h);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 10px;
    line-height: 1.35;
}

.sidebar-cta p {
    font-size: .85rem;
    color: var(--text2);
    line-height: 1.6;
    margin-bottom: 18px;
}

.sidebar-cta .btn-gold {
    width: 100%;
    justify-content: center;
    font-size: .88rem;
    padding: 13px 20px;
}

.sidebar-posts {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 24px;
}

.sidebar-posts h4 {
    font-family: var(--font-h);
    font-size: .85rem;
    font-weight: 700;
    color: var(--text2);
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 16px;
}

.sidebar-post-item {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, .05);
    text-decoration: none !important;
    transition: all .2s;
}

.sidebar-post-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.sidebar-post-item-cat {
    font-size: .7rem;
    color: var(--gold);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    margin-bottom: 4px;
}

.sidebar-post-item-title {
    font-size: .88rem;
    color: var(--text2);
    line-height: 1.4;
    font-weight: 500;
    transition: color .2s;
}

.sidebar-post-item:hover .sidebar-post-item-title {
    color: var(--gold-light);
}

/* PROGRESS BAR */
.read-progress {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    height: 3px;
    z-index: 99;
    background: transparent;
}

.read-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--royal-light), var(--gold-light), var(--gold));
    border-radius: 0 2px 2px 0;
    transition: width .1s linear;
}

/* FAQ */
.faq-section {
    margin-top: 64px;
}

.faq-section h2 {
    font-family: var(--font-h);
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 28px;
}

.faq-item {
    border: 1px solid var(--border);
    border-radius: var(--r);
    margin-bottom: 12px;
    overflow: hidden;
    transition: border-color .3s;
}

.faq-item.open {
    border-color: rgba(59, 130, 246, .2);
}

.faq-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 22px;
    background: transparent;
    border: none;
    color: var(--text);
    font-family: var(--font-h);
    font-size: .97rem;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
    transition: background .2s;
}

.faq-trigger:hover {
    background: rgba(255, 255, 255, .03);
}

.faq-trigger svg {
    width: 18px;
    height: 18px;
    color: var(--gold);
    flex-shrink: 0;
    transition: transform .3s;
}

.faq-item.open .faq-trigger svg {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height .4s cubic-bezier(.16, 1, .3, 1);
}

.faq-item.open .faq-answer {
    max-height: 600px;
}

.faq-answer-inner {
    padding: 0 22px 22px;
}

.faq-answer-inner p {
    font-size: .95rem;
    color: var(--text2);
    line-height: 1.8;
    margin: 0;
}

/* FINAL CTA BANNER */
.post-final-cta {
    background: linear-gradient(135deg, rgba(59, 130, 246, .08) 0%, rgba(30, 58, 138, .12) 100%);
    border: 1px solid rgba(59, 130, 246, .2);
    border-radius: var(--r-xl);
    padding: 56px 48px;
    text-align: center;
    margin-top: 80px;
}

.post-final-cta h2 {
    font-family: var(--font-h);
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 800;
    margin-bottom: 16px;
}

.post-final-cta p {
    font-size: 1.05rem;
    color: var(--text2);
    max-width: 520px;
    margin: 0 auto 32px;
    line-height: 1.7;
}

.post-final-cta .btn-gold {
    font-size: 1rem;
    padding: 16px 36px;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .post-layout {
        grid-template-columns: 1fr;
    }

    .post-sidebar {
        position: static;
    }

    .related-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 640px) {
    .post-hero h1 {
        font-size: 1.7rem;
    }

    .post-final-cta {
        padding: 40px 28px;
    }

    .related-grid {
        grid-template-columns: 1fr;
    }

    .post-meta {
        gap: 12px;
    }

    .post-cta-inline {
        flex-direction: column;
    }

    .post-layout {
        gap: 48px;
    }
}