/* ============================================================
   warm-host · "蜜桃爪爪" 宠物风设计系统
   来源：docs/design.md §8
   ============================================================ */

/* ============ 设计令牌 (CSS Variables) ============ */
:root {
  /* 品牌色 */
  --color-primary: #ED7B78;
  --color-primary-dark: #D95F5C;
  --color-bg-cream: #FFEFEB;
  --color-bg-page-top: #FFF8F5;
  --color-bg-page-bottom: #FFEFE9;
  --color-card: #FFFFFF;
  --color-border: rgba(233, 118, 123, 0.16);
  --color-border-strong: rgba(233, 118, 123, 0.32);

  /* CTA */
  --color-cta: #FF7A59;
  --color-cta-dark: #F2603C;

  /* 信任色 */
  --color-trust: #4FB58B;
  --color-trust-dark: #3B9E74;

  /* 文字 */
  --color-text: #4A2B2B;
  --color-text-secondary: #8A5F5A;
  --color-text-muted: #C9A29B;
  --color-text-inverse: #FFFFFF;

  /* 状态色 */
  --color-error: #E0524E;
  --color-warning: #E8A838;
  --color-info: #5A8BB4;

  /* 间距 (base = 8px) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 48px;

  /* 圆角 */
  --radius-card: 20px;
  --radius-button: 14px;
  --radius-input: 12px;
  --radius-chip: 999px;

  /* 阴影 */
  --shadow-card: 0 6px 18px rgba(233, 110, 105, 0.12);
  --shadow-cta: 0 6px 16px rgba(255, 122, 89, 0.35);

  /* 字体 */
  --font-serif: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", "SF Mono", Consolas, monospace;

  /* 尺寸 */
  --header-height: 48px;
  --tabbar-height: 56px;
  --cta-height: 56px;
  --touch-target: 44px;
}

/* ============ Reset & Base ============ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 15px;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background: linear-gradient(180deg, var(--color-bg-page-top) 0%, var(--color-bg-page-bottom) 100%);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: var(--color-primary); text-decoration: none; }
a:hover { color: var(--color-primary-dark); }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input, select, textarea {
  font-family: inherit;
  font-size: 15px;
  color: inherit;
}

/* ============ 通用卡片 ============ */
.card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: var(--space-4);
}

/* ============ 按钮 ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: var(--touch-target);
  padding: 0 var(--space-4);
  border-radius: var(--radius-button);
  font-size: 15px;
  font-weight: 500;
  transition: transform 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
  user-select: none;
}

.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.btn-primary {
  background: var(--color-cta);
  color: var(--color-text-inverse);
  box-shadow: var(--shadow-cta);
}
.btn-primary:hover { background: var(--color-cta-dark); }

.btn-secondary {
  background: transparent;
  color: var(--color-primary);
  border: 1px solid var(--color-border-strong);
}
.btn-secondary:hover { background: var(--color-bg-cream); }

.btn-ghost {
  background: transparent;
  color: var(--color-text-secondary);
}
.btn-ghost:hover { background: rgba(233, 118, 123, 0.06); }

.btn-block { display: flex; width: 100%; }

.btn-danger {
  background: var(--color-error);
  color: var(--color-text-inverse);
}

/* ============ 表单 ============ */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  margin-bottom: var(--space-3);
}

.form-group label {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text);
}

.form-group label .hint {
  color: var(--color-text-muted);
  font-weight: 400;
  font-size: 12px;
}

.form-group label .required {
  color: var(--color-error);
  margin-left: 2px;
}

input[type="text"],
input[type="tel"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="date"],
input[type="search"],
select,
textarea {
  width: 100%;
  min-height: var(--touch-target);
  padding: 10px 12px;
  border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-input);
  background: #fff;
  color: var(--color-text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  outline: none;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(233, 118, 123, 0.12);
}

input::placeholder,
textarea::placeholder {
  color: var(--color-text-muted);
}

input[disabled], textarea[disabled], select[disabled] {
  background: var(--color-bg-cream);
  color: var(--color-text-muted);
  cursor: not-allowed;
}

textarea {
  resize: vertical;
  min-height: 80px;
  line-height: 1.5;
}

/* ============ Chip / Badge ============ */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: var(--radius-chip);
  font-size: 12px;
  font-weight: 500;
  background: var(--color-bg-cream);
  color: var(--color-text-secondary);
  border: 1px solid var(--color-border);
}

.chip-primary {
  background: rgba(233, 118, 123, 0.1);
  color: var(--color-primary);
  border-color: rgba(233, 118, 123, 0.2);
}

.chip-trust {
  background: rgba(79, 181, 139, 0.12);
  color: var(--color-trust);
  border-color: rgba(79, 181, 139, 0.24);
}

.chip-cta {
  background: rgba(255, 122, 89, 0.14);
  color: var(--color-cta-dark);
  border-color: rgba(255, 122, 89, 0.28);
}

/* ============ Toast ============ */
.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(-40px);
  padding: 12px 20px;
  border-radius: var(--radius-button);
  background: rgba(74, 43, 43, 0.92);
  color: var(--color-text-inverse);
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 9999;
  max-width: 90vw;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.toast-success { background: var(--color-trust); }
.toast-error { background: var(--color-error); }
.toast-warning { background: var(--color-warning); color: var(--color-text); }
.toast-info { background: var(--color-primary); }

/* ============ 顶部标题栏 ============ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  display: flex;
  align-items: center;
  padding: 0 var(--space-3);
  background: rgba(255, 248, 245, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.header-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  flex: 1;
  text-align: center;
}

.header-back {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 20px;
  color: var(--color-primary);
}
.header-back:hover { background: rgba(233, 118, 123, 0.08); }

/* ============ 底部 Tab 导航 ============ */
.tabbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--tabbar-height);
  background: var(--color-card);
  border-top: 1px solid var(--color-border);
  display: flex;
  padding-bottom: env(safe-area-inset-bottom);
  z-index: 100;
}

.tabbar-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: 11px;
  color: var(--color-text-muted);
  transition: color 0.15s ease;
}

.tabbar-item.active {
  color: var(--color-cta);
}

.tabbar-icon {
  font-size: 20px;
  line-height: 1;
}

/* ============ 容器 ============ */
.container {
  max-width: 640px;
  margin: 0 auto;
  padding: var(--space-3);
}

.page-with-tabbar {
  padding-bottom: calc(var(--tabbar-height) + var(--space-6) + env(safe-area-inset-bottom));
}

/* ============ 页面标题 ============ */
.page-title {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: var(--space-3);
}

/* ============ 空状态 ============ */
.empty-state {
  text-align: center;
  padding: var(--space-6) var(--space-4);
  color: var(--color-text-muted);
}

.empty-state .emoji {
  font-size: 48px;
  margin-bottom: var(--space-3);
  display: block;
}

.empty-state h3 {
  font-family: var(--font-serif);
  font-size: 18px;
  color: var(--color-text-secondary);
  margin-bottom: var(--space-2);
}

/* ============ 动画 ============ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in-up { animation: fadeInUp 0.3s ease-out; }

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.fade-in { animation: fadeIn 0.2s ease-out; }

/* ============================================================
   Auth 页面布局
   ============================================================ */
.auth-container {
  max-width: 400px;
  margin: 0 auto;
  padding: var(--space-6) var(--space-4);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-logo {
  text-align: center;
  margin-bottom: var(--space-5);
}

.auth-logo .logo-icon {
  font-size: 56px;
  display: block;
  margin-bottom: var(--space-2);
}

.auth-logo h1 {
  font-family: var(--font-serif);
  font-size: 32px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: var(--space-1);
}

.auth-logo p {
  font-size: 14px;
  color: var(--color-text-secondary);
}

.auth-tabs {
  display: flex;
  background: var(--color-bg-cream);
  border-radius: var(--radius-button);
  padding: 4px;
  margin-bottom: var(--space-4);
}

.tab-btn {
  flex: 1;
  min-height: 40px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  color: var(--color-text-secondary);
  transition: all 0.2s ease;
}

.tab-btn.active {
  background: var(--color-card);
  color: var(--color-primary);
  box-shadow: 0 2px 8px rgba(233, 118, 123, 0.1);
}

.auth-form {
  display: none;
  animation: fadeIn 0.2s ease-out;
}

.auth-form.active {
  display: block;
}

.invite-input {
  letter-spacing: 4px;
  font-family: var(--font-mono);
  font-weight: 700;
  text-transform: uppercase;
  text-align: center;
  padding: 12px 8px;
}

.auth-tip {
  text-align: center;
  margin-top: var(--space-4);
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.auth-footer {
  text-align: center;
  margin-top: var(--space-5);
  font-size: 12px;
  color: var(--color-text-muted);
}

/* ============================================================
   My 页面 · 4 Tab + 宠物档案
   ============================================================ */

.my-tabs {
  display: flex;
  background: var(--color-bg-cream);
  border-radius: var(--radius-button);
  padding: 4px;
  margin-bottom: var(--space-4);
  gap: 4px;
}

.my-tab {
  flex: 1;
  min-height: 40px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-secondary);
  transition: all 0.2s ease;
}

.my-tab.active {
  background: var(--color-card);
  color: var(--color-primary);
  box-shadow: 0 2px 8px rgba(233, 118, 123, 0.1);
}

.my-content { display: none; }
.my-content.active { display: block; animation: fadeIn 0.2s ease-out; }

/* 宠物卡片 */
.pet-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 12px;
}

.pet-cover {
  width: 72px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--color-bg-cream);
}

.pet-cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--color-text-muted);
}

.pet-info { flex: 1; min-width: 0; }

.pet-name {
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 2px;
}

.pet-species { font-size: 16px; margin-left: 4px; }

.pet-breed {
  font-size: 13px;
  color: var(--color-text-secondary);
  margin-bottom: 4px;
}

.pet-meta {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: 6px;
}

.pet-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
}

.pet-actions {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pet-actions .btn {
  padding: 4px 10px;
  min-height: 32px;
  font-size: 13px;
}

.pet-delete { color: var(--color-error); }

/* 表单行 */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* 性格 chips */
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip-cursor {
  cursor: pointer;
  user-select: none;
  padding: 6px 14px;
  font-size: 13px;
  transition: all 0.15s ease;
}

.chip-cursor.chip-primary {
  background: rgba(233, 118, 123, 0.14);
  color: var(--color-primary);
  border-color: rgba(233, 118, 123, 0.36);
}

/* 照片选择器 */
.photo-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.photo-item {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 8px;
  overflow: hidden;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border);
}

.photo-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-add {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  border: 2px dashed var(--color-border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--color-text-muted);
  cursor: pointer;
  background: var(--color-bg-cream);
  transition: all 0.15s ease;
}

.photo-add:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
}

.photo-cover-btn,
.photo-del-btn {
  position: absolute;
  top: 2px;
  min-height: 22px;
  border-radius: 4px;
  font-size: 11px;
  padding: 2px 6px;
  cursor: pointer;
  color: var(--color-text-inverse);
}

.photo-cover-btn {
  left: 2px;
  background: rgba(74, 43, 43, 0.75);
}

.photo-del-btn {
  right: 2px;
  background: rgba(201, 76, 76, 0.9);
  font-weight: 700;
}

.photo-badge {
  position: absolute;
  bottom: 2px;
  left: 2px;
  background: var(--color-cta);
  color: var(--color-text-inverse);
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 500;
}

/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: none;
}

.modal.show { display: block; }

.modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(74, 43, 43, 0.5);
  animation: fadeIn 0.2s ease-out;
}

.modal-content {
  position: relative;
  max-width: 640px;
  margin: 40px auto;
  max-height: calc(100vh - 80px);
  background: var(--color-card);
  border-radius: var(--radius-card);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.24);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: fadeInUp 0.25s ease-out;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-page-top);
}

.modal-header h3 {
  font-family: var(--font-serif);
  font-size: 17px;
  color: var(--color-primary);
}

.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--color-text-secondary);
  cursor: pointer;
}

.modal-close:hover { background: rgba(233, 118, 123, 0.08); }

.modal-body {
  padding: 16px 20px 24px;
  overflow-y: auto;
}

/* 空状态 · 简化 */
.empty-state p {
  font-size: 13px;
  margin-top: var(--space-2);
  color: var(--color-text-muted);
}



/* (legacy comment removed) */
.host-banner {
  display: flex;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-card);
  background: var(--color-card);
  border: 1px solid var(--color-border);
  margin-bottom: 14px;
  align-items: flex-start;
}
.host-banner-hidden { display: none; }
.host-banner-icon {
  font-size: 22px;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}
.host-banner-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}
.host-banner-sub {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: 3px;
}
.host-banner-amber {
  background: linear-gradient(135deg, #FFF6E3 0%, #FFEFC9 100%);
  border-color: rgba(232, 168, 56, 0.35);
}
.host-banner-amber .host-banner-title { color: #B88020; }
.host-banner-amber .host-banner-sub { color: #A06D15; }
.host-banner-danger {
  background: linear-gradient(135deg, #FFEDED 0%, #FFDCDC 100%);
  border-color: rgba(201, 76, 76, 0.3);
}
.host-banner-danger .host-banner-title { color: var(--color-error); }
.host-banner-danger .host-banner-sub { color: #A03B3B; }
.host-banner-info {
  background: linear-gradient(135deg, #EDF3FB 0%, #DCE7F3 100%);
  border-color: rgba(90, 139, 180, 0.25);
}
.host-banner-info .host-banner-title { color: var(--color-info); }
.host-banner-info .host-banner-sub { color: #4A6F94; }

/* (legacy comment removed) */
.host-sponsor-hint {
  display: flex;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-card);
  background: linear-gradient(135deg, #F5EBDD 0%, var(--color-bg-cream) 100%);
  border: 1px solid var(--color-border);
  margin-bottom: 14px;
  align-items: flex-start;
}
.host-sponsor-hint .host-banner-icon { font-size: 20px; }
.host-sponsor-hint .host-banner-title { font-size: 13px; font-weight: 600; }
.host-sponsor-hint .host-banner-sub { font-size: 12px; }
.host-hint-link {
  color: var(--color-primary);
  text-decoration: underline;
  cursor: pointer;
}

/* (legacy comment removed) */
.host-form {
  padding: 18px 16px 20px;
  margin-bottom: 16px;
}
.host-form-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  margin: 0 0 14px 0;
}

/* (legacy comment removed) */
.host-availability {
  padding: 18px 16px 20px;
  background: var(--color-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--color-border);
  margin-bottom: 16px;
}
.host-availability-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 12px;
  gap: 10px;
  flex-wrap: wrap;
}
.host-availability-header h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  margin: 0;
}
.host-availability-header .hint {
  font-size: 12px;
  color: var(--color-text-muted);
}

/* (legacy comment removed) */
.cal-wrap {
  padding: 4px 0 8px;
}
.cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.cal-nav-btn {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border);
  color: var(--color-primary);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cal-nav-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.cal-month-label {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}
.cal-legend {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  font-size: 11px;
  color: var(--color-text-secondary);
}
.cal-legend-item { display: inline-flex; align-items: center; gap: 4px; }
.cal-legend-swatch {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  display: inline-block;
  border: 1px solid var(--color-border);
}
.cal-legend-today { background: var(--color-bg-cream); border-color: var(--color-primary); }
.cal-legend-picking { background: #E8D5F2; border-color: #B489D6; }
.cal-legend-range { background: var(--color-trust); border-color: var(--color-trust-dark); }

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}
.cal-head {
  text-align: center;
  font-size: 11px;
  color: var(--color-text-muted);
  padding: 4px 0;
}
.cal-cell {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: var(--color-text);
  border-radius: 8px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  cursor: pointer;
  user-select: none;
  transition: background 0.15s ease;
}
.cal-cell:hover { background: var(--color-bg-cream); }
.cal-cell-empty { background: transparent; border: none; cursor: default; }
.cal-cell-disabled {
  color: var(--color-text-muted);
  background: transparent;
  border: 1px dashed var(--color-border);
  cursor: not-allowed;
  opacity: 0.5;
}
.cal-cell-disabled:hover { background: transparent; }
.cal-cell-today {
  border-color: var(--color-primary);
  font-weight: 700;
  color: var(--color-primary);
}
.cal-cell-range {
  background: var(--color-trust);
  color: var(--color-text-inverse);
  border-color: var(--color-trust-dark);
}
.cal-cell-range:hover { background: var(--color-trust-dark); }
.cal-cell-picking {
  background: #F4E8FA;
  border-color: #B489D6;
  color: #6B3E9E;
}
.cal-cell-anchor {
  background: #E8D5F2;
  border-color: #B489D6;
  color: #6B3E9E;
  font-weight: 700;
  box-shadow: 0 0 0 2px rgba(180, 137, 214, 0.3);
}

/* (legacy comment removed) */
.cal-ranges {
  margin-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cal-ranges-empty {
  font-size: 12px;
  color: var(--color-text-muted);
  padding: 8px;
  text-align: center;
  border: 1px dashed var(--color-border);
  border-radius: 8px;
}
.cal-range-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(79, 181, 139, 0.08);
  border: 1px solid rgba(79, 181, 139, 0.25);
  border-radius: 8px;
}
.cal-range-idx {
  font-size: 11px;
  font-weight: 700;
  color: var(--color-trust-dark);
  background: var(--color-card);
  border: 1px solid var(--color-trust);
  border-radius: 4px;
  padding: 2px 6px;
  flex-shrink: 0;
}
.cal-range-body { flex: 1; min-width: 0; }
.cal-range-date {
  font-size: 13px;
  color: var(--color-text);
  font-weight: 600;
}
.cal-range-meta {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 2px;
}
.cal-range-del {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: transparent;
  border: 1px solid var(--color-border);
  color: var(--color-error);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.cal-range-del:hover {
  background: rgba(201, 76, 76, 0.1);
}


/* ============================================================
   Hosts 列表页 + Host 详情页
   Task 7b
   ============================================================ */

/* 顶部 header 中占位（保持标题居中） */
.header-placeholder {
  width: 32px;
}

/* ============ 筛选面板 ============ */
.filter-panel {
  padding: 14px 16px 16px;
  margin-bottom: 16px;
}
.filter-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.filter-header h3 {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary);
}
.filter-toggle {
  font-size: 13px;
  color: var(--color-primary);
  padding: 6px 12px;
  border-radius: var(--radius-button);
  border: 1px solid var(--color-border);
  background: var(--color-bg-cream);
}
.filter-toggle:hover {
  background: rgba(233, 118, 123, 0.08);
}
.filter-body {
  animation: fadeIn 0.2s ease-out;
}

/* ============ 结果计数 ============ */
.result-count {
  font-size: 13px;
  color: var(--color-text-secondary);
  padding: 4px 4px 12px;
}

/* ============ 寄养人卡片 ============ */
.host-card {
  display: flex;
  align-items: stretch;
  gap: 14px;
  padding: 14px;
  margin-bottom: 12px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  color: inherit;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  animation: fadeInUp 0.3s ease-out;
}
.host-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(233, 118, 123, 0.14);
  border-color: var(--color-border-strong);
}
.host-card-avatar-wrap {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.host-avatar,
.host-avatar-fallback {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border);
}
.host-avatar-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: var(--color-text-muted);
}
.host-card-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.host-card-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.host-card-name {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text);
}
.host-card-badges {
  display: inline-flex;
  gap: 4px;
  flex-wrap: wrap;
}
.host-card-rating {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--color-text-secondary);
}
.host-card-stars {
  color: var(--color-cta);
  font-size: 13px;
  letter-spacing: 1px;
}
.host-card-rating-num {
  font-weight: 600;
  color: var(--color-text);
  font-family: var(--font-mono);
}
.host-card-reviews {
  color: var(--color-text-muted);
}
.host-card-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.host-region {
  font-size: 12px;
  color: var(--color-text-secondary);
}
.host-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 2px;
}
.host-price {
  font-size: 13px;
  color: var(--color-text-secondary);
}
.host-price strong {
  color: var(--color-cta-dark);
  font-family: var(--font-mono);
  font-size: 15px;
  margin: 0 2px;
}
.host-price small {
  color: var(--color-text-muted);
  font-size: 11px;
}
.host-card-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  font-size: 20px;
  padding: 0 4px;
  flex-shrink: 0;
}

/* ============ 徽章（认证 / 担保 / 可接天数） ============ */
.badge-verified,
.badge-sponsored,
.badge-availability {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 2px 8px;
  border-radius: var(--radius-chip);
  font-size: 11px;
  font-weight: 600;
  line-height: 1.4;
}
.badge-verified {
  background: rgba(79, 181, 139, 0.16);
  color: var(--color-trust-dark);
  border: 1px solid rgba(79, 181, 139, 0.3);
}
.badge-sponsored {
  background: rgba(233, 118, 123, 0.14);
  color: var(--color-primary-dark);
  border: 1px solid rgba(233, 118, 123, 0.28);
}
.badge-availability {
  background: rgba(255, 122, 89, 0.16);
  color: var(--color-cta-dark);
  border: 1px solid rgba(255, 122, 89, 0.32);
}

/* ============ 详情页头部卡 ============ */
.detail-header {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 20px 18px;
  margin-bottom: 16px;
}
.detail-avatar-wrap {
  width: 96px;
  height: 96px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.detail-avatar,
.detail-avatar-fallback {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border);
}
.detail-avatar-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  color: var(--color-text-muted);
}
.detail-header-body {
  flex: 1;
  min-width: 0;
}
.detail-header-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.detail-name {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.2;
}
.detail-badges {
  display: inline-flex;
  gap: 4px;
  flex-wrap: wrap;
}
.detail-header-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--color-text-secondary);
  flex-wrap: wrap;
}
.detail-stars {
  color: var(--color-cta);
  font-size: 15px;
  letter-spacing: 1px;
}
.detail-rating-num {
  font-weight: 600;
  color: var(--color-text);
  font-family: var(--font-mono);
}
.detail-reviews {
  color: var(--color-text-muted);
}

/* ============ 详情页通用 ============ */
.info-card,
.card {
  margin-bottom: 16px;
}
.section-title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary);
  margin: 0 0 12px 0;
}
.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
}
.info-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.info-label {
  font-size: 12px;
  color: var(--color-text-muted);
}
.info-value {
  font-size: 14px;
  color: var(--color-text);
  font-weight: 500;
  word-break: break-word;
}
.detail-text {
  font-size: 14px;
  line-height: 1.65;
  color: var(--color-text);
  white-space: pre-wrap;
  word-break: break-word;
}

/* ============ 可接单日期 ============ */
.availability-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.availability-empty {
  font-size: 13px;
  color: var(--color-text-muted);
  padding: 10px;
  text-align: center;
  border: 1px dashed var(--color-border);
  border-radius: 8px;
}
.availability-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: rgba(79, 181, 139, 0.08);
  border: 1px solid rgba(79, 181, 139, 0.24);
  border-radius: 8px;
}
.availability-idx {
  font-size: 18px;
  flex-shrink: 0;
}
.availability-body {
  flex: 1;
  min-width: 0;
}
.availability-date {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-trust-dark);
}
.availability-meta {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

/* ============ 评价 ============ */
.reviews-header {
  margin-bottom: 12px;
}
.rating-summary {
  display: flex;
  gap: 20px;
  padding: 14px 12px;
  background: var(--color-bg-cream);
  border-radius: 12px;
  margin-bottom: 16px;
  align-items: center;
  flex-wrap: wrap;
}
.rating-avg {
  text-align: center;
  flex-shrink: 0;
  min-width: 90px;
}
.rating-avg-num {
  font-family: var(--font-mono);
  font-size: 34px;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1;
}
.rating-avg-stars {
  color: var(--color-cta);
  font-size: 14px;
  letter-spacing: 1px;
  margin-top: 4px;
}
.rating-avg-count {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 2px;
}
.rating-bars {
  flex: 1;
  min-width: 160px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.rating-bar-row {
  display: grid;
  grid-template-columns: 30px 1fr 24px;
  gap: 8px;
  align-items: center;
  font-size: 12px;
}
.rating-bar-label {
  color: var(--color-text-secondary);
}
.rating-bar-track {
  height: 8px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  overflow: hidden;
}
.rating-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--color-cta) 0%, var(--color-cta-dark) 100%);
  border-radius: 4px;
  transition: width 0.4s ease-out;
  width: 0;
}
.rating-bar-count {
  color: var(--color-text-muted);
  text-align: right;
  font-family: var(--font-mono);
}

.reviews-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.reviews-list-empty {
  font-size: 13px;
  color: var(--color-text-muted);
  padding: 12px;
  text-align: center;
}
.review-card {
  padding: 12px 14px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
}
.review-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.review-avatar-wrap {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.review-avatar,
.review-avatar-fallback {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border);
}
.review-avatar-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 600;
  color: var(--color-primary);
  background: rgba(233, 118, 123, 0.1);
  border: 1px solid var(--color-border-strong);
}
.review-meta {
  flex: 1;
  min-width: 0;
}
.review-nickname {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}
.review-time {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 1px;
}
.review-rating {
  color: var(--color-cta);
  font-size: 13px;
  letter-spacing: 1px;
  flex-shrink: 0;
}
.review-content {
  font-size: 14px;
  line-height: 1.6;
  color: var(--color-text);
  white-space: pre-wrap;
  word-break: break-word;
}
.review-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}

/* ============ 底部悬浮 CTA ============ */
.cta-fixed {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(251, 245, 238, 0) 0%, rgba(251, 245, 238, 0.95) 40%, var(--color-bg-page-top) 100%);
  z-index: 100;
}
.cta-fixed .btn {
  max-width: 640px;
  margin: 0 auto;
  height: var(--cta-height);
  font-size: 17px;
  font-weight: 600;
}
.page-with-cta {
  padding-bottom: calc(var(--cta-height) + 32px + env(safe-area-inset-bottom));
}

/* ============ 骨架屏（预留） ============ */
.skeleton {
  background: linear-gradient(90deg, var(--color-bg-cream) 25%, #EFE3D3 37%, var(--color-bg-cream) 63%);
  background-size: 400% 100%;
  animation: skeleton-loading 1.4s ease infinite;
  border-radius: 8px;
}
@keyframes skeleton-loading {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}


/* ============ 需求 Tab · Task 9 ============ */
#needs-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 12px;
}

/* 需求卡片 */
.need-card {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.need-card-head {
  display: flex;
  align-items: center;
  gap: 12px;
}
.need-pet-cover {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  object-fit: cover;
  border: 1px solid var(--color-border);
  background: var(--color-bg-cream);
  flex-shrink: 0;
}
.need-pet-cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
}
.need-card-title {
  flex: 1;
  min-width: 0;
}
.need-pet-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: 4px;
}
.need-pet-species {
  font-size: 15px;
}
.need-pet-meta {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 2px;
}
.need-card-status {
  flex-shrink: 0;
}

/* 状态徽章 */
.badge-need-amber {
  background: rgba(232, 168, 56, 0.15);
  color: #B37A18;
  border: 1px solid rgba(232, 168, 56, 0.35);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-need-blue {
  background: rgba(91, 140, 200, 0.15);
  color: #3E6B9E;
  border: 1px solid rgba(91, 140, 200, 0.35);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-need-green {
  background: rgba(79, 181, 139, 0.15);
  color: #4F7040;
  border: 1px solid rgba(79, 181, 139, 0.35);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-need-gray {
  background: rgba(201, 162, 155, 0.25);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}

/* 需求详情行 */
.need-card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 10px 12px;
  background: var(--color-bg-cream);
  border-radius: 10px;
  border: 1px solid var(--color-border);
}
.need-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 13px;
  line-height: 1.5;
}
.need-label {
  color: var(--color-text-muted);
  flex-shrink: 0;
  min-width: 60px;
}
.need-value {
  color: var(--color-text);
  flex: 1;
  min-width: 0;
  word-break: break-word;
}

/* 需求操作区 */
.need-card-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.need-card-actions .btn {
  flex: 1;
  min-width: 90px;
}
.need-cancel {
  color: var(--color-text-muted);
}
.need-order-hint {
  font-size: 12px;
  color: var(--color-text-muted);
  padding: 4px 0;
}

/* ============ 订单 Tab · Task 10b ============ */

/* 角色切换 */
.order-tabs-role {
  margin-bottom: 14px;
}
.seg-control {
  display: flex;
  background: var(--color-bg-cream);
  border-radius: var(--radius-button);
  padding: 4px;
  gap: 4px;
  border: 1px solid var(--color-border);
}
.seg-btn {
  flex: 1;
  min-height: 38px;
  border-radius: 9px;
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-secondary);
  transition: all 0.2s ease;
  background: transparent;
}
.seg-btn.active {
  background: var(--color-card);
  color: var(--color-primary);
  box-shadow: 0 2px 8px rgba(233, 118, 123, 0.1);
}

/* 订单列表容器 */
#orders-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 4px;
}

/* 订单卡片 */
.order-card {
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.order-card-body {
  cursor: pointer;
}
.order-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.order-card-badge {
  display: inline-flex;
}
.order-card-date {
  font-size: 12px;
  color: var(--color-text-secondary);
  font-family: var(--font-mono);
}

/* 状态徽章 */
.badge-order-amber {
  background: rgba(232, 168, 56, 0.15);
  color: #B37A18;
  border: 1px solid rgba(232, 168, 56, 0.35);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-order-blue {
  background: rgba(91, 140, 200, 0.15);
  color: #3E6B9E;
  border: 1px solid rgba(91, 140, 200, 0.35);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-order-green {
  background: rgba(79, 181, 139, 0.18);
  color: #4F7040;
  border: 1px solid rgba(79, 181, 139, 0.4);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-order-done {
  background: rgba(59, 158, 116, 0.22);
  color: #3D5432;
  border: 1px solid rgba(59, 158, 116, 0.45);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-order-gray {
  background: rgba(201, 162, 155, 0.25);
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}
.badge-order-red {
  background: rgba(201, 76, 76, 0.14);
  color: #A03B3B;
  border: 1px solid rgba(201, 76, 76, 0.35);
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  white-space: nowrap;
}

/* 宠物信息 */
.order-card-pet {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  background: var(--color-bg-cream);
  border-radius: 10px;
  border: 1px solid var(--color-border);
}
.order-pet-cover {
  width: 60px;
  height: 60px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--color-border);
  background: var(--color-card);
  flex-shrink: 0;
}
.order-pet-cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
}
.order-pet-info {
  flex: 1;
  min-width: 0;
}
.order-pet-name {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text);
  display: flex;
  align-items: center;
  gap: 4px;
}
.order-pet-icon { font-size: 15px; }
.order-pet-breed {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: 2px;
}
.order-pet-meta {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 2px;
}

/* 对方信息 */
.order-card-peer {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 4px 2px;
}
.order-peer-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border);
  flex-shrink: 0;
}
.order-peer-avatar-fallback {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(233, 118, 123, 0.1);
  border: 1px solid var(--color-border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.order-peer-info {
  flex: 1;
  min-width: 0;
}
.order-peer-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}
.order-peer-region {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 1px;
}

/* 金额行 */
.order-card-amount {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  background: rgba(255, 122, 89, 0.08);
  border-radius: 8px;
  border: 1px solid rgba(255, 122, 89, 0.2);
  margin-top: 2px;
}
.order-amount-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}
.order-amount-label {
  font-size: 12px;
  color: var(--color-text-secondary);
}
.order-amount-value {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-cta-dark);
  font-family: var(--font-mono);
}
.order-amount-sub {
  font-size: 11px;
  color: var(--color-text-muted);
  margin-top: 2px;
}

/* 操作区 */
.order-card-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.order-card-actions .btn {
  flex: 1;
  min-width: 100px;
}
.btn-flex {
  flex: 1;
  min-width: 100px;
}

/* 空状态 & 提示 */
.order-empty {
  text-align: center;
  padding: 40px 20px;
  background: var(--color-card);
  border-radius: var(--radius-card);
  border: 1px dashed var(--color-border);
}
.order-empty .emoji {
  font-size: 42px;
  display: block;
  margin-bottom: 10px;
}
.order-empty h3 {
  font-family: var(--font-serif);
  font-size: 16px;
  color: var(--color-text);
  margin-bottom: 6px;
}
.order-empty p {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
}
.order-hint {
  font-size: 12px;
  color: var(--color-text-muted);
  padding: 4px 0;
  flex: 1;
  min-width: 100px;
  text-align: center;
}

/* 详情折叠 */
.order-detail-expand {
  display: none;
  flex-direction: column;
  gap: 10px;
  padding: 12px 14px;
  background: var(--color-bg-cream);
  border-radius: 10px;
  border: 1px solid var(--color-border);
}
.order-card-expanded .order-detail-expand {
  display: flex;
  animation: fadeIn 0.2s ease-out;
}
.order-detail-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.order-detail-label {
  font-size: 12px;
  color: var(--color-text-muted);
  font-weight: 500;
}
.order-detail-text {
  font-size: 13px;
  color: var(--color-text);
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}
.order-detail-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

/* 时间线 */
.order-timeline {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-left: 12px;
  border-left: 2px solid var(--color-border-strong);
  margin-top: 4px;
}
.order-timeline-item {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 12px;
  line-height: 1.5;
}
.order-timeline-time {
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  flex-shrink: 0;
  font-size: 11px;
}
.order-timeline-label {
  color: var(--color-text);
  font-weight: 500;
}

/* 骨架屏 */
.order-skeleton {
  padding: 16px;
  background: var(--color-card);
  border-radius: var(--radius-card);
  border: 1px solid var(--color-border);
}
/* ============================================================
   Task 11 · 评价弹窗样式
   ============================================================ */

.review-modal-head {
  padding: 12px 14px;
  background: var(--color-bg, #fafafa);
  border-radius: var(--radius-card, 12px);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.review-modal-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text, #333);
}

.review-stars {
  display: flex;
  gap: 6px;
  align-items: center;
}
.star {
  font-size: 30px;
  line-height: 1;
  color: #d0d0d0;
  cursor: pointer;
  user-select: none;
  transition: color .12s ease, transform .12s ease;
}
.star:hover { transform: scale(1.12); }
.star.active {
  color: #ff7a45;
}

.review-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tag-chip {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--color-bg, #fafafa);
  border: 1px solid var(--color-border, #e5e5e5);
  font-size: 13px;
  color: var(--color-text, #333);
  cursor: pointer;
  user-select: none;
  transition: all .12s ease;
}
.tag-chip:hover {
  border-color: var(--color-cta, #ff7a45);
}
.tag-chip.active {
  background: var(--color-cta, #ff7a45);
  color: #fff;
  border-color: var(--color-cta, #ff7a45);
}

.review-textarea {
  width: 100%;
  min-height: 88px;
  padding: 10px 12px;
  border: 1px solid var(--color-border, #e5e5e5);
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.5;
  resize: vertical;
  font-family: inherit;
  background: #fff;
  color: var(--color-text, #333);
}
.review-textarea:focus {
  outline: none;
  border-color: var(--color-cta, #ff7a45);
}
.char-count {
  text-align: right;
  font-size: 12px;
  color: var(--color-text-muted, #999);
  margin-top: 4px;
}

.review-upload {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.review-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.review-thumb {
  position: relative;
  width: 80px;
  height: 80px;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--color-border, #e5e5e5);
  background: var(--color-bg, #fafafa);
}
.review-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.review-thumb-del {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: none;
  background: rgba(0,0,0,.55);
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.review-thumb-del:hover { background: rgba(255,70,70,.9); }
.review-thumb-add {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--color-text-muted, #999);
  cursor: pointer;
  border-style: dashed;
}
.review-thumb-add:hover {
  border-color: var(--color-cta, #ff7a45);
  color: var(--color-cta, #ff7a45);
}

/* 已评价标签 */
.review-done-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 8px;
  background: var(--color-bg, #f0f0f0);
  color: var(--color-text-muted, #999);
  font-size: 13px;
  font-weight: 500;
}
/* ==================================================================== */
/*  通知系统 (Task 14) - bell + panel + items                           */
/* ==================================================================== */

.notif-bell {
  position: relative;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 18px;
  color: var(--color-primary, #8b5e3c);
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  flex-shrink: 0;
}

.notif-bell:hover {
  background: rgba(233, 118, 123, 0.08);
}

.notif-bell-icon {
  font-size: 18px;
  line-height: 1;
}

.notif-badge {
  position: absolute;
  top: -2px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 8px;
  background: #e54b4b;
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
  box-sizing: border-box;
  pointer-events: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
}

.notif-panel {
  position: fixed;
  top: 60px;
  right: 12px;
  width: 360px;
  max-width: calc(100vw - 24px);
  max-height: 72vh;
  background: #ffffff;
  border: 1px solid var(--color-border, rgba(233, 118, 123, 0.15));
  border-radius: var(--radius-card, 14px);
  box-shadow: 0 12px 32px rgba(74, 43, 43, 0.18);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: notif-panel-in 0.15s ease-out;
}

@keyframes notif-panel-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.notif-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--color-border, rgba(233, 118, 123, 0.15));
  flex-shrink: 0;
}

.notif-panel-title {
  font-family: var(--font-serif, Georgia, serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--color-primary, #8b5e3c);
}

.notif-read-all {
  background: transparent;
  border: none;
  color: var(--color-text-muted, #8a7d70);
  font-size: 12px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}

.notif-read-all:hover {
  background: rgba(233, 118, 123, 0.08);
  color: var(--color-primary, #8b5e3c);
}

.notif-panel-body {
  flex: 1;
  overflow-y: auto;
  max-height: calc(72vh - 92px);
  padding: 4px 0;
}

.notif-panel-foot {
  padding: 8px 16px 12px;
  border-top: 1px solid var(--color-border, rgba(233, 118, 123, 0.15));
  text-align: center;
  flex-shrink: 0;
  background: rgba(251, 245, 238, 0.5);
}

.notif-view-all {
  background: transparent;
  border: none;
  color: var(--color-primary, #8b5e3c);
  font-size: 13px;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 6px;
  transition: background 0.15s;
}

.notif-view-all:hover {
  background: rgba(233, 118, 123, 0.08);
}

.notif-item {
  position: relative;
  display: flex;
  gap: 10px;
  padding: 10px 16px;
  cursor: pointer;
  transition: background 0.15s;
  border-bottom: 1px solid rgba(233, 118, 123, 0.05);
}

.notif-item:last-child {
  border-bottom: none;
}

.notif-item:hover {
  background: rgba(233, 118, 123, 0.05);
}

.notif-item.unread {
  background: rgba(229, 75, 75, 0.04);
}

.notif-item.unread:hover {
  background: rgba(229, 75, 75, 0.08);
}

.notif-dot {
  position: absolute;
  left: 6px;
  top: 18px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #e54b4b;
}

.notif-item-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.notif-item-body {
  flex: 1;
  min-width: 0;
}

.notif-item-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text, #4a2b2b);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notif-item.unread .notif-item-title {
  color: #4a2b2b;
}

.notif-item-desc {
  font-size: 12px;
  color: var(--color-text-muted, #8a7d70);
  line-height: 1.4;
  margin-top: 2px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.notif-item-time {
  font-size: 11px;
  color: var(--color-text-muted, #a89d90);
  margin-top: 4px;
}

.notif-empty {
  text-align: center;
  padding: 32px 16px;
  color: var(--color-text-muted, #8a7d70);
  font-size: 13px;
}

/* 移动端适配 */
@media (max-width: 480px) {
  .notif-panel {
    right: 6px;
    left: 6px;
    width: auto;
    max-width: none;
    top: 54px;
  }
}

/* ============================================================
   Task 15 — 底部 Tab 导航 + 首页 index.html 样式
   ============================================================ */

/* ---- 底部 Tab 导航 ---- */
.bottom-tab-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--tabbar-height);
  background: var(--color-card);
  border-top: 1px solid var(--color-border-strong);
  display: flex;
  padding: 0 4px;
  padding-bottom: env(safe-area-inset-bottom);
  z-index: 200;
  box-shadow: 0 -2px 12px rgba(233, 118, 123, 0.08);
}

.bottom-tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: var(--color-text-muted);
  text-decoration: none;
  font-size: 10px;
  font-weight: 500;
  transition: color 0.15s ease, transform 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}

.bottom-tab:active {
  transform: scale(0.95);
}

.bottom-tab.active {
  color: var(--color-primary);
  font-weight: 700;
}

.bottom-tab.active .bottom-tab-icon {
  transform: translateY(-1px);
}

.bottom-tab-icon {
  font-size: 22px;
  line-height: 1;
  transition: transform 0.2s ease;
}

.bottom-tab-label {
  font-size: 10px;
  line-height: 1.2;
}

/* body 加底部留白，避免内容被底部栏遮挡 */
body.has-bottom-tabbar {
  padding-bottom: calc(var(--tabbar-height) + 16px + env(safe-area-inset-bottom));
}

/* .page-with-tabbar 已经自带底部 padding，避免重复 */
body.has-bottom-tabbar .page-with-tabbar {
  padding-bottom: 20px;
}

/* host-detail 的固定 CTA 按钮上移到 Tab 栏之上 */
body.has-bottom-tabbar .cta-fixed {
  bottom: calc(var(--tabbar-height) + env(safe-area-inset-bottom));
}

/* ---- 首页：品牌栏 ---- */
.home-brand {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  background: rgba(255, 248, 245, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.home-brand-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.home-brand-logo {
  font-size: 28px;
  line-height: 1;
}

.home-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 0;
}

.home-brand-name {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
}

.home-brand-slogan {
  font-size: 11px;
  color: var(--color-text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.home-brand-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.home-login-btn {
  min-height: 34px;
  padding: 0 14px;
  font-size: 13px;
}

.home-logout-btn {
  min-height: 32px;
  padding: 0 10px;
  font-size: 12px;
}

.home-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-text-inverse);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 14px;
}

/* ---- 首页：Hero ---- */
.home-hero {
  padding: 34px 20px 30px;
  text-align: center;
  background: linear-gradient(150deg, #FFB1A3 0%, #F97C7C 62%, #F76E8E 100%);
  border-radius: 0 0 28px 28px;
  color: #fff;
  box-shadow: 0 10px 28px rgba(249, 124, 124, 0.28);
}

.home-hero-title {
  font-family: var(--font-serif);
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  line-height: 1.25;
  margin-bottom: 10px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.home-hero-sub {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.92);
  margin-bottom: 18px;
}

.home-cta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  max-width: 420px;
  margin: 0 auto;
}

.home-cta .btn {
  font-size: 15px;
}

.home-hero .btn-secondary {
  background: rgba(255, 255, 255, 0.92);
  color: var(--color-cta-dark);
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* ---- 首页：搜索栏 ---- */
.home-search {
  margin: 16px 16px 0;
  padding: 16px;
}

.home-search-title {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--color-primary);
  margin-bottom: 12px;
  font-weight: 600;
}

.home-search-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.home-search-row input[type="date"] {
  flex: 1;
  min-height: 40px;
  padding: 8px 10px;
  font-size: 14px;
}

.home-search-sep {
  color: var(--color-text-muted);
  font-size: 14px;
  flex-shrink: 0;
}

.home-search input[type="text"] {
  margin-bottom: 10px;
  min-height: 40px;
  font-size: 14px;
}

.home-search .btn {
  min-height: 44px;
  font-size: 15px;
}

/* ---- 首页：数据看板 ---- */
.home-stats {
  margin: 16px;
  padding: 16px;
}

.home-stats-title {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--color-primary);
  margin-bottom: 12px;
  font-weight: 600;
}

.home-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.home-stat-item {
  text-align: center;
  padding: 10px 4px;
  background: var(--color-bg-cream);
  border-radius: 10px;
}

.home-stat-num {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.2;
}

.home-stat-label {
  font-size: 11px;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

.home-stat-highlight {
  background: rgba(255, 122, 89, 0.10);
}

.home-stat-highlight .home-stat-num {
  color: var(--color-cta-dark);
}

/* ---- 首页：通用 section 标题 ---- */
.home-section-title {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  margin: 20px 16px 12px;
}

/* ---- 首页：价值主张三卡片 ---- */
.home-value-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  padding: 0 16px;
}

.home-value-card {
  padding: 14px 16px;
}

.home-value-icon {
  font-size: 28px;
  line-height: 1;
  margin-bottom: 6px;
}

.home-value-title {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.home-value-desc {
  font-size: 13px;
  color: var(--color-text-secondary);
  line-height: 1.5;
}

/* ---- 首页：如何运作 ---- */
.home-steps {
  padding: 0 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.home-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: 12px 14px;
  box-shadow: var(--shadow-card);
}

.home-step-idx {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-text-inverse);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}

.home-step-body h3 {
  font-family: var(--font-serif);
  font-size: 15px;
  color: var(--color-primary);
  margin-bottom: 2px;
}

.home-step-body p {
  font-size: 13px;
  color: var(--color-text-secondary);
  line-height: 1.5;
}

/* ---- 首页：信任机制四件套 ---- */
.home-trust {
  padding: 0 16px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.home-trust-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 12px;
  background: var(--color-bg-cream);
  border-radius: 10px;
  border: 1px solid var(--color-border);
}

.home-trust-icon {
  font-size: 20px;
  line-height: 1;
}

.home-trust-label {
  font-family: var(--font-serif);
  font-size: 13px;
  color: var(--color-primary);
  font-weight: 700;
}

.home-trust-desc {
  font-size: 11px;
  color: var(--color-text-secondary);
  line-height: 1.4;
}

/* ---- 首页：页脚 ---- */
.home-footer {
  margin-top: 24px;
  padding: 20px 16px 12px;
  text-align: center;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg-page-top);
}

.home-footer-brand {
  font-family: var(--font-serif);
  font-size: 13px;
  color: var(--color-primary);
  margin-bottom: 4px;
}

.home-footer-meta {
  font-size: 11px;
  color: var(--color-text-muted);
}

/* ---- 桌面端布局微调 ---- */
@media (min-width: 769px) {
  .home-hero-title { font-size: 32px; }
  .home-value-cards {
    grid-template-columns: repeat(3, 1fr);
    max-width: 900px;
    margin: 0 auto;
    padding: 0 16px;
  }
  .home-steps {
    max-width: 900px;
    margin: 0 auto;
  }
  .home-trust {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 16px;
    grid-template-columns: repeat(4, 1fr);
  }
  .home-stats {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    margin-top: 16px;
  }
  .home-search {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    margin-top: 16px;
  }
}

/* ============ 桌面端顶部导航 ============ */
.desktop-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px 32px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(233, 118, 123, 0.12);
  box-shadow: 0 2px 8px rgba(233, 118, 123, 0.04);
}
.desktop-nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Noto Serif SC', serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: none;
  letter-spacing: 0.5px;
}
.desktop-nav-logo {
  display: block;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  flex: none;
}
.desktop-nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
}
.desktop-nav-link {
  color: var(--color-text);
  text-decoration: none;
  font-size: 15px;
  padding: 6px 12px;
  border-radius: 8px;
  transition: background 0.15s, color 0.15s;
}
.desktop-nav-link:hover {
  background: rgba(233, 118, 123, 0.08);
  color: var(--color-primary);
}
.desktop-nav-cta {
  background: var(--color-cta);
  color: #fff;
  padding: 8px 18px;
}
.desktop-nav-cta:hover {
  background: var(--color-cta-dark);
  color: #fff;
}
.desktop-nav-user {
  font-size: 14px;
  color: var(--color-text-muted);
  padding: 6px 10px;
  background: rgba(233, 118, 123, 0.06);
  border-radius: 999px;
}
.desktop-nav-logout {
  border: 1px solid var(--color-border);
  background: transparent;
  color: var(--color-text-muted);
  font-size: 13px;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
}
.desktop-nav-logout:hover {
  border-color: var(--color-cta);
  color: var(--color-cta);
}
@media (max-width: 900px) {
  .desktop-nav { padding: 10px 16px; gap: 12px; }
  .desktop-nav-links { gap: 12px; }
  .desktop-nav-link { padding: 4px 8px; font-size: 14px; }
}
/* 桌面端容器限制宽度 */
@media (min-width: 769px) {
  .container { max-width: 900px; }
  .desktop-body-pad { padding-top: 8px; }
}

/* ============ 担保卡片 ============ */
.sponsor-section { margin-bottom: 16px; }
.sponsor-card {
  display: flex;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius-card);
  background: #FFF7EE;
  border: 1px solid rgba(233, 118, 123, 0.12);
  margin-bottom: 12px;
  align-items: flex-start;
}
.sponsor-card.accepted {
  background: linear-gradient(135deg, #EEF5E8 0%, #F5F9EE 100%);
  border-color: rgba(79, 181, 139, 0.3);
}
.sponsor-card.pending {
  background: #FBF5EE;
  border-style: dashed;
}
.sponsor-card-icon {
  font-size: 28px;
  line-height: 1;
  flex-shrink: 0;
}
.sponsor-card-body {
  flex: 1;
  min-width: 0;
}
.sponsor-card-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 4px;
}
.sponsor-card-sub {
  font-size: 13px;
  color: var(--color-text-muted);
  line-height: 1.6;
  margin-bottom: 10px;
}
.sponsor-subtitle {
  font-size: 13px;
  color: var(--color-text-muted);
  margin: 12px 0 8px 4px;
  font-weight: 500;
}
.sponsor-invite-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.sponsor-invite-row input {
  flex: 1;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  font-size: 14px;
  background: #fff;
  color: var(--color-text);
}
.sponsor-invite-row input:focus {
  outline: none;
  border-color: var(--color-cta);
}
.sponsor-list { display: flex; flex-direction: column; gap: 8px; }
.sponsor-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: 12px;
}
.sponsor-item-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 0;
}
.sponsor-item-nick {
  font-size: 15px;
  font-weight: 500;
  color: var(--color-text);
}
.sponsor-item-meta,
.sponsor-item-time {
  font-size: 12px;
  color: var(--color-text-muted);
}
.sponsor-loading,
.sponsor-error {
  padding: 16px;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 13px;
}

/* ============ 黑名单 & 举报 ============ */
.blacklist-section { margin-bottom: 16px; }
.blacklist-card {
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-card);
  padding: 16px;
}
.blacklist-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--color-border);
}
.blacklist-card-header h3 {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
  color: var(--color-text);
}
.blacklist-subtitle {
  font-size: 13px;
  color: var(--color-text-muted);
  margin: 14px 0 8px;
  font-weight: 500;
}
.blacklist-empty {
  padding: 20px;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 13px;
  background: #FBF5EE;
  border-radius: 10px;
}
.blacklist-list { display: flex; flex-direction: column; gap: 8px; }
.blacklist-item {
  padding: 12px 14px;
  background: #FBF5EE;
  border-radius: 10px;
  border-left: 3px solid var(--color-cta);
}
.blacklist-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}
.blacklist-item-cat {
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text);
}
.blacklist-item-detail {
  font-size: 13px;
  color: var(--color-text);
  line-height: 1.5;
  margin-bottom: 6px;
  word-break: break-word;
}
.blacklist-item-foot {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--color-text-muted);
  gap: 8px;
}
.badge-bl-pending {
  background: rgba(255, 122, 89, 0.12);
  color: #C25E3E;
}
.badge-bl-confirmed {
  background: rgba(201, 76, 76, 0.14);
  color: #C94C4C;
}
.badge-bl-dismissed {
  background: rgba(79, 181, 139, 0.16);
  color: #3B9E74;
}

/* 举报弹窗 */
.report-modal { padding: 4px; }
.report-reasons {
  flex-wrap: wrap;
  gap: 8px;
}
.reason-chip {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border: 1px solid var(--color-border);
  border-radius: 999px;
  background: #fff;
  color: var(--color-text);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
}
.reason-chip:hover {
  border-color: var(--color-cta);
  color: var(--color-cta);
}
.reason-chip.active {
  background: var(--color-cta);
  border-color: var(--color-cta);
  color: #fff;
}
/* ============ Task 18 · 需求广场 + 邀请接单 ============ */

/* 需求广场顶部说明卡 */
.needs-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding: 14px 16px;
  background: linear-gradient(135deg, rgba(232, 168, 56, 0.08), rgba(232, 168, 56, 0.02));
  border: 1px solid rgba(232, 168, 56, 0.25);
}
.needs-banner-icon {
  font-size: 28px;
  flex-shrink: 0;
}
.needs-banner-body {
  flex: 1;
  min-width: 0;
}
.needs-banner-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--color-primary);
}
.needs-banner-desc {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 2px;
}

/* 需求广场卡片容器 */
#needs-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 12px;
}

/* 结果计数 */
.needs-result-count {
  font-size: 13px;
  color: var(--color-text-muted);
  margin: 12px 4px;
}

/* 需求卡片（广场版） */
.need-square-card {
  transition: all 0.25s ease;
}
.need-square-card.need-card-highlight {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(233, 118, 123, 0.25), 0 6px 20px rgba(233, 118, 123, 0.15);
  animation: needHighlightPulse 1.5s ease-out 2;
}
@keyframes needHighlightPulse {
  0%   { box-shadow: 0 0 0 2px rgba(233, 118, 123, 0.4), 0 0 0 0 rgba(233, 118, 123, 0.3); }
  70%  { box-shadow: 0 0 0 2px rgba(233, 118, 123, 0.25), 0 0 0 12px rgba(233, 118, 123, 0); }
  100% { box-shadow: 0 0 0 2px rgba(233, 118, 123, 0.25), 0 0 0 0 rgba(233, 118, 123, 0); }
}
.need-square-card.need-card-done {
  opacity: 0.7;
  background: var(--color-bg-cream);
}

/* 头像包裹 */
.need-pet-avatar-wrap {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  position: relative;
}

/* 描述预览 */
.need-desc-preview {
  font-size: 13px;
  color: var(--color-text-secondary);
  line-height: 1.5;
  padding: 8px 10px;
  background: var(--color-bg-page-top);
  border-radius: 8px;
  margin-top: 6px;
  border-left: 3px solid var(--color-primary);
}

/* 发布时间提示 */
.need-time-hint {
  font-size: 11px;
  color: var(--color-text-muted);
  padding-top: 4px;
  border-top: 1px dashed var(--color-border);
}

/* 我的需求标签 */
.need-own-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  font-size: 12px;
  color: var(--color-text-muted);
  background: var(--color-bg-cream);
  border-radius: 999px;
  border: 1px solid var(--color-border);
  width: 100%;
  justify-content: center;
}

/* 已接单标签 */
.need-done-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  font-size: 14px;
  color: #4F7040;
  background: rgba(79, 181, 139, 0.15);
  border: 1px solid rgba(79, 181, 139, 0.35);
  border-radius: 999px;
  font-weight: 600;
  width: 100%;
  justify-content: center;
}

/* 弹窗底部按钮区 */
.modal-footer {
  display: flex;
  gap: 8px;
  padding: 12px 20px 16px;
  border-top: 1px solid var(--color-border);
  background: var(--color-bg-page-top);
}
.modal-footer .btn {
  flex: 1;
}

/* 接单确认文案 */
.needs-confirm-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--color-text);
  margin: 0 0 12px 0;
  padding: 12px 14px;
  background: var(--color-bg-cream);
  border-radius: 10px;
  border: 1px solid var(--color-border);
}
.needs-confirm-warn {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 12px;
  color: var(--color-text-secondary);
  padding: 10px 12px;
  background: rgba(232, 168, 56, 0.08);
  border-radius: 8px;
  border: 1px solid rgba(232, 168, 56, 0.25);
  line-height: 1.6;
}
.needs-confirm-warn > span {
  font-size: 16px;
  flex-shrink: 0;
}

/* ============ hosts.html 顶部 segment ============ */
.hosts-top-segment {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  background: var(--color-bg-cream);
  padding: 4px;
  border-radius: var(--radius-button);
  border: 1px solid var(--color-border);
}
.seg-btn-large {
  flex: 1;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 12px;
  border-radius: 9px;
  font-size: 15px;
  font-weight: 500;
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: all 0.2s ease;
  background: transparent;
}
.seg-btn-large-active {
  background: var(--color-card);
  color: var(--color-primary);
  box-shadow: 0 2px 8px rgba(233, 118, 123, 0.15);
  font-weight: 600;
}
.seg-btn-large:hover:not(.seg-btn-large-active) {
  color: var(--color-primary);
  background: rgba(233, 118, 123, 0.05);
}

/* ============ index.html 寄养人接单入口卡 ============ */
.home-entry-card {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 20px auto;
  max-width: 640px;
  padding: 16px;
  background: linear-gradient(135deg, rgba(233, 118, 123, 0.06), rgba(232, 168, 56, 0.04));
  border: 1px solid rgba(233, 118, 123, 0.2);
}
.home-entry-icon {
  font-size: 30px;
  flex-shrink: 0;
}
.home-entry-body {
  flex: 1;
  min-width: 0;
}
.home-entry-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--color-primary);
}
.home-entry-desc {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 2px;
  line-height: 1.5;
}
.home-entry-btn {
  flex-shrink: 0;
  padding: 8px 14px;
  height: auto;
  font-size: 13px;
}

/* ============ host-detail 邀请需求选择器 ============ */
.invite-need-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.invite-need-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: var(--color-bg-cream);
  border-radius: 10px;
  border: 1px solid var(--color-border);
  cursor: pointer;
  transition: all 0.15s ease;
}
.invite-need-item:hover {
  border-color: var(--color-primary);
  background: rgba(233, 118, 123, 0.04);
  transform: translateX(2px);
}
.invite-need-icon {
  font-size: 26px;
  flex-shrink: 0;
}
.invite-need-body {
  flex: 1;
  min-width: 0;
}
.invite-need-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text);
}
.invite-need-dates {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-top: 2px;
}
.invite-need-arrow {
  font-size: 20px;
  color: var(--color-text-muted);
  flex-shrink: 0;
}
