* {
    box-sizing: border-box;
}

body {
    font-family: "Orbitron", Arial, sans-serif;
    background-color: black;
    color: white;
    font-size: 0.8em;
    margin: 0;
}

button {
    font-family: "Orbitron", Arial, sans-serif;
}

#page {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(360px, 56vh) auto auto;
    gap: 16px;
    padding: 16px;
}

#buttondiv {
    position: relative;
    min-width: 0;
    min-height: 0;
    border: dashed;
    border-color: gray;
    font-size: 1.2em;
    overflow: auto;
}

#buttondiv button {
    font-family: "Orbitron", Arial, sans-serif;
    width: clamp(100px, 30vw, 400px);
    height: clamp(100px, 30vw, 400px);
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: clamp(1.7rem, 5vw, 4rem);
}

#count {
    position: absolute;
    left: 16px;
    top: 8px;
}

#shop {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    min-width: 0;
    padding: 10px;
    border: dashed;
    border-color: gray;
    overflow: auto;
    font-size: 0.96em;
}

#clickShop,
#CPSShop,
#multiplierShop {
    min-width: 0;
    padding: 0 12px 12px;
    border: 1px solid #444;
    background: #101010;
}

#shop h3 {
    font-size: 1.5em;
}

#shop p {
    font-size: 1.1em;
}

#info {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    min-width: 0;
}

#productionInfo,
#lifetimeInfo {
    min-width: 0;
    border: dashed gray;
    padding: 0 20px;
    padding-bottom: 10px;
}

#productionInfo button,
#lifetimeInfo button {
    font-family: "Orbitron", Arial, sans-serif;
    font-size: 0.9rem;
    padding: 6px 10px;
    border: 2px solid #555;
    background: #1a1a1a;
    color: #e0e0e0;
    white-space: nowrap;
}

#hardReset {
    border: #ff0000;
    background: #ff0000;
    color: #ff0000;
}

@media (max-width: 900px) {
    #shop {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    #page {
        grid-template-rows: minmax(320px, 55vh) auto auto;
        padding: 10px;
        gap: 10px;
    }

    #shop,
    #info {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ---- Shop buttons ---- */
#shop button {
    font-family: "Orbitron", Arial, sans-serif;
    font-size: 0.9rem;
    padding: 6px 10px;
    border: 2px solid #555;
    background: #1a1a1a;
    color: #e0e0e0;
    white-space: nowrap;
    cursor: not-allowed;
}

#shop button .cost {
    font-weight: 700;
    font-size: 1.05rem;
}

#shop button.affordable {
    border-color: #3ddc84;
    color: #3ddc84;
    cursor: pointer;
}