/* Dots container */
.dots-bg {
  position: fixed;
  top: 0; left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 0; /* Lower z-index */
  overflow: hidden;
}

/* Individual dot style */
.dot {
  position: absolute;
  border-radius: 50%;
  background: #636363; /* bright white for visibility */
  opacity: 0.7;
  /* width/height set by JS */
}

/* Keyframes for floating animation */
@keyframes float {
  0% {
    transform: translateY(0) scale(1);
    opacity: 0.7;
  }
  50% {
    transform: translateY(-40px) scale(1.2);
    opacity: 0.5;
  }
  100% {
    transform: translateY(0) scale(1);
    opacity: 0.7;
  }
}

body, html {
  background: #000;
  margin: 0;
  padding: 0;
  height: 100%;
}

@font-face {
  font-family: 'MapleMono-ExtraBold';
  src: url('assets/MapleMono-ExtraBold.ttf') format('truetype');
  font-weight: bold;
  font-style: normal;
}

/* Load Fira Code Bold from assets */
@font-face {
  font-family: 'FiraCode';
  src: url('assets/FiraCode-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

/* Alias the font with the exact family name used in CSS to avoid mismatch */
@font-face {
  font-family: 'FiraCode-Bold';
  src: url('assets/FiraCode-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

.profile-panel {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(106, 106, 106, 0.15); /* much more transparent */
  border-radius: 24px;
  padding: 16px 64px 16px 64px;
  box-shadow: 0 8px 32px rgba(39, 39, 39, 0.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 280px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 2;
  color: #fff; /* default text color inside panel */
}

.currently-panel {
  position: absolute;
  top: 5%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(106, 106, 106, 0.15);
  border-radius: 24px;
  padding: 16px 64px 16px 64px;
  box-shadow: 0 8px 32px rgba(39, 39, 39, 0.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 280px;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  color: #fff;
}

.profile-img {
  width: 128px;
  height: 128px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid #000000;
  box-shadow: 0 2px 16px rgba(0,0,0,0.3);
  margin-bottom: 24px;
}

.window-img {
  width: 100%;
  max-width: 100%;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  margin-bottom: 0px;
}

.profile-text {
  font-family: 'FiraCode-Bold', monospace;
  font-size: 1.8rem; /* smaller font size */
  color: inherit; /* use panel color */
  text-align: center;
  letter-spacing: 0.5px;
}

.sub-text {
  font-family: 'FiraCode-Bold', monospace;
  font-size: 1.2rem; /* smaller font size */
  color: inherit; /* use panel color */
  text-align: center;
  letter-spacing: 0.5px;
}

.profile-icons {
  display: flex;
  gap: 16px;
  margin-top: 16px;
  justify-content: center;
}

.icon-img {
  width: 32px;
  height: 32px;
  transition: transform 0.2s;
  border-radius: 8px;
  filter: brightness(0) invert(1); /* makes images white */
}

.icon-img:hover {
  transform: scale(1.2);
}

.profile-audio {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  margin: 18px 0 0 0;
  justify-content: center;
}

#play-pause {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}

#play-pause:hover {
  transform: scale(1.2);
}

#play-pause-icon {
  width: 28px;
  height: 28px;
  filter: brightness(0) invert(1); /* makes icon white if needed */
}

#progress {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
}

/* Window Panels */

.window-panel {
  font-family: 'FiraCode-Bold', monospace;
  position: absolute;
  top: 19%;
  left: 75%;
  transform: translate(-50%, -50%);
  background: rgba(106, 106, 106, 0.15);
  border-radius: 16px;
  padding: 0; /* header + body handle spacing */
  box-shadow: 0 8px 32px rgba(39, 39, 39, 0.2);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-width: 280px;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  z-index: 2;
  color: #fff;
  overflow: hidden; /* keeps corners rounded */
}

.window-header {
  display: flex;
  align-items: center;
  justify-content: space-between; /* pushes title left, controls right */
  background: rgba(255, 255, 255, 0.1);
  padding: 8px 12px;
  font-weight: bold;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.window-title {
  flex: 1 1 auto;    /* allow it to grow and shrink */
  min-width: 0;      /* crucial: allows it to shrink below content width */
  overflow: hidden;  /* hide overflow */
  text-overflow: ellipsis; /* add ... when truncated */
  white-space: nowrap; /* prevent line breaks */
}

.window-controls {
  display: flex;
  gap: 6px;
}

.window-controls .btn {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.window-controls .btn {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
}

.window-controls .close { background: #ff5f57; }
.window-controls .minimize { background: #ffbd2e; }
.window-controls .maximize { background: #28c940; }

.window-body {
  padding: 16px 24px;
  text-align: center;
}