.streamer-hourly-chart {
  margin-top: 22px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, .1);
  background: linear-gradient(180deg, rgba(30, 43, 64, .98), rgba(17, 27, 41, .98));
}
.streamer-hourly-chart__title {
  margin: 0 0 10px;
  color: #fff3d4;
}
.streamer-hourly-chart__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.streamer-hourly-chart__panel {
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, .1);
  background: rgba(7, 10, 15, .45);
  padding: 10px;
}
.streamer-hourly-chart__panel--all-time {
  grid-column: 1 / -1;
}
.streamer-hourly-chart__panel--calendar {
  grid-column: 1 / -1;
}
.streamer-hourly-chart__panel-title {
  margin: 0 0 8px;
  color: #d8dbe8;
  font-size: .95rem;
  font-weight: 700;
}
.streamer-hourly-chart__canvas-wrap {
  position: relative;
  height: 240px;
}
.streamer-hourly-chart__canvas-wrap--all-time {
  height: 320px;
}

.streamer-hourly-chart__timeline {
  position: relative;
  min-height: 180px;
}

.streamer-hourly-chart__timeline-list {
}

.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__timeline-list {
  gap: 7px;
}

.streamer-hourly-chart__timeline-row {
  display: flex;
  align-items: center;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__timeline-row {
  grid-template-columns: 78px 16px 1fr;
}

.streamer-hourly-chart__timeline-left {
  color: #9da3ba;
  font-size: .86rem;
  white-space: nowrap;
  width: 25%;
  position: relative;
}

.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__timeline-left {
  font-size: .81rem;
}

.streamer-hourly-chart__timeline-dot {
  width: 12px;
  height: 12px;
  border-radius: 999px;
  border: 2px solid rgba(255, 255, 255, .24);
  background: rgba(12, 20, 34, .95);
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
}

.streamer-hourly-chart__timeline-right {
  border-left: 2px solid rgba(255, 255, 255, .08);
  display: grid;
  gap: 4px;
  padding: 10px 35px;
  flex-grow: 1;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__timeline-right {
  padding: 10px 25px;
  gap: 2px;
}

.streamer-hourly-chart__rank-line,
.streamer-hourly-chart__record-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: .86rem;
  color: #c8d4f1;
}

.streamer-hourly-chart__rank-line + .streamer-hourly-chart__rank-line {
  margin-top: 4px;
}

.streamer-hourly-chart__rank-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 2px 0;
  border: 0;
  background: transparent;
  border-radius: 0;
  min-height: 30px;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__rank-item {
  min-height: 24px;
  gap: 9px;
}

.streamer-hourly-chart__rank-label {
  color: #c6d3ef;
  font-size: .89rem;
  min-width: 0;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__rank-label {
  font-size: .82rem;
}

.streamer-hourly-chart__rank-meta,
.streamer-hourly-chart__rank-right {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  justify-content: flex-end;
  white-space: nowrap;
}

.streamer-hourly-chart__rank-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  font-size: .65rem;
  line-height: 1;
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .08);
  opacity: .95;
}

.streamer-hourly-chart__rank-badge.tier-1 {
  border-color: rgba(255, 215, 90, .65);
  background: radial-gradient(circle at 30% 30%, rgba(255, 244, 165, .42), rgba(255, 195, 66, .24));
}

.streamer-hourly-chart__rank-badge.tier-2 {
  border-color: rgba(220, 232, 255, .55);
  background: radial-gradient(circle at 30% 30%, rgba(245, 250, 255, .38), rgba(171, 195, 230, .22));
}

.streamer-hourly-chart__rank-badge.tier-3 {
  border-color: rgba(222, 170, 126, .58);
  background: radial-gradient(circle at 30% 30%, rgba(255, 218, 187, .32), rgba(191, 120, 72, .22));
}

.streamer-hourly-chart__rank-value {
  color: #ecf2ff;
  font-weight: 700;
  font-size: .9rem;
  letter-spacing: 0;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__rank-value {
  font-size: .84rem;
}

.streamer-hourly-chart__trend--inline {
  margin-left: 0;
  padding: 1px 7px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, .05);
  font-size: .74rem;
  font-weight: 700;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__trend--inline {
  padding: 1px 6px;
  font-size: .7rem;
}

.streamer-hourly-chart__trend--inline.up {
  border-color: rgba(82, 216, 132, .38);
  background: rgba(82, 216, 132, .14);
}

.streamer-hourly-chart__trend--inline.down {
  border-color: rgba(255, 91, 115, .38);
  background: rgba(255, 91, 115, .14);
}

.streamer-hourly-chart__rank-item + .streamer-hourly-chart__rank-item {
  border-top: 1px solid rgba(255, 255, 255, .07);
  padding-top: 6px;
}
.streamer-hourly-chart__timeline--ranking .streamer-hourly-chart__rank-item + .streamer-hourly-chart__rank-item {
  padding-top: 4px;
}

.streamer-hourly-chart__rank-line b,
.streamer-hourly-chart__record-line b {
  color: #f0f4ff;
}

.streamer-hourly-chart__record-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, .14);
  padding: 6px 10px;
  background: rgba(255, 255, 255, .05);
  min-height: 34px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
}

.streamer-hourly-chart__record-icon {
  display: inline-flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  font-size: .9rem;
  line-height: 1;
  border-radius: 6px;
  background: rgba(255, 255, 255, .1);
}

.streamer-hourly-chart__record-text {
  color: #d7e2ff;
}

.streamer-hourly-chart__record-value {
  margin-left: 4px;
  font-weight: 800;
  letter-spacing: .01em;
}

.streamer-hourly-chart__record-chip--peak {
  border-color: rgba(255, 73, 139, .42);
  background: linear-gradient(90deg, rgba(255, 73, 139, .2), rgba(255, 73, 139, .08));
}

.streamer-hourly-chart__record-chip--peak .streamer-hourly-chart__record-icon {
  background: rgba(255, 73, 139, .24);
}

.streamer-hourly-chart__record-chip--peak .streamer-hourly-chart__record-value {
  color: #ff82b3;
}

.streamer-hourly-chart__record-chip--avg {
  border-color: rgba(255, 207, 42, .42);
  background: linear-gradient(90deg, rgba(255, 207, 42, .2), rgba(255, 207, 42, .08));
}

.streamer-hourly-chart__record-chip--avg .streamer-hourly-chart__record-icon {
  background: rgba(255, 207, 42, .24);
}

.streamer-hourly-chart__record-chip--avg .streamer-hourly-chart__record-value {
  color: #ffe27a;
}

.streamer-hourly-chart__record-chip--milestone-peak {
  border-color: rgba(46, 231, 196, .42);
  background: linear-gradient(90deg, rgba(46, 231, 196, .2), rgba(46, 231, 196, .08));
}

.streamer-hourly-chart__record-chip--milestone-peak .streamer-hourly-chart__record-icon {
  background: rgba(46, 231, 196, .24);
}

.streamer-hourly-chart__record-chip--milestone-peak .streamer-hourly-chart__record-value {
  color: #6df2d8;
}

.streamer-hourly-chart__record-chip--milestone-followers {
  border-color: rgba(154, 132, 255, .42);
  background: linear-gradient(90deg, rgba(154, 132, 255, .22), rgba(154, 132, 255, .08));
}

.streamer-hourly-chart__record-chip--milestone-followers .streamer-hourly-chart__record-icon {
  background: rgba(154, 132, 255, .26);
}

.streamer-hourly-chart__record-chip--milestone-followers .streamer-hourly-chart__record-value {
  color: #c6b4ff;
}

.streamer-hourly-chart__trend {
  font-size: .78rem;
  font-weight: 700;
}

.streamer-hourly-chart__trend.up {
  color: #52d884;
}

.streamer-hourly-chart__trend.down {
  color: #ff5b73;
}

.streamer-hourly-chart__records {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.streamer-hourly-chart__record {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .04);
  padding: 5px 10px;
  font-size: .82rem;
}

.streamer-hourly-chart__record-label {
  color: #9da3ba;
}

.streamer-hourly-chart__record-value {
  font-weight: 700;
  color: #f0f4ff;
}

.streamer-hourly-chart__calendar {
  min-height: 240px;
  --streamer-day-size: .85rem;
  padding-bottom: 4px;
}

.streamer-hourly-chart__calendar-empty {
  color: #9da3ba;
}

.streamer-hourly-chart__month {
  font-size: .72rem;
  color: #9da3ba;
  white-space: nowrap;
  margin-bottom: 8px;
  text-align: center;
}

.streamer-hourly-chart__calendar-grid {
  display: flex;
  gap: 10px;
  padding-bottom: 6px;
}

.streamer-hourly-chart__month-block {
  flex: 0 0 auto;
}

.streamer-hourly-chart__month-grid {
  display: grid;
  grid-template-rows: repeat(7, var(--streamer-day-size));
  grid-auto-flow: column;
  gap: 2px;
}

.streamer-hourly-chart__day {
  width: var(--streamer-day-size);
  height: var(--streamer-day-size);
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, .08);
  background: rgba(20, 33, 55, .45);
}

.streamer-hourly-chart__day.level-1 { background: rgba(74, 194, 176, .5); border-color: rgba(74, 194, 176, .35); }
.streamer-hourly-chart__day.level-2 { background: rgba(74, 194, 176, .66); border-color: rgba(74, 194, 176, .44); }
.streamer-hourly-chart__day.level-3 { background: rgba(74, 194, 176, .82); border-color: rgba(74, 194, 176, .56); }
.streamer-hourly-chart__day.level-4 { background: rgba(46, 231, 196, .96); border-color: rgba(46, 231, 196, .8); box-shadow: 0 0 0 1px rgba(46, 231, 196, .24); }
.streamer-hourly-chart__day--empty {
  opacity: .25;
}

.streamer-hourly-chart__day:hover {
  outline: 1px solid rgba(255, 255, 255, .45);
  transform: scale(1.2);
  transform-origin: center;
}
.streamer-hourly-chart__meta {
  margin-top: 8px;
  color: #9da3ba;
  font-size: .9rem;
}

.streamer-hourly-chart__legend {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #9da3ba;
  font-size: .78rem;
  margin-bottom: 10px;
}

.streamer-hourly-chart__legend-box {
  width: .72rem;
  height: .72rem;
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, .12);
  display: inline-block;
}

.streamer-hourly-chart__legend-box.level-1 { background: rgba(74, 194, 176, .5); border-color: rgba(74, 194, 176, .35); }
.streamer-hourly-chart__legend-box.level-2 { background: rgba(74, 194, 176, .66); border-color: rgba(74, 194, 176, .44); }
.streamer-hourly-chart__legend-box.level-3 { background: rgba(74, 194, 176, .82); border-color: rgba(74, 194, 176, .56); }
.streamer-hourly-chart__legend-box.level-4 { background: rgba(46, 231, 196, .96); border-color: rgba(46, 231, 196, .8); }

.streamer-hourly-chart__years {
  display: grid;
  gap: 14px;
}

.streamer-hourly-chart__year {
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 10px;
  padding: 10px;
  background: rgba(7, 10, 15, .35);
}

.streamer-hourly-chart__year-title {
  margin-bottom: 8px;
  color: #fff3d4;
  font-weight: 700;
  letter-spacing: .02em;
}

.streamer-hourly-chart__year-body {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 8px;
}

.streamer-hourly-chart__year-main {
  min-width: 0;
}

.streamer-hourly-chart__weekdays {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  grid-template-rows: repeat(7, var(--streamer-day-size));
  gap: 3px;
  font-size: .66rem;
  color: #8e99b3;
  line-height: 1;
}

.streamer-hourly-chart__weekdays span {
  display: inline-flex;
  align-items: center;
  height: var(--streamer-day-size);
}

.streamer-hourly-chart__tooltip {
  position: fixed;
  z-index: 9999;
  min-width: 220px;
  max-width: 280px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(7, 10, 15, .96);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .45);
  padding: 10px 12px;
  pointer-events: none;
  color: #d8dbe8;
}

.streamer-hourly-chart__tooltip-date {
  font-weight: 800;
  color: #eaf1ff;
  margin-bottom: 8px;
  border-bottom: 1px dashed rgba(255, 255, 255, .12);
  padding-bottom: 6px;
}

.streamer-hourly-chart__tooltip-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: .85rem;
  line-height: 1.35;
  padding: 2px 0;
}

.streamer-hourly-chart__tooltip-label--duration { color: #ff8e6d; }
.streamer-hourly-chart__tooltip-label--avg { color: #30e0c4; }
.streamer-hourly-chart__tooltip-label--max { color: #e7d34d; }
.streamer-hourly-chart__tooltip-label--watched { color: #c493ff; }
.streamer-hourly-chart__tooltip-label--followers { color: #5fb3ff; }
.streamer-hourly-chart__tooltip-label--muted { color: #9da3ba; }
.streamer-hourly-chart__tooltip-value {
  font-weight: 700;
  color: #f0f4ff;
}

@media (max-width: 900px) {
  .streamer-hourly-chart__grid {
    grid-template-columns: 1fr;
  }

  .streamer-hourly-chart__calendar-grid {
    gap: 10px;
  }

  .streamer-hourly-chart__month-grid {
    grid-template-rows: repeat(7, var(--streamer-day-size));
    gap: 1px;
  }

  .streamer-hourly-chart__day {
    width: var(--streamer-day-size);
    height: var(--streamer-day-size);
  }

  .streamer-hourly-chart__calendar {
    --streamer-day-size: .65rem;
  }

  .streamer-hourly-chart__year-body {
    grid-template-columns: 1fr;
  }

  .streamer-hourly-chart__weekdays {
    display: none;
  }
}
