/* 
Theme Name: Hello Elementor Child
Theme URI: https://github.com/elementor/hello-theme-child/
Description: Hello Elementor Child is a child theme of Hello Elementor, created by Elementor team
Author: Elementor Team
Author URI: https://elementor.com/
Template: hello-elementor
Version: 2.0.0
Text Domain: hello-elementor-child
License: GNU General Public License v3 or later.
License URI: https://www.gnu.org/licenses/gpl-3.0.html
Tags: flexible-header, custom-colors, custom-menu, custom-logo, editor-style, featured-images, rtl-language-support, threaded-comments, translation-ready
*/

/* Add your custom styles here */
function custom_preload_fonts() {
    echo '<link rel="preconnect" href="https://fonts.googleapis.com">';
    echo '<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>';
    echo '<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap" rel="stylesheet">';
}
add_action('wp_head', 'custom_preload_fonts');

/* =============================
   Engeman – FAQ Accordion (shortcode [post-faqs])
   ============================= */
.engeman-faqs {
    margin: 2rem auto;
    max-width: 820px;
}

.engeman-faq {
    margin: 0 0 12px 0;
}

.engeman-faq-item {
    border: 1px solid #e5e7eb; /* neutral-200 */
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
}

.engeman-faq-summary {
    cursor: pointer;
    padding: 14px 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Remove default markers */
.engeman-faq-item > summary::-webkit-details-marker { display: none; }
.engeman-faq-item > summary::marker { content: ""; }

/* Indicator */
.engeman-faq-item > summary::after {
    content: "+";
    margin-left: auto;
    color: #6b7280; /* neutral-500 */
    font-weight: 700;
}
.engeman-faq-item[open] > summary::after {
    content: "−"; /* minus */
}

.engeman-faq-summary:focus,
.engeman-faq-summary:focus-visible {
    outline: 2px solid #fafafa; /* blue-600 */
    outline-offset: 2px;
}

.engeman-faq-item .engeman-faq-content {
    max-height: 0;
    overflow: hidden;
    padding: 0 16px 0 16px;
    transition: max-height 300ms ease, padding 300ms ease;
}

.engeman-faq-item[open] .engeman-faq-content {
    max-height: 1000px; /* suficientemente alto para conteúdo comum */
    padding: 0 16px 16px 16px;
    transition: cubic-bezier(0.165, 0.84, 0.44, 1);
}

.engeman-faq-answer p { margin: 0 0 0.75rem 0; }
.engeman-faq-answer ul, .engeman-faq-answer ol { margin: 0.5rem 0 0.75rem 1.25rem; }

/* Small screens */
@media (max-width: 480px) {
    .engeman-faq-summary { padding: 12px 14px; }
    .engeman-faq-item[open] .engeman-faq-content { padding: 0 14px 14px 14px; }
}

/* Respeita usuários com preferência por movimento reduzido */
@media (prefers-reduced-motion: reduce) {
    .engeman-faq-item .engeman-faq-content {
        transition: none;
    }
}
