/* Copyright © 2026 Spinium Property Management OÜ - All rights reserved.
 * Author: Timo J. Rinne <tri@iki.fi>
 *
 * Unreleased and unlicensed. Any use is explicitly prohibited without a prior
 * written license from Spinium Property Management OÜ (https://spinium.com).
 * See COPYING.
 *
 * The webshop's console, and the shop front it also dresses.
 *
 * Deliberately small and deliberately plain. bank-simu has four skins, a colour
 * picker and per-bank template overrides because looking like a particular bank
 * is part of what it simulates; a webshop is a fixture and looking like anything
 * in particular is not under test (ROADMAP-WEBSHOP.md §1.3). There is no theme,
 * no script behind any of this, and every page works with scripting off.
 */

:root {
	--bg: #f4f5f7;
	--panel: #ffffff;
	--ink: #1c2024;
	--muted: #6b7280;
	--line: #dfe3e8;
	--accent: #2b6cb0;
	--accent-ink: #ffffff;
	--bad: #b42318;
	--bad-bg: #fef3f2;
	--good: #027a48;
	--good-bg: #ecfdf3;
	--radius: 8px;
}

* { box-sizing: border-box; }

body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

a { color: var(--accent); }

/* -- the bar across the top ---------------------------------------- */

header.top {
	background: var(--panel);
	border-bottom: 1px solid var(--line);
	display: flex;
	align-items: center;
	gap: 18px;
	padding: 0 18px;
	flex-wrap: wrap;
}

header.top .brand {
	font-weight: 600;
	letter-spacing: 0.2px;
	padding: 14px 0;
	white-space: nowrap;
}

header.top nav {
	display: flex;
	gap: 4px;
	flex-wrap: wrap;
	flex: 1 1 auto;
}

header.top nav a {
	padding: 14px 12px;
	text-decoration: none;
	color: var(--ink);
	border-bottom: 3px solid transparent;
}

header.top nav a:hover { background: var(--bg); }
header.top nav a.here {
	border-bottom-color: var(--accent);
	font-weight: 600;
}

header.top .who {
	color: var(--muted);
	font-size: 13px;
	display: flex;
	align-items: center;
	gap: 10px;
	white-space: nowrap;
}

header.top .who form { margin: 0; }

/* -- the page ------------------------------------------------------ */

main {
	flex: 1 1 auto;
	width: 100%;
	max-width: 1040px;
	margin: 0 auto;
	padding: 22px 18px 40px;
}

h1 { font-size: 22px; margin: 0 0 4px; }
h2 { font-size: 17px; margin: 0 0 10px; }
p.lede { color: var(--muted); margin: 0 0 20px; }

.card {
	background: var(--panel);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 18px;
	margin: 0 0 18px;
}

.cards {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
	gap: 14px;
	margin: 0 0 18px;
}

.tile { text-align: left; }
.tile .n { font-size: 28px; font-weight: 600; }
.tile .k { color: var(--muted); font-size: 13px; }

/* -- tables -------------------------------------------------------- */

table { border-collapse: collapse; width: 100%; }
th, td {
	text-align: left;
	padding: 9px 10px;
	border-bottom: 1px solid var(--line);
	vertical-align: top;
}
th { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
tr:last-child td { border-bottom: none; }
td.right, th.right { text-align: right; }
td.mono, .mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }

/* -- forms --------------------------------------------------------- */

label { display: block; font-size: 13px; font-weight: 600; margin: 12px 0 4px; }
label.check { font-weight: 400; display: flex; gap: 8px; align-items: center; }

input[type=text], input[type=password], input[type=number], select {
	width: 100%;
	padding: 8px 10px;
	border: 1px solid var(--line);
	border-radius: 6px;
	font: inherit;
	background: #fff;
	color: inherit;
}

input:focus, select:focus, button:focus {
	outline: 2px solid var(--accent);
	outline-offset: 1px;
}

.hint { color: var(--muted); font-size: 12px; margin: 4px 0 0; }

.row {
	display: flex;
	gap: 14px;
	flex-wrap: wrap;
}
.row > * { flex: 1 1 220px; }

button, .button {
	font: inherit;
	padding: 8px 16px;
	border-radius: 6px;
	border: 1px solid var(--accent);
	background: var(--accent);
	color: var(--accent-ink);
	cursor: pointer;
	text-decoration: none;
	display: inline-block;
}
button.plain, .button.plain {
	background: var(--panel);
	color: var(--ink);
	border-color: var(--line);
}
button.danger {
	background: var(--panel);
	color: var(--bad);
	border-color: var(--bad);
}
button.small { padding: 4px 10px; font-size: 13px; }
button.full { width: 100%; margin-top: 16px; }

.actions { margin-top: 18px; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.actions form { margin: 0; }

/* -- what the page says back --------------------------------------- */

.notice, .problem {
	border-radius: 6px;
	padding: 10px 12px;
	margin: 0 0 14px;
	font-size: 14px;
}
.notice { background: var(--good-bg); color: var(--good); border: 1px solid var(--good); }
.problem { background: var(--bad-bg); color: var(--bad); border: 1px solid var(--bad); }

.muted { color: var(--muted); }
.pill {
	display: inline-block;
	font-size: 12px;
	padding: 1px 8px;
	border-radius: 999px;
	border: 1px solid var(--line);
	color: var(--muted);
}
.pill.on { color: var(--good); border-color: var(--good); }
.pill.off { color: var(--bad); border-color: var(--bad); }

/* -- signing in ---------------------------------------------------- */

.login-wrap {
	max-width: 380px;
	margin: 8vh auto 0;
}
.login-wrap .card { padding: 24px; }
.qr { display: block; margin: 14px auto; max-width: 220px; }
.secret {
	font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
	background: var(--bg);
	padding: 10px;
	border-radius: 6px;
	word-break: break-all;
	text-align: center;
}

/* -- the foot ------------------------------------------------------ */

footer.sitefoot {
	border-top: 1px solid var(--line);
	color: var(--muted);
	font-size: 12px;
	padding: 14px 18px;
	text-align: center;
}
