/* LUMN licenses. Same tokens as the LUMN plugin admin (Lantern): navy, white and grey, light and dark. */
@font-face { font-family: "Onest"; src: url("onest-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
	--navy: #0b1f3a;
	--bg: #e9edf3;
	--surface: #ffffff;
	--surface-2: #f5f7fa;
	--border: #e3e7ed;
	--border-strong: #6b7588;
	--text: #0b1f3a;
	--text-2: #2a3a52;
	--muted: #5a6478;
	--link: #0a5db0;
	--focus: #0b6bcb;
	--good: #067647;
	--good-bg: #e6f4ec;
	--bad: #b42318;
	--bad-bg: #fdecea;
	--warn: #b54708;
	--warn-bg: #fdf2e6;
	--chip: #ebeff5;
	--btn: #0b1f3a;
	--btn-fg: #ffffff;
	--radius: 24px;
	--radius-sm: 14px;
	--shadow: 0 30px 60px -30px rgba(11, 31, 58, 0.18);
	color-scheme: light;
}
@media (prefers-color-scheme: dark) {
	:root:not([data-theme="light"]) {
		--bg: #08111f; --surface: #0f1b2e; --surface-2: #15243b; --border: #21324b; --border-strong: #6a7a94;
		--text: #e9eef6; --text-2: #cad3e1; --muted: #a3aec0; --link: #8ec8ff; --focus: #7cc0ff;
		--good: #5ad7a6; --good-bg: rgba(90, 215, 166, 0.12); --bad: #ff948a; --bad-bg: rgba(255, 148, 138, 0.12);
		--warn: #f5b062; --warn-bg: rgba(245, 176, 98, 0.12); --chip: #1b2d49; --btn: #dce6f6; --btn-fg: #0b1f3a;
		--shadow: none; color-scheme: dark;
	}
}
:root[data-theme="dark"] {
	--bg: #08111f; --surface: #0f1b2e; --surface-2: #15243b; --border: #21324b; --border-strong: #6a7a94;
	--text: #e9eef6; --text-2: #cad3e1; --muted: #a3aec0; --link: #8ec8ff; --focus: #7cc0ff;
	--good: #5ad7a6; --good-bg: rgba(90, 215, 166, 0.12); --bad: #ff948a; --bad-bg: rgba(255, 148, 138, 0.12);
	--warn: #f5b062; --warn-bg: rgba(245, 176, 98, 0.12); --chip: #1b2d49; --btn: #dce6f6; --btn-fg: #0b1f3a;
	--shadow: none; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 1rem/1.55 "Onest", system-ui, -apple-system, "Segoe UI", sans-serif; }
h1, h2, h3 { line-height: 1.2; margin: 0; font-weight: 650; }
h1 { font-size: clamp(1.6rem, 2.4vw + 1rem, 2.1rem); letter-spacing: -0.01em; }
h2 { font-size: 1.1rem; }
p { margin: 0; }
p + p { margin-top: 0.6em; }
a { color: var(--link); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
main:focus { outline: none; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--surface); color: var(--text); padding: 10px 14px; border-radius: 12px; z-index: 10; }
.skip:focus { top: 12px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.92em; letter-spacing: 0.02em; }
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }
.nowrap { white-space: nowrap; }
.lede { color: var(--text-2); font-size: 1.05rem; margin-top: 8px; margin-bottom: 20px; max-width: 46rem; }

/* Top bar. */
.top { background: var(--navy); color: #fff; }
.top-in { max-width: 1180px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; margin-right: auto; }
.mark { width: 34px; height: 34px; border-radius: 10px; background: #16325a; display: grid; place-items: center; }
.mark svg { width: 22px; height: 22px; }
.word { font-weight: 700; letter-spacing: 0.16em; }
.sub { color: #c9d3e3; font-size: 0.9rem; }
.top nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.top nav a { display: inline-flex; align-items: center; min-height: 40px; padding: 6px 12px; border-radius: 999px; color: #e9eef6; text-decoration: none; font-size: 0.92rem; }
.top nav a:hover { background: rgba(255, 255, 255, 0.1); }
.top nav a[aria-current="page"] { background: #fff; color: var(--navy); font-weight: 600; }
.top :focus-visible { outline-color: #fff; }
.top .btn-ghost { color: #fff; border-color: rgba(255, 255, 255, 0.5); }
.icon-btn { width: 40px; height: 40px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.5); background: transparent; color: #fff; display: inline-grid; place-items: center; cursor: pointer; }
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn .i-sun, [data-theme="dark"] .icon-btn .i-moon { display: none; }
[data-theme="dark"] .icon-btn .i-sun { display: block; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .icon-btn .i-moon { display: none; } :root:not([data-theme="light"]) .icon-btn .i-sun { display: block; } }
.logout { margin: 0; }

main { max-width: 1180px; margin: 0 auto; padding: 28px 20px 64px; }
.narrow { max-width: 560px; margin: 0 auto; }
.narrow-form { max-width: 640px; }
.narrow h1, .narrow > p { margin-bottom: 12px; }
.head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; margin-bottom: 16px; min-width: 0; }
.card > h2 { margin-bottom: 4px; }
.card .head { margin-bottom: 8px; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.stack > .card { margin-bottom: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.grid-2 > .card { margin-bottom: 0; }
.grid-2 + .card { margin-top: 16px; }
@media (max-width: 860px) { .grid-2 { grid-template-columns: minmax(0, 1fr); } }

/* Stats. */
.stats { list-style: none; padding: 0; margin: 0 0 16px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.stats li { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px 18px; }
.stats li:first-child { background: var(--navy); color: #fff; border-color: var(--navy); }
.stat-n { display: block; font-size: 1.8rem; font-weight: 700; line-height: 1.1; }
.stat-l { font-size: 0.85rem; color: var(--muted); }
.stats li:first-child .stat-l { color: #c9d3e3; }
@media (max-width: 640px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Forms. */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field.grow { flex: 1; }
label, .label, legend { font-weight: 600; font-size: 0.95rem; }
.help { color: var(--muted); font-size: 0.88rem; }
input:not([type="checkbox"]):not([type="radio"]), select, textarea {
	width: 100%; min-height: 44px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--border-strong);
	background: var(--surface); color: var(--text); font: inherit;
}
input[type="file"] { padding: 9px; }
input[readonly], textarea[readonly] { background: var(--surface-2); }
textarea { resize: vertical; }
[aria-invalid="true"] { border-color: var(--bad) !important; border-width: 2px !important; }
.error { color: var(--bad); font-weight: 600; font-size: 0.88rem; }
.error-summary { background: var(--bad-bg); border: 2px solid var(--bad); border-radius: var(--radius-sm); padding: 16px 18px; margin-bottom: 16px; }
.error-summary h2 { font-size: 1rem; margin-bottom: 6px; }
.error-summary ul { margin: 0; padding-left: 20px; }
.error-summary a { color: var(--text); }
.check { display: flex; gap: 10px; align-items: flex-start; }
.check input, .radio-card input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--focus); }
.radios { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; }
.radios legend { margin-bottom: 8px; }
.radio-card { display: flex; gap: 12px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface-2); }
.radio-card:has(input:checked) { border-color: var(--focus); border-width: 2px; padding: 13px 15px; }
.copy-row { display: flex; gap: 8px; align-items: center; }
.copy-row input { flex: 1; }
.filters { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 12px; }
.filters .field:not(.grow) { min-width: 160px; }

/* Buttons. */
.btn, .btn-ghost { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 999px; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; border: 1px solid transparent; }
.btn { background: var(--btn); color: var(--btn-fg); }
.btn:hover { filter: brightness(1.15); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { background: var(--surface-2); }
.top .btn-ghost:hover { background: rgba(255, 255, 255, 0.1); }
.btn-sm { min-height: 36px; padding: 6px 14px; font-size: 0.88rem; }

/* Callouts and tags. */
.callout { display: flex; gap: 10px; padding: 12px 16px; border-radius: var(--radius-sm); border: 1px solid var(--border-strong); background: var(--surface); margin-bottom: 16px; }
.callout.is-good { border-color: var(--good); background: var(--good-bg); }
.callout.is-warn { border-color: var(--warn); background: var(--warn-bg); }
.tag { display: inline-block; font-size: 0.78rem; font-weight: 650; padding: 2px 10px; border-radius: 999px; background: var(--chip); color: var(--text); vertical-align: middle; }
.tag.is-active { background: var(--good-bg); color: var(--good); }
.tag.is-expired { background: var(--warn-bg); color: var(--text); outline: 1px solid var(--warn); }
.tag.is-disabled { background: var(--bad-bg); color: var(--text); outline: 1px solid var(--bad); }
.card.is-key { border: 2px solid var(--focus); }

/* Tables. */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 0.93rem; }
th { text-align: left; font-size: 0.8rem; font-weight: 650; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--border); }
td { padding: 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
.pager { display: flex; gap: 16px; align-items: center; margin-top: 12px; }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px 20px; margin: 0; }
.facts dt { font-size: 0.8rem; color: var(--muted); font-weight: 600; }
.facts dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.sites { list-style: none; margin: 0; padding: 0; }
.sites li { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--border); }
.sites li:last-child { border-bottom: 0; }
.sites form { margin: 0; flex: none; }
.steps { margin: 0; padding-left: 20px; display: grid; gap: 10px; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
main > h1 { margin-bottom: 16px; }
main > h1 + .lede { margin-top: -8px; }
form.stack + .card, .stack + section.card { margin-top: 16px; }
.facts dd.mono { white-space: nowrap; overflow-wrap: normal; }
.facts { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
