@charset "UTF-8";

ul {
	list-style: none;
	padding: 0;
}

.container li {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 0.75rem;
	background: #f1f2f6;
	padding: 0.75rem;
	border-radius: 6px;
}

.task-entry {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 1rem;
}

.action-btn {
	font-size: 0.9rem;
	margin-left: 0.5rem;
	vertical-align: middle;
}

.sub-category-title {
	font-weight: bold;
	font-size: 1.05rem;
	margin-top: 1.5rem;
	margin-bottom: 0.5rem;
	color: #636e72;
}

.icon-btn {
        background: none;
        border: none;
        font-size: 1rem;
        cursor: pointer;
        padding: 0 !important;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 24px;
        height: 24px;
        border-radius: 50%; /* 원형 배경 */
        transition: background-color 0.2s;
}

.category-header {
        display: flex;
        align-items: center;
        gap: 0.25rem;
}

.category-header .sub-category-title {
        margin: 0;
        flex-grow: 1;
}

.category-header .move-up,
.category-header .move-down {
        margin-left: 0.25rem;
}

.move-up, .move-down {
        color: #888;
        width: 20px;
        height: 20px;
        font-size: 0.8rem;
        opacity: 0.7;
}

.icon-btn:hover {
	background-color: #e0e0e0; /* 호버 시 배경 색상 */
}

.red {
	color: #d63031;
}

.green {
	color: green;
}

.blue {
	color: #1e88e5;
}

/* 서브 체크박스 스타일 */
.sub-tasks {
	margin-top: 0.5rem;
	padding-left: 2rem;
	display: flex; /* 가로 배치를 위해 추가 */
	gap: 0.5rem; /* 체크박스 간 간격 */
	align-items: center; /* 세로 중앙 정렬 */
}

.sub-task-item {
	display: inline-block; /* 한 줄로 배치 */
}

/* 체크박스 간격 조정 */
.sub-task-item input[type="checkbox"] {
	margin: 0; /* 기존 margin-right 제거 */
}

/* 다크모드 스타일 */
.dark-mode .container li {
	background: #3a3a3a;
}

body.dark-mode .task-entry {
	background: #3a3a3a;
}

body.dark-mode .sub-category-title {
	color: #e0e0e0;
}

body.dark-mode .icon-btn:hover {
	background-color: #546e7a;
}

body.dark-mode .task-text {
	color: #e0e0e0;
}

body.dark-mode .task-text:hover {
	color: #81d4fa;
}

body.dark-mode .action-btn#save-btn {
	background-color: #3a3a3a;
	color: #e0e0e0;
}

body.dark-mode .action-btn#save-btn:hover {
	background-color: #546e7a;
}

body.dark-mode .save-notice {
	color: #ff6b6b;
}

.character-list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}
.character-controls {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.character-controls button {
  font-family: 'mabinogi_classic';
  background-color: var(--button-bg);
  color: var(--button-text);
  border: none;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9rem;
}
.character-controls button:hover {
  background-color: var(--button-hover-bg);
}
.character-card {
  position: relative;
  width: 180px;
  background-color: var(--container-bg);
  border: 1px solid var(--input-border);
  border-radius: 8px;
  padding: 1rem;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  transition: box-shadow 0.2s, border-color 0.2s;
}

.character-card.selected {
  border: 2px solid var(--button-bg);
  box-shadow: 0 0 0 3px var(--button-hover-bg);
}

.char-delete-form {
  position: absolute;
  top: 0.4rem;
  right: 0.4rem;
}

.char-delete-btn {
	position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  background: none;
  border: none;
  font-size: 1.1rem;
  color: #888;
  cursor: pointer;
  padding: 0;
}

.char-delete-btn:hover {
  color: #d63031;
}

.char-header {
  font-family: 'mabinogi_classic';
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 1rem;
  font-weight: bold;
  font-size: 1.05rem;
  color: var(--text-color);
}

.char-job {
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.main-badge {
  background-color: var(--button-hover-bg);
  color: var(--button-text);
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  line-height: 1;
}

.not-main-badge {
  color: var(--button-text);
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  line-height: 1;
  background: var(--nav-bg);
}

.select-btn {
  background-color: var(--button-hover-bg);
  color: var(--text-color);
  border: none;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  cursor: pointer;
}

.select-btn:hover {
  background-color: var(--button-bg);
  color: var(--button-text);
}
.progress-box {
  text-align: left;
  font-size: 0.85rem;
  color: var(--text-color);
}

.progress-line {
  display: flex;
  justify-content: space-between;
  margin-top: 0.25rem;
}

.progress-label {
  font-weight: bold;
  color: var(--text-color);
}

.progress-value {
  font-weight: bold;
  color: var(--button-bg);
}

.progress-value.low {
  color: #e74c3c; /* 빨강 */
}
.progress-value.medium {
  color: #e67e22; /* 주황 */
}
.progress-value.high {
  color: #27ae60; /* 초록 */
}

@media (max-width: 600px) {
	.character-list {
	  display: flex;
	  flex-wrap: nowrap;
	  overflow-x: auto; /* 필요 시 스크롤도 가능 */
	}
  .character-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0.75rem;
    min-height: auto;
    font-size: 0.9rem;
    position: relative;
    cursor: pointer;
    border-radius: 6px;
  }

  .char-header {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start; /* 왼쪽 정렬 */
    gap: 0.4rem;
    margin-bottom: 0.4rem;
    font-size: 1rem;
    padding-right: 2rem; /* X 버튼 공간 확보 */
  }

  .char-name {
    font-weight: bold;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-shrink: 0;
    max-width: 10ch;
  }

  .main-badge {
    background-color: var(--button-hover-bg);
    color: var(--button-text);
    font-size: 0.65rem;
    padding: 0.15rem 0.4rem;
    border-radius: 999px;
    line-height: 1;
    flex-shrink: 0;
  }

  .char-job {
    font-size: 0.8rem;
    margin-bottom: 0.4rem;
    color: var(--text-color);
  }

  .char-delete-form {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    z-index: 1;
  }

  .progress-box {
    display: flex;
    flex-direction: row;
    gap: 0.75rem;
    font-size: 0.85rem;
    width: 100%;
    justify-content: flex-start;
	flex-wrap: wrap;
  }

  .progress-line {
    margin: 0;
    display: flex;
    gap: 0.25rem;
    align-items: center;
  }

  .progress-label {
    font-weight: bold;
    width: max-content;
    color: var(--text-color);
  }

  .progress-value {
    font-weight: normal;
    color: var(--button-bg);
  }

  .select-btn {
    display: none;
  }
}