/* Ken Studio 소개 페이지
   색은 로고에서 뽑았다(YouTube 배너·Play 개발자 페이지와 같음). 글꼴은 Paperlogy(OFL) 부분 집합. */

@font-face {
  font-family: "Paperlogy KS";
  src: url("/assets/fonts/paperlogy-400.woff") format("woff");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Paperlogy KS";
  src: url("/assets/fonts/paperlogy-600.woff") format("woff");
  font-weight: 600;
  font-display: swap;
}
@font-face {
  font-family: "Paperlogy KS";
  src: url("/assets/fonts/paperlogy-700.woff") format("woff");
  font-weight: 700;
  font-display: swap;
}

:root {
  --bg: #f6f7fc;
  --surface: #ffffff;
  --ink: #0c1b36;
  --slate: #4f5b75;
  --line: #dce1ee;
  --link: #0b5fd3;
  --blue: #1677f9;
  --cyan: #1bbef7;
  --violet: #6330ed;
  --font: "Paperlogy KS", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", system-ui, sans-serif;
  --wrap: 72rem;
  --radius: 0.75rem;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  font-weight: 400;
  line-height: 1.7;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }

h1, h2, h3, p, dl, dd, ul { margin: 0; }
ul { padding: 0; list-style: none; }

a { color: var(--link); text-underline-offset: 0.2em; }

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: min(100% - 2.5rem, var(--wrap));
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  padding: 0.6rem 1rem;
  background: var(--ink);
  color: #fff;
  border-radius: var(--radius);
}
.skip:focus { top: 1rem; }

.sr-status {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* 머리글 */
.top__in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 1.25rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
}
.brand img { width: 44px; height: 36px; }

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  font-weight: 600;
}
.nav a {
  color: var(--ink);
  text-decoration: none;
  padding-block: 0.25rem;
}
.nav a:hover { color: var(--link); }
.nav .nav__lang { color: var(--slate); font-weight: 400; }

/* 단추 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.9rem;
  padding: 0.55rem 1.2rem;
  border: 1.5px solid #c6cde0;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
  cursor: pointer;
}
.btn:hover { border-color: var(--ink); }
.btn--solid {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}
.btn--solid:hover { background: #1d3463; border-color: #1d3463; }
.btn--small {
  min-height: 2.4rem;
  padding: 0.35rem 0.9rem;
  font-size: 0.9375rem;
}

/* 첫 화면 */
.hero__in {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: center;
  gap: 3rem;
  padding-block: 3.5rem 5rem;
}

h1 {
  font-size: clamp(2.5rem, 5.8vw, 4.6rem);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.03em;
}
:lang(en) h1 { letter-spacing: -0.035em; max-width: 13ch; }

.lead {
  max-width: 34rem;
  margin-top: 1.5rem;
  color: var(--slate);
  font-size: 1.25rem;
  line-height: 1.65;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

/* 로고의 세 픽셀 자리를 그대로 키운 무대.
   보라(오른쪽 위, 가장 큼) = CluPix, 파랑(왼쪽) = Keepling, 작은 하늘색(아래) = 진혼객 */
.stage {
  position: relative;
  justify-self: end;
  width: 100%;
  max-width: 27rem;
  aspect-ratio: 400 / 390;
}

/* --off(색 픽셀이 비켜 선 거리)는 타일을 감싼 쪽(.dot·.app__tile)에서 정한다 */
.tile {
  --tc: var(--blue);
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 22%;
  background: var(--surface);
  box-shadow: var(--off, 10px) var(--off, 10px) 0 0 var(--tc);
}
/* 여백을 %로 주면 부모 폭 기준이 되어 좁은 화면에서 아이콘이 줄어든다 — 그림 크기로 정한다 */
.tile img { width: 78%; height: 78%; object-fit: contain; }
.tile--violet { --tc: rgb(99 48 237 / 0.85); }
.tile--blue { --tc: rgb(22 119 249 / 0.8); }
.tile--cyan { --tc: rgb(27 190 247 / 0.85); }
.tile--full { overflow: hidden; }
.tile--full img { width: 100%; height: 100%; object-fit: cover; }

.dot {
  position: absolute;
  display: block;
  color: var(--ink);
  font-weight: 600;
  text-align: center;
  text-decoration: none;
}
.dot { --off: 11px; }
.dot--clupix { left: 52.5%; top: 0; width: 40.5%; --off: 14px; }
.dot--keepling { left: 0; top: 33.2%; width: 34.5%; }
.dot--jinhon { left: 43.5%; top: 71%; width: 19.5%; --off: 7px; }

.dot__name {
  display: block;
  margin-top: calc(var(--off) + 0.4rem);
  padding-left: var(--off);
  font-size: 0.9375rem;
  line-height: 1.3;
  white-space: nowrap;
}
.dot--jinhon .dot__name { font-size: 0.875rem; }

.dot .tile { transition: transform 160ms ease, box-shadow 160ms ease; }
.dot:hover .tile,
.dot:focus-visible .tile {
  transform: translate(-3px, -3px);
  box-shadow: calc(var(--off, 10px) + 3px) calc(var(--off, 10px) + 3px) 0 0 var(--tc);
}
.dot:focus-visible { outline: none; }
.dot:focus-visible .tile { outline: 3px solid var(--blue); outline-offset: 4px; }

.px {
  position: absolute;
  display: block;
  border-radius: 24%;
}
.px--1 { left: 16%; top: 6%; width: 3.5%; aspect-ratio: 1; background: rgb(27 190 247 / 0.55); }
.px--2 { left: 31%; top: 15%; width: 5.5%; aspect-ratio: 1; background: rgb(22 119 249 / 0.45); }
.px--3 { left: 93%; top: 58%; width: 4.5%; aspect-ratio: 1; background: rgb(99 48 237 / 0.45); }
.px--4 { left: 14%; top: 86%; width: 3%; aspect-ratio: 1; background: rgb(27 190 247 / 0.6); }

/* 처음 열 때 한 번: 작은 픽셀부터 큰 앱 순서로 놓인다 */
@media (prefers-reduced-motion: no-preference) {
  .px,
  .dot { animation: pop 520ms cubic-bezier(0.2, 0.8, 0.25, 1.15) both; }
  .px--1 { animation-delay: 60ms; }
  .px--2 { animation-delay: 120ms; }
  .px--4 { animation-delay: 180ms; }
  .px--3 { animation-delay: 240ms; }
  .dot--jinhon { animation-delay: 300ms; }
  .dot--keepling { animation-delay: 400ms; }
  .dot--clupix { animation-delay: 500ms; }
}
@keyframes pop {
  from { opacity: 0; transform: scale(0.55); }
  to { opacity: 1; transform: scale(1); }
}

/* 공통 구획 */
.about,
.apps,
.contact { padding-block: 5.5rem; }

.apps { background: var(--surface); }

h2 {
  font-size: clamp(1.75rem, 3.2vw, 2.25rem);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

h3 {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.015em;
}

/* 회사 소개 */
.about__in {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr);
  gap: 2rem 4rem;
}

.about__body { max-width: 44rem; }
.about__body > p + p { margin-top: 1rem; }
.about__body > p:not(.about__lead) { color: var(--slate); }

.about__lead {
  font-size: 1.375rem;
  font-weight: 600;
  line-height: 1.55;
}

.values {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem 2rem;
  margin-top: 2.5rem;
}
.values dt {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-weight: 700;
}
.values dt::before {
  content: "";
  flex: none;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 24%;
  background: var(--blue);
}
.values div:nth-child(1) dt::before { background: var(--cyan); }
.values div:nth-child(3) dt::before { background: var(--violet); }
.values dd {
  margin-top: 0.4rem;
  color: var(--slate);
  font-size: 1rem;
}

/* 만든 앱 */
.app {
  display: grid;
  grid-template-columns: 8.5rem minmax(0, 1fr);
  gap: 1.5rem 3rem;
  align-items: start;
  padding-block: 3rem;
  border-bottom: 1px solid var(--line);
}
.apps h2 + .app { margin-top: 1rem; }

.app__tile { --off: 8px; width: 8rem; }

.app__body { max-width: 44rem; }
.app__body > p:not(.app__tag):not(.app__links) { margin-top: 0.75rem; color: var(--slate); }

.app__hanja {
  margin-left: 0.35rem;
  color: var(--slate);
  font-size: 1.125rem;
  font-weight: 400;
}

.app__tag {
  margin-top: 0.25rem;
  font-size: 1.1875rem;
  font-weight: 600;
  line-height: 1.5;
}

.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2.5rem;
  margin-top: 1.25rem;
}
.facts dt { color: var(--slate); font-size: 0.875rem; }
.facts dd { font-size: 1rem; font-weight: 600; }

.app__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.more { padding-top: 3rem; }
.more h3 { font-size: 1.1875rem; }

.more__list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem 3rem;
  margin-top: 1.25rem;
}
.more__list li {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}
.more__list img {
  flex: none;
  width: 3.5rem;
  height: 3.5rem;
  border: 1px solid var(--line);
  border-radius: 22%;
  background: var(--surface);
}
.more__name { font-size: 1.125rem; font-weight: 700; }
.more__list p { margin-top: 0.15rem; color: var(--slate); font-size: 1rem; }

/* 연락처 */
.contact__lead {
  margin-top: 0.75rem;
  color: var(--slate);
}

.channels { margin-top: 2.5rem; border-top: 1px solid var(--line); }

.channel {
  display: grid;
  grid-template-columns: 12rem minmax(0, 1fr);
  gap: 0.5rem 2rem;
  align-items: center;
  padding-block: 1.5rem;
  border-bottom: 1px solid var(--line);
}
.channel dt { color: var(--slate); font-weight: 600; }
.channel dd {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1.25rem;
}

.channel__value {
  font-size: clamp(1.25rem, 2.6vw, 1.625rem);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
  overflow-wrap: anywhere;
}
a.channel__value { color: var(--ink); text-decoration-color: var(--line); text-decoration-thickness: 2px; }
a.channel__value:hover { color: var(--link); text-decoration-color: currentColor; }

.channel.is-soon .channel__value { color: var(--slate); }
.soon { color: var(--slate); font-size: 0.9375rem; }

/* 바닥글 */
.foot { border-top: 1px solid var(--line); }
.foot__in {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 2rem 2.5rem;
  color: var(--slate);
  font-size: 0.9375rem;
}
.foot ul { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
.foot a { color: var(--slate); }
.foot a:hover { color: var(--link); }

/* 좁은 화면 */
@media (max-width: 880px) {
  .hero__in {
    grid-template-columns: minmax(0, 1fr);
    gap: 3.5rem;
    padding-block: 2rem 4.5rem;
  }
  .stage { justify-self: center; max-width: 21rem; }
  .about__in { grid-template-columns: minmax(0, 1fr); }
  .values { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; margin-top: 2rem; }
}

@media (max-width: 640px) {
  body { font-size: 1rem; }
  .wrap { width: min(100% - 2.25rem, var(--wrap)); }
  .brand { font-size: 1.15rem; }
  .nav { gap: 0.25rem 1.1rem; font-size: 0.9375rem; }
  .lead { font-size: 1.125rem; }
  .about,
  .apps,
  .contact { padding-block: 4rem; }
  .app {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.25rem;
    padding-block: 2.5rem;
  }
  .app__tile { width: 5.5rem; --off: 6px; }
  .more__list { grid-template-columns: minmax(0, 1fr); }
  .channel { grid-template-columns: minmax(0, 1fr); gap: 0.35rem; padding-block: 1.25rem; }
}
