/* 简忆 Mory - 浏览器原型样式 */
:root {
  --primary: #2b8cff;
  --primary-dark: #1a6fd4;
  --primary-light: #e8f4ff;
  --accent: #5eb3ff;
  --bg: #f4f9ff;
  --card: #ffffff;
  --text: #1a2b3c;
  --text-muted: #5c6f82;
  --danger: #e85d4a;
  --safe: #3d5a80;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow: 0 4px 24px rgba(43, 140, 255, 0.1);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Noto Sans SC", sans-serif;
  background: #dceaf8;
  color: var(--text);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 24px 12px;
}

.phone-frame {
  width: 100%;
  max-width: 390px;
  min-height: 780px;
  background: var(--bg);
  border-radius: 32px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.screen {
  display: none;
  flex: 1;
  flex-direction: column;
  min-height: 780px;
}

.screen.active {
  display: flex;
}

/* Login */
.login-inner {
  flex: 1;
  padding: 24px 24px 32px;
  display: flex;
  flex-direction: column;
}

.login-back {
  align-self: flex-start;
  margin-bottom: 24px;
  font-size: 16px;
  color: var(--text-muted);
}

.login-title {
  font-size: 26px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 8px;
}

.login-sub {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.login-form label {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.login-form input {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 14px;
  border: 1px solid #e0deda;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-family: inherit;
  background: var(--card);
}

.code-input-wrap {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.code-input-wrap input {
  flex: 1;
  margin-top: 0;
}

.code-send-btn {
  flex-shrink: 0;
  padding: 10px 12px;
  border: 1px solid var(--primary);
  border-radius: var(--radius-sm);
  background: var(--card);
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}

.code-send-btn:disabled {
  color: var(--text-muted);
  border-color: #ddd;
  cursor: not-allowed;
}

.login-legal {
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 20px;
}

/* Welcome */
.welcome-inner {
  flex: 1;
  padding: 48px 24px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.logo {
  font-size: 42px;
  font-weight: 600;
  color: var(--primary);
  letter-spacing: 0.08em;
}

.logo-sub {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 4px;
  letter-spacing: 0.2em;
}

.tagline {
  margin-top: 12px;
  font-size: 17px;
  color: var(--text-muted);
}

.welcome-cards {
  margin-top: 40px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.welcome-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(43, 140, 255, 0.1);
}

.welcome-card span {
  font-size: 28px;
}

.welcome-card p {
  font-size: 15px;
  color: var(--text);
}

/* Buttons */
.btn {
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 600;
  padding: 14px 20px;
  cursor: pointer;
  font-family: inherit;
}

.btn-block {
  width: 100%;
  margin-top: 10px;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

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

.btn-secondary {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid #ddd;
}

.btn-ghost {
  background: transparent;
  color: var(--primary);
}

.btn-link {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 12px;
  cursor: pointer;
  text-decoration: underline;
}

.btn-icon {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: var(--text-muted);
}

.btn-back {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  padding: 8px;
  margin: -8px;
}

/* Main shell */
#screen-main {
  display: none;
  flex-direction: column;
  flex: 1;
  min-height: 780px;
}

#screen-main.active {
  display: flex;
}

.scene-bar {
  padding: 12px 20px;
  background: linear-gradient(180deg, #ffffff 0%, var(--primary-light) 100%);
  border-bottom: 1px solid rgba(43, 140, 255, 0.12);
}

.scene-bar-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: none;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  font-family: inherit;
}

.scene-icon {
  font-size: 18px;
}

.chevron {
  color: var(--text-muted);
  font-size: 14px;
}

.tab-content {
  flex: 1;
  overflow-y: auto;
  padding: 16px 20px 8px;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.tab-content.voice-tab {
  overflow: hidden;
  padding-bottom: 0;
}

.tab-bar {
  display: flex;
  background: var(--card);
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  padding-bottom: var(--safe-bottom);
}

.tab {
  flex: 1;
  border: none;
  background: none;
  padding: 10px 4px 12px;
  font-size: 11px;
  color: var(--text-muted);
  cursor: pointer;
  font-family: inherit;
}

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

.tab.active span::before {
  content: "";
  display: block;
  width: 4px;
  height: 4px;
  background: var(--primary);
  border-radius: 50%;
  margin: 0 auto 4px;
}

/* 问一问 / 记一记：拇指区域在下方 */
.voice-page {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  height: 100%;
}

.voice-top {
  flex: 1;
  overflow-y: auto;
  padding-bottom: 12px;
}

.mic-zone {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0 max(28px, calc(12px + var(--safe-bottom)));
  background: linear-gradient(180deg, transparent 0%, var(--primary-light) 40%, #dff0ff 100%);
  border-top: 1px solid rgba(43, 140, 255, 0.1);
}

.mic-btn {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  border: 3px solid var(--primary);
  background: var(--card);
  font-size: 38px;
  cursor: pointer;
  box-shadow: 0 8px 28px rgba(43, 140, 255, 0.28);
  transition: transform 0.15s, box-shadow 0.15s;
}

.mic-btn.record {
  border-color: var(--primary);
  background: linear-gradient(145deg, #ffffff, var(--primary-light));
  box-shadow: 0 0 0 10px rgba(43, 140, 255, 0.15);
}

.mic-btn:active,
.mic-btn.listening {
  transform: scale(0.96);
}

/* 打字录入区 */
.type-zone {
  margin-bottom: 18px;
}

.type-hint {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.type-row {
  display: flex;
  gap: 8px;
}

.type-row input {
  flex: 1;
  padding: 10px 14px;
  border: 1px solid rgba(43, 140, 255, 0.2);
  border-radius: 10px;
  font-size: 15px;
  background: var(--card);
  outline: none;
}

.type-row input:focus {
  border-color: var(--primary);
}

.type-row .btn {
  flex-shrink: 0;
  padding: 10px 18px;
  font-size: 14px;
}

.type-example {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.4;
}

.mic-hint {
  margin-bottom: 6px;
  font-size: 14px;
  color: var(--text-muted);
  order: -1;
}

.mic-hint-example {
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--primary);
  order: -1;
  text-align: center;
  line-height: 1.5;
}

.mic-hint-sub {
  margin-bottom: 14px;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-muted);
  order: -1;
  text-align: center;
}

.record-count {
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  text-align: center;
  margin: 4px 0;
  min-height: 20px;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--card);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-top: 0;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
  width: 100%;
  border: 1px solid rgba(43, 140, 255, 0.12);
}

.search-box input {
  flex: 1;
  border: none;
  background: none;
  font-size: 16px;
  outline: none;
  font-family: inherit;
}

.recent-title {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 28px;
  margin-bottom: 10px;
}

.recent-list {
  list-style: none;
}

.recent-list li {
  padding: 12px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  cursor: pointer;
  font-size: 16px;
}

.recent-list li:active {
  color: var(--primary);
}

.recent-list .recent-empty {
  color: var(--text-muted);
  font-size: 14px;
  cursor: default;
  padding: 12px 0;
  border-bottom: none;
}

/* Ask result */
.result-panel {
  text-align: center;
  padding: 24px 0;
}

.result-name {
  font-size: 28px;
  font-weight: 600;
  margin-bottom: 20px;
}

.scene-tag {
  display: inline-block;
  background: var(--card);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.result-path {
  font-size: 20px;
  font-weight: 500;
  line-height: 1.6;
  color: var(--primary);
}

.result-path .arrow {
  color: var(--text-muted);
  font-weight: 400;
}

.result-note {
  margin-top: 20px;
  font-size: 15px;
  color: var(--text-muted);
}

.empty-state {
  text-align: center;
  padding: 40px 16px;
}

.empty-state .emoji {
  font-size: 48px;
  margin-bottom: 16px;
}

.empty-state p {
  color: var(--text-muted);
  margin-bottom: 20px;
}

/* Browse */
.breadcrumb {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.breadcrumb strong {
  color: var(--text);
}

.section-label {
  font-size: 13px;
  color: var(--text-muted);
  margin: 16px 0 10px;
}

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

.chip {
  background: var(--primary-light);
  border: 1px solid rgba(43, 140, 255, 0.2);
  border-radius: 20px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  color: var(--text);
  transition: transform 0.1s;
}

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

.chip.add {
  color: var(--primary);
  border-style: dashed;
  background: var(--card);
}

.browse-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin: -6px 0 12px;
}

.chip-wrap {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  max-width: 100%;
}

.chip-del {
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 50%;
  background: rgba(232, 93, 74, 0.15);
  color: var(--danger);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  margin-right: 4px;
}

.chip-wrap .chip {
  margin: 0;
}

.item-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 10px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(43, 140, 255, 0.08);
  cursor: pointer;
}

.item-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 6px;
}

.item-card .path-small {
  font-size: 14px;
  color: var(--text-muted);
}

/* Swipe card */
.swipe-card {
  position: relative;
  overflow: hidden;
  margin-bottom: 10px;
  border-radius: var(--radius);
}
.swipe-actions {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  display: flex;
  align-items: stretch;
}
.swipe-btn {
  width: 64px;
  border: none;
  color: #fff;
  font-size: 20px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.swipe-edit {
  background: #2b8cff;
}
.swipe-delete {
  background: #e53935;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.swipe-inner {
  position: relative;
  z-index: 1;
  background: var(--card);
  transition: transform 0.2s ease;
  touch-action: pan-y;
}

/* Vault */
.vault-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.vault-header h2 {
  font-size: 20px;
  color: var(--safe);
}

.vault-locked {
  text-align: center;
  padding: 60px 20px;
}

.vault-locked .lock-icon {
  font-size: 56px;
  margin-bottom: 16px;
}

.vault-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  margin-bottom: 16px;
  padding-bottom: 4px;
}

.vault-tab {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: 20px;
  border: none;
  background: var(--card);
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
}

.vault-tab.active {
  background: var(--safe);
  color: #fff;
}

.scene-list li {
  margin-bottom: 8px;
}

.scene-list .scene-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.scene-list .scene-row button.scene-pick {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
}

.scene-list .scene-emoji-btn {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  border: 1px dashed rgba(43, 140, 255, 0.35);
  border-radius: var(--radius-sm);
  background: var(--primary-light);
  font-size: 22px;
  cursor: pointer;
}

.sheet-tip {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}

/* Me */
.profile {
  text-align: center;
  padding: 24px 0;
}

.profile .avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 28px;
  line-height: 72px;
  margin: 0 auto 12px;
}

.menu-list {
  list-style: none;
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.menu-list li {
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.menu-list li:last-child {
  border-bottom: none;
}

.menu-list button {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  border: none;
  background: none;
  font-size: 16px;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
}

.menu-list .chev {
  color: var(--text-muted);
}

.menu-section {
  margin-top: 20px;
}

.hidden {
  display: none !important;
}

/* Overlays */
.overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  z-index: 100;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.overlay-full {
  align-items: stretch;
}

.overlay-full .page-sheet {
  max-width: 390px;
  margin: 0 auto;
  width: 100%;
}

.sheet {
  background: var(--bg);
  border-radius: 20px 20px 0 0;
  width: 100%;
  max-width: 390px;
  padding: 20px 20px calc(24px + var(--safe-bottom));
  max-height: 70vh;
}

.page-sheet {
  background: var(--bg);
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding-bottom: 32px;
}

.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.sheet-head h2 {
  font-size: 18px;
}

.scene-list {
  list-style: none;
}

.scene-list .scene-pick {
  text-align: left;
  padding: 14px 16px;
  border: none;
  background: var(--card);
  border-radius: var(--radius-sm);
  font-size: 16px;
  cursor: pointer;
  font-family: inherit;
}

.scene-list .scene-pick.selected {
  border: 2px solid var(--primary);
  color: var(--primary);
  font-weight: 600;
}

.scene-list li button.selected::before {
  content: "✓ ";
}

.page-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 20px;
  background: var(--card);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.page-head.center {
  justify-content: center;
}

.page-head h1 {
  font-size: 17px;
  font-weight: 600;
}

.form {
  padding: 20px;
}

.form label {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.form input,
.form select {
  display: block;
  width: 100%;
  margin-top: 8px;
  padding: 14px;
  border: 1px solid #e0deda;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-family: inherit;
  background: var(--card);
}

.dup-block {
  padding: 0 20px;
  margin-bottom: 12px;
}

.dup-label {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.dup-arrow {
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  margin: 8px 0;
}

.path-card {
  padding: 16px;
  border-radius: var(--radius-sm);
  font-size: 16px;
  line-height: 1.5;
}

.path-card.muted {
  background: #ebe9e6;
  color: var(--text-muted);
}

.path-card.highlight {
  background: var(--card);
  border: 2px solid var(--primary);
  color: var(--primary);
}

.overlay .btn-block {
  margin: 8px 20px;
  width: calc(100% - 40px);
}

.toast {
  position: fixed;
  bottom: 100px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--text);
  color: #fff;
  padding: 12px 24px;
  border-radius: 24px;
  font-size: 14px;
  z-index: 200;
}

.toast.show {
  display: block;
  animation: fade 2s ease forwards;
}

@keyframes fade {
  0%, 70% { opacity: 1; }
  100% { opacity: 0; }
}

.back-link {
  display: inline-block;
  margin-top: 16px;
  color: var(--primary);
  font-size: 15px;
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
}

/* 订阅 / Pro */
.quota-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 14px;
  margin-bottom: 16px;
  background: var(--primary-light);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(43, 140, 255, 0.2);
  font-size: 13px;
  color: var(--text);
}

.quota-bar.pro {
  background: linear-gradient(90deg, #e8f4ff, #f0f8ff);
}

.quota-link {
  border: none;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 16px;
  cursor: pointer;
  font-family: inherit;
  flex-shrink: 0;
}

.pro-card {
  background: linear-gradient(135deg, #2b8cff 0%, #5eb3ff 100%);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 20px;
  color: #fff;
  box-shadow: 0 8px 24px rgba(43, 140, 255, 0.35);
}

.pro-card h3 {
  font-size: 18px;
  margin-bottom: 6px;
}

.pro-card p {
  font-size: 14px;
  opacity: 0.95;
  margin-bottom: 14px;
  line-height: 1.5;
}

.pro-card .btn {
  background: #fff;
  color: var(--primary);
}

.subscribe-body {
  padding: 8px 20px 32px;
}

.subscribe-badge {
  display: inline-block;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  margin-bottom: 12px;
}

.subscribe-title {
  font-size: 22px;
  margin-bottom: 8px;
  color: var(--text);
}

.subscribe-reason {
  font-size: 14px;
  color: var(--danger);
  margin-bottom: 16px;
  display: none;
}

.subscribe-features {
  list-style: none;
  margin-bottom: 24px;
}

.subscribe-features li {
  padding: 10px 0;
  border-bottom: 1px solid rgba(43, 140, 255, 0.1);
  font-size: 15px;
  padding-left: 24px;
  position: relative;
}

.subscribe-features li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: 700;
}

.plan-cards {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
}

.plan-card {
  flex: 1;
  border: 2px solid #e0e8f0;
  border-radius: var(--radius);
  padding: 16px 12px;
  background: var(--card);
  cursor: pointer;
  text-align: center;
  font-family: inherit;
  position: relative;
}

.plan-card.selected {
  border-color: var(--primary);
  background: var(--primary-light);
}

.plan-tag {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 8px;
}

.plan-name {
  display: block;
  font-size: 15px;
  font-weight: 600;
  margin-top: 4px;
}

.plan-price {
  display: block;
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
  margin-top: 6px;
}

.plan-note {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.subscribe-legal {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 12px 0;
  text-align: center;
}

/* Room sections in browse */
.room-section {
  background: var(--card);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 12px;
  box-shadow: 0 2px 12px rgba(43, 140, 255, 0.06);
  border: 1px solid rgba(43, 140, 255, 0.06);
}

.room-section-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.room-section-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.room-section-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-left: 4px;
}

.room-section-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.chip-sm {
  background: var(--primary-light);
  border: 1px solid rgba(43, 140, 255, 0.12);
  border-radius: 14px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 500;
  cursor: default;
  font-family: inherit;
  color: var(--text);
}

.room-section-empty {
  font-size: 13px;
  color: var(--text-muted);
}

/* Context menu */
.chip-menu-item {
  display: block;
  width: 100%;
  padding: 10px 16px;
  border: none;
  background: none;
  font-size: 14px;
  text-align: left;
  cursor: pointer;
  border-radius: 8px;
  font-family: inherit;
}

.chip-menu-item:active {
  background: #f0f4f8;
}

.chip-menu-item-danger {
  color: var(--danger);
}

/* 内联聆听区域（麦克风上方） */
.listen-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.inline-waveform {
  height: 40px;
  margin-bottom: 0;
}

.inline-waveform .bar {
  width: 5px;
  border-radius: 2.5px;
}

@keyframes wave {
  0%, 100% { height: 8px; opacity: 0.4; }
  50% { height: 32px; opacity: 1; }
}

.listening-text-inline {
  font-size: 18px;
  color: var(--text);
  text-align: center;
  line-height: 1.4;
  min-height: 28px;
}

.listening-text-inline:empty::after {
  content: "正在听...";
  font-size: 14px;
  color: var(--text-muted);
}

.listen-cancel {
  font-size: 13px;
  margin-top: 0;
}

/* 语音聆听浮层（保留旧样式以备后用） */
.listening-sheet {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  background: rgba(255,255,255,0.97);
}

.listening-hint {
  font-size: 18px;
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 32px;
}

/* 波形动画 */
.waveform {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 6px;
  height: 64px;
  margin-bottom: 32px;
}

.waveform .bar {
  display: block;
  width: 6px;
  height: 12px;
  border-radius: 3px;
  background: var(--primary);
  animation: wave 0.8s ease-in-out infinite;
}

.waveform .bar:nth-child(1) { animation-delay: 0s; }
.waveform .bar:nth-child(2) { animation-delay: 0.1s; }
.waveform .bar:nth-child(3) { animation-delay: 0.2s; }
.waveform .bar:nth-child(4) { animation-delay: 0.3s; }
.waveform .bar:nth-child(5) { animation-delay: 0.4s; }

@keyframes wave {
  0%, 100% { height: 12px; opacity: 0.4; }
  50% { height: 56px; opacity: 1; }
}

.listening-text {
  font-size: 22px;
  color: var(--text);
  text-align: center;
  line-height: 1.5;
  min-height: 40px;
  max-width: 320px;
  transition: opacity 0.2s;
}

.listening-text:empty {
  opacity: 0.4;
}

.listening-text:empty::after {
  content: "说出物品或问题...";
  font-size: 15px;
  color: var(--text-muted);
}
