/* WhatsApp Reminder Bot — dashboard styles */

:root {
  --bg: #0a1628;
  --bg-2: #0f1e36;
  --bg-3: #16294a;
  --border: #1f3460;
  --text: #e5edf7;
  --text-muted: #8aa0c2;
  --text-dim: #5d7398;
  --teal: #14b8a6;
  --teal-dim: #0d8a7c;
  --amber: #f59e0b;
  --red: #ef4444;
  --green: #22c55e;
  --radius: 10px;
}

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

body {
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

.container { max-width: 1100px; margin: 0 auto; padding: 24px; }

/* Header */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 20px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-icon {
  width: 44px; height: 44px; border-radius: var(--radius);
  background: linear-gradient(135deg, var(--teal), var(--teal-dim));
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.brand-text h1 { font-size: 19px; font-weight: 600; }
.brand-text p { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

/* Buttons */
.btn {
  font: inherit; cursor: pointer;
  padding: 9px 16px; border-radius: 8px;
  background: var(--bg-3); color: var(--text);
  border: 1px solid var(--border);
  font-size: 13px; font-weight: 500;
  display: inline-flex; align-items: center; gap: 6px;
  transition: all .15s;
}
.btn:hover { background: var(--border); border-color: var(--teal); }
.btn-primary {
  background: var(--teal); color: #04241f; border-color: var(--teal);
}
.btn-primary:hover { background: var(--teal-dim); border-color: var(--teal-dim); color: #fff; }
.btn-icon { padding: 6px 9px; font-size: 12px; }
.btn-danger:hover { color: var(--red); border-color: var(--red); }

/* Stat cards */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 28px; }
.stat-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.stat-label { font-size: 12px; color: var(--text-muted); margin-bottom: 6px; }
.stat-value { font-size: 24px; font-weight: 600; }
.stat-value.danger { color: var(--red); }

/* Tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 18px; }
.tab {
  background: none; border: none; cursor: pointer;
  color: var(--text-muted); padding: 10px 16px;
  font-size: 13px; font-weight: 500;
  border-bottom: 2px solid transparent;
  font-family: inherit;
}
.tab.active { color: var(--text); border-bottom-color: var(--teal); }

/* Reminder cards */
.day-header {
  font-size: 11px; text-transform: uppercase; letter-spacing: 1px;
  color: var(--text-dim); margin: 18px 0 10px; font-weight: 600;
}
.reminder {
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 16px;
  margin-bottom: 10px; display: flex; gap: 12px;
}
.avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--bg-3); color: var(--teal);
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 13px; flex-shrink: 0;
}
.reminder-body { flex: 1; min-width: 0; }
.reminder-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 4px;
}
.reminder-name { font-weight: 600; font-size: 14px; }
.reminder-time { font-size: 12px; color: var(--text-muted); }
.reminder-msg { font-size: 13px; color: var(--text-muted); margin-bottom: 8px; line-height: 1.5; }
.reminder-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.tag {
  font-size: 11px; padding: 2px 9px; border-radius: 999px;
  background: var(--bg-3); color: var(--text-muted);
}
.tag.warn { background: rgba(245, 158, 11, .15); color: var(--amber); }
.tag.success { background: rgba(34, 197, 94, .15); color: var(--green); }
.tag.danger { background: rgba(239, 68, 68, .15); color: var(--red); }
.tag.info { background: rgba(20, 184, 166, .15); color: var(--teal); }
.reminder-actions { display: flex; gap: 4px; flex-shrink: 0; align-self: flex-start; }

/* Form */
.form-card {
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 20px; margin-top: 28px;
}
.form-card h3 { font-size: 16px; margin-bottom: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; margin-bottom: 12px; }
.field { margin-bottom: 12px; }
.field label { display: block; font-size: 12px; color: var(--text-muted); margin-bottom: 5px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 9px 12px;
  background: var(--bg); color: var(--text);
  border: 1px solid var(--border); border-radius: 7px;
  font-family: inherit; font-size: 13px;
  transition: border-color .15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--teal);
}
.field textarea { resize: vertical; min-height: 70px; }
.form-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 6px; }

/* Modal */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,.6);
  display: none; align-items: center; justify-content: center;
  z-index: 100;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  width: 90%; max-width: 500px;
}
.modal h3 { margin-bottom: 16px; }

/* Toast */
.toast {
  position: fixed; bottom: 24px; right: 24px;
  background: var(--bg-3); border: 1px solid var(--teal);
  padding: 12px 18px; border-radius: 8px; font-size: 13px;
  transform: translateY(100px); opacity: 0;
  transition: all .25s;
}
.toast.show { transform: translateY(0); opacity: 1; }
.toast.error { border-color: var(--red); }

/* Empty state */
.empty {
  text-align: center; padding: 40px 20px;
  color: var(--text-dim); font-size: 14px;
}

/* Responsive */
@media (max-width: 700px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .reminder { flex-direction: column; }
  .reminder-actions { align-self: flex-end; }
}
