/* ============================================================
   Infrastructure Marketplace — /investments page
   ============================================================ */

.infra-mkt {
    background: #fff;
    width: 100%;
    padding: 64px 0;
}

.infra-mkt__inner {
    max-width: 1290px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: clamp(32px, 7vw, 101px);
}

/* ── Title ── */
.infra-mkt__title {
    color: var(--Primary-Text, #040548);
    font-family: 'Inter', sans-serif;
    font-size: 30px;
    font-style: normal;
    font-weight: 600;
    line-height: normal;
    margin: 0;
}

/* ── Cards row ── */
.infra-mkt__cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 27px;
    width: 100%;
}

@media (max-width: 1100px) {
    .infra-mkt__cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .infra-mkt__cards {
        grid-template-columns: 1fr;
    }
}

/* ── Single card ── */
.infra-mkt__card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    max-width: 409px;
    border-radius: 25px;
    overflow: hidden;
}

/* ── Card image ── */
/* height = 268 − 87 (overlap removed) = 181px */
.infra-mkt__card-image {
    height: 188px;
    flex-shrink: 0;
    align-self: stretch;
    border-radius: 25px 25px 0 0;
    background-color: lightgray;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

/* ── Card body ── */
.infra-mkt__card-body {
    display: flex;
    height: 469px;
    flex-direction: column;
    align-items: flex-start;
    gap: 33px;
    flex-shrink: 0;
    align-self: stretch;
    border-radius: 0 0 25px 25px;
    border: 1px solid #E0E0E0;
    background: var(--Background-color, #FFF);
    padding: 20px 16px 18px;
    box-sizing: border-box;
}

/* ── Header: name + badge ── */
.infra-mkt__card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    align-self: stretch;
    gap: 8px;
}

.infra-mkt__card-name {
    color: var(--Primary-Text, #040548);
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.infra-mkt__badge {
    display: flex;
    height: 30px;
    min-width: 106px;
    padding: 5px 16px;
    justify-content: center;
    align-items: center;
    border-radius: 39.36px;
    background: rgba(225, 29, 111, 0.98);
    color: #fff;
    text-align: center;
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
    white-space: nowrap;
    flex-shrink: 0;
}

/* ── Description ── */
.infra-mkt__desc {
    color: var(--Secondary-Text, #334155);
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
    align-self: stretch;
    margin: 0;
}

/* ── Stats ── */
.infra-mkt__stats {
    display: flex;
    flex-direction: column;
    align-self: stretch;
    margin: 0 -16px;
}

.infra-mkt__stat-row {
    display: flex;
    height: 51px;
    padding: 8px 16px;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    align-self: stretch;
    border-bottom: 1px solid var(--Borders, #E0E0E0);
    box-sizing: border-box;
}

.infra-mkt__stat-inner {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
}

.infra-mkt__stat-label {
    color: var(--Secondary-Text, #334155);
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 150%;
}

.infra-mkt__stat-value {
    color: #040548;
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 600;
    line-height: 150%;
}

/* ── CTA ── */
.infra-mkt__cta {
    display: flex;
    padding: 0 0 0 18px;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    align-self: stretch;
    margin-top: auto;
}

.infra-mkt__btn-outline {
    display: flex;
    height: 48px;
    padding: 7.872px 15.744px;
    justify-content: space-between;
    align-items: center;
    align-self: stretch;
    border-radius: 34.44px;
    border: 1px solid #0A070A;
    background: transparent;
    cursor: pointer;
    gap: 8px;
}

.infra-mkt__btn-outline span {
    color: #040548;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
}

.infra-mkt__btn-outline svg {
    flex-shrink: 0;
}

.infra-mkt__btn-dark {
    display: flex;
    height: 48px;
    padding: 7.801px 15.602px;
    justify-content: center;
    align-items: center;
    gap: 9.751px;
    align-self: stretch;
    border-radius: 35px;
    background: rgba(5, 1, 5, 0.98);
    border: none;
    cursor: pointer;
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
}

/* ============================================================
   Marketplace Payment Modals
   ============================================================ */

.infra-mkt__modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(4, 5, 72, 0.4);
    backdrop-filter: blur(4px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.infra-mkt__modal-overlay.active {
    display: flex;
}

.infra-mkt__modal {
    display: inline-flex;
    height: 655px;
    /* Adjusting height for content flexibility */
    max-height: 90vh;
    /* Responsive fallback */
    overflow-y: auto;
    padding: 24px 0;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    border-radius: 25px;
    border: 1px solid var(--Card-Border, rgba(226, 232, 240, 0.98));
    background: #FFF;
    width: 100%;
    max-width: 530px;
    box-sizing: border-box;
}

.infra-mkt__modal-header {
    display: flex;
    min-height: 60px;
    padding: 16px 24px;
    align-items: flex-start;
    gap: 10px;
    align-self: stretch;
    border-bottom: 1px solid var(--Card-Border, rgba(226, 232, 240, 0.98));
}

.infra-mkt__modal-title {
    color: #040548;
    font-family: 'Inter', sans-serif;
    font-size: 22px;
    font-style: normal;
    font-weight: 600;
    line-height: normal;
    margin: 0;
}

.infra-mkt__modal-desc {
    color: var(--Secondary-Text, #334155);
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    padding: 0 24px;
    align-self: flex-start;
    margin: 0;
}

.infra-mkt__modal-form {
    display: flex;
    padding: 0 24px;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    align-self: stretch;
    width: 100%;
    box-sizing: border-box;
}

.infra-mkt__form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.infra-mkt__form-label {
    color: var(--Secondary-Text, #334155);
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
}

.infra-mkt__form-input {
    display: flex;
    padding: 10px 12px;
    align-items: center;
    align-self: stretch;
    border-radius: 8px;
    border: 1px solid var(--Borders, #E0E0E0);
    width: 100%;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    font-size: 15px;
}

.infra-mkt__form-input:focus {
    outline: none;
    border-color: #040548;
}

.infra-mkt__error-text {
    color: #CA3060;
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    margin-top: -4px;
    display: none;
}

.infra-mkt__error-text.active {
    display: block;
}

.infra-mkt__checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: 10px;
}

.infra-mkt__checkbox-custom {
    display: flex;
    width: 21px;
    height: 21px;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    cursor: pointer;
}

.infra-mkt__checkbox-input {
    display: none;
}

.infra-mkt__checkbox-label {
    color: #040548;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
    cursor: pointer;
}

.infra-mkt__modal-actions {
    display: flex;
    padding: 0 24px;
    justify-content: space-between;
    align-items: center;
    align-self: stretch;
    gap: 16px;
    margin-top: auto;
}

.infra-mkt__btn-cancel {
    display: flex;
    height: 48px;
    padding: 7.8px 15.6px;
    justify-content: center;
    align-items: center;
    flex: 1;
    border-radius: 35px;
    border: 1px solid #E2E8F0;
    background: transparent;
    color: #040548;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.infra-mkt__btn-pay {
    display: flex;
    height: 48px;
    padding: 7.8px 15.6px;
    justify-content: center;
    align-items: center;
    flex: 1;
    border-radius: 35px;
    background: #CA3060;
    /* Brand red/pink */
    border: none;
    color: #FFF;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.infra-mkt__btn-pay:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Success Modal Styles */
.infra-mkt__success-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #F0FDF4;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 24px;
}

.infra-mkt__modal-success {
    justify-content: center;
    height: auto;
    padding: 40px 24px;
    text-align: center;
}

.infra-mkt__success-subtitle {
    color: var(--Secondary-Text, #64748B);
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    margin-top: 12px;
}