/* SLOP GAMES home. One calm system: dark panels, one accent (lime), one support colour (pink). */
:root{--bg:#1c0f2e;--panel:#26173b;--panel-2:#2f1e48;--line:#ffffff1f;--ink:#13091f;--text:#efe6f8;--muted:#b6a6ca;--lime:#d8f244;--grape:#8b3fe0;--sun:#ffd23f;--pink:#ff6a9c;--fun:'Fredoka',system-ui,sans-serif;--mono:'Rubik Mono One',var(--fun);--r:14px}
*{box-sizing:border-box}
html{background:var(--bg);scroll-behavior:smooth;scroll-padding-top:76px;scrollbar-gutter:stable}
body{margin:0;min-height:100vh;color:var(--text);font:500 16px/1.55 var(--fun);background:var(--bg) radial-gradient(#ffffff0d 1.5px,transparent 1.6px) 0 0/22px 22px}
a{color:inherit;text-decoration:none}
img{display:block;max-width:100%}
.wrap{width:min(1760px,100% - 64px);margin:0 auto}

/* buttons: one height, one radius, one weight */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;height:42px;padding:0 16px;border:1.5px solid var(--line);border-radius:10px;background:transparent;color:var(--text);font:600 15px/1 var(--fun);white-space:nowrap;cursor:pointer;transition:background .15s,border-color .15s,transform .15s}
.btn:hover{background:#ffffff12;border-color:#ffffff40}
.btn img{width:22px;height:22px}
.btn.support{border-color:var(--pink);color:var(--pink)}
.btn.support:hover{background:var(--pink);color:var(--ink)}

/* header: logo, one line of purpose, two actions */
.top{display:flex;align-items:center;gap:28px;padding:22px 0 18px}
.mark{display:flex;align-items:center;gap:12px;direction:ltr;flex:none}
.mark img{width:58px;height:auto}
.mark .slop{font:52px/.85 'Rubik Wet Paint',var(--fun);color:var(--lime);text-shadow:3px 3px 0 var(--ink)}
.mark .games{display:block;font:15px/1 var(--mono);color:var(--text);letter-spacing:.04em;margin-top:5px}
.lede{flex:1;margin:0;max-width:560px;color:var(--muted);font-size:16px;line-height:1.5}
.lede b{display:block;color:var(--text);font-weight:600;font-size:18px}
.top-actions{margin-inline-start:auto;flex:none;display:flex;gap:10px}
.h1{margin:0;font-size:inherit;font-weight:inherit}

/* category bar */
.cats{position:sticky;top:0;z-index:5;margin:0 0 6px;padding:10px 24px;background:#1c0f2ecc;backdrop-filter:blur(8px);border-bottom:1px solid var(--line)}
.cats-in{display:flex;align-items:center;gap:14px;width:min(1760px,100%);margin:0 auto}
.cats ul{display:flex;gap:8px;margin:0;padding:0;list-style:none;flex:1;min-width:0;overflow-x:auto;scrollbar-width:none}
.view{flex:none;display:flex;padding:3px;border:1.5px solid var(--line);border-radius:999px}
.view button{height:30px;padding:0 13px;border:0;border-radius:999px;background:transparent;color:var(--muted);font:600 13.5px/1 var(--fun);cursor:pointer;white-space:nowrap;transition:background .15s,color .15s}
.view button:hover{color:var(--text)}
.view button[aria-pressed=true]{background:var(--text);color:var(--ink)}
.cats a{display:inline-flex;align-items:center;gap:8px;height:36px;padding:0 14px;border:1.5px solid var(--line);border-radius:999px;color:var(--text);font:600 14px/1 var(--fun);white-space:nowrap;transition:background .15s,border-color .15s}
.cats a:hover{background:#ffffff12;border-color:#ffffff40}
.cats a.on{background:var(--lime);border-color:var(--lime);color:var(--ink)}
.cats small{font:600 12px/1 var(--fun);color:var(--muted)}
.cats a.on small{color:#3d4a00}

/* category sections */
/* the cards keep one comfortable size and as many fit as the screen allows */
#games{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(280px,100%),1fr));gap:0 24px;grid-auto-flow:dense;align-items:start}
/* a category is as wide as its games (1 to 4 columns), so short ones sit side by side and a new game widens its category by itself */
/* every category has its own full row; the cards keep one size, so a small category leaves room instead of sharing its row */
.cat{grid-column:1/-1;padding:30px 0 6px;min-width:0}
#games>.cat:first-child{padding-top:24px}
.cat-head{display:flex;align-items:baseline;gap:14px;flex-wrap:nowrap;height:34px;margin-bottom:14px;overflow:hidden}
.cat-head h2{white-space:nowrap}
.cat-head p{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cat-head h2{margin:0;font:700 24px/1.2 var(--fun)}
.cat-head p{margin:0;color:var(--muted);font-size:15px}
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(280px,100%),1fr));gap:24px;align-items:stretch}
@media(max-width:639px){#games,.grid{grid-template-columns:minmax(0,1fr)}}

/* the flat view: every card on one shelf, in like order (slop.js sets the order) */
body.flat .cats ul{display:none}
body.flat .cats-in{justify-content:flex-end}
body.flat #games{row-gap:24px;padding-top:24px}
body.flat .cat{display:contents}
body.flat .cat-head{display:none}
body.flat .grid{display:contents}

/* a game card */
.game{position:relative;height:100%;display:flex;flex-direction:column;overflow:hidden;background:var(--panel);border:1px solid var(--line);border-radius:var(--r);transition:border-color .2s,transform .2s,box-shadow .2s}
.game:hover{border-color:#ffffff4d;transform:translateY(-2px);box-shadow:0 10px 28px #0006}
.shot{position:relative;display:block;aspect-ratio:16/10;overflow:hidden;background:#000}
.shot img{width:100%;height:100%;object-fit:cover;transition:transform .5s cubic-bezier(.2,.7,.2,1)}
.game:hover .shot img{transform:scale(1.04)}
.shot .logo{position:absolute;inset:auto auto 10px 10px;width:44%;height:auto;object-fit:contain;filter:drop-shadow(0 6px 10px #000b)}
.pill,.top-pick{position:absolute;top:10px;z-index:2;padding:5px 10px;border-radius:999px;font:700 12px/1 var(--fun)}
.pill{right:10px;background:var(--pink);color:var(--ink)}
.pill.soon{background:var(--sun)}
.top-pick{left:10px;background:#13091fcc;color:var(--lime);border:1px solid #d8f24466;backdrop-filter:blur(4px)}
.body{display:flex;flex-direction:column;gap:8px;flex:1;padding:14px 16px 16px;container-type:inline-size}
.body h3{margin:0;font:700 22px/1.2 var(--fun);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.body h3 a:hover{color:var(--lime)}
.desc{margin:0;color:#dccfec;font-size:14.5px;line-height:1.5;height:3em;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.chips{display:flex;flex-wrap:nowrap;gap:6px;height:26px;margin:0;padding:0;list-style:none;overflow:hidden}
.chips li{white-space:nowrap;padding:4px 9px;border-radius:6px;background:#ffffff14;color:var(--muted);font:600 12.5px/1.2 var(--fun)}
.actions{margin-top:auto;padding-top:6px;display:flex;align-items:stretch;gap:8px;min-width:0}
.actions>*{box-sizing:border-box;height:40px;min-width:0}
.play{flex:1 1 auto;display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:0 12px;border-radius:10px;background:var(--lime);color:var(--ink);font:700 16px/1 var(--fun);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;transition:filter .15s,transform .15s}
.play:hover{filter:brightness(1.08);transform:translateY(-1px)}
.play[aria-disabled=true]{background:#ffffff14;color:var(--muted);pointer-events:none}
.info{flex:none;display:inline-flex;align-items:center;padding:0 12px;border:1.5px solid var(--line);border-radius:10px;color:var(--text);font:600 13.5px/1 var(--fun);white-space:nowrap;transition:background .15s}
.info:hover{background:#ffffff12}
.like{flex:none;display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:0 11px;border:1.5px solid var(--line);border-radius:10px;background:transparent;color:var(--text);font:600 14px/1 var(--fun);cursor:pointer;transition:background .15s,border-color .15s}
.like:hover{background:#ffffff12}
.like .heart{font-size:15px;line-height:1;filter:grayscale(1) brightness(1.5)}
.like[aria-pressed=true]{border-color:var(--pink);background:#ff6a9c26}
.like[aria-pressed=true] .heart{filter:none;animation:pop .4s cubic-bezier(.3,1.6,.5,1)}
.like .n{min-width:1ch;font-variant-numeric:tabular-nums}
.like[disabled]{opacity:.6;cursor:default}
@keyframes pop{0%{transform:scale(.4)}100%{transform:scale(1)}}
.burst{position:absolute;pointer-events:none;font-size:15px;animation:fly .75s ease-out forwards}
@keyframes fly{to{transform:translate(var(--dx),var(--dy)) scale(.4);opacity:0}}
.game.soon .shot img{filter:saturate(.5)}
@container (max-width:270px){.actions{gap:6px}.play{padding:0 8px;font-size:15px}.info{padding:0 8px;font-size:12.5px}.like{padding:0 8px;gap:4px}}
.note{margin:20px 0 0;color:var(--muted);font-size:14px}

/* info panels: questions, supporters, studio */
.panel{margin:34px 0 0;padding:22px 26px;background:var(--panel);border:1px solid var(--line);border-radius:var(--r)}
.panel h2{margin:0 0 8px;font:700 22px/1.2 var(--fun)}
.panel>p{margin:0 0 14px;color:#dccfec}
.faq details{border-top:1px solid var(--line);padding:11px 0}
.faq details:first-of-type{margin-top:10px}
.faq summary{cursor:pointer;font:600 17px/1.35 var(--fun)}
.faq p{margin:8px 0 0;color:#dccfec;font-size:15px}
section.support{display:grid;grid-template-columns:1fr auto;gap:6px 24px;align-items:center}
section.support h2,section.support>p,section.support .donors-list{grid-column:1}
section.support .give-btn{grid-column:2;grid-row:1/4;align-self:center}
.donors-list{display:flex;flex-wrap:wrap;gap:8px;margin:0;padding:0;list-style:none}
.donors-list:empty{display:none}
.donors-list li{padding:6px 12px;border:1px solid var(--line);border-radius:999px;background:#ffffff0f;font:600 14px/1.2 var(--fun)}
.donors-list li.anon{border-style:dashed;color:var(--muted);font-weight:500}
.give-btn{display:inline-flex;align-items:center;justify-content:center;height:44px;padding:0 20px;border-radius:10px;background:var(--pink);color:var(--ink);font:700 16px/1 var(--fun);white-space:nowrap;transition:filter .15s}
.give-btn:hover{filter:brightness(1.08)}
.studio{display:flex;align-items:center;gap:16px;flex-wrap:wrap}
.studio>img{width:44px;height:44px}
.studio p{flex:1;margin:0;min-width:220px;color:var(--muted);font-size:15px}
.studio p b{display:block;color:var(--text);font-size:17px}

footer{display:flex;justify-content:space-between;gap:10px 18px;flex-wrap:wrap;padding:26px 0 40px;color:var(--muted);font-size:14px}
footer a{color:var(--text);text-decoration:underline;text-underline-offset:3px}
footer a:hover{color:var(--lime)}

.skip{position:absolute;right:12px;top:-60px;z-index:10;padding:10px 14px;border-radius:10px;background:var(--lime);color:var(--ink);font-weight:700}
.skip:focus{top:12px}
:focus-visible{outline:2px solid var(--lime);outline-offset:3px}
.sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}

@media(max-width:900px){
  .top{flex-wrap:wrap;gap:12px 16px;padding-top:16px}
  .lede{order:3;flex-basis:100%;max-width:none;font-size:15px}
  .mark .slop{font-size:44px}.mark img{width:50px}.mark .games{font-size:13px}
  section.support{grid-template-columns:1fr}section.support .give-btn{grid-column:1;grid-row:auto;justify-self:start;margin-top:6px}
}
@media(max-width:560px){
  .wrap{width:calc(100% - 28px)}
  .cats{margin:0 0 4px;padding:8px 14px}
  .cats-in{gap:8px}
  .view button{padding:0 10px;font-size:12.5px}
  .btn{height:38px;padding:0 12px;font-size:14px}
  .btn.support span{display:none}
  .cat{padding-top:24px}
  .cat-head h2{font-size:21px}
  .cat-head p{display:none}
  .grid{gap:12px}
  /* phones: compact rows, a picture on one side and the game on the other */
  .game{display:grid;grid-template-columns:38% 1fr}
  .shot{aspect-ratio:auto;height:100%;min-height:150px}
  .shot .logo{width:80%;inset:auto auto 6px 6px}
  .pill,.top-pick{font-size:11px;padding:4px 8px;top:6px}.pill{right:6px}.top-pick{left:6px}
  .game{min-height:218px}
  .body{padding:10px 12px 12px;gap:6px}
  .body h3{font-size:19px}
  .desc{font-size:13.5px;height:2.9em}
  .chips li{font-size:11.5px;padding:3px 7px}
  .actions{flex-wrap:wrap;gap:6px}.actions>*{height:38px}
  .play{flex-basis:100%}.info{flex:1;justify-content:center}
  .panel{padding:18px 16px}
}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important;scroll-behavior:auto!important}}

/* first visit only: the cards keep their places as empty boxes for a moment, until the likes say the order */
#games.sorting .game{visibility:hidden;position:relative}
#games.sorting .game::after{content:"";visibility:visible;position:absolute;inset:0;border-radius:var(--r);background:#ffffff0f;animation:slot 1s ease-in-out infinite alternate}
@keyframes slot{to{background:#ffffff05}}
@media(prefers-reduced-motion:reduce){#games.sorting .game::after{animation:none}}
.game.opens{cursor:pointer}
.game.opens:hover h3 a{text-decoration:underline;text-underline-offset:3px}

/* the like sits on the picture's top-left corner; "לשחק" and "קראו עוד" share the bottom row evenly */
.actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.actions>.play,.actions>.info{width:100%;height:44px;justify-content:center;padding:0 10px}
.actions>.play{font-size:16.5px}
.actions>.info{font-size:15px}
.actions:has(.play[aria-disabled=true]){grid-template-columns:1fr}
.game .like{position:absolute;top:10px;left:10px;z-index:3;height:34px;padding:0 11px;border-color:#ffffff40;background:#13091fcc;backdrop-filter:blur(4px);box-shadow:0 2px 8px #0006}
.game .like:hover{background:#2a1a40e6}
.game .like[aria-pressed=true]{border-color:var(--pink);background:#3a1430e6}
/* the "most liked" badge moves to the right corner, under "חדש" when a game has both */
.top-pick{left:auto;right:10px}
.shot .pill~.top-pick{top:42px}
/* phones: the picture is the right-hand column, so the like sits on its bottom corner */
@media(max-width:560px){.actions{gap:8px}.actions>.play,.actions>.info{height:40px}.actions>.info{font-size:14px}.game .like{top:auto;bottom:8px;left:auto;right:8px;height:30px;padding:0 9px}.top-pick{left:auto;right:6px}.shot .pill~.top-pick{top:34px}}

/* a bigger SLOP GAMES mark fills the header; the view switch sits with the header buttons, and the category bar shows only in the category view */
.top{padding:26px 0 22px;gap:36px}
.mark{gap:16px}
.mark img{width:92px}
.mark .slop{font-size:84px;line-height:.8}
.mark .games{font-size:22px;letter-spacing:.08em;margin-top:12px}
.lede{font-size:17px;max-width:760px}.lede b{font-size:23px;line-height:1.3;margin-bottom:4px}
.top-actions{align-items:center}
.top-actions .view{padding:4px}
.top-actions .view button{height:36px;padding:0 16px;font-size:15px}
/* the category bar is gone in both views: the "סוג" filter does its job, so switching views never moves the page */
.cats{display:none}
@media(max-width:900px){.top{flex-wrap:wrap;gap:16px 24px}.top-actions{margin-inline-start:0;flex:1 1 100%;flex-wrap:wrap}.mark img{width:70px}.mark .slop{font-size:64px}.mark .games{font-size:18px}}
@media(max-width:560px){.mark img{width:54px}.mark .slop{font-size:48px}.mark .games{font-size:14px;margin-top:8px}.lede{font-size:15px}.top-actions .view button{height:32px;padding:0 11px;font-size:13px}}

/* filters: one row of groups under the header */
.filters{display:flex;flex-wrap:wrap;align-items:center;gap:12px 32px;margin:4px 0 6px;padding:14px 0 16px;border-bottom:1px solid var(--line)}
.f-group{display:flex;flex-wrap:wrap;align-items:center;gap:8px}
.f-label{margin-inline-end:4px;color:var(--muted);font:600 14px/1 var(--fun)}
.f-group button{height:36px;padding:0 14px;border:1.5px solid var(--line);border-radius:999px;background:transparent;color:var(--text);font:600 14.5px/1 var(--fun);cursor:pointer;transition:background .15s,border-color .15s}
.f-group button:hover{background:#ffffff12;border-color:#ffffff40}
.f-group button[aria-pressed=true]{background:var(--lime);border-color:var(--lime);color:var(--ink)}
.f-status{display:flex;align-items:center;gap:12px;margin:0 auto 0 0;color:var(--muted);font:600 14.5px/1 var(--fun)}
.f-clear{height:34px;padding:0 12px;border:0;border-radius:8px;background:#ffffff14;color:var(--text);font:600 14px/1 var(--fun);cursor:pointer}
.f-clear:hover{background:#ffffff24}
.game.off,.cat.off{display:none}
/* the tags on the cards are filter buttons */
.chips li{padding:0;border:0;background:none}
.chip{height:26px;padding:0 9px;border:1px solid transparent;border-radius:7px;background:#ffffff14;color:var(--muted);font:600 12.5px/1 var(--fun);white-space:nowrap;cursor:pointer;transition:background .15s,color .15s}
.chip:hover{background:#ffffff24;color:var(--text)}
.chip.on{background:var(--lime);color:var(--ink)}
@media(max-width:560px){.filters{gap:10px;padding:12px}.f-group{gap:6px}.f-group button{height:32px;padding:0 11px;font-size:13px}.f-label{flex-basis:100%;margin:0}.chip{height:24px;font-size:11.5px;padding:0 7px}}

/* ===== the bottom of the home page: three different things that look different ===== */
.panel{background:none;border:0;border-radius:0;padding:0}
/* questions: the title on the side, the questions in two columns, no frame */
.faq{display:grid;grid-template-columns:260px 1fr 1fr;gap:0 40px;align-items:start;margin-top:72px}
.faq h2{grid-row:1/span 9;margin:6px 0 0;font:700 34px/1.15 var(--fun);color:#fff}
.faq details,.faq details:first-of-type{margin:0;padding:16px 0;border-top:1px solid var(--line)}
.faq summary{list-style:none;display:flex;align-items:center;gap:12px;font:600 18px/1.35 var(--fun)}
.faq summary::-webkit-details-marker{display:none}
.faq summary::before{content:"+";flex:none;display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#ffffff14;color:var(--lime);font:700 19px/1 var(--fun);transition:background .15s}
.faq details[open] summary::before{content:"−";background:var(--lime);color:var(--ink)}
.faq summary:hover::before{background:#ffffff26}
.faq p{margin:10px 0 0;padding-inline-start:40px;color:#dccfec;font-size:16px;line-height:1.6}
/* supporters: a coloured strip of its own, with a big button */
section.support{margin-top:64px;padding:36px 40px;border:1px solid #ff6a9c55;border-radius:20px;background:linear-gradient(120deg,#ff6a9c30,#8b3fe030 60%,#26173b)}
section.support h2{font-size:32px;margin-bottom:10px}
section.support>p{font-size:17px;max-width:760px}
section.support .give-btn{height:54px;padding:0 30px;font-size:18px;border-radius:12px;box-shadow:0 8px 22px #ff6a9c40}
/* the studio: a quiet line above the footer */
.studio{margin-top:56px;padding:22px 0 0;border-top:1px solid var(--line)}
.studio>img{width:40px;height:40px}
@media(max-width:900px){.faq{grid-template-columns:1fr}.faq h2{grid-row:auto;margin-bottom:12px;font-size:28px}section.support{grid-template-columns:1fr;padding:26px 22px}section.support .give-btn{grid-column:1;grid-row:auto;justify-self:start;margin-top:8px}}

/* the like on the picture's bottom-left corner, see-through (the picture is 16:10 of the card's width) */
/* (100cqw is the card body, 32px narrower than the picture) */
.game .like{top:calc((100cqw + 32px) * 10 / 16 - 44px);left:10px;background:#13091f59;border-color:#ffffff38;backdrop-filter:blur(6px);box-shadow:none}
.game .like:hover{background:#13091f99}
.game .like[aria-pressed=true]{background:#ff6a9c40}
/* phones: back to the picture's bottom corner (left:10px above plus right:8px from the phone rule stretched it across the whole card, over the buttons) */
@media(max-width:560px){.game .like{top:auto;left:auto}}

/* the kinds link to their own pages */
.cat-head h2 a{color:inherit;text-decoration:none}
.cat-head h2 a:hover{text-decoration:underline;text-decoration-thickness:3px;text-underline-offset:5px;text-decoration-color:var(--lime)}
.faq p a{color:var(--lime);text-decoration:underline;text-underline-offset:3px}
