/* ===== Smart Currency Switcher — scs-style.css ===== */

/* ---- Floating widget positions ---- */
.scs-floating {
    position: fixed;
    z-index: 99999;
}
.scs-pos-top-right    { top: 16px;    right: 16px; }
.scs-pos-top-left     { top: 16px;    left: 16px;  }
.scs-pos-bottom-right { bottom: 16px; right: 16px; }
.scs-pos-bottom-left  { bottom: 16px; left: 16px;  }

/* ---- Inline widget ---- */
.scs-inline-switcher  { display: inline-block; }

/* ---- Dropdown trigger ---- */
.scs-trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: #fff;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #111;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
    transition: border-color .15s, box-shadow .15s;
    white-space: nowrap;
    font-family: inherit;
}
.scs-trigger:hover { border-color: #6366f1; box-shadow: 0 2px 8px rgba(99,102,241,.15); }
.scs-trigger[aria-expanded="true"] { border-color: #6366f1; }

.scs-trigger-flag { font-size: 18px; line-height: 1; }
.scs-chevron      { transition: transform .2s; flex-shrink: 0; }
.scs-trigger[aria-expanded="true"] .scs-chevron { transform: rotate(180deg); }

/* ---- Dropdown list ---- */
.scs-select-wrap { position: relative; }

.scs-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 220px;
    max-height: 300px;
    overflow-y: auto;
    background: #fff;
    border: 1.5px solid #e5e7eb;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0,0,0,.12);
    list-style: none;
    margin: 0;
    padding: 4px;
    z-index: 100000;
    scroll-behavior: smooth;
}
.scs-pos-top-left  .scs-dropdown,
.scs-pos-bottom-left .scs-dropdown { right: auto; left: 0; }

.scs-dropdown.open { display: block; }

.scs-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 7px;
    cursor: pointer;
    font-size: 14px;
    color: #374151;
    transition: background .1s;
}
.scs-option:hover      { background: #f3f4f6; }
.scs-option.active     { background: #eef2ff; color: #4f46e5; font-weight: 600; }
.scs-option .scs-code  { font-weight: 600; min-width: 36px; }
.scs-option .scs-name  { color: #9ca3af; font-size: 12px; }

/* ---- Pills style ---- */
.scs-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.scs-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 10px;
    border: 1.5px solid #d1d5db;
    border-radius: 999px;
    background: #fff;
    font-size: 12px;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: background .12s, border-color .12s, color .12s;
    font-family: inherit;
}
.scs-pill:hover  { border-color: #6366f1; color: #4f46e5; }
.scs-pill.active { background: #6366f1; border-color: #6366f1; color: #fff; }

/* ---- Price converting flash ---- */
.scs-converting {
    display: inline-block;
    animation: scs-flash .4s ease;
}
@keyframes scs-flash {
    0%   { opacity: 0.4; transform: scale(.97); }
    100% { opacity: 1;   transform: scale(1); }
}

/* ---- Dark mode ---- */
@media (prefers-color-scheme: dark) {
    .scs-trigger {
        background: #1f2937;
        border-color: #374151;
        color: #f9fafb;
    }
    .scs-dropdown {
        background: #1f2937;
        border-color: #374151;
    }
    .scs-option          { color: #e5e7eb; }
    .scs-option:hover    { background: #374151; }
    .scs-option.active   { background: #312e81; color: #a5b4fc; }
    .scs-option .scs-name{ color: #6b7280; }
    .scs-pill {
        background: #1f2937;
        border-color: #374151;
        color: #e5e7eb;
    }
    .scs-pill.active { background: #6366f1; }
}
