body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background-color: rgb(247, 237, 251);
  padding-top: 56px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1030;
}

.navbar-brand {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-weight: bold;
  font-size: 1.5rem;
  color: #0d6efd;
}

.school-logo {
  height: 50px;
  margin-right: 10px;
}

.sidebar {
  height: calc(100vh - 56px);
  width: 250px;
  position: fixed;
  top: 56px;
  right: -250px;
  background-color: mediumorchid;
  padding-top: 20px;
  transition: right 0.3s ease-in-out;
  z-index: 1020;
  overflow-y: auto;
}

.sidebar.active {
  right: 0;
}

.sidebar a {
  padding: 12px 25px;
  text-decoration: none;
  font-size: 1.1rem;
  color: #f8f9fa;
  display: block;
  transition: 0.3s;
  border-bottom: 1px solid #495057;
}

.sidebar a:hover {
  background-color: rgb(255, 255, 255);
  color: rgba(50, 0, 150, 0.8);
}

.sidebar a i {
  width: 25px;
  text-align: center;
  margin-right: 10px;
  font-weight: bold;
}

.sidebar-toggle {
  position: fixed;
  top: 68px;
  right: 20px;
  z-index: 1040;
  font-size: 1.5rem;
  cursor: pointer;
  background-color: #0d6efd;
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.sidebar-toggle:hover {
  background-color: #0b5ed7;
}

.main-content {
  transition: margin-right 0.3s ease-in-out;
  flex: 1;
}

.main-content.sidebar-open {
  margin-right: 250px;
}

.welcome-section {
  background-color: white;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 15px 5px 5px 5px;
  margin-top: 10px;
  margin-bottom: 10px;
}

.scrolling-text {
  background-color: #f8f9fa;
  padding: 15px;
  border-left: 4px solid #0d6efd;
  margin-top: 20px;
  font-style: italic;
  overflow: hidden;
}

.carousel-item img {
  height: 400px;
  object-fit: cover;
}

.carousel-caption {
  background-color: rgba(0, 0, 0, 0.6);
  border-radius: 5px;
  padding: 10px;
  bottom: 20px;
}

/* Always show captions on mobile */
.carousel-caption {
  display: block !important;
}

footer {
  color: white;
  padding: 5px 0;
  margin-top: 30px;
}

@media (max-width: 768px) {
  .main-content.sidebar-open {
    margin-right: 0;
  }

  .sidebar {
    width: 100%;
    right: -100%;
  }

  .sidebar.active {
    right: 0;
  }

  .carousel-item img {
    height: 300px;
  }

  .carousel-caption {
    bottom: 10px;
    padding: 5px;
  }

  .carousel-caption h5 {
    font-size: 1rem;
  }

  .carousel-caption p {
    font-size: 0.8rem;
    padding-bottom: 1px !important;
  }
}
