/* Recommendation View Styles */

.recommendation-container {
  display: flex;
  flex-direction: row; /* Reversed to put task list on left */
  height: 100%;
  width: 100%;
  padding: 40px;
  flex: 1;
  position: relative;
}

.recommendation-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.note-card {
  max-width: 600px;
  background-color: white;
  box-shadow: 0 4px 12px var(--shadow-color);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 20px;
  transition: transform 0.3s ease;
  width: 100%;
}

.recommendation-actions {
  display: flex;
  gap: 20px;
  margin-top: 20px;
}

/* Task list container styles */
.task-list-container {
  width: 300px;
  background-color: white;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 4px 12px var(--shadow-color);
  display: flex;
  flex-direction: column;
  height: calc(100% - 40px);
  transition: background-color 0.3s ease;
  margin-right: auto; /* Push to the left edge */
}

.task-list-container.warning {
  background-color: #fff8e1; /* Light orange/amber background */
  border: 1px solid #ffca28;
}

.task-list-container.danger {
  background-color: #ffebee; /* Light red background */
  border: 1px solid #ff5252;
}

.task-list-container h3 {
  margin-top: 0;
  color: var(--accent-color);
  font-weight: 500;
  margin-bottom: 15px;
}

.task-list {
  flex-grow: 1;
  overflow-y: auto;
  margin-bottom: 15px;
}

.empty-task-list {
  color: #999;
  font-style: italic;
  text-align: center;
  padding: 20px 0;
}

/* Task item styling */
.task-item {
  background-color: #f9f9f9;
  border-radius: 4px;
  padding: 10px 12px;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.task-content {
  flex-grow: 1;
  overflow: hidden;
  padding-right: 8px;
  white-space: normal; /* Allow text wrapping */
  line-height: 1.4;
}

.task-content .tag {
  color: var(--accent-color);
  font-weight: 500;
}

.task-progress {
  margin-right: 8px;
  flex-shrink: 0;
}

.task-actions {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.task-remove-btn {
  background-color: transparent;
  border: none;
  color: #999;
  font-size: 18px;
  padding: 0 5px;
  cursor: pointer;
  transition: color 0.2s;
}

.task-remove-btn:hover {
  color: var(--error-color);
}

.start-pomodoro-btn {
  margin-top: auto;
  width: 100%;
}

/* Full list warning */
.list-full-warning {
  background-color: #fff8e1;
  border: 1px solid #ffca28;
  color: #ff8f00;
  padding: 8px;
  margin-bottom: 10px;
  border-radius: 4px;
  font-size: 12px;
  text-align: center;
  display: none;
}

.list-full-warning.show {
  display: block;
}

/* Card transition animations */
.note-card.enter {
  animation: card-enter 0.3s ease forwards;
}

.note-card.exit-left {
  animation: card-exit-left 0.3s ease forwards;
}

.note-card.exit-right {
  animation: card-exit-right 0.3s ease forwards;
}

@keyframes card-enter {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes card-exit-left {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(-100px);
  }
}

@keyframes card-exit-right {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100px);
  }
}

/* Empty state styling */
.empty-recommendation {
  text-align: center;
  padding: 40px;
  color: #777;
  font-style: italic;
  background-color: rgba(255, 255, 255, 0.7);
  border-radius: 8px;
}

/* Card content styling */
.note-card p {
  margin: 0 0 10px 0;
  line-height: 1.6;
}

.note-card .tag {
  display: inline-block;
  margin-right: 5px;
}

/* Metadata display */
.note-metadata {
  display: flex;
  justify-content: space-between;
  margin-top: 15px;
  font-size: 12px;
  color: #777;
  border-top: 1px solid #eee;
  padding-top: 10px;
}

.note-metadata .date {
  font-style: italic;
}

/* Keyboard shortcut hints */
.shortcut-hint {
  position: absolute;
  bottom: 20px;
  font-size: 12px;
  color: #777;
  text-align: center;
  width: 100%;
}

#recommendation-view {
  width: 100%;
  max-width: 100%;
  margin: 0;
  flex-direction: row;
  padding: 0;
  align-items: center;
  justify-content: flex-end;
}

/* Action button hover effects */
.recommendation-actions .btn-primary:hover {
  background-color: var(--accent-color);
  opacity: 0.9;
}

.recommendation-actions .btn-secondary:hover {
  background-color: #ddd;
}

/* Responsive layout */
@media (max-width: 768px) {
  #recommendation-view {
    flex-direction: column-reverse;
  }

  .recommendation-container {
    /* margin-top: 60px; */
    width: calc(100% - 40px);
  }

  .task-list-container {
    width: calc(100% - 40px);
    margin-top: 80px;
    height: 40%;
  }
}

/* Reshuffle container */
.reshuffle-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(255, 255, 255, 0.9);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s;
}

.reshuffle-container.show {
  opacity: 1;
  pointer-events: auto;
}

/* No more tasks display */
.no-more-tasks {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  animation: noMoreTasksfadeIn 0.7s ease-out;
  width: 100%;
}

@keyframes noMoreTasksfadeIn {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.no-more-tasks-icon {
  font-size: 50px;
  width: 80px;
  height: 80px;
  background-color: var(--accent-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
  box-shadow: 0 5px 15px rgba(98, 0, 238, 0.3);
  animation: icon-pop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.no-more-tasks-text {
  font-size: 22px;
  font-weight: 500;
  color: var(--accent-color);
  animation: text-slide 0.5s ease forwards 0.2s;
  opacity: 0;
  transform: translateY(10px);
}

@keyframes icon-pop {
  0% {
    transform: scale(0.5);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes text-slide {
  0% {
    opacity: 0;
    transform: translateY(10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}
