/* 朴小护 H5 移动端演示页面样式 */

/* ============================================
   基础样式重置
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: #333;
  background-color: #f5f5f5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  outline: none;
}

/* ============================================
   通用组件样式
   ============================================ */

/* 容器 */
.container {
  max-width: 750px;
  margin: 0 auto;
  background-color: #fff;
  min-height: 100vh;
}

/* 按钮 */
.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  width: 100%;
}

.btn-primary {
  background: linear-gradient(135deg, #1890FF 0%, #096DD9 100%);
  color: #fff;
  box-shadow: 0 2px 8px rgba(24, 144, 255, 0.3);
}

.btn-primary:active {
  transform: scale(0.98);
  background: linear-gradient(135deg, #096DD9 0%, #0050B3 100%);
}

.btn-secondary {
  background: #fff;
  color: #1890FF;
  border: 1px solid #1890FF;
}

.btn-danger {
  background: #FF4D4F;
  color: #fff;
}

.btn:disabled {
  background: #D9D9D9;
  color: #BFBFBF;
  cursor: not-allowed;
}

/* 卡片 */
.card {
  background: #fff;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* 标签 */
.tag {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 12px;
  font-size: 12px;
  margin-right: 8px;
  margin-bottom: 8px;
  background: #F5F5F5;
  color: #333;
}

.tag-blue {
  background: #E6F7FF;
  color: #1890FF;
}

.tag-green {
  background: #F6FFED;
  color: #52C41A;
}

.tag-orange {
  background: #FFF7E6;
  color: #FA8C16;
}

/* 输入框 */
.input-group {
  margin-bottom: 16px;
}

.input-label {
  display: block;
  font-size: 14px;
  color: #333;
  margin-bottom: 8px;
  font-weight: 500;
}

.input-label .required {
  color: #FF4D4F;
  margin-right: 4px;
}

.input {
  width: 100%;
  padding: 12px;
  border: 1px solid #D9D9D9;
  border-radius: 4px;
  font-size: 14px;
  transition: border-color 0.3s ease;
}

.input:focus {
  border-color: #1890FF;
}

.input::placeholder {
  color: #BFBFBF;
}

textarea.input {
  min-height: 100px;
  resize: vertical;
}

/* 空状态 */
.empty-state {
  text-align: center;
  padding: 60px 20px;
}

.empty-state-icon {
  font-size: 64px;
  color: #D9D9D9;
  margin-bottom: 16px;
}

.empty-state-title {
  font-size: 16px;
  color: #333;
  margin-bottom: 8px;
}

.empty-state-desc {
  font-size: 14px;
  color: #8C8C8C;
}

/* 加载动画 */
.loading {
  text-align: center;
  padding: 20px;
}

.loading-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid #F5F5F5;
  border-top-color: #1890FF;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ============================================
   导航栏样式
   ============================================ */
.nav-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 44px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid #F0F0F0;
}

.nav-bar-title {
  font-size: 18px;
  font-weight: 600;
  color: #333;
}

.nav-bar-back {
  position: absolute;
  left: 16px;
  display: flex;
  align-items: center;
  color: #333;
  cursor: pointer;
}

.nav-bar-back::before {
  content: '←';
  font-size: 20px;
  margin-right: 4px;
}

/* ============================================
   底部标签栏
   ============================================ */
.tab-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: #fff;
  border-top: 1px solid #F0F0F0;
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 100;
}

.tab-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: #8C8C8C;
  font-size: 10px;
  cursor: pointer;
  transition: color 0.3s ease;
}

.tab-item.active {
  color: #1890FF;
}

.tab-item-icon {
  font-size: 24px;
  margin-bottom: 4px;
}

/* ============================================
   工具类
   ============================================ */
.text-center {
  text-align: center;
}

.text-primary {
  color: #1890FF;
}

.text-orange {
  color: #FA8C16;
}

.text-success {
  color: #52C41A;
}

.text-gray {
  color: #8C8C8C;
}

.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.p-16 { padding: 16px; }

.flex {
  display: flex;
}

.flex-between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.flex-center {
  display: flex;
  justify-content: center;
  align-items: center;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.hidden {
  display: none !important;
}
