body {
  margin: 0;
  padding: 0;
  font-family: 'Comic Neue', cursive;
  overflow: hidden;
  background-color: black;
  color: #fff;
  position: relative;
  min-height: 100vh;
}

#terminal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(92vw, 600px);
  height: auto;
  max-height: 90vh;
  background-color: #1e1e1e;
  color: #ffffff;
  border-radius: 10px;
  z-index: 2000;
  border: 2px solid #4d4d4d;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  display: block;
}

@media screen and (max-width: 600px) {
  #terminal {
      width: min(92vw, 420px);
  }
}

#terminal-header {
  background-color: #2d2d2d;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  padding: 10px;
  display: flex;
  justify-content: flex-start;
  transition: background-color 0.3s;
}

#terminal-header:hover {
  background-color: #333333;
}

#terminal-buttons {
  display: flex;
  gap: 10px;
}

.terminal-button {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  transition: background-color 0.3s;
}

.terminal-button:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

#close-button {
  background-color: #FF5F57;
}

#minimize-button {
  background-color: #FFBD2E;
}

#maximize-button {
  background-color: #28CA42;
}

#terminal-content {
  padding: 20px;
  height: calc(100% - 40px);
  overflow-y: auto;
  user-select: none;
}

#terminal-text {
  margin: 0;
  padding: 0;
  font-size: 14px;
  line-height: 1.5;
  overflow: hidden;
  white-space: pre-line;
}

#video-background {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  overflow: hidden;
}

#video-background::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(to bottom, rgba(255, 255, 255, 0.05) 0, rgba(255, 255, 255, 0.05) 1px, transparent 1px, transparent 2px);
  z-index: 1;
  pointer-events: none;
}

#myVideo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.top-left {
  top: 0;
  left: 0;
}

.top-right {
  top: 0;
  right: 0;
}

.bottom-left {
  bottom: 0;
  left: 0;
}

.bottom-right {
  bottom: 0;
  right: 0;
}

#blurred-box {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) perspective(1000px);
  width: min(92vw, 520px);
  max-height: min(86vh, 820px);
  background-color: rgba(0, 0, 0, 0.38);
  border-radius: 24px;
  border: 2px solid rgba(255, 255, 255, 0.75);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  padding: 24px 22px;
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: box-shadow 0.1s linear, transform 0.1s ease-out;
  will-change: box-shadow, transform;
  z-index: 999;
  overflow-y: auto;
  transform-style: preserve-3d;
}

#profile-picture {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 8px;
  flex-shrink: 0;
}

#avatar-frame {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: 140px;
  height: 140px;
  z-index: 2;
  pointer-events: none;
  display: block;
  border-radius: 50% !important;
  object-fit: cover;
  transition: all 0.3s ease;
}

#typing-cursor {
  display: inline-block;
  animation: blink 1s infinite;
  color: white;
  font-weight: normal;
  font-size: 32px;
}

@keyframes blink {
  0% { opacity: 1; }
  50% { opacity: 0; }
  100% { opacity: 1; }
}

#username-container {
  position: relative;
  top: auto;
  left: auto;
  transform: none;
  z-index: 1;
  padding: 4px 0;
  margin: 0;
  text-align: center;
  text-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
  border-radius: 20px;
  pointer-events: auto;
  white-space: normal;
  font-size: 24px;
  font-weight: bold;
  min-height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
}

.links {
  position: relative;
  left: auto;
  bottom: auto;
  transform: none;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  z-index: 1;
  width: 100%;
  margin-top: 4px;
}

.links a {
  display: flex;
  align-items: center;
  color: #ffffff;
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s ease;
}

.links a:hover {
  color: rgba(222, 222, 222, 0.8);
  text-decoration: underline;
  transform: translateY(-5px) scale(1.1);
}

.links a i {
  font-size: 24px;
}

.user-description {
  position: relative;
  left: auto;
  bottom: auto;
  transform: none;
  width: 100%;
  max-width: 420px;
  z-index: 1;
  text-align: center;
  transition: all 0.3s ease;
  margin: 0;
}

.user-description p {
  color: white;
  background-color: rgba(0, 0, 0, 0.3);
  padding: 8px 15px;
  border-radius: 20px;
  font-size: 1.1em;
  margin: 0;
  transition: transform 0.3s;
  word-break: break-word;
}

.discord-widget {
  position: relative;
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  padding: 12px;
  width: min(100%, 360px);
  backdrop-filter: blur(10px);
  color: #fff;
  font-family: 'Comic Neue', cursive;
  transition: all 0.3s ease;
  z-index: 1;
  margin: 0;
}

.discord-content {
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}

.discord-icon img {
  width: 15vmin;
  height: 15vmin;
  max-width: 72px;
  max-height: 72px;
  border-radius: 50%;
  margin-right: 16px;
  background-color: #222;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.5);
}

.discord-meta b {
  font-size: 20px;
  display: block;
  font-weight: 600;
  position: relative;
  bottom: -7px;
}

.discord-meta span, .discord-meta div {
  font-size: 15px;
  display: inline-block;
  color: #ccc;
}

#discord-status-text {
  display: none !important;
}

#discord-status-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
  margin-left: -138px;
  margin-bottom: 3px;
  margin-top: 5px;  
  box-shadow: 0 0 8px rgba(255, 255, 255, 0.2);
}

.status-online { background-color: #3ba55d; }
.status-idle { background-color: #faa81a; }
.status-dnd { background-color: #ed4245; }
.status-offline { background-color: #747f8d; }

.discord-activity {
  position: relative;
  display: flex;
  align-items: center;
  background-color: rgba(0, 0, 0, 0.3);
  padding: 12px;
  border-radius: 13px;
  font-style: italic;
  font-size: 14px;
  color: #ccc;
  min-height: 80px;
  overflow: hidden;
}

#discord-activity-info, #discord-no-activity {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 8px;
  opacity: 1;
  transition: opacity 0.5s ease-in-out;
  display: flex;
  align-items: center;
}

#discord-activity-info.hidden, #discord-no-activity.hidden {
  opacity: 0;
  pointer-events: none;
}

#discord-album-art {
  width: 56px;
  height: 56px;
  background-size: cover;
  background-position: center;
  border-radius: 8px;
  margin-right: 12px;
  flex-shrink: 0;
  background-color: #333;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.discord-activity-content {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

#discord-activity-name {
  font-weight: bold;
  font-style: normal;
  font-size: 16px;
  margin-bottom: 4px;
  color: white;
}

#discord-activity-state, #discord-activity-details {
  font-size: 14px;
  font-style: italic;
  color: #ccc;
  margin-bottom: 2px;
}

.discord-widget .discord-icon img {
  width: 52px !important;
  height: 52px !important;
  margin-right: 14px !important;
}

.badges-container {
  position: relative;
  left: auto;
  top: auto;
  transform: none;
  display: flex;
  justify-content: center;
  gap: 8px;
  width: 100%;
  z-index: 1;
  flex-wrap: wrap;
  margin: 0;
}

.badges-container img {
  width: 24px !important;
  height: 24px !important;
  border-radius: 0 !important;
  object-fit: contain;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.lang-container {
  position: relative;
  left: auto;
  bottom: auto;
  transform: none;
  display: flex;
  justify-content: center;
  gap: 8px;
  width: 100%;
  z-index: 1;
  margin: 0;
  flex-wrap: wrap;
}

.lang-container img {
  width: 50px !important;
  height: 50px !important;
  border-radius: 0 !important;
  object-fit: contain;
  transition: all 0.3s ease;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

#music-player-card {
  width: 100%;
  max-width: 320px;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.player-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

#music-cover {
  width: 38px;
  height: 38px;
  border-radius: 6px;
  object-fit: cover;
}

.track-info {
  display: flex;
  flex-direction: column;
  max-width: 120px;
  overflow: hidden;
}

#track-title {
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

#track-artist {
  color: #bbb;
  font-size: 10px;
}

.player-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.player-controls button {
  background: none;
  border: none;
  color: white;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s, color 0.2s;
}

.player-controls button:hover {
  color: #00d2ff;
  transform: scale(1.15);
}

#top-left-volume {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 9999;
  display: flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  padding: 8px 12px;
  cursor: pointer;
  transition: background 0.3s ease, opacity 0.2s ease, transform 0.2s ease;
}

#top-left-volume.volume-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
}

#top-left-volume:hover {
  background: rgba(0, 0, 0, 0.6);
}

#volume-icon {
  color: white;
  font-size: 18px;
  min-width: 18px;
  transition: font-size 0.2s ease, color 0.2s ease;
}

.volume-slider-wrapper {
  width: 0;
  overflow: hidden;
  opacity: 0;
  transition: width 0.3s ease-in-out, opacity 0.3s ease-in-out, margin-left 0.3s ease-in-out;
  display: flex;
  align-items: center;
}

#top-left-volume:hover .volume-slider-wrapper,
#top-left-volume:focus-within .volume-slider-wrapper {
  width: 90px;
  opacity: 1;
  margin-left: 8px;
}

#volume-slider {
  width: 80px;
  height: 4px;
  cursor: pointer;
  accent-color: #00d2ff;
}

#video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  z-index: 2;
  opacity: 1;
  transition: opacity 0.5s ease, backdrop-filter 0.5s ease;
}

body.video-normal #video-overlay {
  opacity: 0;
  backdrop-filter: blur(0);
  pointer-events: none;
}

.neko {
  transition: left 0.2s ease-out, top 0.2s ease-out;
  will-change: left, top;
}

@media screen and (max-width: 768px) {
  #blurred-box {
    width: min(94vw, 480px);
    padding: 20px 16px;
  }

  #profile-picture {
    width: 100px;
    height: 100px;
  }

  #username-container {
    font-size: 22px;
  }

  #typing-cursor {
    font-size: 22px;
  }

  #avatar-frame {
    width: 120px;
    height: 120px;
    top: 14px;
  }

  .discord-widget {
    width: min(100%, 320px);
  }

  .lang-container img {
    width: 40px;
    height: 40px;
  }

  .badges-container img {
    width: 21px;
    height: 21px;
  }
}

@media screen and (max-width: 480px) {
  #blurred-box {
    width: min(95vw, 420px);
    padding: 14px 12px;
    max-height: 90vh;
  }

  #profile-picture {
    width: 84px;
    height: 84px;
  }

  #username-container {
    font-size: 20px;
  }

  #typing-cursor {
    font-size: 20px;
  }

  #avatar-frame {
    width: 104px;
    height: 104px;
    top: 10px;
    transform: translateX(-50%);
  }

  .discord-widget {
    width: 100%;
    padding: 8px;
  }

  .discord-icon img {
    width: 48px;
    height: 48px;
  }

  .discord-meta b {
    font-size: 16px;
  }

  .discord-meta span, .discord-meta div {
    font-size: 12px;
  }

  .discord-activity {
    min-height: 60px;
    padding: 8px;
    font-size: 12px;
  }

  #discord-status-dot {
    margin-left: -120px;
  }

  #discord-album-art {
    width: 40px;
    height: 40px;
  }

  #discord-activity-name {
    font-size: 14px;
  }

  .lang-container img {
    width: 30px;
    height: 30px;
  }

  .links a i {
    font-size: 20px;
  }

  .user-description p {
    font-size: 14px;
  }

  .badges-container img {
    width: 18px;
    height: 18px;
  }

  #music-player-card {
    max-width: 100%;
    padding: 8px 12px;
  }

  #track-title {
    font-size: 11px;
  }

  #track-artist {
    font-size: 9px;
  }
}
