/* layouts/lp4-hub.css — 랜딩 첫 장 «케어하자로 올인원» 그림 (2026-11-06 · 짝 index.php 의 .p4-slide--hub)
 *  사장님 «3D 마을이 너무 게임 같다 · 세 서비스를 다 한다는 것은 꼭 보이게» → 밝은 바탕 · 세 서비스 카드가 선으로 가운데 «케어하자» 카드에 모인다.
 *  PC = 왼쪽 세 카드(작은 업무 화면) → 오른쪽 케어하자 카드 · 폰 · 태블릿(≤900) = 위 세 칸 → 아래 케어하자 카드.
 *  그림판(.p4-hub__cv)은 비율 고정(PC 720×430 · 폰 360×300) — 칸 · 글 크기는 모두 --u(판 폭 ÷ 기준 폭)로 같이 줄고 는다. 선은 같은 비율의 SVG.
 *  장이 켜질 때(.is-on — 처음 열 때도 · 다시 돌아올 때도, 그래서 transition 이 아니라 animation) 카드가 차례로 들어오고 선이 그어진 뒤 점이 케어하자 쪽으로 흐른다.
 *  움직임 줄이기면 다 멈춘 채로(기본 모습 = 다 보인 상태).
 */
.p4-slide--hub {
	background:
		radial-gradient(38% 55% at 52% 18%, rgba(20, 184, 166, .10), transparent 70%),
		radial-gradient(34% 50% at 58% 92%, rgba(99, 102, 241, .09), transparent 70%),
		radial-gradient(30% 45% at 92% 55%, rgba(249, 115, 22, .07), transparent 70%),
		linear-gradient(180deg, #f8fafc, #eef3f8);
}
.p4-slide--hub::before { background-image: radial-gradient(rgba(15, 23, 42, .09) 1px, transparent 1.4px); }

/* 글 칸 — 밝은 바탕이라 글은 진하게 */
.p4-slide--hub .p4-copy { color: #0f172a; }
.p4-slide--hub .p4-kicker { color: #0f766e; background: #ccfbf1; border-color: #99f6e4; }
.p4-slide--hub .p4-copy p { color: #334155; }
.p4-slide--hub .p4-copy h2 .h-v { color: #0d9488; }
.p4-slide--hub .p4-copy h2 .h-c { color: #4f46e5; }
.p4-slide--hub .p4-copy h2 .h-n { color: #ea580c; }
.p4-slide--hub .p4-cta { background: #0f766e; box-shadow: 0 10px 24px -10px rgba(15, 118, 110, .7); }

/* 그림 자리 — PC: 글 오른쪽 ~ 목록 앞 */
.p4-hub { position: absolute; z-index: 1; top: 30px; bottom: 30px; left: 43%; right: 236px; display: grid; place-items: center; container-type: size; pointer-events: none; }
.p4-hub__cv { position: relative; width: min(100cqw, calc(100cqh * 720 / 430)); aspect-ratio: 720 / 430; container-type: inline-size; --u: calc(100cqw / 720); line-height: 1.35; }   /* 운영 바탕 줄 간격(1.6)이면 카드 아래 줄이 넘친다 */

/* 선 */
.p4-hub__ln { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.p4-hub__ln.is-m { display: none; }
.p4-hub__ln path { fill: none; stroke-width: 2.5; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.p4-hub__ln .l1 { stroke: #5eead4; fill: #14b8a6; }
.p4-hub__ln .l2 { stroke: #a5b4fc; fill: #6366f1; }   /* 11-07 둘째 = 요양원(남색) · 셋째 = 주야간보호(주황) */
.p4-hub__ln .l3 { stroke: #fdba74; fill: #f97316; }
.p4-hub__ln path.l1, .p4-hub__ln path.l2, .p4-hub__ln path.l3 { fill: none; }
.p4-hub__ln .pt circle { fill: #fff; stroke-width: 2.5; }
.p4-hub__ln .pt .l1 { stroke: #14b8a6; } .p4-hub__ln .pt .l2 { stroke: #6366f1; } .p4-hub__ln .pt .l3 { stroke: #f97316; }
.p4-hub__ln .fx { stroke: #fff; stroke-width: 2; }
.p4-slide.is-on .p4-hub__ln path { animation: p4HubDraw .9s cubic-bezier(.4, 0, .2, 1) .55s both; }
.p4-slide.is-on .p4-hub__ln .pt circle { animation: p4HubFade .3s ease .5s both; }
@keyframes p4HubDraw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes p4HubFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes p4HubInX { from { opacity: 0; transform: translateX(calc(-14 * var(--u))); } to { opacity: 1; transform: none; } }
@keyframes p4HubInY { from { opacity: 0; transform: translateY(calc(10 * var(--u))); } to { opacity: 1; transform: none; } }
@keyframes p4HubPop { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: none; } }
@keyframes p4HubBar { from { width: 0; } to { width: 75%; } }

/* 서비스 카드 셋 */
.p4-hub__s { position: absolute; left: 0; width: calc(300 * var(--u)); height: calc(122 * var(--u)); padding: calc(14 * var(--u)) calc(16 * var(--u));
	border-radius: calc(16 * var(--u)); background: #fff; box-shadow: 0 0 0 1px rgba(15, 23, 42, .07), 0 calc(14 * var(--u)) calc(30 * var(--u)) calc(-16 * var(--u)) rgba(15, 23, 42, .3); }
.p4-hub__s::before { content: ''; position: absolute; left: 0; top: calc(16 * var(--u)); bottom: calc(16 * var(--u)); width: calc(4 * var(--u)); border-radius: 0 4px 4px 0; background: var(--c); }
.p4-hub__s.s1 { top: 0; } .p4-hub__s.s2 { top: calc(154 * var(--u)); } .p4-hub__s.s3 { top: calc(308 * var(--u)); }
.p4-slide.is-on .p4-hub__s { animation: p4HubInX .6s cubic-bezier(.2, .7, .2, 1) .05s both; }
.p4-slide.is-on .p4-hub__s.s2 { animation-delay: .17s; } .p4-slide.is-on .p4-hub__s.s3 { animation-delay: .29s; }
.p4-hub__s .hd { display: flex; align-items: center; gap: calc(10 * var(--u)); }
.p4-hub__s .hd i { flex: none; display: grid; place-items: center; width: calc(34 * var(--u)); height: calc(34 * var(--u)); border-radius: calc(10 * var(--u)); background: var(--c); color: #fff; font-size: calc(16 * var(--u)); }
.p4-hub__s .hd b { font-size: calc(18.5 * var(--u)); font-weight: 800; letter-spacing: -.03em; color: #0f172a; white-space: nowrap; }
.p4-hub__s .hd em { margin-left: auto; padding: calc(4 * var(--u)) calc(10 * var(--u)); border-radius: 999px; font-style: normal; font-size: calc(12.5 * var(--u)); font-weight: 700; white-space: nowrap;
	color: var(--ck); background: color-mix(in srgb, var(--c) 12%, #fff); }
.p4-hub__s .m { display: none; }
.p4-hub__s .bd { margin: calc(10 * var(--u)) 0 0; padding: 0; list-style: none; }
/* 방문요양 — 오늘 방문 두 줄 */
.p4-hub__s .bd.v { display: grid; gap: calc(6 * var(--u)); }
.p4-hub__s .bd.v li { display: flex; align-items: center; gap: calc(10 * var(--u)); height: calc(27 * var(--u)); padding: 0 calc(10 * var(--u)); border-radius: calc(8 * var(--u)); background: #f6f8fb; font-size: calc(13.5 * var(--u)); color: #1e293b; }
.p4-hub__s .bd.v time { font-weight: 800; font-variant-numeric: tabular-nums; color: #0f172a; }
.p4-hub__s .bd.v span { flex: 1; font-weight: 600; white-space: nowrap; }
.p4-hub__s .bd.v mark { padding: calc(2 * var(--u)) calc(8 * var(--u)); border-radius: 999px; font-size: calc(11.5 * var(--u)); font-weight: 800; color: #475569; background: #e2e8f0; }
.p4-hub__s .bd.v mark.ok { color: #fff; background: #14b8a6; }
/* 주야간보호 — 차 탑승 막대 */
.p4-hub__s .bd.r p { display: flex; align-items: baseline; justify-content: space-between; margin: 0; font-size: calc(14 * var(--u)); font-weight: 600; color: #1e293b; }
.p4-hub__s .bd.r p b { font-size: calc(15 * var(--u)); font-weight: 800; color: var(--ck); font-variant-numeric: tabular-nums; }
.p4-hub__s .bd.r .pg { margin-top: calc(7 * var(--u)); height: calc(9 * var(--u)); border-radius: 999px; background: #f1f5f9; overflow: hidden; }
.p4-hub__s .bd.r .pg i { display: block; width: 75%; height: 100%; border-radius: inherit; background: var(--c); }
.p4-slide.is-on .p4-hub__s .bd.r .pg i { animation: p4HubBar 1.1s cubic-bezier(.2, .7, .2, 1) .7s both; }
.p4-hub__s .bd.r small { display: block; margin-top: calc(6 * var(--u)); font-size: calc(12.5 * var(--u)); font-weight: 600; color: #475569; }
/* 요양원 — 직종별 할 일 */
.p4-hub__s .bd.j { display: grid; grid-template-columns: repeat(3, 1fr); gap: calc(7 * var(--u)); }
.p4-hub__s .bd.j li { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: calc(2 * var(--u)); height: calc(52 * var(--u)); border-radius: calc(9 * var(--u)); background: #f6f8fb; font-size: calc(12 * var(--u)); font-weight: 600; color: #334155; white-space: nowrap; }
.p4-hub__s .bd.j b { font-size: calc(19 * var(--u)); font-weight: 800; line-height: 1.1; color: var(--ck); font-variant-numeric: tabular-nums; }

/* 가운데 «케어하자» 카드 */
.p4-hub__c { position: absolute; left: calc(440 * var(--u)); top: calc(96 * var(--u)); width: calc(280 * var(--u)); height: calc(238 * var(--u)); display: flex; flex-direction: column;
	padding: calc(20 * var(--u)); border-radius: calc(20 * var(--u)); background: #fff;
	box-shadow: 0 0 0 calc(1.5 * var(--u)) rgba(15, 118, 110, .22), 0 calc(24 * var(--u)) calc(48 * var(--u)) calc(-22 * var(--u)) rgba(15, 23, 42, .4); }
.p4-slide.is-on .p4-hub__c { animation: p4HubPop .7s cubic-bezier(.2, .7, .2, 1) .3s both; }
.p4-hub__c .hd { display: flex; align-items: center; gap: calc(12 * var(--u)); }
.p4-hub__c .hd img { flex: none; width: calc(46 * var(--u)); height: calc(46 * var(--u)); border-radius: calc(13 * var(--u)); box-shadow: 0 0 0 1px rgba(15, 23, 42, .06); }
.p4-hub__c .hd span { display: flex; flex-direction: column; gap: calc(2 * var(--u)); }
.p4-hub__c .hd b { font-size: calc(23 * var(--u)); font-weight: 800; letter-spacing: -.035em; color: #0f172a; line-height: 1.15; }
.p4-hub__c .hd small { font-size: calc(13.5 * var(--u)); font-weight: 600; color: #475569; }
.p4-hub__c .ft { display: grid; grid-template-columns: 1fr 1fr; gap: calc(8 * var(--u)); margin: calc(18 * var(--u)) 0 0; padding: 0; list-style: none; }
.p4-hub__c .ft li { display: flex; align-items: center; gap: calc(7 * var(--u)); height: calc(40 * var(--u)); padding: 0 calc(10 * var(--u)); border-radius: calc(10 * var(--u)); background: #f1f5f9;
	font-size: calc(13.5 * var(--u)); font-weight: 700; color: #1e293b; white-space: nowrap; }
.p4-hub__c .ft i { width: calc(16 * var(--u)); text-align: center; font-size: calc(14 * var(--u)); color: #0f766e; }
.p4-hub__c .ok { display: flex; align-items: center; gap: calc(9 * var(--u)); margin-top: auto; padding-top: calc(14 * var(--u)); border-top: 1px dashed #e2e8f0; font-size: calc(13.5 * var(--u)); font-weight: 700; color: #334155; }
.p4-hub__c .ok span { display: flex; }
.p4-hub__c .ok i { width: calc(14 * var(--u)); height: calc(14 * var(--u)); border-radius: 50%; border: calc(2 * var(--u)) solid #fff; background: #14b8a6; }
.p4-hub__c .ok i + i { margin-left: calc(-5 * var(--u)); }
.p4-hub__c .ok i:nth-child(2) { background: #6366f1; } .p4-hub__c .ok i:nth-child(3) { background: #f97316; }

/* PC 오른쪽 목록 — 이 장일 때 조금 더 진하게(밝은 바탕에서 회색 띠로 뜨지 않게) */
@media (min-width: 901px) {
	.p4-hero:has(.p4-slide--hub.is-on) .p4-list { background: rgba(15, 23, 42, .86); }
}
@media (max-width: 1180px) {
	.p4-hub { left: 45%; right: 222px; }
}

/* ── 폰 · 태블릿(≤900) — 글 아래 남는 칸에 «위 세 칸 → 아래 케어하자 카드» ── */
@media (max-width: 900px) {
	.p4-slide--hub { flex-direction: column; align-items: stretch; }
	.p4-slide--hub .p4-copy { flex: none; }
	.p4-hub { order: 2; position: relative; inset: auto; flex: 1 1 auto; min-height: 0; margin: 14px 0 0; padding: 4px 20px 22px; }
	.p4-hub__cv { width: min(100cqw, calc(100cqh * 360 / 284), 440px); aspect-ratio: 360 / 284; --u: calc(100cqw / 360); }
	.p4-hub__ln.is-d { display: none; }
	.p4-hub__ln.is-m { display: block; }
	.p4-hub__s { width: calc(108 * var(--u)); height: calc(92 * var(--u)); top: 0 !important; padding: calc(10 * var(--u)) calc(6 * var(--u)); border-radius: calc(14 * var(--u)); }
	.p4-slide.is-on .p4-hub__s { animation-name: p4HubInY; }
	.p4-hub__s::before { left: calc(22 * var(--u)); right: calc(22 * var(--u)); top: 0; bottom: auto; width: auto; height: calc(3 * var(--u)); border-radius: 0 0 4px 4px; }
	.p4-hub__s.s2 { left: calc(126 * var(--u)); } .p4-hub__s.s3 { left: calc(252 * var(--u)); }
	.p4-hub__s .hd { flex-direction: column; gap: calc(6 * var(--u)); }
	.p4-hub__s .hd i { width: calc(30 * var(--u)); height: calc(30 * var(--u)); border-radius: calc(9 * var(--u)); font-size: calc(14 * var(--u)); }
	.p4-hub__s .hd b { font-size: calc(15 * var(--u)); }
	.p4-hub__s .hd em, .p4-hub__s .bd.v, .p4-hub__s .bd.r, .p4-hub__s .bd.j { display: none; }
	.p4-hub__s .m { display: block; margin-top: calc(3 * var(--u)); text-align: center; font-size: calc(11.5 * var(--u)); font-weight: 700; color: var(--ck); white-space: nowrap; }
	.p4-hub__c { left: calc(14 * var(--u)); top: calc(150 * var(--u)); width: calc(332 * var(--u)); height: calc(134 * var(--u)); padding: calc(14 * var(--u)); border-radius: calc(18 * var(--u)); }
	.p4-hub__c .hd img { width: calc(38 * var(--u)); height: calc(38 * var(--u)); border-radius: calc(11 * var(--u)); }
	.p4-hub__c .hd b { font-size: calc(19 * var(--u)); }
	.p4-hub__c .hd small { font-size: calc(12 * var(--u)); }
	.p4-hub__c .ft { grid-template-columns: repeat(4, 1fr); gap: calc(6 * var(--u)); margin-top: calc(12 * var(--u)); }
	.p4-hub__c .ft li { flex-direction: column; justify-content: center; gap: calc(4 * var(--u)); height: calc(54 * var(--u)); padding: 0; font-size: calc(11.5 * var(--u)); }
	.p4-hub__c .ft i { width: auto; font-size: calc(15 * var(--u)); }
	.p4-hub__c .ok { display: none; }
}
/* 태블릿(768~900) — 글 아래는 칸이 좁아 그림이 너무 작다 → 글 왼쪽 · 그림 오른쪽 */
@media (min-width: 768px) and (max-width: 900px) {
	.p4-slide--hub { flex-direction: row; align-items: center; }
	.p4-slide--hub .p4-copy { width: 54%; padding-top: 0; padding-right: 0; }
	.p4-slide--hub .p4-hub { align-self: stretch; margin: 0; padding: 28px 18px 28px 12px; }
}

@media (prefers-reduced-motion: reduce) {
	.p4-hub *, .p4-hub *::before { animation: none !important; }
	.p4-hub__ln .fx { display: none; }
}
