/* =============================================
   enhancements.css - 功能增强包样式
   v20260608 — 药签、翻页、成就增强
   ============================================= */

/* ===== 今日药签 ===== */
.prescription-card {
  cursor: pointer;
  transition: all 0.3s ease;
  border: 1px solid #D4C5A9;
}
.prescription-card:active {
  transform: scale(0.98);
  border-color: #C9A96E;
}
.prescription-main {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
}
.prescription-emoji {
  font-size: 36px;
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #F5F0E8;
  border-radius: 50%;
  border: 1px solid #D4C5A9;
  flex-shrink: 0;
}
.prescription-content {
  flex: 1;
}
.prescription-name {
  font-size: 16px;
  font-weight: bold;
  color: #3E2723;
  margin-bottom: 4px;
}
.prescription-herbs {
  font-size: 13px;
  color: #8D6E63;
}
.prescription-brief {
  font-size: 13px;
  color: #8B8B8B;
  line-height: 1.6;
  padding: 4px 0;
}
.prescription-more {
  color: #C9A96E;
  font-size: 12px;
}
.prescription-full {
  padding: 4px 0;
}
.prescription-desc {
  font-size: 13px;
  color: #5D4037;
  line-height: 1.8;
  margin: 8px 0;
}
.prescription-advice {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 8px 12px;
  background: #FFFDF5;
  border-left: 3px solid #C9A96E;
  border-radius: 4px;
  font-size: 13px;
  color: #6D4C41;
  line-height: 1.6;
  margin: 8px 0;
}
.advice-icon {
  flex-shrink: 0;
  font-size: 16px;
}
.prescription-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid #EDE8DD;
  font-size: 12px;
}
.prescription-date {
  color: #B8B2A8;
}
.prescription-link {
  color: #8D6E63;
  font-weight: bold;
  text-decoration: underline;
}

/* ===== 图谱翻页 ===== */
.collection-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 8px 0;
  margin-bottom: 8px;
}
.page-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #D4C5A9;
  background: #F5F0E8;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #5D4037;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}
.page-btn:active:not(:disabled) {
  background: #D4C5A9;
  transform: scale(0.95);
}
.page-btn:disabled {
  opacity: 0.3;
  cursor: default;
}
.page-info {
  font-size: 14px;
  color: #8D6E63;
  min-width: 40px;
  text-align: center;
  font-family: serif;
}
.collection-page-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 4px 0;
}
.collection-swipe-hint {
  text-align: center;
  font-size: 11px;
  color: #B8B2A8;
  padding: 6px 0;
  letter-spacing: 1px;
}

/* 翻页卡片样式 */
.herb-card {
  background: #FFFDF5;
  border-radius: 10px;
  padding: 10px 6px;
  text-align: center;
  border: 1px solid #EDE8DD;
  cursor: pointer;
  transition: all 0.2s ease;
}
.herb-card:active {
  transform: scale(0.95);
  border-color: #C9A96E;
}
.herb-card.locked {
  opacity: 0.6;
  background: #F5F0E8;
}
.herb-card-emoji {
  font-size: 28px;
  margin-bottom: 4px;
}
.herb-card-image {
  width: 56px; height: 56px; object-fit: cover; border-radius: 8px; margin-bottom: 4px;
}
.herb-card-name {
  font-size: 12px;
  color: #3E2723;
  font-weight: bold;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.herb-card-name.locked-name {
  color: #B8B2A8;
  font-weight: normal;
}
.herb-card-nature {
  font-size: 10px;
  color: #8D6E63;
  margin-top: 2px;
}
.herb-card-latin {
  font-size: 9px;
  color: #B8B2A8;
  margin-top: 1px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 增强药签首页布局 - 在底部导航栏前插入 */
#daily-prescription-card {
  margin: 12px 16px;
}

/* ===== 纪念签到奖励弹窗 ===== */
.checkin-celebration {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  background: rgba(0,0,0,0.3);
  animation: fadeIn 0.3s ease;
}
.checkin-celebration-card {
  background: #FFFDF5;
  border-radius: 16px;
  padding: 24px;
  margin: 20px;
  text-align: center;
  border: 2px solid #D4A017;
  animation: popIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  max-width: 300px;
}
.checkin-celebration-title {
  font-size: 22px;
  color: #D4A017;
  font-weight: bold;
  margin: 12px 0;
}
.checkin-celebration-reward {
  font-size: 36px;
  margin: 8px 0;
}
.checkin-celebration-sub {
  font-size: 13px;
  color: #8B8B8B;
  margin: 8px 0;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes popIn {
  from { opacity: 0; transform: scale(0.6); }
  to { opacity: 1; transform: scale(1); }
}

/* ===== 成就进度条 ===== */
.enhanced-achieve-progress {
  margin-top: 8px;
  padding: 0 4px;
}
.achieve-progress-bar {
  height: 6px;
  background: #EDE8DD;
  border-radius: 3px;
  overflow: hidden;
  margin-top: 2px;
}
.achieve-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #C9A96E, #D4A017);
  border-radius: 3px;
  transition: width 0.5s ease;
}
.achieve-progress-text {
  font-size: 11px;
  color: #B8B2A8;
  margin-top: 2px;
}

/* ===== 手机适配 ===== */
@media (max-width: 360px) {
  .collection-page-row {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }
  .prescription-emoji {
    width: 44px;
    height: 44px;
    font-size: 28px;
  }
}
