/* Platinum HMI. Copyright 2026 Platinum LLC dba Platinum Site Solutions. All rights reserved. */
@font-face { font-family: "Inter"; src: url("fonts/inter-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-display: block; }

:root {
  --bg: #0b0d10; --bg-2: #12161b; --panel: #171b21; --panel-2: #1d2229; --panel-3: #252b33;
  --edge: rgba(255, 255, 255, 0.09); --edge-2: rgba(255, 255, 255, 0.16);
  --text: #f2f4f7; --muted: #9aa3ad; --dim: #6b7480;
  --blue: #0a84ff; --blue-2: #2563eb; --green: #30d158; --amber: #ff9f0a; --red: #ff453a;
  --radius: 12px;
  font-family: Inter, -apple-system, "SF Pro Text", "Segoe UI", sans-serif;
  font-feature-settings: "cv11", "ss01";
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: #6cb6ff; }
.hidden { display: none !important; }

.btn { height: 38px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--edge-2); background: var(--panel-2); font-size: 14px; font-weight: 600; color: #e6e9ed; display: inline-flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap; }
.btn:hover { background: var(--panel-3); }
.btn:disabled { opacity: 0.45; cursor: default; }
.btn.primary { background: var(--blue-2); border-color: transparent; color: #fff; }
.btn.primary:hover { background: #1d4ed8; }
.btn.danger { background: rgba(255, 69, 58, 0.16); border-color: rgba(255, 69, 58, 0.45); color: #ff8a80; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.ghost:hover { color: var(--text); background: rgba(255, 255, 255, 0.06); }
.btn.sm { height: 30px; padding: 0 11px; font-size: 13px; border-radius: 8px; }
.btn.lg { height: 48px; padding: 0 22px; font-size: 16px; border-radius: 12px; }

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field > span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.inp, select.inp, textarea.inp { height: 40px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--edge-2); background: #0f1318; color: var(--text); font-size: 14.5px; outline: none; width: 100%; }
textarea.inp { height: auto; min-height: 80px; padding: 10px 12px; resize: vertical; }
.inp:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.25); }
.inp.sm { height: 32px; font-size: 13px; padding: 0 9px; border-radius: 8px; }
.row { display: flex; gap: 10px; align-items: center; }
.grow { flex: 1; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.err { color: #ff8a80; }

.card { background: var(--panel); border: 1px solid var(--edge); border-radius: var(--radius); padding: 18px; }
.pill { display: inline-flex; align-items: center; gap: 7px; height: 28px; padding: 0 11px; border-radius: 14px; font-size: 12.5px; font-weight: 600; background: rgba(255, 255, 255, 0.06); border: 1px solid var(--edge); color: #d6dbe0; white-space: nowrap; }
.pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--dim); }
.pill.ok .dot { background: var(--green); box-shadow: 0 0 6px rgba(48, 209, 88, 0.8); }
.pill.bad .dot { background: var(--red); box-shadow: 0 0 6px rgba(255, 69, 58, 0.8); }
.pill.warn .dot { background: var(--amber); }

table.grid { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.grid th { text-align: left; font-size: 12px; font-weight: 600; color: var(--muted); padding: 9px 12px; border-bottom: 1px solid var(--edge-2); position: sticky; top: 0; background: var(--panel); }
table.grid td { padding: 9px 12px; border-bottom: 1px solid var(--edge); vertical-align: middle; }
table.grid tr:hover td { background: rgba(255, 255, 255, 0.025); }

/* modal */
.modal-back { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.55); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); display: flex; align-items: center; justify-content: center; z-index: 100; padding: 16px; }
.modal { background: var(--panel); border: 1px solid var(--edge-2); border-radius: 16px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); width: min(480px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; }
.modal.wide { width: min(860px, 100%); }
.modal header { padding: 18px 20px 6px; font-size: 17px; font-weight: 700; }
.modal .body { padding: 10px 20px; overflow: auto; }
.modal footer { padding: 14px 20px 18px; display: flex; gap: 10px; justify-content: flex-end; }

/* toast */
.toasts { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 200; pointer-events: none; }
.toast { background: #222831; border: 1px solid var(--edge-2); border-radius: 12px; padding: 11px 16px; font-size: 14px; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5); max-width: min(560px, calc(100vw - 32px)); }
.toast.err { border-color: rgba(255, 69, 58, 0.6); color: #fff; background: #3a1b1b; }

/* keypad */
.keypad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.keypad button { height: 56px; border-radius: 12px; border: 1px solid var(--edge-2); background: var(--panel-2); font-size: 22px; font-weight: 600; }
.keypad button:active { background: var(--panel-3); }
.kp-display { height: 56px; border-radius: 12px; background: #0f1318; border: 1px solid var(--edge-2); display: flex; align-items: center; justify-content: flex-end; padding: 0 16px; font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; }

/* scrollbars */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.12); border-radius: 6px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }
