/* Shakespeare. Layout idea, as in the Garden: one quiet reading column, with one accent colour per subject.
   Set --accent on <body> (the page's theme) or on any section that is split by subject:
   .theme-comedy ochre, .theme-history crimson, .theme-tragedy ink-violet, .theme-romance teal,
   .theme-poem olive, .theme-london steel blue (the neutral accent for the London and life maps).
   Fonts are served from this site (SIL Open Font License), so visitors' browsers contact no one else.
   Cormorant Garamond by Christian Thalmann; Literata by TypeTogether. */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/cormorant-garamond-latin-ext-500-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/cormorant-garamond-latin-ext-600-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 500; font-display: swap; src: url("fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 500; font-display: swap; src: url("fonts/cormorant-garamond-latin-ext-500-italic.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Literata"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/literata-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Literata"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/literata-latin-ext-400-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Literata"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/literata-latin-600-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Literata"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/literata-latin-ext-600-normal.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --bg: #f4f1e8;
  --surface: #fbf9f3;
  --ink: #23271f;
  --muted: #5c6154;
  --line: #d9d4c4;
  --water: #d3e1e8;
  --comedy: #8a6010;
  --history: #8c2f2f;
  --tragedy: #4b3f72;
  --romance: #1f6f6b;
  --poem: #5b6b2f;
  --london: #3d5a73;
  --home: #3d5a73;
  --accent: var(--home);
  --accent-ink: #ffffff;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Literata", Georgia, "Times New Roman", serif;
  --col: 44rem;
  --wide: 70rem;
  color-scheme: light;
}
.theme-home    { --accent: var(--home); }
.theme-london  { --accent: var(--london); }
.theme-comedy  { --accent: var(--comedy); }
.theme-history { --accent: var(--history); }
.theme-tragedy { --accent: var(--tragedy); }
.theme-romance { --accent: var(--romance); }
.theme-poem    { --accent: var(--poem); }

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #161914; --surface: #1d211a; --ink: #e9e7dc; --muted: #a6ab9b; --line: #333929; --water: #24323a;
    --comedy: #e0b45c; --history: #e08c85; --tragedy: #b3a6e6; --romance: #6fc4bd; --poem: #b5c97a;
    --london: #8db4d6; --home: #8db4d6;
    --accent-ink: #14170f;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { font-size: 112.5%; -webkit-text-size-adjust: 100%; scroll-padding-top: 6rem; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font-body); line-height: 1.7;
  font-feature-settings: "kern", "liga";
}
::selection { background: var(--accent); color: var(--accent-ink); }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--accent); color: var(--accent-ink); padding: .5rem 1rem; z-index: 30; }
.skip:focus { left: 0; }

.site-header { position: sticky; top: 0; z-index: 20; display: flex; flex-wrap: nowrap; align-items: center; gap: .5rem 1.5rem; padding: .75rem 1.25rem; border-bottom: 1px solid var(--line); background: var(--surface); }
.brand { flex: none; white-space: nowrap; font-family: var(--font-display); font-weight: 600; font-size: 1.9rem; color: var(--ink); text-decoration: none; letter-spacing: .01em; }
.site-header nav { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; margin-left: auto; }
.site-header nav a { color: var(--ink); text-decoration: none; padding: .15rem 0; border-bottom: 2px solid transparent; font-size: .95rem; white-space: nowrap; }
.site-header nav a:hover { border-bottom-color: var(--line); }
.site-header nav a[aria-current="page"] { border-bottom-color: var(--accent); }

.maps-menu { position: static; }
.maps-menu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .8rem; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); color: var(--ink); font-size: .95rem; user-select: none; }
.maps-menu summary::-webkit-details-marker { display: none; }
.maps-menu summary::after { content: ""; width: .5rem; height: .5rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-.15rem) rotate(45deg); }
.maps-menu[open] summary::after { transform: translateY(.1rem) rotate(-135deg); }
/* While the Maps menu is open, grey out the page beneath it (and stop clicks reaching it; a click outside closes the menu). */
main, .site-footer { transition: opacity .15s ease, filter .15s ease; }
body:has(.maps-menu[open]) main, body:has(.maps-menu[open]) .site-footer { opacity: .3; filter: grayscale(1); pointer-events: none; }
.maps-menu summary.has-current { border-color: var(--accent); }
.maps-menu summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.when-narrow { display: none; }
.maps-panel { position: absolute; left: 0; right: 0; top: 100%; max-height: calc(100vh - 4rem); overflow-y: auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 1rem 2rem; padding: 1.25rem; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: 0 .75rem 1.5rem rgba(0, 0, 0, .12); }
.maps-site { display: none; }
.maps-group { border-left: 4px solid var(--g, var(--line)); padding-left: .75rem; }
.maps-heading { font-weight: 600; font-family: var(--font-display); font-size: 1.15rem; margin: 0 0 .4rem; color: var(--g, var(--ink)); }
.maps-group ul { list-style: none; margin: 0; padding: 0; }
.maps-group li { margin: 0; }
.maps-group a { display: block; padding: .2rem 0; color: var(--ink); text-decoration: none; border-bottom: 2px solid transparent; width: fit-content; }
.maps-group a:hover { border-bottom-color: var(--line); }
.maps-group a[aria-current="page"] { border-bottom-color: var(--g, var(--accent)); font-weight: 600; }

main { padding: 2rem 1.25rem 3rem; }
.col { max-width: var(--col); margin: 0 auto; }
.wide { max-width: var(--wide); margin: 0 auto; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.2; }
h1 { font-size: 2.6rem; margin: 0 0 .75rem; }
h2 { font-size: 1.75rem; margin: 2.25rem 0 .5rem; }
h3 { font-size: 1.3rem; margin: 1.5rem 0 .25rem; }
.lede { font-size: 1.2rem; color: var(--ink); margin: 0 0 1.25rem; }
.eyebrow { font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin: 0 0 .25rem; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
p, li { max-width: 40rem; }
/* Break long words at the end of a line with a hyphen instead of moving the whole word down (needs lang on <html>). */
p, li, dd, figcaption, .sidenote { hyphens: auto; hyphenate-limit-chars: 7 3 3; text-wrap: pretty; }
h1, h2, h3, h4, nav, .chip, .tag, .eyebrow, a.gsrc, a.srcjump, code { hyphens: manual; }

/* Chips and tags */
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .5rem 0 1rem; }
.chip, .tag { display: inline-block; font-family: var(--font-body); font-size: .75rem; line-height: 1.4; padding: .1rem .55rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink); }
.chip-site { border-color: var(--accent); }
.chip-uncertain { border-style: dashed; border-color: var(--accent); }
.tag { border-radius: 3px; padding: .05rem .4rem; vertical-align: .08em; }
.tag-secondary { border-style: dashed; }
.tag-basis { border-color: var(--accent); color: var(--accent); }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1rem; margin: 1rem auto; padding: 0; list-style: none; max-width: var(--col); }
/* Cards fill the text column: two across at most, one card the width of one column. */
.cards:not(:has(> li:nth-child(2))) { grid-template-columns: minmax(0, calc((var(--col) - 1rem) / 2)); }
.card { background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: 4px; padding: 1rem 1.1rem; max-width: none; }
.card h2, .card h3 { margin: 0 0 .25rem; font-size: 1.4rem; }
.card h2 a, .card h3 a { color: var(--ink); text-decoration: none; }
.card h2 a:hover, .card h3 a:hover { color: var(--accent); text-decoration: underline; }
.card p { margin: .25rem 0; font-size: .95rem; }
.card .meta { color: var(--muted); font-size: .85rem; }

/* Glance list */
.glance { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1.25rem; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); padding: 1rem 1.25rem; margin: 1.25rem 0; }
.glance dt { font-weight: 600; font-size: .9rem; color: var(--muted); }
.glance dd { margin: 0; max-width: none; }
@media (max-width: 34rem) { .glance { grid-template-columns: 1fr; } .glance dt { margin-top: .5rem; } }

/* Evidence panels: what the plays say / what the documents show / tradition and inference */
.tier { border-left: 4px solid var(--line); padding-left: 1rem; margin: 1.5rem 0; }
.tier h2 { margin-top: 0; }
.tier-documents { border-left-color: var(--accent); }
.tier-tradition { border-left-style: dashed; }

/* Map */
.map { margin: 1.25rem auto; max-width: var(--col); }
.map svg { display: block; width: 100%; height: auto; max-width: 40rem; background: var(--surface); border: 1px solid var(--line); }
.map .bg { fill: var(--surface); }
.map .grat { fill: none; stroke: var(--line); stroke-width: 1; }
.map .area { font-family: var(--font-body); fill: var(--muted); pointer-events: none; }
.map .area-c { font-size: 10px; letter-spacing: .22em; opacity: .75; }
.map .area-s { font-size: 11px; font-style: italic; letter-spacing: .06em; opacity: .85; }
.map .deg { font-size: 10px; fill: var(--muted); font-family: var(--font-body); }
.map .sea { fill: var(--water); }
.map .land { fill: var(--surface); stroke: var(--muted); stroke-width: .8; stroke-linejoin: round; }
.map .border { fill: none; stroke: var(--muted); stroke-width: .7; stroke-dasharray: 3 2.5; opacity: .75; }
.map .water { fill: var(--water); stroke: none; }
.map .ruins { fill: var(--accent); fill-opacity: .13; stroke: var(--accent); stroke-opacity: .55; stroke-width: .8; }
.map .river { fill: none; stroke: var(--water); stroke-width: 3; }
.map .road { fill: none; stroke: var(--line); stroke-width: 1.4; }
.map .road-minor { fill: none; stroke: var(--line); stroke-width: .7; opacity: .7; }
.map .rail { fill: none; stroke: var(--muted); stroke-width: .8; stroke-dasharray: 4 3; }
.map .compass .cbg { fill: var(--bg); fill-opacity: .85; stroke: var(--line); stroke-width: 1; }
.map .compass path { fill: none; stroke: var(--ink); stroke-width: 1.2; stroke-linejoin: round; }
.map .compass .north { fill: var(--ink); }
.map .compass text { font-size: 11px; font-weight: 700; fill: var(--ink); font-family: var(--font-body); }
.map .scalebar path { fill: none; stroke: var(--ink); stroke-width: 1.5; }
.map .scalebar text { font-size: 11px; fill: var(--ink); font-family: var(--font-body); }
.map .pt { cursor: pointer; }
.map .pt circle { fill: var(--accent); stroke: var(--surface); stroke-width: 2; }
.map .pt .n { fill: var(--accent-ink); font-size: 12px; font-weight: 600; font-family: var(--font-body); pointer-events: none; }
.map .pt .plabel { font-size: 14px; font-weight: 700; fill: var(--accent); font-family: var(--font-body); paint-order: stroke; stroke: var(--surface); stroke-width: 4.5px; stroke-linejoin: round; }
.map .pt.acc-approximate circle { stroke: var(--accent); stroke-width: 2; paint-order: stroke; filter: none; fill-opacity: .65; }
.map .pt.acc-uncertain circle { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; stroke-dasharray: 3 2.5; }
.map .pt.acc-uncertain .n { fill: var(--ink); }
.map .pt.hub circle { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; }
.map .pt:hover circle, .map .pt:focus-visible circle { stroke: var(--ink); }
.map .pt:focus-visible { outline: none; }
.map .pt:focus-visible .plabel { text-decoration: underline; }
.map .lm-d { fill: var(--muted); stroke: var(--surface); stroke-width: 1.5; }
.map .lm-arrow { fill: var(--muted); stroke: var(--surface); stroke-width: 1; stroke-linejoin: round; }
.map .lm-t { font-size: 11px; font-style: italic; font-weight: 400; fill: var(--muted); font-family: var(--font-body); paint-order: stroke; stroke: var(--surface); stroke-width: 3.5px; stroke-linejoin: round; }
.map .lm-s { font-style: normal; font-size: 10px; fill: var(--muted); }
.map .leader { stroke: var(--accent); stroke-width: 1; fill: none; }
.map .true { fill: var(--accent); }
.map figcaption, .fig figcaption { font-size: .85rem; color: var(--muted); max-width: 40rem; margin-top: .4rem; }

.legend { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; list-style: none; padding: 0; margin: .5rem 0 1rem; font-size: .85rem; }
.legend li { display: flex; align-items: center; gap: .4rem; max-width: none; }
.legend li.k-names { display: block; flex-basis: 100%; max-width: 40rem; }
.legend svg { width: 22px; height: 22px; flex: none; }
.legend circle { fill: var(--accent); stroke: var(--accent); stroke-width: 2; }
.legend .k-approximate circle { fill-opacity: .65; }
.legend .k-landmark svg path { fill: var(--muted); stroke: var(--surface); stroke-width: 1; }
.legend .k-pointer svg path { fill: var(--muted); }
.bearings { padding-left: 1.2rem; }
.bearings li { margin: .25rem 0; max-width: none; }
/* The generated "On the map" key is included straight into the wide article, so give it the text column. */
.wide > #on-the-map, .wide > .bearings, .wide > .bearings + p { max-width: var(--col); margin-left: auto; margin-right: auto; }
.legend .k-uncertain circle { fill: var(--surface); stroke-dasharray: 3 2.5; }

/* Line figures: stroke only, in currentColor. The map-base classes (road, river, ruin) do not use non-scaling-stroke: it drew black shards in one browser on very large paths (update 75). */
.fig { margin: 1.5rem 0; color: var(--accent); }
.fig svg { display: block; width: 100%; max-width: 26rem; height: auto; }
.fig .line { fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.fig .line.thin { stroke-width: 1.25; }
.fig .line.heavy { stroke-width: 6; stroke-linecap: butt; }
.fig .glyph .line { stroke-linecap: round; }
.fig .road { fill: none; stroke: var(--muted); stroke-width: .7; stroke-opacity: .5; stroke-linejoin: round; }
.fig .road.major { stroke-width: 1; stroke-opacity: .65; }
.fig .river { fill: none; stroke: currentColor; stroke-opacity: .4; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.fig .ruin { fill: currentColor; fill-opacity: .06; stroke: currentColor; stroke-opacity: .35; stroke-width: .6; stroke-linejoin: round; }
.fig .sdot { fill: var(--muted); fill-opacity: .75; }
.fig .sdot.me { fill: currentColor; fill-opacity: 1; }
.fig .dash { fill: none; stroke: currentColor; stroke-width: 1.25; stroke-dasharray: 5 4; opacity: .75; vector-effect: non-scaling-stroke; }
.fig .lbl { fill: var(--ink); font-size: 12px; font-family: var(--font-body); paint-order: stroke; stroke: var(--bg); stroke-width: 3px; stroke-linejoin: round; }
.fig .lbl.faint { fill: var(--muted); font-size: 11px; }
.fig .lbl.ital { font-style: italic; }
.fig .wash { fill: currentColor; fill-opacity: .08; stroke: none; }
.fig .figsvg.fwide { max-width: 34rem; }
.fig .figsvg.fcol { max-width: none; }
.fig .lbl.faint.scl { font-size: 9px; stroke-width: 2.5px; }
.fig .lbl.faint.sea { font-size: 8px; font-style: italic; letter-spacing: .3px; stroke-width: 2.5px; }
.fig .compass .cbg { fill: var(--bg); fill-opacity: .85; stroke: var(--line); stroke-width: 1; }
.fig .compass path { fill: none; stroke: var(--ink); stroke-width: 1.2; stroke-linejoin: round; }
.fig .compass .north { fill: var(--ink); }
.fig .compass text { font-size: 11px; font-weight: 700; fill: var(--ink); font-family: var(--font-body); stroke: none; }
.fig .lbl.faint.cty { font-size: 8px; letter-spacing: .8px; stroke-width: 2.5px; }
.fig .bar { fill: currentColor; fill-opacity: .55; stroke: none; }
.fig .dot { stroke: var(--bg); stroke-width: 1; fill-opacity: .9; }
.fig .d-history { fill: var(--history); } .fig .d-comedy { fill: var(--comedy); } .fig .d-tragedy { fill: var(--tragedy); }
.fig .d-romance { fill: var(--romance); } .fig .d-london { fill: var(--london); } .fig .d-poem { fill: var(--poem); }
.fig a:hover .dot { stroke: var(--ink); stroke-width: 2; }
.fig figcaption { color: var(--muted); }

/* Footnotes and sources */
sup.fn { font-size: .7em; line-height: 0; }
sup.fn a { text-decoration: none; padding: 0 .1em; }
sup.fn.fn-next::before { content: ","; margin-right: .1em; }
.notes h2 { font-size: 1.4rem; }
.notelist { font-size: .9rem; padding-left: 1.4rem; }
.notelist li { margin: .35rem 0; max-width: 42rem; }
.notelist .back { text-decoration: none; margin-left: .25rem; }
.srclist { list-style: none; padding: 0; font-size: .9rem; }
.srclist li { margin: .75rem 0; max-width: 42rem; padding-left: .75rem; border-left: 2px solid var(--line); }
.srcnote { display: block; color: var(--muted); margin-top: .15rem; }
.srcnote strong { color: var(--ink); font-weight: 600; }
.notice { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); padding: .75rem 1rem; margin: 1.25rem 0; max-width: 40rem; }

/* Tables, forms, footer */
table { border-collapse: collapse; width: 100%; max-width: 46rem; font-size: .95rem; }
th, td { text-align: left; padding: .45rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 600; background: var(--surface); }
.search-form { display: flex; gap: .5rem; flex-wrap: wrap; margin: 1rem 0; }
.search-form input[type="search"] { font: inherit; padding: .45rem .7rem; border: 1px solid var(--muted); background: var(--surface); color: var(--ink); border-radius: 3px; min-width: 14rem; }
.search-form button { font: inherit; padding: .45rem 1rem; border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); border-radius: 3px; cursor: pointer; }
.results { list-style: none; padding: 0; }
.results li { margin: 1rem 0; max-width: 40rem; }
.results .where { font-size: .85rem; color: var(--muted); }
.site-footer { border-top: 1px solid var(--line); background: var(--surface); padding: 1.5rem 1.25rem; text-align: left; }
.site-footer p { margin: .35rem 0; }
.footer-nav { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; margin: .5rem 0; }
.footer-nav a { color: var(--ink); }
.footer-search { margin: .5rem 0; }

@media (max-width: 34rem) {
  .site-header { padding: .5rem .75rem; gap: .25rem .75rem; justify-content: space-between; }
  .brand { font-size: 1.35rem; }
  html { scroll-padding-top: 5.5rem; }
}

@media (max-width: 52rem) {
  .site-header { justify-content: space-between; }
  .site-header .top-links { display: none; }
  .when-wide { display: none; }
  .when-narrow { display: inline; }
  .maps-site { display: block; order: -1; }
  .maps-panel { max-height: calc(100vh - 3rem); max-height: 75vh; max-height: 75dvh; padding: 1rem .75rem; overscroll-behavior: contain; }
}

@media print {
  .site-header { position: static; }
  .site-header nav, .maps-menu, .site-footer form, .skip { display: none; }
  body { background: #fff; color: #000; }
}

/* Locator inset on a map (update 33): a coarse map of the surrounding region, with this map's extent marked */
.map .inset .isea { fill: var(--water); }
.map .inset .land { fill: var(--surface); stroke: var(--muted); stroke-width: .5; }
.map .inset .iext { fill: var(--history); fill-opacity: .25; stroke: var(--history); stroke-width: 1.2; }
.map .inset .iframe { fill: none; stroke: var(--muted); stroke-width: 1; }
.map .inset .ilabel { font-family: var(--font-body); font-size: 11px; font-style: italic; fill: var(--ink); paint-order: stroke; stroke: var(--surface); stroke-width: 3px; stroke-linejoin: round; }
.emblem { margin: .5rem 0 1rem; text-align: center; }
.masks { display: inline-block; width: 100%; max-width: 20rem; height: auto; color: var(--ink); }
/* Painted-style emblem: fixed warm colours (gold, red, silver, charcoal) in both colour schemes, like a picture. */
.masks .washes ellipse { opacity: .38; }
.masks .w1 { fill: #d8382f; } .masks .w2 { fill: #f0b943; } .masks .w3 { fill: #8a8a92; opacity: .30; } .masks .w4 { fill: #e0a02c; } .masks .w5 { fill: #c0392b; opacity: .3; }
.masks .dot.red { fill: #c8302a; opacity: .75; } .masks .dot.gold { fill: #e3a82e; opacity: .85; }
.masks .face { stroke: #2a1d14; stroke-width: 3.4; stroke-linejoin: round; }
.masks .comic .face { fill: url(#mkGold); }
.masks .tragic .face { fill: url(#mkSilver); }
.masks .washred { fill: #d63a30; opacity: .5; }
.masks .washdark { fill: #2c2c34; opacity: .32; }
.masks .washgold { fill: #e6b04a; opacity: .5; }
.masks .gloss { fill: #fff; opacity: .35; }
.masks .rim { fill: none; stroke-width: 1.8; }
.masks .comic .rim { stroke: #b3261e; }
.masks .tragic .rim { stroke: #c9953a; }
.masks .paper { fill: #fff7e6; stroke: #2a1d14; stroke-width: 1; stroke-linejoin: round; }
.masks .line { fill: none; stroke: #2a1d14; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.masks .thin { fill: none; stroke: #2a1d14; stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; opacity: .85; }
.masks .solid { fill: #2a1d14; stroke: #2a1d14; stroke-width: 1.4; stroke-linejoin: round; }
.masks .ribbon path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.masks .ribbon.red .o { stroke: #7e1914; stroke-width: 15; } .masks .ribbon.red .i { stroke: #d6362c; stroke-width: 10; } .masks .ribbon.red .h { stroke: #ff9b8c; stroke-width: 2; opacity: .7; }
.masks .ribbon.gold .o { stroke: #84560f; stroke-width: 15; } .masks .ribbon.gold .i { stroke: #efb843; stroke-width: 10; } .masks .ribbon.gold .h { stroke: #fff0b0; stroke-width: 2; opacity: .75; }

/* Notes in the right margin on wide screens (assets/sidenotes.js adds html.has-sidenotes).
   Below 72rem, or without scripts, the list of notes at the foot of the page is used as before. */
.sidenote { display: none; }
@media screen and (min-width: 72rem) {
  html.has-sidenotes main { position: relative; }
  html.has-sidenotes .notes-fn { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  html.has-sidenotes .sidenote { display: block; position: absolute; font-size: .8rem; line-height: 1.4; color: var(--muted);
    border-left: 2px solid var(--line); padding-left: .6rem; max-width: none; }
  html.has-sidenotes .sidenote .num { color: var(--accent); font-weight: 600; margin-right: .25rem; }
  html.has-sidenotes .sidenote .rd { display: block; margin-top: .15rem; font-size: .72rem; letter-spacing: .02em; color: var(--accent); }
  html.has-sidenotes .sidenote.hot { color: var(--ink); border-left-color: var(--accent); background: var(--bg); z-index: 2; }
  html.has-sidenotes .sidenote.compact:not(.hot) { max-height: 2.8em; overflow: hidden; }
  html.has-sidenotes .sidenote.compact:not(.hot) .rd { display: none; }
}
@media print { .sidenote { display: none !important; } }

/* Source jump link in a note, and the entry it lands on. */
.srcjump { font-size: .78em; white-space: nowrap; margin-left: .15em; }
.srclist li:target { border-left-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, transparent); }
@media screen and (min-width: 72rem) {
  html.has-sidenotes .sidenote .srcjump { display: inline; }
  html.has-sidenotes .sidenote.compact:not(.hot) .srcjump { display: none; }
}

/* The play in brief: an aside above the map, in the left margin on wide screens. */
.inbrief { margin: 1.25rem 0; padding-left: .85rem; border-left: 2px solid var(--line); font-size: .92rem; color: var(--muted); }
.inbrief p { margin: .4rem 0; }
.inbrief .inbrief-h { font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin: 0 0 .35rem; }
@media screen and (min-width: 88rem) {
  .col:has(> .inbrief) { position: relative; }
  .inbrief { position: absolute; top: .3rem; right: calc(100% + 2rem); width: 15rem; margin: 0; padding: 0 .85rem 0 0; border-left: 0; border-right: 2px solid var(--line); font-size: .8rem; line-height: 1.5; text-align: left; }
}
@media screen and (min-width: 100rem) {
  .inbrief { width: 18rem; }
}
@media print { .inbrief { position: static; width: auto; } }

/* Glossary page. */
.glossary .glfilter { margin: 1rem 0; }
.glossary .glfilter button.chip { cursor: pointer; font: inherit; font-size: .8rem; }
.glossary .glfilter button.chip.on { border-color: var(--accent); color: var(--accent); }
.glossary .glfilter input[type="search"] { font: inherit; padding: .25rem .5rem; border: 1px solid var(--line); border-radius: 4px; background: var(--surface); color: var(--ink); min-width: 14rem; }
.glossary .glletters { display: flex; flex-wrap: wrap; gap: .15rem .6rem; margin: 1rem 0; padding: .45rem 0; font-size: .95rem; position: sticky; top: var(--hdr, 3.7rem); z-index: 10; background: var(--bg); border-bottom: 1px solid var(--line); }
html:has(.glossary) { scroll-padding-top: 10rem; }
.glossary .glsec > h2 { border-bottom: 1px solid var(--line); padding-bottom: .15rem; }
.glossary article.gl { margin: 1rem 0; padding: .1rem 0 .1rem .75rem; border-left: 2px solid var(--line); }
.glossary article.gl:target { border-left-color: var(--accent); }
.glossary article.gl h3 { margin: 0 0 .15rem; font-size: 1.05rem; }
.glossary article.gl p { margin: .25rem 0; }
.glossary .gtags { font-size: .85rem; }
.glossary .galt { font-size: .9rem; color: var(--muted); }
.glossary .gsee { font-size: .9rem; }
.glossary a.gsrc { font-size: .74rem; color: var(--muted); text-decoration: none; border: 1px solid var(--line); border-radius: 3px; padding: 0 .3rem; overflow-wrap: anywhere; }
.glossary a.gsrc:hover, .glossary a.gsrc:focus { color: var(--accent); border-color: var(--accent); }
.glossary a.gsrc .rd { opacity: .85; }
[hidden] { display: none !important; }
