@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@400;700;900&display=swap");

body {
  position: relative;
  z-index: 0;
  font-family: "Roboto", sans-serif;
  background-color: #000000;
  color: white;
}

header {
  background-color: #080808;
  color: white;
}

#tsparticles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
}

img,
h1,
p,
a {
  position: relative;
  z-index: 1000;
}

::selection {
  background: #ffffff91 !important;
  color: #ffff !important;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 60px;

  background: rgba(0, 0, 0, 0.5);

  backdrop-filter: blur(10px);
  /* fallback for old browsers */
  -webkit-backdrop-filter: blur(10px);

  outline: 1px solid rgba(255, 255, 255, 0.075);

  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;

  z-index: 9999;

  transition: transform 0.3s ease;
}

.header.hidden {
  transform: translateY(-100%);
}

.cards-container {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  align-items: stretch;
  width: 100%;
  box-sizing: border-box;
  padding: 0 30px;
}

.card {
  min-width: 0;
  box-sizing: border-box;
  padding: 25px;
  margin: 0;

  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.089);

  background: rgba(32, 32, 32, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 0 80px rgba(0, 0, 0, 0.3);
}

.card a {
  color: inherit;
  text-decoration: none;
}

.card h1 {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 0;
  font-size: 24px;
  overflow-wrap: anywhere;
}

.card img {
  width: 70px;
  height: 70px;
  flex-shrink: 0;
  object-fit: contain;
}

@media (max-width: 1200px) {
  .cards-container {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .cards-container {
    grid-template-columns: 1fr;
  }
}

a {
  color: white;
  transition: color 0.3s ease;
}

a:hover {
  color: #b9b9b9;
}
/* Mobile-responsive Changes */
.header-image {
  display: block;
  margin: 60px auto 0;
  max-width: 90%;
  height: auto;
}

.icon-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px 40px;
  margin-top: 20px;
}

.icon-row img {
  width: 60px;
  height: auto;
  margin: 0 !important;
}

.icon-row-social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px 24px;
  margin-top: 20px;
}

.icon-row-social img {
  width: 35px;
  height: auto;
  margin: 0 !important;
}

.section-title {
  margin-top: 80px;
  text-align: center;
  color: white;
}

@media (min-width: 768px) {
  .header-image {
    margin-top: 250px;
    max-width: 400px;
  }
  .icon-row-social {
    margin-top: 40px;
  }
  .icon-row-social img {
    width: 50px;
  }
  .icon-row {
    margin-top: 50px;
    gap: 10px 40px;
  }
  .icon-row img {
    width: 90px;
  }
  .section-title {
    margin-top: 430px;
  }
}

button {
  width: 200px;
  height: 40px;
  border-radius: 8px;
  background-color: white;
  color: white;
  border: none;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.075);

  background: rgba(32, 32, 32, 0.1);
  backdrop-filter: blur(10px);
  /* fallback for old browsers */
  -webkit-backdrop-filter: blur(10px);
  border: 0.5px solid rgba(255, 255, 255, 0.089);
  transition: all 0.3s ease;
}

button:hover {
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.back-btn {
  display: inline-block;
  margin-bottom: 30px;
  margin-top: 30px;
  margin-left: 30px;
  width: 30px;
  height: 30px;
}

.back-btn img {
  width: 30px;
  height: 30px;
  display: block;
}

input {
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  width: 160px;
  height: 15px;
  color: white;
  background-color: transparent;
  border-radius: 8px;
  background: rgba(32, 32, 32, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.075);
  backdrop-filter: blur(10px);
  /* fallback for old browsers */
  -webkit-backdrop-filter: blur(10px);
  border: 0.5px solid rgba(255, 255, 255, 0.089);
}

input:hover {
  border: 1px solid rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
}

::placeholder {
  color: white;
}

.wallpaper-grid {
  max-width: 1200px;
  margin: 0 auto;

  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 25px;
}

.wallpaper-grid a {
  display: block;
  overflow: hidden;
  border-radius: 14px;
  line-height: 0;
}

.wallpaper-grid img {
  width: 100%;
  height: auto;
  display: block;
}

@media (max-width: 800px) {
  .wallpaper-grid {
    grid-template-columns: 1fr;
  }
}

#qrcode {
  width: 256px;
  height: 256px;
  margin: 10px auto 0;
}

@media (max-width: 767px) {
  .hero {
    min-height: calc(100svh - 90px);
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0 15px;
    transform: translateY(-60px);
  }

  .header-image {
    margin: 0;
    max-width: 85%;
  }

  .icon-row-social {
    margin-top: 30px;
  }

  .mobile-section {
    min-height: 100svh;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 30px 15px;
  }

  .section-title {
    margin: 0 0 35px;
    font-size: 1.6rem;
  }

  .icon-row {
    margin-top: 0;
    gap: 25px;
  }

  .icon-row img {
    width: 55px;
  }
}

.copyright {
  color: white;
  text-align: center;
  margin-top: 480px;
}

@media (max-width: 767px) {
  .copyright {
    margin-top: 40px;
    margin-bottom: 20px;
    padding: 0 15px;
  }
}

@media (max-width: 767px) {
  .header {
    justify-content: flex-start;
    gap: 24px;
    padding: 0 20px;
    box-sizing: border-box;
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    scrollbar-width: none;
  }

  .header::-webkit-scrollbar {
    display: none;
  }

  .header a {
    flex-shrink: 0;
    font-size: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
  }
}

/* Projects page */
.projects-page {
  padding: 60px 30px 30px;
  box-sizing: border-box;
}

.projects-heading {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 10px 0 40px;
  min-height: 50px;
}

.projects-heading h1 {
  color: white;
  text-align: center;
  font-size: 42px;
  font-weight: 900;
  margin: 0;
}

.projects-heading .back-btn {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  margin: 0;
}

.projects-heading .back-btn img {
  width: 30px;
  height: 30px;
}

.projects-page .cards-container {
  padding: 0;
}

@media (max-width: 767px) {
  .projects-page {
    padding: 76px 16px 24px;
  }

  .projects-heading {
    margin: 8px 0 28px;
    min-height: 44px;
  }

  .projects-heading h1 {
    font-size: 42px;
  }

  .projects-heading .back-btn {
    left: 0;
    width: 30px;
    height: 30px;
  }

  .projects-page .cards-container {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .projects-page .card {
    padding: 18px;
    border-radius: 5px;
  }

  .projects-page .card h1 {
    gap: 16px;
    font-size: clamp(18px, 5vw, 22px);
    overflow-wrap: anywhere;
  }

  .projects-page .card img {
    width: 48px;
    height: 48px;
    object-fit: contain;
  }
}

@media (max-width: 360px) {
  .projects-page {
    padding-right: 12px;
    padding-left: 12px;
  }

  .projects-page .card {
    padding: 14px;
  }

  .projects-page .card h1 {
    gap: 12px;
    font-size: 18px;
  }

  .projects-page .card img {
    width: 42px;
    height: 42px;
  }
}

.wallpaper-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 10px 0 40px;
}

.wallpaper-header h1 {
  color: white;
  font-size: 42px;
  font-weight: 900;
  text-align: center;
  margin: 0;
}

.wallpaper-back {
  position: absolute;
  left: 30px;
  top: 50%;
  transform: translateY(-50%);
  display: block;
  width: 30px;
  height: 30px;
}

.wallpaper-back img {
  display: block;
  width: 30px;
  height: 30px;
}

@media (max-width: 767px) {
  .wallpaper-back {
    left: 16px;
  }
}

/* Binary Converter –  Mobile */
@media (max-width: 767px) {
  .converter-page {
    margin: 0;
  }

  .converter-page .back-btn {
    position: absolute;
    top: 33px;
    left: 16px;
    margin: 0;
    z-index: 10000;
  }

  .converter-page .converter {
    margin-left: 0 !important;
    padding: 30px 16px 24px;
    box-sizing: border-box;
  }

  .converter-page .converter-title {
    display: flex;
    align-items: center;
    height: 36px;
    margin: 0 0 28px;
    padding-left: 46px;
    font-size: 26px;
    font-weight: 900;
    line-height: 1;
  }

  .converter-page .converter-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 0 !important;
    margin-bottom: 20px;
  }

  .converter-page .converter-form input {
    width: 100%;
    height: 20px;
    box-sizing: content-box;
    max-width: calc(100% - 26px);
    font-size: 16px;
  }

  .converter-page .converter-form button {
    width: 100%;
    height: 44px;
    margin-left: 0 !important;
    font-size: 16px;
  }

  .converter-page .converter h2 {
    font-size: 20px;
    margin: 24px 0 10px;
  }

  .converter-page #output {
    overflow-wrap: anywhere;
    word-break: break-all;
    line-height: 1.5;
  }
}

@media (max-width: 767px) {
  body.guess-page {
    margin: 0 !important;
    padding: 0 !important;
  }

  body.guess-page .back-btn {
    position: absolute !important;
    top: 33px !important;
    left: 16px !important;
    margin: 0 !important;
    z-index: 10000 !important;
  }

  body.guess-page .container {
    padding: 30px 16px 24px !important;
    box-sizing: border-box;
  }

  body.guess-page #headline {
    margin: 0 0 20px !important;
    padding-left: 46px !important;
    font-size: 22px !important;
    font-weight: 900;
    line-height: 36px !important;
    pointer-events: none;
    overflow-wrap: anywhere;
  }

  body.guess-page #displayTries {
    font-size: 20px !important;
    margin: 0 0 20px !important;
  }

  body.guess-page form {
    display: flex !important;
    flex-direction: column;
    gap: 10px;
  }

  body.guess-page #input {
    width: 100% !important;
    height: 44px !important;
    box-sizing: border-box !important;
    font-size: 16px !important;
  }

  body.guess-page form button {
    width: 100% !important;
    height: 44px !important;
    margin-left: 0 !important;
    font-size: 16px !important;
  }
}

@media (max-width: 767px) {
  body.qr-page {
    margin: 0 !important;
    padding: 0 !important;
  }

  body.qr-page .back-btn {
    position: absolute !important;
    top: 33px !important;
    left: 16px !important;
    margin: 0 !important;
    z-index: 10000 !important;
  }

  body.qr-page .qr-container {
    margin-top: 0 !important;
    padding: 80px 16px 24px !important;
    box-sizing: border-box;
  }

  body.qr-page > #qrcode {
    display: none !important;
  }

  body.qr-page #qrcode {
    width: 100% !important;
    max-width: 180px;
    height: auto !important;
    margin: 0 auto !important;
  }

  body.qr-page #qrcode img,
  body.qr-page #qrcode canvas {
    width: 100% !important;
    height: auto !important;
  }

  body.qr-page #qrInput {
    width: 100% !important;
    height: 44px !important;
    box-sizing: border-box !important;
    margin: 16px 0 !important;
    font-size: 16px !important;
  }

  body.qr-page #genBtn {
    width: 100% !important;
    height: 44px !important;
    margin: 0 !important;
    font-size: 16px !important;
  }
}

@media (max-width: 767px) {
  body.privacy-page {
    margin: 0 !important;
    padding: 30px 16px 24px !important;
    box-sizing: border-box;
  }

  body.privacy-page .back-btn {
    position: absolute !important;
    top: 33px !important;
    left: 16px !important;
    margin: 0 !important;
    z-index: 10000 !important;
  }

  body.privacy-page h1 {
    margin: 0 0 20px !important;
    padding-left: 46px !important;
    font-size: 26px !important;
    font-weight: 900;
    line-height: 36px !important;
    pointer-events: none;
    overflow-wrap: anywhere;
  }

  body.privacy-page p {
    font-size: 16px;
    line-height: 1.6;
    overflow-wrap: anywhere;
  }
}

@media (max-width: 767px) {
  body.fire-page {
    margin: 0 !important;
    padding: 30px 16px 24px !important;
    box-sizing: border-box;
  }

  body.fire-page .back-btn {
    position: absolute !important;
    top: 33px !important;
    left: 16px !important;
    margin: 0 !important;
    z-index: 10000 !important;
  }

  body.fire-page #headline {
    margin: 0 0 20px !important;
    padding-left: 46px !important;
    font-size: 26px !important;
    font-weight: 900;
    line-height: 36px !important;
    pointer-events: none;
    overflow-wrap: anywhere;
  }

  body.fire-page form {
    display: flex !important;
    flex-direction: column;
    gap: 10px;
  }

  body.fire-page #input {
    width: 100% !important;
    height: 44px !important;
    box-sizing: border-box !important;
    font-size: 16px !important;
  }

  body.fire-page form button {
    width: 100% !important;
    height: 44px !important;
    margin-left: 0 !important;
    font-size: 16px !important;
  }
}
