/* Global modern input style inspired by setup wizard */
.form-control.form-control-solid,
.form-select.form-select-solid {
    background: #f8f9fa !important;
    border: 1px solid transparent !important;
    border-radius: 12px !important;
    height: 44px !important;
    min-height: 44px !important;
    font-size: 1rem !important;
    font-weight: 400 !important;
    padding: 10px 16px !important;
    box-shadow: none !important;
    color: #4b5563 !important;
    transition: all 0.2s ease !important;
}

.form-control.form-control-solid::placeholder,
.form-select.form-select-solid::placeholder {
    color: #9ca3af !important;
    font-weight: 400 !important;
    opacity: 1 !important;
}

input[type="number"] {
    direction: rtl !important;
    text-align: right !important;
}

input[type="number"].text-start,
input[type="number"].text-end {
    direction: rtl !important;
    text-align: right !important;
}

.form-control.form-control-solid:focus,
.form-select.form-select-solid:focus {
    background: #ffffff !important;
    border-color: #d1d5db !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03) !important;
    color: #181c32 !important;
}

/* Select2 integration */
.select2-container--bootstrap5 .select2-selection,
.select2-container--default .select2-selection {
    background: #f8f9fa !important;
    border: 1px solid transparent !important;
    border-radius: 12px !important;
    height: 44px !important;
    min-height: 44px !important;
    padding: 0 16px !important;
    display: flex !important;
    align-items: center !important;
    box-shadow: none !important;
}

.select2-container--bootstrap5.select2-container--focus .select2-selection {
    background: #ffffff !important;
    border-color: #d1d5db !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03) !important;
}

.select2-container--bootstrap5 .select2-selection__rendered,
.select2-container--default .select2-selection__rendered {
    padding: 0 !important;
    line-height: normal !important;
    color: #4b5563 !important;
    font-size: 1rem !important;
    width: 100%;
}

/* Select2 Dropdown and Search Styling */
.select2-dropdown {
    border: 1px solid #f3f4f6 !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08) !important;
    padding: 8px !important;
    background: #ffffff !important;
    margin-top: 4px !important;
}

.select2-search--dropdown {
    padding: 4px 4px 8px !important;
}

.select2-search__field {
    border: 1px solid #e5e7eb !important;
    border-radius: 8px !important;
    height: 38px !important;
    min-height: 38px !important;
    padding: 6px 12px !important;
    background: #f9fafb !important;
    font-size: 0.95rem !important;
    outline: none !important;
    transition: all 0.2s;
}

.select2-search__field:focus {
    border-color: #d1d5db !important;
    background: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03) !important;
}

.select2-results__option {
    border-radius: 8px !important;
    padding: 8px 12px !important;
    margin-bottom: 2px !important;
    transition: background 0.15s;
}

/* Slightly cleaner labels across forms */
.fv-row > label,
.col-form-label,
.form-label,
.form-check-label {
    font-weight: 600 !important;
    font-size: 1rem !important;
    color: #4b5563 !important;
}

[data-bs-theme="dark"] .form-control.form-control-solid,
[data-bs-theme="dark"] .form-select.form-select-solid,
[data-bs-theme="dark"] .select2-container--bootstrap5 .select2-selection {
    background-color: #2b2b40 !important;
    color: #92929f !important;
}

[data-bs-theme="dark"] .form-control.form-control-solid::placeholder,
[data-bs-theme="dark"] .form-select.form-select-solid::placeholder {
    color: #6b6b8a !important;
    opacity: 1 !important;
}

[data-bs-theme="dark"] .form-control.form-control-solid:focus,
[data-bs-theme="dark"] .form-select.form-select-solid:focus,
[data-bs-theme="dark"] .select2-container--bootstrap5.select2-container--focus .select2-selection {
    background-color: #32324d !important;
    border-color: #4b4b6a !important;
    color: #92929f !important;
}

[data-bs-theme="dark"] .select2-container--bootstrap5 .select2-selection__rendered,
[data-bs-theme="dark"] .fv-row > label,
[data-bs-theme="dark"] .col-form-label,
[data-bs-theme="dark"] .form-label,
[data-bs-theme="dark"] .form-check-label {
    color: #92929f !important;
}

/* Global Container Border Radius Increase */
.card,
.modal-content,
.alert {
    border-radius: 16px !important;
}

.card > .card-header,
.modal-content > .modal-header {
    border-top-left-radius: 16px !important;
    border-top-right-radius: 16px !important;
}

.card > .card-footer,
.modal-content > .modal-footer {
    border-bottom-left-radius: 16px !important;
    border-bottom-right-radius: 16px !important;
}

/* Global Button Styling */
.btn {
    border-radius: 12px !important;
    font-weight: 700 !important;
    font-size: 1.15rem !important;
    padding: 12px 28px !important;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    box-shadow: none !important;
}

.btn.btn-primary {
    background-image: linear-gradient(135deg, #0072ff 0%, #0056b3 51%, #0072ff 100%) !important;
    background-size: 200% auto !important;
    border: none !important;
    color: #ffffff !important;
}

.btn.btn-primary:hover, 
.btn.btn-primary:focus {
    background-position: right center !important;
    color: #ffffff !important;
}

.btn.btn-light {
    background: #f8f9fa !important;
    color: #4b5563 !important;
    border: 1px solid #e5e7eb !important;
}

.btn.btn-light:hover, 
.btn.btn-light:focus {
    background: #f3f4f6 !important;
    color: #181c32 !important;
    border-color: #d1d5db !important;
}
