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

:root {
  --bg: #faf8f5;
  --text: #2c2c2c;
  --text-muted: #888;
  --border: #e8e4df;
  --card-bg: #fff;
  --radius: 12px;

  /* Season colors */
  --season-1: #7eb8a8;
  --season-2: #e8a87c;
  --season-3: #f7c948;
  --season-4: #c17c5a;
  --season-5: #8b6f9e;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100dvh;
}

#app {
  max-width: 480px;
  margin: 0 auto;
  padding: 16px;
}

/* Login */
.login-card {
  text-align: center;
  padding: 60px 24px;
}

.login-card h1 {
  font-size: 28px;
  margin-bottom: 4px;
}

.login-card .subtitle {
  color: var(--text-muted);
  margin-bottom: 32px;
  font-size: 15px;
}

#login-form {
  display: flex;
  gap: 8px;
}

#login-form input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 16px;
  background: var(--card-bg);
}

#login-form button {
  padding: 12px 24px;
  border: none;
  border-radius: var(--radius);
  background: var(--text);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
}

.error {
  color: #d44;
  font-size: 14px;
  margin-top: 12px;
}

/* Header */
header {
  text-align: center;
  padding: 8px 0 20px;
}

header h1 {
  font-size: 22px;
}

/* Season card */
#active-seasons {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.season-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.season-year-label {
  font-weight: 400;
  font-size: 16px;
  color: var(--text-muted);
}

.season-header {
  margin-bottom: 4px;
}

.season-header h2 {
  font-size: 20px;
  margin-bottom: 2px;
}

.season-dates {
  font-size: 13px;
  color: var(--text-muted);
}

.countdown {
  font-size: 14px;
  color: var(--text-muted);
  margin: 8px 0 16px;
  padding: 8px 12px;
  background: var(--bg);
  border-radius: 8px;
  text-align: center;
}

/* Season accent stripe */
.season-card[data-season="1"] { border-top: 4px solid var(--season-1); }
.season-card[data-season="2"] { border-top: 4px solid var(--season-2); }
.season-card[data-season="3"] { border-top: 4px solid var(--season-3); }
.season-card[data-season="4"] { border-top: 4px solid var(--season-4); }
.season-card[data-season="5"] { border-top: 4px solid var(--season-5); }

/* Add task form */
.add-task {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
}

.add-task input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 15px;
  background: var(--bg);
}

.add-task button {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 8px;
  background: var(--text);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Task list */
.task-list {
  list-style: none;
}

.task-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.task-list li:last-child {
  border-bottom: none;
}

.task-list li input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--text);
  cursor: pointer;
  flex-shrink: 0;
}

.task-list li .task-text {
  flex: 1;
  font-size: 15px;
  line-height: 1.4;
}

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

.task-list li .delete-btn {
  border: none;
  background: none;
  color: var(--text-muted);
  font-size: 18px;
  cursor: pointer;
  padding: 4px;
  line-height: 1;
  opacity: 0.5;
}

.task-list li .delete-btn:hover {
  opacity: 1;
  color: #d44;
}

.empty-state {
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  padding: 20px 0;
}

/* History */
#history {
  margin-top: 32px;
  padding-bottom: 40px;
}

.history-title {
  font-size: 16px;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.history-card {
  background: var(--card-bg);
  border-radius: var(--radius);
  margin-bottom: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
  overflow: hidden;
}

.history-card[data-season="1"] { border-left: 4px solid var(--season-1); }
.history-card[data-season="2"] { border-left: 4px solid var(--season-2); }
.history-card[data-season="3"] { border-left: 4px solid var(--season-3); }
.history-card[data-season="4"] { border-left: 4px solid var(--season-4); }
.history-card[data-season="5"] { border-left: 4px solid var(--season-5); }

.history-toggle {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border: none;
  background: none;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  color: var(--text);
  text-align: left;
}

.history-toggle .toggle-meta {
  font-weight: 400;
  font-size: 13px;
  color: var(--text-muted);
}

.history-content {
  display: none;
  padding: 0 16px 14px;
}

.history-content.open {
  display: block;
}

.history-content .task-list li {
  padding: 6px 0;
}

.history-empty {
  color: var(--text-muted);
  font-size: 13px;
  font-style: italic;
}
