﻿.hp-bg-canvas {
    position: relative;
    isolation: isolate;
}

    .hp-bg-canvas::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        height: var(--bg-height, 900px);
        background-image: var(--hero-bg-image);
        background-size: cover;
        background-position: top;
        background-repeat: no-repeat;
        z-index: -1;
        -webkit-mask-image: linear-gradient(to bottom, black 82%, transparent 100%);
        mask-image: linear-gradient(to bottom, black 82%, transparent 100%);
    }

.if-services {
    background: #EDEEEF;
    color: #111111;
    max-width: none;
    padding: clamp(64px, 10vh, 130px) clamp(20px, 4.5vw, 72px) clamp(72px, 11vh, 140px);
}

.sa-services {
    max-width: 1400px;
    margin: 0 auto;
}

.if-services__title-container {
    text-align: left;
    max-width: 100%;
    margin: 0;
}

.if-services__title {
    margin: 0;
    font-size: clamp(28px, 3.6vw, 52px);
    font-weight: 600;
    line-height: 1.04;
    letter-spacing: -0.042em;
    color: var(--color-brand);
    text-align: center;
}

.if-services__head {
    text-align: left;
    max-width: 1000px;
    margin: clamp(22px, 3vh, 36px) auto 0;
    border-radius: 20px;
    border: 1px solid rgba(87, 28, 42, 0.16);
    background: #ffffff;
    overflow: hidden;
}

.dep-info {
    text-align: left;
    max-width: 100%;
}

.dep-info__toggle-all {
    width: 100%;
    background: none;
    border: 0;
    padding: clamp(18px, 2.4vw, 26px) clamp(20px, 2.8vw, 32px);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    text-align: left;
    font-family: inherit;
}

.dep-info__toggle-all-label {
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.012em;
    color: var(--color-brand);
}

.dep-info__toggle-all-icon {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    color: rgba(87, 28, 42, 0.6);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transform: none;
}

    .dep-info__toggle-all-icon svg {
        width: 16px;
        height: 16px;
    }

.dep-info__toggle-all[aria-expanded="true"] .dep-info__toggle-all-icon {
    transform: rotate(180deg);
}

.dep-info__body {
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.55s cubic-bezier(.16, 1, .3, 1);
}

.dep-info__body-inner {
    padding: clamp(4px, 1vw, 8px) clamp(20px, 2.8vw, 32px) clamp(20px, 2.6vw, 28px);
    display: flex;
    flex-direction: column;
    gap: 12px;
    font-size: 14.5px;
    line-height: 1.72;
    color: rgba(17, 17, 17, 0.7);
}

    .dep-info__body-inner p {
        margin: 0;
        font-size: 14.5px;
        line-height: 1.72;
        color: rgba(17, 17, 17, .7);
        text-wrap: pretty;
    }

.dep-info__divider {
    display: block;
    height: 1px;
    background: rgba(87, 28, 42, 0.14);
    margin: 6px 0;
}

.dep-info__subheading {
    font-size: 15px !important;
    font-weight: 600 !important;
    letter-spacing: -.012em;
    color: var(--color-brand) !important;
}

.dep-info__body-inner ol {
    margin: 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    counter-reset: dep-info-counter;
}

    .dep-info__body-inner ol li {
        counter-increment: dep-info-counter;
        display: grid;
        grid-template-columns: auto minmax(0, 1fr);
        gap: 14px;
        align-items: baseline;
        padding: 11px 0;
        border-top: 1px solid rgba(87, 28, 42, .14);
        font-size: 14.5px;
        line-height: 1.6;
        color: rgba(17, 17, 17, .78);
    }

        .dep-info__body-inner ol li::before {
            content: counter(dep-info-counter, decimal-leading-zero);
            font-size: 11px;
            font-weight: 500;
            letter-spacing: .12em;
            color: rgba(87, 28, 42, .65);
        }

.dep-filters-panel .dep-filters#depFilters {
    grid-template-columns: repeat(5, minmax(0, 1fr)) auto;
}

.dep-filters-panel .dep-filter__input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.dep-filters-panel .dep-filter__input {
    width: 100%;
    min-width: 0;
    min-height: 50px;
    padding: 13px 64px 13px 20px;
    background: #ffffff;
    border: 1px solid rgba(87, 28, 42, 0.42);
    border-radius: 999px;
    font-size: 14.5px;
    font-weight: 450;
    color: var(--color-brand);
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.3s, box-shadow 0.3s;
}

input:-internal-autofill-selected {
    background: #ffffff;
}

.dep-filters-panel .dep-filter__input:hover,
.dep-filters-panel .dep-filter__input:focus {
    border-color: var(--color-brand);
}

    .dep-filters-panel .dep-filter__input:focus-visible {
        box-shadow: 0 0 0 3px rgba(87, 28, 42, 0.12);
    }

.dep-filters-panel .dep-filter__icon {
    position: absolute;
    right: 20px;
    font-size: 13.5px;
    font-weight: 600;
    pointer-events: none;
}

.filter-label__required {
    color: #B3261E
}

.dep-filter__input-wrap.dep-filter--error .dep-filter__input {
    border-color: #c0392b;
}

.hp-select-wrap.dep-filter--error .hp-custom-select__trigger {
    border-color: #c0392b;
}

/* Results */
.dep-results-wrap {
    position: relative;
}

.dep-results {
    margin-top: clamp(18px, 2.6vh, 28px);
    display: flex;
    flex-direction: column;
    gap: clamp(10px, 1.4vw, 16px);
}

    .dep-results[hidden] {
        display: none;
    }

/* The card owns the columns; the main row and the stats row below it share them (subgrid), so the three stats sit
   under the bank, the interest rate and the term. */
.dep-row {
    display: grid;
    grid-template-columns: 44px minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr) auto;
    column-gap: clamp(12px, 1.8vw, 26px);
    border-radius: 18px;
    border: 1px solid rgba(87, 28, 42, 0.32);
    background: #ffffff;
    padding: clamp(14px, 1.6vw, 20px) clamp(16px, 2vw, 26px);
    transition: border-color 0.35s ease, box-shadow 0.35s ease;
    box-sizing: border-box;
}

    .dep-row:hover {
        border-color: rgba(87, 28, 42, 0.55);
        box-shadow: 0 14px 34px -18px rgba(87, 28, 42, 0.28);
    }

.dep-row__main {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: subgrid;
    gap: clamp(12px, 1.8vw, 26px);
    align-items: center;
}

.dep-row__logo-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 40px;
    padding: 4px;
    border-radius: 9px;
    background: rgba(87, 28, 42, 0.06);
    box-sizing: border-box;
}

    .dep-row__logo-box img {
        display: block;
        max-width: 36px;
        max-height: 30px;
        width: auto;
        height: auto;
        object-fit: contain;
    }

.dep-row__bank-info {
    min-width: 0;
}

.dep-row__bank-name {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.014em;
    color: var(--color-brand);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dep-row__bank-type {
    margin: 4px 0 0;
    font-size: 14px;
    font-weight: 450;
    color: rgba(87, 28, 42, 0.78);
}

.dep-row__col {
    min-width: 0;
}

.dep-row__col-label {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-brand);
}

.dep-row__col-value {
    margin: 4px 0 0;
    font-size: 14px;
    font-weight: 450;
    color: rgba(87, 28, 42, 0.78);
}

.dep-row__details-btn.hp-btn {
    justify-self: end;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    border: 1px solid rgba(87, 28, 42, 0.42);
    border-radius: 999px;
    background: #ffffff;
    padding: 11px 24px;
    min-height: 44px;
    font-size: 13.5px;
    font-weight: 450;
    color: var(--color-brand);
    white-space: nowrap;
    cursor: pointer;
    transition: background 0.3s, transform 0.35s cubic-bezier(.34, 1.56, .64, 1);
    transform: none;
}

    .dep-row__details-btn.hp-btn:hover {
        background: rgba(87, 28, 42, 0.06);
    }

    .dep-row__details-btn.hp-btn:active {
        transform: scale(0.97);
    }

.dep-row__stats {
    margin-top: clamp(12px, 1.4vw, 16px);
    padding-top: clamp(12px, 1.4vw, 16px);
    border-top: 1px solid rgba(87, 28, 42, 0.14);
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: subgrid;
    gap: clamp(12px, 1.8vw, 26px);
}

.dep-stat {
    position: relative;
    min-width: 0;
}

    /* Gross interest under the bank name, net under the interest rate, maturity under the term. */
    .dep-row__stats .dep-stat:nth-child(1) {
        grid-column: 2;
    }

    .dep-row__stats .dep-stat:nth-child(2) {
        grid-column: 3;
    }

    .dep-row__stats .dep-stat:nth-child(3) {
        grid-column: 4;
    }

.dep-stat__label {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 450;
    color: rgba(87, 28, 42, 0.7);
}

    .dep-stat__label > span:first-child {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

.dep-row__stats .dep-stat:last-child .dep-stat__tooltip {
    left: auto;
    right: 0;
}

.dep-stat__value {
    margin: 4px 0 0;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.014em;
    color: var(--color-brand);
}

.dep-stat__info {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    padding: 0;
    border: 1px solid rgba(87, 28, 42, 0.4);
    border-radius: 50%;
    background: none;
    color: rgba(87, 28, 42, 0.7);
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.25s, color 0.25s;
}

    .dep-stat__info:hover {
        border-color: var(--color-brand);
        color: var(--color-brand);
    }

.dep-stat__tooltip {
    white-space: normal;
    display: none;
    position: absolute;
    bottom: calc(100% + 10px);
    left: 0;
    width: min(280px, 72vw);
    background: var(--color-brand);
    color: #ffffff;
    border-radius: 14px;
    padding: 14px 16px;
    font-size: 12.5px;
    line-height: 1.6;
    box-shadow: 0 24px 54px -26px rgba(17, 17, 17, 0.5);
    z-index: 40;
    text-align: left;
}

.dep-stat__info:hover + .dep-stat__tooltip,
.dep-stat__info:focus-visible + .dep-stat__tooltip,
.dep-stat--open .dep-stat__tooltip {
    display: block;
    animation: dp-fade 0.25s ease both;
}

.dep-empty {
    margin-top: clamp(18px, 2.6vh, 28px);
    border-radius: 22px;
    border: 1px dashed rgba(87, 28, 42, 0.3);
    background: rgba(87, 28, 42, 0.03);
    padding: clamp(28px, 4vw, 52px);
    text-align: center;
}

.dep-results > .dep-empty {
    margin-top: 0;
}

.dep-empty__title {
    margin: 0;
    font-size: clamp(17px, 1.7vw, 21px);
    font-weight: 600;
    letter-spacing: -0.024em;
    color: var(--color-brand);
}

.dep-more-btn.hp-btn {
    align-self: center;
    margin-top: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    background: var(--color-brand);
    color: #ffffff;
    border: 0;
    border-radius: 999px;
    padding: 14px 38px;
    min-height: 48px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s, transform 0.35s cubic-bezier(.34, 1.56, .64, 1);
}

    .dep-more-btn.hp-btn:hover {
        background: #4a1723;
    }

    .dep-more-btn.hp-btn:active {
        transform: scale(0.97);
    }

.dep-loader {
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    padding: 32px 0;
}

    .dep-loader[hidden] {
        display: none;
    }

.dep-loader__spinner {
    width: 30px;
    height: 30px;
    border: 3px solid rgba(87, 28, 42, 0.15);
    border-top-color: var(--color-brand);
    border-radius: 50%;
    animation: dep-spin 0.7s linear infinite;
}

/* Details modal */
.dep-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(16px, 4vw, 48px);
}

    .dep-modal[hidden] {
        display: none;
    }

.dep-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(24, 10, 16, 0.55);
    -webkit-backdrop-filter: blur(3px);
    backdrop-filter: blur(3px);
}

.dep-modal__panel {
    position: relative;
    background: #ffffff;
    color: #111111;
    border-radius: 20px;
    max-width: 560px;
    width: 100%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 40px 90px -40px rgba(17, 17, 17, 0.6);
    animation: dp-pop 0.3s cubic-bezier(.16, 1, .3, 1) both;
}

.dep-modal__body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    /* Without this the body grows to its content height and the list never scrolls. */
    min-height: 0;
}

.dep-modal__header {
    padding: clamp(24px, 3vw, 32px) clamp(24px, 3vw, 32px) clamp(18px, 2.2vw, 24px);
}

.dep-modal__logo-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 52px;
    padding: 8px 14px;
    border-radius: 10px;
    background: rgba(87, 28, 42, 0.07);
    box-sizing: border-box;
}

    .dep-modal__logo-box .dep-modal__bank-logo {
        display: block;
        max-width: 78px;
        max-height: 36px;
        width: auto;
        height: auto;
        object-fit: contain;
    }

.dep-modal__bank-name {
    margin: 18px 0 0;
    font-weight: 600;
    font-size: 19px;
    letter-spacing: -0.02em;
    color: var(--color-brand);
}

.dep-modal__deposit-name {
    margin: 6px 0 0;
    font-size: 15px;
    font-weight: 450;
    color: rgba(87, 28, 42, 0.8);
}

.dep-modal__body a {
    color: var(--color-brand);
}

.dep-modal__close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    font-size: 20px;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    color: rgba(17, 17, 17, 0.6);
    border-radius: 50%;
    transition: background 0.25s, color 0.25s;
}

    .dep-modal__close:hover {
        color: #000;
        background: rgba(87, 28, 42, 0.06);
    }

.dep-details {
    display: flex;
    flex-direction: column;
    gap: 18px;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    border-top: 1px solid rgba(87, 28, 42, 0.12);
    padding: clamp(20px, 2.6vw, 26px) clamp(24px, 3vw, 32px);
    scrollbar-width: thin;
    scrollbar-color: rgba(87, 28, 42, 0.4) transparent;
}

    .dep-details::-webkit-scrollbar {
        width: 8px;
    }

    .dep-details::-webkit-scrollbar-thumb {
        background: rgba(87, 28, 42, 0.4);
        border-radius: 4px;
    }

.dep-details__attr {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
}

.dep-details__attr-label {
    margin: 0;
    font-size: 14.5px;
    font-weight: 600;
    color: var(--color-brand);
}

.dep-details__attr-value {
    margin: 0;
    font-size: 14.5px;
    text-align: right;
    color: rgba(87, 28, 42, 0.85);
    overflow-wrap: anywhere;
}

.dep-details__attr--block {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
}

    .dep-details__attr--block .dep-details__attr-value {
        font-size: 13px;
        line-height: 1.5;
        text-align: left;
    }

.dep-details__rate {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 0;
    font-size: 14px;
    line-height: 1.6;
}

    .dep-details__rate + .dep-details__rate {
        border-top: 1px solid rgba(87, 28, 42, 0.08);
    }

.dep-details__rate-term {
    color: rgba(87, 28, 42, 0.85);
}

.dep-details__rate-value {
    font-weight: 600;
    color: var(--color-brand);
    text-align: right;
}

.dep-details__plan-term {
    margin: 8px 0 2px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-brand);
}

    .dep-details__plan-term:last-child {
        margin-top: 6px;
        font-size: 12.5px;
        font-weight: 450;
        color: rgba(87, 28, 42, 0.6);
    }

.dep-details__choices {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 18px;
}

.dep-details__choice {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.dep-details__radio {
    flex: 0 0 auto;
    width: 15px;
    height: 15px;
    border: 1.5px solid rgba(87, 28, 42, 0.4);
    border-radius: 50%;
}

.dep-details__choice--on .dep-details__radio {
    border-color: var(--color-brand);
    background: var(--color-brand);
    box-shadow: inset 0 0 0 3px #fff;
}

.dep-details__choice--on .dep-details__choice-name {
    color: rgba(87, 28, 42, 0.85);
}

.dep-details__choice-name {
    font-size: 13.5px;
    font-weight: 450;
    color: rgba(87, 28, 42, 0.55);
}

.dep-details__source {
    align-self: flex-start;
    margin-top: 4px;
    font-size: 14px;
    color: var(--color-brand);
    border-bottom: 1px solid rgba(87, 28, 42, 0.45);
    text-decoration: none;
    transition: color 0.25s;
}

    .dep-details__source:hover {
        color: #4a1723;
    }

body.dep-modal-open {
    overflow: hidden;
}

.services-note {
    margin: clamp(20px, 2.8vh, 30px) 0 0;
    font-size: 12.5px;
    line-height: 1.6;
    color: rgba(17, 17, 17, .55);
    text-wrap: pretty;
}

.dep-filters-panel :focus-visible,
.dep-results-wrap :focus-visible,
.dep-modal :focus-visible,
.dep-info :focus-visible {
    outline: 2px solid var(--color-brand);
    outline-offset: 3px;
    border-radius: 2px;
}

.dep-filters-panel .dep-filter__input:focus-visible,
.dep-filters-panel select.dep-filter__select:focus-visible,
.dep-filters-panel .hp-custom-select__trigger:focus-visible,
.dep-filters-panel .dep-radio-select__trigger:focus-visible,
.dep-filters-panel .dep-bank-select__trigger:focus-visible,
.dep-filters-panel .dep-sort__trigger:focus-visible,
.dep-filters-panel .dep-search-btn.hp-btn:focus-visible {
    border-radius: 999px;
}

.dep-filters-panel .dep-filter__input:focus-visible {
    outline: none;
}

.dep-row__details-btn.hp-btn:focus-visible,
.dep-more-btn.hp-btn:focus-visible,
.dep-info-icon__btn:focus-visible,
.dep-modal__close:focus-visible {
    border-radius: 999px;
}

.dep-notice {
    margin-top: clamp(18px, 2.6vh, 28px);
    display: flex;
    align-items: flex-start;
    gap: 14px;
    border-radius: 16px;
    border: 1px solid rgba(87, 28, 42, 0.22);
    background: rgba(87, 28, 42, 0.05);
    padding: clamp(14px, 1.8vw, 20px) clamp(16px, 2vw, 22px);
    animation: dp-fade 0.35s ease both;
}

    .dep-notice[hidden] {
        display: none;
    }

.dep-notice__icon {
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--color-brand);
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    font-style: italic;
    line-height: 1;
}

.dep-notice > span:last-child {
    margin: 0;
    font-size: 13.5px;
    line-height: 1.62;
    color: rgba(87, 28, 42, 0.9);
    text-wrap: pretty;
}

@keyframes dp-pop {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes dp-fade {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes dep-spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes dep-pulse-reduced {
    0%, 100% {
        opacity: 0.35;
    }

    50% {
        opacity: 1;
    }
}

/* Responsive */
@media (max-width: 1340px) {
    .dep-filters-panel .dep-filters#depFilters {
        grid-template-columns: repeat(3, minmax(0px, 1fr));
    }
}

@media (max-width: 1080px) {
    .dep-row {
        grid-template-columns: 44px minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
    }

    .dep-row__details-btn.hp-btn {
        grid-column: 1 / -1;
    }
}

@media (max-width: 991px) {
    .dep-filters-panel .dep-filters#depFilters {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 700px) {
    /* Stacked: the rows no longer share columns. */
    .dep-row {
        display: block;
    }

    .dep-row__main {
        grid-template-columns: 44px minmax(0, 1fr);
    }

    .dep-row__stats .dep-stat:nth-child(n) {
        grid-column: auto;
    }

    .dep-row__col {
        grid-column: 1 / -1;
    }

    .dep-row__details-btn.hp-btn {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .dep-row__stats {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .dep-filters-panel .dep-filters#depFilters {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 480px) {
    .dep-modal__header {
        padding: 24px 20px 16px;
    }

    .dep-details {
        padding: 18px 20px;
    }

    .dep-details__attr {
        gap: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .dep-filters-panel *,
    .dep-results-wrap *,
    .dep-modal,
    .dep-modal *,
    .dep-info * {
        animation: none !important;
        transition: none !important;
    }

    .dep-results-wrap .dep-loader__spinner {
        animation: dep-pulse-reduced 1.6s ease-in-out infinite !important;
        border-color: rgba(87, 28, 42, 0.15);
        border-top-color: rgba(87, 28, 42, 0.15);
    }
}
