/* Page-specific styles for /faq. Base FAQ styles live in style-homepage-gwp.css. */

/* Safety net: keep any wide child (long question, overflowing pill row) from
   forcing a horizontal scrollbar on the page. The pill row keeps its own
   overflow-x:auto so it can still scroll internally. */
.gwp-faq.gwp-faq--redesign { overflow-x: hidden; }

.gwp-faq--redesign .gwp-faq__question,
.gwp-faq--redesign .gwp-faq__answer,
.gwp-faq--redesign .gwp-faq__answer p,
.gwp-faq--redesign .gwp-faq__answer li {
    overflow-wrap: anywhere;
    word-break: break-word;
}

/* Restore paragraph rhythm inside multi-paragraph answers — the shared
   .gwp-faq__answer rules zero all p margins for single-paragraph use. */
.gwp-faq__answer p + p,
.gwp-faq__answer ul + p,
.gwp-faq__answer p + ul {
    margin-top: 12px !important;
}

.gwp-faq__answer ul {
    margin: 12px 0;
    padding-left: 22px;
    list-style: disc;
}

.gwp-faq__answer ul li {
    margin-bottom: 6px;
    line-height: 1.6;
}

.gwp-faq__answer ul li:last-child {
    margin-bottom: 0;
}

.gwp-faq__subtitle {
    max-width: 640px;
    margin-top: 16px !important;
    font-family: var(--gwp-font-body);
    font-weight: 400;
    font-size: var(--gwp-fs-md);
    line-height: 26px;
    color: #6b7280;
}

@media (max-width: 575px) {
    .gwp-faq__subtitle { font-size: 14px; line-height: 22px; }
}

.gwp-faq__tabs {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin: 30px auto 10px;
    max-width: 100%;
    padding: 0 12px;
    box-sizing: border-box;
}

.gwp-faq__nav {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #f0f4fe;
    border: 1px solid #585fbe;
    color: #585fbe;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease, opacity 0.15s ease;
}

.gwp-faq__nav:hover:not(:disabled),
.gwp-faq__nav:focus-visible:not(:disabled) {
    background: #31356e;
    border-color: #31356e;
    color: #fff;
}

.gwp-faq__nav:disabled {
    background: #f5f7fc;
    border-color: #d6dbe8;
    color: #b3b8c9;
    cursor: not-allowed;
}

.gwp-faq__tabs-wrap {
    display: flex;
    flex-wrap: nowrap;
    gap: 18px;
    align-items: center;
    background: #f0f4fe;
    border-radius: 60px;
    padding: 15px 0 15px 15px;
    width: fit-content;
    max-width: 100%;
    min-width: 0;
    flex: 0 1 auto;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
}

/* Browsers drop padding-right on horizontally-scrollable flex containers,
   so we zero it out and put the right inset on the last pill instead. */
.gwp-faq__tabs-wrap > .gwp-faq__tab:last-child {
    margin-right: 15px;
}

.gwp-faq__tabs-wrap::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.gwp-faq__tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    height: 65px;
    padding: 20px 30px;
    border-radius: 60px;
    background: #f0f4fe;
    border: 1px solid #585fbe;
    color: #585fbe;
    font-family: var(--gwp-font-title);
    font-weight: 500;
    font-size: 16px;
    line-height: 23px;
    text-transform: capitalize;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.gwp-faq__tab:hover {
    color: #31356e;
    border-color: #31356e;
}

.gwp-faq__tab.is-active {
    background: #31356e;
    border-color: #e1eaff;
    color: #fff;
    font-weight: 700;
}

.gwp-faq__tab-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    font-size: 18px;
    line-height: 1;
    flex-shrink: 0;
}

.gwp-faq__helper {
    margin-top: 24px !important;
    margin-bottom: 24px !important;
    padding: 0 12px;
    font-family: var(--gwp-font-body);
    font-weight: 400;
    font-size: var(--gwp-fs-base);
    line-height: 22px;
    color: #6b7280;
    text-align: center;
}

.gwp-faq__helper + .gwp-faq__list {
    margin-top: 0 !important;
}

.gwp-faq__helper .bi-info-circle {
    display: inline-block;
    margin-right: 8px;
    vertical-align: middle;
    font-size: 16px;
    color: #9aa3b2;
    line-height: 1;
}

.gwp-faq__helper-link {
    color: #585fbe;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.gwp-faq__helper-link:hover,
.gwp-faq__helper-link:focus {
    color: #31356e;
}

@media (max-width: 991px) {
    .gwp-faq__tabs { margin: 24px auto 8px; padding: 4px 12px 8px; gap: 8px; }
    .gwp-faq__tabs-wrap { border-radius: 40px; padding: 10px 0 10px 10px; gap: 10px; }
    .gwp-faq__tabs-wrap > .gwp-faq__tab:last-child { margin-right: 10px; }
    .gwp-faq__tab { height: 52px; padding: 14px 22px; font-size: 14px; }
    .gwp-faq__tab-icon { font-size: 16px; margin-right: 8px; }
    .gwp-faq__nav { width: 38px; height: 38px; font-size: 16px; }
}

@media (max-width: 575px) {
    .gwp-faq__tabs { gap: 6px; padding: 4px 8px 8px; }
    .gwp-faq__tab { height: 46px; padding: 12px 18px; font-size: 13px; }
    .gwp-faq__nav { width: 34px; height: 34px; font-size: 15px; }
}
