:root {
  --ink: #0b0b0c;
  --paper: #ffffff;
  --mist: #f3f4f6;
  --line: #e9ebee;
  --line2: #dcdfe4;
  --gray: #55585f;
  --faint: #6e7178;
  --ghost: #b8bbc1;
  --accent: #2450ff;
  --accent-ink: #1d43db;
  --accent-bg: #e9eeff;
  --green: #11845b;
  --green-bg: #e3f3eb;
  --amber: #8a5a12;
  --amber-mid: #b07c10;
  --amber-bg: #fbf1dc;
  --terra: #c4321a;
  --terra-bg: #fde8e4;
  --blue: #1d43db;
  --blue-bg: #e9eeff;
  --sans:
    'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --serif: var(--sans);
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}
html,
body {
  height: 100%;
}
body {
  background: #f3f4f6;
  font-family: var(--sans);
  color: var(--ink);
  display: flex;
  justify-content: center;
}
#app {
  position: relative;
  width: 100%;
  max-width: 430px;
  height: 100dvh;
  background: var(--paper);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
button {
  font-family: var(--sans);
  border: none;
  background: none;
  cursor: pointer;
  color: inherit;
  text-align: left;
}
input,
textarea,
select {
  font-family: var(--sans);
  border: none;
  outline: none;
  background: none;
  color: var(--ink);
}
.serif {
  font-family: var(--serif);
}
.screen {
  position: absolute;
  inset: 0;
  background: var(--paper);
  display: none;
  flex-direction: column;
}
.screen.active {
  display: flex;
}
.pad {
  padding: 24px 22px;
}
.eyebrow {
  font-size: 11px;
  letter-spacing: 1.6px;
  color: var(--faint);
  text-transform: uppercase;
}
.h1 {
  font-family: var(--serif);
  font-size: 30px;
  line-height: 1.12;
  font-weight: 700;
  letter-spacing: -0.9px;
}
.h2 {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.4px;
}
.sub {
  font-size: 13.5px;
  color: var(--gray);
  line-height: 1.55;
}
.btn {
  display: block;
  width: 100%;
  text-align: center;
  font-size: 15px;
  font-weight: 600;
  padding: 15px 0;
  border-radius: 28px;
  transition: transform 0.12s;
}
.btn:active {
  transform: scale(0.98);
}
.btn-ink {
  background: var(--ink);
  color: #fff;
}
.btn-line {
  border: 1px solid var(--ink);
}
.btn-soft {
  border: 1px solid var(--line2);
  background: var(--paper);
}
.btn-accent {
  background: var(--accent);
  color: #fff;
}
.btn-sm {
  font-size: 13px;
  padding: 10px 0;
  border-radius: 20px;
}
.icon {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -4px;
}
.icon.lg {
  width: 24px;
  height: 24px;
}
.icon.sm {
  width: 15px;
  height: 15px;
  vertical-align: -2px;
}
.card {
  background: var(--mist);
  border: 1px solid transparent;
  border-radius: 20px;
  padding: 14px 16px;
}
.pill {
  font-size: 10px;
  border-radius: 20px;
  padding: 3px 9px;
  white-space: nowrap;
}
.pill.g {
  color: var(--green);
  background: var(--green-bg);
}
.pill.a {
  color: var(--amber);
  background: var(--amber-bg);
}
.pill.t {
  color: var(--terra);
  background: var(--terra-bg);
}
.pill.b {
  color: var(--blue);
  background: var(--blue-bg);
}
.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 9px;
  flex: none;
}
.row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.between {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.scroll {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 0 22px;
  scrollbar-width: none;
}
.scroll::-webkit-scrollbar {
  display: none;
}
.appbar {
  padding: 16px 18px 10px;
  flex: none;
}
#view {
  padding-bottom: 110px;
}
.tabbar {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: calc(12px + env(safe-area-inset-bottom));
  height: 64px;
  border-radius: 32px;
  background: var(--ink);
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 0 8px;
  z-index: 15;
  box-shadow: 0 10px 30px rgba(11, 11, 12, 0.18);
}
.tab {
  color: #8d9097;
  width: 48px;
  height: 48px;
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.tab.on {
  color: #fff;
  background: #26272b;
}
.tab .bdg {
  position: absolute;
  top: 6px;
  right: 5px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}
.tab.k {
  width: 58px;
  height: 58px;
  border-radius: 29px;
  background: #fff;
  color: var(--ink);
  margin-top: -26px;
  border: 4px solid #fff;
  box-shadow: 0 8px 22px rgba(11, 11, 12, 0.28);
  font-size: 27px;
  font-weight: 700;
  letter-spacing: -0.5px;
}
#kbar {
  display: none !important;
}
.statgrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}
.stat {
  border-radius: 11px;
  padding: 10px 12px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.1s;
}
.stat:active {
  transform: scale(0.97);
}
.stat .n {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 700;
}
.stat .l {
  font-size: 10.5px;
  margin-top: 1px;
}
.stat.sel {
  border-color: currentColor;
}
.listrow {
  border-bottom: 1px solid var(--line);
  padding: 13px 0;
  cursor: pointer;
  transition:
    background 0.12s,
    transform 0.1s;
}
.listrow:active {
  background: var(--mist);
  transform: scale(0.995);
}
.card {
  transition: transform 0.1s;
}
/* Keyboard focus ring for buttons and switches only. Text fields show focus on the field
   itself (.field, .ta below): a ring offset around the bare input looked like a stray box. */
button:focus-visible,
[role='switch']:focus-visible,
input[type='checkbox']:focus-visible,
input[type='radio']:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: none;
}
input,
textarea {
  caret-color: var(--accent);
}
::placeholder {
  color: var(--faint);
  opacity: 1;
}
.tab {
  transition: color 0.15s;
}
.chip {
  transition:
    background 0.15s,
    color 0.15s,
    border-color 0.15s;
}
.chip:active {
  transform: scale(0.97);
}
.tiercard {
  transition: transform 0.1s;
}
.tiercard:active {
  transform: scale(0.97);
}
#view {
  animation: viewIn 0.18s ease-out;
}
@keyframes viewIn {
  from {
    opacity: 0.4;
  }
  to {
    opacity: 1;
  }
}
/* Input fields: a soft filled box, 52px tall for a thumb; focused, it turns white with
   a cobalt edge and glow. Text is 16px: smaller makes iPhones zoom the page on tap. */
.field {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 52px;
  padding: 0 14px;
  margin-top: 6px;
  background: var(--mist);
  border: 1.5px solid transparent;
  border-radius: 14px;
  transition:
    background 0.15s,
    border-color 0.15s,
    box-shadow 0.15s;
}
.field:focus-within,
.field.focus {
  background: var(--paper);
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-bg);
}
.field input,
.field select,
.field textarea {
  flex: 1;
  min-width: 0;
  width: 100%; /* not the input's built-in ~20 characters, which overflowed two-column rows */
  align-self: stretch;
  font-size: 16px;
}
/* A picker in front of the text (the phone's country code) takes only its own width. */
.field select:not(:last-child) {
  flex: none;
}
.field select {
  -webkit-appearance: none;
  appearance: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2355585f' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E")
    right 2px center / 12px no-repeat;
  padding-right: 20px;
}
/* Several lines of text (paste a transcript, edit a draft): the same look as .field. */
.ta {
  display: block;
  width: 100%;
  margin-top: 6px;
  padding: 12px 14px;
  font-size: 16px;
  line-height: 1.5;
  background: var(--mist);
  border: 1.5px solid transparent;
  border-radius: 14px;
  resize: vertical;
  transition:
    background 0.15s,
    border-color 0.15s,
    box-shadow 0.15s;
}
.ta:focus {
  background: var(--paper);
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-bg);
}
/* Autofill (saved email, phone) keeps the field's colours instead of the browser's yellow. */
.field input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 40px var(--mist) inset;
  -webkit-text-fill-color: var(--ink);
}
.field:focus-within input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 40px var(--paper) inset;
}
/* The chat box: a pill, 16px, the same cobalt focus. */
#chatin {
  background: var(--mist);
  min-height: 46px;
  transition:
    background 0.15s,
    border-color 0.15s,
    box-shadow 0.15s;
}
#chatin:focus {
  background: var(--paper);
  border-color: var(--accent) !important; /* over the inline transparent border */
  box-shadow: 0 0 0 4px var(--accent-bg);
}
/* Home: ask Kandake (chat first) */
.askcard {
  background: var(--mist);
  border-radius: 26px;
  padding: 14px;
  margin: 2px 0 14px;
}
.askbox {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 50px;
  border-radius: 25px;
  background: var(--paper);
  padding: 0 16px;
  font-size: 15px;
  color: var(--faint);
  text-align: left;
}
.askmic {
  width: 50px;
  height: 50px;
  border-radius: 25px;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.askchips {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  overflow-x: auto;
  scrollbar-width: none;
}
.askchips::-webkit-scrollbar {
  display: none;
}
.askchips button {
  flex: none;
  height: 36px;
  padding: 0 15px;
  border-radius: 18px;
  border: 1px solid var(--line2);
  background: var(--paper);
  font-size: 13px;
  font-weight: 500;
}
.overlay {
  position: absolute;
  inset: 0;
  background: var(--paper);
  display: flex;
  flex-direction: column;
  transform: translateY(102%);
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  z-index: 20;
}
.overlay.open {
  transform: none;
}
.sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--paper);
  border-radius: 26px 26px 0 0;
  border-top: 1px solid var(--line2);
  padding: 20px 22px calc(24px + env(safe-area-inset-bottom));
  transform: translateY(105%);
  transition: transform 0.28s;
  z-index: 30;
  max-height: 85%;
  overflow-y: auto;
}
.sheet.open {
  transform: none;
}
.scrim {
  position: absolute;
  inset: 0;
  background: rgba(20, 20, 20, 0.32);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
  z-index: 25;
}
.scrim.on {
  opacity: 1;
  pointer-events: auto;
}
.drawer {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 78%;
  max-width: 320px;
  background: var(--paper);
  border-right: 1px solid var(--line2);
  z-index: 40;
  transform: translateX(-103%);
  transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
  display: flex;
  flex-direction: column;
  padding: 26px 0 18px;
}
.drawer.open {
  transform: none;
}
.ditem {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 24px;
  font-size: 14px;
  width: 100%;
}
.ditem:active {
  background: var(--mist);
}
.ditem .icon {
  color: var(--gray);
}
#toast {
  position: absolute;
  left: 50%;
  bottom: 96px;
  transform: translate(-50%, 20px);
  background: var(--ink);
  color: #fff;
  font-size: 12.5px;
  padding: 10px 18px;
  border-radius: 22px;
  opacity: 0;
  transition: all 0.3s;
  z-index: 60;
  pointer-events: none;
  max-width: 85%;
  text-align: center;
}
#toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}
.msg {
  max-width: 82%;
  font-size: 14.5px;
  line-height: 1.5;
  padding: 11px 15px;
  border-radius: 20px;
  margin-bottom: 10px;
  white-space: pre-line;
}
.msg.me {
  margin-left: auto;
  background: var(--ink);
  color: #fff;
  border-bottom-right-radius: 5px;
}
.msg.k {
  background: var(--mist);
  border-bottom-left-radius: 5px;
}
.msg.k .src {
  font-size: 10.5px;
  color: var(--faint);
  margin-top: 6px;
}
.typing span {
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--faint);
  margin-right: 3px;
}
.progress {
  height: 5px;
  background: var(--mist);
  border-radius: 3px;
  overflow: hidden;
}
.progress i {
  display: block;
  height: 100%;
  background: var(--green);
  border-radius: 3px;
}
.otp {
  display: flex;
  gap: 10px;
  justify-content: center;
}
.otp input {
  width: 52px;
  height: 60px;
  border: 1px solid var(--line2);
  border-radius: 11px;
  text-align: center;
  font-size: 24px;
  font-family: var(--serif);
}
.otp input:focus {
  border-color: var(--blue);
  border-width: 1.5px;
}
.sw {
  width: 42px;
  height: 25px;
  border-radius: 13px;
  background: var(--line2);
  position: relative;
  flex: none;
  transition: background 0.2s;
  cursor: pointer;
}
.sw::after {
  content: '';
  position: absolute;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: #fff;
  top: 3px;
  left: 3px;
  transition: left 0.2s;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}
.sw.on {
  background: var(--ink);
}
.sw.on::after {
  left: 20px;
}
.chip {
  font-size: 13px;
  font-weight: 500;
  border: 1px solid var(--line2);
  border-radius: 18px;
  padding: 8px 15px;
  cursor: pointer;
  background: var(--paper);
}
.chip.on {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
}
.tiercard {
  flex: none;
  width: 104px;
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 12px 10px;
  text-align: center;
  cursor: pointer;
  position: relative;
}
.tiercard .av {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--mist);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--gray);
  margin: 0 auto;
}
.hs {
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding: 4px 2px 6px;
  scrollbar-width: none;
}
.hs::-webkit-scrollbar {
  display: none;
}
.stepdots {
  display: flex;
  gap: 6px;
  justify-content: center;
}
.stepdots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--line2);
}
.stepdots i.on {
  background: var(--ink);
  width: 18px;
  border-radius: 3px;
}
.stepper {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--line2);
  border-radius: 9px;
  overflow: hidden;
}
.stepper button {
  width: 34px;
  height: 32px;
  text-align: center;
  font-size: 16px;
  color: var(--gray);
}
.stepper span {
  min-width: 86px;
  text-align: center;
  font-size: 13px;
  font-family: var(--serif);
}
.ring {
  transform-origin: 110px 110px;
}
@media (prefers-reduced-motion: no-preference) {
  @keyframes orbit {
    to {
      transform: rotate(360deg);
    }
  }
  @keyframes rise {
    from {
      opacity: 0;
      transform: translateY(10px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }
  @keyframes pulse {
    0%,
    100% {
      opacity: 0.35;
    }
    50% {
      opacity: 1;
    }
  }
  @keyframes blink {
    0%,
    100% {
      opacity: 1;
    }
    50% {
      opacity: 0.2;
    }
  }
  .ring {
    animation: orbit 15s linear infinite;
  }
  .rise {
    animation: rise 0.8s ease-out both;
  }
  .rise2 {
    animation: rise 0.8s ease-out both 0.25s;
  }
  .pulse {
    animation: pulse 1.4s ease-in-out infinite;
  }
  .typing span {
    animation: blink 1s infinite;
  }
  .typing span:nth-child(2) {
    animation-delay: 0.2s;
  }
  .typing span:nth-child(3) {
    animation-delay: 0.4s;
  }
}

/* Voice input: pulsing mic and a live level "wave" while listening */
.mic {
  border-radius: 50%;
  transition: background 0.2s;
}
.mic.mic-on {
  background: var(--accent-bg);
  animation: micpulse 1.4s ease-out infinite;
}
@keyframes micpulse {
  0% {
    box-shadow: 0 0 0 0 rgba(36, 80, 255, 0.45);
  }
  100% {
    box-shadow: 0 0 0 14px rgba(36, 80, 255, 0);
  }
}
.wave {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 20px;
}
.wave i {
  display: block;
  width: 3px;
  height: 6px;
  border-radius: 2px;
  background: var(--wc, var(--accent));
  animation: wave 1s ease-in-out infinite;
}
.wave i:nth-child(2) {
  animation-delay: 0.12s;
}
.wave i:nth-child(3) {
  animation-delay: 0.24s;
}
.wave i:nth-child(4) {
  animation-delay: 0.36s;
}
.wave i:nth-child(5) {
  animation-delay: 0.48s;
}
@keyframes wave {
  0%,
  100% {
    height: 5px;
  }
  50% {
    height: 18px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .mic.mic-on,
  .wave i {
    animation: none;
  }
  .wave i {
    height: 12px;
  }
}

/* Recording indicator: a pulsing red dot */
.recdot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--terra);
  animation: recdot 1.2s ease-in-out infinite;
}
@keyframes recdot {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
@media (prefers-reduced-motion: reduce) {
  .recdot {
    animation: none;
  }
}

/* Splash into the next screen as one motion (splashTo() in app.js): the logo glides to
   its place (0.34 s, ease-out), the wordmark and tagline fade, then the headline,
   subline, buttons and footer fade in 70 ms apart (about 0.75 s in all). Reduced
   motion: a plain cross-fade. */
#scr-splash {
  transition:
    background-color 0.34s ease-out,
    opacity 0.3s ease-out;
}
#scr-splash.leaving {
  background-color: transparent;
  pointer-events: none;
}
#scr-splash.leaving.fade {
  opacity: 0;
}
#scr-splash.leaving #splash-logo {
  transition: transform 0.34s cubic-bezier(0.2, 0.8, 0.2, 1);
}
#scr-splash.leaving .rise,
#scr-splash.leaving .rise2 {
  animation: none;
  transition: opacity 0.2s ease-out;
  opacity: 0;
}
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.screen.arriving .wl1 {
  animation: fadeUp 0.24s ease-out both 0.3s;
}
.screen.arriving .wl2 {
  animation: fadeUp 0.24s ease-out both 0.37s;
}
.screen.arriving .wl3 {
  animation: fadeUp 0.24s ease-out both 0.44s;
}
.screen.arriving .wl4 {
  animation: fadeUp 0.24s ease-out both 0.51s;
}
.screen.arriving.calm .wl1,
.screen.arriving.calm .wl2,
.screen.arriving.calm .wl3,
.screen.arriving.calm .wl4 {
  animation: fadeIn 0.3s ease-out both;
}

/* The bell (top right) */
.bell {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 20px;
  background: var(--mist);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.bell-dot {
  position: absolute;
  top: 4px;
  right: 3px;
  min-width: 17px;
  height: 17px;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--paper);
}
.notif {
  display: flex;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  width: 100%;
  text-align: left;
}
.notif .ni {
  width: 36px;
  height: 36px;
  border-radius: 18px;
  background: var(--mist);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  color: var(--gray);
}
.notif.new .ni {
  background: var(--accent-bg);
  color: var(--accent-ink);
}

/* Home: the briefing (dark), Needs you (one row per thing), at a glance */
.brief {
  background: var(--ink);
  color: #fff;
  border-radius: 26px;
  padding: 18px 18px 16px;
  margin-bottom: 14px;
}
.brief .lbl {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.4px;
  color: #8fa6ff;
}
.brief .hl {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.3px;
  margin-top: 8px;
}
.brief .bchips {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.brief .bchip {
  font-size: 12px;
  font-weight: 600;
  color: #e6e8ec;
  background: #1e1f23;
  border-radius: 14px;
  padding: 6px 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.brief .bchip.warn {
  color: #ffb4a6;
}
.brief .bact {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  align-items: center;
}
.brief .bbtn {
  height: 38px;
  padding: 0 14px;
  border-radius: 19px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.brief .bbtn.ghost {
  background: #1e1f23;
  color: #fff;
}
.brief .bround {
  width: 38px;
  height: 38px;
  border-radius: 19px;
  background: #1e1f23;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.brief .bsec {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  color: #8d9097;
  margin: 14px 0 4px;
}
.brief .bli {
  font-size: 13.5px;
  line-height: 1.5;
  margin-top: 5px;
  color: #e6e8ec;
}
.brief .bli b {
  color: #fff;
}
.needs {
  background: var(--mist);
  border-radius: 22px;
  padding: 2px 14px;
}
.needrow {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  width: 100%;
  text-align: left;
}
.needrow:last-child {
  border-bottom: 0;
}
.needrow .nic {
  width: 38px;
  height: 38px;
  border-radius: 19px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.needrow .nt {
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.3;
}
.needrow .ns {
  font-size: 12.5px;
  color: var(--gray);
  margin-top: 2px;
  line-height: 1.35;
}
/* Chat: a flight as a boarding pass */
.fk {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--gray);
}
.fc {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.5px;
  line-height: 1.1;
}
.ft {
  font-size: 12px;
  color: var(--gray);
  margin-top: 2px;
}
.fline {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent);
}
.fline i {
  flex: 1;
  border-top: 1.5px dashed var(--ghost);
}
.fsep {
  border-top: 1.5px dashed var(--line2);
  margin: 14px -16px 12px;
}
.fp {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.4px;
}
.sthumb {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  object-fit: cover;
  flex: none;
  background: var(--line);
}
/* Portfolio: the split in one bar, then the list with funding bars */
.psum {
  background: var(--mist);
  border-radius: 24px;
  padding: 16px;
  margin-top: 4px;
}
.pbar {
  display: flex;
  height: 12px;
  border-radius: 6px;
  overflow: hidden;
  gap: 3px;
}
.pcounts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
  margin-top: 12px;
}
.pcounts button {
  text-align: left;
  border-radius: 14px;
  padding: 6px 6px 6px 4px;
}
.pcounts button.sel {
  background: var(--paper);
}
.pcounts .pn {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.5px;
}
.pcounts .pl {
  font-size: 12px;
  color: var(--gray);
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 1px;
}
.pcounts .pl i {
  width: 7px;
  height: 7px;
  border-radius: 4px;
  display: inline-block;
}
.psearch {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 48px;
  border-radius: 24px;
  background: var(--mist);
  padding: 0 16px;
  margin-top: 10px;
}
.plist {
  background: var(--mist);
  border-radius: 24px;
  padding: 2px 16px;
  margin-top: 10px;
}
.prow {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.prow:last-child {
  border-bottom: 0;
}
.prow .pfb {
  flex: 1;
  height: 6px;
  border-radius: 3px;
  background: var(--line);
  overflow: hidden;
  display: flex;
}
/* Travel: three tiles, then what's coming up */
.ttiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 4px 0 6px;
}
.ttile {
  height: 108px;
  border-radius: 24px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--mist);
  text-align: left;
}
.ttile.dark {
  background: var(--ink);
  color: #fff;
}
.ttile .tl {
  font-size: 15px;
  font-weight: 700;
}
.upcard {
  background: var(--mist);
  border-radius: 24px;
  padding: 16px;
  margin-top: 10px;
}
.upcard .uk {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.1px;
  color: var(--gray);
}
.upcard .ut {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.3px;
  margin-top: 6px;
}
.upcard .us {
  font-size: 13px;
  color: var(--gray);
  margin-top: 3px;
}
/* Approvals: one decision per card */
.seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 4px;
  background: var(--mist);
  border-radius: 22px;
  padding: 4px;
  margin: 4px 0 6px;
}
.seg button {
  height: 36px;
  border-radius: 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--gray);
  text-align: center;
}
.seg button.on {
  background: var(--paper);
  color: var(--ink);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(11, 11, 12, 0.08);
}
.apcard {
  background: var(--mist);
  border-radius: 24px;
  padding: 18px;
  margin-top: 12px;
}
.apcard .aphead {
  display: flex;
  align-items: center;
  gap: 9px;
}
.apcard .apic {
  width: 32px;
  height: 32px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  background: var(--paper);
}
.apcard .apkind {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.1px;
  flex: 1;
  min-width: 0;
}
.apcard .apamt {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -1px;
  margin-top: 12px;
}
.apcard .aptitle {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 8px;
}
.apcard .apsub {
  font-size: 13px;
  color: var(--gray);
  margin-top: 4px;
  line-height: 1.45;
}
.apcard .apnote {
  font-size: 12px;
  margin-top: 8px;
  line-height: 1.45;
}
.apcard .apbtns {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}
.apcard .apbtns .btn {
  padding: 13px 0;
  font-size: 14.5px;
}
.glance {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 10px;
}
.glance button {
  background: var(--mist);
  border-radius: 18px;
  padding: 12px;
  text-align: left;
}
.glance .gn {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.5px;
}
.glance .gl {
  font-size: 12px;
  color: var(--gray);
  margin-top: 2px;
}

/* Legibility across every screen (2026-10-18): the old 10.5-12px grey text was tiring to read.
   Inline sizes in the screens are lifted one step; captions stay smaller than body text. */
#view [style*='font-size:10px'],
#view [style*='font-size:10.5px'] {
  font-size: 12px !important;
}
#view [style*='font-size:11px'] {
  font-size: 12.5px !important;
}
#view [style*='font-size:11.5px'] {
  font-size: 13px !important;
}
#view [style*='font-size:12px'] {
  font-size: 13px !important;
}
#view [style*='font-size:12.5px'] {
  font-size: 14px !important;
}
#view [style*='font-size:13px'] {
  font-size: 14.5px !important;
}
#view [style*='font-size:13.5px'] {
  font-size: 15px !important;
}
#view [style*='color:var(--faint)'] {
  color: var(--gray) !important;
}
.eyebrow {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 1.3px;
  color: var(--gray);
}
.listrow {
  padding: 14px 0;
}
.tiercard {
  background: var(--mist);
  border-color: transparent;
  border-radius: 20px;
}
.tiercard .av {
  background: var(--paper);
}
.pill {
  font-weight: 600;
}
.stepper {
  border-radius: 20px;
}
.sheet .sub {
  font-size: 14px;
}
/* Big secondary actions inside the app (Import, Upload, Add a promise…): soft, not outlined.
   The Welcome and sign-in screens keep their outlined buttons. */
#view .btn-line {
  border-color: transparent;
  background: var(--mist);
}
#view .btn-line:active {
  background: var(--line);
}

/* A button that is working: its label gives way to a spinner (see busyStart in app.js). */
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.btn.loading {
  position: relative;
  color: transparent !important;
  pointer-events: none;
}
.btn.loading svg {
  visibility: hidden;
}
.btn.loading::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border-radius: 50%;
  border: 2px solid var(--spin, #fff);
  border-right-color: transparent;
  animation: spin 0.7s linear infinite;
}
.btn-soft.loading,
.btn-line.loading,
#view .btn-line.loading {
  --spin: var(--ink);
}
@media (prefers-reduced-motion: reduce) {
  .btn.loading::after {
    animation-duration: 1.6s;
  }
}

/* Kandake Shield: the scam warning on a payment card */
.riskbox {
  border: 1.5px solid var(--amber);
  border-radius: 14px;
  padding: 12px 13px;
  margin-top: 10px;
  background: var(--paper);
}
.riskbox.hi {
  background: color-mix(in srgb, var(--terra) 6%, var(--paper));
}
.riskhd {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
}
.riskbox ul {
  margin: 8px 0 0;
  padding-left: 18px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--ink);
}
.riskbox li {
  margin: 3px 0;
}
.riskbox li.good {
  list-style: none;
  margin-left: -18px;
  color: var(--green);
}
.riskadv {
  font-size: 12.5px;
  line-height: 1.5;
  margin-top: 8px;
  color: var(--ink);
  font-weight: 600;
}
.riskbtns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.riskbtns .btn {
  flex: 1;
  min-width: 0;
  padding: 9px 10px;
  font-size: 12.5px;
  width: auto;
  text-decoration: none;
  text-align: center;
}
.riskfoot {
  font-size: 10.5px;
  color: var(--faint);
  margin-top: 8px;
}

/* Kandake Shield: the travel safety report */
.sfcard {
  background: var(--paper);
  border: 1.5px solid var(--line2);
  border-left-width: 5px;
  border-radius: 16px;
  padding: 14px 14px 12px;
}
.sfk {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--gray);
}
.sfpill {
  display: inline-block;
  color: #fff;
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
}
.sfplace {
  font-size: 19px;
  font-weight: 700;
  margin-top: 8px;
  line-height: 1.25;
}
.sfplace span {
  font-weight: 500;
  color: var(--gray);
}
.sfdates {
  font-size: 12px;
  color: var(--faint);
  margin-top: 2px;
}
.sfhead {
  font-size: 13.5px;
  line-height: 1.45;
  margin-top: 10px;
  font-weight: 600;
}
.sfsec {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}
.sfst {
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--ink);
}
.sfdot {
  width: 8px;
  height: 8px;
  border-radius: 4px;
  flex: none;
}
.sfit {
  font-size: 12.5px;
  line-height: 1.45;
  margin-top: 6px;
  color: var(--ink);
}
.sfsrc {
  font-size: 11px;
  color: var(--faint);
  margin-top: 2px;
}
.sfsrc a {
  color: var(--accent-ink);
  text-decoration: none;
}
.sful {
  margin: 6px 0 0;
  padding-left: 18px;
  font-size: 12.5px;
  line-height: 1.5;
}
.sful li {
  margin: 3px 0;
}
.sfhelp {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  margin-top: 6px;
}
.sfnums {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.sfnums a,
.sfnums span {
  font-size: 12px;
  font-weight: 600;
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--mist);
  color: var(--ink);
  text-decoration: none;
}
.sfnote {
  font-size: 12px;
  color: var(--amber);
  margin-top: 10px;
  font-weight: 600;
}
.sffoot {
  font-size: 10.5px;
  color: var(--faint);
  margin-top: 10px;
  line-height: 1.45;
}

/* Kandake Shield: SOS */
.sosdot {
  width: 34px;
  height: 34px;
  border-radius: 17px;
  background: var(--terra);
  color: #fff;
  font-size: 10.5px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
  letter-spacing: 0.02em;
}
.sosbig {
  width: 150px;
  height: 150px;
  border-radius: 75px;
  background: var(--terra);
  color: #fff;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0.04em;
  border: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  box-shadow: 0 0 0 10px color-mix(in srgb, var(--terra) 14%, transparent);
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  touch-action: none;
  transition: transform 0.15s;
}
.sosbig span {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  opacity: 0.85;
  margin-top: 2px;
  text-transform: uppercase;
}
.sosbig.holding {
  transform: scale(0.94);
  animation: soshold 2s linear forwards;
}
@keyframes soshold {
  from {
    box-shadow: 0 0 0 10px color-mix(in srgb, var(--terra) 14%, transparent);
  }
  to {
    box-shadow: 0 0 0 26px color-mix(in srgb, var(--terra) 40%, transparent);
  }
}
.sosbig.on {
  width: 110px;
  height: 110px;
  font-size: 28px;
  animation: sospulse 1.4s ease-in-out infinite;
}
@keyframes sospulse {
  50% {
    box-shadow: 0 0 0 18px color-mix(in srgb, var(--terra) 22%, transparent);
  }
}
.sosol {
  margin: 12px 0 10px;
  padding-left: 20px;
  font-size: 13px;
  line-height: 1.55;
}
.sosol li {
  margin: 6px 0;
}
@media (prefers-reduced-motion: reduce) {
  .sosbig.on,
  .sosbig.holding {
    animation: none;
  }
}

/* Kandake's voice picker */
.vplay {
  width: 36px;
  height: 36px;
  border-radius: 18px;
  border: 0;
  background: var(--ink);
  color: var(--paper);
  font-size: 13px;
  flex: none;
  cursor: pointer;
}

/* Signature & stamp (public/sign.js) */
.pickgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.pickbtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 14px 8px;
  border: 1.5px solid var(--line2);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
}
.pickbtn:active {
  background: var(--mist);
}
.checker {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  border-radius: 14px;
  margin-top: 12px;
  border: 1px solid var(--line);
  background-color: #fff;
  background-image:
    linear-gradient(45deg, #e9ebef 25%, transparent 25%), linear-gradient(-45deg, #e9ebef 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #e9ebef 75%), linear-gradient(-45deg, transparent 75%, #e9ebef 75%);
  background-size: 16px 16px;
  background-position:
    0 0,
    0 8px,
    8px -8px,
    -8px 0;
}
.checker.paper {
  background-image: none;
  background-color: #fff;
}
.cropwrap {
  position: relative;
  margin-top: 10px;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  max-width: 640px;
}
.cropwrap canvas {
  display: block;
  border-radius: 10px;
}
.cropbox {
  position: absolute;
  border: 2px solid var(--accent);
  box-shadow: 0 0 0 9999px rgba(11, 11, 12, 0.45);
  border-radius: 4px;
  cursor: move;
  touch-action: none;
}
.cropbox i {
  position: absolute;
  width: 26px;
  height: 26px;
  margin: -13px;
  border-radius: 13px;
  background: #fff;
  border: 2px solid var(--accent);
}
.cropbox i[data-c='nw'] {
  left: 0;
  top: 0;
}
.cropbox i[data-c='ne'] {
  right: 0;
  top: 0;
  margin-right: -13px;
}
.cropbox i[data-c='sw'] {
  left: 0;
  bottom: 0;
  margin-bottom: -13px;
}
.cropbox i[data-c='se'] {
  right: 0;
  bottom: 0;
  margin: 0 -13px -13px 0;
}
.padwrap {
  position: relative;
  margin-top: 10px;
  background: #fff;
  border: 1.5px solid var(--line2);
  border-radius: 14px;
  height: 220px;
  overflow: hidden;
}
.padwrap canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  touch-action: none;
  z-index: 1;
}
.padline {
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 28%;
  border-bottom: 1.5px dashed #c5c9d1;
}
.plscroll {
  overflow: auto;
  border-radius: 12px;
  background: var(--mist);
  padding: 8px;
  max-height: 72vh;
  -webkit-overflow-scrolling: touch;
}
.plpage {
  position: relative;
  margin: 0 auto;
  min-width: 100%;
}
.plcanvas {
  position: relative;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}
.pdfpage {
  display: block;
  width: 100%;
  height: auto;
  background: #fff;
}
#mk-page .pdfpage {
  border-radius: 6px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.12);
}
.plmark {
  position: absolute;
  z-index: 2;
  cursor: grab;
  touch-action: none;
  outline: 1.5px dashed var(--accent);
  outline-offset: 4px;
  border-radius: 2px;
}
.plmark img {
  display: block;
  width: 100%;
  height: auto;
  mix-blend-mode: multiply;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}
.plmark.dragging {
  cursor: grabbing;
  outline-style: solid;
}
.plmark:focus-visible {
  outline: 2.5px solid var(--accent);
}
.plmark i {
  position: absolute;
  width: 24px;
  height: 24px;
  border-radius: 12px;
  background: #fff;
  border: 2px solid var(--accent);
  touch-action: none;
}
.plmark .plh-size {
  right: -16px;
  bottom: -16px;
  cursor: nwse-resize;
}
.plmark .plh-rot {
  left: 50%;
  top: -34px;
  margin-left: -12px;
  cursor: grab;
}
.plmark .plh-rot::after {
  content: '';
  position: absolute;
  left: 9px;
  top: 22px;
  width: 2px;
  height: 10px;
  background: var(--accent);
}
