/* ==========================================================================
   Chrods - Design System & Custom Stylesheet
   ========================================================================== */

:root {
  --font-display: 'Outfit', 'Noto Sans JP', sans-serif;
  
  /* Color Palette */
  --bg-dark: #0a0b10;
  --panel-bg: rgba(18, 20, 32, 0.65);
  --panel-border: rgba(255, 255, 255, 0.08);
  
  --primary: #8a2be2;         /* Indigo/Purple */
  --primary-glow: rgba(138, 43, 226, 0.5);
  --secondary: #00f0ff;       /* Cyan */
  --secondary-glow: rgba(0, 240, 255, 0.4);
  
  --success: #00e676;         /* Bright Green */
  --danger: #ff1744;          /* Neon Red */
  --warning: #ffea00;         /* Neon Yellow */
  
  --text-primary: #f5f6fa;
  --text-muted: #8b92b6;
  --text-dim: #545b85;
  
  --glass-blur: 16px;
  --border-radius-lg: 16px;
  --border-radius-md: 10px;
  --border-radius-sm: 6px;
  
  --transition-smooth: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Reset & Global Base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: var(--font-display);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  line-height: 1.5;
}

/* Dynamic Ambient Glow Background */
.glow-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.15;
  mix-blend-mode: screen;
}

.orb-1 {
  background: var(--primary);
  width: 500px;
  height: 500px;
  top: -10%;
  left: -10%;
  animation: floatOrb 25s infinite alternate;
}

.orb-2 {
  background: var(--secondary);
  width: 450px;
  height: 450px;
  bottom: 10%;
  right: -5%;
  animation: floatOrb 30s infinite alternate-reverse;
}

.orb-3 {
  background: #ff007f;
  width: 350px;
  height: 350px;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation: floatOrb 35s infinite ease-in-out;
}

@keyframes floatOrb {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(40px, -60px) scale(1.1); }
  100% { transform: translate(-30px, 30px) scale(0.9); }
}

/* Layout Container */
.app-container {
  max-width: 1440px;
  margin: 0 auto;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  min-height: 100vh;
}

/* Header */
.app-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  border-bottom: 1px solid var(--panel-border);
  padding-bottom: 1.2rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.logo-icon {
  font-size: 2.2rem;
  background: linear-gradient(135deg, var(--secondary), var(--primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 10px var(--primary-glow));
  animation: pulseLogo 3s infinite ease-in-out;
}

@keyframes pulseLogo {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.08) rotate(-5deg); }
}

.logo h1 {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  background: linear-gradient(180deg, #ffffff, #dcdff0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.badge {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 0.75rem;
  padding: 2px 8px;
  border-radius: 20px;
  color: var(--text-muted);
}

.tagline {
  color: var(--text-muted);
  font-size: 0.95rem;
  flex: 1 1 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Status Indicators */
.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  padding: 6px 12px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--panel-border);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
}

.status-off .status-dot {
  background-color: var(--text-dim);
  box-shadow: 0 0 4px var(--text-dim);
}

.status-on .status-dot {
  background-color: var(--success);
  box-shadow: 0 0 8px var(--success);
  animation: pulseGreen 1.5s infinite;
}

@keyframes pulseGreen {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}

.status-text {
  color: var(--text-muted);
}

/* Panels Common */
.panel {
  border-radius: var(--border-radius-lg);
  border: 1px solid var(--panel-border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.glass {
  background: var(--panel-bg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

.panel-header {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--panel-border);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  background: rgba(255, 255, 255, 0.02);
}

.panel-header i {
  color: var(--secondary);
  font-size: 1.2rem;
  text-shadow: 0 0 8px var(--secondary-glow);
}

.panel-header h2 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

/* Layout Main Body Split */
.app-main {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
}

@media (max-width: 1024px) {
  .app-main {
    grid-template-columns: 1fr;
  }
}

/* Panel Elements & Form Controls */
.settings-group {
  padding: 1.2rem 1.5rem 0.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.setting-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.scale-selector {
  display: grid;
  grid-template-columns: 1fr 1.5fr auto;
  gap: 0.8rem;
}

.select-control {
  background: rgba(10, 11, 16, 0.7);
  border: 1px solid var(--panel-border);
  color: var(--text-primary);
  padding: 0.6rem 1rem;
  border-radius: var(--border-radius-md);
  font-family: var(--font-display);
  font-size: 0.95rem;
  cursor: pointer;
  outline: none;
  transition: var(--transition-smooth);
}

.select-control:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 2px var(--secondary-glow);
}

.select-control option {
  background-color: var(--bg-dark);
  color: var(--text-primary);
}

/* Buttons System */
.btn {
  font-family: var(--font-display);
  padding: 0.6rem 1.2rem;
  border-radius: var(--border-radius-md);
  border: none;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: var(--transition-smooth);
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #b05cff);
  color: white;
  box-shadow: 0 4px 15px rgba(138, 43, 226, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #993bf0, #c078ff);
  box-shadow: 0 6px 20px rgba(138, 43, 226, 0.5);
}

.btn-glowing {
  position: relative;
  overflow: hidden;
}

.btn-glowing::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255,255,255,0.15), transparent);
  transform: rotate(45deg);
  transition: 0.5s;
  pointer-events: none;
}

.btn-glowing:hover::after {
  left: 120%;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-success {
  background: linear-gradient(135deg, #00c853, #5cff9c);
  color: #05260f;
  box-shadow: 0 4px 12px rgba(0, 230, 118, 0.2);
}

.btn-success:hover {
  background: linear-gradient(135deg, #00e676, #80ffbc);
  box-shadow: 0 6px 16px rgba(0, 230, 118, 0.4);
}

.btn-danger {
  background: linear-gradient(135deg, #d50000, #ff5c7d);
  color: white;
  box-shadow: 0 4px 12px rgba(255, 23, 68, 0.2);
}

.btn-danger:hover {
  background: linear-gradient(135deg, #ff1744, #ff809b);
  box-shadow: 0 6px 16px rgba(255, 23, 68, 0.4);
}

/* Chord Type Selector Buttons */
.chord-type-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.type-btn {
  flex: 1 1 calc(25% - 0.4rem);
  min-width: 60px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  padding: 6px 8px;
  border-radius: var(--border-radius-sm);
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.type-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
}

.type-btn.active {
  background: rgba(0, 240, 255, 0.12);
  border-color: var(--secondary);
  color: var(--secondary);
  box-shadow: 0 0 8px var(--secondary-glow);
}

/* Chord Pad Grids */
.chord-grid-container {
  padding: 1rem 1.5rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  overflow-y: auto;
}

.section-title-sm {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 0.8rem;
}

.chord-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.8rem;
}

@media (max-width: 480px) {
  .chord-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Chord Pad Button */
.chord-pad {
  aspect-ratio: 1.1;
  border-radius: var(--border-radius-md);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--panel-border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 0.8rem 0.5rem 0.5rem 0.5rem;
  cursor: pointer;
  position: relative;
  transition: var(--transition-smooth);
  user-select: none;
}

.chord-pad:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
}

.chord-pad:active {
  transform: translateY(0);
}

.chord-pad.active {
  background: linear-gradient(135deg, rgba(138, 43, 226, 0.25), rgba(0, 240, 255, 0.15));
  border-color: var(--secondary);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.3), inset 0 0 10px rgba(138, 43, 226, 0.2);
}

.chord-pad .chord-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: white;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
  transition: var(--transition-smooth);
}

.chord-pad.active .chord-name {
  color: var(--secondary);
  text-shadow: 0 0 8px var(--secondary-glow);
}

.chord-pad .chord-roman {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.chord-pad.active .chord-roman {
  color: rgba(255, 255, 255, 0.8);
}

.chord-add-btn {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  border: none;
  cursor: pointer;
  position: absolute;
  top: 6px;
  right: 6px;
  opacity: 0;
  transition: var(--transition-smooth);
}

.chord-pad:hover .chord-add-btn {
  opacity: 1;
}

.chord-add-btn:hover {
  background: var(--secondary);
  color: #0a0b10;
  transform: scale(1.15);
}

/* Right Panel Elements */
.synth-controls-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  padding: 1.2rem 1.5rem 0.5rem 1.5rem;
}

@media (max-width: 580px) {
  .synth-controls-grid {
    grid-template-columns: 1fr;
  }
}

.control-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--panel-border);
  border-radius: var(--border-radius-md);
  padding: 0.8rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.control-card-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Sound Model Buttons */
.sound-model-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.stroke-direction-selector {
  display: flex;
  gap: 0.4rem;
}

.model-btn {
  flex: 1 1 calc(33.33% - 0.4rem);
  min-width: 80px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  padding: 6px 4px;
  border-radius: var(--border-radius-sm);
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.stroke-btn {
  flex: 1;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  padding: 6px 4px;
  border-radius: var(--border-radius-sm);
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.model-btn:hover, .stroke-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
}

.model-btn.active, .stroke-btn.active {
  background: linear-gradient(135deg, rgba(138, 43, 226, 0.2), rgba(0, 240, 255, 0.1));
  border-color: var(--primary);
  color: var(--text-primary);
  box-shadow: 0 0 8px rgba(138, 43, 226, 0.3);
}

/* Sliders */
.slider-card {
  justify-content: space-between;
}

.slider-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
}

.range-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.1);
  outline: none;
  margin: 10px 0 5px 0;
  transition: var(--transition-smooth);
}

.range-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--secondary);
  cursor: pointer;
  box-shadow: 0 0 6px var(--secondary-glow);
  transition: var(--transition-smooth);
}

.range-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
  background: white;
}

/* Virtual Guitar String Board */
.guitar-board-wrapper {
  padding: 1rem 1.5rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  flex-grow: 1;
}

.guitar-fret-marker-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.string-names {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 220px;
  font-size: 0.75rem;
  font-weight: bold;
  color: var(--text-muted);
  width: 45px;
  padding: 10px 0;
}

.guitar-board {
  height: 240px;
  background: linear-gradient(90deg, #1b1c26 0%, #11121b 100%);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--border-radius-md);
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 4px 20px rgba(0,0,0,0.8);
  display: flex;
  align-items: center;
  padding: 10px 20px;
}

.guitar-board::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 12px;
  background: #3e4256; /* Guitar Nut */
  box-shadow: 2px 0 8px rgba(0,0,0,0.6);
  z-index: 2;
}

.current-chord-badge-container {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.4);
  padding: 4px 10px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  z-index: 10;
}

.active-chord-name-badge {
  color: var(--secondary);
  font-weight: 700;
  font-size: 0.95rem;
}

.strings-container {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  width: 100%;
  position: relative;
  z-index: 3;
}

.guitar-string-wrapper {
  height: 36px;
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  cursor: pointer;
}

/* The actual physical looking string */
.string-line {
  width: 100%;
  background: linear-gradient(180deg, #e4e7f5 0%, #7b809a 100%);
  box-shadow: 0 1px 2px rgba(0,0,0,0.4);
  pointer-events: none;
  transition: transform 0.05s linear;
}

/* Thicker strings on bottom (low pitch), thinner on top */
.guitar-string-wrapper[data-string="5"] .string-line { height: 4.5px; }
.guitar-string-wrapper[data-string="4"] .string-line { height: 3.8px; }
.guitar-string-wrapper[data-string="3"] .string-line { height: 3.0px; }
.guitar-string-wrapper[data-string="2"] .string-line { height: 2.2px; }
.guitar-string-wrapper[data-string="1"] .string-line { height: 1.6px; }
.guitar-string-wrapper[data-string="0"] .string-line { height: 1.0px; }

/* Large invisible hover hitbox for easier playing */
.string-trigger-zone {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
}

/* Vibration Animation */
@keyframes stringVibrate {
  0% { transform: translateY(0) scaleY(1); }
  10% { transform: translateY(-4px) scaleY(1.3); }
  20% { transform: translateY(3px) scaleY(0.7); }
  30% { transform: translateY(-2px) scaleY(1.1); }
  40% { transform: translateY(2px) scaleY(0.8); }
  60% { transform: translateY(-1px) scaleY(1.05); }
  80% { transform: translateY(1px) scaleY(0.95); }
  100% { transform: translateY(0) scaleY(1); }
}

.guitar-string-wrapper.vibrating .string-line {
  animation: stringVibrate 0.6s ease-out;
  background: var(--secondary) !important;
  box-shadow: 0 0 10px var(--secondary-glow);
}

.fret-indicator {
  position: absolute;
  right: 10px;
  background: rgba(0, 0, 0, 0.7);
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.65rem;
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: bold;
  pointer-events: none;
  transition: var(--transition-smooth);
}

.guitar-string-wrapper.vibrating .fret-indicator {
  color: var(--secondary);
  border-color: var(--secondary-glow);
  transform: scale(1.1);
}

.guitar-string-wrapper.muted .string-line {
  opacity: 0.25;
}
.guitar-string-wrapper.muted .fret-indicator {
  color: var(--text-dim);
  text-decoration: line-through;
}

.guitar-instruction {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
}

/* Sequencer Panel (Bottom) */
.sequencer-header {
  flex-direction: row;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.2rem;
}

.sequencer-title {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.sequencer-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
}

.tempo-control, .pattern-control {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.tempo-label, .pattern-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
}

.bpm-badge {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--panel-border);
  color: var(--secondary);
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.85rem;
  min-width: 36px;
  text-align: center;
}

.bpm-range {
  width: 100px;
}

.pattern-select {
  padding: 4px 8px;
  font-size: 0.85rem;
  border-radius: 6px;
}

/* Timeline Container & Cards */
.timeline-container {
  padding: 1.5rem;
  background: rgba(0, 0, 0, 0.2);
  border-bottom: 1px solid var(--panel-border);
}

.timeline-scroll-area {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  min-height: 110px;
  padding: 0.5rem 0.2rem 1rem 0.2rem;
  scroll-behavior: smooth;
}

/* Scrollbar styles for timeline */
.timeline-scroll-area::-webkit-scrollbar, .chord-grid-container::-webkit-scrollbar {
  height: 8px;
  width: 6px;
}
.timeline-scroll-area::-webkit-scrollbar-track, .chord-grid-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 4px;
}
.timeline-scroll-area::-webkit-scrollbar-thumb, .chord-grid-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 4px;
}
.timeline-scroll-area::-webkit-scrollbar-thumb:hover, .chord-grid-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.25);
}

.empty-timeline-message {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  color: var(--text-dim);
  gap: 0.5rem;
  font-size: 0.9rem;
}

.empty-timeline-message i {
  font-size: 1.8rem;
}

/* Sequencer Chord Cards */
.timeline-card {
  flex: 0 0 90px;
  height: 95px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--panel-border);
  border-radius: var(--border-radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  user-select: none;
  transition: var(--transition-smooth);
}

.timeline-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.timeline-card.active-beat {
  background: linear-gradient(135deg, rgba(0, 230, 118, 0.2), rgba(0, 240, 255, 0.15));
  border-color: var(--success);
  box-shadow: 0 0 15px rgba(0, 230, 118, 0.3);
  transform: scale(1.04);
}

.timeline-card .card-name {
  font-size: 1.3rem;
  font-weight: 700;
  color: white;
}

.timeline-card.active-beat .card-name {
  color: var(--success);
  text-shadow: 0 0 6px rgba(0, 230, 118, 0.4);
}

.timeline-card .card-index {
  font-size: 0.65rem;
  color: var(--text-dim);
  position: absolute;
  top: 6px;
  left: 8px;
}

.card-remove-btn {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-dim);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.65rem;
  opacity: 0;
  transition: var(--transition-smooth);
}

.timeline-card:hover .card-remove-btn {
  opacity: 1;
}

.card-remove-btn:hover {
  background: var(--danger);
  color: white;
}

/* Card shift controls (left/right rearrangement) */
.card-shift-btn {
  position: absolute;
  bottom: 4px;
  background: none;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  font-size: 0.65rem;
  opacity: 0;
  transition: var(--transition-smooth);
}

.timeline-card:hover .card-shift-btn {
  opacity: 1;
}

.card-shift-btn:hover {
  color: var(--secondary);
}

.btn-shift-left { left: 8px; }
.btn-shift-right { right: 8px; }

/* Preset Suggestions Row */
.suggestions-container {
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  background: rgba(255, 255, 255, 0.01);
}

.suggestion-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 600;
}

.presets-list {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.preset-btn {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--panel-border);
  color: var(--text-muted);
  font-size: 0.8rem;
  padding: 4px 10px;
  border-radius: 15px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.preset-btn:hover {
  background: rgba(138, 43, 226, 0.1);
  border-color: var(--primary);
  color: var(--text-primary);
}

/* Responsive fixes */
@media (max-width: 768px) {
  .app-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .header-actions {
    width: 100%;
    justify-content: space-between;
  }
  .sequencer-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .sequencer-actions {
    width: 100%;
    justify-content: space-between;
  }
}
