/* ─── Auth Pages (login / change-password / toolbox) ─── */

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

body {
  font-family: -apple-system, 'PingFang SC', 'Microsoft YaHei', sans-serif;
  background: #0a0a1a;
  color: #e6e6e6;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  -webkit-user-select: none;
  user-select: none;
}

.auth-container {
  width: 400px;
  max-width: 94vw;
  padding: 40px 32px;
  background: #12122a;
  border: 1px solid #1e1e3f;
  border-radius: 16px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.4);
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

.auth-logo h1 {
  font-size: 28px;
  color: #e94560;
  letter-spacing: 2px;
}

.auth-logo .logo-icon {
  font-size: 48px;
  margin-bottom: 8px;
}

.auth-logo .subtitle {
  font-size: 13px;
  color: #667;
  margin-top: 6px;
}

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

.form-group label {
  display: block;
  font-size: 14px;
  color: #8892b0;
  margin-bottom: 6px;
}

.form-group input {
  width: 100%;
  padding: 12px 14px;
  background: #0a0a1a;
  border: 1px solid #1e1e3f;
  border-radius: 8px;
  color: #e6e6e6;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus {
  border-color: #e94560;
}

.form-group input::placeholder {
  color: #444;
}

.form-group .hint {
  font-size: 12px;
  color: #667;
  margin-top: 4px;
}

.error-msg {
  color: #e94560;
  font-size: 13px;
  margin-bottom: 12px;
  min-height: 20px;
  text-align: center;
}

.btn-primary {
  width: 100%;
  padding: 14px;
  background: #e94560;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: opacity 0.2s;
}

.btn-primary:hover { opacity: 0.9; }
.btn-primary:active { opacity: 0.75; }
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-footer {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: #667;
}

/* ─── 强制改密提示 ─── */
.force-hint {
  background: rgba(233, 69, 96, 0.1);
  border: 1px solid rgba(233, 69, 96, 0.3);
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 20px;
  font-size: 13px;
  color: #e94560;
  text-align: center;
  line-height: 1.6;
}

/* ─── 密码规则提示 ─── */
.pw-rules {
  font-size: 12px;
  color: #667;
  margin-bottom: 16px;
  line-height: 1.6;
}

.pw-rules .ok { color: #50c878; }
.pw-rules .fail { color: #e94560; }

/* ─── 工具箱 ─── */
.toolbox-container {
  width: 600px;
  max-width: 94vw;
  padding: 40px 32px;
}

.toolbox-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 1px solid #1e1e3f;
}

.toolbox-header .welcome {
  font-size: 14px;
  color: #8892b0;
}

.toolbox-header .welcome strong {
  color: #e6e6e6;
  font-size: 16px;
}

.role-tag {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 10px;
  margin-left: 8px;
}

.role-tag.role-admin {
  background: rgba(255, 215, 0, 0.15);
  color: #ffd700;
}

.role-tag.role-staff {
  background: rgba(102, 119, 136, 0.15);
  color: #667;
}

.store-info {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: rgba(233, 69, 96, 0.08);
  border: 1px solid rgba(233, 69, 96, 0.2);
  border-radius: 8px;
  margin-bottom: 24px;
  font-size: 14px;
  color: #e94560;
}

.store-info .store-badge {
  font-size: 18px;
}

.toolbox-header .btn-logout {
  padding: 6px 16px;
  background: transparent;
  border: 1px solid #1e1e3f;
  border-radius: 6px;
  color: #8892b0;
  font-size: 13px;
  cursor: pointer;
}

.toolbox-header .btn-logout:hover {
  border-color: #e94560;
  color: #e94560;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}

.tool-card {
  background: #12122a;
  border: 1px solid #1e1e3f;
  border-radius: 12px;
  padding: 24px 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
  color: inherit;
}

.tool-card:hover {
  border-color: #e94560;
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(233, 69, 96, 0.15);
}

.tool-card .tool-icon {
  font-size: 40px;
  margin-bottom: 12px;
}

.tool-card .tool-name {
  font-size: 16px;
  font-weight: bold;
  color: #e6e6e6;
  margin-bottom: 2px;
}

.tool-card .tool-store {
  font-size: 12px;
  color: #e94560;
  margin-bottom: 4px;
}

.tool-card .tool-desc {
  font-size: 12px;
  color: #667;
  line-height: 1.4;
}

.tool-card-placeholder {
  background: transparent;
  border: 1px dashed #1e1e3f;
  border-radius: 12px;
  padding: 24px 16px;
  text-align: center;
  color: #333;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
}

/* 开发者预览版提示 */
.preview-notice {
  position: fixed;
  bottom: 20px;
  left: 0; right: 0;
  text-align: center;
  font-size: 11px;
  color: #333;
}
