.map-fullscreen-button {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 36;
  width: 42px;
  height: 42px;
  border: 1px solid var(--map-position-border);
  border-radius: 8px;
  background: var(--map-position-bg);
  color: var(--accent-strong);
  cursor: pointer;
  pointer-events: auto;
  box-shadow: 0 8px 20px rgba(58, 48, 36, 0.12);
}

.map-fullscreen-button::before,
.map-fullscreen-button::after {
  position: absolute;
  inset: 11px;
  content: "";
  border-color: currentColor;
  border-style: solid;
}

.map-fullscreen-button::before {
  border-width: 2px 0 0 2px;
}

.map-fullscreen-button::after {
  border-width: 0 2px 2px 0;
}

.map-fullscreen-button:hover {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--focus-ring), 0 10px 26px rgba(58, 48, 36, 0.14);
}

.map-fullscreen-button.is-active::before {
  inset: 14px 9px 9px 14px;
  border-width: 0 2px 2px 0;
}

.map-fullscreen-button.is-active::after {
  inset: 9px 14px 14px 9px;
  border-width: 2px 0 0 2px;
}

.fullscreen-exit-button {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 1003;
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--map-position-border);
  border-radius: 999px;
  background: var(--map-position-bg);
  color: var(--accent-strong);
  cursor: pointer;
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  pointer-events: auto;
  box-shadow: 0 8px 20px rgba(58, 48, 36, 0.16);
}

.fullscreen-exit-button:hover {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--focus-ring), 0 10px 26px rgba(58, 48, 36, 0.18);
}

.tree-canvas:fullscreen {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100dvh;
  border-radius: 0;
}

.tree-canvas:-webkit-full-screen {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100dvh;
  border-radius: 0;
}

body.map-fullscreen-fallback,
body.map-fullscreen-native {
  overflow: hidden;
}

body.map-fullscreen-fallback .topbar,
body.map-fullscreen-fallback .sidebar,
body.map-fullscreen-fallback .panel-tab,
body.map-fullscreen-fallback .map-settings-toggle,
body.map-fullscreen-fallback .workspace__header {
  display: none !important;
}

body.map-fullscreen-fallback .layout {
  display: block;
  padding: 0;
}

body.map-fullscreen-fallback .workspace {
  position: fixed;
  inset: 0;
  z-index: 1000;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

body.map-fullscreen-fallback .tree-canvas {
  position: fixed;
  inset: 0;
  z-index: 1000;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  min-height: 100vh;
  min-height: 100dvh;
  border-radius: 0;
}

body.map-fullscreen-fallback .map-fullscreen-button,
body.map-fullscreen-native .map-fullscreen-button {
  position: fixed;
  z-index: 1002;
}

body.map-fullscreen-fallback .fullscreen-exit-button,
body.map-fullscreen-native .fullscreen-exit-button {
  position: fixed;
}

.tree-canvas:fullscreen .map-position,
.tree-canvas:-webkit-full-screen .map-position,
body.map-fullscreen-fallback .tree-canvas .map-position,
body.map-fullscreen-native .tree-canvas .map-position {
  top: 64px;
  right: auto;
  left: 12px;
}

.radial-canvas-shell:fullscreen .radial-position,
.radial-canvas-shell:-webkit-full-screen .radial-position,
body.radial-fullscreen-fallback .radial-position {
  top: 12px;
  right: auto;
  left: 12px;
}
