/* CiQueue - styles (colour tokens shared with Options Live) */
:root {
  --bg: #f3f4f7;
  --panel: #ffffff;
  --panel-2: #f8f9fb;
  --ink: #1b2230;
  --muted: #667085;
  --line: #dfe3ea;
  --line-strong: #c7cdd8;
  --accent: #1f5fd1;
  --accent-ink: #ffffff;
  --accent-soft: #e8effc;
  --ok: #16794a;
  --warn: #a15c07;
  --err: #b42318;
  --err-soft: #fdecea;
  --header: #18202e;
  --radius: 6px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .06);
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
  --field: #ffffff;
  --warn-soft: #fff7e6;
  --warn-line: #f3d38b;
  --warn-ink: #6b4a00;
  --warn-text: #8a5a00;
  --ok-soft: #dcf3e6;
  --err-line: #f2b8b5;
  --info-soft: #e7eefc;
  --info-ink: #2f55b5;
  --param: #4a3fb0;
  --cad: var(--cad);
  --row-dirty: #fffaeb;
  --row-new: #f6f9ff;
  --limited-line: #b9c6ef;
  --limited-bg: #f6f8ff;
  --alt-ink: #8a6d1f;
  --suppress: #9b3b3b;
  --resume: #1f7a45;
  --text-2: #444444;
  --neutral-soft: #eeeeee;
  --neutral-ink: #888888;
  --toast-bg: #1b2230;
  --overlay: rgba(16, 24, 40, .35);
  color-scheme: light;
}

/* ---------- dark mode (default, like the Amada site); js/theme.js sets data-theme ---------- */
:root[data-theme="dark"] {
  --bg: #12161c;
  --panel: #1a2029;
  --panel-2: #202834;
  --ink: #e4e9ef;
  --muted: #9aa5b3;
  --line: #2e3744;
  --line-strong: #3d4858;
  --accent: #7fa2f0;
  --accent-ink: #0f1724;
  --accent-soft: #1d2a47;
  --ok: #5cc58e;
  --warn: #e8a64a;
  --err: #f08a82;
  --err-soft: #3d1a18;
  --header: #0d1116;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4);
  --field: #12161c;
  --warn-soft: #3a2a12;
  --warn-line: #6b5420;
  --warn-ink: #f0c98a;
  --warn-text: #e8a64a;
  --ok-soft: #153024;
  --err-line: #6e2f2c;
  --info-soft: #1d2a47;
  --info-ink: #7fa2f0;
  --param: #b19cf2;
  --cad: #4fd1b5;
  --row-dirty: #2e2812;
  --row-new: #16233a;
  --limited-line: #3d5a9a;
  --limited-bg: #172238;
  --alt-ink: #e0b85a;
  --suppress: #f08a82;
  --resume: #5cc58e;
  --text-2: #c0c8d4;
  --neutral-soft: #2a3240;
  --neutral-ink: #9aa5b3;
  --toast-bg: #2c3646;
  --overlay: rgba(0, 0, 0, .55);
  color-scheme: dark;
}


* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { min-height: 100%; }
body { margin: 0; font: 14px/1.45 var(--font); color: var(--ink); background: var(--bg); }
a { color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
.muted { color: var(--muted); font-size: 12.5px; }

/* header (console) */
.app-header { display: flex; align-items: center; gap: 14px; padding: 0 18px; height: 52px; background: var(--header); color: #fff; }
.app-header .brand { font-weight: 600; font-size: 16px; }
.app-header .brand span { color: #9fb7e8; font-weight: 400; }
.app-header .spacer { flex: 1; }
.app-header .who { font-size: 13px; color: #c8d1e0; }
.app-header button { background: transparent; border: 1px solid #3a465d; color: #dfe6f3; border-radius: var(--radius); padding: 4px 10px; cursor: pointer; }
.app-header button:hover { background: #253045; }
.app-tabs { display: flex; align-items: flex-end; gap: 2px; height: 41px; padding: 0 14px; background: var(--panel); border-bottom: 1px solid var(--line); overflow-x: auto; }
.app-tabs a { display: inline-flex; align-items: center; height: 40px; padding: 0 14px; color: var(--muted); text-decoration: none; font-weight: 600; font-size: 13.5px; border-bottom: 3px solid transparent; white-space: nowrap; cursor: pointer; }
.app-tabs a:hover { color: var(--ink); background: var(--panel-2); }
.app-tabs a.on { color: var(--accent); border-bottom-color: var(--accent); }

/* controls */
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-strong); background: var(--panel); border-radius: var(--radius); padding: 5px 11px; cursor: pointer; white-space: nowrap; text-decoration: none; color: var(--ink); }
.btn:hover { background: var(--panel-2); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.danger { color: var(--err); }
.btn.small { padding: 2px 8px; font-size: 12.5px; }
.btn:disabled { opacity: .5; cursor: default; }
label.field { display: grid; gap: 3px; font-size: 12.5px; color: var(--muted); }
label.field input, label.field select, select.inp, input.inp { padding: 6px 9px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--field); color: var(--ink); font-size: 13.5px; width: 100%; }
.chk { display: flex; gap: 7px; align-items: center; font-size: 13px; }
#toast { position: fixed; right: 18px; bottom: 18px; max-width: 420px; display: flex; flex-direction: column; gap: 8px; z-index: 50; }
#toast .t { background: var(--toast-bg); color: #fff; padding: 9px 13px; border-radius: var(--radius); box-shadow: 0 4px 14px rgba(0,0,0,.18); font-size: 13px; }
#toast .t.err { background: var(--err); }

/* cards */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 14px; align-items: start; }
@media (max-width: 520px) { .grid { grid-template-columns: 1fr; } }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; display: grid; min-width: 0; }
.card.wide { grid-column: 1 / -1; }
.card-h { display: flex; gap: 8px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.card-h h2 { margin: 0; font-size: 15px; flex: 1; }
.card-b { padding: 12px 14px; display: grid; gap: 10px; min-width: 0; }
.card-f { padding: 10px 14px; border-top: 1px solid var(--line); display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.card-f .spacer { flex: 1; }
.what { font-size: 12.5px; color: var(--muted); margin: 0; line-height: 1.45; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 520px) { .two { grid-template-columns: 1fr; } }
.badge { font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 10px; white-space: nowrap; }
.badge.on { background: var(--ok-soft); color: var(--ok); }
.badge.cfg { background: var(--info-soft); color: var(--info-ink); }
.badge.off { background: var(--err-soft); color: var(--err); }
.badge.none, .badge.later { background: var(--line); color: var(--muted); }
.result { font-size: 13px; border-radius: 6px; padding: 7px 10px; }
.result.ok { background: var(--ok-soft); color: var(--ok); }
.result.err { background: var(--err-soft); color: var(--err); border: 1px solid var(--err-line); }
.stamp { font-size: 12px; color: var(--muted); }
.stamp b { color: var(--ink); }
.ro { font-size: 13px; display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; }
.ro span { color: var(--muted); }
table.t { border-collapse: collapse; width: 100%; font-size: 13px; }
table.t th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 5px 8px; border-bottom: 1px solid var(--line-strong); white-space: nowrap; }
table.t td { padding: 6px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.scroll { overflow: auto; }
.secret { font: 13px Consolas, "Cascadia Mono", Menlo, monospace; background: var(--warn-soft); border: 1px solid var(--warn-line); color: var(--warn-ink); padding: 8px 10px; border-radius: 6px; word-break: break-all; }

/* ---------- brand logo + BETA marking (2026-10-17) ---------- */
.app-header .brand { display: flex; align-items: center; gap: 10px; white-space: nowrap; min-width: 0; }
.app-header .brand .logo { height: 30px; width: auto; display: block; flex: none; }
.app-header .brand .product { color: #fff; font-weight: 600; font-size: 16px; padding-left: 10px; border-left: 1px solid #3a465d; }
.app-header .brand .company { color: #9fb7e8; font-weight: 400; overflow: hidden; text-overflow: ellipsis; }
.app-header .brand .beta-pill { display: none; }
.is-beta .app-header .brand .beta-pill { display: inline-block; background: #e8590c; color: #fff; font-weight: 700; font-size: 12px; letter-spacing: .12em; padding: 2px 8px; border-radius: 4px; }
.is-beta .app-header { box-shadow: inset 0 -3px 0 #e8590c; }
.beta-stripe { display: flex; align-items: center; gap: 12px; padding: 7px 18px; background: #e8590c; color: #fff; font-size: 13.5px; line-height: 1.3; }
.beta-stripe b { flex: none; background: #fff; color: #c2410c; padding: 1px 9px; border-radius: 4px; letter-spacing: .14em; font-size: 13px; }
.beta-stripe a { margin-left: auto; flex: none; color: #fff; font-weight: 600; text-decoration: underline; }
@media (max-width: 760px) {
  .app-header .brand .logo { height: 22px; }
  .app-header .brand .company { display: none; }
  .beta-stripe { font-size: 12px; padding: 6px 12px; }
  .app-header { gap: 10px; padding: 0 12px; }
  .app-header button { white-space: nowrap; }
}
@media (max-width: 480px) {
  .is-beta .app-header .brand .beta-pill { display: none; }   /* the orange stripe above says it */
  .app-header .brand .product { font-size: 15px; padding-left: 8px; }
}
