.main-container {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  padding: 20px;
  gap: 20px;
  box-sizing: border-box;
  width: 100%;
  flex-wrap: wrap;
}

/* Notice Board */
.notice-board {
  width: 350px;
  /*flex: 0 0 25%;*/
  height: 500px;
  /*border: 2px solid #ccc;*/
  /*border-radius: 8px;*/
  background-color: #fff;
  overflow: hidden;
  font-family: Arial, sans-serif;
}

.notice-board h2 {
  margin: 0;
  text-align: center;
  height: 50px;
  line-height: 50px;
  width: 100%;
  background-color: #1c7ec0;
  color: white;
  font-size: 20px;
  border-bottom: 2px solid #000000;
  position: relative;
  z-index: 2; 
}

.notices-wrapper {
  height: 450px;
  overflow: hidden;
  
}

.notices {
  display: flex;
  flex-direction: column;
  gap: 15px;
  animation: scrollUp 30s linear infinite;
  padding: 12px;
}

.notice-board:hover .notices {
  animation-play-state: paused;
}

.notices a {
  color: #0066cc;
  text-decoration: none;
  font-size: 16px;
  text-align: justify;
}

.notices a:hover {
  text-decoration: underline;
}

@keyframes scrollUp {
  0% { transform: translateY(100%); }
  100% { transform: translateY(-100%); }
}

/* Info Container */
.info-container {
  flex: 1;
  position: relative;
  padding: 20px;
  background: rgba(138, 138, 138, 0.05);
  backdrop-filter: blur(4px);
  /*border-radius: 8px;*/
  overflow: hidden;
  height: 500px;
  box-sizing: border-box;
}

.info-container::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../Image/powergrid2.jpg');
  background-size: cover;
  background-position: center;
  opacity: 0.2;
  z-index: 0;
}

.text-section {
  position: relative;
  z-index: 1;
  color: #333;
  padding: 20px;
  background-color: rgba(255, 255, 255, 0.6);
  border-radius: 8px;
  height: 100%;
  overflow-y: auto;
  line-height: 1.6;
}

.text-section h2 {
  text-align: center;
  margin-bottom: 20px;
}

/* Rightbox */
.rightbox {
  flex: 0 0 20%;
  background-color: #1c7ec0;
  text-align: center;
  font-weight: bold;
  color: white;
  height: 500px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.rightbox div:first-child {
  margin-top: 20px;
}

.rightbox img {
  width: 100%;
  height: 360px;
  object-fit: fill;
}

.rightbox div:last-child {
  margin-bottom: 20px;
}

/* Responsive layout */
@media screen and (max-width: 1024px) {
  .main-container {
    flex-direction: column;
  }

  .notice-board,
  .rightbox {
    width: 100%;
    height: auto;
  }

  .info-container {
    width: 100%;
    height: auto;
  }

  .text-section {
    height: auto;
  }
}