/* ==========================================================================
   찍(ZZIZ) 약관 및 정책 스타일시트
   - ZZIZ 앱 다크 테마 시스템(Color.kt / Theme.kt) 100% 동기화
   - 한국어 모바일 가독성 최적화 (Pretendard, 행간, 자간, 계층 구조)
   ========================================================================== */

:root {
  --bg-color: #141312;
  --surface-container: #1E1C1A;
  --surface-variant: #282522;
  --surface-variant-high: #332F2B;
  --primary: #E3C2AE;
  --primary-hover: #F2DAC9;
  --primary-container: #382C25;
  --on-primary: #1A1410;
  --on-surface: #EAE3DA;
  --on-surface-variant: #B5AA9E;
  --card-border: rgba(255, 255, 255, 0.10);
  --card-border-focus: rgba(227, 194, 174, 0.35);
  --divider: rgba(255, 255, 255, 0.06);
}

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

body {
  background-color: var(--bg-color);
  color: var(--on-surface);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", "Segoe UI", Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.76;
  letter-spacing: -0.015em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  word-break: keep-all;
  overflow-wrap: break-word;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.22);
}

.container {
  max-width: 740px;
  margin: 0 auto;
  padding: 24px 20px 80px;
}

/* Header & Tabs */
.header {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding-bottom: 22px;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--divider);
}

.title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

h1 {
  font-size: 1.45rem;
  font-weight: 700;
  color: #FFFFFF;
  letter-spacing: -0.025em;
  line-height: 1.35;
}

.effective-date {
  font-size: 0.82rem;
  color: var(--on-surface-variant);
  background-color: var(--surface-container);
  border: 1px solid var(--card-border);
  padding: 4px 10px;
  border-radius: 6px;
  font-weight: 500;
  letter-spacing: -0.01em;
}

.nav-tabs {
  display: inline-flex;
  gap: 4px;
  background-color: var(--surface-container);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 4px;
  align-self: flex-start;
}

.nav-tab {
  padding: 9px 18px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--on-surface-variant);
  background-color: transparent;
  border: none;
  border-radius: 9px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.18s ease;
  user-select: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-tab:hover {
  color: var(--on-surface);
  background-color: rgba(255, 255, 255, 0.04);
}

.nav-tab.active {
  color: var(--on-primary);
  background-color: var(--primary);
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

/* Content Area */
.content-section {
  display: none;
}

.content-section.active {
  display: block;
  animation: fadeIn 0.25s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.article {
  margin-bottom: 38px;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--divider);
}

.article:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.article-title {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 1.08rem;
  font-weight: 700;
  color: #FFFFFF;
  margin-bottom: 14px;
  letter-spacing: -0.02em;
}

.article-title::before {
  content: "";
  display: inline-block;
  width: 3.5px;
  height: 15px;
  background-color: var(--primary);
  border-radius: 2px;
  flex-shrink: 0;
}

.article p {
  color: var(--on-surface);
  font-size: 0.95rem;
  line-height: 1.78;
  margin-bottom: 14px;
  white-space: pre-line;
}

.article ol {
  margin: 10px 0 16px 20px;
  padding-left: 2px;
}

.article ol > li {
  margin-bottom: 10px;
  font-size: 0.95rem;
  line-height: 1.76;
  color: var(--on-surface);
}

.article ul {
  margin: 8px 0 14px 20px;
  padding-left: 2px;
}

.article ul > li {
  margin-bottom: 6px;
  font-size: 0.95rem;
  line-height: 1.76;
  color: var(--on-surface);
}

.article strong {
  color: #FFFFFF;
  font-weight: 700;
}

.article a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 500;
  transition: color 0.15s ease;
}

.article a:hover {
  color: var(--primary-hover);
}

/* Tables */
.table-wrapper {
  overflow-x: auto;
  margin: 18px 0 22px;
  background-color: var(--surface-container);
  border-radius: 12px;
  border: 1px solid var(--card-border);
  -webkit-overflow-scrolling: touch;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  text-align: left;
  min-width: 480px;
}

th, td {
  padding: 12px 16px;
  vertical-align: top;
}

th {
  background-color: rgba(255, 255, 255, 0.035);
  color: #FFFFFF;
  font-weight: 600;
  white-space: nowrap;
  border-bottom: 1px solid var(--card-border);
  font-size: 0.88rem;
  letter-spacing: -0.01em;
}

td {
  color: var(--on-surface);
  background-color: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  line-height: 1.62;
}

tr:last-child td {
  border-bottom: none;
}

tr:hover td {
  background-color: rgba(255, 255, 255, 0.015);
}

/* Footer / Contact */
.footer {
  margin-top: 56px;
  padding-top: 28px;
  border-top: 1px solid var(--divider);
  font-size: 0.85rem;
  color: var(--on-surface-variant);
  text-align: center;
  line-height: 1.65;
}

.footer a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s ease;
}

.footer a:hover {
  color: var(--primary-hover);
  text-decoration: underline;
}

/* Mobile Responsiveness */
@media (max-width: 600px) {
  .container {
    padding: 20px 16px 64px;
  }

  .header {
    gap: 14px;
    margin-bottom: 26px;
  }

  h1 {
    font-size: 1.3rem;
  }

  .nav-tabs {
    width: 100%;
    display: flex;
  }

  .nav-tab {
    flex: 1;
    padding: 10px 12px;
    font-size: 0.88rem;
  }

  .article-title {
    font-size: 1.02rem;
  }

  .article p,
  .article ol > li,
  .article ul > li {
    font-size: 0.93rem;
    line-height: 1.74;
  }

  th, td {
    padding: 10px 12px;
  }
}

/* ==========================================================================
   Utility & Landing Page
   ========================================================================== */

.is-hidden {
  display: none !important;
}

.landing-view {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 40px 24px 28px;
  overflow: hidden;
  background-color: var(--bg-color);
}

.landing-glow {
  position: absolute;
  top: 22%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(227, 194, 174, 0.12) 0%,
    rgba(227, 194, 174, 0.04) 45%,
    rgba(20, 19, 18, 0) 72%
  );
  pointer-events: none;
}

.landing-main {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 560px;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 36px;
}

.hero-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.mascot-wrap {
  width: 152px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-mascot {
  width: 100%;
  height: auto;
  display: block;
}

.hero-tagline {
  margin: 0 0 12px;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.02em;
  line-height: 1.45;
  word-break: keep-all;
}

.hero-desc {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 500;
  color: var(--on-surface);
  line-height: 1.7;
  word-break: keep-all;
}

.store-actions {
  width: 100%;
  max-width: 440px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.store-btn {
  height: 56px;
  padding: 0 20px;
  border: none;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.16s ease, background-color 0.16s ease, opacity 0.16s ease;
}

.store-btn:active {
  transform: scale(0.98);
}

.store-btn-play {
  background-color: var(--primary);
  color: var(--on-primary);
}

.store-btn-play:hover {
  background-color: var(--primary-hover);
}

.store-btn-apple {
  background-color: var(--surface-variant);
  color: var(--on-surface);
}

.store-btn-apple:hover {
  background-color: var(--surface-variant-high);
}

.store-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.store-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
  text-align: left;
}

.store-sub {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  opacity: 0.8;
}

.store-name {
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.landing-footer {
  position: relative;
  z-index: 1;
  width: 100%;
  margin-top: 32px;
  text-align: center;
  color: var(--on-surface-variant);
  font-size: 0.82rem;
}

.landing-legal-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 8px;
}

.landing-legal-links a {
  color: var(--on-surface);
  text-decoration: none;
  font-weight: 500;
  padding: 4px 6px;
  transition: color 0.16s ease;
}

.landing-legal-links a:hover {
  color: var(--primary);
}

.dot-sep {
  opacity: 0.45;
}

.copyright {
  margin: 0;
  font-size: 0.78rem;
  opacity: 0.75;
}

.copyright a {
  color: var(--primary);
  text-decoration: none;
}

.copyright a:hover {
  text-decoration: underline;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  background-color: rgba(10, 9, 9, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  backdrop-filter: blur(4px);
}

.modal-card {
  width: 100%;
  max-width: 340px;
  padding: 28px 24px 24px;
  border-radius: 24px;
  background-color: var(--surface-container);
  text-align: center;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.45);
}

.modal-badge {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background-color: var(--primary-container);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-badge svg {
  width: 22px;
  height: 22px;
}

.modal-title {
  margin: 0 0 8px;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--on-surface);
  letter-spacing: -0.02em;
}

.modal-desc {
  margin: 0 0 22px;
  font-size: 0.9rem;
  line-height: 1.65;
  color: var(--on-surface-variant);
  word-break: keep-all;
}

.modal-confirm-btn {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 999px;
  background-color: var(--primary-container);
  color: var(--primary);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.16s ease;
}

.modal-confirm-btn:hover {
  background-color: var(--surface-variant-high);
}

@media (max-width: 600px) {
  .landing-view {
    padding: 32px 20px 24px;
  }

  .landing-main {
    gap: 28px;
  }

  .mascot-wrap {
    width: 124px;
    margin-bottom: 20px;
  }

  .hero-tagline {
    font-size: 1.12rem;
  }

  .hero-desc {
    font-size: 1rem;
  }

  .store-actions {
    grid-template-columns: 1fr;
    max-width: 300px;
  }
}
