Carousel-Menu 1.02

by velo_ninja

HTML

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Centered Div</title>
  <link rel="stylesheet" href="styles.css">
  
   <style>
      :root {--cell-font-color: black;} 
      body {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100vh;
        margin: 0;
      }
      .nav-button {
        padding: 0.3em;
        margin: auto;
        border: 1px solid var(--cell-font-color);
        border-radius: 5px;
        color: white;
        background: red;
        display: flex;
        align-items: center;
        justify-content: center; /* Horizontally center the content */
        text-align: center; /* Horizontally center the text within the button */
      }
      .carousel__cell {
        position: absolute;
        left: 10px;
        top: 10px;
        border: 2px solid var(--cell-font-color);
        line-height: 116px;
        font-size: 80px;
        font-weight: bold;
        color: var(--cell-font-color);
        text-align: center;
        transition: transform 1s, opacity 1s;
      }
      .carousel-options {
        text-align: center;
        position: relative;
        z-index: 2;      
      }
    </style>

    <style>
    /* Add the following styles */
      .radio-container {
        position: absolute;
        top: 50%; /* Center vertically */
        left: 50%; /* Center horizontally */
        transform: translate(-50%, -50%); /* Center both horizontally and vertically */
        background: white; /* Change the background color for visibility */
        padding: 10px; /* Add padding for better visibility */
      }
    </style>
    
    
    
   
    
    
    
    <script>  
      function create_carousel(carouselOptions, radioOptions) {
        let cellCount,selectedIndex=0,isHorizontal=true;
        //-------------------------------------
        const containerMS = create_mainStage();
      ...