body {
    background:
        radial-gradient(circle at 14% 18%, rgba(255, 221, 104, 0.42), transparent 28%),
        linear-gradient(135deg, #fff6df 0%, #e7f7ff 48%, #ffe8ec 100%);
}

.header.board {
    border: 0;
    background: transparent;
}

.header {
    position: absolute;
    inset: 0 0 auto;
    z-index: 20;
    height: 0;
    color: #253044;
}

.text-header {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.game-menu {
    top: 18px;
}

.play-timer,
.track,
.footer.board {
    display: none;
}

.menu-button {
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.76);
    color: #253044;
    box-shadow: 0 10px 24px rgba(38, 50, 56, 0.1);
}

.game.board {
    border: 0;
    height: auto;
    max-height: none;
    min-height: 100dvh;
    justify-content: center;
    padding: clamp(20px, 4dvh, 48px) 0;
    box-sizing: border-box;
}

.landing {
    width: min(980px, calc(100% - 28px));
    color: #253044;
}

.landing-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(250px, 0.78fr);
    align-items: center;
    gap: clamp(18px, 4vw, 42px);
    min-height: min(540px, calc(100dvh - 64px));
    padding: clamp(24px, 4.5vw, 56px);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.34);
    box-shadow: 0 18px 44px rgba(38, 50, 56, 0.08);
    box-sizing: border-box;
}

.landing-copy {
    text-align: left;
}

.landing-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 15px;
    border-radius: 8px;
    background: #ffe36e;
    color: #253044;
    font-size: clamp(1rem, 1.7vw, 1.18rem);
    font-weight: 900;
    box-shadow: 0 8px 24px rgba(38, 50, 56, 0.08);
}

.landing h2 {
    max-width: 8ch;
    margin: 14px 0 12px;
    font-size: clamp(3rem, 5.2vw, 4.6rem);
    line-height: 0.98;
}

.landing p {
    max-width: 460px;
    margin: 0;
    color: #465865;
    font-size: clamp(1.02rem, 1.55vw, 1.2rem);
    line-height: 1.45;
    font-weight: 800;
}

.landing-start {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 210px;
    min-height: 58px;
    margin-top: 22px;
    padding: 0 32px;
    border-radius: 8px;
    background: #ff6b4a;
    color: #ffffff;
    font-size: clamp(1.2rem, 2vw, 1.45rem);
    font-weight: 900;
    text-decoration: none;
    box-shadow: 0 16px 28px rgba(255, 107, 74, 0.28);
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

.landing-start:hover,
.landing-start:active {
    transform: translateY(-2px);
    background: #ee5737;
    box-shadow: 0 18px 34px rgba(255, 107, 74, 0.34);
}

.landing-scene {
    position: relative;
    min-height: clamp(230px, 34dvh, 320px);
}

.landing-picture {
    position: absolute;
    right: 50%;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: clamp(96px, 12vw, 128px);
    height: clamp(96px, 12vw, 128px);
    border-radius: 8px;
    background: #ffffff;
    font-size: clamp(3.4rem, 5.4vw, 4.4rem);
    transform: translateX(50%) rotate(-2deg);
    box-shadow: 0 18px 34px rgba(38, 50, 56, 0.13);
}

.landing-word-card {
    position: absolute;
    left: 50%;
    bottom: 0;
    display: grid;
    gap: 10px;
    width: min(76%, 238px);
    padding: 16px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.88);
    color: #253044;
    text-align: center;
    transform: translateX(-50%);
    box-shadow: 0 18px 34px rgba(38, 50, 56, 0.12);
}

.landing-word {
    font-size: clamp(2.15rem, 4vw, 3rem);
    font-weight: 900;
    letter-spacing: 0.08em;
}

.landing-letter-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.landing-letter-row span,
.landing-small-word {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 8px;
    background: #ffe36e;
    color: #253044;
    font-size: 1.22rem;
    font-weight: 900;
    box-shadow: 0 10px 20px rgba(38, 50, 56, 0.1);
}

.landing-small-word {
    position: absolute;
    min-width: 84px;
    padding: 0 12px;
    background: #97e8d2;
}

.word-dom {
    left: 0;
    top: 22%;
    transform: rotate(-7deg);
}

.word-kit {
    right: 0;
    top: 34%;
    transform: rotate(6deg);
}

.landing-match-board,
.landing-memory-board {
    position: absolute;
    inset: 7% 0 0;
    display: grid;
    gap: 12px;
    width: min(100%, 300px);
    margin: 0 auto;
}

.landing-match-card,
.landing-memory-card {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 56px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    color: #253044;
    font-size: clamp(1.35rem, 2.6vw, 2rem);
    font-weight: 900;
    box-shadow: 0 14px 26px rgba(38, 50, 56, 0.12);
}

.landing-match-card.picture-card {
    font-size: clamp(2.4rem, 4vw, 3.4rem);
}

.landing-match-card.muted {
    opacity: 0.72;
}

.landing-match-row {
    display: grid;
    grid-template-columns: 1fr 18px 1fr;
    gap: 8px;
}

.landing-match-line {
    align-self: center;
    height: 4px;
    border-radius: 999px;
    background: #ff6b4a;
    box-shadow: 0 8px 18px rgba(255, 107, 74, 0.22);
}

.landing-match-spacer {
    min-width: 18px;
}

.landing-memory-board {
    grid-template-columns: repeat(3, 1fr);
    align-content: center;
}

.landing-memory-card {
    min-height: 78px;
}

.landing-memory-card.matched {
    background: #97e8d2;
}

.landing-memory-card.open {
    background: #ffe36e;
}

.landing-memory-card.closed {
    background: #253044;
    color: #ffffff;
}

@media (max-width: 760px) {
    .game.board {
        justify-content: center;
        padding: 10px 0;
    }

    .landing-card {
        grid-template-columns: 1fr;
        align-content: start;
        min-height: calc(100dvh - 20px);
        padding: 20px 16px 16px;
        text-align: center;
    }

    .landing-copy {
        text-align: center;
    }

    .landing h2,
    .landing p {
        margin-inline: auto;
    }

    .landing h2 {
        max-width: 11ch;
        font-size: clamp(2.25rem, 8.8vw, 3rem);
    }

    .landing-start {
        min-width: min(100%, 240px);
    }

    .landing-scene {
        min-height: clamp(178px, 28dvh, 230px);
    }

    .landing-picture {
        top: 0;
        width: 82px;
        height: 82px;
        font-size: 3rem;
    }

    .landing-word-card {
        bottom: 0;
        width: min(74%, 220px);
        padding: 12px;
    }

    .landing-small-word {
        min-width: 70px;
        min-height: 38px;
        font-size: 1.05rem;
    }

    .landing-match-board,
    .landing-memory-board {
        inset: 2% 0 0;
        width: min(100%, 280px);
        gap: 8px;
    }

    .landing-match-card {
        min-height: 48px;
    }

    .landing-memory-card {
        min-height: 58px;
    }
}

@media (max-width: 480px) {
    .game-menu {
        top: 12px;
        right: 10px;
    }

    .landing {
        width: min(100% - 18px, 480px);
    }

    .landing-card {
        min-height: calc(100dvh - 20px);
        padding: 16px 12px 14px;
    }

    .landing p {
        font-size: 0.98rem;
    }

    .landing-scene {
        min-height: 166px;
    }

    .landing-start {
        min-height: 56px;
        margin-top: 18px;
    }

    .landing-match-card {
        min-height: 42px;
        font-size: 1.08rem;
    }

    .landing-match-card.picture-card {
        font-size: 2rem;
    }

    .landing-memory-card {
        min-height: 48px;
        font-size: 1.1rem;
    }
}
