/* Calculator Styles - Lego Brick Counter Theme */

.calculator-container {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/* Display */
.calculator-display {
    background: var(--lego-white);
    border: 3px solid var(--lego-black);
    border-radius: var(--brick-radius-small);
    padding: 4px 10px;
    text-align: right;
    font-size: 18px;
    font-family: 'Courier New', monospace;
    font-weight: 700;
    height: 36px;
    line-height: 28px;
    overflow: hidden;
    white-space: nowrap;
    margin-bottom: 6px;
    box-shadow: inset 2px 2px 4px rgba(0, 0, 0, 0.1);
}

/* Top row (Back, CE, C) - aligned right with spacer */
.calculator-top-row {
    display: flex;
    gap: 4px;
    margin-bottom: 4px;
}

.calculator-top-row .calc-spacer {
    width: 48px;
    flex-shrink: 0;
}

.calculator-top-row .calc-btn {
    flex: 1;
}

.calc-spacer {
    min-width: 0;
}

/* Button Grid - 6 columns with gap after memory */
.calculator-buttons {
    display: grid;
    grid-template-columns: 40px 10px 1fr 1fr 1fr 1fr 1fr;
    gap: 4px;
}

/* Gap divider between memory and numbers */
.calc-gap {
    min-width: 0;
}

/* Button Styles - Lego Stud Style */
.calc-btn {
    height: 32px;
    border: 2px solid var(--lego-black);
    background: var(--lego-gray-light);
    font-size: 13px;
    font-family: var(--font-family);
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
    padding: 0 4px;
    border-radius: var(--brick-radius-small);
    box-shadow: 0 3px 0 var(--lego-gray);
    transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.calc-btn:hover {
    background: var(--lego-white);
    transform: translateY(-1px);
    box-shadow: 0 4px 0 var(--lego-gray);
}

.calc-btn:active {
    transform: translateY(3px);
    box-shadow: 0 0 0 var(--lego-gray);
}

/* Blue number buttons */
.calc-btn-blue {
    color: var(--lego-blue);
    background: var(--lego-white);
}

.calc-btn-blue:hover {
    background: #E8F4FF;
}

/* Red operator/function buttons */
.calc-btn-red {
    color: var(--lego-red);
    background: var(--lego-yellow-light);
    box-shadow: 0 3px 0 var(--lego-yellow-dark);
}

.calc-btn-red:hover {
    background: var(--lego-yellow);
    box-shadow: 0 4px 0 var(--lego-yellow-dark);
}

.calc-btn-red:active {
    box-shadow: 0 0 0 var(--lego-yellow-dark);
}

/* Memory buttons */
.calc-btn-memory {
    color: var(--lego-red);
    background: var(--lego-surface);
}

.calc-btn-memory:hover {
    background: var(--lego-white);
}
