/* ScanViS CMS */
:root {
  --a-ink: #0c1013;
  --a-ink2: #161d22;
  --a-line: #e2e7ea;
  --a-muted: #66747d;
  --a-bg: #f6f8f9;
  --a-cyan: #29abe2;
  --a-cyan-deep: #0b7ba8;
  --a-danger: #b4342c;
  --font: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: var(--font); font-size: 15px; line-height: 1.5; color: var(--a-ink); background: var(--a-bg); }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; letter-spacing: -.02em; line-height: 1.2; }
p { margin: 0; }
img { display: block; max-width: 100%; }
code { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: .92em; background: #eef2f4; padding: 1px 5px; }
:focus-visible { outline: 2px solid var(--a-cyan); outline-offset: 2px; }

/* layout */
.a-body { display: block; }
.a-side {
  background: var(--a-ink); color: #c7d3da;
  padding: 14px 0 0;
}
.a-brand { display: flex; align-items: center; gap: 10px; padding: 4px 20px 18px; }
.a-brand img { height: 26px; width: auto; }
.a-brand span {
  font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--a-cyan);
  border: 1px solid rgba(41,171,226,.4); padding: 2px 6px;
}
.a-nav { display: flex; gap: 2px; overflow-x: auto; padding: 0 10px 10px; }
.a-nav-link {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  font-size: 14px; color: #c7d3da; border-radius: 2px; white-space: nowrap;
  transition: background .15s ease, color .15s ease;
}
.a-nav-link svg { flex: none; opacity: .8; }
.a-nav-link:hover { background: rgba(255,255,255,.07); color: #fff; }
.a-nav-link.is-active { background: rgba(41,171,226,.16); color: #fff; }
.a-nav-link.is-active svg { color: var(--a-cyan); opacity: 1; }
.a-btn-link { background: none; border: 0; width: 100%; cursor: pointer; text-align: left; font: inherit; }
.a-side-foot { padding: 12px 10px 18px; display: grid; gap: 2px; }
.a-user { padding: 12px 12px 0; font-size: 12px; color: #6f7f8a; border-top: 1px solid rgba(255,255,255,.08); margin-top: 10px; }

.a-main { padding: 22px 18px 60px; min-width: 0; }
.a-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.a-head h1 { font-size: 1.5rem; }
.a-sub { color: var(--a-muted); font-size: 13.5px; margin-top: 4px; }

/* cards */
.a-card { background: #fff; border: 1px solid var(--a-line); border-radius: 3px; margin-bottom: 18px; overflow: hidden; }
.a-card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 14px 18px; border-bottom: 1px solid var(--a-line); background: #fbfcfd;
}
.a-card-head h2 { font-size: .95rem; }
.a-count {
  display: inline-block; min-width: 22px; text-align: center; padding: 1px 6px;
  background: #eef2f4; color: var(--a-muted); font-size: 12px; font-weight: 600;
}
.a-link { font-size: 13px; color: var(--a-cyan-deep); font-weight: 600; }
.a-link:hover { text-decoration: underline; }

/* stats */
.a-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 18px; }
.a-stat {
  background: #fff; border: 1px solid var(--a-line); padding: 16px; border-radius: 3px;
  display: grid; gap: 2px; transition: border-color .15s ease;
}
.a-stat:hover { border-color: var(--a-cyan); }
.a-stat-v { font-size: 1.6rem; font-weight: 600; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.a-stat-l { font-size: 12px; color: var(--a-muted); }

/* tables */
.a-scroll { overflow-x: auto; }
.a-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.a-table th, .a-table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--a-line); vertical-align: top; }
.a-table th { font-size: 11px; text-transform: uppercase; letter-spacing: .07em; color: var(--a-muted); font-weight: 700; background: #fbfcfd; }
.a-table tbody tr:hover { background: #fbfcfd; }
.a-table tr:last-child td { border-bottom: 0; }
.a-table a:hover { color: var(--a-cyan-deep); }
.a-dim { color: var(--a-muted); font-size: 12.5px; }
.a-msg { max-width: 340px; font-size: 13px; color: #3a4750; }
.a-actions { white-space: nowrap; text-align: right; }
.a-actions .a-btn + .a-btn { margin-left: 6px; }
.a-empty { text-align: center; color: var(--a-muted); padding: 32px 14px; }
.a-thumb { width: 52px; height: 38px; background: #f4f6f7; border: 1px solid var(--a-line); display: flex; align-items: center; justify-content: center; }
.a-thumb img { max-width: 100%; max-height: 100%; object-fit: contain; }

/* pills */
.a-pill {
  display: inline-block; padding: 2px 8px; font-size: 11.5px; font-weight: 600;
  background: #eef2f4; color: #4b5a63; border-radius: 2px; white-space: nowrap;
}
.a-pill.on { background: #e6f7ee; color: #14603c; }
.a-pill.off { background: #f6f0e2; color: #7a5c1c; }
.a-pill.new { background: #e7f6fd; color: #0b6789; }

/* buttons */
.a-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 9px 14px;
  border: 1px solid #cfd7dc; background: #fff; color: var(--a-ink);
  font-size: 13.5px; font-weight: 600; border-radius: 2px; cursor: pointer; font-family: inherit;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.a-btn:hover { border-color: var(--a-ink); }
.a-btn.primary { background: var(--a-ink); border-color: var(--a-ink); color: #fff; }
.a-btn.primary:hover { background: #1f2a31; }
.a-btn.danger { color: var(--a-danger); border-color: #e6c7c4; }
.a-btn.danger:hover { background: #fdf1f0; border-color: var(--a-danger); }
.a-btn.sm { padding: 6px 10px; font-size: 12.5px; }
.a-btn.block { width: 100%; justify-content: center; }
.a-inline { display: inline; }

/* forms */
.a-form { margin: 0; }
.a-fields { display: grid; gap: 16px; padding: 18px; }
.a-grid2 { display: grid; gap: 16px; padding: 18px; }
.a-fld { display: grid; gap: 6px; }
.a-fld > span { font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--a-muted); font-weight: 700; }
.a-fld .req { color: var(--a-danger); font-style: normal; margin-left: 3px; }
.a-fld input[type="text"], .a-fld input[type="email"], .a-fld input[type="password"],
.a-fld input[type="number"], .a-fld input[type="date"], .a-fld select, .a-fld textarea {
  width: 100%; padding: 10px 11px; border: 1px solid #d3dbe0; border-radius: 2px;
  font-family: inherit; font-size: 14.5px; color: var(--a-ink); background: #fff; line-height: 1.45;
}
.a-fld textarea { resize: vertical; }
.a-fld input:focus, .a-fld select:focus, .a-fld textarea:focus {
  outline: 0; border-color: var(--a-cyan); box-shadow: 0 0 0 3px rgba(41,171,226,.15);
}
.mono, textarea.mono { font-family: ui-monospace, "Cascadia Mono", Consolas, monospace; font-size: 13px; line-height: 1.5; }
.a-switch { display: inline-flex; align-items: center; gap: 9px; font-size: 14px; }
.a-switch input { width: 18px; height: 18px; accent-color: var(--a-cyan-deep); }
.a-imgprev { margin-top: 8px; }
.a-imgprev img { max-height: 90px; border: 1px solid var(--a-line); background: #fff; padding: 4px; }
.a-form-actions {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  padding: 4px 0 0;
}
.a-form-actions .a-btn.danger { margin-left: auto; }
.a-hint { font-size: 12.5px; color: var(--a-muted); padding: 0 18px 18px; }
.a-fld .a-hint { padding: 0; }

/* flash */
.a-flash { padding: 12px 16px; border-radius: 2px; margin-bottom: 16px; font-size: 14px; font-weight: 500; }
.a-flash.ok { background: #eaf8f1; border: 1px solid #bfe6d2; color: #14603c; }
.a-flash.err { background: #fdeeee; border: 1px solid #f3c6c6; color: #8d2020; }

/* dashboard bits */
.a-cols { display: grid; gap: 18px; }
.a-list { padding: 6px 18px 14px; }
.a-list li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--a-line); font-size: 13.5px; }
.a-list li:last-child { border-bottom: 0; }
.a-list a:hover { color: var(--a-cyan-deep); }
.a-tabs { display: flex; gap: 4px; margin-bottom: 14px; }
.a-tab { padding: 8px 14px; font-size: 13.5px; border: 1px solid var(--a-line); background: #fff; border-radius: 2px; }
.a-tab.is-on { background: var(--a-ink); border-color: var(--a-ink); color: #fff; }

/* media */
.a-upload { display: flex; flex-wrap: wrap; gap: 10px; padding: 18px; align-items: center; }
.a-upload input[type="file"] { font-size: 13.5px; }
.a-media-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; padding: 18px; }
.a-media { margin: 0; border: 1px solid var(--a-line); background: #fff; }
.a-media img { width: 100%; height: 96px; object-fit: contain; background: #fbfcfd; padding: 6px; }
.a-media figcaption { padding: 7px 9px; border-top: 1px solid var(--a-line); display: grid; gap: 1px; }
.a-media span { font-size: 11.5px; word-break: break-all; }
.a-media em { font-style: normal; font-size: 11px; color: var(--a-muted); }

/* login */
.login-body { display: grid; place-items: center; min-height: 100vh; background: var(--a-ink); padding: 24px; }
.login-card { width: 100%; max-width: 400px; background: #fff; padding: 34px 30px 26px; border-radius: 3px; }
.login-logo { height: 34px; width: auto; margin-bottom: 26px; }
.login-card h1 { font-size: 1.3rem; }
.login-sub { color: var(--a-muted); font-size: 13.5px; margin: 8px 0 22px; line-height: 1.5; }
.login-card .a-form { display: grid; gap: 14px; }
.login-foot { margin-top: 20px; font-size: 12.5px; color: var(--a-muted); }
.login-foot a:hover { color: var(--a-cyan-deep); }

/* responsive */
@media (min-width: 760px) {
  .a-stats { grid-template-columns: repeat(5, 1fr); }
  .a-grid2 { grid-template-columns: repeat(2, 1fr); }
  .a-cols { grid-template-columns: 1.5fr 1fr; align-items: start; }
  .a-media-grid { grid-template-columns: repeat(4, 1fr); }
  .a-main { padding: 28px 28px 70px; }
}

@media (min-width: 1000px) {
  .a-body { display: grid; grid-template-columns: 236px 1fr; min-height: 100vh; }
  .a-side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding-top: 18px; }
  .a-nav { flex-direction: column; overflow: visible; padding: 0 10px; flex: 1; }
  .a-nav-link { padding: 9px 12px; }
  .a-side-foot { border-top: 1px solid rgba(255,255,255,.08); padding: 10px; }
  .a-main { padding: 30px 34px 80px; }
  .a-head h1 { font-size: 1.7rem; }
}
