@import url("https://fonts.maateen.me/baloo-da-2/font.css");

:root {
  --base-color: #f7f5ff;
  --object-bg: #e8e9ed;
  --text-color: #1d1c1c;
  --secondary-text: #232738;
  --primary-color: #3a435d;
  --button-color: #594adf;
  --link-color: #1670ee;
  --abbr-color: #7d50bd;
  --sub-topic-color: #9368cf;
}

.darkmode {
  --base-bg: #19191b;
  --object-bg: #101425;
  --text-color: #ffffff;
  --secondary-text: #a4a5b8;
  --primary-color: #a8bdfd;
  --button-color: #6c3fbf;
  --link-color: #4fc3f7;
  --abbr-color: #b57cff;
  --sub-topic-color: #c6abec;
  transition: ease-in-out 0.1s;
}

#theme-switch {
  height: 50px;
  width: 50px;
  padding: 0;
  border-radius: 50%;
  background-color: var(--object-bg);
  display: flex;
  justify-content: center;
  align-items: center;
  position: fixed;
  left: 20px;
  top: 20px;
  cursor: pointer;
  animation: transition 0.3s ease-in-out;
  opacity: 0.4;
}

#theme-switch:hover {
  opacity: 1;
  transition: ease-in-out 0.3s;
}
#theme-switch:active {
  opacity: 0.8;
  transition: ease-in-out 0.1s;
}

@keyframes transition {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

#theme-switch svg {
  fill: var(--primary-color);
}

#theme-switch svg:last-child {
  display: none;
}

.darkmode #theme-switch svg:first-child {
  display: none;
}

.darkmode #theme-switch svg:last-child {
  display: block;
}

body {
  font-family: "Baloo Da 2", system-ui;
  background-color: var(--base-bg);
  color: var(--text-color);
  margin: 0;
  padding: 20px;
  line-height: 1.6;
  min-height: 100vh;
  transition: ease-in-out 0.1s;
  cursor: default;
}

h1 {
  font-size: 2em;
  margin-bottom: 20px;
  color: var(--abbr-color);
}

#heading {
  text-align: center;
}

h2 {
  font-size: 1.5em;
  margin-top: 20px;
  margin-bottom: 10px;
  color: var(--sub-topic-color);
}

li {
  font-weight: 500;
}

h3 {
  font-size: 1.3em;
  margin-top: 15px;
  color: var(--sub-topic-color);
}

h4 {
  font-size: 1.2em;
  margin-top: 15px;
  color: var(--sub-topic-color);
}

html,
body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

table {
  width: 90%;
  margin-top: 20px;
  font-weight: 500;
  align-self: center;
  justify-self: center;
  border-collapse: collapse;
}

button {
  background-color: var(--button-color);
  color: white;
  border: none;
  padding: 10px 20px;
  font-size: 20px;
  cursor: pointer;
  border-radius: 5px;
  text-align: center;
  margin: 0 auto;
  display: block;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  margin-top: 20px;
  margin-bottom: 20px;
  font-family: "Baloo Da 2", cursive;
  transition: background-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out,
    transform 0.3s ease-in-out;
}

button:hover {
  background-color: #21afe7;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.7);
  transform: translateY(-2px);
  transition: background-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out,
    transform 0.3s ease-in-out;
}

button:active {
  background-color: #21afe7;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  transform: translateY(2px);
  transition: background-color 0.1s ease-in-out, box-shadow 0.1s ease-in-out,
    transform 0.1s ease-in-out;
}

#rocketBtn {
  display: none;
  position: fixed;
  bottom: 40px;
  right: 40px;
  z-index: 999;
  background-color: transparent;
  border: none;
  cursor: pointer;
}

/* রকেট বাটন */
#rocketBtn {
  display: none;
  position: fixed;
  bottom: 25px;
  right: 10px;
  z-index: 999;
  width: 56px;
  height: 56px;
  background-color: var(--object-bg);
  border: none;
  border-radius: 50%;
  overflow: hidden;
  cursor: pointer;
  padding: 0;
  opacity: 0.4;
}

.darkmode #rocket svg {
  fill: #a8bdfd;
}

#rocket svg {
  fill: #a873f1;
}

/* বাটনের ভিতরের কন্টেন্ট */
.rocket-container {
  position: relative;
  width: 100%;
  height: 100%;
}

#rocket {
  font-size: 24px;
  bottom: 2px;
  position: absolute;
  left: 50%;

  transform: translateX(-50%);
  transition: transform 0.6s ease;
}

#flame {
  position: absolute;
  top: 60%;
  left: 50%;
  transform: translateX(-50%);
  width: 10px;
  height: 20px;
  background: orange;
  border-radius: 50%;
  opacity: 0;
}

/* ফ্লেম animation */
@keyframes flameAnim {
  0% {
    height: 10px;
    background: yellow;
    opacity: 0.6;
  }
  25% {
    height: 15px;
    background: #fae102;
    opacity: 0.8;
  }
  50% {
    height: 35px;
    background: orange;
    opacity: 1;
  }
  100% {
    height: 45px;
    background: red;
    opacity: 2;
  }
}

/* launching অবস্থায় রকেট ও ফ্লেম */
#rocketBtn.launching #rocket {
  transform: translate(-50%, -60px);
}

#rocketBtn.launching #flame {
  animation: flameAnim 0.4s infinite alternate;
  opacity: 1;
}

#rocketBtn.launching,
#rocketBtn:active,
#rocketBtn:hover {
  opacity: 1;
}
#rocketBtn:active #rocket {
  transform: translate(-50%, -50px);
}

a {
  color: var(--link-color);
  text-decoration: none;
}

.vb-link,
tr a {
  color: var(--link-color);
  text-decoration: underline;
}
th {
  color: var(--abbr-color);
}

abbr {
  text-decoration: none;
  color: var(--abbr-color);
}

.loader-parent {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10000;
  flex-direction: column;
  background-color: #03081a;
}

.loader-parent h3 {
  color: #eccc68;
  text-shadow: black 2px 2px px;
  font-size: 30px;
  font-family: monospace;
  text-align: center;
  margin-top: 20px;
  letter-spacing: 2px;
}

#loader {
  width: 100px;
  height: 100px;
  border: 10px solid #fcf9f9;
  border-radius: 50%;
  border-top-color: #223977;
  animation: rotate 1s infinite;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  background-color: transparent;
}

#loader-img {
  width: 100px;
  height: 100px;
  position: absolute;
  top: 42%;
  left: 50%;
  transform: translate(-50%, -47%);
}

@keyframes rotate {
  100% {
    rotate: 360deg;
  }
}

.info {
  font-size: 17px;
  color: var(--abbr-color);
  font-family: "Baloo Da 2", system-ui;
  text-align: center;
  margin-top: 20px;
  text-shadow: 0 1px 1px 5px rgba(0, 0, 0, 0.7);
  font-weight: bold;
}

.info a {
  color: var(--link-color);
  text-decoration: none;
  font-weight: bold;
}

/*Mobile*/
@media screen and (min-width: 220px) and (max-width: 600px) {
  img {
    width: 70vw;
    max-width: 300px;
    height: auto;
  }

  h1 {
    font-size: vw(8);
    margin-top: 15px;
  }

  h2 {
    font-size: vw(6);
  }

  p {
    font-size: vw(5);
  }

  .card {
    width: 90vw;
    height: auto;
    max-width: 320px;
    padding: 13px;
  }

  button {
    font-size: 18px;
    padding: 10px 20px;
  }

  #theme-switch {
    width: 45px;
    height: 45px;
    top: -10px;
    right: 5px;
    left: auto;
  }

  #rocketBtn {
    width: 45px;
    height: 45px;
    bottom: 10px;
    right: 10px;
  }
  #rocket {
    bottom: -2px;
  }
  table {
    width: 98%;
  }
}

/*Tablet*/
@media screen and (min-width: 600px) and (max-width: 1024px) {
  img {
    width: 80vw;
    max-width: 300px;
    height: auto;
  }

  h1 {
    font-size: vw(9);
    margin-top: 16px;
  }

  h2 {
    font-size: vw(7);
  }

  p {
    font-size: vw(5.5);
  }

  li {
    font-size: 18px;
  }

  .card {
    width: 90vw;
    height: auto;
    max-width: 400px;
    padding: 15px;
  }

  button {
    font-size: 20px;
    padding: 12px 24px;
  }

  #theme-switch {
    height: 50px;
    width: 50px;
    top: 20px;
    right: 20px;
    left: auto;
  }
  #rocketBtn {
    height: 50px;
    width: 50px;
    bottom: 20px;
    right: 20px;
  }

  #loader-img {
    width: 100px;
    height: 100px;
    position: absolute;
    top: 42%;
    left: 50%;
    transform: translate(-50%, -33%);
  }
}

@media screen and (min-width: 20000px) {
  body {
    margin-top: 70px;
  }

  #theme-switch {
    height: 50px;
    width: 50px;
    top: 20px;
    right: 20px;
  }

  #loader-img {
    width: 100px;
    height: 100px;
    position: absolute;
    top: 42%;
    left: 50%;
    transform: translate(-50%, -50%);
  }
}

@media screen and (min-width: 1024px) {
  li {
    font-size: 20px;
  }

  th {
    font-size: 18px;
  }

  td {
    font-size: 17px;
  }
}
