:root{font-family:system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;color:#172b45;background:#f3f6fc;line-height:1.5;font-size:16px}*{box-sizing:border-box}body{margin:0}button,input,select{font:inherit}button{cursor:pointer}button:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #9cc5fa;outline-offset:2px}a{color:#145ba0}.page{max-width:1340px;margin:auto;padding:18px 24px 40px}.breadcrumb{display:flex;align-items:center;gap:9px;color:#65758a;font-size:.87rem;margin:0 0 15px}.intro{background:linear-gradient(120deg,#123e75,#17619a);color:white;border-radius:20px;padding:26px 30px;display:flex;justify-content:space-between;gap:18px;align-items:start}.intro h1{font-size:clamp(1.75rem,2.75vw,2.3rem);line-height:1.18;margin:4px 0 10px}.intro p:last-child{max-width:760px;margin:0;color:#e0eaf7}.eyebrow{color:#bad5ff;letter-spacing:.1em;font-weight:800;font-size:.72rem;margin:0}.version{white-space:nowrap;border:1px solid #adc8e5;padding:5px 11px;border-radius:99px;font-size:.8rem;color:#eaf2ff}.notice{background:#fff8e9;border:1px solid #e8c989;border-radius:10px;padding:11px 15px;margin:15px 0;color:#79531a;font-size:.85rem}.layout{display:grid;grid-template-columns:minmax(0,1.17fr) minmax(0,1fr);gap:18px;align-items:start}.work-col,.result-col{min-width:0;display:grid;gap:18px}.panel{background:white;border:1px solid #dae3ef;border-radius:16px;padding:21px 23px;box-shadow:0 5px 22px rgba(30,60,95,.035);min-width:0}.panel-heading{display:flex;justify-content:space-between;align-items:baseline;gap:10px;flex-wrap:wrap;margin:0 0 16px}.panel h2{font-size:1.22rem;margin:0;color:#17375a;line-height:1.3}.small-label{font-size:.76rem;color:#6c7e92}.point-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px}.point-input{min-width:0;display:grid;grid-template-columns:20px minmax(0,1fr);gap:7px;align-items:center;border:1px solid #d6e1ec;border-radius:10px;padding:10px;margin:0}.point-input legend{font-size:.88rem;font-weight:800;padding:0 4px;display:flex;align-items:center;gap:6px}.point-input label{color:#485e79;font-size:.85rem;font-weight:650}.point-input input{width:100%;min-width:0;border:1px solid #adbed2;border-radius:7px;padding:7px 8px;font-size:1rem;background:#fff;color:#172b45}.dot{display:inline-block;width:10px;height:10px;border-radius:50%}.a-dot{background:#1767c2}.b-dot{background:#db6123}.c-dot{background:#178369}.form-actions{display:flex;gap:9px;flex-wrap:wrap;margin-top:15px}.form-actions button,.tool-row button{border-radius:8px;padding:9px 12px;border:1px solid transparent;font-weight:700;font-size:.85rem}.primary{background:#205db0;color:white}.primary:hover{background:#17478e}.secondary{background:#eaf1fb;color:#204d7e}.secondary:hover{background:#d9e8f9}.examples{display:flex;gap:8px;align-items:center;flex-wrap:wrap;border-top:1px solid #e6edf5;margin-top:17px;padding-top:13px;font-size:.82rem}.examples>span{font-weight:700;color:#4d6179}.examples button{border:0;background:transparent;color:#145b9b;padding:4px 3px;text-decoration:underline;text-underline-offset:3px;font-size:inherit}.examples button:hover{color:#083d71}.message{min-height:0;color:#a23b28;font-weight:650;margin:8px 0 0;font-size:.84rem}.message:empty{display:none}.tool-row{display:flex;gap:9px;align-items:center;flex-wrap:wrap}.tool-row>label{font-weight:700;font-size:.85rem}.tool-row select{flex:1;min-width:200px;max-width:100%;padding:8px 7px;border:1px solid #b6c4d8;border-radius:8px;background:#fff;color:#172b45;font-size:.88rem}.tool-row button{color:#184f87;background:#edf4fc;border:1px solid #c0d1e5;min-width:35px;font-size:1rem;padding:6px 10px}.tool-row button.fit{font-size:.82rem}.checks{display:flex;flex-wrap:wrap;gap:10px 16px;margin:12px 0;color:#425a74;font-size:.82rem}.checks label{display:flex;align-items:center;gap:5px}.checks input{accent-color:#2465a8;width:15px;height:15px}.plot-frame{width:100%;border:1px solid #dbe5f0;border-radius:12px;overflow:hidden;background:#fff;touch-action:pan-y}.plot-frame svg{width:100%;height:auto;display:block;touch-action:none;user-select:none}.plot-frame svg .axis{stroke:#8492a5;stroke-width:1.6;vector-effect:non-scaling-stroke}.plot-frame svg .grid{stroke:#e5ebf3;stroke-width:1;vector-effect:non-scaling-stroke}.plot-frame svg .tick{fill:#6d7d91;font:12px system-ui,sans-serif}.plot-frame svg .pt{stroke:white;stroke-width:3;cursor:grab}.plot-frame svg .pt:active{cursor:grabbing}.plot-frame svg .point-hit{fill:transparent;cursor:grab}.plot-frame svg .point-label{font:700 18px system-ui,sans-serif;paint-order:stroke;stroke:#fff;stroke-width:4;stroke-linejoin:round}.plot-frame svg .help-line{stroke:#8b91ac;stroke-dasharray:7 5;stroke-width:1.7;fill:none;vector-effect:non-scaling-stroke}.plot-frame svg .geom-line{stroke:#2365b8;stroke-width:2.4;fill:none;vector-effect:non-scaling-stroke}.plot-frame svg .geom-circle{stroke:#625db2;stroke-width:2;fill:none;vector-effect:non-scaling-stroke}.plot-frame svg .geom-incircle{stroke:#16806c;stroke-width:2;fill:none;vector-effect:non-scaling-stroke}.plot-frame svg .geom-polygon{fill:rgba(40,105,170,.10);stroke:#366ca5;stroke-width:2.5;stroke-linejoin:round;vector-effect:non-scaling-stroke}.plot-frame svg .center-pt{stroke:white;stroke-width:2}.plot-frame svg .center-label{font:700 13px system-ui,sans-serif;paint-order:stroke;stroke:#fff;stroke-width:3}.help,.fineprint{font-size:.82rem;color:#66788e;line-height:1.6}.help{margin:10px 0}.legend{display:flex;flex-wrap:wrap;gap:8px 12px;font-size:.76rem;color:#546a85}.legend span{display:inline-flex;align-items:center;gap:5px}.legend i{width:9px;height:9px;border-radius:50%;display:inline-block}.metrics{width:100%;border-collapse:collapse;font-size:.89rem}.metrics th,.metrics td{border-bottom:1px solid #e9eef5;padding:7px 5px;text-align:left;vertical-align:top}.metrics th{font-weight:600;color:#54657a;width:58%}.metrics td{color:#173e70;font-variant-numeric:tabular-nums;font-weight:700;word-break:break-word}.result-group{margin:13px 0 4px;color:#173d66;font-size:1rem}.result-group:first-child{margin-top:0}.pill{display:inline-block;font-size:.8rem;padding:5px 9px;background:#eaf6ef;border:1px solid #c6e6d3;border-radius:8px;color:#20563c}.warning{border:1px solid #edc6be;background:#fff4f0;padding:12px;border-radius:9px;color:#954332;font-size:.88rem;margin:8px 0}.step{border-bottom:1px solid #e8eef5;padding:11px 0}.step:first-child{padding-top:0}.step:last-child{border-bottom:0}.step h3{font-size:.94rem;color:#1a426d;margin:0 0 5px}.step p{font-size:.85rem;color:#526982;margin:4px 0}.mathblock{overflow-x:auto;margin:8px 0;padding:9px 6px;border-radius:8px;background:#f6f9ff;font-size:.86rem}.mathblock mjx-container{margin:0!important;max-width:100%;overflow-x:auto;overflow-y:hidden;text-align:left!important}.theory{margin-top:18px}.theory-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:20px}.theory h3{margin:8px 0 5px;font-size:1rem;color:#254a75}.theory p{margin:0 0 10px;color:#5b6e82;font-size:.89rem}.theory .fineprint{margin-top:12px}footer{display:flex;gap:16px;justify-content:space-between;flex-wrap:wrap;padding:25px 4px;color:#6d8199;font-size:.8rem}footer a{text-decoration:none;font-weight:650}@media(max-width:1080px){.layout{grid-template-columns:1fr}.result-col{grid-template-columns:1fr 1fr;align-items:start}}@media(max-width:710px){.page{padding:14px 12px 25px}.intro{padding:22px 18px;border-radius:14px}.version{display:none}.panel{padding:16px}.point-grid{grid-template-columns:1fr}.point-input{grid-template-columns:20px 1fr 20px 1fr;gap:7px 8px}.result-col{grid-template-columns:1fr}.theory-grid{grid-template-columns:1fr;gap:10px}.tool-row select{min-width:160px}.plot-frame svg{min-height:275px}}

/* Geometria v1.2: costruzioni dei centri notevoli */
.construction-info{border-left:5px solid #8954b6;background:#f5f8fe;border-radius:9px;padding:11px 13px;margin:13px 0;font-size:.85rem;color:#344e6a;display:grid;gap:5px}
.construction-info[hidden]{display:none}
.construction-info b{font-size:.95rem;color:#173d66}
.construction-info em{color:#a34b32;font-style:normal;font-weight:650}
.construction-line{fill:none;stroke-width:2.8;stroke-dasharray:8 4;vector-effect:non-scaling-stroke}
.construction-axis{stroke:#b47a19;fill:none;stroke-width:2.15;stroke-dasharray:11 5;vector-effect:non-scaling-stroke}
.construction-extension{stroke:#a3aabd;stroke-width:1.8;stroke-dasharray:4 5;vector-effect:non-scaling-stroke}
.construction-pt{stroke:white;stroke-width:2;vector-effect:non-scaling-stroke}
.construction-label{font:700 16px system-ui,sans-serif;paint-order:stroke;stroke:#fff;stroke-width:4px;stroke-linejoin:round}
.angle-mark{fill:none;stroke-width:1.8;vector-effect:non-scaling-stroke}
.construction-tip{background:#f2f7ff;border:1px solid #d8e6f7;color:#35536d;border-radius:9px;padding:10px 12px;font-size:.87rem;line-height:1.6}

/* Distinzione didattica: tratto costruito, prolungamento verso H/O, lato prolungato. */
.construction-center-extension{stroke:#8e9baa;stroke-width:2.4;stroke-dasharray:7 7;fill:none;vector-effect:non-scaling-stroke}
.construction-side-extension{stroke:#c5cbd3;stroke-width:1.7;stroke-dasharray:3 6;fill:none;vector-effect:non-scaling-stroke}
.outside-hint{display:block;color:#40576c;font-size:.87rem;font-weight:650;margin-top:3px}

/* v1.3: circonferenze e costruzioni illustrate dei raggi e delle tangenze. */
.circle-radius-in{stroke:#16806c;stroke-width:1.9;stroke-dasharray:5 4;opacity:.9;fill:none;vector-effect:non-scaling-stroke}
.circle-radius-out{stroke:#625db2;stroke-width:2.1;stroke-dasharray:6 4;opacity:.8;fill:none;vector-effect:non-scaling-stroke}

/* v1.3.1: nella circoscritta gli assi gialli sono la costruzione principale;
   i raggi grigio chiarissimo restano unicamente di supporto alla spiegazione. */
.plot-frame svg .construction-axis-key{stroke:#d19a00;stroke-width:3.15;stroke-dasharray:10 4;stroke-linecap:round;fill:none;vector-effect:non-scaling-stroke}
.plot-frame svg .circle-radius-out{stroke:#c9d2dd;stroke-width:1.45;stroke-dasharray:5 6;opacity:.50;fill:none;vector-effect:non-scaling-stroke}


/* v1.4 — studio di due rette: editor di equazioni e visualizzazione. */
.line-editor{border:1px solid #d8e4f2;border-radius:12px;background:#f8fbff;padding:14px 15px;margin:15px 0;display:grid;gap:10px}
.line-editor[hidden]{display:none}
.line-editor h3{margin:0;color:#173e67;font-size:1rem}
.line-editor p{margin:0;color:#4e6781;font-size:.82rem}
.line-editor code{background:#eaf1fc;border-radius:3px;padding:1px 4px}
.line-input-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
.line-input-grid label{font-size:.79rem;font-weight:700;color:#435f7a;min-width:0}
.line-input-grid input{display:block;width:100%;min-width:0;margin-top:5px;padding:9px 10px;border:1px solid #b6c9de;border-radius:8px;background:white;color:#163654;font-size:1rem}
.line-tag{display:inline-block;font-weight:800;margin-right:5px}.r-tag{color:#2166ae}.s-tag{color:#d36a30}
.line-point-editor{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:.82rem;color:#435c76}
.line-point-editor label{display:inline-flex;align-items:center;gap:5px;font-weight:700}
.line-point-editor input{width:82px;padding:6px 7px;border:1px solid #b6c9de;border-radius:7px;background:#fff}
.line-hint{color:#667b91;font-size:.78rem}
.line-examples{border-top:1px solid #e1eaf5;padding-top:10px;display:flex;flex-wrap:wrap;gap:5px 10px;align-items:center;font-size:.80rem}
.line-examples strong{color:#3d526a}
.line-examples button{background:none;border:0;color:#205b99;padding:2px 0;text-decoration:underline;text-underline-offset:3px;font-size:inherit}
.line-editor .message:not(:empty){background:#fff2ed;border:1px solid #e6b3a5;border-radius:7px;padding:8px}
.plot-frame svg .line-r{stroke:#2166ae;stroke-width:2.8;fill:none;vector-effect:non-scaling-stroke}
.plot-frame svg .line-s{stroke:#db703a;stroke-width:2.8;fill:none;vector-effect:non-scaling-stroke}
.plot-frame svg .line-s-coincident{stroke:#db703a;stroke-width:3;stroke-dasharray:12 9;opacity:.9;fill:none;vector-effect:non-scaling-stroke}
.plot-frame svg .line-foot{stroke:#c5cfdd;stroke-width:1.75;stroke-dasharray:5 5;fill:none;vector-effect:non-scaling-stroke}
.plot-frame svg .line-arc{stroke:#846c97;stroke-width:2;fill:none;vector-effect:non-scaling-stroke}
.plot-frame svg .line-name{font:800 20px system-ui,sans-serif;paint-order:stroke;stroke:#fff;stroke-width:5;stroke-linejoin:round}
@media(max-width:710px){.line-input-grid{grid-template-columns:1fr}.line-point-editor input{width:72px}}

/* v1.5 — navigazione distinta dei laboratori. */
[hidden], .panel[hidden], .tool-row select[hidden] {display:none!important;}
.geometry-subnav{display:flex;align-items:center;flex-wrap:wrap;gap:9px;margin:0 0 16px}
.geometry-subnav a{font-size:.87rem;font-weight:700;color:#2d587e;padding:9px 14px;text-decoration:none;background:#fff;border:1px solid #d5e2f0;border-radius:9px}
.geometry-subnav a:hover{background:#e9f2fb;border-color:#a7c8e9}
.geometry-subnav a[aria-current="page"]{background:#1c5c9a;border-color:#1c5c9a;color:white}
.geometry-subnav .geo-nav-home{background:transparent;border-color:transparent;padding-left:0;color:#34648b}
.geometry-subnav a:focus-visible{outline:3px solid #9cc5fa;outline-offset:2px}
.tool-row .mode-caption{flex:1;font-size:.9rem;font-weight:700;color:#224d74}
@media(max-width:600px){.geometry-subnav{gap:6px}.geometry-subnav a{font-size:.78rem;padding:8px 10px}.geometry-subnav .geo-nav-home{width:100%;padding:4px 0}}
