/* film-reference.com — one stylesheet. Dense, text-first, bbref-style. */
* { box-sizing: border-box; }
html { font-size: 13px; }
body {
  margin: 0;
  background: #fff;
  color: #000;
  font-family: Verdana, Geneva, "DejaVu Sans", sans-serif;
  line-height: 1.35;
}
a { color: #00419e; text-decoration: none; }
a:hover { text-decoration: underline; }
a:visited { color: #3d2b8f; }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 12px; }

header.site { background: #f3f3f3; border-bottom: 1px solid #ccc; }
header.site .wrap { display: flex; align-items: center; gap: 18px; padding-top: 6px; padding-bottom: 6px; flex-wrap: wrap; }
.logo { font-weight: bold; font-size: 1.5rem; color: #000 !important; letter-spacing: -0.5px; }
.logo span { color: #9e1b1b; }
header nav a { margin-right: 12px; font-weight: bold; }
form.search { margin-left: auto; display: flex; gap: 4px; }
form.search input { width: 260px; padding: 3px 5px; font: inherit; border: 1px solid #999; }
form.search { position: relative; }
ul.suggest { position: absolute; top: 100%; left: 0; right: 0; z-index: 10; margin: 1px 0 0; padding: 0;
  list-style: none; background: #fff; border: 1px solid #999; box-shadow: 0 2px 4px rgba(0,0,0,.15); }
ul.suggest li a { display: flex; justify-content: space-between; gap: 8px; padding: 3px 6px; color: #000; }
ul.suggest li.active a, ul.suggest li a:hover { background: #fff7cc; text-decoration: none; }
ul.suggest .kind { color: #777; font-size: 0.8rem; }
form.search button { font: inherit; padding: 3px 8px; border: 1px solid #999; background: #fff; cursor: pointer; }

main { padding-top: 10px; padding-bottom: 20px; }
h1 { font-size: 1.85rem; margin: 6px 0 4px; }
h2 { font-size: 1.25rem; margin: 18px 0 4px; padding-bottom: 2px; border-bottom: 2px solid #9e1b1b; }
h3 { font-size: 1.05rem; margin: 12px 0 4px; }
p { margin: 4px 0 8px; }
.lede { font-size: 1.05rem; }
.notice { background: #fffbe6; border: 1px solid #e6d27a; padding: 6px 8px; }
.muted { color: #555; }

/* Header card on film / person pages */
.meta { border: 1px solid #ccc; background: #fafafa; padding: 8px 10px; margin: 6px 0 10px; display: flex; gap: 14px; }
.meta img.poster { width: 110px; height: auto; border: 1px solid #ccc; }
.meta p { margin: 2px 0; }
.meta strong { font-weight: bold; }

/* Box score strip */
table.box { border-collapse: collapse; margin: 6px 0 10px; }
table.box th, table.box td { border: 1px solid #ccc; padding: 3px 10px; text-align: center; }
table.box th { background: #eee; font-size: 0.85rem; }
table.box td { font-weight: bold; font-size: 1.1rem; }

/* Stats tables */
.table-wrap { overflow-x: auto; margin: 4px 0 12px; }
table.stats { border-collapse: collapse; font-size: 0.92rem; width: auto; min-width: 50%; }
table.stats caption { text-align: left; font-weight: bold; padding: 2px 0; }
table.stats th, table.stats td { border: 1px solid #ddd; padding: 2px 6px; white-space: nowrap; }
table.stats thead th { background: #e8e8e8; border-bottom: 2px solid #888; text-align: center; font-weight: bold; }
table.stats thead th.sortable { cursor: pointer; user-select: none; }
table.stats thead th.sortable:hover { background: #d8d8d8; }
table.stats thead th.asc::after { content: " \25B2"; font-size: 0.7em; }
table.stats thead th.desc::after { content: " \25BC"; font-size: 0.7em; }
table.stats tbody tr:nth-child(even) { background: #f5f5f5; }
table.stats tbody tr:hover { background: #fff7cc; }
table.stats td.num, table.stats th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.stats td.left { text-align: left; }
table.stats td.rank { text-align: right; color: #555; }
table.stats tfoot td { background: #eee; font-weight: bold; border-top: 2px solid #888; }
table.stats td.wrap-ok { white-space: normal; }

.cols { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 4px 20px; align-items: start; }
.cols > div { min-width: 0; }
.cols table.stats { min-width: 0; width: 100%; }
.cols table.stats td.left { white-space: normal; }
ul.inline { list-style: none; padding: 0; margin: 4px 0; }
ul.inline li { display: inline; margin-right: 10px; }
.tabs a { display: inline-block; padding: 3px 10px; border: 1px solid #ccc; border-bottom: none; background: #f3f3f3; margin-right: 2px; }

.tabs a.current { background: #fff; font-weight: bold; color: #000; }
table.stats.leader caption a { color: #000; }
table.stats tbody tr.won td { font-weight: bold; }
table.stats tbody tr:target { background: #fff0a8; }
p.more { margin: -8px 0 10px; font-size: 0.85rem; }
p.pager { margin: 6px 0; }
p.pager a { margin: 0 8px; }
a.rank { font-size: 0.8rem; color: #555; }

ul.sources { font-size: 0.85rem; color: #444; margin: 4px 0; padding-left: 18px; }

footer.site { border-top: 1px solid #ccc; background: #f3f3f3; font-size: 0.85rem; color: #333; padding: 8px 0 14px; }
footer.site p { margin: 3px 0; }

@media (max-width: 640px) {
  form.search { margin-left: 0; width: 100%; }
  form.search input { flex: 1; width: auto; }
  .meta { flex-direction: column; }
  table.box { display: block; overflow-x: auto; max-width: 100%; }
  table.box th, table.box td { padding: 3px 6px; }
  .cols { grid-template-columns: 1fr; }
}

form.inline { margin: 6px 0 10px; }
form.inline input[type=search] { padding: 3px 6px; width: 260px; max-width: 70%; }
ul.dna { padding-left: 18px; }
ul.dna li { margin: 4px 0 8px; }
blockquote.cite { margin: 4px 0 6px 0; padding: 4px 10px; border-left: 3px solid #ccc; background: #f7f7f7; font-style: italic; }
blockquote.cite footer { font-style: normal; font-size: 0.9em; margin-top: 2px; }
.small { font-size: 0.85em; }
table.stats tr.set td { background: #f0f0f0; }
header.site .account { margin-left: auto; font-size: 0.9em; }
header.site .account a { color: inherit; }
form.pin { display: inline-block; margin: 0 0 8px; }
form.pin.inline { margin: 0 0 0 6px; }
form.pin button { font-size: 0.85em; padding: 1px 8px; cursor: pointer; background: #fff; border: 1px solid #bbb; border-radius: 3px; }
form.pin button.on { background: #fff4c2; border-color: #d4b106; }
form.pin button.unpin { padding: 0 5px; border: none; background: none; color: #999; }
ul.pins { list-style: none; padding-left: 0; margin: 4px 0 10px; }
ul.pins li { margin: 2px 0; }
.pin-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 0 18px; }
.pin-groups h3 { margin: 6px 0 2px; font-size: 1em; }
.welcome { max-width: 380px; }
.welcome label { display: block; margin: 8px 0; }
.welcome input[type=text], .welcome input[type=password] { display: block; width: 100%; padding: 5px; box-sizing: border-box; }
.welcome .error { color: #b00020; }
.welcome textarea { display: block; width: 100%; box-sizing: border-box; padding: 5px; font: inherit; }
fieldset.kinds { border: none; padding: 0; margin: 8px 0; }
fieldset.kinds label { display: block; margin: 3px 0; }
.ok { color: #1b6e2b; }
form.status-form input[type=text] { width: 120px; }
td.feedback-msg { white-space: pre-wrap; max-width: 420px; }
table.grid-board { border-collapse: collapse; margin: 8px 0 12px; table-layout: fixed; width: 100%; max-width: 760px; }
table.grid-board th { padding: 6px; font-size: 0.9em; background: #f0f0f0; border: 1px solid #ccc; vertical-align: bottom; }
table.grid-board th.row { text-align: right; width: 22%; }
table.grid-board td.cell { border: 1px solid #ccc; height: 96px; text-align: center; vertical-align: middle; padding: 4px; font-size: 0.9em; }
table.grid-board td.solved { background: #e8f5e9; }
table.grid-board td.picking { outline: 3px solid #d4b106; }
.rarity { font-weight: bold; color: #1b6e2b; margin-top: 2px; }
.top-answers { font-size: 0.8em; margin-top: 3px; }
pre.share { background: #f7f7f7; padding: 8px; display: inline-block; }
.grid-promo { border: 2px solid #d4b106; background: #fffbea; padding: 8px 12px; margin: 10px 0; }
.grid-promo h2 { margin: 0 0 4px; border: none; }
a.button { display: inline-block; background: #1a1a1a; color: #fff; padding: 4px 10px; border-radius: 3px; text-decoration: none; }
.daily .feature { border: 1px solid #ddd; padding: 6px 10px; }
.daily h3 { margin: 0 0 4px; font-size: 0.85em; text-transform: uppercase; color: #777; }
.feature-title { font-size: 1.15em; margin: 0 0 4px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px; margin: 6px 0 12px; }
.tile { display: block; border: 1px solid #ddd; padding: 6px 8px; text-decoration: none; }
.tile strong { display: block; }
.tile:hover { background: #f5f5f5; }
