/* ── Fideograph Ads – Frontend Card Styles ───────────────── */

/* Base ad card – inherits the grid cell dimensions of whatever section it sits in */
.fgads-card {
    position: relative;
    background: #fff;
    border: 1px solid #e0dcd4;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
    display: flex;
    flex-direction: column;
}
.fgads-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    transform: translateY(-1px);
}

/* Sponsor label – small, unobtrusive */
.fgads-card__label {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(0,0,0,0.55);
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 3px;
    line-height: 1.4;
    pointer-events: none;
}

/* Image type */
.fgads-card__link {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    flex: 1;
}
.fgads-card__img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}
.fgads-card__headline {
    display: block;
    padding: 14px 16px 8px;
    font-size: 15px;
    font-weight: 600;
    color: #2c2620;
    line-height: 1.35;
}

/* Text type */
.fgads-card__link--text {
    padding: 20px 16px;
    gap: 8px;
}
.fgads-card__body {
    display: block;
    font-size: 13px;
    color: #666;
    line-height: 1.5;
}
.fgads-card__cta {
    display: inline-block;
    margin-top: 8px;
    padding: 6px 14px;
    background: #2c2620;
    color: #fff;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    align-self: flex-start;
}

/* HTML embed */
.fgads-card__embed {
    padding: 12px;
    flex: 1;
}
.fgads-card__embed iframe {
    max-width: 100%;
}

/* ── Section-specific overrides ──────────────────────────── */

/* Claims page: cards have a question style with bottom badge.
   The ad card matches the claims card padding and height range. */
.fgads-card--claims {
    padding: 0;
    min-height: 180px;
}
.fgads-card--claims .fgads-card__link--text {
    padding: 24px 20px;
}
.fgads-card--claims .fgads-card__headline {
    font-size: 16px;
    padding: 24px 20px 8px;
}

/* Objections: Summa-style layout */
.fgads-card--objections {
    border-left: 3px solid #c0a060;
}

/* Saints: portrait-style cards */
.fgads-card--saints .fgads-card__img {
    aspect-ratio: 3/4;
    object-fit: cover;
}

/* Quiz: compact, vibrant */
.fgads-card--quiz {
    border-radius: 10px;
    border-color: #ddd;
}
.fgads-card--quiz .fgads-card__cta {
    background: #1a56db;
}

/* Library: book-like */
.fgads-card--library {
    background: #faf8f5;
    border-color: #d4c8b4;
}

/* HSE: scenario cards */
.fgads-card--hse {
    background: linear-gradient(180deg, #f8f6f3 0%, #fff 100%);
}

/* Belief Map: data-card style */
.fgads-card--beliefs {
    border: 1px solid #ccc;
    border-radius: 6px;
}

/* Citations: compact text-heavy */
.fgads-card--citations {
    font-size: 13px;
}
.fgads-card--citations .fgads-card__headline {
    font-size: 14px;
}

/* Pathways: logic-flow card */
.fgads-card--pathways {
    border-left: 3px solid #2c2620;
}

/* Global: neutral default */
.fgads-card--global {}

/* Fade-in animation for JS-injected ads */
@keyframes fgadsIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── Responsive ──────────────────────────────────────────── */
@media (max-width: 600px) {
    .fgads-card__headline { font-size: 14px; padding: 12px 14px 6px; }
    .fgads-card__link--text { padding: 14px; }
}

/* ═══════════════════════════════════════════════════════════
   INLINE ADS (between paragraphs in article content)
   ═══════════════════════════════════════════════════════════ */

.fgads-inline {
    position: relative;
    margin: 32px 0;
    padding: 20px 24px;
    background: #faf8f5;
    border: 1px solid #e8e2d8;
    border-radius: 8px;
    clear: both;
}

.fgads-inline__label {
    display: inline-block;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #999;
    margin-bottom: 10px;
}

/* Image inline ad */
.fgads-inline__link {
    display: flex;
    align-items: center;
    gap: 20px;
    text-decoration: none;
    color: inherit;
}
.fgads-inline__img {
    width: 120px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
}
.fgads-inline__headline {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #2c2620;
    line-height: 1.35;
    margin-bottom: 4px;
}

/* Text inline ad */
.fgads-inline__link--text {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}
.fgads-inline__body {
    display: block;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}
.fgads-inline__cta {
    display: inline-block;
    margin-top: 6px;
    padding: 6px 16px;
    background: #2c2620;
    color: #fff;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    transition: background 0.15s;
}
.fgads-inline__cta:hover {
    background: #3d342c;
}

/* HTML embed inline */
.fgads-inline__embed {
    width: 100%;
}
.fgads-inline__embed iframe {
    max-width: 100%;
}

/* Section-specific inline overrides */
.fgads-inline--claims {
    border-left: 3px solid #c9a84c;
    background: #fcfaf5;
}
.fgads-inline--objections {
    border-left: 3px solid #c0a060;
}
.fgads-inline--saints {
    background: #f8f6f2;
    border-color: #d8d0c4;
}

/* Dark theme pages (HSE, pathways, homepage) */
.fg-dark .fgads-inline,
.fgads-inline--hse,
.fgads-inline--pathways {
    background: rgba(250, 246, 237, 0.06);
    border-color: rgba(250, 246, 237, 0.12);
}
.fg-dark .fgads-inline__headline,
.fgads-inline--hse .fgads-inline__headline,
.fgads-inline--pathways .fgads-inline__headline {
    color: rgba(250, 246, 237, 0.9);
}
.fg-dark .fgads-inline__body,
.fgads-inline--hse .fgads-inline__body,
.fgads-inline--pathways .fgads-inline__body {
    color: rgba(250, 246, 237, 0.6);
}
.fg-dark .fgads-inline__label,
.fgads-inline--hse .fgads-inline__label,
.fgads-inline--pathways .fgads-inline__label {
    color: rgba(250, 246, 237, 0.35);
}

/* Inline responsive */
@media (max-width: 600px) {
    .fgads-inline { padding: 16px; margin: 24px 0; }
    .fgads-inline__link { flex-direction: column; gap: 12px; }
    .fgads-inline__img { width: 100%; height: auto; max-height: 160px; }
    .fgads-inline__headline { font-size: 14px; }
}
