/* ───────────────────────────────────────────────────────────────
   PIKPIK 랜딩 페이지 — 다크 배경 + 핑크 액센트 + 반짝이 별
   - 스샷 (까만 배경) 이 사이트 배경과 seamless 하게 블렌딩
   - 반짝이 별은 항상 스샷보다 앞 (z-index 위) → 잘리지 않음
   ─────────────────────────────────────────────────────────────── */

:root {
  --bg: #000000;
  --bg-soft: #0a0a0c;
  --text: #FFFFFF;
  --text-sub: rgba(255,255,255,0.65);
  --text-dim: rgba(255,255,255,0.35);
  --accent: #FF4F7A;
  --accent-soft: rgba(255,79,122,0.18);
  --border: rgba(255,255,255,0.10);
  --pixel-font: 'Galmuri11', 'DungGeunMo', monospace;
  --body-font: 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  font-family: var(--body-font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }

/* ─── 별 반짝이 오버레이 — 스샷 앞 레이어 (z-index 위) ─────── */
.stars-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 5;
}
.star {
  position: absolute;
  color: var(--accent);
  font-size: 16px;
  opacity: 0.7;
  animation: twinkle 3s ease-in-out infinite;
  text-shadow: 0 0 8px rgba(255,79,122,0.6);
}
.star.s1  { top:  8%; left: 12%; font-size: 14px; animation-delay: 0s;   }
.star.s2  { top: 18%; left: 88%; font-size: 22px; animation-delay: 0.3s; color: #FFD6E2; }
.star.s3  { top: 32%; left:  6%; font-size: 18px; animation-delay: 0.7s; }
.star.s4  { top: 45%; left: 92%; font-size: 12px; animation-delay: 1.1s; color: #FFD6E2; }
.star.s5  { top: 58%; left:  4%; font-size: 20px; animation-delay: 1.5s; }
.star.s6  { top: 70%; left: 90%; font-size: 16px; animation-delay: 1.9s; }
.star.s7  { top: 82%; left: 14%; font-size: 14px; animation-delay: 2.2s; color: #FFD6E2; }
.star.s8  { top: 92%; left: 80%; font-size: 18px; animation-delay: 2.5s; }
.star.s9  { top: 14%; left: 50%; font-size: 11px; animation-delay: 0.5s; }
.star.s10 { top: 50%; left: 48%; font-size: 13px; animation-delay: 1.3s; color: #FFD6E2; }
.star.s11 { top: 75%; left: 52%; font-size: 15px; animation-delay: 2.0s; }
.star.s12 { top: 28%; left: 30%; font-size: 10px; animation-delay: 1.8s; }

@keyframes twinkle {
  0%, 100% { opacity: 0.3; transform: scale(0.9) rotate(0deg); }
  50%      { opacity: 1;   transform: scale(1.1) rotate(15deg); }
}

/* ─── 네비게이션 ─────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: inline-flex; align-items: center; gap: 6px; }
/* 픽셀 네온 PIKPIK 로고 — 핑크 그라데이션 글자 + 다층 분홍 글로우 */
.brand-logo {
  font-family: var(--pixel-font);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 3px;
  /* 글자 자체 — 분홍에서 진분홍 그라데이션 */
  background: linear-gradient(180deg, #FFB3CC 0%, #FF77A8 40%, #FF4F7A 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  /* 네온 글로우 — 살짝만 (이전보다 절반 정도) */
  filter:
    drop-shadow(0 0 1px #FFFFFF)
    drop-shadow(0 0 4px rgba(255, 79, 122, 0.75))
    drop-shadow(0 0 10px rgba(255, 79, 122, 0.35));
}
.brand-logo.small { font-size: 18px; }
.brand-star {
  color: var(--accent);
  font-size: 14px;
  text-shadow: 0 0 6px rgba(255,79,122,0.6);
}
.nav-links { display: flex; gap: 24px; }
.nav-links a {
  font-size: 14px;
  color: var(--text-sub);
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--accent); }

/* ─── HERO ─────────────────────────────────────────────── */
.hero {
  position: relative;
  padding: 100px 24px 80px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.hero-title {
  font-family: var(--body-font);
  font-weight: 900;
  font-size: clamp(38px, 7vw, 64px);
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 20px;
}
.hero-line { display: block; }
.accent { color: var(--accent); }
.hero-sub {
  font-size: clamp(13px, 1.6vw, 15px);   /* sub 글자로 완전히 작게 */
  color: var(--text-sub);
  margin-top: 4px;
  margin-bottom: 40px;
}
.hero-muted {
  margin-top: 14px;
  font-size: 12px;
  color: var(--text-dim);
}

/* ─── 교차 카드 (히어로) — 다른 스샷보다 크게 + 좌/우 비대칭 ─── */
.hero-cards {
  position: relative;
  width: 100%;
  max-width: 600px;
  height: 540px;
  margin: 40px auto 40px;
}
.hero-card {
  position: absolute;
  top: 50%;
  height: auto;
  transform-origin: center center;
  filter: drop-shadow(0 24px 48px rgba(255, 79, 122, 0.3));
  transition: transform 0.4s ease-out, filter 0.3s;
}
.hero-card-left {
  width: 250px;                                        /* 왼쪽 — 살짝 작음 */
  left: 50%;
  transform: translate(-95%, -50%) rotate(-12deg);
  animation: floatLeft 5s ease-in-out infinite;
  z-index: 2;
}
.hero-card-right {
  width: 320px;                                        /* 오른쪽 — 더 크게 */
  left: 50%;
  transform: translate(-5%, -55%) rotate(12deg);
  animation: floatRight 5s ease-in-out infinite;
  animation-delay: 0.5s;
  z-index: 1;
}
.hero-card:hover {
  filter: drop-shadow(0 28px 56px rgba(255, 79, 122, 0.5));
  z-index: 3;
}

@keyframes floatLeft {
  0%, 100% { transform: translate(-95%, -50%) rotate(-12deg) translateY(0); }
  50%      { transform: translate(-95%, -50%) rotate(-12deg) translateY(-16px); }
}
@keyframes floatRight {
  0%, 100% { transform: translate(-5%, -55%) rotate(12deg) translateY(0); }
  50%      { transform: translate(-5%, -55%) rotate(12deg) translateY(-16px); }
}

/* ─── CTA 버튼 ───────────────────────────────────────────── */
.cta-row {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
  height: 52px;
  padding: 0 24px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.2px;
  transition: transform 0.15s, box-shadow 0.2s;
  cursor: pointer;
}
/* App Store / Google Play 버튼 — 둘 다 검정 바탕 + 흰색 텍스트 + 흰색 테두리로 통일 */
.cta.primary,
.cta.secondary {
  background: #000000;
  color: #FFFFFF;
  border: 1.5px solid #FFFFFF;
  box-shadow: none;
}
.cta.primary:hover,
.cta.secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-2px);
}
.cta[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* ─── FEATURES ─────────────────────────────────────────── */
.features {
  position: relative;
  padding: 60px 24px;
  max-width: 720px;
  margin: 0 auto;
}
.feature {
  position: relative;
  padding: 60px 0;
  text-align: center;
}
.feature-headline {
  font-family: var(--body-font);
  font-weight: 900;
  font-size: clamp(32px, 6vw, 48px);
  line-height: 1.2;
  letter-spacing: -1px;
  margin-bottom: 14px;
}
.feature-sub {
  font-size: clamp(14px, 2vw, 17px);
  color: var(--text-sub);
  margin-bottom: 16px;   /* 36 → 16, 텍스트와 이미지 간격 축소 */
}
.feature-media {
  position: relative;
  z-index: 1;
  max-width: 380px;
  margin: 0 auto;
}
.feature-img {
  width: 100%;
  height: auto;
  /* 스샷 배경 = 검정 = 사이트 배경. 박스 / 그림자 X — seamless */
}

/* ─── 이미지 위쪽 텍스트 부분만 잘라내고 아래 그림만 보여주기 ───
   .cropped 컨테이너:
     - aspect-ratio 로 보이는 영역 비율 고정
     - overflow:hidden 로 위 텍스트 영역 잘라냄
     - 안의 img 는 width 100% + position:absolute bottom:0 → 위가 잘림
*/
.feature-media.cropped {
  position: relative;
  width: 100%;
  max-width: 380px;
  /* 원본 1290x2796 (비율 0.461) 에서 위 텍스트 영역만 약 20% 자르고 폰 mockup 은 다 보이게 */
  aspect-ratio: 100 / 174;
  overflow: hidden;
  margin: 0 auto;
}
.feature-media.cropped img {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: auto;
  display: block;
}

/* ─── 카드팩 (배경 제거 안 됨 — 그림자 X, 사이즈 작게) ─── */
.feature-media.pack-object {
  max-width: 220px;
  margin: 0 auto;
}
.feature-media.pack-object img {
  animation: packFloat 4s ease-in-out infinite;
}
@keyframes packFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

/* ─── Feature 1 카드 뒷장 — 위아래 검정 여백 살짝 크롭 + floating + 크게 ─── */
.feature-media.card-back {
  max-width: 460px;     /* 다른 폰 스샷(380) 보다 크게 */
}
.feature-media.card-back img {
  /* 이미지의 위/아래 7% 씩 잘라서 검정 여백 최소화 */
  clip-path: inset(7% 0 7% 0);
  /* clip-path 한 만큼 layout 빈 공간을 negative margin 으로 보정 */
  margin: -7% 0;
  animation: cardBackFloat 5s ease-in-out infinite;
}
@keyframes cardBackFloat {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}

/* ─── 등장 애니메이션 — scroll 시 fade + 위로 떠오름 + 살짝 scale ─── */
.reveal {
  opacity: 0;
  transform: translateY(48px) scale(0.96);
  transition:
    opacity 0.9s cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 0.9s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* 이미지 자체에 추가 등장 효과 — 컨테이너 visible 후 살짝 늦게 뜸 */
.reveal .feature-media {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.8s ease-out 0.25s,
    transform 0.8s ease-out 0.25s;
}
.reveal.visible .feature-media {
  opacity: 1;
  transform: translateY(0);
}

/* ─── 최종 CTA ────────────────────────────────────────── */
.cta-final {
  padding: 100px 24px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.cta-final-title {
  font-family: var(--body-font);
  font-weight: 900;
  font-size: clamp(36px, 6vw, 56px);
  letter-spacing: -1px;
  margin-bottom: 14px;
}
.cta-final-sub {
  font-size: clamp(15px, 2.2vw, 18px);
  color: var(--text-sub);
  margin-bottom: 36px;
}

/* ─── 푸터 ────────────────────────────────────────────── */
.footer {
  background: var(--bg-soft);
  border-top: 1px solid var(--border);
  padding: 60px 24px 30px;
  margin-top: 60px;
  position: relative;
  z-index: 1;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto 30px;
}

/* 1행: 좌측 로고 + 우측 약관 가로 나열 */
.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 56px;             /* 약관 ↔ 사업자 정보 간격 늘림 */
  flex-wrap: wrap;
  gap: 16px;
}
.footer-links-horizontal {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-links-horizontal a {
  font-size: 13px;
  color: var(--text-sub);
  transition: color 0.2s;
}
.footer-links-horizontal a:hover { color: var(--accent); }

/* 2행: 사업자 정보 */
.footer-biz-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-sub);
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.footer-business {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  font-size: 11.5px;
  color: var(--text-dim);
  line-height: 1.8;
}
.biz-item {
  position: relative;
}
.biz-item:not(:last-child)::after {
  content: '·';
  color: var(--text-dim);
  margin-left: 18px;
  opacity: 0.6;
}
.biz-item a {
  color: var(--text-sub);
  text-decoration: underline;
}
.biz-item a:hover { color: var(--accent); }
.footer-bottom {
  max-width: 1100px;
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.footer-bottom p {
  font-size: 11px;
  color: var(--text-dim);
}

/* ─── 약관 / 정책 문서 페이지 ──────────────────────────── */
.doc {
  max-width: 760px;
  margin: 0 auto;
  padding: 60px 24px 80px;
  position: relative;
  z-index: 1;
}
.doc h1 {
  font-size: clamp(28px, 5vw, 40px);
  font-weight: 900;
  letter-spacing: -1px;
  margin-bottom: 8px;
}
.doc .doc-meta {
  font-size: 12px;
  color: var(--text-dim);
  margin-bottom: 36px;
}
.doc section {
  margin-bottom: 36px;
}
.doc h2 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.doc h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-sub);
  margin: 20px 0 10px;
}
.doc p {
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.8;
  margin-bottom: 12px;
}
.doc ul, .doc ol {
  padding-left: 20px;
  margin-bottom: 12px;
}
.doc li {
  font-size: 14px;
  color: var(--text-sub);
  line-height: 1.8;
  margin-bottom: 6px;
}
.doc strong { color: var(--text); font-weight: 700; }
.doc a { color: var(--accent); text-decoration: underline; }
.doc .back-link {
  display: inline-block;
  margin-top: 40px;
  font-size: 13px;
  color: var(--text-sub);
  text-decoration: none;
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: border-color 0.2s, color 0.2s;
}
.doc .back-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}

/* ─── 모바일 ────────────────────────────────────────── */
@media (max-width: 720px) {
  .hero { padding: 60px 20px 50px; }
  .feature { padding: 40px 0; }
  .feature-media { max-width: 320px; }
  /* 푸터 — 모바일에선 약관 링크가 자동 줄바꿈됨 (flex-wrap 이미 적용) */
  .footer-top { flex-direction: column; align-items: flex-start; }
  .footer-links-horizontal { gap: 14px; }
  .cta { min-width: 140px; height: 48px; font-size: 14px; }

  /* 교차 카드 — 모바일에선 크기 줄임 (비율 유지) */
  .hero-cards { height: 400px; max-width: 420px; }
  .hero-card-left  { width: 185px; }
  .hero-card-right { width: 240px; }
}
