/* 基础变量与设计系统 */
:root {
  --font-sans: 'Outfit', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --bg-primary: #0a0f18;
  --bg-secondary: rgba(255, 255, 255, 0.04);
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-glass-bright: rgba(255, 255, 255, 0.18);
  
  /* 默认：静谧海蓝主题 */
  --water-gradient-top: #38bdf8;
  --water-gradient-mid: #0284c7;
  --water-gradient-bottom: #034574;
  --water-surface-light: #7dd3fc;
  --water-foam: rgba(255, 255, 255, 0.65);
  --glow-color: rgba(56, 189, 248, 0.22);
  --accent-color: #38bdf8;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --text-subtle: #64748b;
  --card-bg: rgba(15, 23, 42, 0.65);
}

/* 主题预置 */
body.theme-sunset {
  --water-gradient-top: #e879f9;
  --water-gradient-mid: #9333ea;
  --water-gradient-bottom: #581c87;
  --water-surface-light: #f5d0fe;
  --water-foam: rgba(254, 240, 138, 0.85);
  --glow-color: rgba(217, 70, 239, 0.28);
  --accent-color: #d946ef;
}

body.theme-ocean {
  --water-gradient-top: #38bdf8;
  --water-gradient-mid: #0284c7;
  --water-gradient-bottom: #034574;
  --water-surface-light: #7dd3fc;
  --water-foam: rgba(255, 255, 255, 0.65);
  --glow-color: rgba(56, 189, 248, 0.22);
  --accent-color: #38bdf8;
}

body.theme-bamboo {
  --water-gradient-top: #34d399;
  --water-gradient-mid: #059669;
  --water-gradient-bottom: #064e3b;
  --water-surface-light: #6ee7b7;
  --water-foam: rgba(236, 253, 245, 0.75);
  --glow-color: rgba(52, 211, 153, 0.22);
  --accent-color: #34d399;
}

body.theme-lavender {
  --water-gradient-top: #c084fc;
  --water-gradient-mid: #7e22ce;
  --water-gradient-bottom: #4c1d95;
  --water-surface-light: #e9d5ff;
  --water-foam: rgba(250, 245, 255, 0.75);
  --glow-color: rgba(192, 132, 252, 0.22);
  --accent-color: #c084fc;
}

body.theme-amber {
  --water-gradient-top: #fbbf24;
  --water-gradient-mid: #d97706;
  --water-gradient-bottom: #78350f;
  --water-surface-light: #fde68a;
  --water-foam: rgba(254, 243, 199, 0.75);
  --glow-color: rgba(251, 191, 36, 0.2);
  --accent-color: #fbbf24;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
  user-select: none;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  transition: background-color 0.8s ease;
}

/* 背景呼吸光晕 */
.ambient-glow {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 550px;
  height: 550px;
  background: radial-gradient(circle, var(--glow-color) 0%, rgba(0, 0, 0, 0) 70%);
  transform: translate(-50%, -50%) scale(1);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
  transition: transform 3s cubic-bezier(0.4, 0, 0.2, 1), background 1s ease;
}

.ambient-glow.breathing-in {
  transform: translate(-50%, -50%) scale(1.35);
  opacity: 0.9;
}

.ambient-glow.breathing-hold {
  transform: translate(-50%, -50%) scale(1.35);
  opacity: 0.95;
}

.ambient-glow.breathing-out {
  transform: translate(-50%, -50%) scale(0.9);
  opacity: 0.6;
}

/* 工作台双栏布局 (左侧训练区 + 右侧呼吸调律指南) */
.workspace-wrapper {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 32px;
  width: 100%;
  max-width: 1240px;
  min-height: 100vh;
  padding: 24px 20px;
  position: relative;
  z-index: 1;
}

/* 应用容器 */
.app-container {
  width: 100%;
  max-width: 660px;
  min-height: 820px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 20px 24px;
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--border-glass);
  border-radius: 24px;
  backdrop-filter: blur(16px);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

/* 顶栏 */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-color);
  backdrop-filter: blur(8px);
}

.title {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 2px;
}

.stats-bar {
  display: flex;
  gap: 8px;
}

.stat-pill {
  background: var(--card-bg);
  border: 1px solid var(--border-glass);
  backdrop-filter: blur(12px);
  border-radius: 10px;
  padding: 6px 12px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.stat-label {
  font-size: 0.65rem;
  color: var(--text-subtle);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.stat-val {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-main);
  font-variant-numeric: tabular-nums;
}

.stat-val small {
  font-size: 0.7rem;
  font-weight: 400;
  color: var(--text-muted);
}

/* 主展示区：气球与圆柱体双舞台 */
.main-stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  margin: 8px 0;
}

.duo-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 40px;
  position: relative;
  width: 100%;
}

/* 左侧：腹部气球组件 */
.balloon-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 180px;
}

.balloon-stage-inner {
  width: 180px;
  height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.balloon-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  transform-origin: center 70%;
  transition: transform 0.15s ease-out;
  will-change: transform;
}

.balloon-glow {
  position: absolute;
  top: 15%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 160px;
  height: 160px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.25) 0%, rgba(0, 0, 0, 0) 70%);
  filter: blur(25px);
  pointer-events: none;
  transition: background 0.8s ease;
}

body.phase-is-inhale .balloon-glow {
  background: radial-gradient(circle, rgba(217, 70, 239, 0.35) 0%, rgba(0, 0, 0, 0) 70%);
}

.balloon-body {
  width: 130px;
  height: 155px;
  border-radius: 50% 50% 50% 50% / 42% 42% 58% 58%;
  background: radial-gradient(circle at 35% 30%, #7dd3fc 0%, #0284c7 50%, #034574 100%);
  box-shadow: 
    0 16px 36px -8px rgba(0, 0, 0, 0.6),
    inset -4px -6px 14px rgba(0, 0, 0, 0.4),
    inset 4px 6px 16px rgba(255, 255, 255, 0.4);
  position: relative;
  transition: background 0.8s ease, box-shadow 0.8s ease;
}

body.phase-is-inhale .balloon-body {
  background: radial-gradient(circle at 35% 30%, #f5d0fe 0%, #d946ef 50%, #581c87 100%);
  box-shadow: 
    0 18px 40px -6px rgba(217, 70, 239, 0.45),
    inset -4px -6px 14px rgba(0, 0, 0, 0.4),
    inset 4px 6px 18px rgba(255, 255, 255, 0.6);
}

.balloon-highlight {
  position: absolute;
  top: 20px;
  left: 22px;
  width: 34px;
  height: 18px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.65);
  transform: rotate(-35deg);
  filter: blur(1.5px);
}

.balloon-inner-light {
  position: absolute;
  bottom: 22px;
  right: 20px;
  width: 28px;
  height: 14px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  transform: rotate(25deg);
  filter: blur(2px);
}

.balloon-knot {
  width: 14px;
  height: 8px;
  background: #0284c7;
  clip-path: polygon(25% 0%, 75% 0%, 100% 100%, 0% 100%);
  margin-top: -1px;
  transition: background 0.8s ease;
}

body.phase-is-inhale .balloon-knot {
  background: #c026d3;
}

.balloon-string {
  width: 1.5px;
  height: 48px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0.05) 100%);
  border-radius: 1px;
}

/* 舞台小标签指示 */
.stage-tag {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.tag-label {
  font-size: 0.65rem;
  color: var(--text-subtle);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.tag-status {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.4s ease;
}

.cylinder-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* 刻度辅助线 */
.guiding-ticks {
  position: absolute;
  left: calc(100% + 14px);
  top: 15px;
  height: 380px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  pointer-events: none;
}

.tick-mark {
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  opacity: 0.4;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.tick-mark.active {
  opacity: 1;
  transform: translateX(2px);
}

.tick-mark.active .tick-line {
  background: var(--accent-color);
  box-shadow: 0 0 10px var(--accent-color);
}

.tick-mark.active .tick-text {
  color: #fff;
  font-weight: 500;
}

.tick-line {
  width: 14px;
  height: 1.5px;
  background: var(--border-glass-bright);
}

.tick-text {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.top-tick {
  margin-top: 36px;
}

.bottom-tick {
  margin-bottom: 40px;
}

/* 圆柱体玻璃容器（默认与呼气：纯澈静谧深蓝） */
.cylinder-container {
  width: 250px;
  height: 390px;
  position: relative;
  border-radius: 125px / 28px;
  box-shadow: 
    0 24px 60px -12px rgba(0, 0, 0, 0.7),
    0 0 20px rgba(56, 189, 248, 0.15),
    inset 0 0 0 1.5px rgba(56, 189, 248, 0.25),
    inset 1px 0 15px rgba(56, 189, 248, 0.12),
    inset -1px 0 15px rgba(56, 189, 248, 0.12);
  background: linear-gradient(
    90deg, 
    rgba(255, 255, 255, 0.03) 0%, 
    rgba(255, 255, 255, 0.01) 20%, 
    rgba(0, 0, 0, 0.15) 50%, 
    rgba(255, 255, 255, 0.01) 80%, 
    rgba(255, 255, 255, 0.04) 100%
  );
  overflow: hidden;
  backdrop-filter: blur(4px);
  transform: translateZ(0);
  transition: border-color 0.8s ease, box-shadow 0.8s ease;
}

/* 仅吸气时：水槽整体切换为落日紫霞微光 */
body.phase-is-inhale .cylinder-container {
  box-shadow: 
    0 24px 65px -10px rgba(0, 0, 0, 0.7),
    0 0 30px rgba(217, 70, 239, 0.35),
    inset 0 0 0 1.5px rgba(232, 121, 249, 0.45),
    inset 1px 0 18px rgba(217, 70, 239, 0.22),
    inset -1px 0 18px rgba(217, 70, 239, 0.22);
}

body.phase-is-inhale .cylinder-top-rim {
  border-color: rgba(245, 208, 254, 0.6);
  box-shadow: inset 0 2px 10px rgba(232, 121, 249, 0.35);
}

body.phase-is-inhale .glass-reflection-left {
  background: linear-gradient(180deg, rgba(245, 208, 254, 0.4) 0%, rgba(217, 70, 239, 0.08) 80%);
}

body.phase-is-inhale .ambient-glow {
  background: radial-gradient(circle, rgba(217, 70, 239, 0.28) 0%, rgba(0, 0, 0, 0) 70%);
}

/* 1秒屏息阶段水槽柔和闪烁3次 */
.cylinder-container.holding-flash {
  animation: holdFlash3 1000ms cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes holdFlash3 {
  0%, 33.3%, 66.6%, 100% {
    box-shadow: 
      0 24px 60px -12px rgba(0, 0, 0, 0.7),
      0 0 20px rgba(232, 121, 249, 0.2),
      inset 0 0 0 1px rgba(255, 255, 255, 0.2),
      inset 1px 0 15px rgba(255, 255, 255, 0.08);
  }
  16.6%, 50%, 83.3% {
    box-shadow: 
      0 24px 75px -6px rgba(255, 255, 255, 0.5),
      0 0 38px rgba(255, 255, 255, 0.7),
      inset 0 0 30px rgba(255, 255, 255, 0.6),
      inset 1px 0 22px rgba(232, 121, 249, 0.6);
  }
}

/* 玻璃高光反光效果 */
.glass-reflection-left {
  position: absolute;
  left: 12px;
  top: 20px;
  bottom: 20px;
  width: 6px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0.02) 80%);
  border-radius: 4px;
  filter: blur(1px);
  pointer-events: none;
  z-index: 5;
}

.glass-reflection-right {
  position: absolute;
  right: 14px;
  top: 30px;
  bottom: 30px;
  width: 2px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.15) 0%, rgba(255, 255, 255, 0.01) 90%);
  border-radius: 2px;
  pointer-events: none;
  z-index: 5;
}

/* 圆柱体顶部边缘光 */
.cylinder-top-rim {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.35);
  box-shadow: inset 0 2px 8px rgba(255, 255, 255, 0.2);
  pointer-events: none;
  z-index: 10;
}

/* 圆柱体底部边缘反光 */
.cylinder-bottom-rim {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50px;
  border-radius: 50%;
  border-bottom: 2px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5);
  pointer-events: none;
  z-index: 10;
}

#waterCanvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* 呼吸信息区 */
.breath-info {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
}

.phase-badge {
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-color);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass-bright);
  padding: 4px 18px;
  border-radius: 20px;
  font-weight: 600;
  transition: all 0.4s ease;
}

.phase-timer {
  font-size: 3.4rem;
  font-weight: 300;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
  color: #fff;
  text-shadow: 0 2px 20px rgba(255, 255, 255, 0.15);
}

.phase-timer .unit {
  font-size: 1.2rem;
  font-weight: 300;
  color: var(--text-muted);
  margin-left: 2px;
}

.phase-guide {
  font-size: 0.88rem;
  color: var(--text-muted);
  min-height: 22px;
  transition: opacity 0.3s ease;
}

/* 底部控制区 */
.footer-controls {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
}

.control-actions {
  display: flex;
  gap: 12px;
  width: 100%;
  justify-content: center;
}

.btn-primary {
  flex: 1;
  max-width: 220px;
  height: 50px;
  border-radius: 25px;
  background: linear-gradient(135deg, var(--water-gradient-top) 0%, var(--water-gradient-mid) 100%);
  color: #fff;
  border: none;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 8px 24px -4px var(--glow-color);
  transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn-primary:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(1px);
}

.btn-secondary {
  height: 50px;
  padding: 0 20px;
  border-radius: 25px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  backdrop-filter: blur(8px);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
  border-color: var(--border-glass-bright);
}

/* 抽屉/附加设置项 */
.settings-drawer {
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: 100%;
  padding: 10px 16px;
  background: var(--card-bg);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  backdrop-filter: blur(12px);
}

.setting-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.setting-text {
  font-size: 0.75rem;
  color: var(--text-subtle);
}

.icon-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--border-glass);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
}

.icon-btn.active {
  color: var(--accent-color);
  border-color: var(--accent-color);
  background: rgba(255, 255, 255, 0.04);
}

/* 主题颜色选择圆点 */
.theme-selector {
  gap: 10px;
}

.theme-dots {
  display: flex;
  gap: 8px;
}

.dot-btn {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.dot-btn:hover {
  transform: scale(1.15);
}

.dot-btn.active {
  border-color: #fff;
  transform: scale(1.1);
}

.rhythm-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
}

.color-badge {
  padding: 3px 8px;
  border-radius: 12px;
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
}

.badge-sunset {
  background: rgba(217, 70, 239, 0.15);
  color: #f0abfc;
  border: 1px solid rgba(217, 70, 239, 0.35);
}

.badge-ocean {
  background: rgba(56, 189, 248, 0.15);
  color: #7dd3fc;
  border: 1px solid rgba(56, 189, 248, 0.35);
}

.color-arrow {
  color: var(--text-subtle);
  font-size: 0.68rem;
}

/* 右侧：呼吸调律科学指南与选择侧栏 */
.guide-sidebar {
  width: 440px;
  background: var(--card-bg);
  border: 1px solid var(--border-glass);
  border-radius: 24px;
  backdrop-filter: blur(16px);
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  max-height: 860px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.sidebar-header {
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-glass);
}

.sidebar-title-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-color);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.sidebar-title {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-main);
}

.sidebar-subtitle {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 4px;
  line-height: 1.45;
}

/* 卡片滚动列表 */
.mode-cards-container {
  flex: 1;
  overflow-y: auto;
  padding-right: 6px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* 优雅滚动条 */
.mode-cards-container::-webkit-scrollbar {
  width: 5px;
}
.mode-cards-container::-webkit-scrollbar-track {
  background: transparent;
}
.mode-cards-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 4px;
}
.mode-cards-container::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.22);
}

/* 单个呼吸法卡片 */
.mode-card {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border-glass);
  border-radius: 14px;
  padding: 13px 15px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.mode-card:hover {
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

.mode-card.active {
  background: rgba(56, 189, 248, 0.07);
  border-color: var(--accent-color);
  box-shadow: 0 0 20px -4px var(--glow-color);
}

body.phase-is-inhale .mode-card.active {
  border-color: #d946ef;
  box-shadow: 0 0 20px -4px rgba(217, 70, 239, 0.3);
}

.card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-title-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-title {
  font-size: 0.92rem;
  font-weight: 600;
  color: #fff;
}

.badge-rec {
  background: linear-gradient(135deg, rgba(234, 179, 8, 0.25), rgba(217, 70, 239, 0.25));
  border: 1px solid rgba(234, 179, 8, 0.45);
  color: #fde047;
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 10px;
}

.badge-tag {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-glass-bright);
  color: var(--text-muted);
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 10px;
}

.active-indicator {
  font-size: 0.68rem;
  color: var(--accent-color);
  font-weight: 600;
  display: none;
  align-items: center;
  gap: 4px;
}

.mode-card.active .active-indicator {
  display: inline-flex;
}

/* 节奏条 */
.rhythm-strip {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.rhythm-pill {
  font-size: 0.7rem;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.rhythm-pill.inhale-pill {
  color: #f0abfc;
  border-color: rgba(217, 70, 239, 0.25);
  background: rgba(217, 70, 239, 0.08);
}

.rhythm-pill.hold-pill {
  color: #fde047;
  border-color: rgba(234, 179, 8, 0.25);
  background: rgba(234, 179, 8, 0.08);
}

.rhythm-pill.exhale-pill {
  color: #7dd3fc;
  border-color: rgba(56, 189, 248, 0.25);
  background: rgba(56, 189, 248, 0.08);
}

.rhythm-ratio-pill {
  font-size: 0.68rem;
  color: var(--text-subtle);
  margin-left: auto;
}

.card-desc {
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.card-scenes {
  font-size: 0.7rem;
  color: var(--text-subtle);
  display: flex;
  align-items: flex-start;
  gap: 5px;
  line-height: 1.35;
}

.card-scenes-icon {
  flex-shrink: 0;
  margin-top: 1px;
}

/* 响应式调整 */
@media (max-width: 1080px) {
  .workspace-wrapper {
    flex-direction: column;
    align-items: center;
    max-height: none;
    height: auto;
    padding: 16px;
  }
  .guide-sidebar {
    width: 100%;
    max-width: 660px;
    max-height: none;
    margin-top: 16px;
  }
}

@media (max-width: 640px) {
  .duo-stage {
    gap: 18px;
  }
  .balloon-wrapper {
    width: 130px;
  }
  .balloon-stage-inner {
    width: 130px;
    height: 320px;
  }
  .balloon-body {
    width: 105px;
    height: 130px;
  }
  .cylinder-container {
    width: 200px;
    height: 330px;
  }
  .guiding-ticks {
    display: none;
  }
  .phase-timer {
    font-size: 2.8rem;
  }
}

@media (max-width: 440px) {
  .duo-stage {
    gap: 12px;
  }
  .balloon-wrapper {
    width: 110px;
  }
  .balloon-stage-inner {
    width: 110px;
    height: 280px;
  }
  .balloon-body {
    width: 90px;
    height: 115px;
  }
  .cylinder-container {
    width: 175px;
    height: 290px;
  }
  .app-container {
    padding: 14px;
  }
  .phase-timer {
    font-size: 2.5rem;
  }
}
