/*
 * aeo-components.css: citation-ready content components (added 2026-10-06)
 * Answer boxes, definition boxes, data tables, stat sources, source lists,
 * author bylines, founder card and static FAQ blocks.
 * Uses the same design tokens as nerativ.css / the inline homepage styles.
 */

.answer-box {
    position: relative;
    max-width: 780px;
    margin: 40px 0 0;
    padding: 24px 28px;
    background: var(--white, #fff);
    border: 3px solid var(--border, #111);
    box-shadow: 6px 6px 0 var(--border, #111);
    color: var(--text, #111);
}
.answer-box-label {
    display: inline-block;
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent, #e63322);
    margin-bottom: 10px;
}
.answer-box p {
    font-size: 1.05rem;
    line-height: 1.65;
    font-weight: 400;
    margin: 0;
}
.answer-box p + p { margin-top: 10px; }
.section-dark .answer-box, .answer-box.on-dark { box-shadow: 6px 6px 0 var(--accent, #e63322); }

.def-box {
    max-width: 780px;
    margin: 32px 0;
    padding: 20px 24px;
    border-left: 6px solid var(--accent, #e63322);
    background: var(--bg-alt, #e8e5de);
}
.def-box dt {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin-bottom: 6px;
}
.def-box dd { margin: 0; font-size: 1rem; line-height: 1.65; font-weight: 400; }

.nv-section { padding: 96px 0; position: relative; }
.nv-section .nv-kicker {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent, #e63322);
}
.nv-h2 {
    font-family: var(--font-display, 'Bebas Neue', sans-serif);
    font-size: clamp(2.2rem, 4.5vw, 3.6rem);
    line-height: 1;
    letter-spacing: 0.01em;
    font-weight: 400;
    margin: 18px 0 24px;
    max-width: 900px;
}
.nv-prose { max-width: 780px; }
.nv-prose p { font-size: 1.02rem; line-height: 1.7; margin: 0 0 16px; }
.nv-prose ol, .nv-prose ul { margin: 0 0 16px 1.25rem; line-height: 1.7; }
.nv-prose li { margin-bottom: 8px; }
.nv-prose a, .answer-box a, .def-box a, .nv-sources a { color: inherit; text-decoration: underline; text-decoration-color: var(--accent, #e63322); text-underline-offset: 3px; }

.nv-table-wrap { overflow-x: auto; margin: 24px 0 8px; max-width: 980px; }
.nv-table {
    width: 100%;
    border-collapse: collapse;
    border: 3px solid var(--border, #111);
    background: var(--white, #fff);
    font-size: 0.95rem;
}
.nv-table th, .nv-table td {
    text-align: left;
    vertical-align: top;
    padding: 14px 16px;
    border: 1px solid var(--border, #111);
    line-height: 1.5;
}
.nv-table thead th {
    background: var(--bg-dark, #1a1a1a);
    color: var(--white, #fff);
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
.nv-table tbody th { font-weight: 700; background: var(--bg-alt, #e8e5de); }
.nv-table caption { caption-side: bottom; text-align: left; padding-top: 10px; font-size: 0.8rem; color: var(--text-light, #555); }

.stat-source {
    margin-top: 8px;
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.62rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    opacity: 0.7;
}
.stat-source a { color: inherit; }

.nv-sources { max-width: 900px; margin-top: 8px; font-size: 0.85rem; line-height: 1.6; }
.nv-sources ol { margin-left: 1.25rem; }
.nv-sources li { margin-bottom: 6px; }

.byline {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 0 8px;
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 0.75rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}
.byline-mark {
    width: 34px; height: 34px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 2px solid var(--border, #111);
    background: var(--bg-dark, #1a1a1a);
    color: var(--white, #fff);
    font-weight: 700;
}
.byline a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.byline .byline-role { color: var(--text-light, #555); }

.author-box {
    margin: 48px 0 0;
    padding: 22px 24px;
    border: 3px solid var(--border, #111);
    background: var(--bg-alt, #e8e5de);
    max-width: 780px;
}
.author-box p { margin: 6px 0 0; font-size: 0.95rem; line-height: 1.6; }
.author-box strong { font-weight: 700; }

.founder-card {
    display: grid;
    grid-template-columns: 96px 1fr;
    gap: 24px;
    align-items: start;
    max-width: 860px;
    padding: 28px;
    border: 3px solid var(--border, #111);
    background: var(--white, #fff);
    box-shadow: 6px 6px 0 var(--border, #111);
}
.founder-mark {
    width: 96px; height: 96px;
    display: flex; align-items: center; justify-content: center;
    background: var(--bg-dark, #1a1a1a);
    color: var(--white, #fff);
    font-family: var(--font-display, 'Bebas Neue', sans-serif);
    font-size: 2.6rem;
}
.founder-card h3 { font-family: var(--font-display, 'Bebas Neue', sans-serif); font-size: 2rem; font-weight: 400; line-height: 1; }
.founder-card .founder-role { font-family: var(--font-mono, 'JetBrains Mono', monospace); font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent, #e63322); margin: 6px 0 12px; }
.founder-card p { font-size: 1rem; line-height: 1.65; margin: 0 0 10px; }
@media (max-width: 640px) {
    .founder-card { grid-template-columns: 1fr; }
    .answer-box { padding: 20px; box-shadow: 4px 4px 0 var(--border, #111); }
    .nv-section { padding: 64px 0; }
}

.nv-faq { max-width: 860px; margin-top: 16px; border-top: 3px solid var(--border, #111); }
.nv-faq details { border-bottom: 1px solid var(--border, #111); padding: 18px 0; }
.nv-faq summary {
    cursor: pointer;
    list-style: none;
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    justify-content: space-between;
    gap: 16px;
}
.nv-faq summary::-webkit-details-marker { display: none; }
.nv-faq summary::after { content: "+"; font-family: var(--font-mono, 'JetBrains Mono', monospace); color: var(--accent, #e63322); }
.nv-faq details[open] summary::after { content: "\2212"; }
.nv-faq details p { margin: 12px 0 0; line-height: 1.7; font-size: 1rem; }

/* Mobile overflow guards (added 2026-10-06; also fixes pre-existing blog-grid and post-layout overflow) */
.nv-table-wrap { width: 100%; max-width: min(980px, calc(100vw - 32px)); -webkit-overflow-scrolling: touch; }
.nv-table { min-width: 560px; }
.post-layout > *, .term-layout > *, .two-col > *, .mechanism-layout > * { min-width: 0; }
.post-header h1, .post-body { overflow-wrap: anywhere; }
@media (max-width: 768px) {
    .blog-grid[style*="repeat(3"] { grid-template-columns: 1fr !important; }
}
.stat-source { overflow-wrap: anywhere; }
.stat-block { min-width: 0; }
.founder-card a, .author-box a { color: inherit; text-decoration: underline; text-decoration-color: var(--accent, #e63322); text-underline-offset: 3px; }
/* Light stat blocks inside dark sections: keep numbers readable (fixes pre-existing /results/ bug) */
.stat-block:not(.stat-block-dark) .stat-block-number { display: block; color: var(--text, #111); margin-bottom: 12px; }
