:root {
    color: #241c14;
    background: #f6f1e7;
    font-family: Palatino, "Palatino Linotype", "Iowan Old Style", Georgia, serif;
    line-height: 1.5;
}

body {
    margin: 0 auto;
    max-width: 46rem;
    padding: 1.5rem 1.25rem 4rem;
}

a {
    color: #6d3b22;
}

header.site {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.75rem 1.5rem;
    border-bottom: 1px solid #d9cbb8;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
}

.mark {
    font-weight: 700;
    font-size: 1.25rem;
    text-decoration: none;
    color: inherit;
}

nav {
    display: flex;
    gap: 1rem;
}

.who {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
    margin: 0 0 0 auto;
    color: #6b5c4c;
}

form.sign-out {
    display: inline;
    margin: 0;
}

h1 {
    font-size: 2rem;
    line-height: 1.2;
    margin: 0 0 0.75rem;
}

h2 {
    margin: 2rem 0 0.5rem;
    font-size: 1.25rem;
}

pre, code {
    font-family: "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;
}

pre {
    background: #fffdf8;
    border: 1px solid #e4d8c8;
    padding: 0.75rem 1rem;
}

form {
    display: grid;
    gap: 0.5rem;
    justify-items: start;
    margin: 1rem 0;
}

input, button {
    font: inherit;
}

button {
    background: #241c14;
    color: #f6f1e7;
    border: 0;
    border-radius: 4px;
    padding: 0.4rem 0.9rem;
    cursor: pointer;
}

button.quiet {
    background: transparent;
    color: #6b5c4c;
    padding-left: 0;
}

.flash {
    border-left: 4px solid #241c14;
    background: #fffdf8;
    padding: 0.75rem 1rem;
}

.flash.improved {
    border-color: #3f6b32;
}

.flash.worse, .flash.equal, .flash.invalid, .flash.rate_limited, .flash.rejected {
    border-color: #9a3d22;
}

.board-wrap {
    overflow-x: auto;
}

table.board {
    border-collapse: separate;
    border-spacing: 4px;
}

table.board th {
    font-size: 0.8rem;
    font-weight: 500;
    color: #6b5c4c;
    text-align: center;
}

.tile {
    width: 2.4rem;
    height: 2.4rem;
    text-align: center;
    vertical-align: middle;
    font-family: "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;
    font-size: 0.75rem;
    border-radius: 3px;
}

.tile.plain { background: #efe6d6; }
.tile.l2 { background: #c9d6b8; }
.tile.l3 { background: #8faf6a; }
.tile.w2 { background: #f0c7a0; }
.tile.w3 { background: #e08a62; }
.tile.origin { outline: 2px solid #241c14; }

.legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    padding: 0;
    list-style: none;
}

.swatch {
    display: inline-block;
    width: 0.9rem;
    height: 0.9rem;
    margin-right: 0.35rem;
    vertical-align: -0.1rem;
    border-radius: 2px;
}

.swatch.l2 { background: #c9d6b8; }
.swatch.l3 { background: #8faf6a; }
.swatch.w2 { background: #f0c7a0; }
.swatch.w3 { background: #e08a62; }

table.letters, table.top {
    border-collapse: collapse;
    width: 100%;
    background: #fffdf8;
}

table.letters th, table.letters td,
table.top th, table.top td {
    border-bottom: 1px solid #e4d8c8;
    text-align: left;
    padding: 0.3rem 0.5rem;
}

table.letters {
    max-width: 24rem;
}
