@import url("./dialog.css");

/* 레이아웃 */
body {
  /* 100vh - Navigation Bar Height - Content Position */
  height: calc(100vh - 45px - 14px);
  display: flex;
  flex-direction: column;
  margin-bottom: 0;
}
/* 헤더 */
.header {
  background-color: var(--accent-color);
  background-image: url("../src/img_ranking_bg_shape.svg");
  background-repeat: no-repeat;
  padding: 30px 30px 40px 30px;
}
/* 헤더 - 닫기 버튼 */
.header__close {
  text-align: right;
}
.header__close button {
  width: auto;
  background: none;
  display: inline-flex;
  align-items: center;
  column-gap: 10px;
  font-weight: 600;
  font-size: 13px;
  color: var(--white-color);
  opacity: 0.6;
}
/* 헤더 - 타이틀 */
.header__title {
  font-size: 21px;
  font-weight: 500;
  color: var(--white-color);
  margin: 25px 0 10px 0;
}
/* 헤더 - 프로필 */
.header-profile {
  width: 100%;
  display: flex;
  column-gap: 20px;
  margin-top: 20px;
}
.header-profile__thumbnail {
  width: 72px;
  height: 72px;
  box-sizing: border-box;
  padding: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 20px;
  background: #f86600;
}
.header-profile__thumbnail img {
  width: 100%;
  height: auto;
}
.header-profile-info {
  width: 100%;
  display: flex;
  flex-direction: column;
  padding: 10px 0;
  row-gap: 15px;
  flex: 1;
}
.header-profile-info__status {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.header-profile-info__status > div {
  display: flex;
  align-items: center;
  column-gap: 7px;
}
.header-profile-info__status .ranking {
  color: var(--white-color);
  font-size: 13px;
  font-weight: 600;
}
.header-profile-info__status .ranking strong {
  font-size: 24px;
  margin-right: 2px;
}
.header-profile-info__status .ranking .trend {
  position: relative;
  font-size: 13px;
  font-weight: 600;
}
.header-profile-info__status .ranking .trend span {
  position: relative;
  top: -5px;
}
.header-profile-info__status .ranking .trend::after {
  position: absolute;
  left: -1px;
  bottom: -8px;
}
.header-profile-info__status .ranking .trend.down {
  color: #ff3838;
}
.header-profile-info__status .ranking .trend.down::after {
  content: "";
  width: 0;
  height: 0;
  border-bottom: 7px solid transparent;
  border-top: 7px solid #ff3838;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
}
.header-profile-info__status .ranking .trend.up {
  color: #64b8f6;
}
.header-profile-info__status .ranking .trend.up::after {
  content: "";
  width: 0;
  height: 0;
  border-bottom: 7px solid #64b8f6;
  border-top: 7px solid transparent;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  bottom: -1px;
}
.header-profile-info__status .medal {
  color: var(--white-color);
  font-size: 13px;
  font-weight: 600;
}
.header-profile-info__status .point {
  color: var(--white-color);
  font-size: 15px;
  font-weight: 600;
  column-gap: 5px;
}
.header-profile-info__status .point > img {
  margin-bottom: 3px;
}
.header-profile-info__status .divider {
  width: 2px;
  height: 100%;
  background: rgba(255, 252, 250, 0.2);
}
.header-profile-info__guide {
  text-align: right;
}
.header-profile-info__guide button {
  width: auto;
  font-size: 12px;
  font-weight: 500;
  color: var(--white-color);
  background: none;
  display: inline-flex;
  column-gap: 4px;
  align-items: center;
}

.header-profile-info__guide button > img {
  margin-bottom: 3px;
}

/* ---------------------------------------------------- */

/* 랭킹 */
.ranking-list-container {
  background: var(--white-color);
  position: relative;
  top: -20px;
  border-radius: 20px;
  overflow-y: scroll;
  height: 100%;
}
.ranking-list-container::-webkit-scrollbar {
  display: none;
}
/* 랭킹 리스트 */
.ranking-list {
  display: flex;
  flex-direction: column;
  padding: 25px 25px 100px 25px;
  height: -webkit-fill-available;
  margin: 0;
}
/* 랭킹 리스트 - 이벤트 버튼 */
.ranking-list__event-button {
  background: var(--white-color);
  border: 1px solid #f2f0ef;
  box-shadow: 4px 8px 8px rgba(188, 181, 173, 0.2);
  display: flex;
  align-items: center;
  column-gap: 12px;
  font-size: 15px;
  font-weight: 500;
  padding: 16px;
}
.ranking-list__event-button img {
  max-width: 100px;
  height: auto;
}
.ranking-list__event-button span {
  line-height: 21px;
  text-align: left;
  flex: 1;
}
/* 랭킹 리스트 - 타이틀 */
.ranking-list__title {
  position: relative;
  font-size: 16px;
  font-weight: 500;
  display: flex;
  align-items: center;
  margin-top: 25px;
  margin-bottom: 10px;
}
.ranking-list__title > button {
  z-index: 100;
}
.ranking-list__title .info {
  background: none;
  width: auto;
  padding: 5px 5px 7px 5px;
  opacity: 0.4;
}
/* 랭킹 리스트 - 타이틀 - 툴팁 */
.ranking-list-title-tooltip {
  position: relative;
  font-size: 12px;
  color: rgba(35, 34, 33, 0.4);
  padding: 10px 20px 10px 12px;
  background: var(--white-color);
  box-shadow: 0px 2px 14px 6px #2322211a;
  border-radius: 12px;
  border: none;
  max-width: 205px;
  width: 100%;
  flex: 1;
  right: -10px;
  word-break: break-all;
  top: -2px;
  line-height: 16px;
  transition: var(--transition-duration);
  opacity: 0;
}
.ranking-list-title-tooltip button {
  position: absolute;
  width: auto;
  background: none;
  right: 11px;
  top: 7px;
  width: 10px;
  height: 10px;
  padding: 5px;
}
.ranking-list-title-tooltip::after {
  content: "";
  width: 0;
  height: 0;
  border-top: 15px solid transparent;
  border-right: 15px solid var(--white-color);
  border-bottom: 15px solid transparent;
  border-left: 15px solid transparent;
  position: absolute;
  left: -25px;
  top: 50%;
  transform: translateY(-50%);
}
.ranking-list-title-tooltip--open {
  opacity: 1;
}
/* 랭킹 아이템 - 상단 고정 */
.ranking-list__current {
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(35, 34, 33, 0.1);
}
/* 랭킹 리스트 - 랭킹 아이템 리스트 Wrapper */
.ranking-list-items-wrapper {
  flex: 1 1 auto;
  overflow: scroll;
  padding: 10px 0;
}
.ranking-list-items-wrapper .ranking-list-item:not(:first-child) {
  margin-top: 10px;
}
.ranking-list-items-wrapper::-webkit-scrollbar {
  display: none;
}

/* 랭킹 아이템 */
.ranking-list-item {
  position: relative;
  width: 100%;
  padding-left: 30px;
  height: 55px;
  box-sizing: border-box;
}
.ranking-list-item__rank {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 600;
  font-size: 13px;
  border-radius: 15px;
  padding: 10px 0;
  background: var(--white-color);
  box-shadow: 0px 4px 12px 0px #bcb5ad33;
  width: 50px;
  text-align: center;
}
.ranking-list-item-info {
  height: 100%;
  display: flex;
  align-items: center;
  background: rgba(188, 181, 173, 0.2);
  border-radius: 20px;
  padding-left: 35px;
  padding-right: 20px;
  box-sizing: border-box;
}
.ranking-list-item-info__medal {
  margin-right: 12px;
  width: 28px;
  height: 28px;
}
.ranking-list-item-info__name {
  font-size: 15px;
  font-weight: 500;
  margin-right: 5px;
  text-wrap: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 55px;
}
.ranking-list-item-info__id {
  font-size: 13px;
  font-weight: 500;
  color: rgba(35, 34, 33, 0.4);
  overflow-x: hidden;
  text-overflow: ellipsis;
  width: 100%;
}
.ranking-list-item-info__point {
  width: 100%;
  font-size: 15px;
  font-weight: 600;
  color: var(--accent-color);
  display: flex;
  align-items: center;
  justify-content: end;
  column-gap: 3px;
}
.ranking-list-item-info__point > img {
  width: 12px;
  height: 11px;
  margin-bottom: 3px;
}
/* 랭킹 아이템 - 활성화 */
.ranking-list-item.active .ranking-list-item__rank {
  color: var(--accent-color);
}
.ranking-list-item.active .ranking-list-item-info {
  background: var(--accent-color);
}
.ranking-list-item.active .ranking-list-item-info__name {
  color: var(--white-color);
}
.ranking-list-item.active .ranking-list-item-info__id {
  color: rgba(255, 255, 255, 0.6);
}
.ranking-list-item.active .ranking-list-item-info__point {
  color: var(--white-color);
}
.ranking-list-item.active .ranking-list-item-info__point > img {
  filter: brightness(0) saturate(100%) invert(100%) sepia(1%) saturate(7498%) hue-rotate(257deg) brightness(100%) contrast(106%);
}
