@font-face {
  font-family: DM;
  src: url("/font-regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: DM;
  src: url("/font-semibold.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}
:root {
  color-scheme: light;
  --paper: #f5f5ef;
  --surface: #fff;
  --ink: #202b29;
  --muted: #57645e;
  --line: #d9dfd7;
  --green: #205c43;
  --pale: #e4eee4;
  --amber: #82591c;
  --red: #963e34;
  --focus: #287d60;
  --radius: 14px;
  font-family: DM, sans-serif;
  background: var(--paper);
  color: var(--ink);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
textarea {
  font: inherit;
}
button,
a,
input,
textarea {
  -webkit-tap-highlight-color: transparent;
}
button {
  cursor: pointer;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 4px;
}
::selection {
  background: #c5dec5;
  color: #173e2d;
}
input,
textarea {
  caret-color: var(--green);
}
* {
  scrollbar-color: #a7b5a9 var(--paper);
  scrollbar-width: thin;
}
[hidden] {
  display: none !important;
}
a {
  color: var(--green);
  text-underline-offset: 4px;
}
p {
  line-height: 1.6;
  max-width: 65ch;
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-size: clamp(29px, 5vw, 38px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.15;
  text-wrap: balance;
}
h2 {
  font-size: 22px;
  letter-spacing: -0.02em;
}
h3 {
  font-size: 17px;
  font-weight: 600;
}
.app-shell {
  max-width: 680px;
  min-height: 100dvh;
  margin: auto;
  padding: 0 26px 110px;
}
.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 24px 0 32px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--ink);
}
.pilot {
  font-size: 10px;
  font-weight: 400;
  background: #e5e8e0;
  color: #46554b;
  border-radius: 5px;
  padding: 3px 5px;
  letter-spacing: 0;
}
.connection {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.connection::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #a2a89e;
  border-radius: 100%;
  margin-right: 6px;
}
.connection.online::before {
  background: var(--green);
}
.page-head {
  margin-bottom: 28px;
}
.page-head p {
  font-size: 14px;
  color: var(--muted);
  margin-top: 10px;
}
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 34px 0 16px;
}
.section-head span {
  font-size: 12px;
  color: var(--muted);
}
.navigation {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  width: min(680px, 100%);
  background: var(--paper);
  border-top: 1px solid var(--line);
  padding: 10px 16px calc(12px + env(safe-area-inset-bottom));
  z-index: 10;
}
.nav-item {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  min-height: 48px;
}
.nav-item[aria-current="page"] {
  color: var(--green);
  font-weight: 600;
}
.nav-item svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.count {
  position: absolute;
  top: -3px;
  left: calc(50% + 12px);
  font-size: 10px;
  background: var(--green);
  color: #fff;
  min-width: 17px;
  height: 17px;
  border-radius: 10px;
  padding: 2px 4px;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 48px;
  border: 0;
  border-radius: 11px;
  padding: 12px 19px;
  background: var(--green);
  color: #fff;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s;
}
.button:hover {
  background: #164731;
}
.button.secondary {
  background: #e7ebe3;
  color: var(--ink);
}
.button.secondary:hover {
  background: #dce3d7;
}
.button.quiet {
  background: transparent;
  color: var(--green);
  padding: 10px 0;
}
.button.wide {
  width: 100%;
}
.row-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.row-actions .button {
  flex: 1;
}
.muted {
  color: var(--muted);
  font-size: 13px;
}
.login {
  padding: 38px 0 20px;
}
.login p {
  margin-top: 17px;
  color: var(--muted);
}
.login form {
  margin-top: 34px;
}
.label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 9px;
}
.field {
  display: block;
  width: 100%;
  padding: 15px;
  border: 1px solid #a9b7aa;
  background: var(--surface);
  border-radius: 11px;
  font-size: 16px;
  color: var(--ink);
}
.field.code {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.login .button {
  margin-top: 14px;
}
.note {
  margin-top: 16px !important;
  font-size: 12px;
}
.notice {
  background: var(--pale);
  padding: 17px;
  border-radius: var(--radius);
  font-size: 13px;
  line-height: 1.55;
}
.notice p {
  margin-top: 5px;
}
.notice.warning {
  background: #f2ead7;
  color: #654a21;
}
.empty {
  padding: 46px 0 38px;
}
.empty .empty-mark {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--pale);
  display: grid;
  place-items: center;
  margin-bottom: 26px;
}
.empty svg {
  width: 28px;
  height: 28px;
  stroke: var(--green);
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.empty h2 {
  font-size: 26px;
  margin-bottom: 10px;
}
.empty p {
  color: var(--muted);
  font-size: 15px;
  max-width: 32ch;
}
.event-list {
  display: flex;
  flex-direction: column;
}
.event-row {
  width: 100%;
  text-align: left;
  border: 0;
  border-top: 1px solid var(--line);
  background: transparent;
  padding: 22px 0;
  display: grid;
  grid-template-columns: 1fr 20px;
  gap: 7px 18px;
  color: var(--ink);
}
.event-row:last-child {
  border-bottom: 1px solid var(--line);
}
.event-row:hover {
  background: #ebeee5;
}
.event-row .meta {
  display: flex;
  align-items: center;
  gap: 9px;
  grid-column: 1;
  font-size: 11px;
  color: var(--muted);
}
.event-row h3 {
  grid-column: 1;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.event-row .preview {
  grid-column: 1;
  font-size: 14px;
  line-height: 1.5;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
}
.event-row .chevron {
  grid-column: 2;
  grid-row: 1/4;
  align-self: center;
  font-size: 22px;
  color: var(--muted);
}
.source {
  font-weight: 600;
  color: var(--green);
}
.state {
  display: inline-block;
  font-size: 11px;
  border-radius: 5px;
  background: #e7ebe3;
  padding: 4px 7px;
  line-height: 1.3;
}
.state.pending {
  background: #f1e8d3;
  color: var(--amber);
}
.state.received {
  background: #e0ede0;
  color: var(--green);
}
.state.expired,
.state.cancelled {
  color: var(--red);
  background: #f3e4df;
}
.back {
  margin-bottom: 22px;
}
.detail-meta {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 15px 0 25px;
}
.message {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.65;
  font-size: 16px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}
.reply-form {
  margin-top: 28px;
}
.reply-form textarea {
  min-height: 130px;
  resize: vertical;
  line-height: 1.5;
}
.reply-tools {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.reply-tools .label {
  margin: 0;
}
.voice-button {
  border: 0;
  background: transparent;
  color: var(--green);
  font-size: 13px;
  padding: 12px 0;
}
.reply-content {
  white-space: pre-wrap;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 18px;
  margin-top: 18px;
  border: 1px solid var(--line);
  overflow-wrap: anywhere;
}
.reply-content small {
  display: block;
  color: var(--muted);
  margin-bottom: 9px;
}
.settings-section {
  padding: 24px 0;
  border-top: 1px solid var(--line);
}
.settings-section h2 {
  font-size: 18px;
  margin-bottom: 8px;
}
.settings-section p {
  font-size: 14px;
  color: var(--muted);
}
.steps {
  padding-left: 20px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--muted);
}
.test-result {
  font-size: 13px;
  margin-top: 15px;
}
.error {
  color: var(--red) !important;
  font-size: 13px;
  margin-top: 12px;
}
.toast {
  position: fixed;
  bottom: calc(98px + env(safe-area-inset-bottom));
  left: 50%;
  transform: translateX(-50%);
  width: min(90vw, 580px);
  background: var(--ink);
  color: #fff;
  padding: 14px 18px;
  border-radius: 11px;
  font-size: 14px;
  z-index: 20;
  box-shadow: 0 8px 24px #202b2926;
}
.token {
  word-break: break-all;
  font-family: DM, sans-serif;
  font-size: 12px;
  padding: 12px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.session-ref {
  margin-top: 20px;
  font-size: 11px;
  color: var(--muted);
  overflow-wrap: anywhere;
}
main {
  animation: arrive 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes arrive {
  from {
    transform: translateY(5px);
    filter: blur(1px);
  }
  to {
    transform: translateY(0);
    filter: blur(0);
  }
}
@media (max-width: 420px) {
  .app-shell {
    padding-left: 20px;
    padding-right: 20px;
  }
  .app-header {
    padding-top: 18px;
  }
  .brand {
    font-size: 16px;
  }
  .connection {
    font-size: 10px;
  }
  .pilot {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
@media (min-width: 900px) {
  .app-shell {
    padding-top: 20px;
  }
  .app-header {
    padding-bottom: 46px;
  }
  .navigation {
    border: 1px solid var(--line);
    border-bottom: 0;
    border-radius: 18px 18px 0 0;
  }
}
