@charset "UTF-8";

/* Settings 모달 오버레이 */
.settings_modal_overlay {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.5);
	display: flex;
	align-items: center;
	justify-content: center;
	z-index: 9999;
}

/* Settings 모달 박스 */
.settings_modal {
	width: 700px;
	height: 500px;
	background: var(--color-WH);
	border-radius: 16px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

/* 모달 바디 */
.settings_modal_body {
	display: flex;
	flex: 1;
	overflow: hidden;
}

/* 좌측 사이드바 */
.settings_sidebar {
	width: 180px;
	border-right: 1px solid var(--color-G3);
	padding: 12px 8px;
	overflow-y: auto;
	display: flex;
	flex-direction: column;
}

/* 사이드바 내 닫기 버튼 */
.settings_sidebar .btn_close {
	width: 32px;
	height: 32px;
	border: none;
	background: transparent;
	cursor: pointer;
	border-radius: 6px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background-color 0.2s ease;
	margin-bottom: 12px;
	align-self: flex-start;
}

.settings_sidebar .btn_close:hover {
	background: var(--color-G2);
}

.settings_sidebar .btn_close i.icon {
	width: 20px;
	height: 20px;
}

.settings_menu {
	list-style: none;
	padding: 0;
	margin: 0;
}

.settings_menu_item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 6px 10px;
	border-radius: 8px;
	cursor: pointer;
	transition: background-color 0.15s ease;
	font-size: 14px;
	font-weight: 500;
	color: var(--color-BL);
	margin-bottom: 4px;
	height: 30px;
}

.settings_menu_item:hover {
	background: var(--color-G2);
}

.settings_menu_item.active {
	background: var(--color-G2);
	font-weight: 600;
	border-radius: 12px;
}

.settings_menu_item i.icon {
	width: 18px;
	height: 18px;
	flex-shrink: 0;
}

/* 우측 컨텐츠 */
.settings_content {
	flex: 1;
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

/* 스크롤 가능한 컨텐츠 영역 */
.settings_content_scroll {
	flex: 1;
	overflow-y: auto;
	padding: 24px;
}

/* 설정 탭 */
.settings_tab {
	display: none;
}

.settings_tab.active {
	display: flex;
	flex-direction: column;
	height: 100%;
}

.settings_title {
	font-size: 20px;
	font-weight: 700;
	color: var(--color-BL);
	margin: 0 0 24px 0;
}

/* 폼 그룹 */
.form_group {
	margin-top: 15px;
	margin-bottom: 10px;
}

.form_group label {
	display: block;
	font-size: 13px;
	font-weight: 600;
	color: var(--color-BL);
	margin-bottom: 8px;
}

/* 언어 선택 행 (label + select 한 줄) */
.form_group.lang_row {
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.form_group.lang_row label {
	margin-bottom: 0;
	flex-shrink: 0;
}

.form_group.lang_row .custom_select_wrapper {
	position: relative;
	width: 213px;
	flex-shrink: 0;
}

.form_input,
.form_select {
	width: 100%;
	padding: 10px 12px;
	border: 1px solid var(--color-G3);
	border-radius: 8px;
	font-size: 14px;
	color: var(--color-BL);
	background: var(--color-WH);
	transition: border-color 0.2s ease;
}

.form_input:focus,
.form_select:focus {
	outline: none;
	border-color: var(--color-G5);
}

.form_input[readonly] {
	background: var(--color-G2);
	color: var(--color-G6);
	cursor: not-allowed;
}

.form_select {
	cursor: pointer;
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23666' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
	padding-right: 36px;
}

/* 커스텀 언어 선택 드롭다운 스타일 */
.custom_select_button {
	position: relative;
	width: 100%;
	height: 34px;
	padding: 6px 36px 6px 12px;
	border: 1px solid var(--color-G3);
	border-radius: 12px;
	background: var(--color-WH);
	font-size: 14px;
	color: var(--color-BL);
	text-align: left;
	cursor: pointer;
	display: flex;
	align-items: center;
	transition: border-color 0.2s ease;
}

.custom_select_button:hover {
	border-color: var(--color-G5);
}

.custom_select_button .icon.arrow_down {
	position: absolute;
	right: 15px;
	top: 50%;
	transform: translateY(-50%);
	width: 12px;
	height: 12px;
	background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23666' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: center;
	transition: transform 0.2s ease;
}

.custom_select_button.active .icon.arrow_down {
	transform: translateY(-50%) rotate(180deg);
}

.custom_select_dropdown {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	margin-top: 4px;
	background: var(--color-WH);
	border: 1px solid var(--color-G3);
	border-radius: 12px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
	opacity: 0;
	visibility: hidden;
	transform: translateY(-10px);
	transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
	z-index: 1001;
	max-height: 300px;
	overflow-y: auto;
}

.custom_select_dropdown.show {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.custom_select_list {
	list-style: none;
	margin: 0;
	padding: 6px 0;
}

.custom_select_item {
	height: 34px;
	padding: 6px 12px;
	cursor: pointer;
	transition: background-color 0.15s ease;
	font-size: 14px;
	color: var(--color-BL);
	display: flex;
	align-items: center;
	justify-content: space-between;
	border-radius: 12px;
	margin: 0 6px;
}

.custom_select_item:hover {
	background-color: var(--color-G2);
}

.custom_select_item.on {
	background-color: var(--color-G2);
	background-image: url(/common/css/import/icons/check.svg);
	background-repeat: no-repeat;
	background-position: calc(100% - 5px) center;
	font-weight: 600;
}

/* Email 표시 영역 */
.email_display {
	padding: 12px 16px;
	background-color: #F9F9F9;
	border-radius: 8px;
}

.email_text {
	font-size: 14px;
	color: var(--color-BL);
	margin-bottom: 4px;
}

.email_provider {
	font-size: 12px;
	color: #999999;
}

/* Profile Name input 스타일 */
#profileName {
	background-color: var(--color-G2);
	border: 1px solid #E6E6E6;
}

#profileName:focus {
	border-color: #FF6929;
	outline: none;
}

/* Settings 섹션 */
.settings_section {
	margin-bottom: 32px;
}

.section_title {
	font-size: 16px;
	font-weight: 700;
	color: var(--color-BL);
	padding: 0 0 16px 0;
	margin-bottom: 0px;
	border-bottom: 1px solid var(--color-G3);
}

/* Security 아이템 */
.security_item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 0;
}

.security_text {
	font-size: 14px;
	color: var(--color-BL);
}

/* Notification 아이템 */
.notification_item {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	padding: 20px 0;
}

.notification_item:last-child {
	border-bottom: none;
}

.notification_text {
	flex: 1;
	padding-right: 16px;
}

.notification_title {
	font-size: 14px;
	font-weight: 600;
	color: var(--color-BL);
	margin-bottom: 4px;
}

.notification_desc {
	font-size: 13px;
	color: var(--color-G6);
	line-height: 1.5;
}

.notification_link {
	color: var(--color-BL);
	text-decoration: underline;
}

.notification_link:hover {
	text-decoration: none;
}

/* 토글 스위치 */
.toggle_switch {
	position: relative;
	display: inline-block;
	width: 48px;
	height: 28px;
	flex-shrink: 0;
}

.toggle_switch input {
	opacity: 0;
	width: 0;
	height: 0;
}

.toggle_slider {
	position: absolute;
	cursor: pointer;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	background-color: var(--color-G4);
	border-radius: 28px;
	transition: 0.3s;
}

.toggle_slider:before {
	position: absolute;
	content: "";
	height: 22px;
	width: 22px;
	left: 3px;
	bottom: 3px;
	background-color: white;
	border-radius: 50%;
	transition: 0.3s;
}

.toggle_switch input:checked + .toggle_slider {
	background-color: #2196F3;
}

.toggle_switch input:checked + .toggle_slider:before {
	transform: translateX(20px);
}

/* Billing 아이템 */
.billing_item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 0;
}

.billing_item:last-child {
	border-bottom: none;
}

.billing_text {
	flex: 1;
}

.billing_plan,
.billing_cancel,
.billing_label {
	font-size: 14px;
	font-weight: 700;
	color: var(--color-BL);
	margin-bottom: 4px;
}

.billing_cancel_desc,
.billing_value {
	font-size: 13px;
	color: var(--color-G6);
}

/* Settings 푸터 (하단 고정) */
.settings_footer {
	display: flex;
	gap: 12px;
	justify-content: flex-start;
	padding: 16px 24px;
	border-top: 1px solid var(--color-G3);
	background: var(--color-WH);
}

/* 버튼 */
.btn {
	padding: 10px 20px;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	border: none;
	transition: all 0.2s ease;
}

.btn_primary {
	background: #FF6B35;
	color: var(--color-WH);
}

.btn_primary:hover {
	background: #e85a2a;
}

.btn_secondary {
	background: var(--color-WH);
	color: var(--color-BL);
	border: 1px solid var(--color-G3);
}

.btn_secondary:hover {
	background: var(--color-G2);
}

.btn_cancel {
	background: transparent;
	color: var(--color-BL);
	border: 1px solid transparent;
}

.btn_cancel:hover {
	background: var(--color-G2);
}

.btn_danger {
	background: var(--color-BL);
	color: var(--color-WH);
}

.btn_danger:hover {
	background: #1a1a1a;
}



.btn_delete_account:hover {
	background: #1a1a1a;
}

/* 반응형 */
@media (max-width: 768px) {
	.settings_modal {
		width: 90%;
		height: 80vh;
	}

	.settings_sidebar {
		width: 140px;
	}

	.settings_content {
		padding: 16px;
	}
}

/* ===== Invoice 관련 스타일 ===== */

/* Invoice 목록 */
#invoice_list .loading_spinner,
#invoice_list .no_data,
#invoice_list .error_message {
	padding: 20px;
	text-align: center;
	color: #999;
	font-size: 14px;
}

#invoice_list .error_message {
	color: #f44336;
}

.invoice {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 14px;
	font-weight: 700;
	color: var(--color-BL);
	margin-top: 20px;
	
}

.invoice:first-child {
	padding-top: 0;
}

.invoice_content {
	flex: 1;
}

.invoice_info {  
	font-size: 12px;
	color: var(--color-G5);
}

/* Invoice 상세 뷰 */
#invoice_detail_view {
	margin-top: 0;
}

.invoice_detail_header {
	margin-bottom: 16px;
}

.btn_back {
	background: none;
	border: none;
	cursor: pointer;
	padding: 4px;
	display: flex;
	align-items: center;
	color: #333;
}

.btn_back:hover {
	color: #000;
}

.btn_back svg {
	width: 24px;
	height: 24px;
}

/* Invoice 회사 정보 헤더 (PDF용) */
.invoice_company_header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	margin-bottom: 32px;
	padding-bottom: 24px;
	border-bottom: 1px solid #E0E0E0;
}

.invoice_company_info {
	flex: 1;
}

.invoice_main_title {
	font-size: 28px;
	font-weight: 600;
	color: #333;
	margin: 0 0 16px 0;
}

.invoice_company_info .company_name {
	font-size: 14px;
	font-weight: 600;
	color: #333;
	margin: 0 0 4px 0;
}

.invoice_company_info .company_address {
	font-size: 13px;
	font-weight: 400;
	color: #666;
	margin: 0 0 2px 0;
}

.invoice_company_info .company_email {
	font-size: 13px;
	font-weight: 400;
	color: #666;
	margin: 8px 0 0 0;
}

.invoice_logo {
	flex-shrink: 0;
	margin-left: 24px;
}

.invoice_logo img {
	width: 60px;
	height: auto;
}

.invoice_title_section {
	margin-bottom: 24px;
}

.invoice_detail_title {
	font-size: 20px;
	font-weight: 600;
	color: #333;
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
}

.badge_paid {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 29px;
	height: 20px;
	padding: 0 7px;
	border-radius: 2px;
	background-color: #E5FBEE;
	color: #01B574;
	font-size: 10px;
	font-weight: 800;
	line-height: 1;
}

.invoice_date {
	font-size: 12px;
	font-weight : 700;
	color: var(--color-G5);
	margin: 0;
}

.invoice_date span {
	font-weight: 500;
	color: #333;
}

.invoice_details_grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 16px;
	padding-top: 20px;
	margin-bottom: 24px;	
	border-top: 1px solid #e0e0e0;
}

.invoice_detail_item {
	display: flex;
	flex-direction: column;
	font-size: 12px;
	font-weight: 700;
}

.invoice_detail_label {
	color: var(--color-G5);
}

.invoice_detail_value {
	color: var(--color-G7);
}

.invoice_amount_section {
	border-top: 1px solid #e0e0e0;
	margin-bottom: 20px;
	padding-top: 10px;
}

.invoice_amount_row {
	display: flex;
	justify-content: space-between;
	padding-top: 10px;	
	font-size: 12px;
	font-weight : 800;
	color: var(--color-G5);
}

.invoice_amount_row.invoice_total {
	color: var(--color-G7);
}

/* 업그레이드 결제용 추가 스타일 */
.invoice_upgrade_charges {
	margin-bottom: 10px;
	padding-bottom: 10px;
	border-bottom: 1px solid #f0f0f0;
}

.invoice_upgrade_charges .invoice_amount_row {
	padding-top: 8px;
}

.info_icon {
	display: inline-block;
	font-size: 14px;
	color: #888;
	cursor: help;
	margin-left: 4px;
	vertical-align: middle;
}

.prorated_amount {
	/* Prorated charges는 마이너스 금액이므로 녹색으로 표시 (JavaScript에서 동적 설정) */
}

/* ========== PDF 전용 스타일 ========== */
#invoice_pdf_content {
	padding: 20px;
	background: #fff;
}

#invoice_pdf_content .invoice_details_grid {
	border-top: 1px solid #E0E0E0;
	border-bottom: 1px solid #E0E0E0;
	padding: 20px 0;
	margin-bottom: 0;
}

/* 금액 헤더 (예: "$16.50 USD due October 13, 2025") */
.invoice_amount_header {
	font-size: 22px;
	font-weight: 600;
	color: #333;
	padding: 24px 0 16px 0;
}

/* 업그레이드 결제용 상세 금액 (PDF용) */
#invoice_pdf_content .invoice_upgrade_charges {
	border-bottom: none;
	margin-bottom: 0;
	padding-bottom: 0;
}

.invoice_charge_row {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	padding: 12px 0;
	border-bottom: 1px solid #f0f0f0;
}

.invoice_charge_row:last-child {
	border-bottom: none;
}

.charge_info {
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.charge_title {
	font-size: 14px;
	font-weight: 600;
	color: #333;
}

.charge_period {
	font-size: 12px;
	font-weight: 400;
	color: #666;
}

.charge_desc {
	font-size: 12px;
	font-weight: 400;
	color: #888;
}

.charge_amount {
	font-size: 14px;
	font-weight: 600;
	color: #333;
}

.charge_amount.prorated_amount {
	color: #F5803E;
}

/* PDF 금액 섹션 */
#invoice_pdf_content .invoice_amount_section {
	border-top: 1px solid #E0E0E0;
	padding-top: 16px;
	margin-top: 16px;
}

#invoice_pdf_content .invoice_amount_row {
	padding-top: 8px;
}

#invoice_pdf_content .invoice_total span:last-child {
	font-size: 18px;
}

/* Tax 안내 문구 */
.invoice_tax_notice {
	font-size: 11px;
	font-weight: 400;
	color: #888;
	line-height: 1.5;
	margin-top: 24px;
	padding-top: 16px;
	border-top: 1px solid #E0E0E0;
}

.invoice_btn_box {
	border-top: 1px solid #e0e0e0;
	padding-top : 20px;
} 

/* 모바일 대응 */
@media (max-width: 768px) {
	.invoice_detail_header {
		margin-bottom: 12px;
	}

	.invoice_title_section {
		padding-bottom: 12px;
	}

	.invoice_detail_title {
		font-size: 16px;
		font-weight: 800;
	}

	.invoice_details_grid {
		grid-template-columns: 1fr;
	}

	.invoice {
		flex-direction: column;
		align-items: flex-start;
		gap: 12px;
		padding: 16px 0;
	}

	.invoice button {
		width: 100%;
	}
}
