body {
  background-color: #1a1a1a;
  color: white;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  margin: 0;
  padding: 0;
}

.topnav {
  background-color: #333;
  overflow: hidden;
  position: sticky;
  top: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  padding: 0 20px;
  height: 60px;
}

.logonav {
  margin-right: auto;
  display: flex;
  align-items: center;
}

.logonav img {
  height: 50px;
  width: 70px;
  object-fit: cover;
}

.topnav a {
  color: #f2f2f2;
  text-align: center;
  padding: 14px 16px;
  text-decoration: none;
  font-size: 17px;
  transition: 0.3s;
}

.topnav a:hover {
  background-color: #ddd;
  color: black;
}


.algtitle {
  margin-top: 60px;
  text-align: center; 
}

.algsubtitle {
  text-align: center;
  font-size: large;
  margin-bottom: 40px;
}

.container {
  display: flex;
  justify-content: center;
  min-height: 80vh;
  background-color: #1a1a1a;
  padding: 20px;
}

.solve-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr); 
  gap: 40px;
  max-width: 1100px;
  width: 100%;
}

.solve-card {
  text-decoration: none;
  background-color: rgba(255, 255, 255, 0.05);
  padding: 35px;
  border-radius: 25px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  text-align: center;
}

.solve-card:hover {
  background-color: rgba(255, 255, 255, 0.08);
  transform: translateY(-15px);
  border-color: #ffda00;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
}

.cube-grid {
  margin-bottom: 25px;
  width: 100%;
}

.cube-grid img {
  width: 25%;
  max-width: 250px;
  height: auto;
  border-radius: 15px;
  transition: transform 0.4s ease;
}

.solve-card:hover img {
  transform: scale(1.05);
}

.centered {
  font-size: 2.2rem;
  font-weight: bold;
  color: #fff;
  display: block;
  transition: color 0.3s ease;
}

.solve-card:hover .centered {
  color: #ffda00;
}


.site-footer {
  background-color: #111;
  color: #ccc;
  padding: 60px 20px 20px;
  border-top: 1px solid #333;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
  flex-wrap: wrap;
  gap: 40px;
}

.footer-section {
  flex: 1;
  min-width: 200px;
}

.footer-logo {
  height: 50px;
  margin-bottom: 15px;
}

.footer-section h4 {
  color: white;
  text-transform: uppercase;
  margin-bottom: 20px;
  font-size: 1rem;
}

.footer-section ul {
  list-style: none;
  padding: 0;
}

.footer-section ul li {
  margin-bottom: 10px;
}

.footer-section a {
  color: #999;
  text-decoration: none;
  transition: color 0.3s;
}

.footer-section a:hover {
  color: white;
}

.footer-bottom {
  text-align: center;
  margin-top: 50px;
  padding-top: 20px;
  border-top: 1px solid #222;
  font-size: 0.85rem;
}

@media (max-width: 768px) {
  .solve-grid {
    grid-template-columns: 1fr;
  }
  
  .algtitle, .algsubtitle {
    margin-left: 0; 
  }
}

.home-button-container {
        text-align: center;
        margin: 40px 0;
      }

      .home-button {
        display: inline-block;
        padding: 12px 24px;
        background-color: #0077ff;
        color: #fff;
        text-decoration: none;
        border-radius: 6px;
        font-size: 1.2rem;
        font-weight: 600;
        transition: background-color 0.2s ease;
      }

      .home-button:hover,
      .home-button:focus {
        background-color: #005fcc;
      }
