/* Custom School Dropdown Styles - Stylish Version */
.custom-dropdown-container {
    position: relative;
    width: 100%;
}

.custom-dropdown-list {
    position: absolute;
    top: calc(100% + 2px);
    left: 0;
    width: 100%;
    max-height: 180px;
    overflow-y: auto;
    background: linear-gradient(135deg, rgba(26, 26, 58, 0.98) 0%, rgba(45, 27, 105, 0.98) 100%);
    backdrop-filter: blur(15px);
    border: 2px solid rgba(59, 130, 246, 0.4);
    border-radius: 12px;
    padding: 6px 0;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3), 0 0 25px rgba(59, 130, 246, 0.2);
    z-index: 1000;
    display: none;
}

.custom-dropdown-list.show {
    display: block;
    animation: slideDown 0.2s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.custom-dropdown-item {
    padding: 12px 18px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    font-weight: 500;
    border-bottom: 1px solid rgba(59, 130, 246, 0.1);
    border-left: 3px solid transparent;
    margin: 2px 6px;
    border-radius: 6px;
}

.custom-dropdown-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.custom-dropdown-item:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(99, 102, 241, 0.2) 100%);
    color: #ffffff;
    border-left-color: #3b82f6;
    transform: translateX(4px);
}

.custom-dropdown-item.highlighted {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.3) 0%, rgba(99, 102, 241, 0.3) 100%);
    color: #ffffff;
    border-left-color: #60a5fa;
}

.custom-dropdown-item.selected {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.25) 0%, rgba(99, 102, 241, 0.25) 100%);
    color: #60a5fa;
    font-weight: 600;
}

.custom-dropdown-empty {
    padding: 16px 20px;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
    font-style: italic;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Mobile performance overrides to reduce blur and shadow on dropdown */
@media (max-width: 768px), (pointer: coarse) {
  .custom-dropdown-list {
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    box-shadow: none !important;
  }
}

.custom-dropdown-loading {
    padding: 16px 20px;
    text-align: center;
    color: rgba(96, 165, 250, 0.9);
    font-size: 0.9rem;
    font-weight: 500;
}

.custom-dropdown-loading::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Ensure input has proper styling */
.custom-dropdown-input {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    border: 2px solid #ddd;
    border-radius: 5px;
    transition: border-color 0.2s;
}

.custom-dropdown-input:focus {
    border-color: #007bff;
    outline: none;
}

.custom-dropdown-input.has-results {
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}
