/* ==========================================================================
   ITGI Query FAQ Component Styles (Policybazaar Theme - Smooth Transitions)
   ========================================================================== */

.itgi-query-faq-type-wrapper {
    padding: 35px 16px;
    font-family: inherit;
    background-color: #ffffff;
}

.itgi-query-faq-type-container {
    max-width: 1000px;
    margin: 0 auto;
}

/* Header Row */
.itgi-query-faq-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 30px;
}

.itgi-query-faq-type-title {
    font-size: 28px;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
    line-height: 1.3;
}

.itgi-query-faq-top-image {
    max-width: 50px;
    max-height: 50px;
    flex-shrink: 0;
}

.itgi-query-faq-top-image img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

/* List Container */
.itgi-query-faq-type-list {
    display: flex;
    flex-direction: column;
}

/* Flat Item with 24px Padding (Increased from 18px) */
.itgi-query-faq-type-item {
    border-bottom: 1px solid #eaeff5;
    padding: 24px 0; /* Updated to 24px */
    transition: padding 0.3s ease;
}

.itgi-query-faq-type-item:first-child {
    border-top: 1px solid #eaeff5;
}

/* Header / Question Trigger */
.itgi-query-faq-type-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
    gap: 16px;
}

.itgi-query-faq-type-question {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
    margin: 0;
    flex: 1;
    line-height: 1.45;
    transition: color 0.3s ease;
}

/* Q: Prefix Styling */
.itgi-faq-q-prefix {
    color: #0066ff;
    font-weight: 700;
    margin-right: 6px;
}

/* Highlight Question in Blue when Expanded */
.itgi-query-faq-type-item.is-faq-expanded .itgi-query-faq-type-question {
    color: #0066ff;
}

/* Toggle Icon Holder with Smooth Rotation */
.itgi-query-faq-type-toggle {
    font-size: 24px; /* Updated to 24px */
    font-weight: 400;
    color: #0066ff;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.itgi-faq-toggle-icon {
    display: inline-block;
    line-height: 1;
    transition: opacity 0.25s ease, transform 0.3s ease;
}

.itgi-faq-toggle-icon.plus-icon {
    opacity: 1;
    transform: rotate(0deg);
}

.itgi-faq-toggle-icon.minus-icon {
    position: absolute;
    opacity: 0;
    transform: rotate(-90deg);
}

/* Smooth Icon Animation when Expanded */
.itgi-query-faq-type-item.is-faq-expanded .itgi-query-faq-type-toggle {
    transform: rotate(180deg);
}

.itgi-query-faq-type-item.is-faq-expanded .itgi-faq-toggle-icon.plus-icon {
    opacity: 0;
    transform: rotate(90deg);
}

.itgi-query-faq-type-item.is-faq-expanded .itgi-faq-toggle-icon.minus-icon {
    opacity: 1;
    transform: rotate(0deg);
}

/* Answer Drawer with Smooth Opacity & Slide Transition */
.itgi-query-faq-type-drawer {
    display: none;
    margin-top: 14px;
    opacity: 0;
    transform: translateY(-6px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.itgi-query-faq-type-item.is-faq-expanded .itgi-query-faq-type-drawer {
    opacity: 1;
    transform: translateY(0);
}

/* Answer Content Row */
.itgi-query-faq-type-content {
    display: flex;
    gap: 8px;
    font-size: 15px;
    line-height: 1.65;
    color: #475569;
}

/* Ans: Prefix Styling */
.itgi-faq-ans-prefix {
    font-weight: 700;
    color: #334155;
    flex-shrink: 0;
}

.itgi-faq-ans-text {
    flex: 1;
}

.itgi-faq-ans-text p {
    margin: 0 0 10px 0;
}

.itgi-faq-ans-text p:last-child {
    margin: 0;
}

/* Mobile Responsiveness */
@media (max-width: 576px) {
    .itgi-query-faq-type-item {
        padding: 18px 0;
    }

    .itgi-query-faq-type-question {
        font-size: 15px;
    }

    .itgi-query-faq-type-content {
        font-size: 14px;
    }

    .itgi-query-faq-type-title {
        font-size: 22px;
    }
}