:root {
  color-scheme: light;
  --bg: #eef2f6;
  --sidebar: #111a24;
  --sidebar-2: #172330;
  --panel: #ffffff;
  --panel-soft: #f7f9fc;
  --text: #1c2633;
  --muted: #687589;
  --line: #d9e1ea;
  --line-strong: #c7d3df;
  --primary: #1769d1;
  --primary-dark: #1158b1;
  --danger: #c43b3b;
  --danger-dark: #a83232;
  --success: #15815d;
  --warning: #a76816;
  --shadow: 0 14px 36px rgba(26, 39, 56, 0.08);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  min-width: 1240px;
  min-height: 100%;
  margin: 0;
}

body {
  color: var(--text);
  background: var(--bg);
  font: 14px/1.5 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  display: grid;
  grid-template-columns: 248px minmax(980px, 1fr);
  min-height: 100vh;
}

.login-screen {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(23, 105, 209, 0.08), rgba(25, 167, 160, 0.07)),
    var(--bg);
}

.login-card {
  width: min(420px, 100%);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.brand.compact {
  padding: 0;
  margin-bottom: 22px;
  border-bottom: 0;
}

.login-title {
  margin-bottom: 18px;
}

.login-title h1 {
  font-size: 22px;
}

.login-title p,
.login-message {
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
}

.sidebar {
  position: sticky;
  top: 0;
  display: grid;
  grid-template-rows: auto 1fr auto;
  height: 100vh;
  overflow: auto;
  color: #eef4fb;
  background: var(--sidebar);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  background: linear-gradient(145deg, #1769d1, #19a7a0);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.24);
}

.brand-mark svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.brand-title {
  font-size: 16px;
  font-weight: 800;
}

.brand-subtitle {
  margin-top: 2px;
  color: #94a4b8;
  font-size: 12px;
}

.nav {
  padding: 16px 12px;
}

.nav-group + .nav-group {
  margin-top: 18px;
}

.nav-label {
  padding: 0 10px 7px;
  color: #7f91a7;
  font-size: 12px;
  font-weight: 700;
}

.nav-item {
  display: flex;
  align-items: center;
  width: 100%;
  height: 42px;
  gap: 11px;
  border: 0;
  border-radius: 8px;
  padding: 0 11px;
  color: #cbd6e4;
  background: transparent;
  text-align: left;
  transition: background 0.16s ease, color 0.16s ease;
}

.nav-item:hover,
.nav-item.active {
  color: #ffffff;
  background: var(--sidebar-2);
}

.nav-icon {
  flex: 0 0 auto;
  width: 21px;
  height: 21px;
  color: #9bb7db;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: color 0.16s ease, transform 0.16s ease;
}

.nav-item:hover .nav-icon {
  color: #d9e8fb;
}

.nav-item.active .nav-icon {
  color: #6db7ff;
  transform: translateX(1px);
}

.nav-item.active {
  box-shadow: inset 3px 0 0 #4aa3ff;
}

.sidebar-footer {
  margin: 12px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
}

.sidebar-footer-label {
  color: #91a3b8;
  font-size: 12px;
}

.sidebar-footer strong {
  display: block;
  margin-top: 6px;
  color: #ffffff;
  font-size: 16px;
}

.sidebar-footer span {
  display: block;
  margin-top: 3px;
  color: #91a3b8;
  font-size: 12px;
}

.main {
  min-width: 0;
  padding: 22px 24px 34px;
}

.topbar,
.panel-head,
.modal-head,
.modal-foot,
.designer-section-head,
.button-row,
.topbar-actions,
.filter-row,
.editor-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar,
.panel-head,
.modal-head,
.modal-foot,
.designer-section-head {
  justify-content: space-between;
}

.topbar {
  margin-bottom: 18px;
}

.account-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: 6px;
  padding-right: 10px;
  border-right: 1px solid var(--line);
}

.account-user {
  max-width: 160px;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: 24px;
}

h2 {
  font-size: 16px;
}

h3 {
  font-size: 14px;
}

.topbar p,
.panel-head p,
.modal-head p,
.designer-section-head p {
  margin-top: 4px;
  color: var(--muted);
}

.view {
  display: none;
}

.view.active {
  display: block;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 160px) minmax(260px, 1fr) 160px;
  gap: 12px;
  margin-bottom: 16px;
}

.stat-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.stat-card span,
.info-list span,
.setting-card span,
label span {
  color: var(--muted);
  font-size: 12px;
}

.stat-card strong {
  display: block;
  overflow: hidden;
  margin-top: 4px;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 20px;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel-head {
  min-height: 64px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--panel-soft);
}

.filter-row input {
  width: 260px;
}

.filter-row select {
  width: 130px;
}

.table-wrap {
  overflow: auto;
}

.data-table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
}

.data-table th,
.data-table td {
  border-bottom: 1px solid var(--line);
  padding: 12px 14px;
  text-align: left;
  vertical-align: middle;
}

.data-table th {
  color: var(--muted);
  background: #fbfcfe;
  font-size: 12px;
  font-weight: 800;
}

.data-table tr:hover td {
  background: #f8fbff;
}

.map-name-cell strong,
.map-name-cell span {
  display: block;
}

.map-name-cell span {
  max-width: 420px;
  overflow: hidden;
  margin-top: 3px;
  color: var(--muted);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
}

.status-badge {
  display: inline-grid;
  min-width: 58px;
  height: 24px;
  place-items: center;
  border-radius: 999px;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 750;
}

.status-badge.published {
  color: var(--success);
  background: #e7f6f1;
}

.status-badge.published_changed {
  color: var(--warning);
  background: #fff4de;
}

.status-badge.draft {
  color: var(--warning);
  background: #fff4de;
}

.status-badge.waiting_upload,
.status-badge.queued {
  color: #516174;
  background: #eef2f6;
}

.status-badge.uploading,
.status-badge.importing {
  color: var(--primary);
  background: #eaf3ff;
}

.status-badge.completed {
  color: var(--success);
  background: #e7f6f1;
}

.status-badge.failed {
  color: var(--danger);
  background: #ffecec;
}

.status-badge.neutral {
  color: #516174;
  background: #eef2f6;
}

.status-badge.http-success {
  color: var(--success);
  background: #e7f6f1;
}

.status-badge.http-redirect {
  color: var(--primary);
  background: #eaf3ff;
}

.status-badge.http-client {
  color: var(--warning);
  background: #fff4de;
}

.status-badge.http-server {
  color: var(--danger);
  background: #ffecec;
}

.progress-track {
  width: 150px;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e6edf5;
}

.progress-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

.progress-text {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.compact-actions {
  margin-top: 6px;
}

.cell-clip {
  display: block;
  max-width: 280px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.page-grid {
  display: grid;
  gap: 16px;
}

.two-col {
  grid-template-columns: minmax(520px, 1fr) 420px;
}

.import-grid {
  grid-template-columns: minmax(460px, 1fr) minmax(460px, 1fr);
}

.resource-grid {
  grid-template-columns: minmax(460px, 1fr) minmax(460px, 1fr);
}

.resource-list-panel {
  margin-top: 16px;
}

.import-jobs-panel {
  margin-top: 16px;
}

.padded {
  padding: 16px;
}

.hint {
  color: var(--muted);
  font-size: 12px;
}

.resource-grid-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 12px;
  padding: 16px;
}

.resource-grid-list.picker {
  padding: 0;
}

.resource-card {
  display: grid;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  background: #ffffff;
}

.resource-preview {
  display: grid;
  height: 120px;
  place-items: center;
  overflow: hidden;
  border-radius: 6px;
  color: var(--muted);
  background: #f1f4f8;
}

.resource-preview img,
.resource-preview video {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.resource-title {
  overflow: hidden;
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.resource-meta {
  color: var(--muted);
  font-size: 12px;
}

.resource-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.overview-stats {
  grid-template-columns: repeat(6, minmax(150px, 1fr));
}

.compact-table {
  min-width: 620px;
}

.hidden-field {
  display: none !important;
}

.input-with-button,
.textarea-with-button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: start;
}

.common-icon-field {
  display: grid;
  gap: 6px;
}

.common-icon-field > span {
  color: var(--muted);
  font-size: 12px;
}

.common-icon-palette {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(36px, 1fr));
  gap: 8px;
}

.common-icon-btn {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
}

.common-icon-btn:hover,
.common-icon-btn.active {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(23, 105, 209, 0.12);
}

.common-icon-btn img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.textarea-with-button textarea {
  min-height: 96px;
}

.select-filter-stack {
  display: grid;
  gap: 8px;
}

.file-field input[type="file"] {
  width: 100%;
  min-height: 48px;
  padding: 8px;
  border: 1px solid #d6deea;
  border-radius: 8px;
  color: #344258;
  background:
    linear-gradient(180deg, #ffffff 0%, #f8fbff 100%),
    #f8fbff;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.file-field input[type="file"]::file-selector-button {
  height: 32px;
  margin-right: 12px;
  border: 0;
  border-radius: 6px;
  padding: 0 14px;
  color: #ffffff;
  background: var(--primary);
  font-weight: 750;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(23, 105, 209, 0.22);
}

.file-field input[type="file"]:hover {
  border-color: var(--primary);
  background: #f2f7ff;
  box-shadow: 0 0 0 3px rgba(23, 105, 209, 0.11);
}

.file-field input[type="file"]:focus-visible {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(23, 105, 209, 0.18);
}

.file-field span {
  display: block;
  margin-bottom: 6px;
  font-weight: 700;
}

.setting-card,
.license-panel,
.info-list {
  display: grid;
  gap: 10px;
  padding: 16px;
}

.setting-card {
  display: block;
  margin: 16px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #ffffff;
}

.setting-card code,
.setting-card p {
  display: block;
  margin-top: 6px;
}

.setting-card.muted p {
  color: var(--muted);
}

.license-panel {
  padding-top: 0;
}

.license-input textarea {
  min-height: 126px;
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
}

.license-file {
  margin: 0;
}

.license-file small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  line-height: 1.5;
}

.info-list div {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 10px 12px;
  background: #ffffff;
}

.info-list strong,
.info-list code {
  display: block;
  overflow-wrap: anywhere;
  margin-top: 4px;
}

.text-danger {
  color: #c43b3b !important;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-stack {
  display: grid;
  gap: 12px;
}

.span-2 {
  grid-column: span 2;
}

.model-url {
  grid-column: span 1;
}

.mini-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

label {
  display: grid;
  gap: 5px;
  min-width: 0;
}

input,
select,
textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--text);
  background: #ffffff;
}

input,
select {
  height: 36px;
  padding: 0 10px;
}

textarea {
  min-height: 80px;
  resize: vertical;
  padding: 8px 10px;
}

.subsection {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.subsection-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.camera-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 12px;
}

.record-list {
  display: grid;
  gap: 8px;
  overflow: auto;
}

.record-list.compact {
  max-height: calc(100vh - 195px);
  padding: 12px;
}

.object-filter-row {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) 160px 160px;
  gap: 10px;
  margin-bottom: 12px;
}

.record-item {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 10px 11px;
  color: var(--text);
  background: #ffffff;
  text-align: left;
}

.object-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.object-main {
  min-width: 0;
  border: 0;
  padding: 0;
  color: inherit;
  background: transparent;
  text-align: left;
}

.object-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
}

.record-item:hover,
.record-item.active {
  border-color: #95b8e8;
  background: #f0f6ff;
}

.record-title {
  overflow: hidden;
  font-weight: 760;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.record-meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 18, 26, 0.54);
}

.modal-panel {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  max-height: calc(100vh - 48px);
  overflow: hidden;
  transform: translate(-50%, -50%);
  border-radius: 9px;
  background: var(--panel);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.34);
}

.modal-sm {
  width: min(540px, calc(100vw - 48px));
}

.modal-md {
  width: min(760px, calc(100vw - 48px));
}

.modal-lg {
  width: min(1080px, calc(100vw - 48px));
}

.designer-panel {
  width: calc(100vw - 48px);
  height: calc(100vh - 48px);
}

.designer-panel .modal-head {
  flex-wrap: wrap;
}

.modal-head,
.modal-foot {
  min-height: 64px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--panel-soft);
}

.modal-foot {
  justify-content: flex-end;
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.modal-body {
  overflow: auto;
  padding: 16px;
}

.designer-layout {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  min-height: 0;
  overflow: hidden;
}

.designer-section-head {
  min-height: 62px;
  padding: 12px;
  border-bottom: 1px solid var(--line);
}

.designer-map {
  position: relative;
  min-width: 0;
  min-height: 0;
  background: #101720;
}

.designer-toolbars,
.designer-property-toggle {
  position: absolute;
  top: 12px;
  z-index: 20;
}

.designer-toolbars {
  left: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
  max-width: calc(100% - 72px);
}

.designer-map-toolbar,
.designer-map-actions,
.designer-property-toggle {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(17, 26, 36, 0.86);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
}

.designer-map-toolbar {
  max-width: min(660px, calc(100vw - 500px));
}

.designer-map-actions {
  max-width: min(500px, calc(100vw - 690px));
}

.designer-property-toggle {
  right: 12px;
  padding: 8px;
}

.designer-view-controls {
  position: absolute;
  left: 12px;
  top: 74px;
  z-index: 20;
  display: grid;
  gap: 6px;
  padding: 7px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(17, 26, 36, 0.86);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
}

.map-control-btn {
  display: grid;
  width: 34px;
  height: 32px;
  place-items: center;
  border: 0;
  border-radius: 6px;
  color: #f5f8fc;
  background: rgba(255, 255, 255, 0.12);
  font-size: 18px;
  font-weight: 800;
  cursor: pointer;
}

.map-control-btn svg,
.icon-tool-btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.map-control-btn:hover {
  background: rgba(255, 255, 255, 0.22);
}

.icon-tool-btn {
  display: grid;
  width: 34px;
  height: 32px;
  place-items: center;
  border: 0;
  border-radius: 6px;
  color: #f5f8fc;
  background: rgba(22, 31, 43, 0.82);
  cursor: pointer;
}

.icon-tool-btn:hover {
  background: rgba(22, 31, 43, 0.96);
}

.icon-tool-btn.active {
  color: #0d1722;
  background: #ffffff;
}

.tool-btn {
  height: 30px;
  border: 0;
  border-radius: 6px;
  padding: 0 10px;
  color: #f5f8fc;
  background: rgba(255, 255, 255, 0.12);
  font-weight: 750;
  cursor: pointer;
}

.tool-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

.tool-btn.active {
  color: #0d1722;
  background: #ffffff;
}

.tool-btn:disabled,
.primary-btn:disabled,
.secondary-btn:disabled,
.danger-btn:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.danger-tool {
  background: rgba(196, 59, 59, 0.72);
}

.draw-hint {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 20;
  max-width: 420px;
  padding: 9px 11px;
  border-radius: 8px;
  color: #f5f8fc;
  background: rgba(17, 26, 36, 0.9);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
  font-size: 13px;
}

.draw-actions {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}

.draw-actions button {
  height: 28px;
  border: 0;
  border-radius: 6px;
  padding: 0 10px;
  color: #f5f8fc;
  background: rgba(255, 255, 255, 0.14);
  font-weight: 750;
  cursor: pointer;
}

.draw-actions button:hover {
  background: rgba(255, 255, 255, 0.22);
}

.draw-icon-picker {
  position: absolute;
  left: 12px;
  bottom: 82px;
  z-index: 20;
  width: min(320px, calc(100% - 24px));
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(17, 26, 36, 0.9);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.24);
}

.draw-icon-picker-title {
  margin-bottom: 8px;
  color: #f5f8fc;
  font-size: 13px;
  font-weight: 750;
}

.draw-icon-picker .common-icon-palette {
  grid-template-columns: repeat(auto-fill, minmax(38px, 1fr));
}

.draw-icon-picker .common-icon-btn {
  width: 38px;
  height: 38px;
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.96);
}

#mapPreview {
  width: 100%;
  height: 100%;
  min-height: 600px;
}

.designer-property-panel {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 25;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  width: min(420px, calc(100vw - 96px));
  height: 100%;
  min-width: 0;
  min-height: 0;
  border-left: 1px solid var(--line);
  background: var(--panel);
  box-shadow: -18px 0 38px rgba(12, 18, 26, 0.18);
  transform: translateX(0);
  transition: transform 0.18s ease, opacity 0.18s ease;
  visibility: visible;
}

.designer-property-panel[hidden] {
  display: grid !important;
  pointer-events: none;
  opacity: 0;
  transform: translateX(100%);
  visibility: hidden;
}

.property-panel-head,
.property-panel-foot {
  min-height: 62px;
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--panel-soft);
}

.property-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.property-panel-head h2 {
  margin: 0;
  font-size: 18px;
}

.property-panel-head p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.property-head-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 6px;
}

.property-pin-btn svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.property-pin-btn.active {
  color: #ffffff;
  background: var(--primary);
}

.property-close-btn {
  flex: 0 0 auto;
}

.property-panel-body {
  min-height: 0;
  overflow: auto;
  padding: 14px;
}

.property-panel-body[hidden],
.property-panel-foot[hidden] {
  display: none !important;
}

.property-panel-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.property-form-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
}

.property-form-grid textarea {
  min-height: 68px;
}

.property-form-grid #markerGeometryInput,
.property-form-grid #markerExtraInput {
  min-height: 92px;
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  font-size: 12px;
}

@media (max-width: 1180px) {
  .designer-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .property-form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .property-form-grid .span-2 {
    grid-column: auto;
  }
}

.check-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.check-row input {
  width: 16px;
  height: 16px;
}

.modal-check {
  margin-top: 12px;
}

.sdk-layout {
  display: grid;
  grid-template-columns: minmax(520px, 1fr) 320px;
  min-height: 520px;
}

#sdkSnippet {
  height: 100%;
  min-height: 520px;
  overflow: auto;
  margin: 0;
  padding: 16px;
  color: #dce8f8;
  background: #111a24;
  font: 12px/1.65 ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
}

.sdk-info {
  display: grid;
  grid-template-rows: 1fr auto;
  border-left: 1px solid var(--line);
  background: var(--panel-soft);
}

.sdk-info .primary-btn.full {
  margin: 0 16px 16px;
  width: calc(100% - 32px);
}

.primary-btn,
.secondary-btn,
.danger-btn,
.ghost-btn,
.icon-btn {
  height: 34px;
  border: 0;
  border-radius: 6px;
  padding: 0 12px;
  font-weight: 750;
  white-space: nowrap;
}

.primary-btn {
  color: #ffffff;
  background: var(--primary);
}

.primary-btn:hover {
  background: var(--primary-dark);
}

.secondary-btn,
.ghost-btn {
  color: #263243;
  background: #e4ebf3;
}

.secondary-btn:hover,
.ghost-btn:hover {
  background: #d8e2ed;
}

.danger-btn {
  color: #ffffff;
  background: var(--danger);
}

.danger-btn:hover {
  background: var(--danger-dark);
}

.icon-btn {
  width: 34px;
  padding: 0;
  color: #263243;
  background: #e4ebf3;
  font-size: 20px;
  line-height: 1;
}

.small-btn {
  height: 28px;
  border: 0;
  border-radius: 5px;
  padding: 0 8px;
  color: #263243;
  background: #e8eef5;
  font-size: 12px;
  font-weight: 750;
}

.small-btn.primary {
  color: #ffffff;
  background: var(--primary);
}

.small-btn.danger {
  color: #ffffff;
  background: var(--danger);
}

.full {
  width: 100%;
}

.toast {
  position: fixed;
  top: 18px;
  left: 50%;
  right: auto;
  bottom: auto;
  z-index: 100;
  width: max-content;
  max-width: min(520px, calc(100vw - 32px));
  transform: translateX(-50%);
  padding: 10px 16px;
  border-radius: 8px;
  color: #ffffff;
  text-align: center;
  box-shadow: 0 16px 40px rgba(26, 39, 56, 0.18);
}

.toast.success {
  background: #15815d;
}

.toast.error {
  background: #c43b3b;
}
