/* ── Reset & Base ─────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: #f5f5f5;
  color: #333;
  line-height: 1.6;
}

.hidden { display: none !important; }
.error { color: #e74c3c; font-size: 0.85rem; margin-top: 8px; }

/* ── Auth Screen ──────────────────────────────────── */
#auth-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e74c3c, #e67e22);
}

.auth-box {
  background: white;
  border-radius: 16px;
  padding: 40px 32px;
  text-align: center;
  width: 100%;
  max-width: 340px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.15);
}

.auth-emoji { font-size: 3rem; margin-bottom: 12px; }
.auth-box h1 { font-size: 1.5rem; margin-bottom: 6px; }
.auth-sub { color: #777; font-size: 0.9rem; margin-bottom: 20px; }

.auth-box input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #ddd;
  border-radius: 8px;
  font-size: 1rem;
  margin-bottom: 12px;
  outline: none;
  transition: border-color 0.2s;
}
.auth-box input:focus { border-color: #e74c3c; }

.auth-box button {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, #e74c3c, #e67e22);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}
.auth-box button:hover { opacity: 0.9; }

/* ── Header ───────────────────────────────────────── */
header {
  background: linear-gradient(135deg, #e74c3c, #e67e22);
  color: white;
  padding: 24px 16px 28px;
}
.header-content { max-width: 680px; margin: 0 auto; }
header h1 { font-size: 1.8rem; font-weight: 700; }
header p { font-size: 0.95rem; opacity: 0.88; margin-top: 4px; }

/* ── Main ─────────────────────────────────────────── */
main { max-width: 680px; margin: 0 auto; padding: 16px; }

/* ── Info Cards ───────────────────────────────────── */
.info-section { margin-bottom: 8px; }

.info-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-top: -20px;
}

.info-card {
  background: white;
  border-radius: 12px;
  padding: 14px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.info-card .card-icon { font-size: 1.4rem; margin-bottom: 6px; }
.info-card h3 { font-size: 0.8rem; font-weight: 700; color: #e74c3c; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px; }
.info-card p { font-size: 0.85rem; color: #555; line-height: 1.5; }

/* ── Day Sections ─────────────────────────────────── */
.day-card {
  background: white;
  border-radius: 12px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  overflow: hidden;
}

.day-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid #f0f0f0;
}
.day-label {
  background: linear-gradient(135deg, #e74c3c, #e67e22);
  color: white;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 4px 10px;
  border-radius: 20px;
}
.day-subtitle { font-size: 0.85rem; color: #999; }

.day-body { padding: 8px 16px 12px; }

.schedule-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 6px 0;
  border-bottom: 1px solid #f8f8f8;
  font-size: 0.9rem;
}
.schedule-item:last-child { border-bottom: none; }
.schedule-time {
  min-width: 48px;
  font-weight: 600;
  color: #e74c3c;
  font-size: 0.85rem;
  padding-top: 1px;
}
.schedule-content { flex: 1; color: #444; }
.btn-delete {
  background: none;
  border: none;
  color: #ccc;
  cursor: pointer;
  font-size: 0.8rem;
  padding: 2px 4px;
  border-radius: 4px;
  transition: color 0.15s;
}
.btn-delete:hover { color: #e74c3c; }

.memo-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 5px 0;
  font-size: 0.88rem;
  color: #666;
}
.memo-item::before { content: '📝'; font-size: 0.8rem; }
.memo-text { flex: 1; }

.add-schedule-row, .add-memo-row {
  display: flex;
  gap: 6px;
  margin-top: 10px;
}
.add-schedule-row input, .add-memo-row input {
  flex: 1;
  padding: 7px 10px;
  border: 1.5px solid #eee;
  border-radius: 7px;
  font-size: 0.85rem;
  outline: none;
  transition: border-color 0.2s;
}
.add-schedule-row input:focus, .add-memo-row input:focus { border-color: #e74c3c; }
.time-input { max-width: 70px !important; }

.add-schedule-row button, .add-memo-row button {
  padding: 7px 12px;
  background: #e74c3c;
  color: white;
  border: none;
  border-radius: 7px;
  font-size: 0.82rem;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.2s;
}
.add-schedule-row button:hover, .add-memo-row button:hover { opacity: 0.85; }

.section-divider {
  border: none;
  border-top: 1px dashed #eee;
  margin: 10px 0;
}

/* ── Checklist ────────────────────────────────────── */
.checklist-section {
  background: white;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  margin-bottom: 32px;
}
.checklist-section h2 { font-size: 1rem; font-weight: 700; margin-bottom: 12px; }

.checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid #f5f5f5;
  cursor: pointer;
}
.checklist-item:last-child { border-bottom: none; }

.check-box {
  width: 20px;
  height: 20px;
  border: 2px solid #ddd;
  border-radius: 5px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  font-size: 0.75rem;
}
.checklist-item.done .check-box {
  background: #e74c3c;
  border-color: #e74c3c;
  color: white;
}
.checklist-item.done .check-box::after { content: '✓'; }

.check-label {
  flex: 1;
  font-size: 0.9rem;
  color: #444;
  transition: color 0.15s;
}
.checklist-item.done .check-label {
  text-decoration: line-through;
  color: #bbb;
}

.add-row {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.add-row input {
  flex: 1;
  padding: 8px 12px;
  border: 1.5px solid #eee;
  border-radius: 8px;
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.2s;
}
.add-row input:focus { border-color: #e74c3c; }
.add-row button {
  padding: 8px 14px;
  background: #e74c3c;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: opacity 0.2s;
}
.add-row button:hover { opacity: 0.85; }

/* ── Mobile ───────────────────────────────────────── */
@media (max-width: 480px) {
  .info-cards { grid-template-columns: 1fr 1fr; gap: 8px; }
  header h1 { font-size: 1.4rem; }
  main { padding: 12px; }
  .auth-box { padding: 32px 20px; }
}
