/* 极简打卡 —— 一屏、两个页面、没有导航栏 */

:root {
    --bg: #f2f2f7;
    --card: #ffffff;
    --text: #000000;
    --muted: #8e8e93;
    --faint: #c7c7cc;
    --sep: #e5e5ea;
    --accent: #34c759;
    --defer: #f06292;
    --radius: 14px;
    --tap: 52px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #000000;
        --card: #1c1c1e;
        --text: #ffffff;
        --muted: #8e8e93;
        --faint: #3a3a3c;
        --sep: #2c2c2e;
        --accent: #30d158;
    }
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html,
body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
}

body {
    font: 17px/1.35 -apple-system, BlinkMacSystemFont, "SF Pro Text",
        "PingFang SC", "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.app {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100dvh;
    padding: calc(env(safe-area-inset-top) + 10px) 16px
        calc(env(safe-area-inset-bottom) + 16px);
    display: flex;
    flex-direction: column;
}

/* ── 顶栏 ── */

.topbar {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-height: 44px;
}

.seg {
    display: inline-flex;
    padding: 2px;
    background: var(--sep);
    border-radius: 9px;
    flex: 0 0 auto;
    margin-top: 4px;
}

.seg button {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--muted);
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 7px;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.seg button[aria-selected="true"] {
    background: var(--card);
    color: var(--text);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

/* 笔记入口：和分段控件隔开，独立一颗 */
.notebtn {
    appearance: none;
    border: 0;
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    margin: 4px 0 0 12px;
    padding: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--muted);
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.notebtn svg {
    width: 19px;
    height: 19px;
}

.notebtn[aria-pressed="true"] {
    background: var(--card);
    color: var(--text);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.headline {
    flex: 1 1 auto;
    min-width: 0;
    text-align: right;
}

.date {
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

.sub {
    font-size: 13px;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
    margin-top: 2px;
    white-space: nowrap;
}

/* ── 进度条 ── */

.progress {
    height: 4px;
    border-radius: 2px;
    background: var(--sep);
    margin: 12px 0 18px;
    overflow: hidden;
}

.progress i {
    display: block;
    height: 100%;
    width: 0;
    border-radius: 2px;
    background: var(--accent);
    transition: width 0.28s cubic-bezier(0.34, 1.36, 0.64, 1);
}

.progress.hidden {
    visibility: hidden;
}

/* ── 列表卡片 ── */

.card {
    background: var(--card);
    border-radius: var(--radius);
    overflow: hidden;
}

.row {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: var(--tap);
    padding: 8px 14px;
    border: 0;
    width: 100%;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.row + .row {
    border-top: 1px solid var(--sep);
}

.row:active {
    background: color-mix(in srgb, var(--sep) 55%, transparent);
}

.row .names {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.row .name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: opacity 0.15s ease;
}

.row .subnote {
    font-size: 12px;
    color: var(--muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.moodbadge {
    flex: 0 0 auto;
    width: 28px;
    height: 28px;
    padding: 0;
    border-radius: 50%;
    border: 1.5px solid var(--m);
    background: color-mix(in srgb, var(--m) 16%, transparent);
    font-size: 15px;
    line-height: 1;
    display: grid;
    place-items: center;
    cursor: pointer;
}

.row.on .name {
    opacity: 0.55;
}

.row .val {
    flex: 0 0 auto;
    font-variant-numeric: tabular-nums;
    color: var(--muted);
    font-size: 16px;
}

.row .skip {
    flex: 0 0 auto;
    font-size: 13px;
    color: var(--defer);
    font-weight: 600;
}

/* 圆圈 */

.tick {
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1.5px solid var(--faint);
    display: grid;
    place-items: center;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.tick svg {
    width: 13px;
    height: 13px;
    opacity: 0;
    transform: scale(0.6);
    transition: opacity 0.15s ease, transform 0.2s cubic-bezier(0.34, 1.36, 0.64, 1);
}

.row.on .tick {
    background: var(--accent);
    border-color: var(--accent);
}

.row.on .tick svg {
    opacity: 1;
    transform: scale(1);
}

/* ── 分区标题 ── */

.section {
    margin: 22px 0 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--muted);
    letter-spacing: 0.02em;
    padding-left: 4px;
}

/* ── 近 7 天 ── */

.days {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
}

.days .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--sep);
}

.days .dot.partial {
    background: color-mix(in srgb, var(--accent) 45%, var(--sep));
}

.days .dot.full {
    background: var(--accent);
}

.days .dot.today {
    outline: 2px solid color-mix(in srgb, var(--text) 22%, transparent);
    outline-offset: 3px;
}

.days .label {
    margin-left: auto;
    font-size: 13px;
    color: var(--muted);
}

/* ── 训练页 ── */

.workout-row .name {
    flex: 1 1 auto;
}

.workout-row .kg {
    color: var(--text);
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    font-size: 16px;
    min-width: 66px;
    text-align: right;
}

.workout-row .reps {
    color: var(--muted);
    font-variant-numeric: tabular-nums;
    font-size: 15px;
    min-width: 60px;
    text-align: right;
}

.scroller {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 -4px;
}

table.history {
    border-collapse: separate;
    border-spacing: 0;
    width: max-content;
    min-width: 100%;
    font-size: 13px;
    font-variant-numeric: tabular-nums;
}

table.history th,
table.history td {
    padding: 9px 10px;
    text-align: right;
    white-space: nowrap;
}

table.history th:first-child,
table.history td:first-child {
    text-align: left;
    position: sticky;
    left: 0;
    background: var(--card);
}

table.history thead th {
    color: var(--muted);
    font-weight: 600;
    font-size: 12px;
    border-bottom: 1px solid var(--sep);
}

table.history tbody tr + tr td {
    border-top: 1px solid var(--sep);
}

table.history td.miss {
    color: color-mix(in srgb, var(--muted) 45%, transparent);
}

table.history tbody tr.yearrow td {
    background: var(--bg);
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    border-top: 1px solid var(--sep);
}

table.history tbody tr.yearrow td:first-child {
    background: var(--bg);
}

.wpickdot {
    fill: none;
    stroke: var(--accent);
    stroke-width: 2;
}

table.history th:last-child,
table.history td:last-child {
    padding-right: 16px;
}

/* ── 训练：今天的表单 ── */

.wrow {
    position: relative;
    overflow: hidden;
    touch-action: pan-y;
}

.wrow + .wrow {
    border-top: 1px solid var(--sep);
}

.wrow-slide {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 4px;
    min-height: 54px;
    padding: 4px 6px 4px 14px;
    background: var(--card);
    transition: transform 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.wname {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 15px;
}

.win {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    background: transparent;
    color: var(--text);
    font: inherit;
    font-variant-numeric: tabular-nums;
    text-align: right;
    padding: 8px 6px;
    border-radius: 7px;
}

.win:focus {
    outline: none;
    background: color-mix(in srgb, var(--sep) 62%, transparent);
}

.win.w {
    width: 74px;
    font-size: 17px;
    font-weight: 600;
}

.win.r {
    width: 84px;
    font-size: 16px;
    color: var(--muted);
}

.unit {
    font-size: 12px;
    color: var(--muted);
    margin-right: 2px;
}

.addrow {
    border-top: 1px solid var(--sep);
}

.addbtn {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--accent);
    font: inherit;
    font-size: 15px;
    width: 100%;
    min-height: 46px;
    text-align: left;
    padding: 0 14px;
    cursor: pointer;
}

.picker {
    border-top: 1px solid var(--sep);
    padding: 10px 14px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.picker .pick {
    appearance: none;
    border: 0;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 14px;
    padding: 8px 12px;
    border-radius: 999px;
    cursor: pointer;
}

.newname {
    flex: 1 1 100%;
    border: 1px dashed var(--faint);
    background: transparent;
    color: var(--text);
    font: inherit;
    font-size: 14px;
    padding: 8px 10px;
    border-radius: 8px;
}

.savebar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 14px;
    padding: 0 2px;
}

.savebar.tight {
    margin-top: 10px;
}

.savebtn {
    appearance: none;
    border: 0;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
    padding: 10px 18px;
    border-radius: 10px;
    cursor: pointer;
}

.hint {
    font-size: 12px;
    color: var(--muted);
}

/* ── 空态 ── */

.empty {
    padding: 22px 16px;
    color: var(--muted);
    font-size: 15px;
    text-align: center;
}

/* ── 笔记页 ── */

.notehead {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin: 0 0 8px;
}

.notehead .section {
    margin: 0;
}

.editbtn {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--accent);
    font: inherit;
    font-size: 14px;
    padding: 4px 2px;
    cursor: pointer;
}

.prose {
    padding: 16px 18px 20px;
    font-size: 15.5px;
    line-height: 1.6;
}

.prose > :first-child {
    margin-top: 0;
}

.prose > :last-child {
    margin-bottom: 0;
}

.prose h1 {
    font-size: 1.35em;
    line-height: 1.3;
    margin: 0 0 10px;
}

.prose h2 {
    font-size: 1.03em;
    margin: 20px 0 6px;
}

.prose h3,
.prose h4,
.prose h5,
.prose h6 {
    font-size: 0.97em;
    margin: 16px 0 4px;
}

.prose p {
    margin: 0 0 10px;
}

.prose ul,
.prose ol {
    margin: 0 0 10px;
    padding-left: 22px;
}

.prose li {
    margin: 3px 0;
}

.prose li.task {
    list-style: none;
    margin-left: -20px;
    display: flex;
    gap: 8px;
    align-items: baseline;
}

.prose li.task .box {
    color: var(--accent);
    font-size: 13px;
    flex: 0 0 auto;
}

.prose code {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.84em;
    background: var(--bg);
    padding: 1px 5px;
    border-radius: 4px;
}

.prose pre {
    background: var(--bg);
    padding: 12px;
    border-radius: 10px;
    overflow-x: auto;
    margin: 0 0 10px;
}

.prose pre code {
    background: none;
    padding: 0;
    font-size: 0.81em;
    line-height: 1.6;
}

.prose blockquote {
    margin: 0 0 10px;
    padding-left: 12px;
    border-left: 3px solid var(--sep);
    color: var(--muted);
}

.prose hr {
    border: 0;
    border-top: 1px solid var(--sep);
    margin: 16px 0;
}

.prose a {
    color: var(--accent);
}

.noteedit {
    display: block;
    width: 100%;
    min-height: 58vh;
    border: 0;
    resize: none;
    background: var(--card);
    color: var(--text);
    font: 14px/1.65 ui-monospace, SFMono-Regular, Menlo, monospace;
    padding: 16px 18px;
    border-radius: var(--radius);
    outline: none;
}

.noteedit::placeholder {
    color: var(--faint);
}

/* ── 每个习惯的近 7 天 ── */

.h7row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
}

.h7row + .h7row {
    border-top: 1px solid var(--sep);
}

.h7name {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13.5px;
}

.h7dots {
    display: flex;
    gap: 7px;
    flex: 0 0 auto;
}

.h7dots .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--sep);
}

.h7dots .dot.today {
    outline: 2px solid color-mix(in srgb, var(--text) 22%, transparent);
    outline-offset: 3px;
}

.h7streak {
    flex: 0 0 34px;
    text-align: right;
    font-size: 12px;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
}

.hatedit {
    appearance: none;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    padding: 0;
    cursor: pointer;
}

.habitinput {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 16px;
    padding: 8px 10px;
    border-radius: 8px;
    outline: none;
}

/* ── 统计页 ── */

.date {
    cursor: pointer;
}

.hcard {
    margin-bottom: 14px;
}

.hhead {
    padding: 14px 14px 0;
}

.hname {
    font-size: 15px;
    font-weight: 600;
}

.hstats {
    display: flex;
    gap: 16px;
    margin-top: 6px;
}

.hstats span {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.hstats b {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.hstats i {
    font-style: normal;
    font-size: 9.5px;
    color: var(--muted);
    letter-spacing: 0.03em;
}

.hmapwrap {
    padding: 10px 14px 14px;
    overflow-x: auto;
}

.hmonths {
    display: grid;
    gap: 2px;
    height: 12px;
    margin-bottom: 4px;
    font-size: 9px;
    line-height: 1;
    color: var(--muted);
    width: max-content;
}

.hmap {
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: repeat(7, 13px);
    gap: 2px;
    width: max-content;
}

.hcell {
    width: 13px;
    height: 13px;
    padding: 0;
    border: 0;
    border-radius: 3px;
    background: var(--sep);
    cursor: pointer;
}

.hcell.on {
    background: var(--c);
}

.hcell.blank {
    background: transparent;
    cursor: default;
}

.hlegend {
    padding: 2px 0 10px;
    text-align: center;
    font-size: 11px;
    color: var(--muted);
}

/* 补打卡的完成开关 */

.donetoggle {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    margin-top: 14px;
    padding: 10px 12px;
    border: 0;
    border-radius: 12px;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 15px;
    cursor: pointer;
}

.donetoggle .dtbox {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1.5px solid var(--faint);
    display: grid;
    place-items: center;
    font-size: 12px;
    color: transparent;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.donetoggle.on {
    background: color-mix(in srgb, var(--accent) 12%, var(--bg));
}

.donetoggle.on .dtbox {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

/* ── 每日状态弹层 ── */

.overlay {
    position: fixed;
    inset: 0;
    z-index: 60;
    background: rgba(0, 0, 0, 0.35);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    animation: fadein 0.18s ease;
}

@keyframes fadein {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.sheet {
    width: 100%;
    max-width: 480px;
    background: var(--card);
    border-radius: 20px 20px 0 0;
    padding: 20px 18px calc(18px + env(safe-area-inset-bottom));
    animation: slideup 0.22s cubic-bezier(0.2, 0.8, 0.2, 1);
}

@keyframes slideup {
    from {
        transform: translateY(24px);
    }
    to {
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .overlay,
    .sheet {
        animation: none;
    }
}

.sheet-title {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.01em;
    overflow-wrap: anywhere;
}

.sheet-sub {
    margin-top: 2px;
    font-size: 13px;
    color: var(--muted);
}

.moods {
    display: flex;
    gap: 10px;
    margin: 16px 0 6px;
}

.mood {
    flex: 1 1 0;
    aspect-ratio: 1;
    border-radius: 50%;
    border: 1.5px solid transparent;
    background: transparent;
    font-size: 30px;
    line-height: 1;
    display: grid;
    place-items: center;
    cursor: pointer;
    opacity: 0.6;
    filter: grayscale(0.7);
    transition: transform 0.14s ease, background 0.14s ease, border-color 0.14s ease,
        opacity 0.14s ease, filter 0.14s ease;
}

.mood.sel {
    background: color-mix(in srgb, var(--m) 14%, transparent);
    border-color: var(--m);
    opacity: 1;
    filter: none;
    transform: scale(1.06);
}

.moodlabels {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--muted);
    padding: 0 4px;
}

.statenote {
    width: 100%;
    margin-top: 14px;
    border: 0;
    border-radius: 12px;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 16px;
    line-height: 1.5;
    padding: 12px;
    resize: none;
    outline: none;
    box-sizing: border-box;
}

.statenote::placeholder {
    color: var(--faint);
}

.sheet-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 14px;
}

.sheet-actions .savebtn {
    flex: 1 1 auto;
}

.sheet-actions .savebtn:disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* ── 体重 ── */

.weightcard {
    margin-bottom: 4px;
}

.weighthead {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px 0;
}

.wlabel {
    font-size: 15px;
    font-weight: 600;
}

.wdate {
    font-size: 13px;
    color: var(--muted);
}

.weightbody {
    padding: 4px 14px 12px;
}

.wvalue {
    font-size: 27px;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
}

.wunit {
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
    margin-left: 3px;
}

.wdelta {
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
    margin-left: 8px;
    font-variant-numeric: tabular-nums;
}

.wchart {
    display: block;
    width: 100%;
    height: auto;
    margin-top: 6px;
}

.wchart .warea {
    fill: color-mix(in srgb, var(--accent) 14%, transparent);
    stroke: none;
}

.wchart .wline {
    fill: none;
    stroke: var(--accent);
    stroke-width: 1.8;
    stroke-linejoin: round;
    stroke-linecap: round;
}

.wchart .wdot {
    fill: var(--accent);
}

.wcaption {
    margin-top: 6px;
    font-size: 11.5px;
    color: var(--muted);
    font-variant-numeric: tabular-nums;
}

.weightentry {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px 14px;
}

.weightentry input {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    border-radius: 8px;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 20px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    padding: 8px 10px;
    outline: none;
    text-align: right;
}

.savebtn.small {
    padding: 8px 14px;
    font-size: 14px;
}

/* ── 训练动作管理 ── */

.exrow {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 48px;
    padding: 6px 8px 6px 14px;
}

.exrow + .exrow {
    border-top: 1px solid var(--sep);
}

.exname {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 16px;
}

.exdel {
    appearance: none;
    border: 0;
    background: transparent;
    color: var(--faint);
    font-size: 19px;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    cursor: pointer;
}

.exadd {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-top: 1px solid var(--sep);
}

.exadd input {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 16px;
    padding: 9px 10px;
    border-radius: 8px;
    outline: none;
}

.exaddbtn {
    appearance: none;
    border: 0;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-size: 14px;
    font-weight: 600;
    padding: 9px 14px;
    border-radius: 8px;
    flex: 0 0 auto;
    cursor: pointer;
}

/* ── 步进器（设置里的加减） ── */

.stepper {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
    flex: 0 0 auto;
}

.stepper b {
    min-width: 42px;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.stepbtn {
    appearance: none;
    border: 0;
    width: 30px;
    height: 30px;
    padding: 0;
    border-radius: 50%;
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: 17px;
    line-height: 1;
    display: grid;
    place-items: center;
    cursor: pointer;
}

/* ── 连接设置 ── */

.pillbtn {
    appearance: none;
    border: 0;
    background: var(--sep);
    color: var(--muted);
    font: inherit;
    font-size: 11.5px;
    padding: 4px 10px;
    border-radius: 999px;
    cursor: pointer;
}

.setup {
    padding: 2px 0;
}

.field {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 14px;
    min-height: 48px;
}

.field + .field {
    border-top: 1px solid var(--sep);
}

.field > span {
    flex: 0 0 86px;
    font-size: 14px;
    color: var(--muted);
}

.field input,
.field select {
    flex: 1 1 auto;
    min-width: 0;
    border: 0;
    background: transparent;
    color: var(--text);
    font: inherit;
    font-size: 16px;
    text-align: right;
    padding: 6px 0;
    outline: none;
}

.field input::placeholder {
    color: var(--faint);
}

.danger {
    color: #ff3b30;
}

.muted {
    color: var(--muted);
}

.warn {
    color: #ff3b30;
}

.mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 12px;
}

/* ── 底栏 ── */

.foot {
    margin-top: auto;
    padding-top: 22px;
    text-align: center;
    font-size: 12px;
    color: var(--muted);
}

.pill {
    display: inline-block;
    padding: 3px 9px;
    border-radius: 999px;
    background: var(--sep);
    color: var(--muted);
    font-size: 11.5px;
}
