:root {
    color-scheme: dark;
    --base: #111411;
    --surface: #181d18;
    --field: #121712;
    --edge: #343e33;
    --text: #f3f6ee;
    --soft: #b2bead;
    --accent: #c2f86d;
    --muted-green: #232e1a;
    --danger: #ffd0c9;
    font-family: Inter, "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
    background: var(--base);
    color: var(--text);
    line-height: 1.5;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: .22em; }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, p { margin: 0; }
h1 { font-size: clamp(1.85rem, 5vw, 2.65rem); font-weight: 720; line-height: 1.2; letter-spacing: -.035em; }
h2 { font-size: 1.13rem; font-weight: 690; }
small { color: var(--soft); }
code, .mono { font-family: "IBM Plex Mono", ui-monospace, monospace; }
.top { background: #141914; border-bottom: 1px solid var(--edge); }
.top-inner { min-height: 72px; padding: 12px clamp(16px, 4vw, 44px); max-width: 1390px; margin: auto; display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.brand { display: flex; gap: 10px; align-items: center; font-size: .95rem; font-weight: 700; line-height: 1.25; color: var(--text); }
.mark { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 8px; flex-shrink: 0; background: var(--accent); color: #192311; font-size: 1.15rem; font-weight: 850; }
.languages { display: flex; align-items: center; gap: 2px; border: 1px solid var(--edge); border-radius: 9px; padding: 3px; }
.languages a, .nav a { color: var(--soft); font-size: .79rem; padding: 5px 8px; white-space: nowrap; border-radius: 6px; }
.languages a[aria-current], .nav a[aria-current] { color: var(--accent); background: var(--muted-green); }
.nav { display: flex; align-items: center; gap: 8px; }
main { padding: 44px 16px 20px; margin: auto; }
.narrow { max-width: 714px; }
.wide { max-width: 1280px; }
.heading { margin: 0 0 24px; }
.heading p, .dialog-body p, .report-bar p, .card p { color: var(--soft); }
.heading p { margin-top: 10px; font-size: .98rem; }
.network { display: flex; align-items: center; gap: 7px; margin-bottom: 12px; color: var(--accent); font-size: .78rem; }
.network span { width: 8px; height: 8px; background: var(--accent); border-radius: 50%; }
.card { border: 1px solid var(--edge); background: var(--surface); border-radius: 14px; padding: clamp(16px, 4vw, 27px); min-width: 0; }
.stack { display: grid; gap: 18px; align-content: start; }
.field { display: grid; gap: 7px; font-size: .92rem; font-weight: 600; min-width: 0; }
.field b { color: var(--accent); }
.field small { font-weight: 400; line-height: 1.5; }
.field small.address-hint { color: #dce7bc; }
.field :is(input, textarea) { border: 1px solid var(--edge); border-radius: 8px; color: var(--text); background: var(--field); padding: 10px 12px; min-height: 44px; min-width: 0; width: 100%; font-size: 16px; font-weight: 400; }
.field textarea { resize: vertical; }
.field ::placeholder { color: #9daa96; opacity: 1; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.unit { padding: 11px 14px; border: 1px solid #405133; border-radius: 9px; background: var(--muted-green); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 16px; color: #e1edcc; font-size: .88rem; }
.unit output { color: var(--accent); font-weight: 650; overflow-wrap: anywhere; }
.upload { display: grid; gap: 8px; border: 1px dashed #57654d; border-radius: 9px; padding: 10px 12px; background: var(--field); color: var(--soft); font-size: .76rem; font-weight: 400; }
.upload input { border: 0; padding: 0; min-height: 36px; font-size: .88rem; }
.upload input::file-selector-button { background: var(--muted-green); color: var(--accent); border: 1px solid var(--edge); border-radius: 7px; margin-inline-end: 8px; min-height: 34px; padding: 4px 8px; font: inherit; cursor: pointer; }
.primary, .secondary { display: inline-flex; justify-content: center; align-items: center; gap: 8px; min-height: 44px; padding: 9px 14px; border-radius: 8px; text-align: center; font-weight: 700; font-size: .92rem; line-height: 1.3; cursor: pointer; }
.primary { background: var(--accent); color: #1a2510; border: 1px solid var(--accent); }
.primary:hover { background: #d0fa95; text-decoration: none; }
.primary:disabled { opacity: .65; cursor: wait; }
.secondary { background: #1a2118; color: var(--text); border: 1px solid var(--edge); }
.secondary:hover { background: var(--muted-green); text-decoration: none; }
dialog { width: min(540px, calc(100% - 24px)); max-height: calc(100% - 24px); background: #1c241b; color: var(--text); border: 1px solid #516344; border-radius: 14px; padding: 0; box-shadow: 0 16px 70px #000a; }
dialog::backdrop { background: #070907c9; }
.dialog-body { padding: clamp(16px, 4vw, 26px); display: grid; gap: 14px; }
.destination { display: grid; gap: 5px; padding: 12px 14px; background: var(--field); border: 1px solid var(--edge); border-radius: 9px; overflow-wrap: anywhere; }
.destination strong + small { margin-top: 6px; }
.destination code { font-size: .98rem; color: var(--accent); }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.actions button { flex: 1 1 150px; }
.errors { margin: 0 0 16px; padding: 12px 16px 12px 34px; border-radius: 8px; border: 1px solid #8d5a50; color: var(--danger); background: #352521; }
footer, .pagination { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 16px; font-size: .85rem; color: var(--soft); }
footer a, .text-button, .back { color: var(--soft); }
.text-button { background: transparent; border: 0; padding: 8px 0; cursor: pointer; }
.back { display: inline-block; margin-bottom: 12px; font-size: .86rem; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.pill, .status { display: inline-flex; align-items: center; gap: 6px; width: fit-content; padding: 4px 9px; border-radius: 7px; border: 1px solid var(--edge); white-space: nowrap; color: var(--soft); font-size: .8rem; }
.pill[aria-current], .status.sent { background: var(--muted-green); color: var(--accent); }
.pill span { color: var(--text); }
.status.pending { color: #f2daa0; }
.status.approved { color: #c2defd; }
.status.rejected { color: var(--danger); }
.table-wrap { padding: 0; overflow-x: auto; margin-top: 8px; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: .86rem; }
th, td { padding: 12px 14px; border-bottom: 1px solid var(--edge); }
th { color: var(--soft); white-space: nowrap; background: var(--field); }
tr:last-child td { border-bottom: 0; }
.empty { padding: 24px; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.facts { margin: 0; display: grid; grid-template-columns: minmax(90px, 32%) minmax(0, 1fr); gap: 10px; font-size: .9rem; }
dt { color: var(--soft); }
dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.form-separator { border-top: 1px solid var(--edge); padding-top: 16px; }
.check { display: flex; align-items: flex-start; gap: 8px; font-size: .9rem; }
.check input { margin-top: .3em; accent-color: var(--accent); }
.proof { display: block; max-width: 100%; max-height: 430px; border-radius: 8px; object-fit: contain; background: var(--field); }
.report-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; }
.report-details { margin-top: 22px; }
.break { min-width: 150px; max-width: 210px; overflow-wrap: anywhere; }
@media (max-width: 650px) {
    main { padding-top: 28px; }
    .detail-grid { grid-template-columns: 1fr; }
    .top-inner { min-height: 62px; }
    .pair { gap: 10px; }
}
@media (max-width: 345px) {
    .pair { grid-template-columns: 1fr; }
    .brand { font-size: .81rem; }
}
