/* Meadow Bound test realm: the login screen's look (sunset sky, meadow green, cream panels). */
:root {
    --sky-top: #8f5a7a;
    --sky-low: #f2c6a0;
    --meadow: #6f9a4b;
    --meadow-dark: #3f5d2b;
    --cream: #f6efdc;
    --cream-edge: #d9c9a0;
    --ink: #2f3a25;
    --muted: #6d6a58;
    --button: #6f9a4b;
    --button-ink: #fffaf0;
    --danger: #a5443a;
    --good: #3f7a3a;
    --field: #fffdf6;
    --line: #e3d7b8;
}

* { box-sizing: border-box; }

html { min-height: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
    color: var(--ink);
    background: linear-gradient(180deg, var(--sky-top) 0%, #c58a8a 30%, var(--sky-low) 55%, var(--meadow) 56%, var(--meadow-dark) 100%) fixed;
    display: flex;
    flex-direction: column;
}

body.admin { background: linear-gradient(180deg, #4b5a44 0%, #2f3a25 100%) fixed; }

.top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding: 18px 24px;
}

.brand {
    color: #fff6e2;
    text-decoration: none;
    font-size: 26px;
    letter-spacing: 6px;
    font-weight: 300;
    text-shadow: 0 1px 3px rgba(0, 0, 0, .25);
}

.brand span {
    display: block;
    font-size: 12px;
    letter-spacing: 2px;
    font-style: italic;
    opacity: .9;
}

nav { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }

nav a, button.link {
    color: #fff6e2;
    text-decoration: none;
    font-size: 15px;
    background: none;
    border: 0;
    padding: 0;
    margin: 0;
    cursor: pointer;
    font: inherit;
}

nav a:hover, button.link:hover { text-decoration: underline; }

main {
    flex: 1;
    width: 100%;
    max-width: 980px;
    margin: 0 auto;
    padding: 16px;
}

body.admin main { max-width: 1200px; }

.panel {
    background: var(--cream);
    border: 1px solid var(--cream-edge);
    border-radius: 10px;
    padding: 24px 28px;
    margin: 0 auto 20px;
    box-shadow: 0 6px 24px rgba(40, 30, 20, .18);
}

.panel.narrow { max-width: 460px; }

h1 { margin: 0 0 6px; font-size: 26px; font-weight: 500; color: var(--meadow-dark); }
h2 { margin: 18px 0 8px; font-size: 18px; font-weight: 600; color: var(--meadow-dark); }
p { line-height: 1.55; }
.sub { color: var(--muted); margin-top: 0; }

label { display: block; font-size: 14px; margin: 12px 0 4px; color: var(--muted); }

input[type=text], input[type=email], input[type=password], input[type=number], input[type=search] {
    width: 100%;
    padding: 9px 10px;
    border: 1px solid #b9ad8e;
    border-radius: 5px;
    background: var(--field);
    font: inherit;
    color: var(--ink);
}

input:focus { outline: 2px solid var(--meadow); outline-offset: 1px; }

button, .button {
    display: inline-block;
    margin-top: 16px;
    padding: 9px 18px;
    border: 0;
    border-radius: 5px;
    background: var(--button);
    color: var(--button-ink);
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
}

button:hover, .button:hover { filter: brightness(1.08); }
button.secondary { background: #b9ad8e; color: var(--ink); }
button.danger { background: var(--danger); }
button.small { margin: 0; padding: 4px 10px; font-size: 13px; font-weight: 500; }

form.inline { display: inline; }

.message { padding: 10px 12px; border-radius: 6px; margin: 12px 0; line-height: 1.45; }
.message.error { background: #f3d9d3; color: #6e2a22; }
.message.ok { background: #dcebd3; color: #2c4f22; }

.hint { font-size: 13px; color: var(--muted); }

.grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 20px; }

@media (max-width: 760px) {
    .grid { grid-template-columns: 1fr; }
    .panel { padding: 20px 16px; }
    .top { padding: 14px 16px; }
}

ol.steps { padding-left: 20px; line-height: 1.7; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--muted); font-weight: 600; border-bottom: 2px solid var(--line); padding: 6px 8px; }
td { border-bottom: 1px solid var(--line); padding: 7px 8px; vertical-align: top; }
.table-wrap { overflow-x: auto; }

.tag { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; background: #e6dcc1; }
.tag.active, .tag.unused { background: #dcebd3; color: var(--good); }
.tag.banned, .tag.revoked { background: #f3d9d3; color: var(--danger); }
.tag.disabled, .tag.used { background: #ece4cf; color: var(--muted); }
.tag.online { background: #d6e6f2; color: #2a5677; }

.actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.actions input[type=text] { width: 150px; padding: 4px 6px; font-size: 13px; }

.codes { font-family: Consolas, "Courier New", monospace; font-size: 18px; line-height: 1.8; }
.mono { font-family: Consolas, "Courier New", monospace; font-size: 12px; word-break: break-all; }

footer { text-align: center; color: #f3ead2; font-size: 13px; padding: 18px; text-shadow: 0 1px 2px rgba(0, 0, 0, .3); }

.actions.spaced { margin-top: 6px; }

.panel a:not(.button) { color: var(--meadow-dark); font-weight: 600; }
.mono.nowrap { word-break: normal; white-space: nowrap; }
