/* ========================================
   iLoveMusic Custom Styles
   Dark theme with orange accent (#ff8c00)
   ======================================== */

/* ========== ORANGE BUTTONS ========== */
.btn-orange {
    background-color: #ff8c00;
    border-color: #ff8c00;
    color: white;
    font-weight: 500;
}

.btn-orange:hover {
    background-color: #e67e00;
    border-color: #e67e00;
    color: white;
}

.btn-orange:focus,
.btn-orange:active {
    background-color: #e67e00;
    border-color: #e67e00;
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
}

.btn-orange:disabled {
    background-color: #ff8c00;
    border-color: #ff8c00;
    opacity: 0.65;
}

/* Orange outline button */
.btn-outline-orange {
    border-color: #ff8c00;
    color: #ff8c00;
    background-color: transparent;
}

.btn-outline-orange:hover {
    background-color: #ff8c00;
    border-color: #ff8c00;
    color: white;
}

.btn-outline-orange:focus,
.btn-outline-orange:active {
    background-color: #ff8c00;
    border-color: #ff8c00;
    color: white;
    box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
}

/* ========== DARK THEME TABLES ========== */
.table-dark {
    --bs-table-bg: #212529;
    --bs-table-striped-bg: #2c3034;
    --bs-table-hover-bg: #323539;
    --bs-table-color: #fff;
    --bs-table-border-color: #495057;
}

.table-dark thead {
    background-color: #1a1d20;
    border-bottom: 2px solid #495057;
}

.table-dark th,
.table-dark td {
    border-color: #495057;
}

/* ========== SORTABLE TABLE HEADERS ========== */
.sortable {
    cursor: pointer;
    user-select: none;
    transition: background-color 0.2s ease;
}

.sortable:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.sortable i {
    font-size: 0.8em;
    margin-left: 4px;
    opacity: 0.6;
}

/* ========== DARK FORM CONTROLS ========== */
.form-control-dark {
    background-color: #212529;
    border-color: #495057;
    color: #fff;
}

.form-control-dark:focus {
    background-color: #2c3034;
    border-color: #ff8c00;
    color: #fff;
    box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
}

.form-control-dark::placeholder {
    color: #6c757d;
}

.form-select-dark {
    background-color: #212529;
    border-color: #495057;
    color: #fff;
}

.form-select-dark:focus {
    background-color: #2c3034;
    border-color: #ff8c00;
    color: #fff;
    box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
}

/* ========== COLORED BORDERS ========== */
.border-orange {
    border-color: #ff8c00 !important;
}

.text-orange {
    color: #ff8c00 !important;
}

.bg-orange {
    background-color: #ff8c00 !important;
}

/* ========== PROGRESS BARS ========== */
.progress-bar.bg-orange {
    background-color: #ff8c00 !important;
}

/* ========== ACTIONS COLUMN ========== */
.actions-column {
    width: 200px;
    white-space: nowrap;
}

/* ========== EMPTY STATE ========== */
.empty-state {
    padding: 3rem 1.5rem;
    text-align: center;
}

.empty-state i {
    font-size: 3rem;
    opacity: 0.5;
}

/* ========== VISIBILITY ICONS ========== */
.visibility-icon {
    cursor: pointer;
    font-size: 1.2rem;
    transition: transform 0.2s ease;
}

.visibility-icon:hover {
    transform: scale(1.2);
}

/* ========== CARD DARK THEME ========== */
.card.bg-dark {
    background-color: #212529 !important;
    border-color: #495057;
}

.card-header.bg-dark {
    background-color: #1a1d20 !important;
    border-bottom-color: #495057;
}

/* ========== BADGES ========== */
.badge.bg-orange {
    background-color: #ff8c00 !important;
}

/* ========== ACCORDION DARK THEME ========== */
.accordion-item.bg-dark {
    background-color: #212529;
    border-color: #495057;
}

.accordion-button.bg-dark {
    background-color: #1a1d20;
    color: #fff;
}

.accordion-button.bg-dark:not(.collapsed) {
    background-color: #2c3034;
    color: #ff8c00;
}

.accordion-button.bg-dark:focus {
    border-color: #ff8c00;
    box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
}

.accordion-body.bg-dark {
    background-color: #212529;
    color: #fff;
}

/* ========== BUTTON GROUP FIXES ========== */
.btn-group .btn-orange,
.btn-group-vertical .btn-orange {
    color: white;
}

.btn-group .btn-outline-orange,
.btn-group-vertical .btn-outline-orange {
    color: #ff8c00;
}

.btn-group .btn-outline-orange:hover,
.btn-group-vertical .btn-outline-orange:hover {
    color: white;
}

/* Fix for small buttons in dark tables */
.table-dark .btn-sm {
    color: white;
}

.table-dark .btn-orange {
    color: white !important;
}

.table-dark .btn-danger {
    color: white !important;
}

.table-dark .btn-info {
    color: white !important;
}

.table-dark .btn-secondary {
    color: white !important;
    background-color: #6c757d;
    border-color: #6c757d;
}

.table-dark .btn-secondary:hover {
    background-color: #5a6268;
    border-color: #545b62;
}

/* ========== CODE BLOCKS ========== */
code {
    background-color: rgba(13, 110, 253, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.9em;
    color: #0dcaf0;
}

.table-dark code {
    background-color: rgba(13, 202, 240, 0.15);
    color: #0dcaf0;
}

/* ========== RESPONSIVE ADJUSTMENTS ========== */
@media (max-width: 768px) {
    .actions-column {
        width: auto;
        white-space: normal;
    }
    
    .btn-group-vertical .btn {
        margin-bottom: 0.25rem;
    }
}
