#gameCanvas {
    position: relative;
    border: 1px solid black;
    display: block;
    z-index: 0;
}

#answerWrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#modalP {
    display: none;
}

.training-toggle {
    display: flex;
    align-items: center;   /* vertical centering */
    justify-content: flex-start; /* left-align inside parent */
    gap: 8px;              /* spacing between items */
}

#projectTableDiv {
    display: flex;
    flex-direction: column;
    align-items: flex-start; /* left-align children */
}

body.mobile #projectTableDiv {
    margin-top: 50px;
    padding-bottom: 50px;
}

body.mobile #fileTable {
    font-size: 1rem;
}

body.mobile #fileTable td{
    padding: 10px 0;
}

#fileTable th, td {
    padding: 2px 5px;
}

.tableHeadProjects {
    padding: 5px;
    text-align: left;
    border: none;
    border-bottom: 1px solid #000;
    position: sticky;
    top: 0;
    background-color: #f2f2f2;
}

#routeButtonTable thead tr th, thead tr td {
    text-align: center;
}

table {
    font-family: Arial, sans-serif;
}

#resultBoxWrapper {
    display: flex;
    font-weight: bold;
    align-items: center;
    justify-content: space-between;
    background-color: white;
}

#resultBox {
    font-family: Arial, Helvetica, sans-serif;
    flex-grow: 1;
    text-align: left;
    margin-left: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 80%;
    background-color: transparent;
    justify-content: center;
}

#routeButtonContainer {
    text-align: center;
}

#startButtonContainer {
    display: flex;
    justify-content: center;
    width: 100%;
}

#divH {
    right: 0;
    top: 0;
}

#gameContainer {
    margin: 0;
    padding: 0;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#nextButton {
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
    display: none;
    text-align: center;
    padding: 5px;
    justify-content: center;
    align-items: center;
    padding: 0 10px;
}

#trainingButton {
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
    display: none;
    text-align: center;
    padding: 5px;
    justify-content: center;
    align-items: center;
    padding: 0 10px;
}

#nextButton:hover {
    background-color: #afafaf;
}

#openButton {
    top: 0px;
    left: 0px;
}

body.mobile #openButton {
    font-size: 1.5rem;
}

#startButton {
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
    text-align: center;
    justify-content: center;
    align-items: center;
    padding: 0 10px;
}
#startButton:hover {
    background-color: #afafaf;
}

.buttonMain {
    border: 2px solid black;
    padding: 8px;
    font-weight: bold;
    text-align: center;
    background-color: white;
    cursor: pointer;
    border-radius: 5px;
    padding: 3px;
    background-color: #f2f2f2;
    position: absolute;
    margin: 5px;
    z-index: 1;
}

/* Rounded sliders */
.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

.switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

.switch input { 
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  -webkit-transition: .4s;
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  -webkit-transition: .4s;
  transition: .4s;
}

input:checked + .slider {
  background-color: #2196F3;
}

input:focus + .slider {
  box-shadow: 0 0 1px #2196F3;
}

input:checked + .slider:before {
  -webkit-transform: translateX(26px);
  -ms-transform: translateX(26px);
  transform: translateX(26px);
}

.tooltip {
  position: relative; 
  display: inline-block; /* keep it inline with the icon */
}

.tooltip .tooltiptext {
  visibility: hidden;
  width: 300px;
  background-color: #333;
  color: #fff;
  text-align: left;
  border-radius: 6px;
  padding: 6px;
  position: absolute;
  z-index: 12;

  /* Position above the icon */
  top: 100%;
  left: 100%;

  opacity: 0;
  transition: opacity 0.2s;
}

.tooltip:hover .tooltiptext {
  visibility: visible;
  opacity: 1;
}
