/* 儿童成长系统 - 公共基础样式 */
* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --font: 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 18px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --transition: 0.2s ease;
}

body {
  font-family: var(--font);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

button {
  cursor: pointer;
  border: none;
  font-family: var(--font);
  transition: var(--transition);
}

button:hover { opacity: 0.85; }
button:active { transform: scale(0.97); }

input, textarea, select {
  font-family: var(--font);
  border: 1px solid #e0e0e0;
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  font-size: 14px;
  outline: none;
  transition: var(--transition);
}

input:focus, textarea:focus, select:focus {
  border-color: #5B8DEF;
  box-shadow: 0 0 0 3px rgba(91,141,239,0.1);
}

a { text-decoration: none; color: inherit; }

.tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 20px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
}

.btn-primary { background: #5B8DEF; color: #fff; }
.btn-success { background: #4CAF50; color: #fff; }
.btn-warning { background: #FF9800; color: #fff; }
.btn-danger { background: #EF5350; color: #fff; }
.btn-outline { background: #fff; color: #5B8DEF; border: 1.5px solid #5B8DEF; }
.btn-sm { padding: 5px 14px; font-size: 13px; }
.btn-lg { padding: 12px 28px; font-size: 16px; }

.modal-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.4);
  display: flex; align-items: center; justify-content: center;
  z-index: 1000;
  animation: fadeIn 0.2s ease;
}

.modal {
  background: #fff;
  border-radius: var(--radius-xl);
  padding: 28px;
  min-width: 400px;
  max-width: 90vw;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}

.modal h3 { font-size: 18px; margin-bottom: 16px; color: #1a1a2e; }

.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 13px; font-weight: 500; color: #555; margin-bottom: 5px; }
.form-group input, .form-group textarea, .form-group select { width: 100%; }

.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

.empty-state {
  text-align: center;
  color: #999;
  padding: 40px 20px;
}

.empty-state-icon { font-size: 48px; margin-bottom: 12px; opacity: 0.5; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* 通知提示 */
.toast {
  position: fixed; top: 20px; right: 20px;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  z-index: 2000;
  animation: slideUp 0.3s ease;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}
.toast-success { background: #4CAF50; }
.toast-error { background: #EF5350; }
.toast-warning { background: #FF9800; }
