:root {
    --faqc-max-width: 1440;
    --faqc-max-width-absolute: 1440px;
    --faqc-st-t: 0.2s;
    --faqc-st-p: all;
    --faqc-st-e: ease-in-out;
    --faqc-st-d: 0;
    --faqc-standard-transition: var(--faqc-st-t) var(--faqc-st-p) var(--faqc-st-e) var(--faqc-st-d);
    --faqc-selected-item-font-size: 1rem;
    --faqc-border-radius: 0.75rem;
    --faqc-engagement-box-shadow: 0px 5px 15px rgba(51, 51, 51, 0.25);
    --faqc-blue: #3ba8e0;
    --faqc-dark-gray-r: 93;
    --faqc-dark-gray-g: 103;
    --faqc-dark-gray-b: 123;
    --faqc-dark-gray: rgb(var(--faqc-dark-gray-r), var(--faqc-dark-gray-g), var(--faqc-dark-gray-b));
    --faqc-item-question-text-size: clamp(1.125rem, 0.6875rem + 1.4583vw, 2rem);
    --faqc-item-answer-text-size: clamp(1rem, 0.7188rem + 0.9375vw, 1.5625rem);
}
@media(max-width:1440px){
    :root {
        --faqc-engagement-box-shadow: 0px 5px calc((15 / 1440) * 100vw) rgba(51, 51, 51, 0.25);
    }
}

/* faqs block */
section.faqs-section {
    position: relative;
    padding: var(--section-block-padding) 0;
    box-sizing: border-box;
    width: 100vw;
    left: 50%;
    margin-left: -50vw;
    align-items: center;
    justify-content: flex-start;
}
.faqs-block .faq-item-answer,
.faqs-block .faq-item-answer li,
.faqs-block .faq-item-answer h4,
.faqs-block .faq-item-answer p {
    color: var(--faqc-dark-gray);
    font-size: var(--faqc-item-answer-text-size);
    font-weight: 100;
    line-height: calc(var(--faqc-item-answer-text-size) * 1.4);
}
.faqs-block .faq-item-answer h4 {
    font-weight: 400;
    text-decoration: underline;
    margin: var(--faqc-item-answer-text-size) 0;
}
.faqs-block .faq-item-answer p {
    margin-bottom: var(--faqc-item-answer-text-size);
}

.faqs-block .faq-item-answer ul {
    margin-bottom: 35px;
}
.faqs-block .faq-item-answer:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
}
p:last-of-type + ul {
    margin-top: 15px;
}

.faqs-block {
    display: flex;
    flex-direction: column;
    width: 100%;
    flex-grow: 1;
    gap: 0rem;
    max-width:calc(var(--faqc-max-width-absolute) * 0.85);
    align-self: center;
    margin: 0 auto;
}


/* =========================================
   Sea2Soil FAQ Component Styles
   ========================================= */

/* --- 1. Utility & Layout --- */
.hidden { 
    display: none !important; 
}

.faq-wrapper {
    max-width: 800px; /* Adjust container width as needed */
    margin: 0 auto;
    position: relative;
    font-family: inherit; /* Inherit theme font */
    width:100%;
}

/* --- 2. Search Controls --- */
.faq-controls { 
    margin-bottom: 40px; 
    position: relative; 
    z-index: 10; /* Ensure search sits above grid */
}

.search-container { 
    position: relative; 
    width: 100%; 
}

.faq-search-input { 
    width: 100%; 
    padding: 15px; 
    font-size: 18px; 
    border: 1px solid #ccc; 
    border-radius: 4px; 
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.faq-search-input:focus {
    border-color: #0073aa; /* Sea2Soil Focus Color */
    outline: none;
}

/* --- 3. Suggestions Dropdown --- */
.suggestions-panel {
    position: absolute; 
    top: 100%; 
    left: 0; 
    right: 0;
    background: white; 
    border: 1px solid #ddd; 
    border-top: none;
    padding: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1); 
    z-index: 100;
}

.suggestion-group {
    margin-bottom: 10px;
}
.suggestion-group:last-child { margin-bottom: 0; }

.s-label {
    display: block;
    font-size: 12px;
    font-weight: bold;
    color: #888;
    margin-bottom: 5px;
    text-transform: uppercase;
}

.pill {
    background: #eef; 
    border: none; 
    padding: 5px 12px; 
    margin: 0 5px 5px 0; 
    border-radius: 15px; 
    cursor: pointer; 
    font-size: 14px;
    color: #333;
    transition: background 0.2s, color 0.2s;
}

.pill:hover { 
    background: #dde; 
    color: #000;
}

/* --- 4. FAQ Grid Items & Accordion --- */
.faq-grid {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.faq-item {
    background: #fff;
    border: 0.5px solid #f2f2f2;
    overflow: hidden; /* Essential for animation */
    padding: 0 1rem;
    border-radius: 0.5rem;
    transition: background 0.2s;
}
.faq-item:hover {
    background:#f2f2f2;
}

.faq-question {
    padding: 20px 0;
    cursor: pointer;
    font-weight: 600;
    font-size: 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    transition: color 0.2s;
}

.faq-question:hover,
.faq-question.active {
    color: #0073aa; /* Brand Color */
}

.faq-question .icon {
    font-size: 24px;
    font-weight: 300;
    line-height: 1;
    color: #888;
    transition: transform 0.3s ease;
}

/* The Smooth Slide Animation */
.faq-answer {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, opacity 0.3s ease-out;
}

.faq-answer.open {
    opacity: 1;
    /* max-height set via JS */
}

.faq-content-inner {
    padding-bottom: 25px; /* Spacing at bottom of answer */
    color: #555;
    line-height: 1.6;
}

/* --- 5. WYSIWYG Content Formatting --- */
.faq-content-inner p { margin-bottom: 15px; }
.faq-content-inner p:last-child { margin-bottom: 0; }

.faq-content-inner a {
    color: #0073aa;
    text-decoration: underline;
}

.faq-content-inner ul, 
.faq-content-inner ol {
    margin-left: 20px;
    margin-bottom: 15px;
}

.faq-content-inner li { margin-bottom: 5px; }

.faq-content-inner img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 10px 0;
}

/* --- 6. Tags Styling --- */
.tags-row { 
    margin-top: 20px; 
    font-size: 11px; 
    color: #999; 
    text-transform: uppercase; 
    letter-spacing: 0.5px; 
    padding-top: 15px;
    border-top: 1px dashed #eee;
}

.tags-row span { 
    display: inline-block;
    background: #f4f4f4; 
    border: 1px solid #ddd; 
    padding: 3px 8px; 
    border-radius: 3px; 
    margin-right: 6px; 
    margin-bottom: 5px;
}

/* --- 7. Empty State --- */
.faq-empty {
    text-align: center;
    padding: 40px;
    color: #777;
    background: #f9f9f9;
    border-radius: 4px;
}