/* Baithak in-app styles. Dark, glassy, denser than landing. */

:root {
  --bg: #08080C;
  --bg-2: #0E0E16;
  --surface: rgba(255, 255, 255, 0.03);
  --surface-2: rgba(255, 255, 255, 0.06);
  --surface-3: rgba(255, 255, 255, 0.09);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #F5F5F7;
  --text-muted: #A1A1AA;
  --text-dim: #71717A;
  --saffron: #F97316;
  --saffron-bright: #FB923C;
  --saffron-glow: rgba(249, 115, 22, 0.5);
  --teal: #14B8A6;
  --teal-bright: #2DD4BF;
  --teal-glow: rgba(20, 184, 166, 0.5);
  --violet: #8B5CF6;
  --violet-bright: #A78BFA;
  --amber: #F59E0B;
  --rose: #F43F5E;
  --font: 'Inter', -apple-system, system-ui, "Segoe UI", sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --radius: 14px;
  --radius-sm: 10px;
  --radius-xs: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; position: relative; z-index: 2; }
.mono { font-family: var(--font-mono); }
.muted { color: var(--text-muted); }
.small { font-size: 13px; }

/* ─── Animated background ─────────────────────────────────────────── */
.bg-fx { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.orb { position: absolute; border-radius: 50%; filter: blur(110px); opacity: 0.4; will-change: transform; }
.orb-1 { width: 520px; height: 520px; top: -120px; left: -160px;
         background: radial-gradient(circle, var(--saffron) 0%, transparent 70%);
         animation: drift1 24s ease-in-out infinite; }
.orb-2 { width: 460px; height: 460px; top: 30%; right: -120px;
         background: radial-gradient(circle, var(--teal) 0%, transparent 70%);
         animation: drift2 30s ease-in-out infinite; }
.orb-3 { width: 600px; height: 600px; bottom: -200px; left: 30%;
         background: radial-gradient(circle, var(--violet) 0%, transparent 70%);
         animation: drift3 36s ease-in-out infinite; opacity: 0.3; }
@keyframes drift1 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(70px,50px) scale(1.08); } }
@keyframes drift2 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(-90px,70px) scale(0.95); } }
@keyframes drift3 { 0%,100% { transform: translate(0,0) scale(1); } 50% { transform: translate(50px,-90px) scale(1.05); } }

/* ─── Nav ─────────────────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  background: rgba(8, 8, 12, 0.7);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1280px; margin: 0 auto;
  padding: 12px 24px;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-brand {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--text);
  font-weight: 600; font-size: 16px; letter-spacing: -0.01em;
}
.nav-brand img { color: var(--saffron-bright); }
.nav-script {
  font-family: 'Times New Roman', Georgia, serif;
  font-style: italic; color: var(--saffron-bright);
  font-size: 14px; opacity: 0.85;
}
.nav-right { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.nav-email { font-size: 13px; color: var(--text-muted); max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-sep   { color: var(--text-dim); }
.nav-link  {
  color: var(--text-muted); text-decoration: none; font-size: 14px;
  transition: color .15s;
}
.nav-link:hover { color: var(--text); }
.nav-link-cta {
  padding: 8px 14px; border: 1px solid var(--border-strong); border-radius: 999px; color: var(--text);
}
.nav-link-cta:hover { background: var(--surface-2); }

/* ─── Footer ──────────────────────────────────────────────────────── */
.footer { border-top: 1px solid var(--border); padding: 22px 0; position: relative; z-index: 2; }
.footer-inner {
  max-width: 1280px; margin: 0 auto; padding: 0 24px;
  font-size: 12px; color: var(--text-dim); text-align: center;
}
.footer-inner a { color: var(--text-muted); text-decoration: none; border-bottom: 1px dotted var(--text-dim); }
.footer-inner a:hover { color: var(--saffron-bright); border-color: var(--saffron-bright); }

/* ─── Container / page ────────────────────────────────────────────── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.page { padding-top: 36px; padding-bottom: 80px; }
.page-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 16px; margin-bottom: 28px; flex-wrap: wrap;
}
.page-title { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; }
.page-sub   { color: var(--text-muted); font-size: 14px; margin-top: 4px; }

/* ─── Card ────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(8px);
  padding: 18px;
}
.card-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 10px;
}
.card-h { font-size: 14px; font-weight: 600; letter-spacing: -0.005em; }
.count {
  display: inline-block; min-width: 22px; padding: 2px 8px; margin-left: 6px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 999px; font-size: 11px; color: var(--text-muted);
  font-family: var(--font-mono); text-align: center;
}

/* ─── Buttons ─────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px; min-height: 44px;
  border-radius: 10px; font-size: 14px; font-weight: 600; font-family: inherit;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .1s, box-shadow .2s, background .15s, border-color .15s;
}
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-primary {
  color: white;
  background: linear-gradient(135deg, var(--saffron) 0%, var(--saffron-bright) 100%);
  box-shadow: 0 4px 20px -8px var(--saffron-glow);
}
.btn-primary:hover:not(:disabled) { box-shadow: 0 8px 32px -8px var(--saffron-glow); transform: translateY(-1px); }
.btn-primary:active:not(:disabled) { transform: translateY(0); }
.btn-secondary {
  color: var(--text); background: var(--surface-2); border-color: var(--border-strong);
}
.btn-secondary:hover:not(:disabled) { background: var(--surface-3); }
.btn-block { width: 100%; }
.icon-btn {
  background: transparent; border: 0; color: var(--text-muted);
  font-size: 22px; line-height: 1; cursor: pointer; padding: 8px; min-width: 44px; min-height: 44px;
}
.icon-btn:hover { color: var(--text); }

/* ─── Inputs ──────────────────────────────────────────────────────── */
.field { display: flex; flex-direction: column; gap: 6px; }
.field-label {
  font-size: 12px; color: var(--text-muted); font-weight: 500; letter-spacing: 0.02em;
}
.field-hint { font-size: 12px; color: var(--text-dim); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 720px) { .field-row { grid-template-columns: 1fr; } }
.input {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px; min-height: 44px;
  color: var(--text); font-size: 14px; font-family: inherit;
  outline: none; transition: border-color .15s, background .15s;
  width: 100%;
}
.input:focus { border-color: var(--saffron-bright); background: rgba(255, 255, 255, 0.06); }
select.input { appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-muted) 50%),
                    linear-gradient(135deg, var(--text-muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 36px;
}
select.input option { background: #14141B; color: var(--text); }
.form-error {
  background: rgba(244, 63, 94, 0.10);
  border: 1px solid rgba(244, 63, 94, 0.35);
  color: #FECACA;
  padding: 10px 12px; border-radius: var(--radius-sm); font-size: 13px;
}

/* ─── Auth pages ──────────────────────────────────────────────────── */
.auth-wrap {
  min-height: calc(100vh - 200px);
  display: flex; align-items: center; justify-content: center;
  padding: 48px 20px;
}
.auth-card { max-width: 440px; width: 100%; padding: 32px; }
.auth-h1 { font-size: 26px; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 6px; }
.auth-sub { color: var(--text-muted); font-size: 14px; margin-bottom: 22px; }
.auth-form { display: flex; flex-direction: column; gap: 14px; }
.auth-form .btn-primary { margin-top: 6px; }
.auth-meta { color: var(--text-muted); font-size: 13px; margin-top: 18px; }
.auth-meta a { color: var(--saffron-bright); text-decoration: none; }
.auth-meta a:hover { text-decoration: underline; }
.auth-meta-sm { font-size: 12.5px; color: var(--text-dim); }

/* ─── Dashboard / meeting list ────────────────────────────────────── */
.empty-state {
  text-align: center; padding: 56px 24px; max-width: 560px; margin: 24px auto 0;
}
.empty-state h2 { font-size: 18px; font-weight: 600; margin-bottom: 6px; }
.empty-state p  { color: var(--text-muted); font-size: 14px; }
.empty-icon {
  font-size: 12px; color: var(--saffron-bright); display: inline-block;
  margin-bottom: 12px; box-shadow: 0 0 12px var(--saffron-glow);
  width: 12px; height: 12px; border-radius: 50%; background: var(--saffron-bright);
}

.meetings-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.meeting-row { padding: 0; transition: border-color .15s, background .15s, transform .1s; }
.meeting-row:hover { border-color: var(--border-strong); background: var(--surface-2); transform: translateY(-1px); }
.meeting-link {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 18px; text-decoration: none; color: inherit;
  flex-wrap: wrap;
}
.meeting-main { min-width: 0; flex: 1; }
.meeting-title { font-size: 15px; font-weight: 600; letter-spacing: -0.005em; }
.meeting-meta { font-size: 12.5px; color: var(--text-muted); margin-top: 4px; display: flex; gap: 8px; }
.dot-sep { color: var(--text-dim); }
.meeting-stats { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.stat-mini { text-align: right; }
.stat-mini-v { font-family: var(--font-mono); font-size: 15px; font-weight: 600; }
.stat-mini-l { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em; }

.badge {
  display: inline-flex; padding: 4px 10px; border-radius: 999px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text-muted);
}
.badge-recording { background: rgba(249,115,22,0.12); border-color: rgba(249,115,22,0.35); color: var(--saffron-bright); }
.badge-done      { background: rgba(20,184,166,0.10); border-color: rgba(20,184,166,0.30); color: var(--teal-bright); }
.badge-created   { background: rgba(139,92,246,0.10); border-color: rgba(139,92,246,0.30); color: var(--violet-bright); }
.badge-error     { background: rgba(244,63,94,0.10);  border-color: rgba(244,63,94,0.30);  color: #FECACA; }

/* ─── Modal ───────────────────────────────────────────────────────── */
.modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,0.6); backdrop-filter: blur(4px); }
.modal-card {
  position: relative; width: min(520px, 100%); max-height: 90vh; overflow-y: auto;
  background: var(--bg-2); border: 1px solid var(--border-strong);
}
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.modal-head h2 { font-size: 18px; font-weight: 600; }
.modal-body { display: flex; flex-direction: column; gap: 14px; }
.modal-foot { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; }
@media (max-width: 720px) { .modal-foot { flex-direction: column-reverse; } .modal-foot .btn { width: 100%; } }

/* ─── Meeting page ────────────────────────────────────────────────── */
.meeting-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; margin-bottom: 20px; flex-wrap: wrap;
}
.meeting-head-left { min-width: 0; }
.back-link { color: var(--text-muted); font-size: 13px; text-decoration: none; }
.back-link:hover { color: var(--text); }
.meeting-title-h {
  font-size: 24px; font-weight: 700; letter-spacing: -0.02em; margin-top: 4px;
  outline: none; padding: 2px 0;
}
.meeting-title-h[data-editable="1"]:focus {
  border-bottom: 1px dashed var(--saffron-bright);
}
.conn-status {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border);
  font-size: 12px; color: var(--text-muted);
}
.conn-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--text-dim);
  transition: background .2s, box-shadow .2s;
}
.conn-status.live .conn-dot { background: var(--teal-bright); box-shadow: 0 0 10px var(--teal-glow); }
.conn-status.live #conn-label { color: var(--teal-bright); }

.meeting-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px;
  align-items: start;
}
@media (max-width: 1080px) { .meeting-grid { grid-template-columns: 1fr; } }

.meeting-left { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.meeting-right { display: flex; flex-direction: column; gap: 12px; }

/* Record card */
.record-card { padding: 18px; }
.record-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.record-meta { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.rec-timer { font-size: 18px; color: var(--text); font-weight: 600; }
.upload-status { font-size: 12px; color: var(--text-dim); }
.btn-record {
  background: linear-gradient(135deg, var(--saffron) 0%, var(--saffron-bright) 100%);
  color: white; box-shadow: 0 6px 24px -10px var(--saffron-glow);
  padding: 13px 22px; min-height: 48px; font-size: 15px;
}
.btn-record:hover:not(:disabled) { box-shadow: 0 10px 36px -10px var(--saffron-glow); transform: translateY(-1px); }
.btn-record.is-recording {
  background: linear-gradient(135deg, #DC2626 0%, #EF4444 100%);
  box-shadow: 0 6px 24px -10px rgba(239,68,68,0.6);
}
.btn-record.is-recording .rec-glyph {
  width: 10px; height: 10px; background: white; border-radius: 50%; display: inline-block;
  animation: rec-pulse 1.4s ease-in-out infinite;
}
.rec-glyph {
  width: 10px; height: 10px; background: white; border-radius: 2px; display: inline-block;
}
@keyframes rec-pulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.55; transform: scale(0.85); } }

/* Transcript */
.transcript-card { display: flex; flex-direction: column; min-height: 320px; }
.transcript {
  flex: 1; overflow-y: auto; max-height: 60vh;
  padding: 4px 0; display: flex; flex-direction: column; gap: 10px;
}
.tline { display: flex; gap: 10px; align-items: flex-start; padding: 8px 4px; border-bottom: 1px dashed var(--border); }
.tline:last-child { border-bottom: 0; }
.tline-meta { display: flex; flex-direction: column; gap: 4px; min-width: 110px; flex-shrink: 0; }
.tline-speaker {
  display: inline-flex; padding: 2px 9px; border-radius: 999px;
  font-size: 11px; font-weight: 600; max-width: fit-content;
}
.tline-ts { font-family: var(--font-mono); font-size: 11px; color: var(--text-dim); }
.tline-text { font-size: 14px; line-height: 1.55; color: var(--text); flex: 1; min-width: 0; }
@media (max-width: 720px) {
  .tline { flex-direction: column; gap: 4px; }
  .tline-meta { flex-direction: row; min-width: 0; align-items: center; }
}

/* Right column blocks */
.topic-now { font-size: 13.5px; color: var(--text-muted); }
.topic-now em { color: var(--saffron-bright); font-style: italic; }

.stat-block { text-align: center; padding: 22px 18px; }
.stat-label { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.stat-big   { font-size: 36px; font-weight: 700; letter-spacing: -0.02em; margin: 4px 0;
              background: linear-gradient(135deg, var(--saffron-bright), var(--violet-bright));
              -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.stat-sub   { font-size: 12.5px; color: var(--text-dim); }

.cost-block { padding: 14px 18px; }
.cost-row { display: flex; justify-content: space-between; align-items: baseline; }
.cost-label { font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.cost-val { font-size: 13px; }
.cost-bar {
  margin-top: 8px; height: 6px; border-radius: 999px;
  background: var(--surface-2); overflow: hidden;
}
.cost-fill {
  display: block; height: 100%; width: 0%;
  background: var(--saffron-bright); transition: width .3s, background .3s;
}
.cost-fill.warn  { background: var(--amber); }
.cost-fill.alert { background: var(--rose); }

/* Generic panel list */
.panel-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.panel-list li {
  font-size: 13px; line-height: 1.5;
  padding: 8px 10px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-xs);
}
.panel-list li .ts {
  font-family: var(--font-mono); font-size: 11px; color: var(--text-dim);
  display: block; margin-bottom: 2px;
}
.panel-list li .owner {
  display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px;
  background: rgba(20,184,166,0.10); border: 1px solid rgba(20,184,166,0.30);
  color: var(--teal-bright); font-size: 10.5px; font-weight: 600;
}
.panel-list .empty-li { color: var(--text-dim); background: transparent; border: 0; padding: 4px 0; font-size: 12.5px; }

.speakers li { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.speakers .sp-name { display: inline-flex; align-items: center; gap: 8px; }
.speakers .sp-color { width: 10px; height: 10px; border-radius: 50%; }
.speakers button { background: transparent; border: 1px solid var(--border-strong); color: var(--text-muted); border-radius: 6px; padding: 4px 8px; font-size: 11px; cursor: pointer; }
.speakers button:hover { color: var(--text); border-color: var(--text-muted); }

/* Toggle */
.toggle { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 12px; color: var(--text-muted); }
.toggle input { accent-color: var(--saffron-bright); width: 14px; height: 14px; }

/* ─── Toasts ──────────────────────────────────────────────────────── */
.toast-host {
  position: fixed; bottom: 20px; right: 20px; z-index: 300;
  display: flex; flex-direction: column; gap: 8px; max-width: 360px;
}
.toast {
  padding: 12px 14px; border-radius: var(--radius-sm);
  background: rgba(20, 20, 28, 0.95); border: 1px solid var(--border-strong);
  color: var(--text); font-size: 13px; box-shadow: 0 12px 40px -10px rgba(0,0,0,0.6);
  animation: toast-in 0.18s ease-out;
}
.toast.error   { border-color: rgba(244,63,94,0.5); }
.toast.success { border-color: rgba(20,184,166,0.5); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ─── Responsive ──────────────────────────────────────────────────── */
@media (max-width: 720px) {
  .nav-inner { padding: 10px 16px; }
  .container { padding: 0 16px; }
  .page { padding-top: 24px; }
  .page-title { font-size: 22px; }
  .meeting-stats { gap: 12px; }
  .stat-mini-l { font-size: 10px; }
}

/* ─── Delete + danger ───────────────────────────────────────────────── */
.btn-danger {
  background: rgba(244, 63, 94, 0.12);
  color: #fca5a5;
  border: 1px solid rgba(244, 63, 94, 0.35);
}
.btn-danger:hover {
  background: rgba(244, 63, 94, 0.22);
  border-color: rgba(244, 63, 94, 0.55);
  color: #fee2e2;
}
.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}

/* Dashboard delete button (×) on each row */
.meeting-row {
  position: relative;
  padding-right: 48px;
}
.meeting-delete {
  position: absolute;
  top: 50%; right: 14px;
  transform: translateY(-50%);
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-dim, #6B6B6B);
  border-radius: 8px;
  font-size: 18px; line-height: 1;
  cursor: pointer;
  opacity: 0;
  transition: all 0.15s;
}
.meeting-row:hover .meeting-delete { opacity: 1; }
.meeting-delete:hover {
  background: rgba(244, 63, 94, 0.15);
  border-color: rgba(244, 63, 94, 0.4);
  color: #fca5a5;
}

/* Meeting page danger zone — always visible delete */
.danger-card { border-color: rgba(244, 63, 94, 0.25); }
.danger-card .btn-danger { width: 100%; }

/* ─── Web context / insights ────────────────────────────────────────── */
.insight-card .card-head { display: flex; align-items: center; justify-content: space-between; }
.insights-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.insight-item {
  padding: 14px;
  background: rgba(20, 184, 166, 0.06);
  border: 1px solid rgba(20, 184, 166, 0.18);
  border-left: 3px solid #14B8A6;
  border-radius: 8px;
}
.insight-item .insight-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text, #F5F5F7);
}
.insight-item .insight-content {
  font-size: 13px;
  color: var(--text-muted, #A1A1AA);
  line-height: 1.55;
}
.insight-item .insight-sources {
  margin-top: 8px;
  display: flex; flex-wrap: wrap; gap: 8px;
}
.insight-item .insight-sources a {
  font-size: 11px;
  color: #2DD4BF;
  text-decoration: none;
  padding: 2px 8px;
  background: rgba(20, 184, 166, 0.1);
  border-radius: 999px;
  border: 1px solid rgba(20, 184, 166, 0.2);
}
.insight-item .insight-sources a:hover { background: rgba(20, 184, 166, 0.2); }
.insight-item.insight-error { border-left-color: #f87171; background: rgba(244, 63, 94, 0.05); }
.enrich-spinner {
  display: inline-block; width: 12px; height: 12px;
  border: 2px solid rgba(255,255,255,0.2);
  border-top-color: var(--saffron-bright, #FB923C);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 6px;
  vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Item rows (decisions / actions / questions) ───────────────────── */
.item-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 12px;
  margin-bottom: 8px;
  background: rgba(255,255,255,0.02);
  border-radius: 8px;
  border-left: 2px solid transparent;
  font-size: 13px;
  line-height: 1.5;
}
.item-row .item-main {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
  color: var(--text, #F5F5F7);
}
.item-row .item-main .ts {
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 11px;
  color: var(--text-dim, #6B6B6B);
  font-weight: 500;
  flex-shrink: 0;
}
.item-row .item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 2px;
}
.item-row .item-meta .owner,
.item-row .item-meta .due {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
}
.item-row .item-meta .owner {
  background: rgba(15, 118, 110, 0.18);
  color: #5eead4;
  border: 1px solid rgba(15, 118, 110, 0.35);
}
.item-row .item-meta .due {
  background: rgba(194, 65, 12, 0.15);
  color: #fdba74;
  border: 1px solid rgba(194, 65, 12, 0.3);
}
.item-row .item-native {
  font-size: 12px;
  color: var(--text-muted, #A1A1AA);
  font-style: italic;
  padding-left: 8px;
  border-left: 2px solid rgba(255,255,255,0.08);
}
.item-action { border-left-color: rgba(15, 118, 110, 0.4); }


/* ─── Disabled button state (Enrich, etc.) ──────────────────────────── */
.btn:disabled,
.btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}
.btn:disabled:hover,
.btn[disabled]:hover {
  /* Cancel hover effects when disabled */
  background: inherit;
  border-color: inherit;
  color: inherit;
}

/* ─── Insight bullets (replace old paragraph .insight-content) ──────── */
.insight-bullets {
  list-style: disc;
  padding-left: 18px;
  margin: 6px 0 4px;
  color: var(--text-muted, #A1A1AA);
}
.insight-bullets li {
  font-size: 13px;
  line-height: 1.45;
  margin: 3px 0;
  color: var(--text, #F5F5F7);
}
.insight-bullets li::marker { color: var(--teal-bright, #2DD4BF); }

/* ─── Two-column transcript (Source | Translation) ──────────────────── */
.transcript-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  flex: 1;
  min-height: 280px;
}
.transcript-col {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.015);
  overflow: hidden;
}
.transcript-col-head {
  padding: 8px 14px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted, #A1A1AA);
  background: rgba(255,255,255,0.025);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
/* Override base .transcript so each column scrolls independently */
.transcript-col .transcript {
  flex: 1;
  overflow-y: auto;
  padding: 10px 14px;
  min-height: 220px;
  max-height: 60vh;
}
.live-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--saffron-bright, #FB923C);
  font-weight: 500;
}
.live-status .live-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--saffron-bright, #FB923C);
  box-shadow: 0 0 8px var(--saffron-bright, #FB923C);
  animation: pulse 1.4s infinite;
}
@keyframes pulse {
  0%,100% { opacity: 1; }
  50%     { opacity: 0.35; }
}

/* Stack columns on narrow screens */
@media (max-width: 880px) {
  .transcript-grid { grid-template-columns: 1fr; }
  .transcript-col .transcript { max-height: 320px; }
}

/* ─── Live streaming interim line ───────────────────────────────────── */
.tline-interim .tline-text {
  font-style: italic;
  color: var(--text-muted, #A1A1AA);
  position: relative;
}
.tline-interim .tline-text::after {
  content: '·';
  display: inline-block;
  margin-left: 4px;
  color: var(--saffron-bright, #FB923C);
  animation: blink 1s steps(2, start) infinite;
  font-weight: 700;
}
@keyframes blink { to { visibility: hidden; } }

/* ─── Polish pass: empty states, waveform, stats strip, etc. ──────── */

/* Empty-state list rows (decisions, actions, questions, sinks, etc.) */
.empty-state-li {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 12px !important;
  color: var(--text-dim) !important;
  background: rgba(255,255,255,0.015) !important;
  border: 1px dashed var(--border) !important;
  border-radius: var(--radius-xs) !important;
  font-size: 12.5px;
  line-height: 1.45;
}
.empty-state-icon {
  font-size: 16px;
  opacity: 0.65;
  filter: saturate(0.6);
  flex-shrink: 0;
  width: 22px; text-align: center;
}
.empty-state-msg { color: var(--text-muted); }
.empty-state-msg em { color: var(--saffron-bright); font-style: normal; font-weight: 600; }

/* Waveform — sits below the record button */
.waveform {
  display: block;
  margin-top: 12px;
  width: 100%;
  height: 48px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0.01));
  border: 1px solid var(--border);
  opacity: 0.55;
  transition: opacity .25s, box-shadow .3s, border-color .25s;
}
.waveform.is-active {
  opacity: 1;
  border-color: rgba(249,115,22,0.25);
  box-shadow: 0 0 24px -10px var(--saffron-glow), inset 0 0 18px -10px var(--teal-glow);
}

/* Processing pill ("translating…") next to topic */
.processing-pill {
  display: inline-flex; align-items: center; gap: 6px;
  margin-left: 8px;
  padding: 2px 9px;
  border-radius: 999px;
  background: rgba(20,184,166,0.10);
  border: 1px solid rgba(20,184,166,0.30);
  color: var(--teal-bright);
  font-size: 11px; font-weight: 600;
  letter-spacing: 0.02em;
  vertical-align: middle;
  animation: toast-in 0.18s ease-out;
}
.processing-pill[hidden] { display: none; }
.processing-spinner {
  width: 9px; height: 9px;
  border: 1.5px solid rgba(45,212,191,0.25);
  border-top-color: var(--teal-bright);
  border-radius: 50%;
  display: inline-block;
  animation: spin 0.9s linear infinite;
}

/* Animated entrance for new items in panels */
@keyframes item-fade-in {
  0%   { opacity: 0; transform: translateY(8px); }
  100% { opacity: 1; transform: translateY(0); }
}
.item-row.item-new {
  animation: item-fade-in 0.32s ease-out;
  box-shadow: 0 0 0 1px rgba(249,115,22,0.35), 0 4px 16px -8px var(--saffron-glow);
}

/* Cost meter — gradient + smoother transition */
.cost-fill {
  background: linear-gradient(90deg, var(--saffron) 0%, var(--saffron-bright) 70%, var(--amber) 100%);
  transition: width 0.45s ease-out, background 0.3s;
}
.cost-fill.warn  {
  background: linear-gradient(90deg, var(--saffron-bright) 0%, var(--amber) 100%);
}
.cost-fill.alert {
  background: linear-gradient(90deg, var(--amber) 0%, var(--rose) 100%);
}

/* ─── Dashboard stats strip ────────────────────────────────────────── */
.dash-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}
.dash-stat {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  backdrop-filter: blur(8px);
  transition: transform .15s, border-color .15s, background .15s;
  text-align: left;
}
.dash-stat:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
  background: var(--surface-2);
}
.dash-stat-v {
  font-family: var(--font-mono);
  font-size: 26px; font-weight: 700; letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--saffron-bright) 0%, var(--teal-bright) 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  line-height: 1.1;
}
.dash-stat-l {
  font-size: 11px; letter-spacing: 0.10em; text-transform: uppercase;
  color: var(--text-muted); margin-top: 6px; font-weight: 500;
}
@media (max-width: 880px) { .dash-stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .dash-stats { grid-template-columns: 1fr 1fr; gap: 10px; }
                            .dash-stat-v { font-size: 22px; } }

/* ─── Welcome card (zero-meeting state) ───────────────────────────── */
.welcome-card {
  margin: 8px 0 24px;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background:
    radial-gradient(120% 80% at 0% 0%, rgba(249,115,22,0.10) 0%, transparent 60%),
    radial-gradient(120% 80% at 100% 100%, rgba(20,184,166,0.10) 0%, transparent 60%),
    var(--surface);
}
.welcome-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 20px;
  padding: 28px;
  align-items: center;
}
.welcome-eyebrow {
  display: inline-block;
  font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--saffron-bright);
  font-weight: 700; margin-bottom: 8px;
}
.welcome-h {
  font-size: 24px; font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 8px; color: var(--text);
  background: linear-gradient(135deg, var(--text) 0%, var(--teal-bright) 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.welcome-sub { color: var(--text-muted); font-size: 14px; margin-bottom: 14px; }
.welcome-steps {
  list-style: none; padding: 0; margin: 0 0 20px;
  display: flex; flex-direction: column; gap: 10px;
}
.welcome-steps li {
  display: flex; align-items: flex-start; gap: 12px;
  font-size: 13.5px; color: var(--text-muted); line-height: 1.5;
}
.welcome-steps li strong { color: var(--text); font-weight: 600; }
.step-num {
  flex-shrink: 0;
  width: 24px; height: 24px; border-radius: 50%;
  background: linear-gradient(135deg, var(--saffron) 0%, var(--saffron-bright) 100%);
  color: white;
  font-size: 12px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px -4px var(--saffron-glow);
}
.welcome-cta {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
}
.welcome-art {
  position: relative; height: 200px; min-width: 0;
  display: flex; align-items: center; justify-content: center;
}
.welcome-orb {
  position: absolute; border-radius: 50%; filter: blur(40px); opacity: 0.55;
}
.welcome-orb-saffron {
  width: 160px; height: 160px; top: 0; left: 30px;
  background: radial-gradient(circle, var(--saffron) 0%, transparent 65%);
  animation: drift1 18s ease-in-out infinite;
}
.welcome-orb-teal {
  width: 180px; height: 180px; bottom: 0; right: 10px;
  background: radial-gradient(circle, var(--teal) 0%, transparent 65%);
  animation: drift2 22s ease-in-out infinite;
}
.welcome-pulse {
  position: relative; z-index: 1;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--saffron-bright);
  box-shadow: 0 0 24px var(--saffron-glow);
  animation: pulse 1.8s ease-in-out infinite;
}
.welcome-pulse::before, .welcome-pulse::after {
  content: ''; position: absolute; inset: -10px; border-radius: 50%;
  border: 1px solid rgba(251,146,60,0.35); animation: ring-grow 2.4s ease-out infinite;
}
.welcome-pulse::after { animation-delay: 1.2s; }
@keyframes ring-grow {
  0%   { transform: scale(0.6); opacity: 0.85; }
  100% { transform: scale(2.4); opacity: 0; }
}
@media (max-width: 760px) {
  .welcome-grid { grid-template-columns: 1fr; padding: 22px; }
  .welcome-art { height: 140px; }
  .welcome-h { font-size: 20px; }
}

/* ─── Auth: email check + button spinner ──────────────────────────── */
.input-with-check { position: relative; display: block; }
.input-with-check .input { padding-right: 110px; }
.input-check {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  font-size: 11.5px; color: var(--teal-bright); font-weight: 600;
  background: rgba(20,184,166,0.10);
  padding: 3px 9px; border-radius: 999px;
  border: 1px solid rgba(20,184,166,0.25);
  opacity: 0; pointer-events: none;
  transition: opacity 0.2s;
}
.input-check.is-visible { opacity: 1; }

.btn-spinner {
  width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: white;
  border-radius: 50%;
  display: inline-block;
  animation: spin 0.8s linear infinite;
  margin-right: 6px;
  vertical-align: middle;
}
.btn-loading { opacity: 0.8; }

/* ─── Transcript column header subtle pulse when active ────────────── */
.transcript-col-head { transition: color .25s; }
.tline-interim ~ * { } /* placeholder, no-op */

/* DEPLOY-CHECK 1777882014 */

/* ─── Dashboard quick-start tiles ────────────────────────────────────── */
.quick-tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 22px;
}
.quick-tile {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 16px 18px;
  text-align: left;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: inherit; text-decoration: none;
  cursor: pointer; font-family: inherit;
  transition: transform .15s, border-color .15s, background .15s, box-shadow .2s;
}
.quick-tile:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
  background: var(--surface-2);
  box-shadow: 0 10px 30px -16px rgba(0,0,0,0.6);
}
.quick-tile-icon {
  font-size: 22px; line-height: 1;
  width: 40px; height: 40px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(249,115,22,0.15), rgba(20,184,166,0.12));
  border: 1px solid var(--border);
}
.quick-tile-body { min-width: 0; }
.quick-tile-title {
  font-size: 14px; font-weight: 600; color: var(--text);
  letter-spacing: -0.005em;
}
.quick-tile-desc {
  font-size: 12.5px; color: var(--text-muted); margin-top: 3px;
  line-height: 1.4;
}
@media (max-width: 880px) {
  .quick-tiles { grid-template-columns: 1fr; }
}

/* ─── Dashboard 2-col content row ────────────────────────────────────── */
.dash-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 0 0 22px;
}
@media (max-width: 880px) {
  .dash-row-2col { grid-template-columns: 1fr; }
}
.dash-list { display: flex; flex-direction: column; gap: 4px; }

.action-row, .decision-row {
  display: flex; flex-direction: column; gap: 4px;
  padding: 10px 12px;
  border-radius: var(--radius-xs);
  text-decoration: none; color: inherit;
  border: 1px solid transparent;
  transition: background .15s, border-color .15s;
  cursor: pointer;
}
.action-row:hover, .decision-row:hover {
  background: var(--surface-2);
  border-color: var(--border);
}
.action-text, .decision-text {
  font-size: 13.5px; line-height: 1.45; color: var(--text);
}
.action-meta, .decision-meta {
  display: flex; align-items: center; flex-wrap: wrap; gap: 6px;
  font-size: 11.5px; color: var(--text-dim);
}
.action-meta .meeting-link-mini,
.decision-meta .meeting-link-mini {
  color: var(--text-muted); font-size: 11.5px;
  border-bottom: 1px dotted var(--border-strong);
}
.action-row:hover .meeting-link-mini,
.decision-row:hover .meeting-link-mini { color: var(--saffron-bright); }
.decision-meta .ts {
  font-family: var(--font-mono); font-size: 11px; color: var(--text-dim);
}
.pill {
  display: inline-block; padding: 1px 8px; border-radius: 999px;
  font-size: 11px; font-weight: 500; line-height: 1.5;
}
.pill-owner {
  background: rgba(20,184,166,0.10); color: var(--teal-bright);
  border: 1px solid rgba(20,184,166,0.30);
}
.pill-due {
  background: rgba(194,65,12,0.12); color: #fdba74;
  border: 1px solid rgba(194,65,12,0.30);
}

.link-btn {
  background: transparent; border: 0; cursor: pointer;
  color: var(--saffron-bright); font-size: 12px; font-weight: 600;
  font-family: inherit; padding: 4px 6px;
}
.link-btn:hover { text-decoration: underline; }

/* ─── Productivity trend mini-chart ──────────────────────────────────── */
.trend-card { margin-bottom: 22px; }
.trend-chart {
  display: block; width: 100%; height: 80px;
  margin-top: 6px;
}
.trend-bar {
  fill: var(--saffron);
  transition: fill .2s, opacity .15s;
}
.trend-bar-good {
  fill: var(--teal-bright);
}
.trend-bar-warn {
  fill: var(--saffron-bright);
}
.trend-bar:hover { opacity: 0.85; }
.trend-empty {
  margin-top: 6px;
}

/* ─── Meetings section header + search ──────────────────────────────── */
.meetings-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin: 4px 0 12px; flex-wrap: wrap;
}
.search-meetings {
  max-width: 260px; min-height: 38px; padding: 8px 12px;
  font-size: 13px;
}
@media (max-width: 560px) {
  .search-meetings { max-width: 100%; width: 100%; }
}

/* ─── Inline empty states for dashboard cards ───────────────────────── */
.empty-state-mini {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 12px;
  color: var(--text-muted);
  background: rgba(255,255,255,0.015);
  border: 1px dashed var(--border);
  border-radius: var(--radius-xs);
  font-size: 12.5px; line-height: 1.45;
}
.empty-state-mini > :first-child {
  font-size: 14px; opacity: 0.75; flex-shrink: 0;
}

/* ─── Light theme override ──────────────────────────────────────────── */
/* Activated by adding `class="theme-light"` to <html> or <body>.
   Brand colors (saffron / teal / violet) stay; only neutrals invert. */
html.theme-light, body.theme-light {
  --bg:           #FAF9F5;
  --bg-2:         #FFFFFF;
  --surface:      rgba(15, 23, 42, 0.04);
  --surface-2:    rgba(15, 23, 42, 0.08);
  --surface-3:    rgba(15, 23, 42, 0.12);
  --border:       rgba(15, 23, 42, 0.10);
  --border-strong:rgba(15, 23, 42, 0.18);
  --text:         #1F2937;
  --text-muted:   #4B5563;
  --text-dim:     #6B7280;
}
/* In light mode, the dark gradient orbs in the background look weird
   (too much contrast). Lower their intensity. */
html.theme-light .bg-fx, body.theme-light .bg-fx { opacity: 0.45; }

/* The .grid-overlay (faint grid pattern on dark) needs a light-friendly
   tone and lower opacity */
html.theme-light .grid-overlay,
body.theme-light .grid-overlay {
  background-image:
    linear-gradient(rgba(15, 23, 42, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 23, 42, 0.08) 1px, transparent 1px);
  opacity: 0.5;
}

/* Theme toggle button in the nav */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s;
  font-size: 14px;
  line-height: 1;
}
.theme-toggle:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--text);
}
.theme-toggle:active { transform: scale(0.95); }
.theme-toggle .icon-sun, .theme-toggle .icon-moon { display: none; }
html:not(.theme-light) .theme-toggle .icon-moon { display: inline; }
html.theme-light .theme-toggle .icon-sun { display: inline; }
