:root {
  --bg: #f6f7f3;
  --paper: #fff;
  --sage: #e7ede4;
  --primary: #315d43;
  --ink: #24362c;
  --muted: #66736a;
  --line: #dfe5dc;
  --danger: #a23232;
  --radius: 18px;
  font:
    16px/1.6 Inter,
    "Segoe UI",
    "Microsoft YaHei",
    sans-serif;
  color: var(--ink);
  background: var(--bg);
}
.language-reminder {
  display: grid;
  gap: 10px;
}
#language-onboarding-form .language-options {
  max-height: 32vh;
  overflow-y: auto;
  padding: 4px;
}
.language-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 8px 16px;
}
#notes-editor {
  min-height: 45vh;
}
#live-status {
  position: sticky;
  top: 0;
  z-index: 8;
  background: var(--bg);
}
.home-quick {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.home-quick button {
  flex: 1;
  white-space: nowrap;
}
.full-notes > summary {
  padding: 14px 0;
  cursor: pointer;
  font-weight: 600;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
.site-footer {
  padding: 20px 24px calc(24px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 14px;
  color: var(--muted);
}
.site-footer nav,
.legal-navigation {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 18px;
}
.site-footer a,
.legal-navigation a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}
.site-footer p {
  margin: 0;
}
.site-footer p a + a {
  margin-left: 14px;
}
.legal-content {
  width: min(100%, 860px);
  margin: 0 auto;
  padding: 36px 24px;
  overflow-wrap: anywhere;
}
.legal-content header > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin-bottom: 18px;
}
.legal-navigation {
  justify-content: flex-start;
  margin: 12px 0;
}
.legal-content section {
  padding-top: 28px;
  margin-top: 24px;
  border-top: 1px solid var(--line);
  scroll-margin-top: 24px;
}
@media (max-width: 760px) {
  .site-footer {
    padding-bottom: calc(100px + env(safe-area-inset-bottom));
  }
  .legal-page .site-footer {
    padding-bottom: calc(24px + env(safe-area-inset-bottom));
  }
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
a,
input,
select,
textarea {
  touch-action: manipulation;
}
button {
  cursor: pointer;
  border: 1px solid var(--line);
  background: white;
  color: var(--ink);
  padding: 10px 17px;
  border-radius: 10px;
  min-height: 44px;
  font-weight: 600;
}
button:hover {
  background: var(--sage);
}
button.primary {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}
button.danger {
  color: var(--danger);
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
a {
  color: var(--primary);
}
:focus-visible {
  outline: 3px solid #8caf6e;
  outline-offset: 3px;
}
input,
select,
textarea {
  width: 100%;
  border: 1px solid #becbbd;
  border-radius: 10px;
  padding: 11px 12px;
  background: #fff;
  color: var(--ink);
  min-height: 46px;
}
textarea {
  min-height: 110px;
  resize: vertical;
}
label {
  display: grid;
  gap: 6px;
  font-size: 14px;
  font-weight: 600;
}
h1,
h2,
h3,
p {
  margin: 0 0 15px;
}
h1 {
  font-size: 30px;
  letter-spacing: -1px;
  line-height: 1.3;
}
h2 {
  font-size: 21px;
}
h3 {
  font-size: 17px;
}
.muted,
small {
  color: var(--muted);
}
small {
  font-size: 13px;
}
.shell {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  min-height: 100vh;
}
.sidebar {
  padding: 30px 20px;
  background: var(--sage);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 25px;
  position: sticky;
  top: 0;
  height: 100vh;
}
.brand {
  font-size: 25px;
  font-weight: 750;
  letter-spacing: 2px;
}
.brand small {
  display: block;
  letter-spacing: 0;
  font-size: 12px;
  font-weight: 400;
}
.nav {
  display: grid;
  gap: 7px;
}
.nav button {
  border: 0;
  background: transparent;
  text-align: left;
}
.nav button.active {
  background: white;
  box-shadow: 0 3px 12px #1f39200a;
}
.sidebar-bottom {
  margin-top: auto;
}
.workspace {
  font-size: 14px;
}
.main {
  padding: 32px 42px;
  max-width: 1600px;
  width: 100%;
  margin: auto;
}
.topbar,
.row,
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.topbar {
  margin-bottom: 34px;
}
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 6px;
}
.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 25px;
  margin-bottom: 20px;
}
.hero {
  background: var(--sage);
  padding: 30px;
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.two {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 1fr);
  gap: 22px;
}
.stack {
  display: grid;
  gap: 16px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 17px;
}
.full {
  grid-column: 1/-1;
}
.toolbar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
.toolbar input {
  max-width: 250px;
}
.meeting {
  transition:
    box-shadow 0.15s,
    transform 0.15s;
}
.meeting:hover {
  box-shadow: 0 8px 28px #24362c0c;
  transform: translateY(-2px);
}
.meeting h3 {
  margin: 13px 0;
}
.badge {
  display: inline-flex;
  padding: 3px 10px;
  border-radius: 30px;
  background: var(--sage);
  color: var(--primary);
  font-size: 12px;
  font-weight: 650;
}
.badge.warn {
  background: #fff0d7;
  color: #875d14;
}
.badge.live {
  background: #e0f4e6;
  color: #236e3f;
}
.meta {
  font-size: 13px;
  color: var(--muted);
}
.empty {
  text-align: center;
  padding: 55px 20px;
  color: var(--muted);
}
.empty h3 {
  color: var(--ink);
}
.tabs {
  display: flex;
  gap: 5px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 22px;
  overflow: auto;
}
.tabs button {
  white-space: nowrap;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.tabs button.active {
  border-bottom: 3px solid var(--primary);
  color: var(--primary);
}
.transcript {
  min-height: 260px;
  max-height: 65vh;
  overflow: auto;
  scroll-behavior: smooth;
}
.segment {
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 30px;
}
.segment:last-child {
  border: 0;
}
.segment-head {
  display: flex;
  gap: 9px;
  align-items: center;
  margin-bottom: 8px;
  font-size: 12px;
  color: var(--muted);
}
.segment-head button {
  min-height: 32px;
  padding: 3px 9px;
  font-size: 12px;
}
.translated {
  font-size: 18px;
  line-height: 1.8;
}
.segment details {
  font-size: 14px;
  color: var(--muted);
  margin-top: 7px;
}
.segment summary {
  cursor: pointer;
}
.segment.starred {
  border-left: 3px solid #b48a3c;
  padding-left: 14px;
}
.meter {
  display: flex;
  align-items: center;
  gap: 5px;
  height: 30px;
}
.meter i {
  display: block;
  width: 4px;
  height: 8px;
  background: #5d8062;
  border-radius: 3px;
  animation: wave 0.9s ease-in-out infinite alternate;
}
.meter i:nth-child(2n) {
  animation-delay: 0.3s;
}
.meter i:nth-child(3n) {
  animation-delay: 0.6s;
}
@keyframes wave {
  to {
    height: 26px;
  }
}
.recording-bar {
  display: flex;
  align-items: center;
  gap: 18px;
  justify-content: space-between;
  background: #eef3ea;
  padding: 16px 20px;
  border-radius: 12px;
  margin-bottom: 18px;
}
.notice {
  padding: 12px 16px;
  background: #fff5df;
  border: 1px solid #f0d7a4;
  border-radius: 10px;
  color: #73541d;
  margin-bottom: 16px;
  font-size: 14px;
}
.error {
  color: var(--danger);
  font-size: 14px;
}
.note-section {
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
  white-space: pre-wrap;
}
.note-section h3 {
  white-space: normal;
}
.price {
  font-size: 34px;
  line-height: 1.3;
  margin: 15px 0;
}
.price small {
  font-size: 14px;
}
.table-wrap {
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
th,
td {
  text-align: left;
  padding: 13px 10px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
th {
  color: var(--muted);
  font-weight: 500;
}
.login {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.login-story {
  background: var(--sage);
  padding: 10vw 7vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.login-story h1 {
  font-size: 48px;
  margin: 50px 0 24px;
  line-height: 1.35;
}
.login-form {
  padding: 40px;
  max-width: 480px;
  margin: auto;
  width: 100%;
}
.login-form form {
  display: grid;
  gap: 20px;
}
.login-form h2 {
  font-size: 28px;
  margin-bottom: 8px;
}
.login-form .muted {
  margin-bottom: 30px;
}
.steps {
  display: flex;
  gap: 15px;
  margin-top: 40px;
  font-size: 13px;
}
.steps span {
  border-top: 2px solid #afc3a6;
  padding-top: 12px;
  flex: 1;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  width: min(640px, calc(100% - 28px));
  max-height: 90vh;
  color: var(--ink);
  box-shadow: 0 20px 80px #152b2633;
}
dialog::backdrop {
  background: #172d2655;
  backdrop-filter: blur(3px);
}
dialog form {
  display: grid;
  gap: 18px;
}
dialog .dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
dialog .dialog-head h2 {
  margin: 0;
}
dialog .actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}
#toast {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  background: #263e30;
  color: #fff;
  border-radius: 12px;
  padding: 12px 22px;
  z-index: 100;
  max-width: calc(100% - 24px);
  box-shadow: 0 5px 20px #0002;
}
#toast:empty {
  display: none;
}
.loading {
  padding: 60px;
  text-align: center;
}
.mobile-brand {
  display: none;
}
.switch {
  display: flex;
  gap: 9px;
  align-items: center;
}
.switch input {
  width: 20px;
  min-height: 20px;
}
.source {
  font-size: 12px;
}
.qr {
  max-width: 240px;
  display: block;
  margin: auto;
}
.amount {
  font-variant-numeric: tabular-nums;
}
.link-button {
  border: 0;
  background: transparent;
  padding: 4px 0;
  min-height: 32px;
  text-decoration: underline;
}
.status-line {
  min-height: 22px;
  font-size: 13px;
}
.notes-content {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.account-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--sage);
  display: grid;
  place-items: center;
  font-weight: 700;
}
.title-wrap {
  min-width: 0;
}
.title-wrap h1 {
  overflow-wrap: anywhere;
}
.compact {
  margin: 0;
}
.hidden {
  display: none !important;
}
@media (max-width: 1050px) {
  .main {
    padding: 26px;
  }
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .two {
    grid-template-columns: 1fr;
  }
  .sidebar {
    width: 200px;
    padding: 25px 16px;
  }
  .shell {
    grid-template-columns: 200px minmax(0, 1fr);
  }
}
@media (max-width: 680px) {
  .shell {
    display: block;
  }
  .sidebar {
    position: static;
    width: 100%;
    height: auto;
    padding: 16px;
    gap: 14px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .sidebar .brand {
    font-size: 21px;
  }
  .sidebar .brand small,
  .sidebar-bottom {
    display: none;
  }
  .sidebar .nav {
    display: flex;
    overflow: auto;
    gap: 3px;
  }
  .nav button {
    white-space: nowrap;
    padding: 8px 12px;
    font-size: 14px;
  }
  .workspace {
    max-width: 100%;
  }
  .main {
    padding: 22px 16px 40px;
  }
  .topbar {
    margin-bottom: 22px;
    align-items: flex-start;
  }
  .topbar .muted {
    font-size: 13px;
  }
  .card {
    padding: 19px;
  }
  .hero {
    padding: 23px;
  }
  .grid,
  .form-grid {
    grid-template-columns: 1fr;
  }
  .full {
    grid-column: auto;
  }
  h1 {
    font-size: 25px;
  }
  .section-head {
    align-items: flex-start;
  }
  .recording-bar {
    flex-wrap: wrap;
    padding: 14px;
    gap: 10px;
  }
  .recording-bar .toolbar {
    width: 100%;
  }
  .recording-bar .toolbar button {
    flex: 1;
  }
  .login {
    display: block;
  }
  .login-story {
    padding: 27px;
  }
  .login-story h1 {
    font-size: 29px;
    margin: 25px 0 14px;
  }
  .login-story .steps {
    display: none;
  }
  .login-form {
    padding: 30px 24px;
  }
  .toolbar input {
    max-width: none;
    flex: 1;
    min-width: 140px;
  }
  .translated {
    font-size: 17px;
  }
  .topbar .account-name {
    display: none;
  }
  .row {
    flex-wrap: wrap;
  }
  .actions button {
    flex: 1;
  }
  .tabs button {
    font-size: 14px;
  }
  dialog {
    padding: 22px;
  }
  .price {
    font-size: 30px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
@media (max-width: 680px) {
  .segment-head {
    flex-wrap: wrap;
  }
  .segment-head button,
  .link-button {
    min-height: 44px;
  }
  .main {
    padding-bottom: calc(40px + env(safe-area-inset-bottom));
  }
  #toast {
    bottom: calc(20px + env(safe-area-inset-bottom));
  }
}
button:active {
  filter: brightness(0.94);
}
pre {
  font-family: inherit;
}
.bottom-nav,
.mobile-recording {
  display: none;
}
.home-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(270px, 1fr);
  gap: 24px;
}
.start-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 24px;
}
.home-heading {
  margin: 15px 0 28px;
}
.home-heading h1 {
  font-size: 36px;
}
.recent-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}
.recent-row:last-child {
  border: 0;
}
.jump-latest {
  position: sticky;
  bottom: 25px;
  display: block;
  margin: 0 auto 20px;
  background: var(--primary);
  color: white;
  z-index: 2;
}
.source-card {
  display: block;
  text-align: left;
  width: 100%;
  margin-bottom: 10px;
  font-weight: 400;
}
.notes-parallel {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 1fr);
  gap: 22px;
}
.source-reference {
  max-height: 75vh;
  overflow: auto;
}
.notes-parallel > .card {
  min-width: 0;
}
progress {
  width: 100%;
  height: 24px;
  accent-color: var(--primary);
}
@media (max-width: 1050px) {
  .home-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .home-grid > aside {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
  .notes-parallel {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 680px) {
  .sidebar .nav {
    display: none;
  }
  .sidebar {
    padding: 14px 16px;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 16px;
  }
  .sidebar .workspace {
    font-size: 12px;
  }
  .sidebar .workspace select {
    font-size: 13px;
    padding: 6px;
    min-height: 40px;
  }
  .sidebar .brand {
    white-space: nowrap;
  }
  .main {
    padding-bottom: calc(100px + env(safe-area-inset-bottom));
  }
  .bottom-nav {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 1px solid var(--line);
    z-index: 20;
    padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
    gap: 6px;
  }
  .bottom-nav button {
    border: 0;
    font-size: 14px;
    background: transparent;
    padding: 8px;
  }
  .bottom-nav button.active {
    background: var(--sage);
    color: var(--primary);
  }
  .mobile-recording {
    position: fixed;
    bottom: calc(70px + env(safe-area-inset-bottom));
    left: 12px;
    right: 12px;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 8px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 5px 24px #18372620;
    z-index: 19;
  }
  .mobile-recording button {
    font-size: 13px;
    padding: 8px 6px;
  }
  .main:has(.mobile-recording) {
    padding-bottom: calc(180px + env(safe-area-inset-bottom));
  }
  .home-heading h1 {
    font-size: 29px;
  }
  .home-grid > aside {
    display: block;
  }
  .start-grid {
    grid-template-columns: 1fr;
  }
  .notes-parallel .source-reference {
    max-height: 50vh;
  }
  .recording-bar .toolbar:last-child {
    display: none;
  }
  .jump-latest {
    bottom: 155px;
  }
  .home-grid {
    gap: 0;
  }
}
