/* 기본 바디 설정 및 전체 레이아웃 */
body {
  font-family: 'Pretendard Variable', 'Pretendard', '맑은 고딕', '돋움', Dotum, sans-serif;
  background: #f5f5f7;
  margin: 0;
  padding-bottom: 120px;
  padding: 10px 20px 0 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  color: #1d1d1f;
  min-height: 100vh;
}

/* 상단 고정 메뉴 스타일 */
.top-menu {
  top: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  padding: 8px 0;
}

.tab-menu {
  list-style: none;
  display: flex;
  gap: 24px;
  margin: 0;
  padding: 0;
  font-weight: 600;
  font-size: 16px;
}

.tab-item {
  cursor: pointer;
  padding-bottom: 8px;
  border-bottom: 3px solid transparent;
  transition: border-color 0.3s ease, color 0.3s ease;
  color: #555;
}

.tab-item:hover {
  color: #0071e3;
}

.tab-item.active {
  border-color: #0071e3;
  color: #0071e3;
}

/* 제목 스타일 */
h1 {
  font-weight: 600;
  margin: 10px 0 20px 0;
  font-weight: bold;
  background: linear-gradient(270deg, #ff6ec4, #7873f5, #4ade80, #ff6ec4);
  background-size: 600% 600%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: gradientMove 60s linear infinite;
}

@keyframes gradientMove {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 600% 50%;
  }
}


/* 텍스트 입력 필드 스타일 */
input[type="text"] {
  width: 300px;
  padding: 12px 15px;
  border-radius: 12px;
  border: 1.5px solid #d2d2d7;
  font-size: 16px;
  outline-offset: 2px;
  transition: border-color 0.3s ease, box-shadow 0.4s ease;
}

/* 텍스트 입력 필드 - 포커스 시 강조 효과 */
input[type="text"]:focus {
  border-color: #0071e3;
  box-shadow: 0 0 8px 2px rgba(0, 113, 227, 0.6);
}

/* 레이블 스타일 (입력 필드 위 텍스트) */
label {
  margin-top: 20px;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 14px;
}

/* 슬라이더 (range 타입 입력) 기본 스타일 */
input[type="range"] {
  width: 300px;
  -webkit-appearance: none;
  height: 6px;
  border-radius: 10px;
  background: #d2d2d7;
  outline: none;
  cursor: pointer;
  transition: background 0.3s ease;
}

/* 슬라이더 호버 시 배경 색상 변화 */
input[type="range"]:hover {
  background: #a8c5f7;
}

/* 슬라이더 썸(thumb) 스타일 - 웹킷 브라우저용 */
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #0071e3;
  cursor: pointer;
  border: none;
  box-shadow: 0 0 6px rgba(0, 113, 227, 0.7);
  transition: background-color 0.3s ease;
}

/* 슬라이더 썸 클릭 활성화 시 색상 변화 */
input[type="range"]:active::-webkit-slider-thumb {
  background: #005bb5;
}

/* 바코드 컨테이너 스타일 */
.barcode-container {
  margin-top: 40px;
  background: #f0f0f5;
  padding: 30px;
  border-radius: 24px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 350px;
  min-height: 350px;
}

/* SVG 요소가 블록 레벨 요소처럼 보이도록 설정 */
svg {
  display: block;
}

/* 저장 버튼 그룹 컨테이너 */
#saveButtons {
  margin-top: 40px;
}

/* 저장 버튼 기본 스타일 */
#saveButtons button {
  padding: 8px 16px;
  margin-right: 12px;
  background: linear-gradient(90deg, #0071e3, #005bb5);
  border: none;
  border-radius: 12px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: background-position 0.5s ease;
  background-size: 200% 100%;
  background-position: 0% 0%;
}

/* 저장 버튼 호버 시 그라데이션 움직임 효과 */
#saveButtons button:hover {
  background-position: 100% 0%;
}

/* 푸터 (페이지 하단) */
footer {
  flex-shrink: 0;
  margin-top: 20px;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 15px 20px;
  text-align: center;
  font-size: 13px;
  color: #666;
  font-weight: 400;
  line-height: 1.4;
}

/* 푸터 내부 링크 스타일 */
footer a {
  color: #0071e3;
  text-decoration: none;
}

/* 푸터 링크 호버 시 밑줄 효과 */
footer a:hover {
  text-decoration: underline;
}


/* DataMatrix 바코드 애니메이션 정의 */
@keyframes fadeScaleIn {
  0% {
    opacity: 0;
    transform: scale(0.9);
  }
  70% {
    opacity: 1;
    transform: scale(0.99);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

/* 애니메이션 적용 클래스 */
.animated-barcode {
  animation: fadeScaleIn 0.3s ease forwards;
}

