.image-template-container {
    position: absolute;
    left: -9999px;
    top: 0;
    width: 900px;
    background-color: #2c2f33;
    color: #e0e0e0;
    /* [수정] 기본 폰트 적용 */
    font-family: 'DnfTemperedBlade', sans-serif;
    font-weight: 300;
    padding: 24px;
    box-sizing: border-box;
}

.template-header {
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 1px solid #4f545c;
    margin-bottom: 20px;
}
.template-header .build-name {
    /* [수정] 제목 폰트 적용 */
    font-family: 'Isamanru', sans-serif;
    font-weight: 700;
    font-size: 28px;
    margin-bottom: 10px;
}
.template-header .author-name {
    font-size: 18px;
    color: #aaa;
}

.template-main {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.template-portrait-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
}
.template-portrait {
    width: 100%;
    height: auto;
}

.template-content-right {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.template-section h4 {
    /* [수정] 부제목 폰트 적용 */
    font-family: 'MuseumCulturalFoundationClassic', sans-serif;
    font-weight: 500;
    font-size: 16px;
    color: #00aaff;
    margin: 0 0 5px 0;
    padding-bottom: 5px;
}

.template-section:not(:last-child) {
    border-bottom: 1px solid #4f545c;
    padding-bottom: 15px;
}

.template-starting-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.template-memory-essence-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.template-memory-group {
    display: flex;
    flex-direction: column;
    gap: 0; /* 간격 제거 */
}

.template-memory-group .template-item-box {
    grid-column: 1 / -1; /* Full width */
}

/* [수정] 정수 목록 상단에 간격 추가 */
.template-essence-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-left: 25px;
    margin-top: 4px; /* 기억 아이템과의 간격 */
}

.template-item-box {
    display: flex;
    align-items: center;
    gap: 10px;
    background-color: #23272a;
    padding: 4px 12px;
    border-radius: 5px;
    font-size: 14px;
    min-height: 40px;
}
.template-item-box img, .template-item-box .item-icon-wrapper {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}
.template-item-box .item-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.template-item-box.label {
    background-color: transparent;
    color: #00aaff;
    font-weight: bold;
}

.template-footer {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #4f545c;
    position: relative;
}
.template-footer h4 {
    /* [수정] 부제목 폰트 적용 */
    font-family: 'MuseumCulturalFoundationClassic', sans-serif;
    font-weight: 500;
    font-size: 16px;
    color: #00aaff;
    margin: 0 0 10px 0;
}
.template-constellations {
    display: grid;
    grid-template-columns: repeat(9, 1fr);
    gap: 8px;
    padding: 0 10px;
}
.template-constellation-slot {
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    border: 1px solid #555;
    display: flex;
    align-items: center;
    justify-content: center;
}
/* [수정] img 태그 크기 조절 */
.template-constellation-slot img {
    width: 65%;
    height: 65%;
}
.template-site-url {
    position: absolute;
    bottom: 10;
    right: 0;
    font-size: 12px;
    color: #777;
}

/* [수정] 이미지 템플릿용 하이라이트 스타일 선택자 구체화 */
.template-item-box.template-highlight-dejavu,
.template-constellation-slot.template-highlight-dejavu {
    border: 2px solid #e67e22;
}
.template-item-box.template-highlight-core,
.template-constellation-slot.template-highlight-core {
    border: 2px solid #f1c40f;
}

.template-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.template-legend {
    display: flex;
    gap: 15px;
    font-size: 13px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.legend-color-box {
    width: 13px;
    height: 13px;
    display: inline-block;
}

.legend-color-box.dejavu {
    border: 2px solid #e67e22;
    border-radius: 4px;
}
.legend-color-box.core {
    border: 2px solid #f1c40f;
    border-radius: 4px;
}