MotrixSimWeb/src/styles.css

1154 lines
18 KiB
CSS

:root {
color: #e5edf7;
background: #0f172a;
font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
font-synthesis: none;
text-rendering: optimizeLegibility;
}
* {
box-sizing: border-box;
}
body {
margin: 0;
min-width: 320px;
min-height: 100vh;
overflow: hidden;
}
button,
input,
select {
font: inherit;
}
.shell {
display: grid;
grid-template-columns: 340px minmax(0, 1fr) 320px;
width: 100vw;
height: 100vh;
background: #0f172a;
}
.sidebar,
.inspector {
display: flex;
flex-direction: column;
gap: 14px;
min-width: 0;
padding: 22px;
background: #111827;
border-right: 1px solid rgba(148, 163, 184, 0.18);
overflow: auto;
}
.inspector {
background: #10151f;
border-right: 0;
border-left: 1px solid rgba(148, 163, 184, 0.18);
}
.eyebrow {
color: #38bdf8;
font-size: 12px;
font-weight: 800;
letter-spacing: 0;
text-transform: uppercase;
}
.app-header {
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 12px;
}
.app-header > div {
min-width: 0;
}
.language-control {
min-width: 108px;
margin: 0;
}
.language-control span {
display: block;
margin-bottom: 6px;
color: #a9b8ca;
font-size: 12px;
}
.language-control select {
width: 100%;
height: 32px;
padding: 0 8px;
font-size: 12px;
}
h1 {
margin: 5px 0 0;
font-size: 25px;
line-height: 1.12;
letter-spacing: 0;
}
h2 {
margin: 0 0 12px;
font-size: 15px;
letter-spacing: 0;
}
.panel,
.note {
border: 1px solid rgba(148, 163, 184, 0.18);
border-radius: 8px;
background: rgba(15, 23, 42, 0.66);
padding: 14px;
}
.compact {
padding: 13px 14px;
}
.product-summary {
background: rgba(8, 47, 73, 0.46);
}
.template-grid {
display: grid;
grid-template-columns: 1fr;
gap: 8px;
}
.template-grid button {
width: 100%;
background: #bae6fd;
}
.asset-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
}
.upload-zone {
transition: border-color 0.16s ease, background 0.16s ease;
}
.upload-zone.drag-over {
border-color: rgba(34, 211, 238, 0.9);
background: rgba(8, 47, 73, 0.58);
}
.asset-card {
display: grid;
grid-template-columns: 18px minmax(0, 1fr) auto;
align-items: center;
gap: 8px;
min-height: 48px;
padding: 6px 10px;
color: #dbeafe;
background: #1f2937;
border: 1px solid rgba(148, 163, 184, 0.24);
text-align: left;
}
.asset-card:hover {
color: #06121f;
}
.asset-meta {
display: grid;
gap: 3px;
min-width: 0;
}
.asset-meta strong {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 12px;
}
.asset-remove {
width: 24px;
height: 24px;
padding: 0;
color: #f8fafc;
background: #334155;
border: 1px solid rgba(148, 163, 184, 0.3);
}
.asset-swatch {
width: 16px;
height: 16px;
background: var(--asset-color);
border: 1px solid rgba(255, 255, 255, 0.55);
border-radius: 4px;
}
label {
display: block;
margin-bottom: 8px;
color: #a9b8ca;
font-size: 13px;
}
.inline {
display: flex;
gap: 8px;
}
input,
select {
flex: 1;
min-width: 0;
height: 38px;
padding: 0 10px;
color: #f8fafc;
background: #0b1220;
border: 1px solid rgba(148, 163, 184, 0.32);
border-radius: 6px;
}
select {
appearance: none;
}
input[type="range"] {
padding: 0;
accent-color: #67e8f9;
}
input[type="number"] {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}
button {
height: 38px;
border: 0;
border-radius: 6px;
padding: 0 14px;
color: #06121f;
background: #67e8f9;
font-weight: 800;
cursor: pointer;
}
button:hover {
background: #22d3ee;
}
button:disabled {
color: #94a3b8;
background: #1f2937;
cursor: not-allowed;
}
.button-row {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
margin-top: 10px;
}
.button-row.single {
grid-template-columns: 1fr;
}
.builder-panel label + select,
.builder-panel label + .inline {
margin-bottom: 10px;
}
.prop-list {
display: grid;
gap: 6px;
min-height: 32px;
margin-top: 10px;
}
.layout-tools {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
margin-top: 10px;
}
.layout-tools button {
height: 32px;
padding: 0 8px;
background: #e0f2fe;
font-size: 12px;
}
.prop-row {
display: grid;
gap: 8px;
min-height: 76px;
padding: 8px;
background: rgba(30, 41, 59, 0.72);
border: 1px solid rgba(148, 163, 184, 0.16);
border-radius: 6px;
font-size: 12px;
}
.prop-row.selected {
border-color: rgba(250, 204, 21, 0.72);
background: rgba(63, 52, 20, 0.42);
}
.prop-row-title {
display: grid;
grid-template-columns: minmax(0, 1fr) auto auto;
align-items: center;
gap: 8px;
}
.prop-row-title > span {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.prop-row-actions {
display: inline-grid;
grid-template-columns: auto auto;
gap: 6px;
}
.physics-badge {
display: inline-flex;
align-items: center;
width: fit-content;
max-width: 100%;
min-height: 18px;
padding: 2px 6px;
border-radius: 999px;
border: 1px solid rgba(148, 163, 184, 0.22);
font-size: 11px;
font-weight: 800;
line-height: 1.2;
white-space: nowrap;
}
.physics-badge.dynamic {
color: #052e16;
background: #bbf7d0;
border-color: rgba(34, 197, 94, 0.42);
}
.physics-badge.visual {
color: #3b2602;
background: #fde68a;
border-color: rgba(245, 158, 11, 0.46);
}
.physics-badge.fixed {
color: #082f49;
background: #bae6fd;
border-color: rgba(14, 165, 233, 0.42);
}
.prop-row button {
height: 24px;
padding: 0 8px;
background: #c7d2fe;
font-size: 12px;
}
.prop-position {
display: grid;
grid-template-columns: repeat(3, minmax(0, 1fr));
gap: 6px;
}
.prop-position label {
display: grid;
grid-template-columns: 16px minmax(0, 1fr);
align-items: center;
gap: 5px;
margin: 0;
font-size: 11px;
}
.prop-position input {
width: 100%;
height: 28px;
padding: 0 6px;
font-size: 12px;
}
.prop-empty {
min-height: 30px;
padding: 7px;
color: #94a3b8;
background: rgba(15, 23, 42, 0.55);
border: 1px dashed rgba(148, 163, 184, 0.24);
border-radius: 6px;
font-size: 12px;
}
.button-row button {
background: #dbeafe;
}
.advanced-panel {
padding: 0;
}
.advanced-panel summary {
display: block;
padding: 14px;
color: #dbeafe;
font-size: 15px;
font-weight: 800;
cursor: pointer;
}
.advanced-panel[open] {
padding: 0 14px 14px;
}
.advanced-panel[open] summary {
margin: 0 -14px 12px;
border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}
.control-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
}
.control-grid button {
background: #bfdbfe;
}
#control-status,
#input-status,
#actuator-status,
#builder-status,
#workspace-status {
margin: 10px 0 0;
min-height: 18px;
color: #a7f3d0;
font-size: 13px;
line-height: 1.4;
}
.joint-form {
display: grid;
grid-template-columns: minmax(0, 1fr);
gap: 8px;
}
.joint-form input,
.joint-form select {
width: 100%;
}
#joint-status {
margin: 10px 0 0;
min-height: 18px;
color: #a7f3d0;
font-size: 13px;
line-height: 1.4;
}
dl {
display: grid;
grid-template-columns: minmax(104px, 0.9fr) minmax(0, 1.1fr);
gap: 8px 12px;
margin: 0;
font-size: 13px;
}
dt {
color: #94a3b8;
}
dd {
margin: 0;
min-width: 0;
overflow-wrap: anywhere;
color: #f8fafc;
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
text-align: right;
}
#status,
#state-status,
.note p {
margin: 0;
color: #b6c3d2;
font-size: 13px;
line-height: 1.45;
}
#state-status {
margin-top: 8px;
color: #86efac;
}
.viewport {
position: relative;
min-width: 0;
min-height: 0;
background: #0b1020;
}
#preview {
width: 100%;
height: 100%;
}
.preview-canvas {
display: block;
width: 100%;
height: 100%;
touch-action: none;
}
.preview-canvas.draggable-hover {
cursor: grab;
}
.preview-canvas.dragging {
cursor: grabbing;
}
.overlay {
position: absolute;
left: 18px;
top: 78px;
display: inline-flex;
align-items: center;
gap: 10px;
padding: 8px 10px;
color: #dbeafe;
background: rgba(15, 23, 42, 0.72);
border: 1px solid rgba(148, 163, 184, 0.26);
border-radius: 8px;
font-size: 13px;
backdrop-filter: blur(8px);
}
.drag-hint {
color: #7dd3fc;
font-size: 12px;
white-space: nowrap;
}
.hover-target {
margin-left: 4px;
padding: 2px 6px;
color: #f1f5f9;
border-radius: 6px;
border: 1px solid rgba(148, 163, 184, 0.36);
background: rgba(15, 23, 42, 0.5);
font-size: 11px;
white-space: nowrap;
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
}
.viewport-topbar {
position: absolute;
left: 18px;
right: 18px;
top: 18px;
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
min-height: 44px;
padding: 8px 10px;
color: #e5edf7;
background: rgba(15, 23, 42, 0.78);
border: 1px solid rgba(148, 163, 184, 0.26);
border-radius: 8px;
backdrop-filter: blur(8px);
}
.viewport-topbar > div:first-child {
display: grid;
gap: 2px;
min-width: 0;
}
.viewport-topbar strong,
.viewport-topbar span {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.viewport-topbar strong {
font-size: 13px;
}
.viewport-topbar span {
color: #a9b8ca;
font-size: 12px;
}
.sim-source {
display: inline-flex;
align-items: center;
width: fit-content;
margin-top: 2px;
padding: 1px 8px;
border-radius: 999px;
color: #7dd3fc;
background: rgba(56, 189, 248, 0.16);
border: 1px solid rgba(56, 189, 248, 0.45);
font-size: 11px;
}
.viewport-actions {
display: inline-flex;
gap: 8px;
flex: 0 0 auto;
}
.viewport-actions button {
height: 30px;
padding: 0 10px;
background: #dbeafe;
font-size: 12px;
}
.viewport-controls {
position: absolute;
left: 18px;
bottom: 18px;
display: inline-grid;
grid-template-columns: auto repeat(4, auto);
align-items: center;
gap: 8px;
max-width: calc(100% - 36px);
padding: 8px;
color: #dbeafe;
background: rgba(15, 23, 42, 0.78);
border: 1px solid rgba(148, 163, 184, 0.26);
border-radius: 8px;
backdrop-filter: blur(8px);
}
.viewport-controls span {
min-width: 58px;
color: #a7f3d0;
font-size: 12px;
font-weight: 800;
text-align: center;
}
.viewport-controls button {
height: 30px;
padding: 0 10px;
background: #dbeafe;
font-size: 12px;
}
.health-list,
.scene-outline,
#property-inspector {
display: grid;
gap: 8px;
}
.project-panel dd {
font-size: 12px;
}
.acceptance-panel {
background: rgba(6, 78, 59, 0.24);
border-color: rgba(45, 212, 191, 0.24);
}
.acceptance-verdict {
display: grid;
gap: 6px;
min-height: 58px;
padding: 10px;
background: rgba(2, 6, 23, 0.46);
border: 1px solid rgba(148, 163, 184, 0.18);
border-radius: 6px;
}
.acceptance-verdict strong {
color: #e5edf7;
font-size: 17px;
line-height: 1.2;
}
.acceptance-verdict strong.pass {
color: #86efac;
}
.acceptance-verdict strong.warn {
color: #fde68a;
}
.acceptance-verdict strong.fail {
color: #fda4af;
}
.acceptance-verdict span {
color: #94a3b8;
font-size: 12px;
line-height: 1.35;
}
.acceptance-checks {
display: grid;
gap: 8px;
margin-top: 10px;
}
.acceptance-case-title {
margin: 12px 0 8px;
color: #cbd5e1;
font-size: 12px;
font-weight: 800;
}
.acceptance-cases {
display: grid;
gap: 8px;
}
.acceptance-check {
display: grid;
grid-template-columns: 10px minmax(0, 1fr);
gap: 8px;
min-height: 46px;
padding: 8px;
background: rgba(15, 23, 42, 0.54);
border: 1px solid rgba(148, 163, 184, 0.16);
border-radius: 6px;
}
.acceptance-check > span {
width: 9px;
height: 9px;
margin-top: 4px;
border-radius: 999px;
}
.acceptance-check.pass > span {
background: #22c55e;
box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.14);
}
.acceptance-check.warn > span {
background: #f59e0b;
box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}
.acceptance-check.fail > span {
background: #f43f5e;
box-shadow: 0 0 0 4px rgba(244, 63, 94, 0.14);
}
.acceptance-check strong,
.acceptance-check small {
display: block;
min-width: 0;
overflow-wrap: anywhere;
}
.acceptance-check strong {
color: #dbeafe;
font-size: 12px;
}
.acceptance-check small {
margin-top: 3px;
color: #94a3b8;
font-size: 11px;
line-height: 1.35;
}
.acceptance-case {
display: grid;
gap: 6px;
min-height: 58px;
padding: 9px;
background: rgba(15, 23, 42, 0.42);
border: 1px solid rgba(148, 163, 184, 0.16);
border-left-width: 3px;
border-radius: 6px;
}
.acceptance-case.pass {
border-left-color: #22c55e;
}
.acceptance-case.warn {
border-left-color: #f59e0b;
}
.acceptance-case.fail {
border-left-color: #f43f5e;
}
.acceptance-case strong,
.acceptance-case small,
.acceptance-case p {
min-width: 0;
overflow-wrap: anywhere;
}
.acceptance-case strong {
color: #e5edf7;
font-size: 12px;
}
.acceptance-case small {
display: block;
margin-top: 3px;
color: #94a3b8;
font-size: 11px;
line-height: 1.35;
}
.acceptance-case p {
margin: 0;
color: #cbd5e1;
font-size: 11px;
line-height: 1.35;
}
#acceptance-status {
margin: 10px 0 0;
min-height: 18px;
color: #a7f3d0;
font-size: 13px;
line-height: 1.4;
}
.saved-project-panel input {
width: 100%;
}
.saved-project-list {
display: grid;
gap: 8px;
margin-top: 10px;
}
.saved-project-row {
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
align-items: center;
gap: 8px;
min-height: 50px;
padding: 8px;
background: rgba(30, 41, 59, 0.55);
border: 1px solid rgba(148, 163, 184, 0.16);
border-radius: 6px;
}
.saved-project-row strong,
.saved-project-row small {
display: block;
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.saved-project-row small {
margin-top: 4px;
color: #94a3b8;
font-size: 11px;
}
.saved-project-actions {
display: inline-grid;
grid-template-columns: auto auto;
gap: 6px;
}
.saved-project-actions button {
height: 26px;
padding: 0 8px;
background: #dbeafe;
font-size: 12px;
}
.health-item {
display: grid;
grid-template-columns: 10px minmax(0, 1fr);
align-items: center;
gap: 8px;
min-height: 30px;
color: #dbeafe;
font-size: 13px;
}
.health-item span {
width: 9px;
height: 9px;
border-radius: 999px;
}
.health-item.ok span {
background: #22c55e;
box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.16);
}
.health-item.warn span {
background: #f59e0b;
box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}
.activity-list {
display: grid;
gap: 7px;
}
.activity-item {
display: grid;
grid-template-columns: 68px minmax(0, 1fr);
align-items: start;
gap: 8px;
min-height: 32px;
padding: 8px;
color: #dbeafe;
background: rgba(30, 41, 59, 0.55);
border: 1px solid rgba(148, 163, 184, 0.16);
border-left-width: 3px;
border-radius: 6px;
font-size: 12px;
line-height: 1.35;
}
.activity-item.info {
border-left-color: #38bdf8;
}
.activity-item.ok {
border-left-color: #22c55e;
}
.activity-item.warn {
border-left-color: #f59e0b;
}
.activity-item time {
color: #94a3b8;
font-variant-numeric: tabular-nums;
}
.activity-item span {
min-width: 0;
overflow-wrap: anywhere;
}
.outline-static,
.outline-row {
display: grid;
grid-template-columns: minmax(62px, 0.7fr) minmax(0, 1.3fr);
align-items: center;
gap: 8px;
min-height: 34px;
padding: 7px 8px;
color: #dbeafe;
background: rgba(30, 41, 59, 0.55);
border: 1px solid rgba(148, 163, 184, 0.16);
border-radius: 6px;
font-size: 12px;
}
.outline-static span,
.outline-row span,
.outline-row small,
.inspector-heading span,
.inspector-heading small {
color: #94a3b8;
}
.outline-static strong,
.outline-row strong {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.outline-row {
grid-template-columns: 24px minmax(0, 1fr);
height: auto;
padding: 7px 8px;
text-align: left;
}
.outline-row small {
grid-column: 2;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.outline-row.selected {
border-color: rgba(250, 204, 21, 0.72);
background: rgba(63, 52, 20, 0.58);
}
.outline-divider {
height: 1px;
background: rgba(148, 163, 184, 0.18);
}
.inspector-heading {
display: grid;
gap: 5px;
padding: 10px;
background: rgba(8, 47, 73, 0.34);
border: 1px solid rgba(125, 211, 252, 0.2);
border-radius: 6px;
}
.inspector-heading strong,
.inspector-heading small {
min-width: 0;
overflow-wrap: anywhere;
}
.inspector-position {
display: grid;
grid-template-columns: 1fr;
gap: 8px;
}
.inspector-position label {
display: grid;
grid-template-columns: 24px minmax(0, 1fr);
align-items: center;
gap: 8px;
margin: 0;
}
.workflow-grid {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
}
.workflow-grid button,
.wide-action {
height: 34px;
padding: 0 10px;
background: #dbeafe;
font-size: 12px;
}
.wide-action {
width: 100%;
margin-top: 8px;
}
#workflow-report-text {
display: block;
width: 100%;
min-height: 132px;
margin-top: 8px;
padding: 10px;
resize: vertical;
color: #dbeafe;
background: #0b1220;
border: 1px solid rgba(148, 163, 184, 0.28);
border-radius: 6px;
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
font-size: 12px;
line-height: 1.45;
}
#workflow-status {
margin: 10px 0 0;
min-height: 18px;
color: #a7f3d0;
font-size: 13px;
line-height: 1.4;
}
#project-status {
margin: 10px 0 0;
min-height: 18px;
color: #a7f3d0;
font-size: 13px;
line-height: 1.4;
}
.diagnostics-panel {
background: rgba(15, 23, 42, 0.72);
border-color: rgba(125, 211, 252, 0.22);
}
.diagnostics-list dd {
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
overflow-wrap: anywhere;
}
#diagnostics-status {
margin: 10px 0 0;
min-height: 18px;
color: #a7f3d0;
font-size: 13px;
line-height: 1.4;
}
.live-dot {
width: 9px;
height: 9px;
border-radius: 999px;
background: #22c55e;
box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18);
}
@media (max-width: 820px) {
body {
overflow: auto;
}
.shell {
grid-template-columns: 1fr;
grid-template-rows: auto minmax(520px, 1fr) auto;
min-height: 100vh;
height: auto;
}
.sidebar,
.inspector {
max-height: none;
}
.inspector {
border-left: 0;
border-top: 1px solid rgba(148, 163, 184, 0.18);
}
.viewport-topbar {
align-items: stretch;
flex-direction: column;
}
.overlay {
top: 116px;
}
.viewport-controls {
grid-template-columns: auto auto auto;
right: 18px;
}
}