.app {
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.view {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.topbar-title {
  font-weight: 800;
  letter-spacing: -.02em;
  background: linear-gradient(135deg, var(--accent), var(--purple), var(--orange));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 65vw;
}
.topbar-spacer { flex: 1; }
.pill {
  font-size: 11px;
  color: var(--text-dim);
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 999px;
  padding: 4px 10px;
  white-space: nowrap;
}

.main {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.tab-content {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.topbar-toggle {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-dim);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  transition: border-color .15s, color .15s;
}
.topbar-toggle[data-active="true"] {
  color: var(--accent);
  border-color: rgba(56, 189, 248, .4);
}
.topbar-toggle[data-speaking="true"] {
  color: var(--green);
  border-color: rgba(52, 211, 153, .6);
  animation: mic-pulse .6s ease-in-out infinite;
}
.topbar-toggle[data-processing="true"] {
  color: var(--amber);
  border-color: rgba(251, 191, 36, .5);
  animation: none;
}

.auth-view { justify-content: center; padding: 22px 14px; }
.auth-card {
  margin: 0 auto;
  width: min(420px, 100%);
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.brand { font-size: 18px; font-weight: 900; letter-spacing: -.03em; }

.row { display: flex; gap: 10px; padding: 12px 14px 6px; }
.list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 8px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.list-item {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 14px;
  padding: 12px 12px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.list-item .title { font-weight: 900; }
.list-item .subtitle {
  font-size: 12px;
  color: var(--text-dim);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  justify-content: center;
  align-items: flex-end;
  padding: 14px;
}
.modal-card {
  width: min(520px, 100%);
  max-height: 70dvh;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.modal-header { display: flex; align-items: center; gap: 10px; }
.modal-title { font-weight: 900; }
