/* ============================================================
   身心信号 · 躯体化自评 — 样式
   治愈系 · 移动优先 · 柔和绿调
   ============================================================ */

:root {
  --c-primary: #6B9080;
  --c-primary-light: #A4C3B2;
  --c-primary-dark: #4A6B5E;
  --c-bg: #F4F8F6;
  --c-bg-warm: #F9F6F0;
  --c-card: #FFFFFF;
  --c-text: #2D3E36;
  --c-text-light: #6B7B73;
  --c-text-muted: #9BAAA3;
  --c-accent: #E07A5F;
  --c-warning: #E9B44C;
  --c-border: #E8EDE9;
  --c-shadow: 0 2px 12px rgba(45, 62, 54, 0.06);
  --c-shadow-md: 0 4px 20px rgba(45, 62, 54, 0.08);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 24px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Noto Sans SC",
               "Helvetica Neue", "Microsoft YaHei", sans-serif;
  background: var(--c-bg);
  color: var(--c-text);
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

#app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
}

/* ============================================================
   View 切换
   ============================================================ */
.view {
  display: none;
  min-height: 100vh;
  padding: 0 20px 40px;
  animation: fadeIn 0.4s ease;
}

.view.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ============================================================
   按钮
   ============================================================ */
.btn {
  border: none;
  border-radius: var(--radius);
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  font-family: inherit;
  line-height: 1.4;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--c-primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(107, 144, 128, 0.25);
}

.btn-primary:hover {
  background: var(--c-primary-dark);
}

.btn-primary:disabled {
  background: var(--c-border);
  color: var(--c-text-muted);
  cursor: not-allowed;
  box-shadow: none;
}

.btn-secondary {
  background: var(--c-bg-warm);
  color: var(--c-text);
  border: 1px solid var(--c-border);
}

.btn-text {
  background: transparent;
  color: var(--c-primary);
  padding: 10px 20px;
  font-weight: 500;
}

.btn-large {
  width: 100%;
  padding: 16px 28px;
  font-size: 17px;
  border-radius: var(--radius-lg);
}

/* ============================================================
   首页
   ============================================================ */
.hero {
  text-align: center;
  padding: 60px 20px 40px;
}

.hero-icon {
  font-size: 56px;
  margin-bottom: 16px;
  animation: gentleFloat 3s ease-in-out infinite;
}

@keyframes gentleFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--c-text);
  letter-spacing: 2px;
  margin-bottom: 8px;
}

.hero-subtitle {
  font-size: 15px;
  color: var(--c-primary);
  letter-spacing: 4px;
  margin-bottom: 24px;
  font-weight: 500;
}

.hero-desc {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
  margin-bottom: 32px;
}

.hero .btn-primary {
  margin-bottom: 12px;
}

.home-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
}

.feature-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  box-shadow: var(--c-shadow);
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--c-shadow-md);
}

.feature-icon {
  font-size: 28px;
  flex-shrink: 0;
}

.feature-card h3 {
  font-size: 16px;
  margin-bottom: 4px;
  color: var(--c-text);
}

.feature-card p {
  font-size: 13px;
  color: var(--c-text-light);
  line-height: 1.5;
}

.disclaimer-mini {
  margin-top: 32px;
  padding: 14px 16px;
  font-size: 12px;
  color: var(--c-text-muted);
  text-align: center;
  line-height: 1.6;
  background: rgba(228, 226, 221, 0.3);
  border-radius: var(--radius-sm);
}

/* ============================================================
   通用页面头部
   ============================================================ */
.page-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 0;
  position: sticky;
  top: 0;
  background: var(--c-bg);
  z-index: 10;
}

.page-header h2 {
  font-size: 22px;
  font-weight: 700;
}

.back-btn {
  background: var(--c-card);
  border: 1px solid var(--c-border);
  border-radius: 24px;
  padding: 8px 16px;
  font-size: 14px;
  color: var(--c-text);
  cursor: pointer;
  font-family: inherit;
  transition: var(--transition);
}

.back-btn:active {
  transform: scale(0.95);
}

/* ============================================================
   科普页
   ============================================================ */
.edu-section {
  margin-bottom: 16px;
}

.edu-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--c-shadow);
}

.edu-card h3 {
  font-size: 18px;
  margin-bottom: 16px;
  color: var(--c-text);
}

.edu-card p {
  font-size: 14px;
  color: var(--c-text-light);
  margin-bottom: 12px;
  line-height: 1.8;
}

.edu-card p:last-child {
  margin-bottom: 0;
}

.edu-card-highlight {
  background: linear-gradient(135deg, #F0F7F3, #F9F6F0);
  border: 1px solid var(--c-primary-light);
}

.edu-intro {
  font-size: 14px;
  color: var(--c-text-light);
  margin-bottom: 16px;
}

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

.symptom-item {
  background: var(--c-bg);
  border-radius: var(--radius-sm);
  padding: 12px;
  font-size: 13px;
  color: var(--c-text);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.symptom-item:hover {
  background: var(--c-primary-light);
  color: #fff;
}

.symptom-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-primary);
  flex-shrink: 0;
}

.reason-item {
  margin-bottom: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--c-border);
}

.reason-item:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.reason-item h4 {
  font-size: 15px;
  color: var(--c-primary);
  margin-bottom: 6px;
  font-weight: 600;
}

.reason-item p {
  font-size: 14px;
  color: var(--c-text-light);
  margin: 0;
}

.edu-cta {
  margin-top: 24px;
}

/* ============================================================
   自测页
   ============================================================ */
.quiz-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0 12px;
}

.quiz-progress-info {
  font-size: 15px;
  color: var(--c-text-light);
  font-weight: 500;
}

#quiz-current {
  color: var(--c-primary);
  font-weight: 700;
  font-size: 18px;
}

.progress-bar {
  width: 100%;
  height: 6px;
  background: var(--c-border);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 8px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--c-primary), var(--c-primary-light));
  border-radius: 3px;
  transition: width 0.4s ease;
  width: 0%;
}

.quiz-part-label {
  font-size: 13px;
  color: var(--c-primary);
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: 1px;
}

.quiz-content {
  min-height: 300px;
}

.quiz-question {
  animation: slideIn 0.4s ease;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

.quiz-question-text {
  font-size: 19px;
  font-weight: 600;
  line-height: 1.6;
  margin-bottom: 28px;
  color: var(--c-text);
}

.quiz-question-sub {
  font-size: 14px;
  color: var(--c-text-muted);
  margin-bottom: 20px;
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.quiz-option {
  background: var(--c-card);
  border: 2px solid var(--c-border);
  border-radius: var(--radius);
  padding: 18px 20px;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 15px;
  font-family: inherit;
  color: var(--c-text);
  text-align: left;
  width: 100%;
}

.quiz-option:hover {
  border-color: var(--c-primary-light);
  background: var(--c-bg-warm);
}

.quiz-option.selected {
  border-color: var(--c-primary);
  background: rgba(107, 144, 128, 0.06);
  color: var(--c-primary-dark);
  font-weight: 600;
}

.quiz-option-radio {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--c-border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.quiz-option.selected .quiz-option-radio {
  border-color: var(--c-primary);
  background: var(--c-primary);
}

.quiz-option.selected .quiz-option-radio::after {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
}

.quiz-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 28px;
  padding-bottom: 20px;
}

.quiz-nav .btn {
  flex: 1;
}

/* ============================================================
   结果页
   ============================================================ */
.result-hero {
  text-align: center;
  padding: 20px 0 28px;
}

.result-emoji {
  font-size: 64px;
  margin-bottom: 12px;
  animation: gentleFloat 3s ease-in-out infinite;
}

.result-level-badge {
  display: inline-block;
  padding: 6px 20px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
}

.result-score {
  font-size: 48px;
  font-weight: 800;
  margin: 8px 0;
}

.result-score-max {
  font-size: 18px;
  color: var(--c-text-muted);
  font-weight: 400;
}

.result-summary {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 12px;
}

.result-description {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
  text-align: left;
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 20px;
  box-shadow: var(--c-shadow);
}

.result-breakdown {
  margin-top: 20px;
}

.result-breakdown-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 14px;
}

.breakdown-item {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 10px;
  box-shadow: var(--c-shadow);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.breakdown-item-left h4 {
  font-size: 14px;
  color: var(--c-text);
  margin-bottom: 4px;
}

.breakdown-item-left p {
  font-size: 12px;
  color: var(--c-text-muted);
}

.breakdown-item-right {
  text-align: right;
}

.breakdown-score {
  font-size: 18px;
  font-weight: 700;
}

.breakdown-label {
  font-size: 12px;
  color: var(--c-text-muted);
}

.result-actions {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* ============================================================
   缓解方案页
   ============================================================ */
.relief-intro {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 24px 20px;
  margin-bottom: 16px;
  box-shadow: var(--c-shadow);
  text-align: center;
}

.relief-intro h3 {
  font-size: 20px;
  margin-bottom: 8px;
  color: var(--c-text);
}

.relief-intro p {
  font-size: 14px;
  color: var(--c-text-light);
}

.relief-strategy {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 12px;
  box-shadow: var(--c-shadow);
  transition: var(--transition);
}

.relief-strategy-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.relief-strategy-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text);
}

.relief-strategy-tag {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 12px;
  background: rgba(107, 144, 128, 0.1);
  color: var(--c-primary);
  font-weight: 500;
}

.relief-strategy-detail {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.7;
}

.relief-cta {
  margin-top: 28px;
}

/* ============================================================
   资源页
   ============================================================ */
.res-section {
  margin-bottom: 28px;
}

.res-title {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 14px;
  color: var(--c-text);
}

.res-hotline-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 10px;
  box-shadow: var(--c-shadow);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.res-hotline-info h4 {
  font-size: 15px;
  color: var(--c-text);
  margin-bottom: 4px;
}

.res-hotline-info p {
  font-size: 12px;
  color: var(--c-text-muted);
}

.res-hotline-number {
  font-size: 16px;
  font-weight: 700;
  color: var(--c-accent);
  white-space: nowrap;
}

.res-prof-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 10px;
  box-shadow: var(--c-shadow);
}

.res-prof-card h4 {
  font-size: 15px;
  color: var(--c-primary);
  margin-bottom: 6px;
}

.res-prof-card .res-prof-where {
  font-size: 13px;
  color: var(--c-text-light);
  margin-bottom: 4px;
}

.res-prof-card .res-prof-can {
  font-size: 13px;
  color: var(--c-text);
  margin-bottom: 4px;
}

.res-prof-card .res-prof-note {
  font-size: 12px;
  color: var(--c-text-muted);
  background: var(--c-bg-warm);
  border-radius: 8px;
  padding: 6px 10px;
  display: inline-block;
}

.res-selfhelp-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 8px;
  box-shadow: var(--c-shadow);
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.res-selfhelp-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.res-selfhelp-info h4 {
  font-size: 14px;
  color: var(--c-text);
  margin-bottom: 2px;
}

.res-selfhelp-info p {
  font-size: 13px;
  color: var(--c-text-light);
}

.res-signals {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--c-shadow);
}

.res-signal-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--c-border);
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.6;
}

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

.res-signal-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--c-accent);
  margin-top: 8px;
  flex-shrink: 0;
}

.res-disclaimer {
  background: rgba(224, 122, 95, 0.06);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 20px;
  text-align: center;
}

.res-disclaimer p {
  font-size: 13px;
  color: var(--c-text-light);
  margin-bottom: 6px;
}

.res-disclaimer p:last-child {
  margin-bottom: 0;
}

.res-footer {
  padding-bottom: 20px;
}

/* ============================================================
   响应式 — 桌面端优化
   ============================================================ */
@media (min-width: 481px) {
  body {
    background: linear-gradient(180deg, var(--c-bg) 0%, #E8F0EA 100%);
  }

  #app {
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.04);
    background: var(--c-bg);
  }

  .symptom-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================================
   工具类
   ============================================================ */
.hidden {
  display: none !important;
}

/* ============================================================
   退出确认弹窗
   ============================================================ */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(45, 62, 54, 0.4);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.modal-box {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  max-width: 320px;
  width: 90%;
  text-align: center;
  animation: modalIn 0.3s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

.modal-box h3 {
  font-size: 18px;
  margin-bottom: 10px;
}

.modal-box p {
  font-size: 14px;
  color: var(--c-text-light);
  margin-bottom: 20px;
  line-height: 1.6;
}

.modal-actions {
  display: flex;
  gap: 12px;
}

.modal-actions .btn {
  flex: 1;
  padding: 12px 20px;
  font-size: 14px;
}

/* ============================================================
   工具箱 Hub
   ============================================================ */
.tools-intro {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: var(--c-shadow);
  text-align: center;
}

.tools-intro p {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
}

.tools-intro b {
  color: var(--c-primary);
}

.tools-category {
  margin-bottom: 24px;
}

.tools-category-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--c-text-light);
  margin-bottom: 12px;
  padding-left: 4px;
}

.tool-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 10px;
  box-shadow: var(--c-shadow);
  transition: var(--transition);
  cursor: pointer;
}

.tool-card:active {
  transform: scale(0.98);
}

.tool-card-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 10px;
}

.tool-card-emoji {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.tool-card-info {
  flex: 1;
}

.tool-card-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 2px;
}

.tool-card-tag {
  font-size: 12px;
  font-weight: 500;
}

.tool-card-desc {
  font-size: 13px;
  color: var(--c-text-light);
  line-height: 1.6;
  margin: 0;
}

.tools-note {
  text-align: center;
  padding: 16px;
  margin-top: 8px;
}

.tools-note span {
  font-size: 12px;
  color: var(--c-text-muted);
  background: var(--c-bg-warm);
  padding: 8px 16px;
  border-radius: 20px;
}

/* ============================================================
   工具通用
   ============================================================ */
.tool-section {
  padding-bottom: 40px;
}

.tool-intro-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 24px 20px;
  margin-bottom: 20px;
  box-shadow: var(--c-shadow);
}

.tool-intro-card h3 {
  font-size: 18px;
  margin-bottom: 10px;
  color: var(--c-text);
}

.tool-intro-card p {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
  margin: 0;
}

.tool-tips {
  margin-top: 20px;
}

.tip-card {
  background: var(--c-bg-warm);
  border-radius: var(--radius);
  padding: 20px;
}

.tip-card strong {
  display: block;
  font-size: 14px;
  color: var(--c-text);
  margin-bottom: 10px;
}

.tip-card ul {
  list-style: none;
  padding: 0;
}

.tip-card li {
  font-size: 13px;
  color: var(--c-text-light);
  padding: 4px 0;
  padding-left: 16px;
  position: relative;
  line-height: 1.6;
}

.tip-card li::before {
  content: '•';
  color: var(--c-primary);
  position: absolute;
  left: 4px;
}

.btn-stop {
  background: var(--c-accent) !important;
  box-shadow: 0 4px 14px rgba(224, 122, 95, 0.25) !important;
}

.btn-danger-text {
  color: var(--c-accent) !important;
}

/* ============================================================
   工具1: 呼吸引导器
   ============================================================ */
.breathing-stage {
  text-align: center;
  padding: 20px 0;
}

.breath-circle-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 280px;
  margin-bottom: 20px;
}

.breath-circle {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--c-primary-light) 0%, var(--c-primary) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 4s cubic-bezier(0.4, 0, 0.6, 1), background 2s ease;
  transform: scale(0.6);
  box-shadow: 0 0 40px rgba(107, 144, 128, 0.3);
}

.breath-circle.breath-inhale {
  transform: scale(1.0);
  transition: transform 4s ease-in;
  background: radial-gradient(circle, #A4C3B2 0%, #6B9080 100%);
}

.breath-circle.breath-hold {
  transform: scale(1.0);
  background: radial-gradient(circle, #88B8A0 0%, #4A6B5E 100%);
}

.breath-circle.breath-exhale {
  transform: scale(0.6);
  transition: transform 8s ease-out;
  background: radial-gradient(circle, #C3D9CC 0%, #88B8A0 100%);
}

.breath-circle.breath-done {
  transform: scale(0.8);
  background: radial-gradient(circle, #D4EDDA 0%, #88B8A0 100%);
}

.breath-circle-inner {
  text-align: center;
  color: #fff;
}

.breath-text {
  display: block;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 2px;
}

.breath-count {
  display: block;
  font-size: 28px;
  font-weight: 700;
  margin-top: 4px;
}

.breath-round-info {
  font-size: 14px;
  color: var(--c-text-light);
  margin-bottom: 20px;
}

.breath-round-info span {
  font-weight: 700;
  color: var(--c-primary);
  font-size: 18px;
}

.breath-complete-msg {
  margin-top: 20px;
  padding: 16px 20px;
  background: linear-gradient(135deg, #F0F7F3, #E8F5E9);
  border-radius: var(--radius);
  font-size: 14px;
  color: var(--c-text);
  font-weight: 500;
  animation: fadeIn 0.5s ease;
}

.breath-complete-msg span {
  display: block;
  font-size: 13px;
  font-weight: 400;
  color: var(--c-text-light);
  margin-top: 4px;
}

/* ============================================================
   工具2: 5-4-3-2-1 着陆法
   ============================================================ */
.grounding-step-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--c-shadow);
  border: 2px solid transparent;
}

.grounding-step-header {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 20px;
}

.grounding-step-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.grounding-step-sense {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
}

.grounding-step-prompt {
  font-size: 15px;
  color: var(--c-text);
  line-height: 1.6;
}

.grounding-inputs {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.grounding-input {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
  transition: var(--transition);
}

.grounding-input:focus {
  outline: none;
  border-color: var(--c-primary);
  background: #fff;
}

.grounding-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.grounding-nav .btn {
  flex: 1;
}

.grounding-progress {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}

.grounding-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-border);
  transition: var(--transition);
}

.grounding-dot.active {
  width: 24px;
  border-radius: 4px;
}

.grounding-complete {
  text-align: center;
  padding: 30px 20px;
  animation: fadeIn 0.5s ease;
}

.grounding-complete-emoji {
  font-size: 56px;
  margin-bottom: 16px;
  animation: gentleFloat 3s ease-in-out infinite;
}

.grounding-complete h3 {
  font-size: 22px;
  color: var(--c-text);
  margin-bottom: 12px;
}

.grounding-complete p {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
  margin-bottom: 20px;
}

.grounding-complete-stats {
  margin-bottom: 24px;
}

.stat-item {
  display: inline-block;
  text-align: center;
  padding: 16px 24px;
  background: var(--c-bg-warm);
  border-radius: var(--radius);
}

.stat-num {
  font-size: 32px;
  font-weight: 800;
  color: var(--c-primary);
}

.stat-label {
  font-size: 12px;
  color: var(--c-text-muted);
}

/* ============================================================
   工具3: 想法记录表
   ============================================================ */
.tr-form {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--c-shadow);
}

.tr-field {
  margin-bottom: 18px;
}

.tr-field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 8px;
}

.tr-field textarea,
.tr-field input[type="date"],
.tr-field input[type="text"] {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
  line-height: 1.6;
  resize: vertical;
}

.tr-field textarea:focus,
.tr-field input:focus {
  outline: none;
  border-color: var(--c-primary);
  background: #fff;
}

.tr-emotion-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.tr-emotion-row input[type="text"] {
  flex: 1;
}

.tr-slider-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 140px;
}

.tr-slider-wrap input[type="range"] {
  flex: 1;
  height: 6px;
  -webkit-appearance: none;
  appearance: none;
  background: var(--c-border);
  border-radius: 3px;
  outline: none;
}

.tr-slider-wrap input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--c-primary);
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(107, 144, 128, 0.3);
}

.tr-intensity-val {
  font-size: 18px;
  font-weight: 700;
  color: var(--c-primary);
  min-width: 24px;
  text-align: center;
}

.tr-history {
  margin-top: 24px;
}

.tr-history-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 14px;
  color: var(--c-text);
}

.tr-record-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 10px;
  box-shadow: var(--c-shadow);
  border-left: 3px solid var(--c-primary-light);
}

.tr-record-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}

.tr-record-date {
  font-size: 13px;
  color: var(--c-text-muted);
}

.tr-record-emotion {
  font-size: 12px;
  font-weight: 600;
  color: var(--c-primary);
  background: rgba(107, 144, 128, 0.08);
  padding: 2px 10px;
  border-radius: 10px;
}

.tr-record-row {
  font-size: 13px;
  color: var(--c-text-light);
  line-height: 1.6;
  margin-bottom: 4px;
}

.tr-record-change {
  font-size: 12px;
  font-weight: 600;
  color: var(--c-primary);
  margin-top: 8px;
  padding: 6px 10px;
  background: rgba(107, 144, 128, 0.06);
  border-radius: 8px;
  display: inline-block;
}

/* ============================================================
   工具4: 情绪锚定法
   ============================================================ */
.anchor-step-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--c-shadow);
}

.anchor-step-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}

.anchor-step-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #FFF7ED;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.anchor-step-num {
  font-size: 12px;
  color: var(--c-text-muted);
  margin-bottom: 2px;
}

.anchor-step-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--c-text);
}

.anchor-step-desc {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
  margin-bottom: 20px;
}

.anchor-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.anchor-choice-btn {
  padding: 12px 20px;
  border: 2px solid var(--c-border);
  border-radius: 24px;
  background: var(--c-bg);
  font-size: 14px;
  color: var(--c-text);
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
}

.anchor-choice-btn.selected {
  border-color: #D97706;
  background: #FFF7ED;
  color: #D97706;
  font-weight: 600;
}

.anchor-textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
  line-height: 1.7;
  resize: vertical;
  margin-bottom: 20px;
}

.anchor-textarea:focus {
  outline: none;
  border-color: #D97706;
  background: #fff;
}

.anchor-guide-timer {
  text-align: center;
  padding: 20px 0;
  margin-bottom: 20px;
}

.anchor-timer-circle {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 4px solid var(--c-border);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  transition: var(--transition);
}

.anchor-timer-circle.anchor-timer-active {
  border-color: #D97706;
  background: #FFF7ED;
}

.anchor-timer-num {
  font-size: 32px;
  font-weight: 700;
  color: var(--c-text);
}

.anchor-guide-timer p {
  font-size: 14px;
  color: var(--c-text-light);
}

.anchor-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.anchor-nav .btn {
  flex: 1;
}

.anchor-complete {
  text-align: center;
  padding: 20px 0;
  animation: fadeIn 0.5s ease;
}

.anchor-complete-emoji {
  font-size: 56px;
  margin-bottom: 12px;
  animation: gentleFloat 3s ease-in-out infinite;
}

.anchor-complete h3 {
  font-size: 22px;
  color: var(--c-text);
  margin-bottom: 12px;
}

.anchor-complete p {
  font-size: 14px;
  color: var(--c-text-light);
  line-height: 1.8;
  margin-bottom: 16px;
}

.anchor-use-cases {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.anchor-use-cases li {
  font-size: 14px;
  color: var(--c-text-light);
  padding: 8px 14px;
  background: var(--c-bg);
  border-radius: 10px;
  text-align: left;
}

.anchor-tip {
  background: #FFF7ED;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 13px;
  color: var(--c-text-light);
  line-height: 1.6;
  text-align: left;
  margin-bottom: 12px;
}

.anchor-tip strong {
  color: #D97706;
}

.anchor-stat {
  font-size: 13px;
  color: var(--c-text-muted);
  padding: 8px 14px;
  background: var(--c-bg-warm);
  border-radius: 20px;
  display: inline-block;
}

/* ============================================================
   工具5: 症状追踪日志
   ============================================================ */
.st-form {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--c-shadow);
}

.st-field {
  margin-bottom: 18px;
}

.st-field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 8px;
}

.st-datetime {
  display: flex;
  gap: 10px;
}

.st-datetime input {
  flex: 1;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
}

.st-datetime input:focus {
  outline: none;
  border-color: var(--c-primary);
  background: #fff;
}

.st-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  padding: 8px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: 20px;
  background: var(--c-bg);
  font-size: 13px;
  color: var(--c-text-light);
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
}

.chip.selected {
  border-color: var(--c-primary);
  background: rgba(107, 144, 128, 0.1);
  color: var(--c-primary-dark);
  font-weight: 600;
}

.st-other-input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
  margin-top: 8px;
}

.st-other-input:focus {
  outline: none;
  border-color: var(--c-primary);
  background: #fff;
}

.st-intensity {
  display: flex;
  gap: 8px;
}

.st-intensity-btn {
  flex: 1;
  padding: 14px 0;
  border: 2px solid var(--c-border);
  border-radius: var(--radius-sm);
  background: var(--c-bg);
  font-size: 18px;
  font-weight: 700;
  color: var(--c-text-light);
  font-family: inherit;
  cursor: pointer;
  transition: var(--transition);
}

.st-intensity-btn.selected {
  border-color: var(--c-accent);
  background: rgba(224, 122, 95, 0.1);
  color: var(--c-accent);
}

.st-intensity-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 11px;
  color: var(--c-text-muted);
}

.st-field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
  resize: vertical;
  line-height: 1.6;
}

.st-field textarea:focus {
  outline: none;
  border-color: var(--c-primary);
  background: #fff;
}

.st-insights {
  margin-top: 20px;
}

.st-insight-card {
  background: linear-gradient(135deg, #F0F7F3, #FFF7ED);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--c-shadow);
}

.st-insight-card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--c-text);
}

.st-insight-note {
  font-size: 12px;
  color: var(--c-text-muted);
  margin-bottom: 14px;
}

.st-insight-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  font-size: 13px;
  color: var(--c-text);
  line-height: 1.6;
  border-bottom: 1px solid rgba(0,0,0,0.04);
}

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

.st-insight-icon {
  flex-shrink: 0;
  font-size: 16px;
}

.st-history {
  margin-top: 24px;
}

.st-history-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 14px;
  color: var(--c-text);
}

.st-log-card {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 10px;
  box-shadow: var(--c-shadow);
}

.st-log-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.st-log-date {
  font-size: 13px;
  color: var(--c-text-muted);
}

.st-log-intensity {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 12px;
}

.st-log-symptoms {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.st-tag {
  font-size: 12px;
  padding: 4px 10px;
  background: rgba(107, 144, 128, 0.08);
  color: var(--c-primary-dark);
  border-radius: 10px;
  font-weight: 500;
}

.st-log-row {
  font-size: 13px;
  color: var(--c-text-light);
  line-height: 1.6;
  margin-bottom: 2px;
}

.st-empty {
  text-align: center;
  padding: 30px;
  font-size: 14px;
  color: var(--c-text-muted);
}

/* ============================================================
   工具6: 情绪温度计
   ============================================================ */
.mood-checkin {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 28px 20px;
  box-shadow: var(--c-shadow);
  text-align: center;
}

.mood-checkin h3 {
  font-size: 18px;
  color: var(--c-text);
  margin-bottom: 24px;
}

.mood-slider-wrap {
  margin-bottom: 16px;
}

.mood-slider-wrap input[type="range"] {
  width: 100%;
  height: 8px;
  -webkit-appearance: none;
  appearance: none;
  background: linear-gradient(90deg, #FECACA 0%, #FEF3C7 35%, #D1FAE5 65%, #A7F3D0 100%);
  border-radius: 4px;
  outline: none;
}

.mood-slider-wrap input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--c-primary);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.mood-display {
  margin: 16px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.mood-emoji {
  font-size: 40px;
}

.mood-num {
  font-size: 32px;
  font-weight: 800;
  color: var(--c-primary);
}

.mood-label {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text-light);
}

.mood-scale-labels {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--c-text-muted);
  margin-bottom: 24px;
}

.mood-note-field {
  text-align: left;
  margin-bottom: 20px;
}

.mood-note-field label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 8px;
}

.mood-note-field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  background: var(--c-bg);
  color: var(--c-text);
  resize: vertical;
  line-height: 1.6;
}

.mood-note-field textarea:focus {
  outline: none;
  border-color: var(--c-primary);
  background: #fff;
}

.mood-today-done {
  background: linear-gradient(135deg, #F0F7F3, #E8F5E9);
  border-radius: var(--radius);
  padding: 28px 20px;
  box-shadow: var(--c-shadow);
  text-align: center;
}

.mood-done-emoji {
  font-size: 48px;
  margin-bottom: 12px;
}

.mood-today-done p {
  font-size: 15px;
  color: var(--c-text);
  font-weight: 500;
  margin-bottom: 8px;
}

.mood-done-note {
  font-size: 14px;
  color: var(--c-text-light);
  font-style: italic;
  margin-bottom: 16px !important;
}

.mood-stats {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}

.mood-stat-card {
  flex: 1;
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 16px 12px;
  text-align: center;
  box-shadow: var(--c-shadow);
}

.mood-stat-num {
  font-size: 24px;
  font-weight: 800;
  color: var(--c-primary);
}

.mood-stat-label {
  font-size: 11px;
  color: var(--c-text-muted);
  margin-top: 4px;
}

.mood-chart {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 16px;
  box-shadow: var(--c-shadow);
}

.mood-chart h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 14px;
  color: var(--c-text);
}

.mood-heatmap {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 4px;
  margin-bottom: 12px;
}

.mood-cell {
  aspect-ratio: 1;
  border-radius: 4px;
  background: var(--c-bg-warm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  color: var(--c-text-muted);
  transition: var(--transition);
  position: relative;
}

.mood-cell.today {
  border: 2px solid var(--c-primary);
  font-weight: 700;
}

.mood-cell:not(.empty):hover {
  transform: scale(1.15);
  z-index: 1;
}

.mood-cell-day {
  font-size: 9px;
  opacity: 0.7;
}

.mood-legend {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
}

.mood-legend span {
  font-size: 11px;
  color: var(--c-text-muted);
}

.mood-legend-bar {
  width: 80px;
  height: 8px;
  border-radius: 4px;
  background: linear-gradient(90deg, #FECACA 0%, #FEF3C7 35%, #D1FAE5 65%, #A7F3D0 100%);
}

.mood-history {
  background: var(--c-card);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 16px;
  box-shadow: var(--c-shadow);
}

.mood-history h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 14px;
  color: var(--c-text);
}

.mood-record {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--c-border);
}

.mood-record:last-child {
  border-bottom: none;
}

.mood-record-date {
  font-size: 12px;
  color: var(--c-text-muted);
  min-width: 80px;
}

.mood-record-mood {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 70px;
}

.mood-record-emoji {
  font-size: 20px;
}

.mood-record-num {
  font-size: 14px;
  font-weight: 600;
  color: var(--c-text);
}

.mood-record-note {
  font-size: 13px;
  color: var(--c-text-light);
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ============================================================
   Toast 提示
   ============================================================ */
.tool-toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--c-text);
  color: #fff;
  padding: 12px 24px;
  border-radius: 24px;
  font-size: 14px;
  font-weight: 500;
  z-index: 200;
  opacity: 0;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  white-space: nowrap;
}

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