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

body {
  font-family: 'Fredoka', sans-serif;
  background: linear-gradient(145deg, #fff5f5 0%, #ffe4e8 50%, #ffd6e0 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

.app-container {
  min-height: 100vh;
  position: relative;
  overflow: hidden;
}

.strawberry-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.floating-strawberry {
  position: absolute;
  font-size: 24px;
  opacity: 0.15;
  animation: float-up 20s linear infinite;
}

@keyframes float-up {
  0% {
    transform: translateY(100vh) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.15;
  }
  90% {
    opacity: 0.15;
  }
  100% {
    transform: translateY(-100px) rotate(360deg);
    opacity: 0;
  }
}

.main-content {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.header {
  text-align: center;
  padding: 20px 0;
}

.title {
  font-size: 2.5rem;
  font-weight: 700;
  color: #be123c;
  text-shadow: 2px 2px 0 rgba(255, 255, 255, 0.8);
  margin-bottom: 8px;
}

.tagline {
  font-size: 1.1rem;
  color: #9f1239;
  font-weight: 500;
}

.grid-container {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  border-radius: 24px;
  padding: 24px;
  box-shadow: 
    0 10px 40px rgba(190, 18, 60, 0.1),
    0 0 0 1px rgba(255, 255, 255, 0.8) inset;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
}

.grid-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.row-label {
  width: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.label-emoji {
  font-size: 1.5rem;
}

.label-text {
  font-size: 0.75rem;
  font-weight: 600;
  color: #9f1239;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cells-container {
  display: flex;
  gap: 6px;
  flex: 1;
}

.cell-wrapper {
  flex: 1;
  position: relative;
}

.cell-wrapper.beat-start::before {
  content: '';
  position: absolute;
  left: -3px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: rgba(190, 18, 60, 0.2);
  border-radius: 1px;
}

.cell-wrapper.playhead::after {
  content: '';
  position: absolute;
  inset: -4px;
  background: rgba(251, 113, 133, 0.3);
  border-radius: 12px;
  z-index: -1;
  animation: pulse-glow 0.2s ease-out;
}

@keyframes pulse-glow {
  0% {
    transform: scale(0.8);
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 0.5;
  }
}

.cell {
  width: 100%;
  aspect-ratio: 1;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 
    0 2px 4px rgba(0, 0, 0, 0.1),
    0 0 0 1px rgba(255, 255, 255, 0.5) inset;
}

.cell:hover {
  transform: scale(1.08);
  box-shadow: 
    0 4px 8px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(255, 255, 255, 0.6) inset;
}

.cell:active {
  transform: scale(0.95);
}

.cell.active {
  box-shadow: 
    0 4px 12px rgba(244, 63, 94, 0.4),
    0 0 0 2px rgba(255, 255, 255, 0.8) inset;
}

.cell.playing {
  animation: cell-flash 0.15s ease-out;
}

@keyframes cell-flash {
  0% {
    transform: scale(1.15);
    filter: brightness(1.3);
  }
  100% {
    transform: scale(1);
    filter: brightness(1);
  }
}

.empty-state {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: #be123c;
  font-weight: 500;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 20px;
  animation: fade-pulse 2s ease-in-out infinite;
}

@keyframes fade-pulse {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

.controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 20px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  width: 100%;
  box-shadow: 0 4px 20px rgba(190, 18, 60, 0.08);
}

.play-button {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border: none;
  background: linear-gradient(135deg, #f43f5e 0%, #be123c 100%);
  color: white;
  font-size: 1.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 
    0 6px 20px rgba(244, 63, 94, 0.4),
    0 0 0 4px rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
}

.play-button:hover {
  transform: scale(1.08);
  box-shadow: 
    0 8px 25px rgba(244, 63, 94, 0.5),
    0 0 0 4px rgba(255, 255, 255, 0.9);
}

.play-button:active {
  transform: scale(0.98);
}

.play-button.playing {
  animation: pulse-play 1s ease-in-out infinite;
}

@keyframes pulse-play {
  0%, 100% {
    box-shadow: 
      0 6px 20px rgba(244, 63, 94, 0.4),
      0 0 0 4px rgba(255, 255, 255, 0.8);
  }
  50% {
    box-shadow: 
      0 6px 30px rgba(244, 63, 94, 0.6),
      0 0 0 8px rgba(251, 113, 133, 0.3);
  }
}

.bpm-control {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.bpm-label {
  font-size: 1rem;
  font-weight: 600;
  color: #be123c;
}

.bpm-slider {
  width: 150px;
  height: 8px;
  border-radius: 4px;
  background: linear-gradient(to right, #fecdd3, #f43f5e);
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}

.bpm-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: white;
  border: 3px solid #f43f5e;
  box-shadow: 0 2px 8px rgba(244, 63, 94, 0.3);
  cursor: pointer;
  transition: all 0.15s ease;
}

.bpm-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.action-buttons {
  display: flex;
  gap: 12px;
}

.action-button {
  padding: 12px 20px;
  border: none;
  border-radius: 14px;
  font-family: 'Fredoka', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.action-button.blast {
  background: linear-gradient(135deg, #fb7185 0%, #f43f5e 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(244, 63, 94, 0.3);
}

.action-button.blast:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(244, 63, 94, 0.4);
}

.action-button.scrub {
  background: rgba(255, 255, 255, 0.8);
  color: #be123c;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.action-button.scrub:hover {
  transform: translateY(-2px);
  background: white;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.footer {
  padding: 20px;
  text-align: center;
  color: #9f1239;
  font-size: 0.9rem;
}

.footer-link {
  color: #be123c;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.footer-link:hover {
  color: #f43f5e;
  text-decoration: underline;
}

.heart {
  display: inline-block;
  animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .main-content {
    padding: 16px;
    gap: 16px;
  }
  
  .title {
    font-size: 1.8rem;
  }
  
  .tagline {
    font-size: 0.95rem;
  }
  
  .grid-container {
    padding: 16px;
    gap: 8px;
  }
  
  .grid-row {
    gap: 8px;
  }
  
  .row-label {
    width: 50px;
  }
  
  .label-emoji {
    font-size: 1.2rem;
  }
  
  .label-text {
    font-size: 0.6rem;
  }
  
  .cells-container {
    gap: 4px;
  }
  
  .cell {
    border-radius: 6px;
  }
  
  .controls {
    padding: 16px;
    gap: 16px;
  }
  
  .play-button {
    width: 60px;
    height: 60px;
    font-size: 1.5rem;
  }
  
  .bpm-slider {
    width: 120px;
  }
  
  .action-buttons {
    flex-direction: column;
    width: 100%;
  }
  
  .action-button {
    width: 100%;
    padding: 14px;
  }
}

@media (max-width: 480px) {
  .title {
    font-size: 1.5rem;
  }
  
  .row-label {
    width: 40px;
  }
  
  .label-emoji {
    font-size: 1rem;
  }
  
  .label-text {
    font-size: 0.5rem;
  }
  
  .cells-container {
    gap: 3px;
  }
  
  .cell {
    border-radius: 4px;
  }
  
  .cell-wrapper.beat-start::before {
    left: -2px;
    width: 1px;
  }
}