html怎么让图片中三个元素间距变紧凑,不想要滚轮

这是插入的iframe标签,宽高不变的情况下有没有办法讲这三个元素弄到一起
图片

img

img

https://www.imbuerjia.cn/

HTML

<!DOCTYPE html>
<html lang="en" >
<head>
  <meta charset="UTF-8">
  <title> 益智游戏演示</title>
  <meta name="viewport" content="width=device-width, initial-scale=1"><link rel="stylesheet" href="css/Game_style.css">

</head>
<body>

<div class="top-bar">
  <button class="button level-select-button">Levels</button>
</div>

<ol class="level-list"></ol>

<canvas></canvas>
<p class="instruction"></p>
<button class="button next-level-button">Next level</button>

<div class="levels">

<pre id="intro-fixed1" data-blurb="Tutorial">
blurb: Tutorial
instruction: Drag cub to star
---
*=.=.
    !
. . .
    !
@=.=.
</pre>

<pre id="intro-fixed2" data-blurb="Tutorial">
blurb: Tutorial
instruction: Drag grid to rotate. Cub and star moves with grid. Orange links stay in place.
---
* . .
    !
. . .
    !
@=.=.
</pre>

<pre id="intro-fixed3" data-blurb="★">
blurb: ★
---
@=. .

. . .
    !
*=. .
</pre>

<pre id="intro-free1" data-blurb="Tutorial">
blurb: Tutorial
instruction: Blue links move with grid. Rotate grid to connect blue and orange links in different ways.
---
@-. .
!   | 
. . .
    |
*-.-.
</pre>

<pre id="m3x3-2-med" data-blurb="★">
blurb: ★
---
. . *
| | | 
. . .
| | | 
@ .=.
</pre>

<pre id="m3x3-fixed-switch" data-blurb="★">
blurb: ★
---
*=.-.
 
. . .
    | 
@-. .
</pre>

<pre id="m4x4-2" data-blurb="★">
blurb: ★
---
. .=. .
  | !  
. . .-*
  |    
. . . .
       
. @-. .
</pre>

<pre id="m4x4-1" data-blurb="★">
blurb: ★
---
. . . .
       
* . . @
  | ! |
. . . .
  !    
. . . .
</pre>

<pre id="m4x4-3" data-blurb="★">
blurb: ★
---
. @ . .
! |    
. . . .
      |
.=.=.-.
|       
. * . .
</pre>

<pre id="m4x4-4" data-blurb="★">
blurb: ★
---
. . . .
       
* . . .
    !  
. . .-.
!      
.=.=. @
</pre>

<pre id="m4x4-5" data-blurb="★">
blurb: ★
---
.-.-.-.
|       
@ .-.-.
       
* .=. .
!   |   
.-.-. .
</pre>

<pre id="m4x4-6-med" data-blurb="★">
blurb: ★
---
. * . .

.-.=. .
  |
. . . .
!   |
.=. @ .
</pre>

<pre id="m4x4-7-hard1" data-blurb="★★">
blurb: ★★
---
. . *-.
       
.-.=. .
      |
.=. . .
  | |  
@-.-.=.
</pre>

<pre id="m4x4-8-hard2" data-blurb="★★">
blurb: ★★
---
.-@ .=.
       
. . . .
    |  
.-. .-*
  |    
. .=.-.
</pre>

<pre id="m4x4-9-hard1" data-blurb="★★">
blurb: ★★
---
. . .=.
  !    
@-. .-.
     
. .=. .
       
. . * .
</pre>

<pre id="m4x4-10-hard1" data-blurb="★★">
blurb: ★★
---
. @=. .
  |   
. .-.-.
       
.-.-.-.
!     ! 
. * . .
</pre>

<pre id="m5x5-3" data-blurb="★">
. . . . .
  | !   
. . .-. .
  |     
. . . . *
  |     
. . .=. .
  |     
. @ . . .
</pre>

<pre id="m5x5-1" data-blurb="★">
@-.-. .-.
    |    
. . . . .
         
. . .=. .
         
. . . .=.
    |    
. .=.-* .
</pre>

<pre id="m5x5-2" data-blurb="★★">
. . . . .
        
. .=.-. @
|       !
. . . .-.
        
.=. . .=.
!       
* . . . .
</pre>

<pre id="m5x5-4" data-blurb="★★">
. . . .-.
      ! 
. .-. . .
  !     |
.=. . . .
|        
. . . . *
|        
.-@=. .=.
</pre>

<pre id="m5x5-5" data-blurb="★★">
. . . . .

. . .-. *
    !
. . .-. .

.=. . . .
    |
. @-. . .
</pre>

<pre id="m5x5-6" data-blurb="★★">
. . .-.-.
!   !    
. .=.-. .
|   
. .-. .-@
!
* .=. . .
      |
.=. .-.=.
</pre>

<pre id="m5x5-7" data-blurb="★★★">
.=* . @=.
|
. .=. . .
|   | |
.=. . .-.
        |
. . . .=.
!    
. .-.-. .
</pre>

<pre id="m5x5-8" data-blurb="★★★">
. * . .-.
  |     
. . .=.-.
!       | 
. . . . .
        
. .-. .=.
        |
. . .=.-@
</pre>

<pre id="m5x5-9" data-blurb="★★★">
.-.-. . .
    |    
. . . .-@
  !      
* . .-. .
|   !    
.-. . .=.
    |   !
. . .=. .
</pre>

<pre id="m5x5-10" data-blurb="★★">
. . . . .
         
. . . .-@
  !      
* . .=. .
|   !    
.-. . . .
         
. . . . .
</pre>

<pre id="m5x5-11" data-blurb="★★★">
. . . .=.
  |     
. . . .=.
|        
. . .-. .
! |     
. .=. . .
|   !   !
.-@ . * .
</pre>

<pre id="m5x5-12" data-blurb="★★">
. . .=.=.
        
. . . . .
        
. . . . @
        
. . . . .
        
* . .=.=.
</pre>

<pre id="m6x6-1-hard1" data-blurb="★★★">
. . * . . .
  ! | |  
. .-. .-. .
          |
. . . . .-.
      | ! |
. . .=. . .
    |
@-.-. .-. .
          |
. .=. . .-.
</pre>

<pre id="m6x6-2" data-blurb="★★★">
@ .=. . .=.
  | | !
. . . .=. .
  |     |
. . . .-. .
|   !
. . . . . *
|     |
.=. .-. . .
  |   | |
.-. . . .=.
</pre>

<pre id="m6x6-3" data-blurb="★★★">
.=. .=.-.-*
  |        
.-. . . . .
        | !
. . .-.-. .
!          
.-. .=.=. .
           
@ .=. . . .
  |     !
. .-. .-. .
</pre>

<pre id="pivot-4x4-intro" data-blurb="Tutorial">
instruction: Green links pivot with grid, but point in the same direction
---
. .-* .
  |    
. . . .
       
. .>. .
       
. @ . .
</pre>

<pre id="pivot-5x5-2" data-blurb="★★">
. . .-.-@
        
. .<. . .
        
.>. . . .
| !      
.-.-. . *
  !     
. . . . .
</pre>

<pre id="pivot-5x5-swirly" data-blurb="★★★">
. . . . .
      ^ 
.<. . . *
        
. . . . .
        
@ . . .>.
  v     
. . . . .
</pre>

<pre id="pivot-5x5-1" data-blurb="★★★">
. .-. . .
      ^ 
. .<.=.=.
        
.>. . .-@
        
* . . .=.
        
. . . . .
</pre>

<pre id="pivot-5x5-3" data-blurb="★★">
.=. . .-*
    v   
. . . . .
         
. . .-.J.
         
@-. . . .
    v   
.<. . . .
</pre>

<pre id="pivot-5x5-4" data-blurb="★★★">
.-.-. @>.
!     ^ 
. . . . .
  |      
. . . . .
  |     
. . . .=*
    ^    
. . .-. .>
</pre>

<pre id="pivot-5x5-5" data-blurb="★★★">
.-. . . *
        
. .>. . .
|       v
.-. . . .
  ^      
. . .-. .
      v 
@=.=. . .
</pre>

<pre id="pivot-5x5-6" data-blurb="★★★">
. . .>. .
  ! |    
@=. .-. .
        
. . . .=.>
         
. . . . .
         
. *>.<. .
</pre>

<pre id="pivot-5x5-7" data-blurb="★★★">
* . @ . .
v   |   
. . . . .
      !  
. . . . .
^     ! !
. .-. . .
  !     
. . . . .
    v
</pre>

<pre id="pivot-6x6-1" data-blurb="★★★">
. . . . . .
| v         
@ . . . . *
  | |      
. . . . . .
| !   ^ | K
. . . .-.=.
|          
. .-. . . .
v          
.>. . . . .
</pre>

<pre id="pivot-6x6-3" data-blurb="★★★">
. @-. .>.-.
          
. . . . . .
          |
* .>. .=. .
    !      
. . . . . .>
      |   ^
. . . .=. .
           
. .=. . .=.>
</pre>

<pre id="pivot-6x6-2" data-blurb="★★★">
. .-.-. .=.
      v   
. . . . . .
  |     ! v
.>. . . . *
    ^      
. . . . . .
|          
. .-.<. . .
! |       |
. . . .>.-@
</pre>

<pre id="m44" data-blurb="★★">
. .=. *-.
        
. . .=. .
!        
. . . . .
  |   ! 
. . . . .
  |     |
. @ . .=.
</pre>

<pre id="m45" data-blurb="★★">
@ * .>. .
        
. .=.=. .
|     | 
.>. . . .
        
. . . .>.
|       
.=. . .-.
</pre>

<pre id="m46" data-blurb="★★★">
.-. . .
    ^ 
. . . .
       
.L. . .
      !
@ . .-*
</pre>

<pre id="m47" data-blurb="★★">
@ . . . . .
v v v v v v
. . . . . .
 
. . . . . .
           
. . . . . .
  v v v v v
. . . . . .
           
. . . .=. *
v v v v   v
</pre>

<pre id="m48" data-blurb="★">
.-.<.>.=. .
W !       |
. . .A. . *
    |   |  
. .=. . . .
^ !        
. .D.-.=.=@
          | 
. . .-.-. .
|          
.#.=. .<. .
    v     v
</pre>

<pre id="m49" data-blurb="★★★">
. . .-@ .
    |   
. . . .J.
        
* . . . .
| !     !
. . . . .
    v   !
. . . .-.
</pre>

<pre id="m50" data-blurb="★★★">
*=. . .
    v  
. . . .
^     |
. . . .
  ^   |
@ .>. .
</pre>

<pre id="rotate-tut" data-blurb="Tutorial">
instruction: Red links are fixed in place, but rotate with grid
---
. . . .
       
@ .4. .
  |    
. . .-*
       
. . . .
</pre>

<pre id="rotate1" data-blurb="★">
. . .-*
    |  
. . . .
    5  
.4. . .
|      
@ . . .
</pre>

<pre id="rotate2" data-blurb="★★">
@ .-.=.
    |  
. . .4.
    |  
* . . .
|   |  
. . . . 
</pre>

<pre id="rotate3" data-blurb="★★">
. . * .
! 5 v  
. . . @
  |    
. .4. .
  !    
. . . .
</pre>

<pre id="rotate3b" data-blurb="★★">
* . . .
! 5    
. . . @
  |    
. .4. .
  !    
. . . .
</pre>

<pre id="rotate-5x5-1" data-blurb="★★">
. . . .-@
      8 
. .=. . .
        
*=. . . .
        
. .-. . .
        
. . . . .
</pre>

<pre id="rotate-5x5-2" data-blurb="★★">
. . . . .
        
. . . .6*
  |     
. . . .=.
  |     
.4. . . .
        |
. . . .-@
</pre>

<pre id="rotate-5x5-2b" data-blurb="★★★">
. . . . .
  !   | 
.-.-. . .
  v   |
. . .-. .
        
@ . . . .
    5   
. . .=* .
</pre>

<pre id="rotate-6x6-1" data-blurb="★★★">
@4.=. . . .
          
. . . . . .
      v 8 |
.-.-. . . .
!   !   ^   
. . . . . .
           
. .>. . . .
!          
* . .4. . .
</pre>

<pre id="rotate-6x6-2" data-blurb="★★★">
. . *<. . .
          
.=. .-. . .
        5
. . . .-. .
        |   
. . . . . .
           
. . . . . .
    5     | 
. .=. . @-.
</pre>

<pre id="rotate-6x6-3" data-blurb="★★★">
.4. . . . @
!          
.-. . .=. .
! 
. . . . . .
!           
.>.6. . . .
!          
. . . .=.-.
      ^    
. . . . * .
</pre>


</div>

  <script  src="js/Game_script.js"></script>

</body>
</html>


CSS

* { box-sizing: border-box; }

body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    font-family: 'Avenir Next', Avenir, sans-serif;
    font-weight: 500;
    font-size: 20px;
    color: #555;
    background-color: #1B1B1B;
}

canvas {
  cursor: move;
  display: block;
  position: absolute;
  max-width: 100%;
  left: 0;
  top: 0;
}

.is-cub-hovered,
.is-cub-hovered canvas {
  cursor: -webkit-grab;
  cursor: grab;
}

.is-cub-dragging,
.is-cub-dragging canvas {
  cursor: -webkit-grabbing;
  cursor: grabbing;
}

.instruction {
  padding: 0 10px;
  text-align: center;
  position: absolute;
  width: 100%;
  padding-bottom: 40px;
}

.button {
  font-family: 'Avenir Next', Avenir, sans-serif;
  font-weight: 500;
  font-size: 20px;
  padding: 5px 15px;
  margin: 10px;
  background: #BBB;
  color: white;
  border-radius: 5px;
  border: none;
  cursor: pointer;
}

.button:hover {
  background: #09F;
}

.top-bar {
  position: absolute;
  left: 0;
  top: 0;
}

.level-select-button {
  position: relative;
  z-index: 2; /* above canvas */
}

.next-level-button {
  position: absolute;
  left: 50%;
  -webkit-transform: translateX(-110px) scale(0.5);
  transform: translateX(-110px) scale(0.5);
  opacity: 0;
  background: #09F;
  width: 200px;
  height: 80px;
  pointer-events: none;
  -webkit-transition: -webkit-transform 0.2s, opacity 0.2s;
  transition: transform 0.2s, opacity 0.2s;
}

.next-level-button:hover {
  background: #2BF;
}

.next-level-button.is-open {
  display: inline-block;
  pointer-events: auto;
  -webkit-transform: translateX(-110px) scale(1);
  transform: translate(-110px) scale(1);
  opacity: 1;
}

/* ---- level list ---- */

.level-list {
  position: absolute;
  background: #EEE;
  width: 100%;
  min-height: 100%;
  left: 0;
  top: 0;
  margin: 0;
  list-style: none;
  padding: 10px;
  z-index: 3; /* above canvas, level select button */
  left: -100%;
  transition: left 0.2s;
}

.level-list.is-open {
  left: 0;
}

.level-list__item {
  display: inline-block;
  background: #DDD;
  margin: 5px;
  padding: 10px;
  width: 80px;
  height: 80px;
  text-align: center;
  border-radius: 10px;
  position: relative;
}

.level-list__item:hover {
  color: #09F;
  cursor: pointer;
  background: white;
}

.level-list__item.is-playing {
  background: #09F;
  color: white;
}

.level-list__item__number {
  display: block;
  font-size: 30px;
  line-height: 35px;
}

.level-list__item__blurb {
  display: block;
  font-size: 16px;
}

.level-list__item__check {
  position: absolute;
  right: -10px;
  top: -10px;
  width: 30px;
  line-height: 30px;
  background: #555;
  border-radius: 15px;
  color: white;
  display: none;
}

.level-list__item.did-complete .level-list__item__check {
  display: block;
}

/* ---- level pres ---- */

.levels { display: none; }

检查一下样式 。看看是不是有margin