
/* -------------------------------------
   1. 기본 폰트 및 전역 설정
------------------------------------- */
@font-face {
  font-family: 'IQOS Regular';
  src: url('../font/IQOSHangul-Regular.woff');
}
@font-face {
  font-family: 'IQOS Bold';
  src: url('../font/IQOSHangul-Bold.woff');
}

body, html {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  font-family: "IQOS Regular", sans-serif;
  background-color: #f0f0f0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  touch-action: manipulation;
  user-select: none;
}



/* 비밀번호 입력 모달 */
.passwordModal {
  display: none;
  position: fixed;
  top: 30%;
  left: 50%;
  width: 80vw;
  transform: translateX(-50%);
  background: #fff;
  padding: 20px;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  z-index: 9999;
  text-align: center;
}

.passwordModal input[type="password"] {
  width: 90%;
  padding: 8px;
  margin: 10px 0;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.passwordModal button {
  padding: 10px 20px;
  margin: 0 5px;
  width: 100px;
  height: 50px;
  color: #fff;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.passwordModal .passwordSubmit {
  background: #00d1d2;
}

.passwordModal .passwordCancel {
  background: #666666;
}

.passwordModal button:hover {
}



/* -------------------------------------
   2. 공통 입력 및 버튼
------------------------------------- */
input, button {
  font-family: "IQOS Regular";
  height: 40px;
  padding: 5px;
  border: none;
}
input {
  font-size: 1.2em;
  border: 1px solid #ddd;
}
button {
  font-size: 1.0em;
}
label {font-size: 2.0vw;}
label .DescTxt {font-size: 1.5vw;}

img {width: 100%;}

/* -------------------------------------
   3. 상단 편집 버튼
------------------------------------- */
#btn_edit {
  position: fixed;
  top: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  background: url('../images/edit.svg') center/contain no-repeat;
  cursor: pointer;
  z-index: 999;
}

/* -------------------------------------
   4. 타이틀 영역
------------------------------------- */
.PageTit {
  position: absolute;
  top: 10vh;
  text-align: center;
  z-index: 10;
}
.PageTit .SubTit {
  margin: 0;
  margin-bottom: 20px; 
  padding: 10px 50px;
  font-family: "IQOS Regular";
  /*font-size: 4.5em;*/
	font-size: clamp(1.5rem, 7vw, 4.5rem); /* 중간 ~ 큰 크기 반응형 */
  color: #fff;
  background: #34303D;
  border-radius: 999px;
  display: inline-block;
}
.PageTit .HeadTit {
  margin: 0;
  font-family: "IQOS Bold";
  /*font-size: 5.8em;*/
	font-size: clamp(2rem, 9vw, 5.8rem); /* 헤드타이틀은 더 크고 강조 */
  color: #fff;
  text-shadow: 0 10px 20px rgba(50, 50, 93, 0.25),
               0 5px 15px rgba(0, 0, 0, 0.3);
}

/* -------------------------------------
   5. 설명 영역
------------------------------------- */
.PageDesc {
  position: absolute;
  bottom: 14vh;
  font-family: "IQOS Regular";
  text-align: center;
  /*font-size: 4em;*/
	font-size: clamp(1.2rem, 6.5vw, 4rem); /* 설명은 조금 작고 유연하게 */
  color: #fff;
  text-shadow: 0 10px 20px rgba(50, 50, 93, 0.25),
               0 5px 15px rgba(0, 0, 0, 0.3);
  z-index: 10;
}

/* -------------------------------------
   6. 휠 및 돌리기 버튼
------------------------------------- */
.container {
  width: 95%;
  max-width: 1080px;
  margin: 0 auto;
  text-align: center;
  position: relative;
}
#wheelCanvas {
  border-radius: 50%;
  display: block;
  margin: 0 auto;
  background: #34303d url("../images/bg_wheel.png") center/100% no-repeat;
}
#spinButton {
  position: absolute;
  z-index: 10;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  overflow: hidden;
}
#spinButton img {
  width: 100%;
}

/* -------------------------------------
   7. 설정 패널
------------------------------------- */

.modalBackdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  display: none;
}


#dataEditor {
  position: fixed;
  /*top: 50%;*/
  bottom:3%;
  left: 50%;
  transform: translate(-50%, 0%);
  width: 85vw;
  max-width: 850px;
  max-height: 30vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 8px;
  padding: 40px;
  z-index: 1001;
  display: none;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
}

#dataEditor .dataItemTit {font-size: 3vw;}
#dataEditor .dataItemTit span {font-size: 2.0vw; color: #3498db;}
#dataEditor .dataItemTit span a {text-decoration: none;}

#dataEditor h2 span {font-family: "IQOS Regular"; font-size: 2vw;}


/* -------------------------------------
   8. 상품 리스트 관리
------------------------------------- */
#dataList {
  list-style: none;
  padding: 0;
}

#dataList li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px;
  border-bottom: 0px solid #eee;
}

#dataList .GiftList {
  display: flex;
  align-items: center;
  width: 75%;
  gap: 10px;
}

.GiftList textarea {
  width: 70%;
  height: 3em;
  resize: vertical;
  font-size: 1em;
  font-family: "IQOS Regular", sans-serif;
  padding: 6px;
  white-space: pre-wrap;
  overflow-wrap: break-word;
  box-sizing: border-box;
}

#dataList li input[type="color"] {
  width: 40px;
  height: 40px;
  border: 1px solid #ddd;
}

#dataList li input[type="number"] {
  width: 50px;
  padding: 5px 10px;
}

#dataList li input[type="text"] {
  width: 50%;
  padding: 5px 10px;
}

/* 체크박스 스타일 */
#dataList li input[type="checkbox"].exclude-checkbox {
  width: 20px;
  height: 40px;
  margin-left: 20px;
  margin-right: 10px;
  vertical-align: middle;
  cursor: pointer;
}

/* 체크박스 라벨 (텍스트 포함) */
#dataList li label {
  margin-left: 10px;
  font-size: 1.2em;
  color: #333;
  white-space: nowrap;
  display: flex;
  align-items: center;
}

/* 버튼 스타일 */
#dataList li button {
  width: 10%;
  padding: 5px 10px;
  border-radius: 5px;
  color: white;
  cursor: pointer;
}

#dataList li button.editButton {
  background-color: #3498db;
  margin: 5px;
}

#dataList li button:not(.editButton) {
  background-color: #e74c3c;
}

/* 상품 추가 입력 영역 */
#newItemInput {
  width: 72%;
  padding: 5px 10px;
  margin-bottom: 10px;
  margin-right: 20px;
}

#addItemButton {
  background: #27ae60;
  color: white;
  width: 10%;
  padding: 5px 10px;
  border-radius: 3px;
  cursor: pointer;
}

/* -------------------------------------
   9. 텍스트 설정 컨트롤 (회전 + 글자 크기)
------------------------------------- */
.textSettingsRow {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 10px;
}

.textRotateControl label,
.textSizeControl label {
  font-size: 1.2em;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

#fontSizeInput {
  width: 60px;
}
/* -------------------------------------
   9. 배경 설정
------------------------------------- */
.bgControlBox {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  width: 100%;
  margin-top: 10px;
}

.bgControlBox .SubTit {font-size: 2.0vw; margin-right: 20px;}
.bgControlBox input[type="file"] {
  width: 50%;
}
.bgControlBox input[type="color"] {
  width: 40px;
  height: 40px;
  margin: 0 10px;
  border: 1px solid #ddd;
}
.bgControlBox button {
  padding: 5px 10px;
  border-radius: 3px;
  cursor: pointer;
}
#bgColorApplyButton { background: #34303d; color: #fff; }
#bgApplyButton {margin-left: 20px; background: #34303d; color: #fff; }
#bgRemoveButton {width: 100%; height: 60px; background: #e74c3c; color: #fff; border-radius: 5px; margin-bottom: 10px; text-align: center; cursor: pointer;}

.bgControlBox .FullWidth {width: 100%; margin: 10px 0;}

.presetBgBox {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.preset-bg {
  width: 80px;
  border: 2px solid #ccc;
  border-radius: 4px;
  cursor: pointer;
}
.preset-bg:hover {
  border-color: #34303d;
}

/* -------------------------------------
   10. 텍스트 설정
------------------------------------- */
.textControlBox {
  margin-top: 20px;
}

.textControlBox label {
  display: block;
  margin: 10px 0;
}

.textControlBox input[type="text"],
.textControlBox input[type="color"],
.textControlBox input[type="number"] {
  margin-right: 10px;
  padding: 4px;
}

.textControlBox input[type="text"] {
  width: 50vw;
  border: 1px solid #ddd;
  margin-bottom: 10px;
}

.textControlBox input[type="color"] {
  width: 40px;
  height: 40px;
  padding: 5px;
  border: 1px solid #ddd;
}

.textControlBox textarea {
  width: 50vw;
  min-height: 60px;
  padding: 4px;
  margin-right: 10px;
  margin-bottom: 10px;
  resize: vertical;
  border: 1px solid #ddd;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.4;
}

.textControlBox button {
  margin-top: 10px;
  padding: 6px 12px;
  background: #34303d;
  color: #fff;
  border-radius: 5px;
  cursor: pointer;
}

.textControlBox .TitInput {float: left;}
.textControlBox .TxtSize {width: 100px;}


/* -------------------------------------
   11. 당첨 축하 효과 설정
------------------------------------- */
.effectControlBox {
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.effectControlBox select {
  padding: 6px 10px;
  font-size: 2vw;
  border-radius: 4px;
  border: 1px solid #ccc;
	font-family: "IQOS Regular";
}
.effectControlBox select option {font-family: "IQOS Regular";}


/* -------------------------------------
   12. 전체화면 버튼
------------------------------------- */
.btn_fullscreen {
	margin-top: 40px;
  background: #34303d;
  padding: 20px 10px;
  color: #fff;
  border-radius: 5px;
  margin-bottom: 10px;
  font-size: 1.0em;
	text-align: center;
  cursor: pointer;
}


/* -------------------------------------
   13. 리셋 버튼
------------------------------------- */
.resetButton {background: #ec1c24;
	margin-top: 20px;
  padding: 20px 10px;
  color: #fff;
  border-radius: 5px;
  margin-bottom: 10px;
  font-size: 1.0em;
	text-align: center;
  cursor: pointer;
}

/* -------------------------------------
   14. 설청 창 닫기 버튼
------------------------------------- */
.editorCloseButton {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 60px;
  height: 60px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 2vw;
}
.editorCloseButton:hover {}



/* -------------------------------------
   15. 페이지 하단 DTI
------------------------------------- */
.FooterDTI {position: fixed; bottom: 0; width: 100vw; font-size: 3.2vw; text-align: center; line-height: 10vh; background: #fff;}

/* -------------------------------------
   16. 반응형 대응
------------------------------------- */



@media screen and (min-aspect-ratio: 1/1) { /*화면 비율이 가로(landscape)가 세로(portrait)보다 긴 경우, aspect-ratio가 1보다 큰 경우 .SubTit, .HeadTit, .PageDesc를 숨김*/
  .PageTit,
  .PageDesc {
    display: none;
  }
}

/*@media screen and (width: 1080px) and (min-width: 1080px) and (height: 1920px) {
  .container { width: 95%; }
}

@media screen and (width: 1920px) and (height: 1080px) {
  .container { width: 55%; }
}*/

@media screen and (max-width: 820px) and (max-width: 820px) and (orientation: portrait) {
  .container { width: 85%; margin-top: -3vh;}
  .PageTit {top: 4vh;}
  .PageTit .SubTit {margin-bottom: 10px; font-size: 6vw;}
  .PageTit .HeadTit {font-size: 7vw;}
  .PageDesc {bottom: 12vh; font-size: 3.5vh; text-shadow: 0 0px 5px rgba(50, 50, 93, 0.2), 0 5px 10px rgba(0, 0, 0, 0.4);}
  /*.PageTit .SubTit {padding: 10px 30px; margin-bottom: 10px; font-size: 3.0em;}
  .PageTit .HeadTit {font-size: 4.0em; text-shadow: 0 10px 15px rgba(50, 50, 93, 0.25), 0 5px 10px rgba(0, 0, 0, 0.3);}
  .PageDesc {bottom: 5vh;font-size: 2.2em; text-shadow: 0 10px 15px rgba(50, 50, 93, 0.25), 0 5px 10px rgba(0, 0, 0, 0.3);}*/
}

@media screen and (device-width: 1180px) and (orientation: landscape) {
  .container { width: 70%; }
}

@media screen and (device-width: 768px) and (device-height: 1024px) and (orientation: portrait) {
  .container { width: 85%; margin-top: 10vh;}
	
  .PageTit {top: 7vh;}
	.PageTit .SubTit {margin-bottom: 10px;}
	.PageDesc {bottom: 3vh; text-shadow: 0 0px 5px rgba(50, 50, 93, 0.2), 0 5px 10px rgba(0, 0, 0, 0.4);}
  /*.PageTit .SubTit {padding: 10px 30px; margin-bottom: 10px; font-size: 3.0em;}
  .PageTit .HeadTit {font-size: 4.0em; text-shadow: 0 10px 15px rgba(50, 50, 93, 0.25), 0 5px 10px rgba(0, 0, 0, 0.3);}
  .PageDesc {bottom: 3vh; font-size: 2.2em; text-shadow: 0 10px 15px rgba(50, 50, 93, 0.25), 0 5px 10px rgba(0, 0, 0, 0.3);}*/
}

@media screen and (device-width: 1024px) and (device-height: 768px) and (orientation: landscape) {
  .container { width: 80%; }
}

@media screen and (max-width: 390px) and (orientation: portrait) {
  .container { width: 90%; }
  .bgControlBox { flex-direction: column; align-items: stretch; }
	
  .PageTit {}
	.PageTit .SubTit {padding: 10px 30px;}
  /*.PageTit .SubTit {padding: 10px 30px; margin-bottom: 10px; font-size: 1.5em;}
  .PageTit .HeadTit {font-size: 2.0em; text-shadow: 0 10px 15px rgba(50, 50, 93, 0.25), 0 5px 10px rgba(0, 0, 0, 0.3);}
  .PageDesc {font-size: 1.4em; text-shadow: 0 10px 15px rgba(50, 50, 93, 0.25), 0 5px 10px rgba(0, 0, 0, 0.3);}*/
	
}

@media screen and (max-height: 480px) and (max-height: 500px) and (orientation: landscape) {
  .container { width: 53%; }
}