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

body {
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  padding: 20px;
}

#app {
  max-width: 1400px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.header {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
  padding: 30px;
  text-align: center;
  color: white;
}

.header h1 {
  font-size: 2.5em;
  font-weight: 300;
  margin-bottom: 10px;
}

.header p {
  opacity: 0.9;
  font-size: 1.1em;
}

nav {
  background: white;
  padding: 20px 30px;
  border-bottom: 1px solid #e9ecef;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

nav button {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 25px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

nav button:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

nav button.active {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.view-container {
  padding: 30px;
  min-height: 600px;
}

.hidden {
  display: none !important;
}

/* Task Styles */
.task-controls {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
  flex-wrap: wrap;
  align-items: center;
}

.task-controls select,
.task-controls input {
  padding: 10px 15px;
  border: 2px solid #e9ecef;
  border-radius: 10px;
  font-size: 14px;
  transition: border-color 0.3s ease;
}

.task-controls select:focus,
.task-controls input:focus {
  outline: none;
  border-color: #4facfe;
}

.btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.3s ease;
  font-size: 14px;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.btn-success {
  background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
}

.btn-danger {
  background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
}

.btn-warning {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.btn-info {
  background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.btn-sm {
  padding: 8px 12px;
  font-size: 12px;
}

.task-item {
  background: white;
  margin: 15px 0;
  padding: 20px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  border-left: 5px solid;
  transition: all 0.3s ease;
}

.task-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.task-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 15px;
}

.task-title {
  font-size: 1.2em;
  font-weight: 600;
  color: #2c3e50;
}

.task-meta {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  margin-bottom: 15px;
  font-size: 0.9em;
  color: #6c757d;
}

.task-meta span {
  background: #f8f9fa;
  padding: 4px 8px;
  border-radius: 6px;
}

.task-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.subtasks {
  margin-left: 20px;
  margin-top: 15px;
  border-left: 2px solid #e9ecef;
  padding-left: 20px;
}

/* Priority colors */
.priority-1 {
  border-left-color: #dc3545;
  background: linear-gradient(135deg, #fff5f5 0%, #fed7d7 100%);
}
.priority-2 {
  border-left-color: #fd7e14;
  background: linear-gradient(135deg, #fffaf0 0%, #feebc8 100%);
}
.priority-3 {
  border-left-color: #ffc107;
  background: linear-gradient(135deg, #fffff0 0%, #fefcbf 100%);
}
.priority-4 {
  border-left-color: #28a745;
  background: linear-gradient(135deg, #f0fff4 0%, #c6f6d5 100%);
}
.priority-5 {
  border-left-color: #007bff;
  background: linear-gradient(135deg, #f0f8ff 0%, #bee3f8 100%);
}
.priority-6 {
  border-left-color: #6f42c1;
  background: linear-gradient(135deg, #faf5ff 0%, #e9d8fd 100%);
}

.completed {
  opacity: 0.6;
  background: linear-gradient(135deg, #f0fff4 0%, #c6f6d5 100%) !important;
}

.completed .task-title {
  text-decoration: line-through;
  color: #28a745;
}

/* Calendar Styles */
.calendar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  flex-wrap: wrap;
  gap: 15px;
}

.calendar-nav {
  display: flex;
  gap: 10px;
  align-items: center;
}

.calendar-grid {
  display: grid;
  gap: 20px;
}

.calendar-grid.day-view {
  grid-template-columns: 1fr;
}

.calendar-grid.week-view {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.calendar-grid.month-view {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.calendar-day {
  background: white;
  border-radius: 15px;
  padding: 20px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  min-height: 200px;
}

.calendar-day h3 {
  color: #2c3e50;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e9ecef;
}

.schedule-item {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 10px 12px;
  margin: 8px 0;
  border-radius: 8px;
  font-size: 0.9em;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.schedule-priority-1 {
  background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
}
.schedule-priority-2 {
  background: linear-gradient(135deg, #fd7e14 0%, #e56f0d 100%);
}
.schedule-priority-3 {
  background: linear-gradient(135deg, #ffc107 0%, #e0a800 100%);
}
.schedule-priority-4 {
  background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
}
.schedule-priority-5 {
  background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
}
.schedule-priority-6 {
  background: linear-gradient(135deg, #6f42c1 0%, #59359a 100%);
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  z-index: 999;
  display: flex;
  justify-content: center;
  align-items: center;
}

.modal {
  background: white;
  border-radius: 20px;
  padding: 30px;
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.modal h2 {
  color: #2c3e50;
  margin-bottom: 20px;
  text-align: center;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  color: #495057;
  font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 15px;
  border: 2px solid #e9ecef;
  border-radius: 10px;
  font-size: 14px;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #4facfe;
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

.form-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 30px;
}

/* Stats Styles */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: white;
  padding: 25px;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  text-align: center;
  border-left: 5px solid #4facfe;
}

.stat-card h3 {
  color: #2c3e50;
  margin-bottom: 10px;
  font-size: 1.1em;
}

.stat-card .stat-value {
  font-size: 2.5em;
  font-weight: 300;
  color: #4facfe;
  margin-bottom: 5px;
}

.stat-card .stat-label {
  color: #6c757d;
  font-size: 0.9em;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: #e9ecef;
  border-radius: 4px;
  overflow: hidden;
  margin: 10px 0;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #4facfe 0%, #00f2fe 100%);
  transition: width 0.3s ease;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header h1 {
    font-size: 2em;
  }

  nav {
    padding: 15px 20px;
  }

  .view-container {
    padding: 20px;
  }

  .task-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .task-header {
    flex-direction: column;
    gap: 10px;
  }

  .calendar-header {
    flex-direction: column;
    align-items: stretch;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.task-item,
.calendar-day,
.stat-card {
  animation: fadeIn 0.3s ease;
}

/* Notification styles */
.notification {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 15px 20px;
  border-radius: 10px;
  color: white;
  font-weight: 500;
  z-index: 1000;
  transform: translateX(100%);
  transition: transform 0.3s ease;
}

.notification.show {
  transform: translateX(0);
}

.notification.success {
  background: linear-gradient(135deg, #56ab2f 0%, #a8e6cf 100%);
}

.notification.error {
  background: linear-gradient(135deg, #ff416c 0%, #ff4b2b 100%);
}

.notification.warning {
  background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}
