/* 테이크 독 사이트 공통 스타일 — 색상 토큰, 글자 크기 체계, 버튼, 머리글·바닥글 */

/* 색은 인턴 1호기 앱 화면에서 뽑았다. 바탕은 앱의 가장 어두운 색(#131211)보다 한 단계 어둡게 해서
   앱 화면이 바탕에서 떠 보이게 한다. 주황은 주 버튼, 가격, 제목과 문구의 핵심 구절, 아이콘에 포인트로 쓴다 */
:root {
  --bg: #0a0a09;
  --panel: #1f1e1d;
  --panel-2: #262624;
  --line: rgba(255, 244, 230, 0.1);
  --line-strong: rgba(255, 244, 230, 0.16);
  --text: #f2efe9;
  --text-2: #a19a90;
  --accent: #e8913a;
  --accent-hover: #f2a04f;
  --accent-ink: #1e1308;
  --radius: 14px;
  --container: 1200px;
  --gutter: 32px;
  --header-h: 64px;
  /* 글자 크기는 이 여섯 단계만 쓴다 */
  --fs-display: clamp(40px, 5vw, 72px);
  --fs-h2: clamp(30px, 3.2vw, 44px);
  --fs-h3: clamp(22px, 2vw, 28px);
  --fs-lead: clamp(17px, 1.4vw, 20px);
  --fs-body: 17px;
  --fs-small: 14px;
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, system-ui,
    "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif;
  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  word-break: keep-all;
  overflow-wrap: break-word;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
p {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.nowrap {
  white-space: nowrap;
}

/* 글 속 포인트 색 */
.pt {
  color: var(--accent);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* 버튼 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-size: var(--fs-small);
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 16px;
}

.btn--primary:hover {
  background: var(--accent-hover);
}

.btn--light {
  background: var(--text);
  color: #141312;
}

.btn--light:hover {
  background: #fff;
}

.btn--ghost {
  background: transparent;
  border-color: var(--line-strong);
  color: var(--text);
}

.btn--ghost:hover {
  background: rgba(255, 244, 230, 0.06);
}

.btn--sm {
  min-height: 40px;
  padding: 0 18px;
}

.btn[aria-disabled="true"] {
  background: transparent;
  border-color: var(--line);
  color: var(--text-2);
  cursor: not-allowed;
}

/* 글 링크: 화살표 대신 밑줄로 링크임을 보인다 */
.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 6px;
  transition: text-decoration-color 0.18s ease;
}

.text-link:hover {
  text-decoration-color: var(--text);
}

/* 머리글 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: rgba(10, 10, 9, 0.76);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 100%;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  white-space: nowrap;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--text);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.site-nav a {
  padding: 10px 12px;
  border-radius: 8px;
  font-size: var(--fs-small);
  font-weight: 500;
  color: var(--text-2);
  transition: color 0.15s ease;
}

.site-nav a:hover {
  color: var(--text);
}

/* 바닥글 */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 48px;
  color: var(--text-2);
  font-size: var(--fs-small);
}

.site-footer__top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 24px 48px;
}

.site-footer__note {
  max-width: 520px;
}

.site-footer__note a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 정책·안내 같은 글 페이지(환불 정책, 결제 뒤 안내 등) */
.doc {
  padding-top: 88px;
  padding-bottom: 120px;
}

/* 머리글과 같은 왼쪽 선에 두고, 글 줄 길이만 줄인다 */
.doc > * {
  max-width: 760px;
}

.doc h1 {
  font-size: var(--fs-h2);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.doc h2 {
  margin-top: 48px;
  font-size: var(--fs-h3);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.doc__lead {
  margin-top: 16px;
  font-size: var(--fs-lead);
  color: var(--text-2);
}

.doc ol {
  margin-top: 32px;
  padding-left: 1.4em;
  list-style: decimal;
}

.doc ol li {
  padding-left: 6px;
}

.doc ol li + li {
  margin-top: 14px;
}

.doc li::marker {
  color: var(--accent);
  font-weight: 700;
}

.doc p + p {
  margin-top: 12px;
}

.doc a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 초안 표시: 공개 전에 지운다 */
.doc__draft {
  margin-bottom: 32px;
  padding: 16px 20px;
  border: 1px dashed rgba(232, 145, 58, 0.6);
  border-radius: 12px;
  font-size: var(--fs-small);
  color: var(--text);
}

.doc h3 {
  margin-top: 28px;
  font-size: var(--fs-lead);
  font-weight: 700;
}

/* 문서 안의 폴더 경로. 한글 고정폭 글꼴은 \를 ₩로 그리므로 Consolas 계열을 먼저 쓴다 */
.doc code {
  font-family: Consolas, "SF Mono", Menlo, monospace;
  font-size: 0.88em;
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--panel-2);
  overflow-wrap: anywhere;
}

.doc ul {
  margin-top: 12px;
  padding-left: 1.2em;
  list-style: disc;
}

.doc ul li + li {
  margin-top: 6px;
}

.doc ol ol,
.doc ol ul {
  margin-top: 8px;
}

.doc table {
  width: 100%;
  margin-top: 16px;
  border-collapse: collapse;
  font-size: var(--fs-small);
}

.doc th,
.doc td {
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  text-align: left;
  vertical-align: top;
}

.doc th {
  background: var(--panel);
  font-weight: 600;
}

.doc__table {
  overflow-x: auto;
}

/* 휴대폰에서는 표를 좁히지 않고 표 칸 안에서만 옆으로 밀어 본다 */
@media (max-width: 760px) {
  .doc__table table {
    min-width: 640px;
  }
}

.doc__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 28px;
  margin-top: 40px;
}

.doc__actions a.btn {
  text-decoration: none;
}

.site-footer__bottom {
  margin-top: 40px;
}

@media (max-width: 760px) {
  :root {
    --gutter: 20px;
    --header-h: 58px;
  }

  /* 넓은 화면에서만 쓰는 줄바꿈 */
  .br-wide {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  /* 확인용으로 움직임을 켠 경우(motion 클래스)는 예외로 둔다 */
  html:not(.motion) *,
  html:not(.motion) *::before,
  html:not(.motion) *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
