* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
  background: radial-gradient(circle at top, #141923, #0e1117 65%);
  color: #e6e6e6;
  display: flex;
  justify-content: center;
  padding: 50px 20px;
}

.app {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
}

/* HEADER */

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 25px;
}

header h1 {
  font-size: 1.8rem;
  font-weight: 600;
}

.stats {
  display: flex;
  gap: 18px;
  font-size: 0.9rem;
  color: #9aa0a6;
}

/* XP BAR */

.xp-bar {
  height: 10px;
  background: #1a1f2b;
  border-radius: 20px;
  overflow: hidden;
  margin-bottom: 35px;
}

.xp-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #5b8cff, #7aa2ff);
  transition: width 0.4s ease;
}

/* CONTRIBUTION SECTION */

.contribution-section {
  margin-bottom: 35px;
}

.contribution-section h2 {
  font-size: 1rem;
  margin-bottom: 20px;
  color: #aab2c0;
  font-weight: 500;
}

/* COMPARTMENTS */

.compartment {
  margin-bottom: 30px;
  padding: 18px 20px;
  background: rgba(26, 31, 43, 0.6);
  border-radius: 12px;
  border: 1px solid #1f2532;
}

.compartment h3 {
  font-size: 0.9rem;
  margin-bottom: 14px;
  color: #aab2c0;
  font-weight: 500;
}

.heatmap {
  display: grid;
  grid-template-columns: repeat(52, 11.7px);
  grid-template-rows: repeat(7, 11.7px);
  gap: 5px;
}

.heatmap div {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  background: #262c38;
  transition:
    transform 0.15s ease,
    box-shadow 0.2s ease;
}

.heatmap div:hover {
  transform: scale(1.15);
  box-shadow: 0 0 8px rgba(91, 140, 255, 0.6);
}

/* ADD TASK SECTION */

.add-task {
  display: flex;
  gap: 12px;
  margin: 30px 0;
}

.add-task input,
.add-task select {
  background: #1a1f2b;
  border: 1px solid #252c3b;
  color: #e6e6e6;
  padding: 10px;
  border-radius: 6px;
  font-size: 0.9rem;
}

.add-task input[type="text"] {
  flex: 1;
}

.add-task input:focus,
.add-task select:focus {
  outline: none;
  border-color: #5b8cff;
}

.add-task button {
  background: #5b8cff;
  border: none;
  padding: 10px 18px;
  border-radius: 6px;
  color: white;
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.1s ease;
}

.add-task button:hover {
  background: #6f9dff;
  transform: translateY(-1px);
}

/* TASK SECTIONS */

.task-section {
  margin-bottom: 28px;
}

.task-section h2 {
  font-size: 0.95rem;
  margin-bottom: 12px;
  color: #aab2c0;
}

/* TASK CARD */

.task {
  background: #1a1f2b;
  padding: 12px 14px;
  border-radius: 8px;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition:
    background 0.2s ease,
    transform 0.1s ease;
}

.task:hover {
  background: #202636;
  transform: translateY(-2px);
}

.task.work {
  border-left: 3px solid #5b8cff;
}
.task.health {
  border-left: 3px solid #3ddc97;
}
.task.life {
  border-left: 3px solid #8c7ae6;
}

.completed {
  opacity: 0.55;
  text-decoration: line-through;
}

/* RESPONSIVE */

@media (max-width: 700px) {
  .add-task {
    flex-direction: column;
  }

  .add-task button {
    width: 100%;
  }

  .heatmap {
    grid-template-columns: repeat(52, 9px);
    grid-template-rows: repeat(7, 9px);
    gap: 2px;
  }

  .heatmap div {
    width: 9px;
    height: 9px;
  }
}
