/* ===================================================
   SEO Product Optimizer Pro - Frontend Styles
   =================================================== */

/* --- Pain Points Banner --- */
.spo-pain-hook {
    background: linear-gradient(135deg, #fff3cd 0%, #ffe8a1 100%);
    border-left: 4px solid #ffc107;
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 20px;
    font-size: 15px;
}
.spo-pain-hook .spo-pain-intro { margin: 0 0 8px; font-size: 16px; }
.spo-pain-hook .spo-pain-list { margin: 0 0 10px 0; padding-left: 4px; list-style: none; }
.spo-pain-hook .spo-pain-list li { padding: 3px 0; color: #555; }
.spo-pain-hook .spo-pain-solution { margin: 0; color: #2e7d32; font-size: 15px; }

/* --- Social Proof Bar --- */
.spo-social-proof-bar {
    display: flex; flex-wrap: wrap; gap: 12px;
    background: #f0f7ff; border-radius: 8px;
    padding: 12px 16px; margin: 16px 0;
    font-size: 14px;
}
.spo-sp-item { display: flex; align-items: center; gap: 4px; color: #333; }

/* --- Urgency Strip --- */
.spo-urgency-strip {
    background: #fff0f0; border: 1px solid #ffcdd2;
    border-radius: 6px; padding: 8px 14px;
    font-size: 13px; color: #c62828;
    display: flex; align-items: center; gap: 8px;
    margin: 8px 0;
}
.spo-live-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: #e53935; display: inline-block;
    animation: spo-pulse 1.5s infinite;
}
@keyframes spo-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.3); }
}

/* --- Urgency Banner (shortcode) --- */
.spo-urgency-banner {
    border-radius: 6px; padding: 10px 16px;
    font-weight: 600; font-size: 14px; margin: 12px 0;
    text-align: center;
}
.spo-urgency-red { background: #ffebee; color: #b71c1c; border: 1px solid #ef9a9a; }
.spo-urgency-green { background: #e8f5e9; color: #1b5e20; border: 1px solid #a5d6a7; }
.spo-urgency-orange { background: #fff3e0; color: #e65100; border: 1px solid #ffcc80; }

/* --- Comparison Table --- */
.spo-comparison-section, .spo-comparison-table { margin: 30px 0; }
.spo-comp-title, .spo-comparison-table h2 {
    font-size: 22px; font-weight: 700;
    text-align: center; margin-bottom: 16px;
}
.spo-comp-table, .spo-comparison-table table {
    width: 100%; border-collapse: collapse;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    border-radius: 10px; overflow: hidden;
}
.spo-comp-table thead tr, .spo-comparison-table thead tr {
    background: linear-gradient(135deg, #1976d2, #1565c0);
    color: #fff;
}
.spo-comp-table th, .spo-comp-table td,
.spo-comparison-table th, .spo-comparison-table td {
    padding: 12px 16px; text-align: center;
    border-bottom: 1px solid #e8eaf6; font-size: 14px;
}
.spo-comp-table td:first-child,
.spo-comparison-table td:first-child { text-align: left; font-weight: 500; }
.spo-comp-ours, .spo-comparison-table td.spo-ours {
    background: #e8f5e9; color: #2e7d32; font-weight: 600;
}
.spo-comp-others, .spo-comparison-table td.spo-others { color: #c62828; }
.spo-comp-table tbody tr:hover { background: #f5f5f5; }

/* --- Related Products Grid --- */
.spo-related-products { margin: 30px 0; }
.spo-related-products h3 { font-size: 20px; margin-bottom: 16px; }
.spo-related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
.spo-related-item a {
    display: block; text-decoration: none; color: inherit;
    border: 1px solid #e0e0e0; border-radius: 8px;
    overflow: hidden; transition: box-shadow .2s, transform .2s;
    text-align: center; padding-bottom: 10px;
}
.spo-related-item a:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.12); transform: translateY(-3px); }
.spo-related-item img { width: 100%; height: 140px; object-fit: cover; }
.spo-rel-name { display: block; font-size: 13px; font-weight: 600; padding: 6px 8px 2px; }
.spo-rel-price { display: block; font-size: 12px; color: #1976d2; }

/* --- See Also Widget --- */
.spo-see-also { background: #f9f9f9; border-radius: 8px; padding: 16px; margin: 20px 0; }
.spo-see-also h4 { margin: 0 0 10px; font-size: 15px; }
.spo-see-also ul { margin: 0; padding: 0; list-style: none; }
.spo-see-also li a { color: #1976d2; text-decoration: none; font-size: 14px; display: block; padding: 4px 0; }
.spo-see-also li a:hover { text-decoration: underline; }

/* --- Internal Links Widget --- */
.spo-internal-links-widget { margin: 20px 0; }
.spo-internal-links-widget h4 { font-size: 16px; margin-bottom: 10px; }
.spo-internal-links-widget ul { padding-left: 0; list-style: none; }
.spo-internal-links-widget li a { color: #1565c0; font-size: 14px; }
.spo-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.spo-pill {
    display: inline-block; background: #e3f2fd; color: #1565c0;
    padding: 5px 12px; border-radius: 20px; font-size: 13px;
    text-decoration: none; transition: background .2s;
}
.spo-pill:hover { background: #bbdefb; }

/* --- Internal links in content --- */
a.spo-internal-link {
    color: #1565c0; text-decoration: underline;
    text-decoration-style: dotted; font-weight: 500;
}
a.spo-internal-link:hover { text-decoration-style: solid; }

/* --- FAQ Accordion --- */
.spo-faq, .spo-faq-vc { margin: 30px 0; }
.spo-faq-title, .spo-faq-heading { font-size: 22px; margin-bottom: 16px; }
.spo-faq-item {
    border: 1px solid #e0e0e0; border-radius: 8px;
    margin-bottom: 10px; overflow: hidden;
}
.spo-faq-q {
    padding: 14px 18px; font-size: 15px; font-weight: 600;
    cursor: pointer; display: flex; justify-content: space-between;
    align-items: center; background: #fafafa; margin: 0;
    transition: background .2s;
}
.spo-faq-q:hover { background: #f0f4ff; }
.spo-faq-toggle, .spo-plus {
    font-size: 20px; color: #1976d2; transition: transform .3s;
}
.spo-faq-a { display: none; padding: 0 18px; }
.spo-faq-a.open, .spo-faq-item.active .spo-faq-a { display: block; padding: 14px 18px; }

/* FAQ Boxed style */
.spo-faq-boxed .spo-faq-item { box-shadow: 0 2px 8px rgba(0,0,0,0.07); }
.spo-faq-minimal .spo-faq-item { border: none; border-bottom: 1px solid #eee; border-radius: 0; }

/* --- SEO Score Widget --- */
.spo-score-widget { text-align: center; }
.spo-circle-svg { width: 100px; height: 100px; }
.spo-grade-label { display: block; font-weight: 600; margin-top: 6px; }
.spo-score-bar-wrap { background: #eee; border-radius: 10px; overflow: hidden; height: 12px; }
.spo-score-bar-fill { height: 100%; border-radius: 10px; transition: width 1s ease; }
.spo-score-num { display: block; font-size: 14px; margin-top: 6px; font-weight: 600; }
.spo-score-badge { border-radius: 6px; padding: 5px 14px; font-size: 15px; font-weight: 700; }
.spo-issues-list { text-align: left; font-size: 13px; margin-top: 10px; }

/* --- Audit Badge (admin preview) --- */
.spo-audit-badge { font-size: 12px; margin-bottom: 10px; }

/* --- Enriched Article Block --- */
.spo-enriched-article, .spo-article-block {
    background: #f9fafb; border-radius: 10px;
    padding: 24px 28px; margin: 30px 0;
    border: 1px solid #e8eaf6;
}

/* --- Pain Banner (WPBakery) --- */
.spo-pain-banner {
    border-radius: 8px; padding: 20px 24px;
    border-left: 5px solid #ffc107; margin: 20px 0;
}
.spo-pain-banner ul { margin: 8px 0; list-style: none; padding: 0; }
.spo-pain-banner li { padding: 3px 0; }
.spo-pain-q { margin: 0 0 10px; font-size: 16px; }
.spo-pain-sol { margin-top: 12px; color: #2e7d32; font-size: 15px; }

/* --- Why Us Tab --- */
.spo-why-us, .spo-product-article { padding: 10px 0; }

/* --- Responsive --- */
@media (max-width: 600px) {
    .spo-related-grid { grid-template-columns: repeat(2, 1fr); }
    .spo-social-proof-bar { gap: 8px; font-size: 12px; }
    .spo-comp-table th, .spo-comp-table td { padding: 8px; font-size: 13px; }
}
