/* Operational UI: native controls, readable tables, explicit review states. */
:root { color-scheme: dark; --focus: #a6caff; }
[hidden] { display: none !important; }
button, a, input, select, textarea { touch-action: manipulation; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
input:not([type=checkbox]), select, textarea { width: 100%; color: var(--text,#dce3ee); background: var(--panel2,#1d2430); border: 1px solid var(--line,#2a3342); border-radius: 7px; padding: 9px 10px; font: inherit; min-height: 40px; }
input::placeholder, textarea::placeholder { color: #9ca9bb; }
label { color: #aab6c8; }
nav.tabs { overflow-x: auto; white-space: nowrap; position: sticky; top: 65px; z-index: 4; background: var(--bg); padding-bottom: 1px; }
nav.tabs button { min-height: 44px; flex-shrink: 0; }
header .account { margin-left: auto; display: flex; gap: 12px; align-items: center; font-size: 12px; }
.notice { max-width: 1240px; margin: 12px auto 0; padding: 10px 14px; border-left: 3px solid var(--warn); background: var(--panel); color: var(--text); font-size: 13px; }
.notice:empty { display: none; }
.filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; margin: 12px 0; }
.filters label { margin: 0; flex: 1; min-width: 150px; max-width: 330px; }
.filters input, .filters select { margin-top: 6px; }
.filters button { min-height: 40px; margin-bottom: 1px; }
.section-heading { display: flex; justify-content: space-between; align-items: start; gap: 18px; }
.section-heading h2 { margin: 0; }
.review-options { padding: 10px 0; border-top: 1px solid var(--line); margin-top: 14px; }
.form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px 18px; }
.form-grid .wide { grid-column: 1 / -1; }
.form-error { color: #ffb1b1; padding: 10px 0; }
.form-actions { display: flex; justify-content: end; gap: 10px; margin-top: 18px; }
.table-scroll { overflow-x: auto; }
.table-scroll table { min-width: 660px; }
.pagination { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 18px; color: var(--muted); font-size: 12px; }
.totals { display: flex; flex-wrap: wrap; gap: 16px 28px; padding: 16px 0; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.totals div { font-size: 12px; color: var(--muted); }
.totals strong { display: block; font-size: 20px; color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.preview-summary { border-left: 3px solid var(--ok); padding: 12px; margin-top: 12px; background: var(--panel2); }
.preview-summary p { white-space: pre-wrap; }
button.act.primary { background: #2563b8; border-color: #2563b8; }
.empty { padding: 24px 10px; color: var(--muted); text-align: center; }
.loading { opacity: .7; }
.customer-address { max-width: 330px; }
.login-page { margin: 0; min-height: 100dvh; display: grid; place-items: center; background: #0e1116; color: #dce3ee; font: 15px/1.5 -apple-system,"Segoe UI",sans-serif; padding: 24px; }
.login-card { width: min(100%,420px); background: #161b24; border: 1px solid #2a3342; border-radius: 12px; padding: 30px; }
.login-card h1 { font-size: 22px; margin: 0 0 8px; }
.login-card label { display: block; margin: 18px 0 6px; }
.login-card button { width: 100%; min-height: 44px; border: 0; background: #2563b8; color: #fff; border-radius: 7px; margin-top: 22px; font: inherit; cursor: pointer; }
.login-card .muted { color: #aab6c8; font-size: 13px; }
.login-card h2 { font-size: 16px; margin: 22px 0 0; }
.cross-login-button { display: block; background: #2563b8; color: #fff; border-radius: 7px; min-height: 44px; padding: 11px 14px; box-sizing: border-box; text-align: center; text-decoration: none; font-weight: 600; }
@media (max-width: 900px) { nav.tabs { top: 0; } header { position: static; } .section-heading { flex-wrap: wrap; } }
@media (max-width: 600px) { main { padding: 12px 12px 40px; } header { padding: 12px; gap: 8px; } .notice { margin: 10px 12px; } .form-grid { grid-template-columns: 1fr; } .filters label { max-width: none; } dialog { width: 96vw; padding: 16px; } header .account { width: 100%; margin-left: 0; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
