/* ============================================================
   PontoonHQ — SEO Components CSS
   Styles for: cluster links, PAA blocks, sources, tools CTA,
   featured snippets, zero-click optimization elements
   ============================================================ */

/* ── CLUSTER LINKS ────────────────────────────────────────── */
.cluster-links {
    background: var(--gray-100);
    border-left: 3px solid var(--teal);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 14px 18px;
    margin: 1.5rem 0;
}
.cluster-links-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--gray-400);
    font-weight: 600;
    margin-bottom: 10px;
}
.cluster-links ul {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.cluster-links a {
    font-size: 14px;
    color: var(--teal-dark);
    font-weight: 500;
}
.cluster-links a:hover { color: var(--teal); }

/* ── RELATED TOOLS BLOCK ──────────────────────────────────── */
.related-tools-block {
    background: var(--teal-light);
    border: 1px solid var(--teal);
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    margin: 1.5rem 0;
}
.rtb-heading {
    font-family: var(--font-display);
    font-size: 14px;
    font-weight: 700;
    color: var(--teal-dark);
    margin-bottom: 12px;
}
.related-tools-block ul {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.rtb-link {
    font-size: 14px;
    color: var(--teal-dark);
    font-weight: 500;
    display: inline-block;
}
.rtb-link:hover { color: var(--teal); }

/* ── PEOPLE ALSO ASK BLOCK ───────────────────────────────── */
.paa-block {
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    margin: 1.5rem 0;
    background: var(--white);
}
.paa-heading {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--gray-400);
    font-weight: 600;
    margin-bottom: 14px;
}
.paa-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--gray-100);
    gap: 12px;
    flex-wrap: wrap;
}
.paa-item:last-child { border-bottom: none; }
.paa-q { font-size: 14px; font-weight: 500; color: var(--gray-800); }
.paa-link {
    font-size: 13px;
    color: var(--teal);
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
}

/* ── SOURCES SECTION ──────────────────────────────────────── */
.sources-section {
    border-top: 1px solid var(--gray-200);
    padding-top: 16px;
    margin-top: 2rem;
}
.sources-title {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--gray-400);
    font-weight: 600;
    margin-bottom: 10px;
}
.sources-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.sources-list a {
    font-size: 13px;
    color: var(--gray-500);
    border-bottom: 1px dashed var(--gray-200);
}
.sources-list a:hover { color: var(--teal); border-color: var(--teal); }

/* ── FEATURED SNIPPET OPTIMIZATION ───────────────────────── */
/* Direct answer box — use for definition/answer content */
.direct-answer {
    background: var(--gray-100);
    border-left: 4px solid var(--teal);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    padding: 16px 20px;
    margin: 1rem 0 1.5rem;
    font-size: 15px;
    line-height: 1.65;
}
.direct-answer strong { font-weight: 600; color: var(--gray-900); }

/* TL;DR summary — place after intro for zero-click optimization */
.tldr-box {
    background: var(--teal-light);
    border: 1px solid var(--teal);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    margin: 1rem 0 1.5rem;
}
.tldr-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--teal-dark);
    font-weight: 700;
    margin-bottom: 8px;
}
.tldr-box p {
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    color: var(--gray-800);
}

/* Step list — for HowTo rich results */
.step-list {
    counter-reset: step-counter;
    list-style: none;
    padding: 0;
    margin: 1rem 0 1.5rem;
}
.step-list li {
    counter-increment: step-counter;
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 12px 0;
    border-bottom: 1px solid var(--gray-100);
    font-size: 15px;
    line-height: 1.65;
}
.step-list li:last-child { border-bottom: none; }
.step-list li::before {
    content: counter(step-counter);
    min-width: 28px;
    height: 28px;
    background: var(--teal);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 700;
    flex-shrink: 0;
}

/* Comparison table — for featured snippet eligibility */
.comparison-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    margin: 1.5rem 0;
}
.comparison-table th {
    background: var(--teal);
    color: white;
    padding: 10px 14px;
    text-align: left;
    font-weight: 600;
    font-size: 13px;
}
.comparison-table th:first-child { border-radius: var(--radius-sm) 0 0 0; }
.comparison-table th:last-child  { border-radius: 0 var(--radius-sm) 0 0; }
.comparison-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--gray-100);
    vertical-align: middle;
}
.comparison-table tr:nth-child(even) td { background: var(--gray-100); }
.comparison-table tr:hover td { background: var(--teal-light); }
.comparison-table .winner { color: var(--teal); font-weight: 600; }
.comparison-table .loser  { color: var(--gray-400); }

/* ── ANCHOR TEXT QUALITY INDICATORS (dev only) ────────────── */
/* Highlights bad anchor text patterns in development */
body.dev-mode a[href*="pontoonhq"]:not([data-anchor-ok])::after {
    content: " ⚠";
    color: #BA7517;
    font-size: 11px;
}

/* ── FRESHNESS DATE BADGE ─────────────────────────────────── */
.freshness-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--gray-100);
    border-radius: var(--radius-sm);
    padding: 3px 10px;
    font-size: 11px;
    color: var(--gray-500);
    font-weight: 500;
}
.freshness-badge.recent { background: var(--teal-light); color: var(--teal-dark); }

/* ── KEYWORD DENSITY METER (visible in admin only) ───────── */
.kw-dashboard { overflow-x: auto; }
.kw-dashboard table { font-size: 12px; min-width: 600px; }
.kw-dashboard th { background: var(--gray-100); }

/* ── EXTERNAL LINK INDICATOR ─────────────────────────────── */
/* Visual signal for external authority links */
.article-body a[target="_blank"]:not(.btn):not(.btn-affiliate)::after {
    content: " ↗";
    font-size: 11px;
    opacity: 0.6;
    margin-left: 1px;
}

/* ── ZERO-CLICK FAQ OPTIMIZATION ─────────────────────────── */
/* FAQ answers kept concise for PAA eligibility */
.faq-item p {
    font-size: 15px;
    line-height: 1.7;
    max-width: 680px; /* Prevents overly wide answers */
}

/* ── ARTICLE IMAGE FIGURES ────────────────────────────────── */
.article-figure {
    margin: 1.5rem 0;
}
.article-figure img {
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    display: block;
}
.article-figure figcaption {
    font-size: 13px;
    color: var(--gray-400);
    margin-top: 8px;
    text-align: center;
    font-style: italic;
}

/* ── INTERNAL LINK STYLING ────────────────────────────────── */
/* Contextual internal links in article body */
.article-body a:not(.btn):not(.btn-affiliate) {
    color: var(--teal-dark);
    border-bottom: 1px solid var(--teal-mid);
    padding-bottom: 1px;
    transition: border-color var(--duration), color var(--duration);
}
.article-body a:not(.btn):not(.btn-affiliate):hover {
    color: var(--teal);
    border-color: var(--teal);
}

/* ── RESPONSIVE ───────────────────────────────────────────── */
@media (max-width: 768px) {
    .paa-item { flex-direction: column; }
    .paa-link { align-self: flex-start; }
    .step-list li { flex-direction: column; gap: 8px; }
    .step-list li::before { align-self: flex-start; }
}
