:root {
  color-scheme: light;
  font-family: "Avenir Next", system-ui, sans-serif;
  color: #191b32;
  background: #f4f5fb;
  --ink: #191b32;
  --muted: #585d78;
  --line: #e4e6f1;
  --blue: #3842c9;
  --surface: #fff;
}
* { box-sizing: border-box }
body { margin: 0 }
button, input, select { font: inherit }
button, a { -webkit-tap-highlight-color: transparent }
button { cursor: pointer }
button:disabled { cursor: wait; opacity: .6 }
a { color: inherit; text-decoration: none }
:focus-visible { outline: 3px solid #6b70ed; outline-offset: 4px }
[hidden] { display: none !important }
.top {
  min-height: 72px;
  padding: 0 max(5vw, calc((100% - 1120px)/2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; font-size: 1.45rem; font-weight: 790; letter-spacing: -.055em }
.brand > span:last-child { color: var(--blue) }
.emblem {
  width: 35px; height: 35px; border-radius: 11px; margin-right: 10px;
  display: grid; grid-auto-flow: column; place-content: center; align-items: center; gap: 2px;
  background: var(--blue); color: #fff;
}
.emblem i, .wave i { display: block; border-radius: 99px; background: currentColor }
.emblem i { width: 3px; height: 11px }
.emblem i:nth-child(2) { height: 20px }
.emblem i:nth-child(3) { height: 14px }
.emblem i:nth-child(4) { height: 8px }
nav { display: flex; gap: clamp(14px, 4vw, 37px) }
.nav { font-size: .92rem; font-weight: 700; color: var(--muted) }
.nav:hover, .example:hover { text-decoration: underline }
main { width: min(1120px, 90%); margin: 35px auto 60px }
.intro { margin-bottom: 22px }
.date { margin: 0 0 6px; color: var(--muted); font-weight: 650; font-size: .94rem }
.date::first-letter { text-transform: uppercase }
h1, h2, h3, p { margin-top: 0 }
h1 { margin-bottom: 0; font-size: clamp(2.15rem, 5vw, 3.65rem); line-height: 1.04; letter-spacing: -.066em }
h2 { font-size: clamp(1.33rem, 3vw, 1.75rem); letter-spacing: -.043em; margin-bottom: 0 }
h3 { font-size: 1.13rem; letter-spacing: -.027em; margin-bottom: 10px }
.button { border: 0; border-radius: 12px; padding: 11px 15px; min-height: 44px; font-weight: 700; font-size: .91rem }
.secondary { background: #f5f5ff; border: 1px solid #dedff4; color: var(--blue) }
.secondary:hover { background: #ecebff }
.voice {
  position: relative; isolation: isolate; overflow: hidden; min-height: 235px;
  padding: 31px clamp(19px, 4vw, 42px) 25px; border-radius: 24px; color: #fff;
  background: radial-gradient(ellipse at 87% 55%, #5d62e4, transparent 62%), linear-gradient(116deg, #292eaa, #4148cc);
}
.voice-copy { position: relative; z-index: 1 }
.voice h2 { max-width: 22ch; font-size: clamp(1.54rem, 4vw, 2.37rem); line-height: 1.08; margin-bottom: 9px }
.voice-copy > p { color: #ecedff; line-height: 1.45; margin-bottom: 16px }
.voice-actions { display: flex; align-items: stretch; gap: 10px; flex-wrap: wrap }
.mic {
  display: inline-flex; gap: 10px; align-items: center; justify-content: center;
  min-height: 58px; padding: 0 19px; border: 0; border-radius: 14px;
  color: #2f35ae; background: #fff; font-weight: 800; box-shadow: 0 8px 22px #20207d52;
}
.mic:hover { background: #ecebff }
.mic[aria-pressed=true] { color: #932154; background: #ffe6f4 }
.mic svg { width: 23px; height: 23px }
.manual { color: #fff; border: 1px solid #ffffff64; background: #252a9c60 }
.manual:hover { background: #181e887f }
.voice-copy .voice-status { max-width: 520px; font-weight: 650; margin: 12px 0 0 }
.example { display: inline-block; margin: 10px 0 0; padding: 6px 0; color: #fff; background: none; border: 0; font-size: .88rem }
.voice-art { pointer-events: none; position: absolute; inset: 0 0 0 auto; width: min(44%, 460px); display: grid; place-items: center }
.voice-orbit {
  position: absolute; width: 145%; aspect-ratio: 1; border-radius: 50%; opacity: .6;
  background: repeating-radial-gradient(circle, transparent 0 28px, #b6baff30 29px 30px, transparent 31px 43px);
  mask-image: radial-gradient(circle, black 44%, transparent 69%);
}
.wave { display: flex; gap: clamp(4px, 1vw, 10px); height: 111px; align-items: center; color: #e0dcff; transform: rotate(-9deg) }
.wave i { width: clamp(4px, .75vw, 8px); height: 12%; opacity: .68 }
.wave i:nth-child(2n) { height: 24% }
.wave i:nth-child(3n) { height: 41% }
.wave i:nth-child(5), .wave i:nth-child(9) { height: 61% }
.wave i:nth-child(6), .wave i:nth-child(8) { height: 77%; opacity: .88 }
.wave i:nth-child(7) { height: 96%; opacity: 1 }
.overview, .journal { margin-top: 25px; scroll-margin-top: 12px }
.section-head, .journal-header { display: flex; gap: 12px; align-items: center; justify-content: space-between }
.section-head { margin-bottom: 12px }
.period { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: .875rem; font-weight: 650 }
select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #555b7d 50%), linear-gradient(135deg, #555b7d 50%, transparent 50%);
  background-position: calc(100% - 14px) 52%, calc(100% - 9px) 52%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
  padding-right: 25px !important;
}
.period select { width: auto; min-height: 40px; border-radius: 10px; font-size: .9rem; font-weight: 700; color: var(--ink) }
.analytics { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 14px; align-items: stretch }
.panel, .journal { border: 1px solid var(--line); background: var(--surface); border-radius: 21px; padding: clamp(17px,2.4vw,26px) }
.chart-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .98fr); align-items: center; gap: 10px }
.chart-label, #count, .today-total { font-size: .9rem; color: var(--muted) }
.chart-label { margin-bottom: 4px; font-weight: 670 }
.metric { display: block; color: var(--ink); font-size: clamp(1.65rem, 3.5vw, 2.8rem); line-height: 1.08; font-variant-numeric: tabular-nums; letter-spacing: -.065em; overflow-wrap: anywhere }
#count { margin: 7px 0 13px }
.today-total { margin: 0; display: flex; gap: 8px; flex-wrap: wrap; align-items: baseline }
.today-total strong { color: var(--ink) }
.donut { position: relative; width: min(100%, 210px); margin-inline: auto; aspect-ratio: 1 }
.donut canvas { display: block; width: 100%; height: auto }
.donut-center { position: absolute; inset: 0; display: grid; align-content: center; justify-items: center; line-height: 1.18 }
.donut-center strong { font-size: clamp(1.42rem, 4vw, 2.2rem); letter-spacing: -.06em }
.donut-center span { font-size: .78rem; color: var(--muted) }
.trend { display: grid; grid-template-columns: repeat(6,minmax(0,1fr)); gap: 5px; margin-top: 16px; border-top: 1px solid var(--line); padding-top: 12px }
.month {
  display: grid; grid-template-rows: 36px auto; gap: 5px; justify-items: center; align-items: end;
  width: 100%; border: 0; border-radius: 8px; padding: 4px; background: transparent; color: var(--muted); font-size: .79rem
}
.month:hover { background: #f4f4ff }
.month[aria-pressed=true] { color: var(--blue); font-weight: 790 }
.month-bar { width: min(100%, 36px); border-radius: 5px 5px 2px 2px; background: #c9cdef }
.month[aria-pressed=true] .month-bar { background: var(--blue) }
.breakdown h3 { margin-bottom: 9px }
.category {
  display: grid; grid-template-columns: 12px minmax(0,1fr) auto; align-items: center; gap: 10px;
  padding: 11px 0; border-bottom: 1px solid #eff0f6;
}
.category:last-child { border-bottom: 0 }
.swatch { width: 11px; height: 11px; border-radius: 50%; align-self: start; margin-top: 5px }
.category-detail { min-width: 0; overflow-wrap: anywhere; font-weight: 650 }
.share { display: block; width: 100%; height: 3px; border-radius: 4px; margin-top: 7px; background: #eef0f8 }
.share-fill { display: block; height: 100%; border-radius: inherit }
.category-total { min-width: 0; text-align: right; font-weight: 750; font-variant-numeric: tabular-nums }
.category-total small { display: block; font-size: .8rem; color: var(--muted); font-weight: 500 }
.empty { padding: 19px 13px; margin: 12px 0 0; color: var(--muted); background: #f5f6fc; border-radius: 12px; line-height: 1.45 }
.day { margin: 21px 0 3px; color: var(--muted); font-size: .89rem }
.entry {
  display: grid; width: 100%; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 10px;
  padding: 11px 6px; border: 0; border-bottom: 1px solid var(--line); background: none; text-align: left; color: var(--ink)
}
.entry:hover { background: #f6f6fd }
.entry > span { min-width: 0; overflow-wrap: anywhere }
.entry small { color: var(--muted); display: block; margin-top: 3px }
.entry > strong { white-space: nowrap; font-variant-numeric: tabular-nums }
dialog { width: min(calc(100% - 28px), 510px); border: 1px solid var(--line); border-radius: 21px; padding: 22px; color: var(--ink); background: var(--surface) }
dialog::backdrop { background: #171a43ac }
.dialog-top, .dialog-actions { display: flex; align-items: center; justify-content: space-between; gap: 9px }
.dialog-top h2 { margin: 0 }
.icon { border: 0; background: #f1f1fc; color: var(--ink); border-radius: 9px; font-size: 1.45rem; line-height: 1; width: 40px; height: 40px }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px }
.telegram { margin-top: 25px }
.telegram form { display: flex; flex-wrap: wrap; align-items: end; gap: 10px }
.telegram form label { flex: 1 1 220px }
.telegram-status { margin: 12px 0 }
form label { display: grid; gap: 6px; font-size: .9rem; font-weight: 650; margin-top: 14px }
input, select { min-width: 0; width: 100%; background-color: white; color: var(--ink); border: 1px solid #d6daed; border-radius: 9px; padding: 9px; min-height: 43px; font-size: 1rem }
.transcript { background: #f1f2fe; padding: 11px; border-radius: 9px; margin: 12px 0 0; overflow-wrap: anywhere }
.dialog-actions { justify-content: end; margin-top: 17px; flex-wrap: wrap }
.primary { background: var(--blue); color: white }
.primary:hover { background: #2933b2 }
.danger { margin-right: auto; background: #fcebf0; color: #8c2855 }
.form-error, .form-hint, .confirm-status { margin: 12px 0 0; font-size: .92rem }
.form-error { color: #8c2855 }
.form-hint { color: var(--muted) }
.confirm-status { color: var(--blue) }
@media (max-width: 760px) {
  main { margin-top: 26px }
  .analytics { grid-template-columns: 1fr; gap: 10px }
  .voice-art { opacity: .5; right: -5% }
  .donut { width: min(100%,180px) }
  .trend { margin-top: 11px }
}
@media (max-width: 480px) {
  .top { min-height: 60px }
  .voice { border-radius: 20px; min-height: auto; padding-top: 22px; padding-bottom: 14px }
  .voice-art { width: 58%; opacity: .21 }
  .mic { min-height: 55px; width: 100% }
  .manual { min-height: 38px; padding: 7px 10px; font-size: .86rem }
  .example { margin-top: 5px }
  .period { gap: 4px; font-size: .79rem }
  .period select { min-height: 36px; font-size: .82rem }
  .chart-main { grid-template-columns: minmax(0,1.12fr) minmax(0,.88fr) }
  .chart-panel { padding-inline: 15px }
}
@media (max-width: 380px) {
  .section-head { flex-wrap: wrap }
  .fields { grid-template-columns: minmax(0, 1fr); gap: 0 }
}

.entry .entry-income { color: #07856f }
