body {
    font-family: Impact;
    margin: 0;
    padding: 20px;
    background-image: url("../pics/фон.png");
    background-repeat: repeat;
    overflow-x: hidden;
}

h1 {
  color: #6a3314;
  text-align: center;
  font-family: Impact;
  
} 
h2 {
  color: #401802;
  text-align: center;
  font-family: Impact;
}   
.chapters {
    gap: 20px;
    
}
        
.chapter-list {
    width: 250px;
    left: -300px;
    position: fixed;
    background: #FFEFDF;
    padding: 15px;
    border: black 10px solid;
    transition: 0.5s;
    z-index: 2;
}

.chapter-list a {
    padding: 15px 25px;
    text-decoration: none;
    font-size: 18px;
    display: block;
    transition: 0.3s;
     
}
.video-container {
            display: none;
            margin: 20px 0;
             z-index: -1000;
        }
        
.close-btn {
    background-color: #af804f;
    position: flex;
    top: 10px;
    right: 10px;
    font-size: 30px;
    color: white;
}

.menu-open {
    left: 0px;
    
}   
#menuButton {
    position: fixed;
    top: 20px;
    left: 20px;
    font-size: 20px;
    z-index: 1;
    cursor: pointer;
    background: #333;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
}

        
.chapter-item {
    margin-bottom: 15px;
}
        
.chapter-title {
    padding: 8px;
    background: #af804f;
    color: white;
    cursor: pointer;
    font-weight: bold;
}
        
.image-links {
    list-style: none;
    padding: 0;
    margin-top: 5px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}
        
.chapter-open .image-links {
    max-height: 500px;
}

.image-links li {
    padding: 5px 0;
}
        
.image-links a {
    color: #333;
    text-decoration: none;
    display: block;
    padding: 5px 8px;
}
        
.image-links a:hover {
    background: #e0e0e0;
}
        
.image-links a.active {
    background: #846647;
    color: white;
}
.image-display {
    min-height: 400px;
    display:flex;
    align-items: center;
    justify-content: center;
    background: #000000;
    position: relative;
    overflow: hidden;
    border: none;
    margin-left: 50px;
    margin-right: 200px;
}
        
.image-display img {
    
    max-width: 100%;
    max-height: 80vh;
    display: block;
}
.image-display:not(:empty)  {
    border: black 10px solid;
}    
.nav-area {
    position: absolute;
    top: 0;
    height: 100%;
    width: 30%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255,255,255,0.5);
    font-size: 2em;
    user-select: none;
    transition: background 0.2s;
}
        
.nav-area.left {
    left: 0;
}
        
.nav-area.right {
    right: 0;
}
        
.nav-area:hover {
    background: rgba(0,0,0,0.1);
}
        
.image-info {
    margin-top: 10px;
    text-align: center;
    font-size: 18px;
}
        
.chapter-info {
    color: #666;
    margin-bottom: 5px;
}