/**
 * Silky Currency Converter Styles
 * Luxury Design Matching SilkyWigs Aesthetics
 */

/* ==========================================================================
   FLOATING CURRENCY SWITCHER (Luxury Pill)
   ========================================================================== */
.silky-floating-currency-switcher {
    position: fixed;
    bottom: 50px;
    left: 24px;
    z-index: 99999;
    font-family: 'Outfit', 'Josefin Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Scroll To Top button lifted to clear footer bottom copyright/policy bar */
html body #ast-scroll-top,
#ast-scroll-top {
    bottom: 50px !important;
}

.silky-currency-pill-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(229, 213, 203, 0.9);
    padding: 8px 14px;
    border-radius: 30px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #2b2b2b;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
}

.silky-currency-pill-trigger:hover {
    background: #ffffff;
    border-color: #91173b;
    box-shadow: 0 6px 22px rgba(145, 23, 59, 0.15);
    transform: translateY(-2px);
    color: #91173b;
}

.silky-currency-flag {
    font-size: 16px;
    line-height: 1;
    display: inline-block;
}

.silky-currency-code {
    font-weight: 700;
    letter-spacing: 0.5px;
}

.silky-currency-symbol {
    opacity: 0.7;
    font-size: 12px;
}

.silky-currency-chevron {
    font-size: 10px;
    margin-left: 2px;
    transition: transform 0.25s ease;
}

.silky-floating-currency-switcher.open .silky-currency-chevron {
    transform: rotate(180deg);
}

/* ==========================================================================
   DROPDOWN MENU
   ========================================================================== */
.silky-currency-dropdown-modal {
    position: absolute;
    bottom: calc(100% + 10px);
    left: 0;
    width: 260px;
    max-height: 380px;
    background: #ffffff;
    border: 1px solid rgba(229, 213, 203, 0.8);
    border-radius: 16px;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(145, 23, 59, 0.06);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px) scale(0.97);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

.silky-floating-currency-switcher.open .silky-currency-dropdown-modal {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.silky-currency-dropdown-header {
    padding: 12px 16px;
    background: #fbf9f8;
    border-bottom: 1px solid #f0e6e0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.silky-currency-dropdown-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #8c827a;
}

.silky-currency-detected-tag {
    font-size: 10px;
    background: rgba(145, 23, 59, 0.08);
    color: #91173b;
    padding: 2px 7px;
    border-radius: 12px;
    font-weight: 600;
}

.silky-currency-list {
    list-style: none;
    margin: 0;
    padding: 6px;
    overflow-y: auto;
    max-height: 320px;
}

.silky-currency-list::-webkit-scrollbar {
    width: 5px;
}

.silky-currency-list::-webkit-scrollbar-thumb {
    background: #e5d5cb;
    border-radius: 4px;
}

.silky-currency-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 12px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 13px;
    color: #333333;
    transition: all 0.15s ease;
}

.silky-currency-item:hover {
    background: #fbf6f4;
    color: #91173b;
}

.silky-currency-item.active {
    background: #f7e8ee;
    color: #91173b;
    font-weight: 700;
}

.silky-currency-item-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.silky-currency-item-name {
    font-size: 12px;
    color: #777;
    margin-left: 4px;
}

.silky-currency-item.active .silky-currency-item-name {
    color: #91173b;
    opacity: 0.8;
}

.silky-currency-check {
    font-size: 14px;
    color: #91173b;
    display: none;
}

.silky-currency-item.active .silky-currency-check {
    display: block;
}

/* ==========================================================================
   SHORTCODE SWITCHER (Inline / Header Dropdown)
   ========================================================================== */
.silky-inline-currency-switcher {
    display: inline-flex;
    align-items: center;
    position: relative;
    font-family: inherit;
}

.silky-inline-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #ffffff;
    border: 1px solid #e5d5cb;
    padding: 6px 28px 6px 10px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
}

.silky-inline-select:hover,
.silky-inline-select:focus {
    border-color: #91173b;
}

.silky-inline-arrow {
    position: absolute;
    right: 8px;
    pointer-events: none;
    font-size: 10px;
    color: #777;
}

/* Loader Overlay on Currency Change */
.silky-currency-switching {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(4px);
    z-index: 999999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.silky-currency-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid #f3e9e3;
    border-top: 3px solid #91173b;
    border-radius: 50%;
    animation: silky-spin 0.8s linear infinite;
}

.silky-currency-switching-text {
    font-size: 14px;
    font-weight: 600;
    color: #2b2b2b;
    font-family: 'Outfit', sans-serif;
}

@keyframes silky-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile responsive */
@media (max-width: 768px) {
    /* Hide desktop floating currency switcher on mobile as it is now inside the mobile drawer (Option A) */
    .silky-floating-currency-switcher {
        display: none !important;
    }

    /* Position Astra Scroll-to-Top on mobile: bottom right, floating compactly above the 60px bottom app bar */
    html body #ast-scroll-top,
    #ast-scroll-top {
        bottom: 65px !important;
        right: 14px !important;
        width: 30px !important;
        height: 30px !important;
        line-height: 30px !important;
        border-radius: 50% !important;
        background: #ffffff !important;
        color: #1e293b !important;
        border: 1px solid rgba(0, 0, 0, 0.1) !important;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.16) !important;
        z-index: 99980 !important;
        font-size: 14px !important;
        text-align: center !important;
        transition: all 0.2s ease !important;
    }

    #ast-scroll-top .ast-icon.icon-arrow svg {
        fill: #1e293b !important;
        width: 14px !important;
        height: 14px !important;
    }

    #ast-scroll-top:hover,
    #ast-scroll-top:active {
        background: #91173b !important;
        color: #ffffff !important;
        border-color: #91173b !important;
    }

    #ast-scroll-top:hover .ast-icon.icon-arrow svg,
    #ast-scroll-top:active .ast-icon.icon-arrow svg {
        fill: #ffffff !important;
    }
}
