/* ==========================================================================
   티켓타임 인사이트 (TicketTime Insight) 전용 마스터 스타일시트 (insight.css)
   - 모바일 & 데스크톱 100% 완벽 반응형
   - Pure CSS 디자인 시스템 (Tailwind 의존성 완전 제거)
   - 최상의 가독성 & 모던 매거진 타이포그래피
   ========================================================================== */

/* 1. CSS 리셋 & 기본 변수 */
:root {
  --font-main: 'Pretendard', 'Noto Sans KR', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-body: #334155;
  --text-muted: #94a3b8;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-full: 9999px;
  --shadow-card: 0 4px 12px -2px rgba(15, 23, 42, 0.05), 0 2px 6px -1px rgba(15, 23, 42, 0.03);
  --shadow-hover: 0 16px 24px -4px rgba(15, 23, 42, 0.08), 0 6px 12px -2px rgba(15, 23, 42, 0.04);
}

[data-theme="dark"] {
  --bg-page: #0b0f17;
  --bg-card: #151d2a;
  --text-main: #f8fafc;
  --text-body: #cbd5e1;
  --text-muted: #64748b;
  --primary: #3b82f6;
  --primary-hover: #60a5fa;
  --primary-light: #1e293b;
  --border: #263346;
  --border-light: #1e293b;
  --shadow-card: 0 4px 12px -2px rgba(0, 0, 0, 0.3);
  --shadow-hover: 0 16px 24px -4px rgba(0, 0, 0, 0.4);
}

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

body {
  font-family: var(--font-main);
  background-color: var(--bg-page);
  color: var(--text-body);
  line-height: 1.65;
  letter-spacing: -0.02em;
  -webkit-font-smoothing: antialiased;
  word-break: keep-all;
  overflow-wrap: break-word;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease, background-color 0.15s ease;
}

/* 2. 레이아웃 컨테이너 */
.wrap {
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
}

.wrap-article {
  width: 100%;
  max-width: 820px;
  margin: 0 auto;
  padding: 0 16px;
}

/* 3. 헤더 (GNB) */
.in-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.03);
  height: 62px;
}

[data-theme="dark"] .in-header {
  background-color: rgba(21, 29, 42, 0.95);
}

.in-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.in-logo {
  display: flex;
  align-items: center;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.03em;
}

.in-logo .logo-badge {
  font-size: 1.25rem;
  margin-right: 6px;
}

.in-logo .logo-sub {
  color: var(--text-muted);
  font-weight: 400;
  font-style: italic;
  margin-left: 4px;
  font-size: 0.95rem;
}

.in-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.in-nav-link {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-body);
}

.in-nav-link:hover {
  background-color: var(--primary-light);
  color: var(--primary);
}

.in-nav-link.active {
  color: var(--primary);
  background-color: var(--primary-light);
  font-weight: 700;
}

.in-lang-box {
  display: flex;
  align-items: center;
  background-color: var(--primary-light);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  padding: 4px 8px;
}

.in-lang-select {
  border: none;
  background: transparent;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-body);
  outline: none;
  cursor: pointer;
}

.in-theme-btn {
  background: none;
  border: none;
  font-size: 15px;
  padding: 6px;
  border-radius: 8px;
  cursor: pointer;
  color: var(--text-body);
  display: flex;
  align-items: center;
  justify-content: center;
}

.in-theme-btn:hover {
  background-color: var(--primary-light);
}

/* 4. 메인 목록 소개 배너 */
.in-intro {
  padding: 36px 0 24px;
}

.in-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background-color: var(--primary-light);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 12px;
}

.in-title-main {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 6px;
  letter-spacing: -0.03em;
}

.in-desc-main {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* 5. 카드 그리드 시스템 */
.in-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

@media (max-width: 900px) {
  .in-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
}

@media (max-width: 600px) {
  .in-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.in-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease, border-color 0.25s ease;
}

.in-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary);
}

.in-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: var(--primary-light);
  overflow: hidden;
}

.in-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.in-card:hover .in-card-thumb img {
  transform: scale(1.04);
}

.in-card-body {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  justify-content: space-between;
}

.in-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 0.75rem;
}

.in-card-tag {
  background-color: var(--primary-light);
  color: var(--primary);
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 4px;
  letter-spacing: 0.02em;
}

.in-card-date {
  color: var(--text-muted);
  font-weight: 500;
}

.in-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.45;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.15s ease;
}

.in-card:hover .in-card-title {
  color: var(--primary);
}

.in-card-footer {
  border-top: 1px solid var(--border-light);
  padding-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--primary);
  font-weight: 700;
}

/* 6. 페이지네이션 */
.in-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 36px 0 60px;
}

.in-page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border-radius: 10px;
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-body);
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.in-page-btn:hover {
  background-color: var(--primary-light);
  color: var(--primary);
  border-color: var(--primary);
}

.in-page-btn.active {
  background-color: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  font-weight: 800;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.3);
}

.in-page-dots {
  color: var(--text-muted);
  font-size: 0.8rem;
  padding: 0 4px;
}

/* 7. 상세 아티클 스타일 */
.in-article-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
  padding: 36px 44px;
  margin: 28px 0 48px;
}

@media (max-width: 640px) {
  .in-article-card {
    padding: 22px 18px;
    border-radius: var(--radius-lg);
    margin: 16px 0 36px;
  }
}

.in-art-header {
  margin-bottom: 24px;
}

.in-art-badge-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.in-art-title {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.35;
  margin-bottom: 14px;
  letter-spacing: -0.03em;
}

@media (max-width: 640px) {
  .in-art-title {
    font-size: 1.45rem;
  }
}

.in-art-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-light);
}

/* 대표 이미지 크기 단정하게 제한 (세로 최대 320px) */
.in-art-cover {
  width: 100%;
  max-height: 320px;
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 24px;
  background-color: var(--primary-light);
  border: 1px solid var(--border);
}

.in-art-cover img {
  width: 100%;
  height: 100%;
  max-height: 320px;
  object-fit: cover;
  display: block;
}

/* 💡 3초 핵심 요약 박스 */
.in-summary-box {
  background: linear-gradient(135deg, #eff6ff 0%, #eef2ff 100%);
  border: 1px solid #bfdbfe;
  border-radius: 14px;
  padding: 20px 24px;
  margin-bottom: 28px;
}

[data-theme="dark"] .in-summary-box {
  background: linear-gradient(135deg, #172554 0%, #1e1b4b 100%);
  border-color: #1e3a8a;
}

.in-summary-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  font-weight: 800;
  color: #1e40af;
  margin-bottom: 10px;
}

[data-theme="dark"] .in-summary-label {
  color: #93c5fd;
}

.in-summary-content {
  font-size: 0.95rem;
  color: #1e293b;
  line-height: 1.75;
  font-weight: 500;
}

[data-theme="dark"] .in-summary-content {
  color: #e2e8f0;
}

.in-summary-content ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.in-summary-content li {
  position: relative;
  padding-left: 18px;
  margin-bottom: 8px;
  line-height: 1.7;
}

.in-summary-content li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--primary);
  font-weight: 800;
  font-size: 1.1rem;
}

/* 8. 본문 타이포그래피 */
.in-body {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--text-body);
  border-top: 1px solid var(--border-light);
  padding-top: 24px;
}

.in-body p {
  margin-bottom: 1.5rem;
}

.in-body h2 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 2.5rem 0 1rem;
  padding-left: 12px;
  border-left: 4px solid var(--primary);
  line-height: 1.4;
}

.in-body h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  margin: 2rem 0 0.75rem;
  line-height: 1.4;
}

.in-body ul, .in-body ol {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}

.in-body li {
  margin-bottom: 0.5rem;
  line-height: 1.75;
}

.in-body img {
  max-width: 100% !important;
  height: auto !important;
  border-radius: 12px;
  margin: 1.5rem auto;
  display: block;
}

.in-body blockquote {
  border-left: 4px solid var(--primary);
  background-color: var(--primary-light);
  padding: 14px 18px;
  border-radius: 0 10px 10px 0;
  margin: 1.5rem 0;
  color: var(--text-body);
}

/* 목차 */
.toc-box {
  background-color: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 22px;
  margin: 1.5rem 0 2rem;
}

.toc-title {
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--text-main);
  margin-bottom: 10px;
}

.toc-list {
  list-style: none !important;
  padding-left: 0 !important;
  margin: 0 !important;
}

.toc-list li {
  margin-bottom: 6px;
  font-size: 0.88rem;
}

.toc-list li a {
  color: var(--primary);
  font-weight: 600;
}

.toc-list li a:hover {
  text-decoration: underline;
}

.toc-sub-item {
  padding-left: 16px;
}

/* 광고 컨테이너 (애드센스 100% 가로폭 및 렌더링 보장) */
.ads-container {
  display: block;
  width: 100%;
  margin: 32px 0;
  background-color: var(--bg-page);
  border: 1px dashed var(--border);
  border-radius: 12px;
  padding: 14px 10px;
  text-align: center;
  overflow: hidden;
  box-sizing: border-box;
}

.ads-label {
  display: block;
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.ads-container .adsbygoogle {
  display: block !important;
  width: 100% !important;
  min-height: 100px;
  margin: 0 auto;
}

/* 9. 소셜 공유 바 */
.in-share-bar {
  margin-top: 36px;
  padding: 20px 24px;
  background-color: var(--bg-page);
  border: 1px solid var(--border);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
}

.in-share-text {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.in-share-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.in-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid var(--border);
  background-color: var(--bg-card);
  color: var(--text-body);
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}

.in-share-btn:hover {
  background-color: var(--primary-light);
  color: var(--primary);
}

.in-share-btn.btn-x {
  background-color: #000000;
  color: #ffffff;
  border-color: #000000;
}

.in-share-btn.btn-x:hover {
  background-color: #262626;
}

/* 10. 연관 아티클 추천 그리드 */
.in-rel-section {
  margin-top: 48px;
}

.in-section-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* 11. 푸터 스타일 */
.in-footer {
  background-color: #0f172a;
  color: #94a3b8;
  padding: 56px 0 40px;
  margin-top: 60px;
  border-top: 1px solid #1e293b;
}

.in-footer-inner {
  text-align: center;
}

.in-footer-logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.in-footer-sub {
  font-size: 0.82rem;
  color: #64748b;
  max-width: 580px;
  margin: 0 auto 28px;
  line-height: 1.6;
}

.in-family-box {
  background-color: #1e293b;
  border: 1px solid #334155;
  border-radius: 14px;
  padding: 16px 20px;
  max-width: 740px;
  margin: 0 auto 28px;
}

.in-family-title {
  font-size: 0.72rem;
  font-weight: 800;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 10px;
}

.in-family-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #e2e8f0;
}

.in-family-links a:hover {
  color: #60a5fa;
}

.in-legal-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 0.78rem;
  color: #64748b;
  margin-bottom: 20px;
}

.in-legal-links a:hover {
  color: #cbd5e1;
}

.in-copy {
  font-size: 0.72rem;
  color: #475569;
}

/* 12. 번역 위젯 숨김 */
#google_translate_element {
  position: absolute !important;
  left: -9999px !important;
  z-index: -999 !important;
}
.goog-te-banner-frame.skiptranslate {
  display: none !important;
}
body {
  top: 0px !important;
}
