/* UNIPLAST — Cart phone country-code dropdown: complete, self-contained styling.
   This does NOT rely on the site's existing compiled CSS having correct rules
   for the dropdown panel — it defines everything needed so the panel floats
   properly above the form instead of pushing content sideways/down. */

.cart-phone-field {
    display: flex !important;
    align-items: stretch !important;
    border: 1px solid #d7dde5;
    border-radius: 12px;
    overflow: visible !important; /* allow the panel to float outside the box */
    background: #fff;
}

.cart-phone-code {
    position: relative !important;
    flex: 0 0 auto !important;
    border-right: 1px solid #e3e8ef;
    z-index: 1;
}

.cart-phone-code.is-open {
    z-index: 999 !important;
}

.cart-phone-code-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 100%;
    min-width: 90px;
    padding: 0 12px;
    background: #f8fafc;
    border: none;
    color: #2d3748;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
}

.cart-phone-code-toggle i {
    font-size: 0.65rem;
    color: #8a94a6;
    transition: transform 0.15s ease;
}

.cart-phone-code.is-open .cart-phone-code-toggle i {
    transform: rotate(180deg);
}

.cart-phone-code.is-open .cart-phone-code-toggle {
    background: #eef4fb;
}

.cart-phone-field input[type="tel"] {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 14px;
}

/* --- The critical fix: the panel must float ABOVE the page, not sit inline --- */
.cart-phone-code-panel {
    display: block;
    position: absolute !important;
    top: calc(100% + 6px) !important;
    left: 0 !important;
    width: 280px !important;
    max-width: calc(100vw - 48px);
    margin: 0;
    background: #ffffff !important;
    border: 1px solid #d7dde5;
    border-radius: 12px;
    box-shadow: 0 16px 36px rgba(15, 33, 61, 0.18);
    z-index: 999 !important;
    overflow: hidden;
}

.cart-phone-code-panel[hidden] {
    display: none !important;
}

.cart-phone-code-search {
    width: 100%;
    box-sizing: border-box;
    border: none;
    border-bottom: 1px solid #e3e8ef;
    padding: 10px 14px;
    font-size: 0.88rem;
    color: #333;
}

.cart-phone-code-search:focus {
    outline: none;
    background: #f8fafc;
}

.cart-phone-code-list {
    list-style: none;
    margin: 0;
    padding: 6px 0;
    max-height: 260px;
    overflow-y: auto;
}

.cart-phone-code-list li[data-code] {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 14px;
    font-size: 0.86rem;
    color: #2d3748;
    cursor: pointer;
    outline: none;
}

.cart-phone-code-list li[data-code]:hover,
.cart-phone-code-list li[data-code]:focus-visible {
    background: #eef4fb;
}

.cart-phone-code-country {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.cart-phone-code-value {
    flex: 0 0 auto;
    color: #6c757d;
    font-weight: 600;
}

.cart-phone-code-empty {
    padding: 12px 14px;
    color: #8a94a6;
    font-size: 0.85rem;
}

/* Flag images (both in the closed toggle and in the open list) */
.cart-phone-code-flag {
    display: inline-block;
    width: 20px;
    height: 15px;
    object-fit: cover;
    border-radius: 2px;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.08);
    flex: 0 0 auto;
}

#cartInquiryPhoneCodeLabel {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}