/* Health Measurements. Shared site styles are in /css/style.css. */

.input-unit .input { min-width: 0; }
.input[type=number] { font-variant-numeric: tabular-nums; }
.input[aria-invalid=true] { border-color: #b3261e; box-shadow: inset 1px 1px 0 #b3261e; }

.segmented button:focus-visible { outline: 2px solid var(--accent); outline-offset: -4px; }

.tile-value { font-size: 2rem; }

/* Visceral fat scale: 0 to 300 cm², with the 130 cm² threshold marked */
.gauge { display: grid; gap: 4px; }
.gauge-track {
    position: relative; height: 14px;
    border: 1px solid var(--frame);
    background: linear-gradient(to right, #cfe8cf 0 43.33%, #f6d2b8 43.33% 100%);
    box-shadow: inset 1px 1px 0 rgba(0, 0, 0, 0.15);
}
.gauge-track::after {
    content: ""; position: absolute; top: -4px; bottom: -4px; left: 43.33%; width: 2px; background: #333;
}
.gauge-mark {
    position: absolute; top: -6px; width: 0; height: 0; margin-left: -7px;
    border: 7px solid transparent; border-top: 9px solid var(--hilite); border-bottom: 0;
}
.gauge-scale { position: relative; display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--muted); }
.gauge-cut { position: absolute; left: 43.33%; transform: translateX(-50%); font-weight: 700; color: var(--text); }

.formula {
    padding: 10px 14px; background: var(--surface-2); border: 1px solid var(--nx-light);
    font-family: var(--code); font-size: 0.85rem; line-height: 1.7; color: var(--text) !important;
    overflow-x: auto;
}

@media (max-width: 480px) {
    .tile-value { font-size: 1.6rem; }
}
