/* General Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

hr {
  margin: 10px;
}

/* Typography */
p {
  font-family: Verdana, Geneva, sans-serif;
  font-size: 20px;
  color: #424249;
}

a {
  color: blue;
  text-decoration: none;
  cursor: pointer;
}

/* Selection Styles */
::-moz-selection {
  color: red;
  background: #ffffc7;
}

::selection {
  color: red;
  background: #ffffc7;
}

/* Form Elements */
textarea:focus,
input:focus,
select:focus {
  box-shadow: none;
  border: none;
  outline: none;
}

.btn-text-top {
  background-color: white;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding-left: 10px;
  padding-right: 30px;
  border-radius: 20px;
  width: 205px;
  height: 30px;
  font-size: 15px;
  color: #424249;
}

.btn-buscar-top {
  width: 20px;
  height: 22px;
  background: url(/storage/img/buscar_grey.png) no-repeat;
  cursor: pointer;
  border: none;
  transform: translateY(-50%);
  position: relative;
  top: -15px;
  left: 178px;
  z-index: 9999;
}

/* Font Size Buttons */
button[name="decrease-font"],
button[name="increase-font"],
button[name="version"] {
  width: 35px;
  /* font-size: 14px; */
  /* cursor: pointer; */
}

/* No Select */
.noSelect {
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -khtml-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

/* Layout */
#box {
  display: flex;
}

#sidebar {
  background-color: #f2f2f2;
  width: 222px;
  height: 100vh;
  position: fixed;
  padding: 10px;
  top: 0;
}

#b {
  flex-grow: 1;
  padding-left: 225px;
  /* Adjusted for sidebar width + padding */
  padding-bottom: 50px;
  min-height: 100vh;
}

#livros {
  overflow: auto;
  height: 80%;
  font-size: 19px;
}

#Caps {
  background-color: #f2f2f2;
  position: fixed;
  top: 0;
  padding: 12px 30px;
  font-size: 1.3em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: calc(100% - 232px);
  /* Adjusted for sidebar */
}

#Caps:hover {
  overflow: visible;
  white-space: normal;
}

#Text {
  background-color: white;
  padding: 110px 30px 20px;
  width: 100%;
  text-align: justify;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.4);
  padding-top: 100px;
}

.modal-content {
  background-color: #fefefe;
  margin: auto;
  padding: 20px;
  border: 1px solid #888;
  width: 80%;
  max-width: 600px;
}

.close {  
  color: #555555;
  float: right;
  font-size: 30px;
  font-weight: bold;
}

.close:hover,
.close:focus {
  color: #000;
  text-decoration: none;
  cursor: pointer;
}

/* Interlinear */
#interlinear {
  font-family: Verdana, Geneva, sans-serif;
  display: none;
  width: 400px;
  /* Fixed width for sidebar */
  height: 100vh;
  position: fixed;
  z-index: 1000;
  top: 0;
  right: 0;
  /* Position on the right */
  overflow-y: auto;
  /* Scrollable content */
  transition: transform 0.3s ease-in-out;
  color: #000;
  padding: 20px;
  background: #f0e68c;
  font-size: 18px;
  opacity: 0.97;
  box-shadow: -2px 0 5px rgba(0, 0, 0, 0.2);
}

#interlinear.show {
  display: block;
  transform: translateX(0);
}

#interlinear .close {
  color: #000000;
  font-size: 30px;
  font-weight: bold;
  cursor: pointer;
  /* position: fixed; */
  top: 10px;
  right: 10px;
}

#interlinear .close:hover,
#interlinear .close:focus {
  color: #000;
}

#interlinear h3 {
  margin-bottom: 15px;
  font-size: 20px;
}

#interlinear p {
  margin: 10px 0;
  font-size: 16px;
}

#interlinear .version-title {
  font-weight: bold;
  color: #424249;
}


/* Responsive Design */
@media (max-width: 768px) {
  /* #sidebar {
    width: 100%;
    height: auto;
    position: static;
  } */


  /* Adjust main content to avoid overlap */
  /* #b {
    flex-grow: 1;
    padding-right: 20px;
    padding-bottom: 50px;
    min-height: 100vh;
  }

  #Caps {
    width: 100%;
    padding: 12px 20px;
  } */

  #Text {
    padding: 110px 20px 20px;
  }

  #interlinear {
    font-family: Verdana, Geneva, sans-serif;
    display: none;
    height: 100%;
    width: 100%;
    position: fixed;
    z-index: 1;
    top: 0;
    left: 0;
    overflow-x: hidden;
    transition: 0.5s;
    color: #000;
    padding: 20px;
    background: #f0e68c;
    font-size: 20px;
    opacity: 0.97;
  }

}

.pointer {
  cursor: pointer;
}

.sticky-header{
  position: sticky;
  top: -20;
  background: #f0e68c;
  padding-bottom: 10px;
  padding-top: 5px;
  z-index: 10;
}