/* =============================================
   Cubic Promote – Category FAQ
   Loaded only on WooCommerce product category pages.
   Vanilla JS toggle — no jQuery.
   ============================================= */

.rk-category-faq {
    background: #ffffff;
    max-width: 100%;
    margin-bottom: 30px;
}

.rk-faq-intro {
    text-align: center;
    margin-bottom: 20px;
}

h2.rk-faq-heading {
    font-size: 28px;
}

.rk-faq-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    align-items: start;
}

.rk-faq-column {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.rk-faq-item {
    border-bottom: 1px solid #e5e5e5;
}

/* ── Question Row ─────────────────────────────── */

.rk-faq-question {
    cursor: pointer;
    background: transparent;
    padding: 0;
    border: none;
    font-weight: 600;
    font-size: 18px;
    color: #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    width: 100%;
    line-height: 1.4;
    min-height: 50px;
    transition: color 0.2s ease;
}

.rk-faq-question:hover {
    color: #0066cc;
}

.rk-faq-question:focus {
    outline: 2px solid #0066cc;
    outline-offset: 2px;
}

h4.rk-faq-text {
    margin-bottom: 0;
    line-height: 22px;
    flex: 1;
    padding-right: 15px;
}

.rk-faq-text a {
    color: #0066cc;
    text-decoration: none;
}

.rk-faq-text a:hover {
    text-decoration: underline;
}

.rk-faq-icon {
    font-size: 24px;
    font-weight: 300;
    color: #0066cc;
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 10px;
}

/* ── Answer (collapsed by default) ────────────── */

.rk-faq-answer {
    overflow: hidden;
    max-height: 1000px;
    opacity: 1;
    transition: max-height 0.3s ease, opacity 0.3s ease, padding 0.3s ease;
    padding-bottom: 15px;
}

.rk-faq-answer.rk-faq-collapsed {
    max-height: 0;
    opacity: 0;
    padding-bottom: 0;
}

.rk-faq-answer-content {
    padding: 0;
    color: #666;
    font-size: 16px;
    line-height: 1.6;
}

.rk-faq-answer-content a {
    color: #0066cc;
    text-decoration: none;
}

.rk-faq-answer-content a:hover {
    text-decoration: underline;
}

/* ── Responsive ───────────────────────────────── */

@media (min-width: 995px) {
    .rk-faq-text {
        font-size: 1.125rem;
    }
}

@media (max-width: 991px) {
    h2.rk-faq-heading {
        font-size: 24px;
    }
    .rk-faq-text {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .rk-faq-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    h2.rk-faq-heading {
        font-size: 22px;
    }
}

/* ── Content After Listing (ACF WYSIWYG) ──────── */

.cp-category-after-listing {
    max-width: 1200px;
    margin: 40px auto 30px;
    padding: 0 20px;
    font-size: 16px;
    line-height: 1.7;
    color: #333;
}

.cp-category-after-listing h1,
.rk-category-faq h1 {
    font-size: 30px !important;
    line-height: 1.3;
    margin: 0 0 12px;
}

.cp-category-after-listing h2,
.rk-category-faq h2 {
    font-size: 24px !important;
    line-height: 1.3;
    margin: 20px 0 10px;
}

.cp-category-after-listing h3,
.rk-category-faq h3 {
    font-size: 20px !important;
    color: #2b2a2a;
    line-height: 1.4;
    margin: 16px 0 8px;
}

.cp-category-after-listing p,
.rk-category-faq p {
    color: #000;
}

.cp-category-after-listing strong {
    font-weight: 600;
}

@media (max-width: 991px) {
    .cp-category-after-listing h1,
    .rk-category-faq h1 {
        font-size: 26px !important;
    }
    .cp-category-after-listing h2,
    .rk-category-faq h2 {
        font-size: 21px !important;
    }
}

@media (max-width: 768px) {
    .cp-category-after-listing h1,
    .rk-category-faq h1 {
        font-size: 22px !important;
    }
    .cp-category-after-listing h2,
    .rk-category-faq h2 {
        font-size: 19px !important;
    }
}

@media (max-width: 480px) {
    .cp-category-after-listing h1,
    .rk-category-faq h1 {
        font-size: 20px !important;
    }
    .cp-category-after-listing h2,
    .rk-category-faq h2 {
        font-size: 18px !important;
    }
}

.cp-category-after-listing a {
    color: #0066cc;
    text-decoration: none;
}

.cp-category-after-listing a:hover {
    text-decoration: none;
}

.cp-category-after-listing ul,
.cp-category-after-listing ol {
    margin: 0 0 16px 20px;
    padding: 0;
}

.cp-category-after-listing li {
    margin-bottom: 6px;
    line-height: 1.6;
}

.cp-category-after-listing img {
    max-width: 100%;
    height: auto;
    margin: 16px 0;
}
