
.math-tool{background:#edf4ef;border:1px solid #b8cfc0;border-radius:16px;padding:clamp(16px,3vw,26px);margin:24px 0}.math-tool h3{margin-top:0}.math-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.math-tool label{display:block;font-weight:650;margin-bottom:6px}.math-tool input,.math-tool select{box-sizing:border-box;width:100%;min-height:46px;font:inherit;font-size:16px;padding:10px;border:1px solid #6e8b7a;border-radius:7px;background:#fff;color:#173b2d}.math-tool fieldset{min-width:0;border:1px solid #b8cfc0;border-radius:10px;margin:16px 0;padding:14px}.math-tool legend{font-weight:700}.math-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:20px}.math-actions button{font:inherit;min-height:46px;padding:10px 16px;border-radius:8px;border:1px solid #28584b;cursor:pointer;background:#28584b;color:#fff}.math-actions button.secondary{background:white;color:#28584b}.math-result{background:#fff;border-left:4px solid #28584b;padding:16px;margin-top:20px;overflow-wrap:anywhere}.math-result:empty{display:none}.math-warning{background:#fff6e8;border-left:4px solid #987145;padding:16px}.math-table{max-width:100%;overflow-x:auto;border:1px solid #d6dfd9;border-radius:10px;margin:22px 0;overscroll-behavior-x:contain}.math-table table{min-width:650px;margin:0}.math-table:focus-visible,.math-tool :focus-visible{outline:3px solid #a36b15;outline-offset:3px}.math-table caption{padding:12px;font-weight:700;text-align:left;color:#173b2d}.math-tool small{display:block;margin-top:5px}.math-tool .check-row{display:flex;align-items:flex-start;gap:10px;font-weight:400}.math-tool .check-row input{width:20px;min-height:20px;flex-shrink:0;margin:3px 0}.formula-block{background:#f3f0e7;border:1px solid #d8d0ba;padding:18px;white-space:pre-wrap;overflow-wrap:anywhere;font-size:17px}.page p,.page li{line-height:1.75}.contents a{display:inline-block;padding:4px 0}.exercise details summary{min-height:44px;display:flex;align-items:center;cursor:pointer}.math-tool [hidden]{display:none}@media(max-width:520px){.math-grid{grid-template-columns:1fr}.math-actions button{width:100%}.math-tool{padding:16px}.math-tool fieldset{padding:12px}.page h1{overflow-wrap:anywhere}}
.page a[href^="#source-"]{display:inline-block;padding:3px 0}

.card h2 a,.card h3 a{display:block;padding:4px 0}.breadcrumbs a{display:inline-block;padding:2px 0}

.math-quick{display:flex;flex-wrap:wrap;gap:8px;margin:16px 0}.math-quick a{display:inline-flex;align-items:center;min-height:44px;padding:0 10px;border:1px solid #a4baad;border-radius:7px;background:#edf4ef;color:#173b2d;font-size:16px;box-sizing:border-box}.contents a{display:block}.contents li{break-inside:avoid}
