/* ==========================================================
   MintPay
   PATCH-MINTPAY-007
   Favourites Dropdown + Delete
   ========================================================== */


.favourite-dropdown-section {
    margin:
        18px
        0;

    padding:
        16px;

    border-radius:
        20px;

    background:
        linear-gradient(
            145deg,
            rgba(255,255,255,.66),
            rgba(255,255,255,.34)
        );

    border:
        1px solid
        var(--sp-glass-border);

    box-shadow:
        0 10px 28px
        rgba(15,23,42,.07);

    backdrop-filter:
        blur(22px)
        saturate(140%);

    -webkit-backdrop-filter:
        blur(22px)
        saturate(140%);
}


/* ==========================================================
   Header
   ========================================================== */

.favourite-dropdown-header {
    display:
        flex;

    align-items:
        center;

    justify-content:
        space-between;

    gap:
        12px;

    margin-bottom:
        12px;
}


.favourite-dropdown-header > div {
    display:
        grid;

    gap:
        2px;
}


.favourite-dropdown-header strong {
    color:
        var(--sp-text-primary);

    font-size:
        14px;

    font-weight:
        900;
}


.favourite-dropdown-header span {
    color:
        var(--sp-text-tertiary);

    font-size:
        11px;
}


/* ==========================================================
   Add Button
   ========================================================== */

.favourite-dropdown-add {
    min-height:
        36px;

    padding:
        7px
        12px;

    border-radius:
        12px;

    color:
        #ffffff;

    background:
        linear-gradient(
            135deg,
            #7c3aed,
            #4f46e5,
            #06b6d4
        );

    border:
        0;

    box-shadow:
        0 9px 20px
        rgba(79,70,229,.20);

    font-weight:
        800;
}


/* ==========================================================
   Controls
   ========================================================== */

.favourite-dropdown-controls {
    display:
        grid;

    grid-template-columns:
        minmax(0,1fr)
        auto;

    gap:
        10px;
}


/* ==========================================================
   Select
   ========================================================== */

.favourite-select-wrap {
    position:
        relative;

    min-width:
        0;
}


.favourite-select-icon {
    position:
        absolute;

    left:
        14px;

    top:
        50%;

    z-index:
        2;

    transform:
        translateY(-50%);

    pointer-events:
        none;

    color:
        #7c3aed;

    font-size:
        16px;
}


.favourite-recipient-select {
    width:
        100%;

    min-width:
        0;

    min-height:
        52px;

    padding:
        0
        38px
        0
        42px;

    border-radius:
        16px;

    color:
        var(--sp-text-primary);

    background:
        rgba(
            255,
            255,
            255,
            .72
        );

    border:
        1px solid
        var(--sp-border-primary);

    box-shadow:
        inset
        0
        1px
        0
        rgba(
            255,
            255,
            255,
            .40
        );

    font-size:
        13px;

    font-weight:
        750;

    outline:
        none;
}


.favourite-recipient-select:focus {
    border-color:
        var(--sp-primary-400);

    box-shadow:
        var(--sp-focus-ring);
}


/* ==========================================================
   Delete
   ========================================================== */

.favourite-dropdown-delete {
    min-width:
        92px;

    min-height:
        52px;

    padding:
        7px
        12px;

    display:
        inline-flex;

    align-items:
        center;

    justify-content:
        center;

    gap:
        6px;

    border-radius:
        16px;

    color:
        #dc2626;

    background:
        rgba(
            254,
            242,
            242,
            .85
        );

    border:
        1px solid
        rgba(
            239,
            68,
            68,
            .22
        );

    font-size:
        12px;

    font-weight:
        850;

    transition:
        transform
        var(--sp-transition-spring),
        opacity
        var(--sp-transition-fast),
        background
        var(--sp-transition-fast);
}


.favourite-dropdown-delete:not(:disabled):active {
    transform:
        scale(.96);
}


.favourite-dropdown-delete:disabled {
    opacity:
        .38;

    cursor:
        not-allowed;
}


/* ==========================================================
   Existing horizontal favourites cards
   Hide them from normal UI.
   Data/logic remains preserved.
   ========================================================== */

#favouritesSection {
    display:
        none !important;
}


/* ==========================================================
   Bottom Navigation
   Now 4 tabs instead of 5
   ========================================================== */

.mobile-bottom-navigation {
    grid-template-columns:
        repeat(
            4,
            minmax(0,1fr)
        )
        !important;
}


/* ==========================================================
   Dark
   ========================================================== */

html[data-sp-theme="dark"]
.favourite-dropdown-section {
    background:
        linear-gradient(
            145deg,
            rgba(15,23,42,.78),
            rgba(15,23,42,.48)
        );
}


html[data-sp-theme="dark"]
.favourite-recipient-select {
    color:
        var(--sp-text-primary);

    background:
        rgba(
            15,
            23,
            42,
            .76
        );
}


/* ==========================================================
   Mobile
   ========================================================== */

@media (max-width: 430px) {

    .favourite-dropdown-section {
        padding:
            14px;

        border-radius:
            18px;
    }


    .favourite-dropdown-controls {
        grid-template-columns:
            minmax(0,1fr)
            48px;
    }


    .favourite-dropdown-delete {
        min-width:
            48px;

        width:
            48px;

        padding:
            0;
    }


    .favourite-dropdown-delete span {
        display:
            none;
    }

}


/* ==========================================================
   END PATCH-MINTPAY-007
   ========================================================== */


/* ==========================================================
   PATCH-MINTPAY-007A
   Compact Favourite Recipient UI
   ========================================================== */


/* ==========================================================
   Main Favourite Card
   ========================================================== */

.favourite-dropdown-section {
    margin:
        14px 0 18px !important;

    padding:
        14px !important;

    border-radius:
        20px !important;

    background:
        linear-gradient(
            145deg,
            rgba(255,255,255,.78),
            rgba(255,255,255,.48)
        ) !important;

    border:
        1px solid
        rgba(255,255,255,.68) !important;

    box-shadow:
        0 12px 30px
        rgba(15,23,42,.08) !important;
}


/* ==========================================================
   Header
   ========================================================== */

.favourite-dropdown-header {
    margin-bottom:
        11px !important;

    align-items:
        center !important;
}


.favourite-dropdown-header strong {
    font-size:
        14px !important;

    font-weight:
        900 !important;

    letter-spacing:
        -.02em;
}


.favourite-dropdown-header span {
    margin-top:
        2px;

    font-size:
        10px !important;

    line-height:
        1.3;
}


/* ==========================================================
   Add Button - Smaller
   ========================================================== */

.favourite-dropdown-add {
    min-height:
        34px !important;

    padding:
        6px 12px !important;

    border-radius:
        11px !important;

    font-size:
        12px !important;

    white-space:
        nowrap;

    box-shadow:
        0 8px 18px
        rgba(79,70,229,.18) !important;
}


/* ==========================================================
   Main Controls
   ========================================================== */

.favourite-dropdown-controls {
    display:
        grid !important;

    grid-template-columns:
        minmax(0,1fr)
        46px !important;

    gap:
        9px !important;

    align-items:
        stretch !important;
}


/* ==========================================================
   Select Wrapper
   ========================================================== */

.favourite-select-wrap {
    position:
        relative;

    width:
        100%;

    min-width:
        0;

    height:
        54px;

    overflow:
        hidden;

    border-radius:
        16px;

    background:
        rgba(
            255,
            255,
            255,
            .82
        );

    border:
        1px solid
        rgba(
            99,
            102,
            241,
            .18
        );

    box-shadow:
        inset
        0
        1px
        0
        rgba(
            255,
            255,
            255,
            .78
        ),
        0
        7px
        18px
        rgba(
            15,
            23,
            42,
            .05
        );
}


/* ==========================================================
   Favourite Star
   ========================================================== */

.favourite-select-icon {
    position:
        absolute !important;

    left:
        14px !important;

    top:
        50% !important;

    z-index:
        3;

    width:
        28px;

    height:
        28px;

    display:
        grid;

    place-items:
        center;

    transform:
        translateY(-50%) !important;

    border-radius:
        9px;

    color:
        #ffffff !important;

    background:
        linear-gradient(
            135deg,
            #7c3aed,
            #6366f1,
            #06b6d4
        );

    box-shadow:
        0 7px 16px
        rgba(
            99,
            102,
            241,
            .20
        );

    font-size:
        13px !important;

    pointer-events:
        none;
}


/* ==========================================================
   Native Select
   ========================================================== */

.favourite-recipient-select {
    position:
        relative;

    z-index:
        2;

    width:
        100% !important;

    height:
        54px !important;

    min-height:
        54px !important;

    margin:
        0 !important;

    padding:
        0
        40px
        0
        52px !important;

    appearance:
        none;

    -webkit-appearance:
        none;

    border:
        0 !important;

    border-radius:
        16px !important;

    outline:
        none !important;

    background:
        transparent !important;

    color:
        var(--sp-text-primary) !important;

    font-size:
        13px !important;

    font-weight:
        800 !important;

    line-height:
        1.2;

    text-overflow:
        ellipsis;

    white-space:
        nowrap;

    overflow:
        hidden;
}


/* ==========================================================
   Custom Dropdown Chevron
   ========================================================== */

.favourite-select-wrap::after {
    content:
        "⌄";

    position:
        absolute;

    right:
        14px;

    top:
        50%;

    z-index:
        4;

    transform:
        translateY(-54%);

    color:
        var(--sp-text-secondary);

    font-size:
        17px;

    font-weight:
        900;

    pointer-events:
        none;
}


/* ==========================================================
   Focus
   ========================================================== */

.favourite-select-wrap:focus-within {
    border-color:
        rgba(
            99,
            102,
            241,
            .50
        );

    box-shadow:
        0
        0
        0
        4px
        rgba(
            99,
            102,
            241,
            .08
        ),
        0
        10px
        24px
        rgba(
            79,
            70,
            229,
            .08
        );
}


/* ==========================================================
   Delete Button - Compact Icon
   ========================================================== */

.favourite-dropdown-delete {
    width:
        46px !important;

    min-width:
        46px !important;

    height:
        54px !important;

    min-height:
        54px !important;

    padding:
        0 !important;

    border-radius:
        15px !important;

    display:
        grid !important;

    place-items:
        center !important;

    color:
        #dc2626 !important;

    background:
        rgba(
            254,
            242,
            242,
            .88
        ) !important;

    border:
        1px solid
        rgba(
            239,
            68,
            68,
            .18
        ) !important;

    box-shadow:
        0
        7px
        18px
        rgba(
            239,
            68,
            68,
            .07
        ) !important;

    font-size:
        18px !important;
}


.favourite-dropdown-delete span {
    display:
        none !important;
}


.favourite-dropdown-delete:not(:disabled):hover {
    color:
        #ffffff !important;

    background:
        linear-gradient(
            135deg,
            #ef4444,
            #f43f5e
        ) !important;

    border-color:
        transparent !important;
}


.favourite-dropdown-delete:disabled {
    opacity:
        .30 !important;

    filter:
        grayscale(.4);
}


/* ==========================================================
   Remove Any Stray Overflow
   ========================================================== */

.favourite-dropdown-section,
.favourite-dropdown-controls,
.favourite-select-wrap {
    box-sizing:
        border-box;
}


.favourite-dropdown-section * {
    box-sizing:
        border-box;
}


/* ==========================================================
   iPhone
   ========================================================== */

@media (max-width: 430px) {

    .favourite-dropdown-section {
        padding:
            13px !important;

        margin-top:
            12px !important;
    }


    .favourite-dropdown-header {
        margin-bottom:
            10px !important;
    }


    .favourite-dropdown-add {
        min-height:
            32px !important;

        padding:
            5px
            10px !important;
    }


    .favourite-select-wrap,
    .favourite-recipient-select {
        height:
            52px !important;

        min-height:
            52px !important;
    }


    .favourite-dropdown-delete {
        width:
            44px !important;

        min-width:
            44px !important;

        height:
            52px !important;

        min-height:
            52px !important;
    }

}


/* ==========================================================
   Dark Mode
   ========================================================== */

html[data-sp-theme="dark"]
.favourite-dropdown-section {
    background:
        linear-gradient(
            145deg,
            rgba(15,23,42,.78),
            rgba(15,23,42,.54)
        ) !important;
}


html[data-sp-theme="dark"]
.favourite-select-wrap {
    background:
        rgba(
            15,
            23,
            42,
            .72
        );
}


/* ==========================================================
   END PATCH-MINTPAY-007A
   ========================================================== */
