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

html, body {
  height: 100%;
}

body {
  display: flex;
  flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #1e1f22;
}

.tabs {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  background: #2b2d31;
  border-bottom: 1px solid #1a1b1e;
}

.tab-indicator {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: #5865f2;
  transition: transform 0.25s ease, width 0.25s ease;
}

.tab {
  flex: 1;
  min-width: 80px;
  padding: 12px 8px;
  border: none;
  background: transparent;
  color: #b5bac1;
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.tab:hover {
  background: #35373c;
  color: #ffffff;
}

.tab.active {
  background: #404249;
  color: #ffffff;
}

.panel-container {
  position: relative;
  flex: 1;
}

.frame-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: none;
}

.frame-wrap.active {
  display: block;
}

.panel-frame {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.loader {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1e1f22;
  z-index: 1;
  transition: opacity 0.2s ease;
}

.loader.hidden {
  opacity: 0;
  pointer-events: none;
}

.loader::after {
  content: "";
  width: 40px;
  height: 40px;
  border: 4px solid #404249;
  border-top-color: #5865f2;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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