/* ================================================
   Modern Flat Custom Selects & Inputs
   ================================================ */

/* Custom Select Wrapper */
.custom-select-wrapper {
    position: relative;
    width: 100%;
}

.custom-select {
    position: relative;
    display: block;
    width: 100%;
}

.custom-select-trigger {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.875rem 1rem;
    background: #2a2a3e;
    border: 2px solid #3a3a4e;
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.custom-select-trigger:hover {
    border-color: #4a4a5e;
    background: #323246;
}

.custom-select.open .custom-select-trigger {
    border-color: #e50914;
    background: #323246;
}

.custom-select-trigger i {
    transition: transform 0.2s ease;
    color: #999;
}

.custom-select.open .custom-select-trigger i {
    transform: rotate(180deg);
}

.custom-select-options {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #2a2a3e;
    border: 2px solid #3a3a4e;
    border-radius: 8px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.custom-select.open .custom-select-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-select-option {
    padding: 0.875rem 1rem;
    cursor: pointer;
    transition: all 0.15s ease;
    color: #ccc;
    font-size: 0.95rem;
}

.custom-select-option:hover {
    background: #323246;
    color: #fff;
}

.custom-select-option.selected {
    background: #e50914;
    color: #fff;
}

.custom-select-option.selected:hover {
    background: #f40612;
}

/* Scrollbar styling */
.custom-select-options::-webkit-scrollbar {
    width: 8px;
}

.custom-select-options::-webkit-scrollbar-track {
    background: #1a1a2e;
    border-radius: 8px;
}

.custom-select-options::-webkit-scrollbar-thumb {
    background: #4a4a5e;
    border-radius: 8px;
}

.custom-select-options::-webkit-scrollbar-thumb:hover {
    background: #5a5a6e;
}

/* Autocomplete Styles */
.autocomplete-wrapper {
    position: relative;
    width: 100%;
}

.autocomplete-input {
    width: 100%;
    padding: 0.875rem 1rem;
    background: #2a2a3e;
    border: 2px solid #3a3a4e;
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.autocomplete-input:focus {
    outline: none;
    border-color: #e50914;
    background: #323246;
}

.autocomplete-input::placeholder {
    color: #666;
}

.autocomplete-list {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #2a2a3e;
    border: 2px solid #3a3a4e;
    border-radius: 8px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.autocomplete-list.show {
    display: block;
}

.autocomplete-item {
    padding: 0.875rem 1rem;
    cursor: pointer;
    transition: all 0.15s ease;
    color: #ccc;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.autocomplete-item:hover,
.autocomplete-item.active {
    background: #323246;
    color: #fff;
}

.autocomplete-item .country-code {
    background: #e50914;
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    min-width: 32px;
    text-align: center;
}

.autocomplete-item .country-name {
    flex: 1;
}

.autocomplete-empty {
    padding: 1rem;
    text-align: center;
    color: #666;
    font-size: 0.9rem;
}

.autocomplete-list::-webkit-scrollbar {
    width: 8px;
}

.autocomplete-list::-webkit-scrollbar-track {
    background: #1a1a2e;
    border-radius: 8px;
}

.autocomplete-list::-webkit-scrollbar-thumb {
    background: #4a4a5e;
    border-radius: 8px;
}

.autocomplete-list::-webkit-scrollbar-thumb:hover {
    background: #5a5a6e;
}

/* Modern Flat Input Styles */
.modern-input {
    width: 100%;
    padding: 0.875rem 1rem;
    background: #2a2a3e;
    border: 2px solid #3a3a4e;
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.modern-input:focus {
    outline: none;
    border-color: #e50914;
    background: #323246;
}

.modern-input::placeholder {
    color: #666;
}

.modern-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Modern Select (native fallback) */
.modern-select {
    width: 100%;
    padding: 0.875rem 1rem;
    background: #2a2a3e;
    border: 2px solid #3a3a4e;
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%23999' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 16px;
    padding-right: 3rem;
}

.modern-select:hover {
    border-color: #4a4a5e;
    background-color: #323246;
}

.modern-select:focus {
    outline: none;
    border-color: #e50914;
    background-color: #323246;
}

.modern-select option {
    background: #2a2a3e;
    color: #ffffff;
    padding: 0.5rem;
}


