/* fasting-timer 轻断食计时器 */
.ft-seg {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
  margin-bottom: 16px;
}
.ft-seg .calc-seg-btn {
  padding: 10px 4px;
  font-size: 13px;
  border-radius: 10px;
}

/* 环形进度 */
.ft-ring-wrap {
  display: flex;
  justify-content: center;
  padding: 8px 0 4px;
}
.ft-ring {
  position: relative;
  width: 200px;
  height: 200px;
}
.ft-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}
.ft-ring .track {
  fill: none;
  stroke: var(--border, #e8ecf3);
  stroke-width: 10;
}
.ft-ring .prog {
  fill: none;
  stroke: var(--primary, #4f7cff);
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dashoffset .6s ease, stroke .3s;
}
.ft-ring.done .prog { stroke: #22a06b; }
.ft-ring-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0 18px;
}
.ft-ring-big {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text, #1a2234);
  line-height: 1.15;
}
.ft-ring-label { font-size: 12px; color: var(--text-light, #8a93a6); margin-top: 4px; }
.ft-ring-sub { font-size: 12px; color: var(--text-light, #8a93a6); margin-top: 2px; }

/* 当前阶段卡 */
.ft-zone {
  margin-top: 14px;
  border: 1px solid var(--border, #e8ecf3);
  border-radius: 14px;
  padding: 14px 16px;
  background: var(--bg-soft, #f7f9fd);
}
.ft-zone h4 {
  margin: 0 0 6px;
  font-size: 15px;
  color: var(--primary, #4f7cff);
  display: flex;
  align-items: center;
  gap: 6px;
}
.ft-zone p { margin: 0; font-size: 13px; line-height: 1.7; color: var(--text, #4a5468); }
.ft-zone .ft-next { margin-top: 8px; font-size: 12.5px; color: var(--text-light, #8a93a6); }

/* 计时指标 */
.ft-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 14px;
}
.ft-stat {
  border: 1px solid var(--border, #e8ecf3);
  border-radius: 12px;
  padding: 10px 12px;
}
.ft-stat .k { display: block; font-size: 12px; color: var(--text-light, #8a93a6); }
.ft-stat .v { display: block; font-size: 16px; font-weight: 700; margin-top: 3px; color: var(--text, #1a2234); }

/* 打卡统计 */
.ft-badges {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.ft-badge {
  text-align: center;
  border-radius: 12px;
  padding: 12px 6px;
  background: var(--bg-soft, #f7f9fd);
  border: 1px solid var(--border, #e8ecf3);
}
.ft-badge b { display: block; font-size: 22px; color: var(--primary, #4f7cff); }
.ft-badge small { font-size: 12px; color: var(--text-light, #8a93a6); }

/* 历史清单 */
.ft-history { list-style: none; margin: 0; padding: 0; }
.ft-history li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 2px;
  border-bottom: 1px dashed var(--border, #e8ecf3);
  font-size: 13.5px;
}
.ft-history li:last-child { border-bottom: none; }
.ft-history li .k { color: var(--text, #4a5468); }
.ft-history li .v { color: var(--text-light, #8a93a6); }
.ft-history li.ok .v { color: #22a06b; font-weight: 600; }
.ft-history li.miss .v { color: #d9822b; }
.ft-history li.empty .v { color: var(--text-light, #b6bdca); }

/* 阶段时间轴静态表内的阶段行 */
.ft-zone-row td:first-child { white-space: nowrap; font-weight: 600; }

.ft-toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%) translateY(16px);
  background: rgba(20, 28, 46, .92);
  color: #fff;
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 999;
  max-width: 88vw;
}
.ft-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
[data-theme="dark"] .ft-toast { background: rgba(238, 242, 252, .95); color: #1a2234; }

@media (max-width: 560px) {
  .ft-seg { grid-template-columns: repeat(3, 1fr); }
  .ft-ring { width: 176px; height: 176px; }
  .ft-ring-big { font-size: 26px; }
}
