:root { --accent:#f6c85f; --accent2:#54d6ae; }
.memory-grid { display:grid; gap:clamp(6px,1.2vw,12px); margin:auto; width:min(100%,calc(100dvh - 265px),520px); }
.memory-card { position:relative; width:100%; aspect-ratio:1; min-height:0; overflow:hidden; border:3px solid #d6af61; border-radius:clamp(10px,1.4vw,17px); background: linear-gradient(135deg,transparent 43%,rgba(255,255,255,.15) 44% 56%,transparent 57%),linear-gradient(45deg,transparent 43%,rgba(255,255,255,.12) 44% 56%,transparent 57%),linear-gradient(145deg,#176382,#073c61) !important; background-size:22px 22px,22px 22px,auto !important; box-shadow:inset 0 0 0 3px rgba(255,255,255,.12),0 7px 14px rgba(0,0,0,.34) !important; transform-style:preserve-3d; transition:transform .2s ease,box-shadow .2s ease,opacity .2s ease; }
.memory-card::after { position:absolute; inset:11%; border:1px solid rgba(246,200,95,.46); border-radius:50%; background:radial-gradient(circle,#f6c85f 0 6%,transparent 7%),conic-gradient(from 0deg,transparent 0 10%,rgba(246,200,95,.5) 11% 13%,transparent 14% 35%,rgba(246,200,95,.5) 36% 38%,transparent 39% 60%,rgba(246,200,95,.5) 61% 63%,transparent 64% 85%,rgba(246,200,95,.5) 86% 88%,transparent 89%); content:""; }
.memory-card.open,.memory-card.matched { border-color:#efd8a5; background-image:url("/images/games/assets/memory-match/woodland-v1.png") !important; background-position:var(--art-x,0%) var(--art-y,0%) !important; background-size:600% 300% !important; background-repeat:no-repeat !important; box-shadow:0 0 0 2px rgba(255,246,201,.45),0 8px 18px rgba(0,0,0,.3) !important; transform:rotateY(0) scale(1.02); }
.memory-card.open::after,.memory-card.matched::after { display:none; }
.memory-card.matched { opacity:.38; filter:saturate(.55); }
.memory-grid[data-cols="6"] { gap:4px; }
.memory-grid[data-cols="6"] .memory-card { min-height:42px; padding:0; border-width:2px; border-radius:9px; }
@media(max-width:799px){.table-wrap{min-height:calc(100dvh - 290px)}.table{display:grid;min-height:0;align-items:center}.memory-grid{width:min(100%,calc(100dvh - 320px),480px)}}
