/* ================================================================
   NEOMORPH PLAYER – admin.css
   Stylesheet khusus halaman Admin Panel
================================================================ */

/* ================================================================
   1. DESIGN TOKENS (sama dengan player utama)
================================================================ */
:root, body.light-mode {
  --bg:             #e8ecf1;
  --surface:        #e8ecf1;
  --shadow-dark:    #b8bec8;
  --shadow-light:   #ffffff;
  --accent:         #7c5cbf;
  --accent-2:       #e44d7b;
  --accent-glow:    rgba(124,92,191,0.3);
  --accent-grad:    linear-gradient(135deg,#7c5cbf 0%,#e44d7b 100%);
  --danger:         #ef4444;
  --danger-glow:    rgba(239,68,68,0.25);
  --success:        #10b981;
  --text-primary:   #2d3142;
  --text-secondary: #6b7280;
  --text-muted:     #9ca3af;
  --sidebar-w:      260px;
  --topbar-h:       64px;
  --neu-shadow:     6px 6px 14px var(--shadow-dark), -6px -6px 14px var(--shadow-light);
  --neu-shadow-sm:  3px 3px 8px var(--shadow-dark),  -3px -3px 8px var(--shadow-light);
  --neu-shadow-inset: inset 4px 4px 10px var(--shadow-dark), inset -4px -4px 10px var(--shadow-light);
  --neu-pressed:    inset 3px 3px 8px var(--shadow-dark), inset -3px -3px 8px var(--shadow-light);
  --transition:     0.25s ease;
}

body.dark-mode {
  --bg:             #1e2030;
  --surface:        #1e2030;
  --shadow-dark:    #14161f;
  --shadow-light:   #282b3a;
  --accent:         #a07cff;
  --accent-2:       #ff6b9d;
  --accent-glow:    rgba(160,124,255,0.3);
  --accent-grad:    linear-gradient(135deg,#a07cff 0%,#ff6b9d 100%);
  --text-primary:   #e8ecf1;
  --text-secondary: #9aa1b9;
  --text-muted:     #6b7280;

  /* Explicitly redefine shadows for Dark Mode */
  --neu-shadow:     6px 6px 14px var(--shadow-dark), -6px -6px 14px var(--shadow-light);
  --neu-shadow-sm:  3px 3px 8px var(--shadow-dark),  -3px -3px 8px var(--shadow-light);
  --neu-shadow-inset: inset 4px 4px 10px var(--shadow-dark), inset -4px -4px 10px var(--shadow-light);
  --neu-pressed:    inset 3px 3px 8px var(--shadow-dark), inset -3px -3px 8px var(--shadow-light);
}

/* ================================================================
   2. RESET & BASE
================================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 15px; scroll-behavior: smooth; }

body {
  font-family: 'Outfit', sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  overflow-x: hidden;
  transition: background var(--transition), color var(--transition);
}

ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; outline: none; }
input, select, textarea { font-family: inherit; outline: none; }
a { text-decoration: none; color: inherit; }

/* ================================================================
   3. BACKGROUND BLOBS
================================================================ */
.bg-blobs {
  position: fixed; inset: 0; overflow: hidden;
  pointer-events: none; z-index: 0;
}
.blob {
  position: absolute; border-radius: 50%;
  filter: blur(80px); opacity: 0.08;
  animation: blobFloat 15s ease-in-out infinite;
}
.blob-1 { width:500px;height:500px; background:var(--accent); top:-150px;left:-150px; }
.blob-2 { width:400px;height:400px; background:var(--accent-2); bottom:-100px;right:-100px; animation-delay:-5s; }
.blob-3 { width:300px;height:300px; background:#06b6d4; top:50%;left:50%; transform:translate(-50%,-50%); animation-delay:-10s; }
@keyframes blobFloat {
  0%,100% { transform:translate(0,0) scale(1); }
  33%      { transform:translate(30px,-30px) scale(1.05); }
  66%      { transform:translate(-20px,20px) scale(0.95); }
}

/* ================================================================
   4. SIDEBAR
================================================================ */
.sidebar {
  position: fixed;
  left: 0; top: 0; bottom: 0;
  width: var(--sidebar-w);
  background: var(--surface);
  box-shadow: var(--neu-shadow);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform var(--transition), background var(--transition);
}

/* Logo area */
.sidebar-logo {
  display: flex; align-items: center; gap: 12px;
  padding: 24px 20px 20px;
  border-bottom: 1px solid var(--shadow-dark);
}
.logo-icon {
  width: 40px; height: 40px; border-radius: 12px;
  background: var(--accent-grad);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 17px;
  box-shadow: 0 4px 12px var(--accent-glow);
  flex-shrink: 0;
}
.logo-icon.big { width: 56px; height: 56px; font-size: 24px; }
.logo-title {
  font-size: 0.95rem; font-weight: 700;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.logo-sub { font-size: 0.7rem; color: var(--text-muted); display: block; }

/* Nav items */
.sidebar-nav {
  flex: 1; padding: 16px 12px;
  display: flex; flex-direction: column; gap: 4px;
  overflow-y: auto;
}
.nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 14px; border-radius: 12px;
  color: var(--text-secondary); font-size: 0.875rem; font-weight: 500;
  transition: all var(--transition); position: relative;
}
.nav-item i { width: 18px; text-align: center; font-size: 15px; }
.nav-item:hover { color: var(--accent); background: rgba(124,92,191,0.06); }
.nav-item.active {
  background: var(--surface);
  box-shadow: var(--neu-shadow-sm);
  color: var(--accent);
}
.nav-badge {
  margin-left: auto;
  background: var(--accent-grad);
  color: #fff; font-size: 0.65rem; font-weight: 700;
  padding: 2px 7px; border-radius: 50px;
}

/* Sidebar footer */
.sidebar-footer {
  padding: 16px 12px;
  border-top: 1px solid var(--shadow-dark);
  display: flex; flex-direction: column; gap: 8px;
}
.theme-toggle-btn {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 12px;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--text-secondary); font-size: 0.8rem; font-weight: 500;
  width: 100%; transition: all var(--transition);
}
.theme-toggle-btn:hover { color: var(--accent); }
.back-to-player {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 12px;
  background: var(--accent-grad); color: #fff;
  font-size: 0.8rem; font-weight: 600;
  box-shadow: 0 4px 12px var(--accent-glow);
  transition: opacity var(--transition), transform var(--transition);
}
.back-to-player:hover { opacity: 0.9; transform: translateY(-1px); }

/* Overlay mobile */
.sidebar-overlay {
  display: none; position: fixed; inset: 0;
  background: rgba(0,0,0,0.4); z-index: 99;
}

/* ================================================================
   5. CONTENT WRAPPER
================================================================ */
.content-wrapper {
  margin-left: var(--sidebar-w);
  flex: 1; display: flex; flex-direction: column;
  min-height: 100vh; position: relative; z-index: 1;
}

/* ================================================================
   6. TOPBAR
================================================================ */
.topbar {
  height: var(--topbar-h);
  background: var(--surface);
  box-shadow: var(--neu-shadow-sm);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; position: sticky; top: 0; z-index: 50;
  transition: background var(--transition);
}
.topbar-left { display: flex; align-items: center; gap: 16px; }
.topbar-right { display: flex; align-items: center; gap: 12px; }

.page-breadcrumb { font-size: 0.9rem; font-weight: 600; color: var(--text-primary); }

.stats-pill {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: 50px;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  font-size: 0.78rem; font-weight: 600; color: var(--accent);
}
.admin-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--accent-grad);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 15px;
  box-shadow: 0 3px 10px var(--accent-glow);
}

/* Tombol toggle sidebar (mobile) */
.sidebar-toggle-btn {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--text-secondary); font-size: 15px;
  display: flex; align-items: center; justify-content: center;
  display: none; /* tersembunyi di desktop */
  transition: all var(--transition);
}
.sidebar-toggle-btn:hover { color: var(--accent); }

/* ================================================================
   7. MAIN AREA & PAGES
================================================================ */
.main-area {
  flex: 1; padding: 28px 28px 40px;
  max-width: 1200px; width: 100%;
}
.page { display: none; animation: fadeIn 0.3s ease; }
.page.active { display: block; }

@keyframes fadeIn {
  from { opacity:0; transform:translateY(8px); }
  to   { opacity:1; transform:translateY(0); }
}

.page-header { margin-bottom: 24px; }
.page-title  { font-size: 1.5rem; font-weight: 700; color: var(--text-primary); }
.page-subtitle { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; }

/* ================================================================
   8. NEU-CARD (CONTAINER)
================================================================ */
.neu-card {
  background: var(--surface);
  border-radius: 20px;
  box-shadow: var(--neu-shadow);
  padding: 22px;
  transition: box-shadow var(--transition), background var(--transition);
}
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px;
}
.card-header h3 {
  font-size: 0.95rem; font-weight: 700; color: var(--text-primary);
  display: flex; align-items: center; gap: 8px;
}
.card-header h3 i { color: var(--accent); }
.btn-link {
  font-size: 0.78rem; color: var(--accent); font-weight: 500;
  background: none; border: none; cursor: pointer;
  transition: opacity var(--transition);
}
.btn-link:hover { opacity: 0.7; }

/* ================================================================
   9. DASHBOARD – STAT CARDS
================================================================ */
.stat-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 18px; margin-bottom: 24px;
}
.stat-card {
  background: var(--surface); border-radius: 16px;
  box-shadow: var(--neu-shadow-sm); padding: 18px 20px;
  display: flex; align-items: center; gap: 16px;
  transition: box-shadow var(--transition), transform var(--transition);
}
.stat-card:hover { box-shadow: var(--neu-shadow); transform: translateY(-2px); }
.stat-icon {
  width: 48px; height: 48px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 20px; flex-shrink: 0;
}
.stat-value { font-size: 1.5rem; font-weight: 700; color: var(--text-primary); display: block; }
.stat-label { font-size: 0.72rem; color: var(--text-muted); font-weight: 500; }

/* ================================================================
   10. DASHBOARD – GRID & SECTIONS
================================================================ */
.dashboard-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 20px; margin-bottom: 24px;
}

/* Genre list */
.genre-list { display: flex; flex-direction: column; gap: 10px; }
.genre-item { display: flex; flex-direction: column; gap: 4px; }
.genre-row { display: flex; justify-content: space-between; align-items: center; }
.genre-name { font-size: 0.82rem; font-weight: 500; color: var(--text-secondary); }
.genre-count { font-size: 0.72rem; color: var(--text-muted); }
.genre-bar-track {
  height: 6px; border-radius: 3px;
  background: var(--surface); box-shadow: var(--neu-shadow-inset);
  overflow: hidden;
}
.genre-bar-fill {
  height: 100%; border-radius: 3px;
  background: var(--accent-grad); transition: width 0.6s ease;
}

/* Recent songs list */
.recent-songs { display: flex; flex-direction: column; gap: 8px; }
.recent-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  transition: transform var(--transition);
}
.recent-item:hover { transform: translateX(4px); }
.recent-cover {
  width: 38px; height: 38px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 15px; flex-shrink: 0;
}
.recent-info { flex: 1; min-width: 0; }
.recent-title { font-size: 0.83rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent-artist { font-size: 0.72rem; color: var(--text-muted); }
.recent-dur { font-size: 0.72rem; color: var(--text-muted); }

/* Quick actions */
.quick-actions {
  display: flex; flex-wrap: wrap; gap: 12px;
}

/* ================================================================
   11. BUTTONS
================================================================ */
.btn-action {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; border-radius: 50px;
  font-size: 0.85rem; font-weight: 600;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--text-secondary);
  transition: all var(--transition); cursor: pointer;
}
.btn-action:hover { box-shadow: var(--neu-shadow); transform: translateY(-1px); }
.btn-action:active { box-shadow: var(--neu-pressed); transform: translateY(0); }
.btn-action.accent {
  background: var(--accent-grad); color: #fff;
  box-shadow: 0 4px 14px var(--accent-glow);
}
.btn-action.accent:hover { box-shadow: 0 6px 20px var(--accent-glow); }
.btn-action.danger { color: var(--danger); }
.btn-action.secondary { color: var(--text-secondary); }

.action-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: 12px;
  font-size: 0.82rem; font-weight: 600;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--text-secondary);
  transition: all var(--transition);
}
.action-btn:hover { box-shadow: var(--neu-shadow); color: var(--accent); }
.action-btn.accent { background: var(--accent-grad); color: #fff; box-shadow: 0 4px 12px var(--accent-glow); }
.action-btn.danger { color: var(--danger); }

.btn-sm {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px; border-radius: 8px; font-size: 0.78rem; font-weight: 600;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--text-secondary); transition: all var(--transition);
}
.btn-sm:hover { box-shadow: var(--neu-shadow); }
.btn-sm.accent { background: var(--accent-grad); color: #fff; box-shadow: 0 3px 10px var(--accent-glow); }
.btn-sm.danger { color: var(--danger); }
.btn-sm.danger:hover { background: var(--danger); color: #fff; box-shadow: 0 3px 10px var(--danger-glow); }

.btn-icon-label {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 18px; border-radius: 50px; font-size: 0.82rem; font-weight: 600;
  transition: all var(--transition);
}
.btn-icon-label.accent {
  background: var(--accent-grad); color: #fff;
  box-shadow: 0 4px 12px var(--accent-glow);
}
.btn-icon-label.accent:hover { opacity: 0.9; transform: translateY(-1px); }

/* ================================================================
   12. TOOLBAR (halaman lagu)
================================================================ */
.toolbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; margin-bottom: 18px; flex-wrap: wrap;
}
.search-box {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface); box-shadow: var(--neu-shadow-inset);
  border-radius: 50px; padding: 10px 18px; flex: 1; max-width: 380px;
}
.search-box i { color: var(--text-muted); font-size: 13px; }
.search-box input {
  background: transparent; color: var(--text-primary);
  font-size: 0.85rem; flex: 1;
}
.search-box input::placeholder { color: var(--text-muted); }

.toolbar-right { display: flex; align-items: center; gap: 10px; }
.neu-select {
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  border: none; border-radius: 50px; padding: 9px 16px;
  font-size: 0.82rem; font-weight: 500; color: var(--text-secondary);
  cursor: pointer; transition: box-shadow var(--transition);
}
.neu-select:hover { box-shadow: var(--neu-shadow); }

/* ================================================================
   13. SONGS TABLE
================================================================ */
.table-card { padding: 0; overflow: hidden; }
.table-scroll { overflow-x: auto; }

.songs-table {
  width: 100%; border-collapse: collapse;
  font-size: 0.83rem;
}
.songs-table thead tr {
  background: var(--surface);
  border-bottom: 2px solid var(--shadow-dark);
}
.songs-table th {
  padding: 14px 12px; text-align: left;
  font-weight: 700; color: var(--text-secondary);
  white-space: nowrap; user-select: none;
}
.songs-table th[data-sort] { cursor: pointer; }
.songs-table th[data-sort]:hover { color: var(--accent); }
.sort-icon { color: var(--text-muted); font-size: 10px; margin-left: 3px; }

.songs-table tbody tr {
  border-bottom: 1px solid var(--shadow-dark);
  transition: background var(--transition), transform var(--transition);
}
.songs-table tbody tr:hover { background: rgba(124,92,191,0.04); }
.songs-table tbody tr.selected-row { background: rgba(124,92,191,0.07); }
.songs-table td { padding: 12px 12px; vertical-align: middle; }

/* Kolom khusus */
.col-drag { width: 32px; }
.col-num  { width: 36px; color: var(--text-muted); font-weight: 600; }
.col-cover { width: 52px; }
.col-title  { min-width: 160px; font-weight: 600; color: var(--text-primary); }
.col-artist { min-width: 120px; color: var(--text-secondary); }
.col-album  { min-width: 110px; color: var(--text-muted); }
.col-genre  { width: 90px; }
.col-dur    { width: 70px; color: var(--text-muted); text-align: center; }
.col-actions { width: 100px; }

/* Cover kecil di tabel */
.table-cover {
  width: 40px; height: 40px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 16px; flex-shrink: 0;
}

/* Badge genre */
.genre-badge {
  display: inline-block; padding: 3px 10px; border-radius: 50px;
  font-size: 0.68rem; font-weight: 600;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--accent); white-space: nowrap;
}

/* Drag handle */
.drag-handle {
  cursor: grab; color: var(--text-muted); padding: 4px 6px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 6px; transition: color var(--transition);
}
.drag-handle:hover { color: var(--accent); }
.drag-handle:active { cursor: grabbing; }

/* Tombol aksi di tabel */
.row-actions { display: flex; align-items: center; gap: 6px; }
.row-btn {
  width: 32px; height: 32px; border-radius: 8px;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  color: var(--text-secondary); font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
}
.row-btn:hover { box-shadow: var(--neu-shadow); }
.row-btn.edit:hover { color: var(--accent); }
.row-btn.delete:hover { color: var(--danger); }

/* Checkbox pilih */
.row-check {
  width: 16px; height: 16px; accent-color: var(--accent);
  cursor: pointer;
}

/* Table footer */
.table-footer {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; border-top: 1px solid var(--shadow-dark);
  font-size: 0.78rem; color: var(--text-muted);
}

/* Empty state */
.empty-table {
  text-align: center; padding: 60px 20px;
  color: var(--text-muted);
}
.empty-table i { font-size: 2.5rem; opacity: 0.3; margin-bottom: 12px; display: block; }
.empty-table p { font-size: 0.88rem; }

/* Drag-over style */
.drag-over td { background: rgba(124,92,191,0.1) !important; }
tr.dragging { opacity: 0.4; }

/* ================================================================
   14. FORM TAMBAH / EDIT LAGU
================================================================ */
.form-layout {
  display: grid; grid-template-columns: 1fr 320px;
  gap: 22px; align-items: start;
}
.form-main .neu-card { display: flex; flex-direction: column; gap: 18px; }

.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.form-label {
  font-size: 0.82rem; font-weight: 600; color: var(--text-secondary);
  display: flex; align-items: center; gap: 6px;
}
.form-label i { color: var(--accent); width: 14px; }
.required { color: var(--accent-2); }

.neu-input {
  background: var(--surface); box-shadow: var(--neu-shadow-inset);
  border: none; border-radius: 12px;
  padding: 11px 14px; font-size: 0.875rem;
  color: var(--text-primary); width: 100%;
  transition: box-shadow var(--transition);
}
.neu-input:focus { box-shadow: var(--neu-shadow-inset), 0 0 0 2px var(--accent); }
.neu-input::placeholder { color: var(--text-muted); }
.neu-input.error { box-shadow: var(--neu-shadow-inset), 0 0 0 2px var(--danger); }

/* ── Input dengan Prefix (assets/music/ / assets/images/) ── */
/* Wrapper: position relative agar prefix bisa diposisikan absolut */
.input-with-prefix {
  position: relative;
  display: flex;
  align-items: stretch;
}

/* Prefix: overlay visual SAJA – tidak menghalangi klik */
.input-prefix {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  display: flex; align-items: center;
  padding: 0 12px;
  font-size: 0.75rem; color: var(--text-muted); font-weight: 500;
  white-space: nowrap;
  pointer-events: none;          /* ← TIDAK menghalangi klik ke input */
  z-index: 2;
  border-right: 1px solid var(--shadow-dark);
  background: transparent;
  border-radius: 12px 0 0 12px;
  /* Hitung lebar prefix agar input tahu seberapa jauh mundur */
  user-select: none;
}

/* Input: full width, z-index di bawah prefix tapi tetap bisa diklik */
.input-with-prefix .neu-input {
  width: 100%;
  border-radius: 12px;
  position: relative;
  z-index: 1;
  cursor: text;
}

/* Padding kiri berbeda sesuai panjang teks prefix */
.prefix-music  .neu-input { padding-left: 112px; } /* "assets/music/"  ± 104px */
.prefix-images .neu-input { padding-left: 124px; } /* "assets/images/" ± 116px */

/* Garis pemisah antara prefix dan input (hanya visual) */
.input-prefix::after {
  content: '';
  position: absolute;
  right: 0; top: 20%; bottom: 20%;
  width: 1px;
  background: var(--shadow-dark);
}


/* ================================================================
   UPLOAD UI – Tombol Pilih File, Drop Zone, Preview
================================================================ */

/* ── Baris Input + Tombol Upload ────────────────────────────── */
.upload-input-row {
  display: flex;
  align-items: stretch;
  gap: 10px;
}
.upload-input-row .input-with-prefix {
  flex: 1;
  min-width: 0;
}

/* ── Tombol "Pilih File / Pilih Gambar" ─────────────────────── */
.upload-pick-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 18px;
  border-radius: 12px;
  background: var(--accent-grad);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 4px 14px var(--accent-glow);
  transition: all var(--transition);
  flex-shrink: 0;
  cursor: pointer;
  border: none;
}
.upload-pick-btn i { font-size: 15px; }
.upload-pick-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px var(--accent-glow);
}
.upload-pick-btn:active {
  transform: translateY(0);
  filter: brightness(0.95);
}

/* ── Drop Zone ──────────────────────────────────────────────── */
.upload-drop-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 18px 20px;
  border-radius: 14px;
  border: 2px dashed var(--shadow-dark);
  background: var(--surface);
  box-shadow: var(--neu-shadow-inset);
  color: var(--text-muted);
  font-size: 0.82rem;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
  margin-top: 6px;
}
.upload-drop-zone i {
  font-size: 1.6rem;
  opacity: 0.4;
  transition: all var(--transition);
}
.upload-drop-zone strong { color: var(--accent); }
.drop-hint {
  font-size: 0.7rem;
  color: var(--text-muted);
  opacity: 0.7;
}

/* Hover & drag-over drop zone */
.upload-drop-zone:hover,
.upload-drop-zone.drag-active {
  border-color: var(--accent);
  background: rgba(124, 92, 191, 0.05);
  color: var(--text-secondary);
}
.upload-drop-zone:hover i,
.upload-drop-zone.drag-active i {
  opacity: 0.8;
  color: var(--accent);
  transform: translateY(-3px);
}
.upload-drop-zone.drag-active {
  border-style: solid;
  box-shadow: 0 0 0 3px var(--accent-glow), var(--neu-shadow-inset);
  animation: dropPulse 1s ease infinite;
}
@keyframes dropPulse {
  0%, 100% { box-shadow: 0 0 0 3px var(--accent-glow), var(--neu-shadow-inset); }
  50%       { box-shadow: 0 0 0 6px rgba(124,92,191,0.15), var(--neu-shadow-inset); }
}

/* ── Audio Preview Box ──────────────────────────────────────── */
.audio-preview-box {
  background: var(--surface);
  border-radius: 14px;
  box-shadow: var(--neu-shadow-sm);
  padding: 14px 16px;
  margin-top: 8px;
  animation: fadeSlideIn 0.3s ease;
}

.audio-preview-info {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.audio-preview-icon {
  font-size: 1.6rem;
  color: var(--accent);
  flex-shrink: 0;
}
.audio-preview-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.audio-preview-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.audio-preview-size {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* Tombol hapus pilihan */
.audio-remove-btn {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--surface);
  box-shadow: var(--neu-shadow-sm);
  color: var(--danger);
  font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: all var(--transition);
  cursor: pointer;
}
.audio-remove-btn:hover {
  background: var(--danger);
  color: #fff;
  box-shadow: 0 3px 10px var(--danger-glow);
}

/* Audio player HTML5 – styling kustom */
.audio-preview-player {
  width: 100%;
  height: 40px;
  border-radius: 10px;
  outline: none;
  accent-color: var(--accent);
}
/* Webkit custom scrollbar untuk audio player */
.audio-preview-player::-webkit-media-controls-panel {
  background: var(--surface);
  border-radius: 10px;
}

/* ── Image Preview Box ──────────────────────────────────────── */
.image-preview-box {
  background: var(--surface);
  border-radius: 14px;
  box-shadow: var(--neu-shadow-sm);
  padding: 14px 16px;
  margin-top: 8px;
  animation: fadeSlideIn 0.3s ease;
}
.image-preview-inner {
  display: flex;
  align-items: center;
  gap: 16px;
}
.image-preview-thumb {
  width: 72px;
  height: 72px;
  border-radius: 10px;
  object-fit: cover;
  box-shadow: var(--neu-shadow-sm);
  flex-shrink: 0;
}
.image-preview-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.image-preview-meta .audio-remove-btn {
  width: auto;
  height: auto;
  border-radius: 8px;
  padding: 5px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  gap: 5px;
  display: inline-flex;
  margin-top: 4px;
  align-self: flex-start;
}

/* ── Animasi muncul ─────────────────────────────────────────── */
@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* code inline di hint */
.field-hint code {
  background: var(--surface);
  box-shadow: var(--neu-shadow-sm);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.7rem;
  color: var(--accent);
  font-family: monospace;
}

/* ── Status upload di tombol (saat file dipilih) ────────────── */
.upload-pick-btn.has-file {
  background: linear-gradient(135deg, var(--success), #059669);
  box-shadow: 0 4px 14px rgba(16,185,129,0.35);
}

.field-error { font-size: 0.72rem; color: var(--danger); min-height: 16px; }
.field-hint  { font-size: 0.72rem; color: var(--text-muted); }


.form-actions {
  display: flex; gap: 12px; justify-content: flex-end;
  padding-top: 8px; border-top: 1px solid var(--shadow-dark);
}

/* ================================================================
   15. FORM SIDEBAR (Preview + Warna)
================================================================ */
.form-sidebar { display: flex; flex-direction: column; gap: 18px; }

.preview-card { text-align: center; }
.preview-album {
  display: flex; justify-content: center; margin: 8px 0 14px;
}
#preview-canvas {
  border-radius: 50%;
  box-shadow: var(--neu-shadow);
  width: 160px; height: 160px;
}
.preview-title  { font-size: 0.9rem; font-weight: 700; color: var(--text-primary); }
.preview-artist { font-size: 0.78rem; color: var(--accent); margin-top: 3px; }
.preview-genre  { font-size: 0.68rem; color: var(--text-muted); margin-top: 2px; }

.color-pickers { display: flex; gap: 16px; margin-bottom: 14px; }
.color-group { display: flex; flex-direction: column; gap: 6px; align-items: center; flex: 1; }
.color-group label { font-size: 0.72rem; font-weight: 600; color: var(--text-secondary); }
.color-input {
  width: 100%; height: 42px; border: none; border-radius: 10px;
  cursor: pointer; box-shadow: var(--neu-shadow-sm);
  background: none; padding: 2px;
}

.preset-label { font-size: 0.72rem; color: var(--text-muted); margin-bottom: 8px; font-weight: 500; }
.preset-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.preset-swatch {
  width: 100%; aspect-ratio: 1; border-radius: 8px;
  cursor: pointer; border: 2px solid transparent;
  box-shadow: var(--neu-shadow-sm);
  transition: transform var(--transition), border-color var(--transition);
}
.preset-swatch:hover { transform: scale(1.15); }
.preset-swatch.active { border-color: var(--text-primary); }

/* ================================================================
   16. SETTINGS PAGE
================================================================ */
.settings-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.settings-list { display: flex; flex-direction: column; gap: 2px; }
.setting-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0; border-bottom: 1px solid var(--shadow-dark);
}
.setting-item:last-child { border-bottom: none; }
.setting-title { font-size: 0.85rem; font-weight: 600; color: var(--text-primary); margin-bottom: 2px; }
.setting-desc  { font-size: 0.75rem; color: var(--text-muted); }

.storage-stats { display: flex; flex-direction: column; gap: 12px; }
.storage-item {
  display: flex; flex-direction: column; gap: 4px;
}
.storage-key { font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); }
.storage-val { font-size: 0.8rem; color: var(--text-primary); word-break: break-all; }

.about-card .about-content { text-align: center; padding: 10px 0; }
.about-content h4 {
  font-size: 1.1rem; font-weight: 700; margin: 12px 0 4px;
  background: var(--accent-grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.about-content > p { font-size: 0.75rem; color: var(--text-muted); }
.about-desc { font-size: 0.8rem; color: var(--text-secondary); margin: 10px 0; line-height: 1.6; }
.tech-badges { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.badge {
  padding: 4px 12px; border-radius: 50px;
  background: var(--surface); box-shadow: var(--neu-shadow-sm);
  font-size: 0.7rem; font-weight: 600; color: var(--accent);
}
.about-logo { display: flex; justify-content: center; }

/* ================================================================
   17. MODAL
================================================================ */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999; opacity: 0; pointer-events: none;
  transition: opacity var(--transition);
  backdrop-filter: blur(4px);
}
.modal-overlay.show { opacity: 1; pointer-events: all; }

.modal-box {
  background: var(--surface); border-radius: 24px;
  box-shadow: var(--neu-shadow), 0 20px 60px rgba(0,0,0,0.3);
  padding: 36px 32px; max-width: 380px; width: 90%;
  text-align: center;
  transform: scale(0.9); transition: transform var(--transition);
}
.modal-overlay.show .modal-box { transform: scale(1); }

.modal-icon {
  width: 60px; height: 60px; border-radius: 50%; margin: 0 auto 16px;
  background: var(--surface); box-shadow: var(--neu-shadow);
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; color: var(--danger);
}
.modal-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 10px; }
.modal-body  { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 24px; line-height: 1.5; }
.modal-actions { display: flex; gap: 12px; justify-content: center; }

/* ================================================================
   18. TOAST
================================================================ */
.toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(60px);
  background: var(--surface); box-shadow: var(--neu-shadow), 0 0 20px var(--accent-glow);
  color: var(--text-primary); padding: 12px 24px;
  border-radius: 50px; font-size: 0.85rem; font-weight: 500;
  opacity: 0; transition: all 0.3s ease; pointer-events: none;
  z-index: 9998; white-space: nowrap;
  border-left: 3px solid var(--accent);
}
.toast.show {
  opacity: 1; transform: translateX(-50%) translateY(0);
}

/* ================================================================
   19. SCROLLBAR
================================================================ */
* { scrollbar-width: thin; scrollbar-color: var(--shadow-dark) transparent; }
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--shadow-dark); border-radius: 4px; }

/* ================================================================
   20. RESPONSIVE – TABLET ≤ 1024px
================================================================ */
@media (max-width: 1024px) {
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .settings-grid { grid-template-columns: 1fr; }
  .form-layout { grid-template-columns: 1fr; }
  .form-sidebar { flex-direction: row; flex-wrap: wrap; }
  .form-sidebar .neu-card { flex: 1; min-width: 240px; }
}

/* ================================================================
   21. RESPONSIVE – MOBILE ≤ 768px
================================================================ */
@media (max-width: 768px) {
  :root { --sidebar-w: 260px; }

  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: var(--neu-shadow), 4px 0 30px rgba(0,0,0,0.2);
  }
  .sidebar-overlay.show { display: block; }
  .content-wrapper { margin-left: 0; }
  .sidebar-toggle-btn { display: flex; }

  .main-area { padding: 18px 16px 30px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .stat-card { padding: 14px; }

  .toolbar { flex-direction: column; align-items: stretch; }
  .search-box { max-width: 100%; }
  .toolbar-right { justify-content: space-between; }

  .form-row { grid-template-columns: 1fr; }
  .form-layout { grid-template-columns: 1fr; }
  .form-sidebar { flex-direction: column; }
}

@media (max-width: 480px) {
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .quick-actions { flex-direction: column; }
  .action-btn { width: 100%; justify-content: center; }
}

/* ================================================================
   22. FOCUS & ACCESSIBILITY
================================================================ */
.neu-input:focus-visible,
.neu-btn:focus-visible,
.nav-item:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ================================================================
   23. ANIMASI ROWS (delay per baris)
================================================================ */
@keyframes rowSlide {
  from { opacity:0; transform:translateX(-8px); }
  to   { opacity:1; transform:translateX(0); }
}
.songs-table tbody tr {
  animation: rowSlide 0.2s ease forwards;
}
