/* The all-games page (/games/): the home page's chalkboard, with a search
   box, over one long list. It borrows rooms.css for the colours, type and
   drawings; each row's tile is drawn in its game's room, so the list reads
   as the same places as the home page's cards, just smaller. */

.games-page{min-height:100vh;display:flex;flex-direction:column}
.vh{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

/* ---------- the board: the way home, the name, the search ---------- */
/* the board clips its chalk dust, so in the page's column it mustn't be squeezed */
.games-page .board{flex:none;padding-bottom:clamp(20px,3vw,30px)}
.games-page .board-in{max-width:860px;gap:14px}
.games-page .backlink.mark{justify-self:start;margin-left:-6px}
.games-head{display:grid;gap:6px;padding-right:44px} /* clear of the account bubble */
.games-head .kicker{font:700 11px/1 var(--f-deco);letter-spacing:.2em;text-transform:uppercase;color:var(--brass)}
.games-head h1{
  margin:0;font:400 clamp(38px,8vw,64px)/1 var(--f-chalk);color:var(--chalk);
  text-shadow:0 0 1px #fff6, 0 0 14px #ffffff14;
}
.find input{
  width:100%;font:500 17px/1.2 var(--f-body);color:var(--chalk);
  background:#ffffff0d;border:1.5px solid #ecebe355;border-radius:6px;
  padding:13px 14px 13px 42px;
  /* a chalk magnifier, drawn in the box */
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a7b0a9' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='10' cy='10' r='6.5'/%3E%3Cpath d='M15 15l5.5 5.5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:13px 50%;background-size:19px;
}
.find input::placeholder{color:var(--chalk-dim);opacity:.85}
.find input:focus{outline:none;border-color:var(--brass);background-color:#ffffff14}
.find input::-webkit-search-cancel-button{filter:invert(1) opacity(.6)}
.count{margin:0;font:600 12px/1 var(--f-deco);letter-spacing:.14em;text-transform:uppercase;color:var(--chalk-dim)}

/* ---------- the list ---------- */
.games{flex:1;padding:clamp(18px,3vw,30px) max(16px,4vw) 36px}
.game-list{list-style:none;margin:0 auto;padding:0;max-width:860px;display:grid;gap:2px}
.game-list li[hidden]{display:none}
.game-row{
  display:grid;grid-template-columns:64px minmax(0,1fr);column-gap:16px;row-gap:4px;align-items:center;
  padding:12px 10px;border-radius:6px;text-decoration:none;color:var(--chalk);
  border-bottom:1px dashed #ecebe324;transition:background .15s ease;
}
.game-list li:last-child .game-row{border-bottom:none}
.game-row:hover{background:#ffffff0a}
.game-row .what{display:grid;gap:3px;min-width:0}
.game-row b{font:700 19px/1.15 var(--f-body);color:var(--chalk)}
.game-row small{font:500 14px/1.4 var(--f-body);color:var(--chalk-dim)}
.room-tag{grid-column:2;font:700 10.5px/1 var(--f-deco);letter-spacing:.14em;text-transform:uppercase}
.parlor-tag{color:var(--brass)}
.living-tag{color:#e9b3a8}   /* the living room's red ink, lifted to read on slate */
.workshop-tag{color:#8fc3b3}
.game-row:hover b{color:#fff}
/* on a wider screen the room sits at the end of the row instead of under it */
@media (min-width:640px){
  .game-row{grid-template-columns:72px minmax(0,1fr) auto;padding:14px 14px;column-gap:20px}
  .room-tag{grid-column:3;text-align:right;white-space:nowrap}
  .game-row b{font-size:21px}
  .game-row small{font-size:15px}
}

/* the tiles: a small framed slate, a taped slip of legal pad, a scrap of graph paper */
.tile{grid-row:1 / span 2;width:64px;height:64px;display:grid;place-items:center;border-radius:3px}
@media (min-width:640px){.tile{width:72px;height:72px}}
.tile svg{width:78%;height:78%}
.tile-parlor{background:var(--slate-2);border:4px solid #5d4128;box-shadow:0 4px 10px #0007, inset 0 0 0 1px #0006}
.tile-living{
  background:#fffdf2;border:1px solid #d8cfa3;box-shadow:0 4px 10px #0006;transform:rotate(-1.5deg);
  background-image:repeating-linear-gradient(180deg, transparent 0 13px, #e2e9f1 13px 14px);
}
.game-list li:nth-child(even) .tile-living{transform:rotate(1.2deg)}
.tile-workshop{
  border:1.5px solid var(--graph-ink);box-shadow:0 4px 10px #0006;
  background:
    linear-gradient(var(--graph-line) 1px, transparent 1px) 0 0/9px 9px,
    linear-gradient(90deg, var(--graph-line) 1px, transparent 1px) 0 0/9px 9px,
    var(--graph);
}
.ws-line{fill:none;stroke:var(--graph-ink);stroke-width:2.4;stroke-linejoin:round}
.ws-accent{fill:none;stroke:#2f6d5c;stroke-width:4;stroke-linecap:round}

/* the Builder row stays put after a search, set apart from the matches */
.game-list li.any{margin-top:10px;border-top:1px solid #ecebe330;padding-top:10px}
.none{max-width:860px;margin:6px auto 0;padding:0 10px;font:500 15px/1.5 var(--f-body);color:var(--chalk-dim)}
.none[hidden]{display:none}

.games-foot{padding:6px 16px calc(22px + var(--pad, 0px));text-align:center}
.games-foot .legal-links{margin:0;font-size:12.5px;color:var(--chalk-dim)}
