/* ===== STATUS ===== */

.status {
    font-weight: bold;
    font-size: 15px;
    gap: 8px;
    border: 2px solid var(--twitch-purple);
}

.status-icon {
    width: 20px;
    height: 20px;
}

.status.online .status-icon {
    color: #00f593;
    animation: onlinePulse 1.5s infinite;
}

.status.offline .status-icon {
    color: #eb0400;
    animation: offlinePulse 1.5s infinite;
}

.clock,
.theme-toggle {
    height: 32px;
    padding: 0 14px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    box-sizing: border-box;
}

.topbar-badge {
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.status {
    font-weight: bold;
    padding: 0 14px;
    border-radius: 6px;
    font-size: 15px;
    border: 2px solid transparent;
}

.status.online {
    background: transparent;
    color: #000;
    border: 2px solid var(--twitch-purple);
}

.status.offline {
    background: transparent;
    color: #000;
    border: 2px solid var(--twitch-purple);
}

/* ===== CLOCK ===== */

.clock {
    font-size: 15px;
    font-weight: bold;
    padding: 0 14px;
    border-radius: 6px;
    border: 2px solid var(--twitch-purple);
}

/* ===== THEME BUTTON ===== */

.theme-toggle {
    background: #18181b;
    border: 2px solid var(--twitch-purple);
    color: white;
    font-size: 15px;
    padding: 0;
    width: 36px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
    line-height: 1;
}

.theme-toggle:hover {
    background: rgba(119, 44, 232, 0.5);
}

/* ===== ACTIVE USERS ===== */

.active-users {
    height: 32px;
    padding: 0 14px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 15px;
    border: 2px solid var(--twitch-purple);
    gap: 6px;
    position: relative;
    color: #ff827f;
    z-index: 1000;
}

.active-users .tooltip {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    background: #18181b;
    color: white;
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 6px;
    white-space: nowrap;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.active-users:hover .tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(4px);
}

.active-users-icon {
    width: 20px;
    height: 20px;
    fill: #fff !important;
}

/* ===== VIEWER COUNT ===== */

.viewer-count {
    height: 32px;
    padding: 0 14px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 15px;
    border: 2px solid var(--twitch-purple);
    gap: 6px;
    color: #ff827f;
    position: relative;
}

.viewer-icon {
    width: 20px;
    height: 20px;
    fill: #fff !important;
}

.viewer-count:hover .tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(4px);
}

/* ===== GLOBAL TOOLTIP ===== */

.tooltip {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    background: #18181b;
    color: white;
    font-size: 12px;
    font-weight: 600;
    font-family: inherit;
    padding: 6px 10px;
    border-radius: 6px;
    white-space: nowrap;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.topbar-badge:hover .tooltip,
.bot-container:hover .tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(4px);
}

/* ===== BOT CONTAINER ===== */

.bot-container {
    position: relative;
}

.bot-btn {
    height: 32px;
    padding: 6px 15.5px;
    border-radius: 6px;
    border: 2px solid var(--twitch-purple);
    background: #18181b;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
}

.bot-icon {
    width: 20px;
    height: 20px;
    display: block;
}

/* ===== PLAYER SWITCH ===== */

.player-container {
    position: relative;
}

.player-container:hover .tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(4px);
}

.player-btn {
    height: 32px;
    padding: 6px 15.5px;
    border-radius: 6px;
    border: 2px solid var(--twitch-purple);
    background: #18181b;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
}

.player-icon {
    width: 20px;
    height: 20px;
    display: block;
}

/* ===== SWITCH ===== */

.switch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 18px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  border-radius: 5px;
  background: #444;
  transition: 0.25s ease;
}

.slider::before {
  content: "";
  position: absolute;
  height: 12px;
  width: 12px;
  left: 3px;
  top: 3px;
  border-radius: 3px;
  background: white;
  transition: 0.25s ease;
}

.slider::after {
  content: "OFF";
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 7px;
  font-weight: 600;
  letter-spacing: 0.5px;
  width: 18px;
  text-align: center;
  right: 2px;
  color: #aaa;
  pointer-events: none;
  transition: 0.2s ease;
}

.switch input:checked + .slider {
  background: var(--twitch-purple);
}

.switch input:checked + .slider::before {
  transform: translateX(18px);
}

.switch input:checked + .slider::after {
  content: "ON";
  left: 1px;
  right: auto;
  color: #fff;
}

/* ===== TITLE + HISTORY ===== */

.title-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.history-container {
    position: relative;
}

.history-btn {
    background: #18181b;
    border-radius: 6px;
    border: 2px solid var(--twitch-purple);
    color: white;
    padding: 6px 15.5px;
    cursor: pointer;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.history-text {
    font-size: 15px;
    font-weight: 600;
}

.history-btn:hover {
    background: rgba(119, 44, 232, 0.5);
}

.history-dropdown {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: #18181b;
    border: 1px solid var(--twitch-purple);
    border-radius: 6px;
    min-width: 160px;
    max-height: 250px;
    overflow-y: auto;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
    z-index: 999;
}

.history-dropdown div {
    padding: 8px 12px;
    cursor: pointer;
    font-size: 13px;
}

.hidden {
    display: none;
}

.live-day {
    font-weight: bold;
    color: var(--twitch-purple);
}

.history-year {
    padding: 6px 10px;
    font-weight: bold;
    font-size: 13px;
    opacity: 0.7;
    pointer-events: none;
}

.history-month-header {
    padding: 6px 10px;
    cursor: pointer;
    font-weight: 600;
    border-radius: 4px;
}

.history-month-header:hover {
    background: rgba(145, 70, 255, 0.12);
}

.history-month-content {
    display: none;
    padding-left: 12px;
}

.history-month-content.open {
    display: block;
}

.history-day {
    padding: 6px 10px;
    cursor: pointer;
    border-radius: 4px;
}

.history-day:hover {
    background: rgba(145, 70, 255, 0.18);
}

.history-icon {
    width: 20px;
    height: 20px;
}

/* ===== USERLIST ===== */

.userlist-container {
    position: relative;
}

.userlist-btn {
    height: 32px;
    padding: 6px 15.5px;
    border-radius: 6px;
    border: 2px solid var(--twitch-purple);
    background: #18181b;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.userlist-text {
    font-size: 15px;
    font-weight: 550;
}

.userlist-btn:hover {
    background: rgba(119, 44, 232, 0.5);
}

.userlist-icon {
    width: 20px;
    height: 20px;
}

.user-dropdown {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: #18181b;
    border: 1px solid var(--twitch-purple);
    border-radius: 6px;
    min-width: 220px;
    max-height: 300px;
    overflow-y: auto;
    padding: 8px 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
    z-index: 999;
}

.user-dropdown-header {
    padding: 10px 0;
    font-weight: bold;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid var(--twitch-purple);
    margin-bottom: 6px;
}

.user-entry {
    display: flex;              /* 🔥 neu */
    align-items: center;        /* 🔥 vertikal zentriert */
    gap: 8px;                   /* 🔥 Abstand zwischen Icon & Name */

    padding: 6px 12px;
    font-size: 13px;
    cursor: pointer;
}

.twitch-icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;             /* 🔥 verhindert Verkleinern */
}

.user-entry:hover {
    background: rgba(145, 70, 255, 0.18);
	border-radius: 6px;
}

#userCount {
    background: rgba(145, 70, 255, 0.15);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.message-count {
    opacity: 0.6;
    font-size: 12px;
}