/* 填写页：底部表单、喂养/疫苗/体检表单、“我的”页账号、体型概览。
   样式按原 styles.css 的顺序拆成 base → home → components → forms → features，index.html 按这个顺序加载；后面的覆盖前面的，调整时不要打乱顺序。 */

.feed-sheet {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  align-items: end;
  width: min(100%, 480px);
  margin: 0 auto;
  background: rgba(218, 236, 245, 0.78);
  backdrop-filter: blur(10px);
}

.feed-form {
  min-height: 92vh;
  padding: 22px 18px calc(24px + env(safe-area-inset-bottom));
  color: var(--text);
}

.sheet-head {
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  align-items: center;
  margin-bottom: 34px;
}

.sheet-head h2 {
  color: var(--text);
  font-size: calc(19px * var(--fs, 1));
  text-align: center;
}

.sheet-card {
  display: grid;
  min-height: 58vh;
  padding: 28px 18px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.94);
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(88, 147, 178, 0.16);
}

.feed-hero {
  display: grid;
  place-items: center;
  width: 116px;
  height: 116px;
  margin: 0 auto 22px;
  border-radius: 32px;
  background: var(--surface-soft);
  font-size: calc(68px * var(--fs, 1));
}

.feed-form label {
  position: relative;
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  align-items: center;
  min-height: 58px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: calc(18px * var(--fs, 1));
  font-weight: 500;
}

.feed-form input,
.feed-form select {
  width: 100%;
  min-width: 0;
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  background: #f6f9fb;
  color: var(--text);
  padding: 0 12px;
  text-align: right;
}

.feed-form .select-row input,
.feed-form .select-row select {
  padding-right: 34px;
}

.select-row::after {
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 13px;
  height: 18px;
  transform: translateY(-50%);
  background:
    linear-gradient(135deg, transparent 50%, #9aa8b5 50%) 1px 2px / 6px 6px no-repeat,
    linear-gradient(225deg, transparent 50%, #9aa8b5 50%) 6px 2px / 6px 6px no-repeat,
    linear-gradient(45deg, transparent 50%, #9aa8b5 50%) 1px 11px / 6px 6px no-repeat,
    linear-gradient(315deg, transparent 50%, #9aa8b5 50%) 6px 11px / 6px 6px no-repeat;
  pointer-events: none;
}

.feed-form input[type="time"] {
  appearance: none;
}

.feed-form select {
  appearance: none;
}

.feed-form small {
  position: absolute;
  right: 12px;
  color: var(--muted);
  font-size: calc(18px * var(--fs, 1));
  pointer-events: none;
}

#feed-amount {
  padding-right: 44px;
}

.sheet-actions {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 12px;
  margin-top: 90px;
}

.cancel-feed,
.save-feed {
  min-height: 58px;
  border: 0;
  border-radius: 999px;
  font-size: calc(19px * var(--fs, 1));
  font-weight: 600;
}

.cancel-feed {
  background: rgba(255, 255, 255, 0.88);
  color: var(--muted);
  border: 1px solid var(--line);
}

/* 所有填写页的“保存”统一用主题蓝；必填未填完时为灰色（见 .incomplete）。 */
.save-feed {
  background: linear-gradient(90deg, #58a9d4, #76c7e8);
  color: #fff;
}





@media (max-width: 380px) {
  .health-grid {
    grid-template-columns: 1fr;
  }

  .primary-action {
    width: 100%;
  }
}

/* 疫苗沿用喂养的底部表单、卡片与主题色。 */
.vaccine-sheet {
  overflow-y: auto;
  overscroll-behavior: contain;
  align-items: start;
}

.vaccine-form {
  min-height: 100%;
}

.vaccine-form .sheet-head {
  margin-bottom: 18px;
}

.vaccine-form .sheet-card {
  min-height: 0;
  padding: 20px 16px;
}

.vaccine-form .feed-hero {
  width: 68px;
  height: 68px;
  margin-bottom: 12px;
  border-radius: 22px;
  background: var(--rose);
  color: #fff;
  font-size: calc(32px * var(--fs, 1));
}

.vaccine-form label {
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 8px;
  font-size: calc(15px * var(--fs, 1));
}

.vaccine-form input,
.vaccine-form select,
.vaccine-form textarea {
  font: inherit;
  font-size: max(16px, calc(16px * var(--fs, 1)));
}

.vaccine-form textarea {
  width: 100%;
  min-width: 0;
  resize: vertical;
  border: 0;
  border-radius: 8px;
  padding: 10px 12px;
  background: #f6f9fb;
  color: var(--text);
}

.vaccine-note-row {
  padding: 8px 0;
}

.vaccine-form-hint,
.vaccine-empty {
  color: var(--muted);
  font-size: calc(12px * var(--fs, 1));
  line-height: 1.7;
}

.vaccine-form-hint {
  margin: 8px 0;
}

.vaccine-form-hint:empty,
.vaccine-error:empty {
  display: none;
}

.vaccine-empty {
  padding: 16px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.65);
}

.vaccine-form .sheet-actions {
  margin-top: 20px;
}


.vaccine-status {
  margin-top: 8px;
}

.vaccine-card .overdue,
.vaccine-error {
  color: #ac5269;
}

.vaccine-error {
  margin-top: 8px;
  font-size: calc(14px * var(--fs, 1));
}

.timeline-card {
  min-width: 0;
  overflow-wrap: anywhere;
}

.vaccine-card .record-meta {
  white-space: pre-wrap;
}

.home-timeline .timeline-time span {
  font-size: calc(13px * var(--fs, 1));
  overflow-wrap: anywhere;
}
/* 账号、密码各占一行：左边标签，右边内容；密码框右侧是眼睛按钮。 */
.growth-mark { background: #e2f4ea; color: #287351; }
#growth-overview { grid-template-columns: repeat(3, minmax(0, 1fr)); }
#growth-overview strong { font-size: calc(18px * var(--fs, 1)); overflow-wrap: anywhere; }
#growth-overview small { display: block; font-size: calc(11px * var(--fs, 1)); margin-top: 5px; }
