:root {
    --bark: #5b4636;
    --bark-dark: #3d2f24;
    --bark-light: #7a5e47;
    --leaf: #3f7d4a;
    --leaf-deep: #2a5733;
    --syrup: #a65a1e;
    --waffle: #e8b04b;
    --waffle-deep: #c98a2f;
    --sky-top: #bfe3d6;
    --sky-bot: #f6e7c4;
    --ink: #2c2118;
    --cream: #fff7e8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent
}

html,
body {
    height: 100%;
    overflow: hidden;
    font-family: 'Trebuchet MS', 'Segoe UI', sans-serif;
    background: var(--bark-dark)
}

#wrap {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center
}

canvas {
    display: block;
    touch-action: none;
    background: linear-gradient(180deg, var(--sky-top), var(--sky-bot))
}

.overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    text-align: center;
    background: rgba(44, 33, 24, .78);
    color: var(--cream);
    padding: 28px;
    z-index: 10;
}

.hidden {
    display: none
}

.title {
    font-size: clamp(38px, 12vw, 72px);
    line-height: .92;
    font-weight: 800;
    letter-spacing: -.02em;
    color: var(--waffle);
    text-shadow: 0 4px 0 var(--bark-dark), 0 6px 14px rgba(0, 0, 0, .4);
}

.sub {
    font-size: clamp(14px, 4.2vw, 18px);
    max-width: 22ch;
    opacity: .92;
    line-height: 1.4
}

.pill {
    display: inline-block;
    background: var(--leaf);
    color: var(--cream);
    font-weight: 700;
    font-size: clamp(17px, 5.5vw, 22px);
    padding: 16px 38px;
    border-radius: 999px;
    border: none;
    cursor: pointer;
    box-shadow: 0 5px 0 var(--leaf-deep), 0 8px 18px rgba(0, 0, 0, .35);
    transition: transform .08s, box-shadow .08s;
}

.pill:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 var(--leaf-deep)
}

.score-big {
    font-size: clamp(46px, 16vw, 90px);
    font-weight: 800;
    color: var(--waffle);
    line-height: 1
}

.score-lbl {
    font-size: 13px;
    letter-spacing: .22em;
    text-transform: uppercase;
    opacity: .7
}

.hint {
    font-size: 13px;
    opacity: .65;
    display: flex;
    align-items: center;
    gap: 8px
}

#hud {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 14px 18px;
    pointer-events: none;
    z-index: 5;
    font-weight: 800;
    color: var(--ink)
}

.hud-box {
    background: var(--cream);
    border-radius: 14px;
    padding: 8px 14px;
    box-shadow: 0 3px 0 rgba(0, 0, 0, .18);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: clamp(16px, 5vw, 22px)
}

.hud-lbl {
    font-size: 10px;
    letter-spacing: .15em;
    text-transform: uppercase;
    opacity: .55;
    display: block;
    font-weight: 700
}
