@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --primary: #00d4ff;
  --primary-dark: #0099cc;
  --primary-light: #66e5ff;
  --secondary: #ff0066;
  --accent: #00ff99;
  --bg-dark: #0d0d0d;
  --bg-card: #1a1a1a;
  --bg-elevated: #262626;
  --text-primary: #ffffff;
  --text-secondary: #cccccc;
  --text-muted: #808080;
  --border: #333333;
  --success: #00cc66;
  --error: #ff3333;
  --rekordbox-orange: #ff6600;
  --rekordbox-blue: #00ccff;
  --rekordbox-purple: #9933ff;
  --gradient-1: linear-gradient(135deg, #00d4ff 0%, #0099ff 100%);
  --gradient-2: linear-gradient(135deg, #ff6600 0%, #ff3366 100%);
  --gradient-rekordbox: linear-gradient(135deg, #00d4ff 0%, #0099ff 50%, #9933ff 100%);
  --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.8);
  --shadow-glow: 0 0 40px rgba(0, 212, 255, 0.3);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-dark);
  background-image: 
    radial-gradient(ellipse at top, rgba(0, 212, 255, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at bottom right, rgba(255, 102, 0, 0.1) 0%, transparent 50%),
    radial-gradient(ellipse at bottom left, rgba(153, 51, 255, 0.1) 0%, transparent 50%),
    linear-gradient(180deg, #0d0d0d 0%, #1a1a2e 100%);
  min-height: 100vh;
  color: var(--text-primary);
  padding: 2rem;
  line-height: 1.7;
}

.container {
  max-width: 700px;
  width: 100%;
  margin: 0 auto 2rem;
  padding: 2.5rem;
  background: linear-gradient(145deg, rgba(26, 26, 26, 0.95) 0%, rgba(18, 18, 18, 0.98) 100%);
  backdrop-filter: blur(20px);
  border-radius: 4px;
  border: 1px solid rgba(0, 212, 255, 0.2);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(0, 212, 255, 0.1);
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  color: #ffffff;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 2px;
  position: relative;
}

h3::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--gradient-rekordbox);
  margin: 10px auto 0;
  border-radius: 2px;
}

.drag-area {
  height: 200px;
  border: 2px dashed rgba(0, 212, 255, 0.3);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  margin: 1.5rem 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: linear-gradient(145deg, rgba(20, 20, 20, 0.8) 0%, rgba(30, 30, 30, 0.8) 100%);
  position: relative;
  overflow: hidden;
}

.drag-area::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 212, 255, 0.05) 0%, rgba(255, 102, 0, 0.05) 100%);
  opacity: 0;
  transition: opacity 0.3s;
}

.drag-area.active {
  border-color: var(--primary);
  background: linear-gradient(145deg, rgba(0, 212, 255, 0.1) 0%, rgba(0, 153, 255, 0.1) 100%);
  transform: scale(1.02);
  box-shadow: var(--shadow-glow), inset 0 0 30px rgba(0, 212, 255, 0.05);
}

.drag-area.active::before {
  opacity: 1;
}

.drag-area .icon {
  font-size: 3.5rem;
  color: var(--primary);
  filter: drop-shadow(0 0 10px rgba(0, 212, 255, 0.5));
  margin-bottom: 1rem;
  z-index: 1;
}

.drag-area .header {
  font-size: 1.25rem;
  font-weight: 600;
  color: #ffffff;
  z-index: 1;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.drag-area .support {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
  z-index: 1;
}

.drag-area .button {
  font-size: 1rem;
  font-weight: 700;
  color: var(--primary);
  cursor: pointer;
  transition: all 0.3s;
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.3);
}

.drag-area .button:hover {
  color: var(--primary-light);
  text-shadow: 0 0 20px rgba(0, 212, 255, 0.6);
}


h1 {
  font-size: 2.5rem;
  font-weight: 700;
  text-align: center;
  margin: 3rem 0 2rem;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 4px;
  position: relative;
  display: inline-block;
  left: 50%;
  transform: translateX(-50%);
}

h1::before,
h1::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 60px;
  height: 2px;
  background: var(--gradient-rekordbox);
}

h1::before {
  right: 100%;
  margin-right: 20px;
}

h1::after {
  left: 100%;
  margin-left: 20px;
}

.filters {
  background: linear-gradient(145deg, rgba(26, 26, 26, 0.95) 0%, rgba(18, 18, 18, 0.98) 100%);
  backdrop-filter: blur(20px);
  padding: 1.5rem;
  border-radius: 4px;
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  border: 1px solid rgba(0, 212, 255, 0.15);
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.05);
}

.filter-group {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 180px;
}

.filter-group.button-group {
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.75rem;
  flex: none;
}

label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--primary-light);
  margin-bottom: 0.5rem;
}

input, select {
  width: 100%;
  padding: 0.75rem 1rem;
  background: rgba(15, 15, 15, 0.9);
  border: 1px solid rgba(0, 212, 255, 0.2);
  border-radius: 4px;
  font-size: 0.9rem;
  color: #ffffff;
  transition: all 0.3s;
  font-family: inherit;
}

input::placeholder {
  color: var(--text-muted);
}

input:focus, select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.3), 0 0 15px rgba(0, 212, 255, 0.2);
}

select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%2300d4ff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
  background-size: 1rem;
  padding-right: 2.5rem;
}

button {
  background: var(--gradient-rekordbox);
  color: white;
  border: none;
  padding: 0.875rem 1.25rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 700;
  font-size: 0.8rem;
  font-family: inherit;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
  min-width: 140px;
  text-align: center;
}

button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 212, 255, 0.5);
  filter: brightness(1.1);
}

button:active {
  transform: translateY(0);
}

#reset-filters {
  background: linear-gradient(135deg, #ff3333 0%, #ff6600 100%);
  box-shadow: 0 4px 15px rgba(255, 51, 51, 0.3);
}

#reset-filters:hover {
  box-shadow: 0 6px 20px rgba(255, 51, 51, 0.5);
}

.toggle-btn {
  background: linear-gradient(145deg, rgba(50, 50, 50, 0.8) 0%, rgba(40, 40, 40, 0.8) 100%);
  box-shadow: none;
  border: 1px solid rgba(0, 212, 255, 0.3);
}

.toggle-btn:hover {
  background: linear-gradient(145deg, rgba(60, 60, 60, 0.9) 0%, rgba(50, 50, 50, 0.9) 100%);
  box-shadow: none;
  border-color: var(--primary);
}

.toggle-btn.active {
  background: linear-gradient(135deg, #00cc66 0%, #00ff99 100%);
  box-shadow: 0 4px 15px rgba(0, 204, 102, 0.4);
  border-color: transparent;
}

#download-btn {
  background: linear-gradient(135deg, #ff6600 0%, #ff9933 100%);
  box-shadow: 0 4px 15px rgba(255, 102, 0, 0.3);
}

#download-btn:hover {
  box-shadow: 0 6px 20px rgba(255, 102, 0, 0.5);
}

#loading {
  text-align: center;
  padding: 3rem;
  color: var(--text-secondary);
  font-size: 1.1rem;
}

#table-container {
  background: linear-gradient(145deg, rgba(26, 26, 26, 0.95) 0%, rgba(18, 18, 18, 0.98) 100%);
  backdrop-filter: blur(20px);
  border-radius: 4px;
  border: 1px solid rgba(0, 212, 255, 0.15);
  overflow: hidden;
  margin-bottom: 1.5rem;
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.05);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  padding: 1rem 1.25rem;
  text-align: left;
  border-bottom: 1px solid rgba(51, 51, 51, 0.8);
}

th {
  background: linear-gradient(145deg, rgba(30, 30, 30, 0.95) 0%, rgba(20, 20, 20, 0.98) 100%);
  color: var(--primary-light);
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  position: sticky;
  top: 0;
  cursor: pointer;
  user-select: none;
  transition: all 0.3s;
  border-bottom: 2px solid rgba(0, 212, 255, 0.3);
}

th:hover {
  background: rgba(0, 212, 255, 0.15);
  color: var(--primary);
}

th.sort-asc, th.sort-desc {
  color: var(--primary);
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

th::after {
  content: '';
  display: inline-block;
  margin-left: 0.5rem;
  font-size: 0.75rem;
}

th.sort-asc::after {
  content: '↑';
}

th.sort-desc::after {
  content: '↓';
}

tr {
  transition: background 0.3s;
}

tr:hover {
  background: linear-gradient(90deg, rgba(0, 212, 255, 0.1) 0%, transparent 100%);
}

td {
  color: #cccccc;
  font-size: 0.9rem;
}

.track-number {
  width: 60px;
  text-align: center;
  color: var(--text-muted);
  font-weight: 600;
  font-family: 'Monaco', 'Consolas', monospace;
}

.track-title {
  width: 50%;
  font-weight: 600;
  color: #ffffff;
}

.track-title:hover {
  color: var(--primary-light);
}

.artist {
  width: 30%;
  color: #999999;
}

.key {
  font-family: 'Monaco', 'Consolas', monospace;
  background: linear-gradient(145deg, rgba(0, 212, 255, 0.15) 0%, rgba(0, 153, 255, 0.15) 100%);
  padding: 0.35rem 0.75rem;
  border-radius: 4px;
  color: var(--primary);
  font-weight: 700;
  font-size: 0.8rem;
  border: 1px solid rgba(0, 212, 255, 0.2);
  text-shadow: 0 0 5px rgba(0, 212, 255, 0.3);
}

.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.pagination button {
  background: linear-gradient(145deg, rgba(30, 30, 30, 0.9) 0%, rgba(20, 20, 20, 0.95) 100%);
  border: 1px solid rgba(0, 212, 255, 0.2);
  padding: 0.6rem 1rem;
  min-width: 44px;
  font-size: 0.85rem;
  box-shadow: none;
  color: #999999;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.pagination button:hover {
  background: rgba(0, 212, 255, 0.15);
  border-color: var(--primary);
  transform: translateY(-1px);
  color: var(--primary);
}

.pagination button.active {
  background: var(--gradient-rekordbox);
  border-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 0 15px rgba(0, 212, 255, 0.4);
}

.no-results {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-muted);
  font-size: 1.1rem;
  background: linear-gradient(145deg, rgba(26, 26, 26, 0.95) 0%, rgba(18, 18, 18, 0.98) 100%);
  border-radius: 4px;
  border: 1px solid rgba(0, 212, 255, 0.15);
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #0d0d0d;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(145deg, #00d4ff 0%, #0099ff 100%);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(145deg, #00e5ff 0%, #00aaff 100%);
}

/* Responsive */
@media (max-width: 768px) {
  body {
    padding: 1rem;
  }
  
  .container {
    padding: 1.5rem;
  }
  
  h1 {
    font-size: 1.75rem;
  }
  
  h3 {
    font-size: 1.25rem;
  }
  
  .filters {
    flex-direction: column;
  }
  
  .filter-group {
    min-width: 100%;
  }
  
  .filter-group.button-group {
    flex-direction: column;
  }
  
  .filter-group.button-group button {
    width: 100%;
  }
  
  table {
    font-size: 0.85rem;
  }
  
  th, td {
    padding: 0.75rem 0.5rem;
  }
}
