/* 几何综合计算器样式 */
.geo-calc {
  color: #0f172a;
  font-size: 14px;
}
.geo-head h2 {
  margin: 0 0 6px;
  font-size: 20px;
  color: #0f172a;
}
.geo-head p {
  margin: 0 0 18px;
  color: #64748b;
  line-height: 1.7;
}
.geo-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  padding: 6px;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}
.geo-tab {
  flex: 1 1 120px;
  min-width: 92px;
  padding: 9px 12px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #475569;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s, color .15s, box-shadow .15s;
}
.geo-tab:hover { background: #e2e8f0; color: #0f172a; }
.geo-tab.is-active {
  background: #2563eb;
  color: #fff;
  box-shadow: 0 2px 8px rgba(37, 99, 235, .22);
}
.geo-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
}
.geo-panel {
  min-width: 0;
  padding: 18px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}
.geo-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.geo-row > label {
  flex: 0 0 72px;
  color: #334155;
  font-weight: 600;
}
.geo-row > .tool-input { flex: 1 1 auto; min-width: 0; }
.geo-row > small { color: #94a3b8; font-size: 12px; }
.geo-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px 0;
  border-top: 1px dashed #e2e8f0;
  border-bottom: 1px dashed #e2e8f0;
  margin-bottom: 14px;
}
.geo-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.geo-field > span {
  color: #334155;
  font-weight: 600;
}
.geo-field > small {
  color: #94a3b8;
  font-size: 12px;
}
.geo-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.geo-formula {
  margin-top: 14px;
  padding: 10px 12px;
  background: #eff6ff;
  border-left: 3px solid #2563eb;
  border-radius: 5px;
  color: #1e3a8a;
  line-height: 1.6;
  word-break: break-word;
}
.geo-model-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 8px;
  color: #334155;
}
.geo-model-name { color: #64748b; font-size: 12px; }
.geo-model-canvas {
  width: 100%;
  min-height: 240px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
}
.geo-svg { display: block; width: 100%; height: auto; max-height: 300px; }
.geo-svg .geo-shape { fill: rgba(37, 99, 235, .10); stroke: #2563eb; stroke-width: 2; }
.geo-svg .geo-top { fill: rgba(59, 130, 246, .16); }
.geo-svg .geo-side { fill: rgba(37, 99, 235, .18); }
.geo-svg .geo-faint { fill: rgba(148, 163, 184, .08); stroke: #94a3b8; }
.geo-svg .geo-hole { fill: #f8fafc; stroke: #2563eb; stroke-width: 2; }
.geo-svg .geo-line { fill: none; stroke: #64748b; stroke-width: 1.6; }
.geo-svg .geo-hidden { fill: none; stroke: #94a3b8; stroke-width: 1.4; stroke-dasharray: 5 4; }
.geo-svg .geo-dim { stroke: #64748b; stroke-width: 1.4; marker-end: url(#geoArrow); }
.geo-svg .geo-dot { fill: #2563eb; }
.geo-svg .geo-label { fill: #0f172a; font-size: 13px; font-family: inherit; }
.geo-svg .geo-sub { fill: #64748b; font-size: 12px; font-family: inherit; }
.geo-model-note {
  margin: 10px 0 0;
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.6;
}
.geo-output {
  margin-top: 16px;
  padding: 18px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}
.geo-output-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  color: #334155;
}
.geo-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.geo-result {
  min-width: 0;
  padding: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}
.geo-result.is-primary {
  background: #eff6ff;
  border-color: #93c5fd;
}
.geo-result > span {
  display: block;
  margin-bottom: 8px;
  color: #64748b;
  font-size: 12px;
}
.geo-result > b {
  display: block;
  color: #0f172a;
  font-size: 20px;
  line-height: 1.3;
  word-break: break-all;
}
.geo-result.is-primary > b { color: #1d4ed8; }
.geo-result > b em {
  margin-left: 4px;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
}
.geo-result > small {
  display: block;
  margin-top: 6px;
  color: #94a3b8;
  font-size: 12px;
}
.geo-error {
  grid-column: 1 / -1;
  padding: 14px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  color: #b91c1c;
}
.geo-unit-note {
  margin: 12px 0 0;
  color: #94a3b8;
  font-size: 12px;
}
.geo-help {
  margin-top: 16px;
  padding: 16px 18px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  color: #475569;
  line-height: 1.8;
}
.geo-help b { color: #334155; }
.geo-help ol { margin: 8px 0 0; padding-left: 22px; }

@media (max-width: 900px) {
  .geo-main { grid-template-columns: 1fr; }
  .geo-model-canvas { min-height: 210px; }
}
@media (max-width: 600px) {
  .geo-calc { font-size: 13px; }
  .geo-head h2 { font-size: 17px; }
  .geo-tab { flex: 1 1 calc(50% - 8px); min-width: 0; padding: 8px 6px; }
  .geo-panel, .geo-output, .geo-help { padding: 14px; }
  .geo-row { align-items: flex-start; flex-direction: column; gap: 6px; }
  .geo-row > label { flex: none; }
  .geo-row > small { margin-left: 0; }
  .geo-fields { grid-template-columns: 1fr; }
  .geo-results { grid-template-columns: 1fr; }
  .geo-result > b { font-size: 18px; }
}
