/* Calculator panel. Loaded by both test sites; nothing here touches the test itself. */
.ca-wrap { display: flex; flex-direction: column; height: 100%; font-size: 0.95rem; }
.ca-tabs { display: flex; gap: 2px; padding: 6px 6px 0; background: #f2f5f9; border-bottom: 1px solid var(--line, #d9e0ea); }
.ca-tab { flex: 1; padding: 8px 10px; border: 1px solid transparent; border-bottom: none; background: none;
  border-radius: 6px 6px 0 0; font: inherit; font-weight: 600; color: #4a5568; cursor: pointer; }
.ca-tab.on { background: #fff; border-color: var(--line, #d9e0ea); color: var(--ink, #12203a); }
.ca-pane { flex: 1; display: flex; flex-direction: column; min-height: 0; padding: 10px; gap: 8px; }
.ca-pane[hidden] { display: none; }

.ca-history { flex: 1; min-height: 44px; overflow-y: auto; font-variant-numeric: tabular-nums; }
.ca-hrow { display: flex; justify-content: space-between; align-items: baseline; gap: 10px;
  padding: 3px 0; border-bottom: 1px dotted #e6ebf2; }
.ca-hsrc { background: none; border: none; padding: 0; font: inherit; color: #4a5568; text-align: left; cursor: pointer; }
.ca-hsrc:hover { text-decoration: underline; }
.ca-hout { font-weight: 700; }
.ca-input { width: 100%; padding: 10px; font-size: 1.15rem; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  border: 1px solid var(--line, #d9e0ea); border-radius: 8px; }
.ca-input:focus { outline: 2px solid #2a78d6; outline-offset: 1px; }
.ca-result { min-height: 1.4em; text-align: right; font-size: 1.1rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.ca-result.bad { color: #b3261e; font-size: 0.9rem; font-weight: 600; }

.ca-keys { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.ca-key { padding: 12px 0; font: inherit; font-size: 1.02rem; background: #fff; color: var(--ink, #12203a);
  border: 1px solid var(--line, #d9e0ea); border-radius: 8px; cursor: pointer; min-height: 44px; }
.ca-key:hover { background: #eef3fa; }
.ca-key:active { background: #dbe6f5; }
.ca-eq { background: #2a78d6; border-color: #2a78d6; color: #fff; font-weight: 700; }
.ca-key.ca-mode { background: #f2f5f9; font-size: 0.85rem; font-weight: 700; }
.ca-key.ca-mode.on { background: #2a78d6; border-color: #2a78d6; color: #fff; }

.ca-eqs { display: flex; flex-direction: column; gap: 6px; }
.ca-graph .ca-eq { display: flex; align-items: center; gap: 6px; background: none; border: none; color: inherit; font-weight: 400; }
.ca-dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.ca-y { color: #4a5568; }
.ca-line { flex: 1; min-width: 0; padding: 7px 8px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  border: 1px solid var(--line, #d9e0ea); border-radius: 6px; }
.ca-canvas { flex: 1; min-height: 180px; width: 100%; border: 1px solid var(--line, #d9e0ea); border-radius: 8px; background: #fff; }
.ca-zoom { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 0.82rem; color: #4a5568; }
.ca-zoom button { padding: 6px 10px; font: inherit; background: #fff; border: 1px solid var(--line, #d9e0ea);
  border-radius: 6px; cursor: pointer; }
.ca-range { margin-left: auto; }

@media (max-width: 560px) {
  .ca-key { padding: 10px 0; font-size: 0.95rem; }
  .ca-input { font-size: 1.05rem; }
}
