.memory-game { max-width: 760px; margin: auto; padding: 3rem 1.25rem; }
.memory-game h1 { margin: .2rem 0 .6rem; font-size: clamp(2.5rem, 6vw, 4rem); letter-spacing: -.05em; }
.memory-game .game-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; margin-top: 2rem; }
.memory-game button { font: inherit; cursor: pointer; }
.memory-game #restart { padding: .65rem 1rem; border: 1px solid #a5b4fc; border-radius: .5rem; background: #4f46e5; color: white; font-weight: 700; }
.memory-game #status { min-height: 1.5em; color: #cbd5e1; }
.memory-game .board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .7rem; }
.memory-game .card { aspect-ratio: 1; min-width: 0; border: 1px solid #6366f1; border-radius: .8rem; background: linear-gradient(135deg, #303a77, #164e63); color: white; font-weight: 800; font-size: clamp(.85rem, 3vw, 1.25rem); }
.memory-game .card:hover:not(:disabled) { border-color: #67e8f9; }
.memory-game .card:focus-visible, .memory-game #restart:focus-visible { outline: 3px solid #67e8f9; outline-offset: 3px; }
.memory-game .card.is-revealed { background: #e0e7ff; border-color: #e0e7ff; color: #172554; }
.memory-game .card.is-matched { background: #14532d; border-color: #4ade80; color: #dcfce7; cursor: default; }
.memory-game .note { margin-top: 2rem; color: #a5b4c9; font-size: .9rem; }
