* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  overflow: hidden;
  font-family: Arial, Helvetica, sans-serif;
}

.main {
  width: 100vw;
  height: 100vh;

  display: flex;
  justify-content: center;
  align-items: center;

  background: linear-gradient(135deg, #f8fafc, #dbeafe, #e0f2fe);

  transition: 1s;
}

.main:hover {
  background: linear-gradient(135deg, #0f172a, #1e293b, #111827);
}

.logo-container {
  width: 900px;
  height: 500px;
  position: relative;
}

.box {
  width: 140px;
  height: 140px;

  position: absolute;

  display: flex;
  justify-content: center;
  align-items: center;

  border-radius: 20px;

  color: white;
  font-size: 80px;
  font-weight: bold;

  border: 2px solid rgba(255, 255, 255, 0.15);

  backdrop-filter: blur(10px);

  transition: all 1.2s cubic-bezier(0.17, 0.67, 0.4, 1.39);

  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

/* Initial Positions */

.sub1 {
  background: #e42527;
  left: 120px;
  top: 180px;
}

.sub2 {
  background: #00a651;
  left: 280px;
  top: 180px;
}

.sub3 {
  background: #1f7ae0;
  left: 440px;
  top: 180px;
}

.sub4 {
  background: #f7c600;
  left: 600px;
  top: 180px;
}

/* Center Logo */

.sub5 {
  position: absolute;

  left: 50%;
  top: 50%;

  transform: translate(-50%, -50%) scale(0.2);

  opacity: 0;

  transition: 1.2s ease;
}

.sub5 img {
  width: 320px;
}

/* Hover Effects */

.main:hover .sub1 {
  transform: translate(-180px, -140px) rotate(-25deg) scale(0.8);

  filter: brightness(1.2);

  box-shadow: 0 30px 60px rgba(255, 0, 0, 0.5);
}

.main:hover .sub2 {
  transform: translate(450px, -140px) rotate(25deg) scale(0.8);

  filter: brightness(1.2);

  box-shadow: 0 30px 60px rgba(0, 255, 0, 0.5);
}

.main:hover .sub3{

    transform: translate(-450px,140px) rotate(25deg) scale(.8);

    filter:brightness(1.2);

    box-shadow: 0 30px 60px rgba(0,140,255,.5);
}

.main:hover .sub4 {
  transform: translate(180px, 140px) rotate(-25deg) scale(0.8);

  filter: brightness(1.2);

  box-shadow: 0 30px 60px rgba(255, 255, 0, 0.5);
}

.main:hover .sub5 {
  opacity: 1;

  transform: translate(-50%, -50%) scale(1);
}
