﻿:root {
	--brand-50: #eef3f9;
	--brand-100: #e0e8f2;
	--brand-200: #c5d3e5;
	--brand-300: #9fb5d0;
	--brand-400: #577cab;
	--brand-500: #496a93;
	--brand-600: #3e5878;
	--brand-700: #334964;
	--on-brand: #ffffff;

	--ink-900: #1c1d1f;
	--ink-800: #2c2e31;
	--ink-700: #44474b;
	--ink-600: #62656a;
	--ink-500: #84878c;
	--ink-400: #a8abaf;
	--ink-300: #d2d4d7;
	--ink-200: #e6e7ea;
	--ink-100: #f1f2f4;
	--ink-50: #f7f8f9;

	--bg: #ffffff;
	--bg-soft: #f7f8f9;
	--bg-cream: #f3f6fa;
	--surface: #ffffff;
	--border: rgba(0, 0, 0, 0.08);

	--radius-sm: 8px;
	--radius-md: 14px;
	--radius-lg: 20px;
	--radius-xl: 24px;

	--shadow-sm: 0 2px 6px rgba(20, 20, 20, 0.05);
	--shadow-md: 0 8px 24px rgba(20, 20, 20, 0.07);
	--shadow-lg: 0 20px 60px rgba(20, 20, 20, 0.1);
	--shadow-brand: 0 14px 32px rgba(87, 124, 171, 0.3);
}

html[data-theme="dark"] {
	--ink-900: #f4f5f7;
	--ink-800: #e7e8ea;
	--ink-700: #c8cacf;
	--ink-600: #9da0a6;
	--ink-500: #7c7f85;
	--ink-400: #5d6066;
	--ink-300: #3a3d42;
	--ink-200: #2a2c30;
	--ink-100: #202225;
	--ink-50: #181a1d;

	--bg: #0f1114;
	--bg-soft: #16181c;
	--bg-cream: #1a1c1f;
	--surface: #1a1c1f;
	--border: rgba(255, 255, 255, 0.08);

	--brand-50: #202b3a;
	--brand-100: #26374d;
	--brand-200: #3e5878;
	--brand-300: #577cab;
	--brand-500: #9fb5d0;
	--brand-600: #c5d3e5;
	--brand-700: #e0e8f2;
}

*,
*::before,
*::after {
	box-sizing: border-box;
}
html {
	scroll-behavior: smooth;
}
body {
	margin: 0;
	font-family:
		"Pretendard Variable",
		"Pretendard",
		-apple-system,
		BlinkMacSystemFont,
		system-ui,
		"Apple SD Gothic Neo",
		"Malgun Gothic",
		sans-serif;
	color: var(--ink-900);
	background: var(--bg);
	transition:
		background 0.25s ease,
		color 0.25s ease;
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
}

a {
	color: inherit;
	text-decoration: none;
}
button {
	font: inherit;
	cursor: pointer;
	border: none;
	background: none;
	color: inherit;
}
img {
	max-width: 100%;
	display: block;
}

.container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 24px;
}

/* ────── Header ────── */
.header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: color-mix(in srgb, var(--bg) 88%, transparent);
	backdrop-filter: saturate(140%) blur(14px);
	-webkit-backdrop-filter: saturate(140%) blur(14px);
	border-bottom: 1px solid var(--border);
}
.header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	height: 92px;
	gap: 24px;
}
.logo {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-shrink: 0;
}
.logo-text {
	height: 32px;
	width: auto;
	transition: filter 0.25s;
}
html[data-theme="dark"] .logo-text {
	filter: brightness(0) invert(1);
	opacity: 0.95;
}

.nav {
	display: flex;
	gap: 6px;
	align-items: center;
}
.nav-item {
	position: relative;
}
.nav-item > a,
.nav-item > button {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 12px 18px;
	border-radius: 10px;
	font-size: 16px;
	font-weight: 600;
	color: var(--ink-800);
	transition:
		background 0.15s,
		color 0.15s;
}
.nav-item:hover > a,
.nav-item:hover > button {
	background: var(--ink-100);
	color: var(--ink-900);
}
.nav-item .chev {
	width: 10px;
	height: 10px;
	transition: transform 0.2s;
}
.nav-item:hover .chev {
	transform: rotate(180deg);
}

.submenu {
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%) translateY(-4px);
	background: var(--surface);
	border-radius: 18px;
	box-shadow: var(--shadow-lg);
	border: 1px solid var(--border);
	padding: 12px;
	margin-top: 8px;
	min-width: 300px;
	opacity: 0;
	pointer-events: none;
	transition:
		opacity 0.2s,
		transform 0.2s;
}
.submenu::before {
	content: "";
	position: absolute;
	top: -12px;
	left: 0;
	right: 0;
	height: 12px;
}
.nav-item {
	padding-bottom: 4px;
}
.nav-item:hover .submenu {
	opacity: 1;
	pointer-events: auto;
	transform: translateX(-50%) translateY(0);
}
.submenu-grid {
	display: grid;
	gap: 2px;
}
.submenu-item {
	display: grid;
	grid-template-columns: 36px 1fr;
	gap: 12px;
	align-items: center;
	padding: 12px 14px;
	border-radius: 12px;
	transition: background 0.15s;
}
.submenu-item:hover {
	background: var(--ink-100);
}
.submenu-icon {
	width: 36px;
	height: 36px;
	border-radius: 10px;
	background: var(--bg);
	border: 1px solid var(--border);
	color: var(--ink-700);
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	transition:
		background 0.15s,
		color 0.15s,
		border-color 0.15s;
}
.submenu-item:hover .submenu-icon {
	background: var(--brand-50);
	border-color: var(--brand-200);
	color: var(--brand-700);
}
.submenu-icon svg {
	width: 18px;
	height: 18px;
	display: block;
}
.submenu-text-title {
	display: block;
	font-size: 15px;
	font-weight: 700;
	color: var(--ink-900);
	line-height: 1.3;
	margin-bottom: 4px;
}
.submenu-text-desc {
	display: block;
	font-size: 12.5px;
	color: var(--ink-500);
	line-height: 1.4;
}

.header-actions {
	display: flex;
	align-items: center;
	gap: 8px;
}
.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 10px 18px;
	border-radius: 10px;
	font-weight: 600;
	font-size: 14px;
	transition:
		transform 0.12s ease,
		box-shadow 0.15s,
		background 0.15s;
	white-space: nowrap;
}
.btn-ghost {
	color: var(--ink-700);
}
.btn-ghost:hover {
	background: var(--ink-100);
	color: var(--ink-900);
}
.btn-outline {
	border: 1.5px solid var(--ink-900);
	color: var(--ink-900);
}
.btn-outline:hover {
	background: var(--ink-900);
	color: var(--bg);
}
.btn-primary {
	background: var(--brand-400);
	color: var(--on-brand);
	box-shadow: 0 6px 18px rgba(87, 124, 171, 0.35);
}
.btn-primary:hover {
	transform: translateY(-1px);
	box-shadow: 0 10px 24px rgba(87, 124, 171, 0.45);
}
.btn-dark {
	background: var(--ink-900);
	color: var(--bg);
}
.btn-dark:hover {
	background: var(--ink-800);
	transform: translateY(-1px);
}

.theme-toggle {
	width: 40px;
	height: 40px;
	border-radius: 10px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--ink-700);
	transition:
		background 0.15s,
		color 0.15s,
		transform 0.3s;
}
.theme-toggle:hover {
	background: var(--ink-100);
	color: var(--ink-900);
}
.theme-toggle svg {
	width: 20px;
	height: 20px;
}
.theme-toggle .icon-sun {
	display: none;
}
.theme-toggle .icon-moon {
	display: block;
}
html[data-theme="dark"] .theme-toggle .icon-sun {
	display: block;
}
html[data-theme="dark"] .theme-toggle .icon-moon {
	display: none;
}

.menu-toggle {
	display: none;
	width: 40px;
	height: 40px;
	border-radius: 10px;
	align-items: center;
	justify-content: center;
	color: var(--ink-700);
}
.menu-toggle:hover {
	background: var(--ink-100);
}

.scroll-top {
	position: fixed;
	right: 22px;
	bottom: 22px;
	z-index: 120;
	width: 48px;
	height: 48px;
	border-radius: 999px;
	background: var(--ink-900);
	color: var(--bg);
	box-shadow: var(--shadow-md);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	visibility: hidden;
	transform: translateY(10px);
	transition:
		opacity 0.18s ease,
		transform 0.18s ease,
		visibility 0.18s ease,
		background 0.15s ease;
}
.scroll-top:hover {
	background: var(--ink-800);
	transform: translateY(6px);
}
.scroll-top.is-visible {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.scroll-top svg {
	width: 20px;
	height: 20px;
}

.mobile-drawer-backdrop {
	position: fixed;
	inset: 0;
	z-index: 190;
	background: rgba(0, 0, 0, 0.42);
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.22s ease;
}

.mobile-drawer {
	position: fixed;
	top: 0;
	right: 0;
	z-index: 200;
	width: min(86vw, 360px);
	height: 100dvh;
	padding: 18px;
	background: var(--surface);
	border-left: 1px solid var(--border);
	box-shadow: -24px 0 60px rgba(20, 20, 20, 0.16);
	transform: translateX(100%);
	transition: transform 0.24s ease;
	display: flex;
	flex-direction: column;
	overflow-y: auto;
}

body.drawer-open {
	overflow: hidden;
}
body.drawer-open .mobile-drawer-backdrop {
	opacity: 1;
	pointer-events: auto;
}
body.drawer-open .mobile-drawer {
	transform: translateX(0);
}

.mobile-drawer-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding-bottom: 18px;
	border-bottom: 1px solid var(--border);
}
.mobile-drawer-close {
	width: 40px;
	height: 40px;
	border-radius: 10px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--ink-700);
}
.mobile-drawer-close:hover {
	background: var(--ink-100);
	color: var(--ink-900);
}

.mobile-nav {
	display: grid;
	gap: 4px;
	padding: 18px 0;
}
.mobile-nav a,
.mobile-nav summary {
	min-height: 48px;
	padding: 13px 12px;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	font-size: 16px;
	font-weight: 700;
	color: var(--ink-900);
	list-style: none;
}
.mobile-nav a:hover,
.mobile-nav summary:hover {
	background: var(--ink-100);
}
.mobile-nav summary::-webkit-details-marker {
	display: none;
}
.mobile-nav .chev {
	width: 12px;
	height: 12px;
	transition: transform 0.18s ease;
}
.mobile-nav details[open] .chev {
	transform: rotate(180deg);
}
.mobile-submenu {
	display: grid;
	gap: 2px;
	padding: 2px 0 8px 12px;
}
.mobile-submenu a {
	min-height: 42px;
	font-size: 14px;
	font-weight: 600;
	color: var(--ink-600);
}

.mobile-drawer-actions {
	display: grid;
	gap: 8px;
	margin-top: auto;
	padding-top: 18px;
	border-top: 1px solid var(--border);
}
.mobile-drawer-actions .btn {
	width: 100%;
}

@media (max-width: 1024px) {
	.nav {
		display: none;
	}
	.menu-toggle {
		display: inline-flex;
	}
	.header-actions .btn-ghost,
	.header-actions > .btn-primary {
		display: none;
	}
}

@media (max-width: 640px) {
	.header-inner {
		height: 72px;
	}
	.header-actions .btn:not(.btn-primary):not(.theme-toggle) {
		display: none;
	}
	.scroll-top {
		right: 16px;
		bottom: 16px;
		width: 44px;
		height: 44px;
	}
}

/* Shared bottom CTA: home/partials/cta.html */
.site-cta { padding: 64px 0; border-top: 1px solid #314b6c; background: linear-gradient(115deg,#14243b,#203a5d); color: #f7faff; text-align: center; }
.site-cta h2, .site-cta p { word-break: keep-all; }
.site-cta-eyebrow { margin: 0 0 18px; color: #aecdf5; font-size: 12px; font-weight: 800; letter-spacing: .11em; }
.site-cta h2 { margin: 0 0 20px; color: #fff; font-size: clamp(30px,3.5vw,42px); line-height: 1.4; letter-spacing: -.045em; }
.site-cta-description { margin: 0; color: #c9d7e9; font-size: 15px; line-height: 1.8; }
.site-cta-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 18px; margin-top: 30px; }
.site-cta-primary { padding: 12px 20px; background: #b9d8ff; color: #162b46; box-shadow: 0 6px 18px rgba(6,15,30,.18); }
.site-cta-primary:hover { background: #d7e8ff; transform: translateY(-1px); }
.site-cta .btn-outline { border-color: rgba(200,221,248,.5); background: transparent; color: #edf5ff; }
.site-cta .btn-outline:hover { border-color: #dceaff; background: rgba(194,219,255,.1); color: #fff; }
.site-cta .btn:focus-visible { outline: 2px solid #b9d8ff; outline-offset: 4px; }
html[data-theme="dark"] .site-cta { border-top-color: #233044; background: linear-gradient(115deg,#080f19,#101c2c); color: #edf2f8; }
html[data-theme="dark"] .site-cta h2 { color: #edf2f8; }
html[data-theme="dark"] .site-cta-eyebrow { color: #8eaaca; }
html[data-theme="dark"] .site-cta-description { color: #a0aec0; }
html[data-theme="dark"] .site-cta-primary { background: #314d71; color: #e8f0fb; box-shadow: 0 6px 18px rgba(0,0,0,.24); }
html[data-theme="dark"] .site-cta-primary:hover { background: #3c5e87; }
html[data-theme="dark"] .site-cta .btn:focus-visible { outline-color: #9bb7d8; }
@media (max-width: 640px) {
 .site-cta { padding: 40px 0; }
 .site-cta-eyebrow { margin-bottom: 14px; font-size: 10px; }
 .site-cta-description { font-size: 14px; }
 .site-cta-actions { gap: 14px; }
}
@media (prefers-reduced-motion: reduce) {
 .site-cta .btn { transition: none; }
 .site-cta-primary:hover { transform: none; }
}
