:root {
	/* 컬러 변수 */
	--primary-color: #2563eb;
	--primary-hover: #1d4ed8;
	--accent-color: #36db70;
	--text-accent: #8aaaf3;
	--text-main: #1e293b;
	--text-secondary: #666666;
	--text-tertiary: #999999;
	--text-white: #ffffff;
	--bg-white: #ffffff;
	--bg-light: #f8fafc;
	--disabled: #eeeeee;
	--black: #000000;
	--border-color: #e2e8f0;

	/* Layout */
	--max-width: 1260px;
	--header-height: 80px;

	/* 타이포그래피 변수 */
	--font-h1-size: 48px;
	--font-h1-height: 56px;
	--font-h2-size: 40px;
	--font-h2-height: 48px;
	--font-h3-size: 32px;
	--font-h3-height: 44px;
	--font-h4-size: 28px;
	--font-h4-height: 38px;

	--font-section-title-bl-size: 64px;
	--font-section-title-bl-height: 80px;

	--font-body-l-size: 26px;
	--font-body-l-height: 38px;
	--font-body-m-size: 22px;
	--font-body-m-height: 36px;
	--font-body-s-size: 18px;
	--font-body-s-height: 28px;

	--font-btn-m-size: 24px;
	--font-btn-m-height: 38px;
	--font-btn-s-size: 20px;
	--font-btn-s-height: 20px;
}

/* ==========================================
   반응형 CSS 변수 오버라이드
   - 기존 변수 이름 그대로 사용
   - 화면 크기에 따라 자동 조정
   - 모든 유틸리티 클래스 자동 적용
========================================== */

/* 태블릿 (768px ~ 1023px) */
@media (max-width: 1023px) {
	:root {
		/* Layout */
		--max-width: 728px;
		--header-height: 70px;

		/* Typography - 약 80% 크기 */
		--font-section-title-bl-size: 52px; /* 64px → 52px */
		--font-section-title-bl-height: 64px; /* 80px → 64px */

		--font-h1-size: 40px; /* 48px → 40px */
		--font-h1-height: 48px; /* 56px → 48px */

		--font-h2-size: 32px; /* 40px → 32px */
		--font-h2-height: 40px; /* 48px → 40px */

		--font-h3-size: 28px; /* 32px → 28px */
		--font-h3-height: 36px; /* 44px → 36px */

		--font-h4-size: 24px; /* 28px → 24px */
		--font-h4-height: 32px; /* 38px → 32px */

		--font-body-l-size: 20px; /* 26px → 20px */
		--font-body-l-height: 30px; /* 38px → 30px */

		--font-body-m-size: 18px; /* 22px → 18px */
		--font-body-m-height: 28px; /* 36px → 28px */

		--font-body-s-size: 16px; /* 18px → 16px */
		--font-body-s-height: 24px; /* 28px → 24px */

		--font-btn-m-size: 20px; /* 24px → 20px */
		--font-btn-m-height: 32px; /* 38px → 32px */

		--font-btn-s-size: 18px; /* 20px → 18px */
		--font-btn-s-height: 18px; /* 20px → 18px */
	}
}

/* 모바일 (~767px) */
@media (max-width: 767px) {
	:root {
		/* Layout */
		--max-width: 100%;
		--header-height: 60px;

		/* Typography - 약 60-70% 크기 */
		--font-section-title-bl-size: 36px; /* 64px → 36px */
		--font-section-title-bl-height: 44px; /* 80px → 44px */

		--font-h1-size: 32px; /* 48px → 32px */
		--font-h1-height: 40px; /* 56px → 40px */

		--font-h2-size: 28px; /* 40px → 28px */
		--font-h2-height: 36px; /* 48px → 36px */

		--font-h3-size: 24px; /* 32px → 24px */
		--font-h3-height: 32px; /* 44px → 32px */

		--font-h4-size: 20px; /* 28px → 20px */
		--font-h4-height: 28px; /* 38px → 28px */

		--font-body-l-size: 18px; /* 26px → 18px */
		--font-body-l-height: 28px; /* 38px → 28px */

		--font-body-m-size: 16px; /* 22px → 16px */
		--font-body-m-height: 24px; /* 36px → 24px */

		--font-body-s-size: 14px; /* 18px → 14px */
		--font-body-s-height: 22px; /* 28px → 22px */

		--font-btn-m-size: 18px; /* 24px → 18px */
		--font-btn-m-height: 28px; /* 38px → 28px */

		--font-btn-s-size: 16px; /* 20px → 16px */
		--font-btn-s-height: 16px; /* 20px → 16px */
	}
}

button,
a {
	-webkit-tap-highlight-color: transparent; /* 모바일 탭 하이라이트 제거 */
}

/* 타이포그래피 유틸리티 */
.text-section-title-bl {
	font-size: var(--font-section-title-bl-size);
	line-height: var(--font-section-title-bl-height);
	font-weight: 800;
}
.text-h1 {
	font-size: var(--font-h1-size);
	line-height: var(--font-h1-height);
	font-weight: 700;
}
.text-h2 {
	font-size: var(--font-h2-size);
	line-height: var(--font-h2-height);
	font-weight: 700;
}
.text-h3 {
	font-size: var(--font-h3-size);
	line-height: var(--font-h3-height);
	font-weight: 600;
}
.text-h4 {
	font-size: var(--font-h4-size);
	line-height: var(--font-h4-height);
	font-weight: 600;
}

.text-body-l {
	font-size: var(--font-body-l-size);
	line-height: var(--font-body-l-height);
	font-weight: 400;
}
.text-body-m {
	font-size: var(--font-body-m-size);
	line-height: var(--font-body-m-height);
	font-weight: 500;
}
.text-body-s {
	font-size: var(--font-body-s-size);
	line-height: var(--font-body-s-height);
	font-weight: 400;
}

.text-btn-m {
	font-size: var(--font-btn-m-size);
	line-height: var(--font-btn-m-height);
	font-weight: 600;
}
.text-btn-s {
	font-size: var(--font-btn-s-size);
	line-height: var(--font-btn-s-height);
	font-weight: 700;
}

/* 초기화 및 기본 스타일 */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	margin: 0;
	padding: 0;
	font-family:
		'Pretendard Variable',
		Pretendard,
		-apple-system,
		BlinkMacSystemFont,
		system-ui,
		sans-serif;
	color: var(--text-main);
	line-height: 1.6;
	background-color: var(--bg-white);
	word-break: keep-all;
}

.page-wrapper {
	display: flex;
	flex-direction: column;
	width: 100%;
	align-items: center;
	background: white;
	position: relative;
}

a {
	text-decoration: none;
	color: inherit;
}

ul {
	list-style: none;
}

/* 유틸리티 클래스 */
.container {
	max-width: var(--max-width);
	width: 100%;
	margin: 0 auto;
	padding: 0 30px;
	position: relative; /* Ensure relative positioning for absolute children */
	height: 100%; /* Often needed for flex children */
}

@media (max-width: 767px) {
	.container {
		padding: 0 32px;
	}
}

.flex {
	display: flex;
}
.justify-between {
	justify-content: space-between;
}
.items-center {
	align-items: center;
}
.gap-4 {
	gap: 1rem;
}
.gap-8 {
	gap: 2rem;
}

/* 공통 섹션 스타일 */
section {
	width: 100%;
}

.cta-section {
	text-align: center;
	background: var(--bg-light);
}

/* 텍스트 오브젝트 섹션 - 무한스크롤 */
.section-text-objects {
	width: 100%;
	padding: 60px 0;
	position: relative;
	overflow: hidden;
	background: white;
	display: flex;
	align-items: center;
	user-select: none;
}

.text-objects-track {
	display: flex;
	white-space: nowrap;
	animation: scroll-left 30s linear infinite;
}

.text-objects-content {
	display: flex;
	align-items: center;
	gap: 40px;
	margin-left: 40px;
}

.text-objects-item {
	flex-shrink: 0;
}

.text-objects-item.text {
	color: var(--disabled, #eeeeee);
	font-size: 64px;
	font-weight: 800;
}

.text-objects-item.logo {
	height: 45px;
	width: auto;
	object-fit: contain;
}

@keyframes scroll-left {
	0% {
		transform: translateX(0);
	}
	100% {
		transform: translateX(-50%);
	}
}

/* ==========================================
   텍스트 오브젝트 섹션 반응형
========================================== */

/* 태블릿 (1023px 이하) */
@media (max-width: 1023px) {
	.section-text-objects {
		padding: 40px 0;
	}

	.text-objects-item.text {
		font-size: 48px;
	}

	.text-objects-item.logo {
		height: 34px;
	}

	.text-objects-content {
		gap: 30px;
		margin-left: 30px;
	}
}

/* 모바일 (767px 이하) */
@media (max-width: 767px) {
	.section-text-objects {
		padding: 30px 0;
	}

	.text-objects-item.text {
		font-size: 32px;
	}

	.text-objects-item.logo {
		height: 22px;
	}

	.text-objects-content {
		gap: 20px;
		margin-left: 20px;
	}
}

/* 줄바꿈 유틸리티 (태블릿 이하에서만 줄바꿈) */
.newline-tablet {
	display: none;
}

@media (max-width: 1023px) {
	.newline-tablet {
		display: block;
	}
}

/* =========================================
   공통 버튼 컴포넌트
   - Hero 및 각 페이지 CTA 버튼에 공통 사용
   ========================================= */
.btn {
	text-decoration: none;
	padding: 18px 32px;
	border-radius: 50px;
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 10px;
	cursor: pointer;
	width: fit-content;
	min-width: 230px;
	transition: all 0.2s ease;
	box-sizing: border-box; /* 패딩 포함 너비 계산 */
}

/* 호버 효과 */
.btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn:active {
	transform: translateY(0);
}

/* 기본 스타일 (파란색 배경) */
.btn-primary {
	background: var(--primary-color);
	color: white; /* 텍스트 색상 명시 */
	border: none;
}

.btn-primary svg path {
	stroke: white; /* 아이콘 색상 */
}

/* 보조 스타일 (흰색 배경) */
.btn-secondary {
	background: white;
	color: var(--primary-color); /* 텍스트 파란색 예상 */
	border: 1px solid #e5e7eb; /* 선택 사항: 경계선 */
}

.btn-secondary svg path {
	stroke: var(--primary-color);
}

/* 태블릿 및 모바일 반응형 */
@media (max-width: 1023px) {
	.btn {
		padding: 16px 30px !important;
	}
}
@media (max-width: 767px) {
	.btn {
		padding: 14px 22px !important;
		min-width: 210px;
	}
}

/* ==========================================
   서브페이지 공통 스타일
   - 헤더, CTA (Order, Product, Stats 페이지 공유)
   ========================================== */
.subpage-header-section {
	width: 100%;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	padding: 41px 0;
	background: white;
}

.subpage-header-content {
	display: flex;
	align-items: center;
	gap: 30px;
}

.subpage-header-title {
	color: var(--text-main);
	font-size: var(--font-h2-size);
	font-weight: 700;
	line-height: var(--font-h2-height);
	margin-bottom: 0;
}

.subpage-header-divider {
	width: 1px;
	height: 28px;
	background-color: var(--text-tertiary);
}

.subpage-header-current {
	color: var(--text-main);
	font-size: var(--font-h2-size);
	font-weight: 300;
	line-height: var(--font-h2-height);
	margin-bottom: 0;
}

.subpage-cta-section {
	position: relative;
	width: 100%;
	height: 480px;
	display: flex;
	justify-content: center;
	align-items: center;
	background-size: cover;
	background-position: center;
	overflow: hidden;
	padding: 130px 0 100px 0;
}

/* 서브페이지 헤더/CTA 반응형 */
@media (max-width: 1023px) {
	.subpage-header-section {
		padding: 20px 0;
	}
	.subpage-cta-section {
		height: auto;
		padding: 100px 0;
	}
}

@media (max-width: 767px) {
	.subpage-header-section {
		padding: 15px 0;
	}
	.subpage-cta-section {
		padding: 80px 0;
	}
}

/* ==========================================
   스크롤 애니메이션 (Scroll Interactions)
   - Fade In Up 효과
   ========================================== */

/* 기본 상태: 투명하고 아래로 내려가 있음 */
.scroll-animate {
	opacity: 0;
	transform: translateY(30px);
}

/* 애니메이션 정의 */
@keyframes fadeInUp {
	0% {
		opacity: 0;
		transform: translateY(30px);
	}
	100% {
		opacity: 1;
		transform: translateY(0);
	}
}

/* 활성화 클래스 (JS에서 추가) */
.scroll-animate.scrolled-in {
	opacity: 1; /* Fallback */
	animation: fadeInUp 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

/* 딜레이 유틸리티 */
.delay-100 {
	animation-delay: 0.1s;
}
.delay-200 {
	animation-delay: 0.2s;
}
.delay-300 {
	animation-delay: 0.3s;
}
.delay-400 {
	animation-delay: 0.4s;
}
.delay-500 {
	animation-delay: 0.5s;
}
