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

:root {
  --gradient-1: #2d1b4e;
  --gradient-2: #1a1a2e;
  --gradient-3: #16213e;
  --accent-pink: #ff6b9d;
  --accent-purple: #c77dff;
  --accent-blue: #48cae4;
  --accent-cyan: #4ecdc4;
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.1);
  --text-primary: #ffffff;
  --text-secondary: rgba(255, 255, 255, 0.6);
  --text-muted: rgba(255, 255, 255, 0.4);
}

body {
  font-family: 'Space Grotesk', sans-serif;
  background: linear-gradient(135deg, var(--gradient-1) 0%, var(--gradient-2) 50%, var(--gradient-3) 100%);
  min-height: 100vh;
  color: var(--text-primary);
  overflow-x: hidden;
}

.app-container {
  min-height: 100vh;
  padding: 2rem 1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* Header */
.header-container {
  text-align: center;
  margin-bottom: 2rem;
  padding: 2rem;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border-radius: 24px;
  border: 1px solid var(--glass-border);
}

.header-title {
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent-pink), var(--accent-purple), var(--accent-blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 0.5rem;
}

.eye-roll {
  display: inline-block;
  transition: transform 0.5s ease;
}

.eye-roll.rolling {
  animation: eyeRoll 0.5s ease;
}

@keyframes eyeRoll {
  0% { transform: rotate(0deg); }
  50% { transform: rotate(360deg) scale(1.2); }
  100% { transform: rotate(360deg); }
}

.header-tagline {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 1rem;
}

.header-counter {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.counter-number {
  color: var(--accent-cyan);
  font-weight: 600;
}

/* Task Input */
.task-input-container {
  margin-bottom: 1.5rem;
  position: relative;
}

.meta-message {
  background: linear-gradient(135deg, var(--accent-pink), var(--accent-purple));
  padding: 1rem;
  border-radius: 16px;
  margin-bottom: 1rem;
  text-align: center;
  font-weight: 600;
  animation: shake 0.5s ease;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  75% { transform: translateX(5px); }
}

.task-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.input-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.task-input {
  width: 100%;
  padding: 1.25rem;
  font-size: 1.1rem;
  font-family: 'Space Grotesk', sans-serif;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 2px solid var(--glass-border);
  border-radius: 16px;
  color: var(--text-primary);
  transition: all 0.3s ease;
}

.task-input:focus {
  outline: none;
  border-color: var(--accent-purple);
  box-shadow: 0 0 30px rgba(199, 125, 255, 0.2);
}

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

.vibe-selector {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
}

.vibe-btn {
  padding: 0.5rem 1rem;
  font-size: 1.25rem;
  background: var(--glass-bg);
  border: 2px solid var(--glass-border);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.vibe-btn:hover {
  transform: scale(1.1);
}

.vibe-btn.active {
  border-color: var(--accent-purple);
  background: rgba(199, 125, 255, 0.2);
}

.add-btn {
  padding: 1rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  font-family: 'Space Grotesk', sans-serif;
  background: linear-gradient(135deg, var(--accent-pink), var(--accent-purple));
  border: none;
  border-radius: 16px;
  color: white;
  cursor: pointer;
  transition: all 0.3s ease;
}

.add-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(199, 125, 255, 0.4);
}

.add-btn.pulse {
  animation: pulse 0.3s ease;
}

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

/* Filter Tabs */
.filter-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-tabs {
  display: flex;
  gap: 0.5rem;
}

.filter-tab {
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  font-family: 'Space Grotesk', sans-serif;
  background: transparent;
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.3s ease;
}

.filter-tab:hover {
  color: var(--text-primary);
  border-color: var(--accent-purple);
}

.filter-tab.active {
  background: var(--accent-purple);
  border-color: var(--accent-purple);
  color: white;
}

.clear-btn {
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  font-family: 'Space Grotesk', sans-serif;
  background: transparent;
  border: 1px solid rgba(255, 107, 157, 0.5);
  border-radius: 10px;
  color: var(--accent-pink);
  cursor: pointer;
  transition: all 0.3s ease;
}

.clear-btn:hover {
  background: var(--accent-pink);
  color: white;
}

/* Tasks List */
.tasks-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
  min-height: 100px;
}

.empty-state {
  text-align: center;
  padding: 3rem;
  color: var(--text-muted);
  font-size: 1.1rem;
  background: var(--glass-bg);
  border-radius: 16px;
  border: 1px dashed var(--glass-border);
}

/* Task Item */
.task-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.25rem;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  transition: all 0.3s ease;
  cursor: grab;
  position: relative;
  overflow: hidden;
}

.task-item:hover {
  border-color: var(--accent-purple);
  transform: translateX(4px);
}

.task-item.completed {
  opacity: 0.7;
}

.task-item.deleting {
  animation: slideOut 0.3s ease forwards;
}

@keyframes slideOut {
  to {
    transform: translateX(100%);
    opacity: 0;
  }
}

.task-left {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
  min-width: 0;
}

.checkbox {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 2px solid var(--glass-border);
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1rem;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.checkbox:hover {
  border-color: var(--accent-cyan);
}

.checkbox.checked {
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-purple));
  border-color: transparent;
}

.task-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
}

.task-text {
  font-size: 1rem;
  word-break: break-word;
  transition: all 0.3s ease;
}

.task-text.strike {
  text-decoration: line-through;
  color: var(--text-muted);
}

.celebration-msg {
  font-size: 0.8rem;
  color: var(--accent-cyan);
  font-weight: 500;
  animation: fadeIn 0.3s ease;
}

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

.task-meta {
  font-size: 0.75rem;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-muted);
}

.delete-btn {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.delete-btn:hover {
  background: rgba(255, 107, 157, 0.2);
  color: var(--accent-pink);
}

/* Confetti */
.confetti-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.confetti-particle {
  position: absolute;
  border-radius: 2px;
  animation: confettiFall 1s ease forwards;
}

@keyframes confettiFall {
  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100px) rotate(720deg);
    opacity: 0;
  }
}

/* Stats */
.stats-container {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.stats-container.ultra-vibe {
  border-color: var(--accent-cyan);
  animation: glow 2s ease infinite;
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 20px rgba(78, 205, 196, 0.3); }
  50% { box-shadow: 0 0 40px rgba(78, 205, 196, 0.6); }
}

.stats-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1rem;
}

.stat-card {
  text-align: center;
  padding: 1rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
}

.stat-value {
  font-size: 1.75rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--accent-pink), var(--accent-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-value.vibe-score {
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-blue));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.quote-container {
  padding-top: 1rem;
  border-top: 1px solid var(--glass-border);
}

.quote {
  font-style: italic;
  color: var(--text-secondary);
  font-size: 0.95rem;
  text-align: center;
  line-height: 1.5;
}

/* Footer */
.footer {
  text-align: center;
  padding: 1.5rem;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.footer-link {
  color: var(--accent-cyan);
  text-decoration: none;
  margin: 0.5rem 0;
  display: block;
  transition: color 0.3s ease;
}

.footer-link:hover {
  color: var(--accent-purple);
}

.footer-counter {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

/* Cursor Trail */
.cursor-trail {
  position: fixed;
  width: 8px;
  height: 8px;
  background: var(--accent-purple);
  border-radius: 50%;
  pointer-events: none;
  opacity: 0.6;
  animation: trailFade 0.5s ease forwards;
  z-index: 9999;
  transform: translate(-50%, -50%);
}

@keyframes trailFade {
  to {
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
  }
}

/* Ultra Vibe Mode */
.ultra-banner {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  padding: 0.75rem;
  background: linear-gradient(90deg, 
    #ff6b6b, #feca57, #48dbfb, #ff9ff3, #54a0ff, #5f27cd);
  background-size: 300% 100%;
  animation: rainbowSlide 3s linear infinite;
  text-align: center;
  font-weight: 700;
  z-index: 1000;
}

@keyframes rainbowSlide {
  0% { background-position: 0% 50%; }
  100% { background-position: 300% 50%; }
}

.ultra-mode .app-container {
  padding-top: 4rem;
}

body.ultra-vibe-mode {
  animation: hueRotate 5s linear infinite;
}

@keyframes hueRotate {
  from { filter: hue-rotate(0deg); }
  to { filter: hue-rotate(360deg); }
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .app-container {
    padding: 1rem 0.75rem;
    padding-bottom: 100px;
  }

  .header-title {
    font-size: 1.5rem;
  }

  .header-container {
    padding: 1.5rem 1rem;
    border-radius: 16px;
  }

  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
  }

  .stat-card {
    padding: 0.75rem 0.5rem;
  }

  .stat-value {
    font-size: 1.35rem;
  }

  .stat-label {
    font-size: 0.65rem;
  }

  .filter-container {
    justify-content: center;
  }

  .filter-tab {
    padding: 0.4rem 0.75rem;
    font-size: 0.8rem;
  }

  .task-input-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem;
    background: var(--gradient-2);
    border-top: 1px solid var(--glass-border);
    z-index: 100;
  }

  .task-form {
    flex-direction: row;
    gap: 0.5rem;
  }

  .input-wrapper {
    flex: 1;
  }

  .task-input {
    padding: 0.875rem;
    font-size: 1rem;
    border-radius: 12px;
  }

  .vibe-selector {
    display: none;
  }

  .add-btn {
    padding: 0.875rem 1rem;
    font-size: 1rem;
    border-radius: 12px;
    white-space: nowrap;
  }

  .cursor-trail {
    display: none;
  }
}

@media (min-width: 641px) {
  .app-container {
    padding: 3rem 2rem;
  }

  .header-title {
    font-size: 2.5rem;
  }
}