/* ─── GAUTH base ───────────────────────────────────────────
   Shared design tokens and element styling. This file is the
   single source of truth for the Gumpworks visual language.
   ───────────────────────────────────────────────────────── */

:root {
  --ink: #000;
  --bg: #d8d8d8;
  --chrome: #d2d2d2;
  --panel: #ececec;
  --field: #f7f7f7;
  --line: #000;
  --hi: #fff;
  --lo: #9a9a9a;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  padding: 18px 14px 48px;
  background: var(--bg);
  color: var(--ink);
  font-family: "MS Sans Serif", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color-scheme: light;
}

h1, h2, h3, h4 { line-height: 1.3; }

h2 {
  margin: 0 0 12px;
  padding-bottom: 6px;
  font-size: 16px;
  border-bottom: 1px solid var(--line);
}

h3 {
  margin: 20px 0 10px;
  padding: 3px 8px;
  font-size: 13px;
  background: linear-gradient(#f2f2f2, #dedede);
  border: 1px solid var(--line);
}

h4 { margin: 16px 0 8px; font-size: 13px; }

p { margin: 0 0 10px; }

small { font-size: 11px; }

a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

a:hover, a:focus {
  background: #000080;
  color: #fff;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 1px dotted var(--ink);
  outline-offset: 1px;
}

::selection { background: #000080; color: #fff; }

form { margin: 0 0 12px; }
form p { margin: 0 0 9px; }

label { display: inline-block; margin-bottom: 2px; }

input, select, textarea {
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 3px 6px;
  max-width: 100%;
  box-shadow: inset 1px 1px 0 var(--lo);
}

input[type=text],
input[type=password],
input[type=email],
input[type=number],
input[type=search],
input[type=url] {
  width: 100%;
  max-width: 20em;
}

textarea {
  width: 100%;
  max-width: 42em;
  min-height: 4.5em;
  resize: vertical;
}

select { max-width: 100%; }

input[type=checkbox],
input[type=radio] {
  width: auto;
  padding: 0;
  border: 0;
  box-shadow: none;
  accent-color: #000;
  vertical-align: -1px;
  margin: 0 4px 0 0;
}

button,
input[type=submit],
input[type=button] {
  font-family: inherit;
  font-size: 13px;
  color: var(--ink);
  background: var(--chrome);
  border: 1px solid var(--line);
  border-radius: 0;
  padding: 3px 12px;
  min-height: 26px;
  cursor: pointer;
  box-shadow: inset 1px 1px 0 var(--hi), inset -1px -1px 0 var(--lo);
  -webkit-appearance: none;
  appearance: none;
}

button:hover,
input[type=submit]:hover { background: #e4e4e4; }

button:active,
input[type=submit]:active {
  box-shadow: inset 1px 1px 0 var(--lo);
  padding-top: 4px;
  padding-bottom: 2px;
}

button:disabled {
  color: #6b6b6b;
  background: #cfcfcf;
  box-shadow: none;
  cursor: not-allowed;
}

table {
  width: 100%;
  margin: 10px 0 16px;
  border-collapse: collapse;
  background: var(--panel);
  font-size: 13px;
}

th, td {
  border: 1px solid var(--line);
  padding: 4px 8px;
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
}

th {
  background: linear-gradient(#f2f2f2, #dcdcdc);
  font-weight: 700;
  white-space: nowrap;
}

tr:nth-child(even) th,
tr:nth-child(even) td { background: #e3e3e3; }

td form { margin: 0 0 4px; }
td form:last-child { margin-bottom: 0; }
td button { min-height: 22px; padding: 1px 8px; font-size: 12px; }

pre {
  margin: 10px 0 14px;
  padding: 8px 10px;
  background: var(--field);
  border: 1px solid var(--line);
  box-shadow: inset 1px 1px 0 var(--lo);
  overflow-x: auto;
  font-family: "Lucida Console", "Courier New", monospace;
  font-size: 12px;
  line-height: 1.45;
}

code {
  font-family: "Lucida Console", "Courier New", monospace;
  font-size: 12px;
  background: #e0e0e0;
  border: 1px solid #a6a6a6;
  padding: 0 3px;
  overflow-wrap: anywhere;
}

pre code { background: none; border: 0; padding: 0; }

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 14px 0;
}

ul, ol { padding-left: 24px; }

img { max-width: 100%; height: auto; }

/* ─── Notices ──────────────────────────────────────────── */
.notice {
  margin: 0 0 12px;
  padding: 6px 10px;
  background: #e6e6e6;
  border: 1px solid var(--line);
  box-shadow: inset 1px 1px 0 var(--hi);
}

.notice strong {
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.notice.ok { background: #e3e9dd; }
.notice.err { background: #eee1e1; }

/* ─── Narrow form column ───────────────────────────────── */
.narrow { max-width: 420px; margin: 0 auto; }

.narrow input[type=text],
.narrow input[type=password],
.narrow input[type=email] { max-width: 100%; }
