* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  min-height: 100%;
  width: 100%;
}

/* Loading Screen Styles */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #040a14 0%, #0b1220 50%, #070a12 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.3s ease-out, visibility 0.3s ease-out;
  visibility: visible;
  opacity: 1;
}

.loading-screen.hidden {
  visibility: hidden;
  opacity: 0;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(107, 182, 255, 0.3);
  border-top: 3px solid rgba(107, 182, 255, 0.8);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-bottom: 20px;
}

.loading-screen p {
  color: rgba(243, 247, 255, 0.8);
  font-family: "Space Mono", monospace;
  font-size: 14px;
  letter-spacing: 2px;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

body {
  background-color: #e1e2dd;
  text-align: center;
  font-family: "Space Mono", monospace;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px 12px calc(18px + env(safe-area-inset-bottom));
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  width: 100dvw;
  height: 100vh;
  height: 100dvh;
  background-image: linear-gradient(rgba(4, 10, 20, 0.6), rgba(4, 10, 20, 0.6)), url("asset/images/bg.jpg");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  z-index: -1;
}

.container {
  margin: 0;
  width: 100%;
  max-width: 520px;
  padding: 20px 28px;
  position: relative;
  z-index: 1;
  background-color: rgba(0, 0, 0, 0.32);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 18px;
}

.profile {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 3px solid #d5d9e3;
  margin: 20px auto;
  object-fit: cover;
}

.user-name {
  font-family: "Space Mono", monospace;
  font-size: 30px;
  margin: 10px 0;
  color: #f4f7ff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.7);
}

.description {
  color: #e6eaf5;
  margin-bottom: 20px;
}

.links {
  margin: 20px 0;
}

.link {
  background-color: rgba(248, 251, 255, 0.92);
  color: #283041;
  display: block;
  padding: 15px;
  margin: 10px 0;
  border: 2px solid rgba(255, 255, 255, 0.55);
  border-radius: 20px;
  text-decoration: none;
  transition: background-color 0.3s, color 0.3s;
}

.link:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #f4f7ff;
  border-color: rgba(255, 255, 255, 0.35);
}

.shake {
  animation: shake-animation 4.72s ease infinite;
  transform-origin: 50% 50%;
}

@keyframes shake-animation {
  0% {
    transform: translate(0, 0) rotate(0deg);
  }
  2% {
    transform: translate(1px, -1px) rotate(-1deg);
  }
  4% {
    transform: translate(-1px, 1px) rotate(1deg);
  }
  6% {
    transform: translate(1px, 1px) rotate(0deg);
  }
  8% {
    transform: translate(-1px, -1px) rotate(1deg);
  }
  10% {
    transform: translate(0, 0) rotate(0deg);
  }
  100% {
    transform: translate(0, 0) rotate(0deg);
  }
}

.footer-text {
  color: #e8ecf7;
  margin: 15px 0;
  font-family: "Space Mono", monospace;
}

.footer-text a {
  color: #ffffff;
  text-decoration: none;
}

.social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin: 20px 0;
}

.social a {
  padding: 10px;
  font-size: 30px;
  margin: 0;
  color: #f3f6ff;
  text-decoration: none;
}

.social a:hover {
  opacity: 0.7;
}

#contact-form {
  margin: 20px 0;
}

#contact-form input,
#contact-form textarea {
  width: 100%;
  padding: 10px;
  margin: 10px 0;
  border: 2px solid #c7ab96;
  border-radius: 5px;
}

#contact-form input[type="submit"] {
  background-color: #fffbf4;
  border: none;
  cursor: pointer;
  border-radius: 20px;
  transition: background-color 0.3s;
}

#contact-form input[type="submit"]:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #f4f7ff;
}

.reach-out-btn {
  display: inline-block;
  text-decoration: none;
  background-color: #263046;
  color: #f3f6ff;
  padding: 12px 30px;
  margin: 15px 0;
  border: 2px solid #b7c4df;
  border-radius: 20px;
  font-size: 16px;
  font-family: "Gill Sans", sans-serif;
  cursor: pointer;
  transition: background-color 0.3s, color 0.3s;
}

.reach-out-btn:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #f4f7ff;
  border-color: rgba(255, 255, 255, 0.35);
}

@media (max-width: 768px) {
  body {
    align-items: flex-start;
    min-height: 100dvh;
    padding: 12px 10px calc(14px + env(safe-area-inset-bottom));
  }

  .container {
    max-width: 100%;
    padding: 16px 14px;
    border-radius: 16px;
  }

  .user-name {
    font-size: 26px;
    line-height: 1.2;
  }

  .description {
    font-size: 15px;
    margin-bottom: 12px;
  }

  .links {
    margin: 14px 0;
  }

  .link {
    padding: 12px;
    margin: 7px 0;
  }

  .reach-out-btn {
    width: 100%;
    padding: 12px 14px;
    margin: 12px 0;
  }

  .social {
    margin: 14px 0;
  }

  .social a {
    font-size: 25px;
    padding: 6px;
  }

  .footer-text {
    margin: 10px 0 4px;
  }
}

@media (max-width: 420px) {
  .profile {
    width: 76px;
    height: 76px;
    margin: 10px auto;
  }

  .user-name {
    font-size: 20px;
  }

  .footer-text {
    font-size: 13px;
  }
}

.modal-content #contact-form input[type="submit"] {
  background-color: #263046;
  color: #f3f6ff;
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.dashboard-trigger {
  position: fixed;
  right: 18px;
  bottom: calc(18px + env(safe-area-inset-bottom));
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.65);
  background-color: rgba(14, 22, 36, 0.88);
  color: #f4f7ff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  z-index: 20;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.dashboard-trigger:hover {
  transform: translateY(-2px);
  background-color: rgba(255, 255, 255, 0.12);
}

.auth-modal {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.65);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 30;
  padding: 16px;
}

.auth-modal.open {
  display: flex;
}

.auth-modal-card {
  width: 100%;
  max-width: 420px;
  background-color: rgba(19, 29, 46, 0.96);
  color: #edf2ff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 16px;
  padding: 20px;
  text-align: left;
  position: relative;
}

.auth-modal-card h2 {
  margin-bottom: 6px;
  font-size: 24px;
}

.auth-modal-card p {
  margin-bottom: 14px;
  color: #d8e0f5;
}

.auth-close {
  position: absolute;
  right: 10px;
  top: 8px;
  border: none;
  background: transparent;
  color: #e9efff;
  font-size: 28px;
  cursor: pointer;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.auth-form label {
  font-size: 14px;
}

.auth-form input {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background-color: rgba(255, 255, 255, 0.08);
  color: #f4f7ff;
  border-radius: 10px;
  padding: 10px 12px;
  font-family: "Space Mono", monospace;
}

.auth-form button,
.auth-actions button,
.auth-links button,
.auth-actions a {
  border: 1px solid rgba(255, 255, 255, 0.35);
  background-color: #eef3ff;
  color: #1f2b42;
  border-radius: 12px;
  padding: 10px 12px;
  font-family: "Space Mono", monospace;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
}

.auth-links {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

.auth-links button {
  background-color: transparent;
  color: #dfe7fb;
}

.auth-actions {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.auth-message {
  min-height: 20px;
  margin-top: 14px;
  color: #f6dda6;
}

@media (max-width: 768px) {
  .dashboard-trigger {
    right: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
    width: 48px;
    height: 48px;
    font-size: 24px;
  }

  .auth-modal-card {
    padding: 16px;
  }

  .auth-actions,
  .auth-links {
    flex-direction: column;
  }
}
