/**
 * UTV Guide AEO — Frontend Styles
 * Entity links, schema-enhanced content, and block styles.
 */

/* ─── Entity Links ─── */
a.utv-entity-link {
    color: #0066cc;
    text-decoration: underline;
    text-decoration-style: dotted;
    text-underline-offset: 2px;
    font-weight: 500;
    transition: color 0.15s ease, text-decoration-style 0.15s ease;
}

a.utv-entity-link:hover {
    color: #004499;
    text-decoration-style: solid;
}

a.utv-entity-link[data-entity^="brand"] {
    font-weight: 600;
}

a.utv-entity-link[data-entity^="model"] {
    font-weight: 600;
    color: #005522;
}

a.utv-entity-link[data-entity^="trail"] {
    color: #885500;
}

/* ─── Answer Capsules ─── */
.utv-answer-capsule {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border-left: 4px solid #0066cc;
    border-radius: 0 8px 8px 0;
    padding: 20px 24px;
    margin: 20px 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.utv-answer-capsule__label {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #0066cc;
    margin-bottom: 8px;
    padding: 2px 8px;
    background: rgba(0,102,204,0.08);
    border-radius: 3px;
}

.utv-answer-capsule__content {
    font-size: 1rem;
    line-height: 1.6;
    color: #333;
    margin: 0;
}

.utv-answer-capsule__source {
    font-size: 0.75rem;
    color: #888;
    margin-top: 10px;
    font-style: italic;
}

/* ─── Key Takeaways Box ─── */
.utv-takeaways {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 24px;
    margin: 24px 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.utv-takeaways__title {
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin: 0 0 16px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #0066cc;
    color: #1a1a1a;
}

.utv-takeaways__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.utv-takeaways__list li {
    position: relative;
    padding-left: 24px;
    margin-bottom: 12px;
    font-size: 0.9375rem;
    line-height: 1.5;
    color: #333;
}

.utv-takeaways__list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    color: #2e7d32;
    font-weight: 700;
    font-size: 0.875rem;
}

/* ─── FAQ Schema Accordion ─── */
.utv-faq-block {
    margin: 24px 0;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}

.utv-faq-block__title {
    font-size: 1.125rem;
    font-weight: 700;
    padding: 16px 20px;
    margin: 0;
    background: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
}

.utv-faq-item {
    border-bottom: 1px solid #f0f0f0;
}

.utv-faq-item:last-child {
    border-bottom: none;
}

.utv-faq-item__question {
    display: block;
    width: 100%;
    padding: 14px 20px;
    font-size: 0.9375rem;
    font-weight: 600;
    text-align: left;
    background: #fff;
    border: none;
    cursor: pointer;
    color: #1a1a1a;
    transition: background 0.15s ease;
    position: relative;
    padding-right: 40px;
}

.utv-faq-item__question:hover {
    background: #f8f9fa;
}

.utv-faq-item__question::after {
    content: "+";
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.25rem;
    color: #888;
    font-weight: 300;
}

.utv-faq-item__question[aria-expanded="true"]::after {
    content: "−";
}

.utv-faq-item__answer {
    padding: 0 20px 16px 20px;
    font-size: 0.9375rem;
    line-height: 1.6;
    color: #444;
    display: none;
}

.utv-faq-item__answer.is-open {
    display: block;
}

/* ─── Freshness Banner ─── */
.utv-freshness-banner {
    background: #fff8e1;
    border: 1px solid #ffc107;
    border-radius: 6px;
    padding: 12px 16px;
    margin: 16px 0;
    font-size: 0.875rem;
    color: #6c5300;
    display: flex;
    align-items: center;
    gap: 10px;
}

.utv-freshness-banner__icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.utv-freshness-banner--stale {
    background: #ffebee;
    border-color: #ef5350;
    color: #8b0000;
}

/* ─── Print Styles ─── */
@media print {
    a.utv-entity-link {
        text-decoration: none;
        color: inherit;
    }

    .utv-answer-capsule,
    .utv-takeaways,
    .utv-faq-block {
        box-shadow: none;
        border: 1px solid #ccc;
    }

    .utv-faq-item__answer {
        display: block !important;
    }

    .utv-faq-item__question::after {
        display: none;
    }
}

/* ─── Accessibility ─── */
@media (prefers-reduced-motion: reduce) {
    a.utv-entity-link {
        transition: none;
    }

    .utv-faq-item__question {
        transition: none;
    }
}
