:root {
  --primary: #1e3a8a;
  --primary-light: #2563eb;
  --primary-hover: #1d4ed8;
  --secondary: #10b981;
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #0f172a;
  --text-sub: #475569;
  --text-muted: #64748b;
  --border: #e2e8f0;
  --accent-a: #0284c7;
  --accent-b: #7c3aed;
  --radius: 14px;
  --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.06), 0 2px 4px -2px rgb(0 0 0 / 0.06);
  --shadow-lg: 0 12px 24px -4px rgb(15 23 42 / 0.08);
}

html,
body {
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: "Pretendard", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Apple SD Gothic Neo", "Noto Sans KR", "Noto Sans JP", "Noto Sans TC", sans-serif;
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.7;
  font-size: 16px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

/* Header & Navigation */
.site-header {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  width: 100%;
  max-width: 100vw;
  box-sizing: border-box;
}

.header-top {
  border-bottom: 1px solid #f1f5f9;
  width: 100%;
  box-sizing: border-box;
}

.header-top-inner {
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  padding: 8px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-sizing: border-box;
}

.brand-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  text-decoration: none;
}

.brand-logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 8px;
  flex-shrink: 0;
}

.brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.5px;
  white-space: nowrap;
}

.brand-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  display: none;
  white-space: nowrap;
}

@media (min-width: 900px) {
  .brand-sub {
    display: inline-block;
    margin-left: 6px;
    padding-left: 10px;
    border-left: 1px solid var(--border);
  }
}

.header-nav-bar {
  background-color: #ffffff;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
}

.header-nav-inner {
  max-width: 1240px;
  width: 100%;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
  overflow: hidden;
}

.main-nav {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.main-nav::-webkit-scrollbar {
  display: none;
}

.nav-links-top {
  display: flex;
  gap: 6px;
  list-style: none;
  white-space: nowrap;
  padding: 6px 0;
  margin: 0;
}

.nav-links-top a {
  color: var(--text-sub);
  font-weight: 600;
  font-size: 0.88rem;
  transition: color 0.18s, background-color 0.18s;
  padding: 6px 10px;
  border-radius: 6px;
  text-decoration: none;
  display: inline-block;
  white-space: nowrap;
}

.nav-links-top a:hover,
.nav-links-top a.active {
  color: var(--primary-light);
  background-color: #f1f5f9;
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 2px;
  background: #f1f5f9;
  padding: 3px;
  border-radius: 8px;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 3px 7px;
  border-radius: 5px;
  color: var(--text-sub);
  transition: all 0.15s ease;
  white-space: nowrap;
  text-decoration: none;
  min-width: 26px;
  text-align: center;
}

.lang-btn:hover {
  background: #e2e8f0;
  color: var(--primary);
}

.lang-btn.active {
  background: var(--primary-light);
  color: #ffffff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

/* Main Layout Container (2-Column with Sidebar) */
.container {
  max-width: 1180px;
  margin: 28px auto;
  padding: 0 20px;
  flex: 1;
  width: 100%;
  box-sizing: border-box;
}

.layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 32px;
  align-items: start;
  width: 100%;
  box-sizing: border-box;
}

@media (max-width: 960px) {
  .layout-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }
}

.main-col {
  min-width: 0;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

/* AdSense Box */
.ad-box {
  margin: 20px 0;
  text-align: center;
  min-height: 90px;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px;
  overflow: hidden;
  max-width: 100%;
  box-sizing: border-box;
}

.ad-box ins.adsbygoogle {
  max-width: 100% !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
}

/* Hero Banner */
.hero {
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: #ffffff;
  border-radius: var(--radius);
  padding: 2.25rem 2rem;
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
  width: 100%;
  box-sizing: border-box;
}

background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
color: #ffffff;
border-radius: var(--radius);
padding: 2.25rem 2rem;
margin-bottom: 2rem;
box-shadow: var(--shadow);
}

.hero h1 {
  font-size: 1.85rem;
  font-weight: 800;
  margin-bottom: 0.6rem;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.hero p {
  font-size: 1rem;
  color: #e0e7ff;
  max-width: 780px;
  line-height: 1.6;
}

/* Section Headers */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 1.1rem;
  flex-wrap: wrap;
  gap: 8px;
}

.section-header h2 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-main);
}

.section-more {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--primary-light);
}

.section-more:hover {
  text-decoration: underline;
}

/* Post & Compare Card Grid */
.post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 2.5rem;
  width: 100%;
  box-sizing: border-box;
}

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

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.post-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card-thumb {
  width: 100%;
  height: 175px;
  object-fit: cover;
  background: #f1f5f9;
  border-bottom: 1px solid var(--border);
}

.card-body {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.badge {
  display: inline-block;
  background: #eff6ff;
  color: var(--primary-light);
  font-size: 0.76rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
  width: fit-content;
}

.badge-green {
  background: #ecfdf5;
  color: #059669;
}

.card-title {
  font-size: 1.12rem;
  font-weight: 700;
  line-height: 1.42;
  margin-bottom: 10px;
  color: var(--text-main);
}

.card-excerpt {
  font-size: 0.9rem;
  color: var(--text-sub);
  line-height: 1.58;
  margin-bottom: 14px;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  font-size: 0.8rem;
  color: #94a3b8;
  border-top: 1px solid #f1f5f9;
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Compare Detail Page */
.compare-header-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 28px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.winner-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.winner-pill {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-sub);
}

.winner-pill strong {
  color: var(--primary-light);
}

.compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

@media (max-width: 680px) {
  .compare-grid {
    grid-template-columns: 1fr;
  }
}

.stock-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 24px;
  box-shadow: var(--shadow);
}

.stock-card.badge-a {
  border-top: 4px solid var(--accent-a);
}

.stock-card.badge-b {
  border-top: 4px solid var(--accent-b);
}

.stock-card h2 {
  font-size: 1.45rem;
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 4px;
}

.stock-ticker {
  font-weight: 800;
  color: var(--text-main);
}

.stock-sub {
  font-size: 0.82rem;
  background: #f1f5f9;
  color: var(--text-sub);
  padding: 2px 7px;
  border-radius: 4px;
  font-weight: 600;
}

.metrics-list {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.metric-row {
  display: flex;
  justify-content: space-between;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--border);
  font-size: 0.93rem;
}

.metric-label {
  color: var(--text-muted);
}

.metric-value {
  font-weight: 700;
  color: var(--text-main);
}

.metric-highlight {
  color: var(--secondary);
}

/* Interactive Dividend Calculator */
.calculator-box {
  background: #ffffff;
  border: 2px solid #dbeafe;
  border-radius: var(--radius);
  padding: 26px;
  margin: 24px 0;
  box-shadow: var(--shadow-lg);
}

.calc-title {
  font-size: 1.32rem;
  font-weight: 800;
  margin-bottom: 6px;
  color: var(--text-main);
}

.calc-desc {
  color: var(--text-sub);
  font-size: 0.92rem;
  margin-bottom: 20px;
}

.slider-group {
  margin-bottom: 20px;
}

.slider-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  margin-bottom: 10px;
}

.target-amount-display {
  color: var(--primary-light);
  font-size: 1.35rem;
  font-weight: 800;
}

input[type="range"] {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: #cbd5e1;
  outline: none;
  cursor: pointer;
  accent-color: var(--primary-light);
}

/* Stock Info Card (기본 정보 카드: 주가, 배당률, 배당금, 배당성향, 5년성장) */
.stock-info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
}

.info-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 14px;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 10px;
}

.info-header-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.info-stock-name {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 0;
}

.info-header-right {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.info-price-label {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.info-price-val {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--primary);
}

.info-metric-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}

@media (max-width: 1024px) {
  .info-metric-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 600px) {
  .info-metric-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.info-metric-item {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  flex-direction: column;
}

.info-metric-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 4px;
}

.info-metric-val {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.3;
}

.info-metric-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.highlight-blue {
  color: #2563eb !important;
}

.highlight-green {
  color: #059669 !important;
}

.highlight-red {
  color: #dc2626 !important;
}

/* Calculator Top Header & Tax Toggle */
.calc-top-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 14px;
}

.tax-toggle-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f1f5f9;
  padding: 4px 8px;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.tax-toggle-label {
  font-size: 0.82rem;
  color: var(--text-sub);
  font-weight: 600;
}

.slider-group-box {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: 24px;
}

.slider-row {
  background: #ffffff;
  border: 1px solid #f1f5f9;
  border-radius: 10px;
  padding: 12px 14px;
}

.calc-result-grid.three-col {
  grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 768px) {
  .calc-result-grid.three-col {
    grid-template-columns: 1fr;
  }
}

.result-card.card-c {
  border-left: 4px solid var(--secondary);
}

/* Roadmap & Tier Section */
.roadmap-section,
.tier-section {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-top: 24px;
}

/* calculator-box 내부에 위치할 때는 이중 카드 테두리/패딩 제거 */
.calculator-box .roadmap-section,
.calculator-box .tier-section {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
}

.roadmap-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
}

.roadmap-chart-container {
  background: #f8fafc;
  border: 1px solid #f1f5f9;
  border-radius: 10px;
  padding: 12px;
  overflow-x: auto;
}

.sim-note {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 10px;
  line-height: 1.5;
}

.calc-result-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 16px;
}

@media (max-width: 600px) {

  /* Stock Info Card (기본 정보 카드: 주가, 배당률, 배당금, 배당성향, 5년성장) */
  .stock-info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 24px;
    margin-bottom: 22px;
    box-shadow: var(--shadow);
  }

  .info-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 14px;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 10px;
  }

  .info-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
  }

  .info-stock-name {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0;
  }

  .info-header-right {
    display: flex;
    align-items: baseline;
    gap: 8px;
  }

  .info-price-label {
    font-size: 0.88rem;
    color: var(--text-muted);
  }

  .info-price-val {
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--primary);
  }

  .info-metric-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
  }

  @media (max-width: 1024px) {
    .info-metric-grid {
      grid-template-columns: repeat(3, 1fr);
    }
  }

  @media (max-width: 600px) {
    .info-metric-grid {
      grid-template-columns: repeat(2, 1fr);
    }
  }

  .info-metric-item {
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px;
    display: flex;
    flex-direction: column;
  }

  .info-metric-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 4px;
  }

  .info-metric-val {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.3;
  }

  .info-metric-sub {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 4px;
  }

  .highlight-blue {
    color: #2563eb !important;
  }

  .highlight-green {
    color: #059669 !important;
  }

  .highlight-red {
    color: #dc2626 !important;
  }

  /* Calculator Top Header & Tax Toggle */
  .calc-top-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 14px;
  }

  .tax-toggle-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f1f5f9;
    padding: 4px 8px;
    border-radius: 8px;
    border: 1px solid var(--border);
  }

  .tax-toggle-label {
    font-size: 0.82rem;
    color: var(--text-sub);
    font-weight: 600;
  }

  .slider-group-box {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 24px;
  }

  .slider-row {
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 10px;
    padding: 12px 14px;
  }

  .calc-result-grid.three-col {
    grid-template-columns: repeat(3, 1fr);
  }

  @media (max-width: 768px) {
    .calc-result-grid.three-col {
      grid-template-columns: 1fr;
    }
  }

  .result-card.card-c {
    border-left: 4px solid var(--secondary);
  }

  /* Roadmap & Tier Section */
  .roadmap-section,
  .tier-section {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    margin-top: 24px;
  }

  /* calculator-box 내부에 위치할 때는 이중 카드 테두리/패딩 제거 */
  .calculator-box .roadmap-section,
  .calculator-box .tier-section {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
  }

  .roadmap-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 12px;
  }

  .roadmap-chart-container {
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    border-radius: 10px;
    padding: 12px;
    overflow-x: auto;
  }

  .sim-note {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 10px;
    line-height: 1.5;
  }

  .calc-result-grid {
    grid-template-columns: 1fr;
  }
}

.result-card {
  background: #f8fafc;
  border-radius: 10px;
  padding: 18px;
  border: 1px solid var(--border);
  text-align: center;
}

.result-card.card-a {
  border-left: 4px solid var(--accent-a);
}

.result-card.card-b {
  border-left: 4px solid var(--accent-b);
}

.result-label {
  font-size: 0.85rem;
  color: var(--text-sub);
  font-weight: 600;
  margin-bottom: 6px;
}

.result-value {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 4px;
}

.result-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Article / Post Content Styling */
.article-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 34px 30px;
  box-shadow: var(--shadow);
}

@media (max-width: 640px) {
  .article-wrap {
    padding: 22px 18px;
  }
}

.article-header {
  border-bottom: 1px solid var(--border);
  padding-bottom: 18px;
  margin-bottom: 24px;
}

.article-title {
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 8px 0 12px;
  color: var(--text-main);
}

.article-meta {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.entry-content h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #1e293b;
  margin: 32px 0 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid #e2e8f0;
}

.entry-content h3 {
  font-size: 1.18rem;
  font-weight: 700;
  color: var(--primary);
  margin: 24px 0 10px;
}

.entry-content h4 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 18px 0 8px;
}

.entry-content p {
  margin-bottom: 16px;
  color: #1e293b;
  word-break: keep-all;
}

.entry-content ul,
.entry-content ol {
  margin: 0 0 18px 22px;
}

.entry-content li {
  margin-bottom: 8px;
}

.entry-content figure {
  margin: 24px auto;
  text-align: center;
}

.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
}

.entry-content figcaption {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 6px;
}

.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 0.92rem;
}

.entry-content table th,
.entry-content table td {
  border: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
}

.entry-content table th {
  background: #f1f5f9;
  font-weight: 700;
}

/* Prev / Next Navigation */
.post-nav-links {
  margin-top: 30px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

@media (max-width: 600px) {
  .post-nav-links {
    flex-direction: column;
  }
}

.nav-item {
  flex: 1;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.88rem;
  transition: border-color 0.15s;
}

.nav-item:hover {
  border-color: var(--primary-light);
}

.nav-item span {
  display: block;
  font-size: 0.76rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.nav-item strong {
  color: var(--primary);
}

/* Sidebar Widgets */
.sidebar-widget {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
}

.widget-title {
  font-size: 1.02rem;
  font-weight: 800;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text-main);
}

.recent-list {
  list-style: none;
}

.recent-list li {
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px dashed #e2e8f0;
  font-size: 0.88rem;
  line-height: 1.45;
}

.recent-list li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

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

/* Footer */
.site-footer {
  margin-top: 60px;
  background: #0f172a;
  color: #94a3b8;
  padding: 36px 20px;
  text-align: center;
  font-size: 0.86rem;
}

.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
}

/* 추가 반응형 및 1:1 비교 엔진 스타일 [아사히나] */

html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

/* 3탭 버튼 */
.calc-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 8px;
  margin-bottom: 18px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.calc-tab-btn {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 0.92rem;
  font-weight: 700;
  color: #475569;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
}

.calc-tab-btn:hover {
  background: #e2e8f0;
}

.calc-tab-btn.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
  box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

/* 컨트롤 행 */
.control-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 14px;
  align-items: center;
}

.control-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.control-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: #475569;
}

.btn-group {
  display: inline-flex;
  background: #f1f5f9;
  border-radius: 7px;
  padding: 2px;
  border: 1px solid #e2e8f0;
}

.toggle-btn {
  background: transparent;
  border: none;
  border-radius: 5px;
  padding: 4px 10px;
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
}

.toggle-btn.active {
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* 기간 칩 */
.period-chips-wrap {
  display: flex;
  align-items: center;
  margin-top: 14px;
  flex-wrap: wrap;
  gap: 8px;
}

.period-chips {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 2px 2px 6px 2px;
}

.period-chips::-webkit-scrollbar {
  display: none;
  height: 0;
}

.chip-btn {
  flex-shrink: 0;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 0.82rem;
  font-weight: 700;
  color: #334155;
  cursor: pointer;
  white-space: nowrap;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.chip-btn:hover:not(:disabled) {
  background: #f8fafc;
  border-color: #2563eb;
}

.chip-btn.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
}

.chip-btn.disabled,
.chip-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #f1f5f9;
}

/* SVG 차트 박스 */
.chart-container-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.03);
}

.tax-chart-container {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px;
}

/* Portfolio Visualizer 형식 테이블 */
.table-scroll-wrapper {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #ffffff;
}

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

.stat-perf-table th {
  background: #f8fafc;
  color: #475569;
  font-weight: 700;
  padding: 10px 14px;
  border-bottom: 2px solid #e2e8f0;
}

.stat-perf-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #f1f5f9;
  color: #1e293b;
}

.stat-perf-table tr:last-child td {
  border-bottom: none;
}

.stat-perf-table tr:hover td {
  background: #f8fafc;
}

/* 모바일 미디어 쿼리 */
@media (max-width: 640px) {
  .header-top-inner {
    padding: 8px 12px;
  }

  .header-nav-inner {
    padding: 0 12px;
  }

  .brand-title {
    font-size: 1.2rem;
  }

  .control-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  /* Stock Info Card (기본 정보 카드: 주가, 배당률, 배당금, 배당성향, 5년성장) */
  .stock-info-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 24px;
    margin-bottom: 22px;
    box-shadow: var(--shadow);
  }

  .info-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 14px;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 10px;
  }

  .info-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
  }

  .info-stock-name {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0;
  }

  .info-header-right {
    display: flex;
    align-items: baseline;
    gap: 8px;
  }

  .info-price-label {
    font-size: 0.88rem;
    color: var(--text-muted);
  }

  .info-price-val {
    font-size: 1.45rem;
    font-weight: 800;
    color: var(--primary);
  }

  .info-metric-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
  }

  @media (max-width: 1024px) {
    .info-metric-grid {
      grid-template-columns: repeat(3, 1fr);
    }
  }

  @media (max-width: 600px) {
    .info-metric-grid {
      grid-template-columns: repeat(2, 1fr);
    }
  }

  .info-metric-item {
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px;
    display: flex;
    flex-direction: column;
  }

  .info-metric-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 4px;
  }

  .info-metric-val {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.3;
  }

  .info-metric-sub {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 4px;
  }

  .highlight-blue {
    color: #2563eb !important;
  }

  .highlight-green {
    color: #059669 !important;
  }

  .highlight-red {
    color: #dc2626 !important;
  }

  /* Calculator Top Header & Tax Toggle */
  .calc-top-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 14px;
  }

  .tax-toggle-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f1f5f9;
    padding: 4px 8px;
    border-radius: 8px;
    border: 1px solid var(--border);
  }

  .tax-toggle-label {
    font-size: 0.82rem;
    color: var(--text-sub);
    font-weight: 600;
  }

  .slider-group-box {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 24px;
  }

  .slider-row {
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 10px;
    padding: 12px 14px;
  }

  .calc-result-grid.three-col {
    grid-template-columns: repeat(3, 1fr);
  }

  @media (max-width: 768px) {
    .calc-result-grid.three-col {
      grid-template-columns: 1fr;
    }
  }

  .result-card.card-c {
    border-left: 4px solid var(--secondary);
  }

  /* Roadmap & Tier Section */
  .roadmap-section,
  .tier-section {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    margin-top: 24px;
  }

  /* calculator-box 내부에 위치할 때는 이중 카드 테두리/패딩 제거 */
  .calculator-box .roadmap-section,
  .calculator-box .tier-section {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
  }

  .roadmap-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 12px;
  }

  .roadmap-chart-container {
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    border-radius: 10px;
    padding: 12px;
    overflow-x: auto;
  }

  .sim-note {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 10px;
    line-height: 1.5;
  }

  .calc-result-grid {
    grid-template-columns: 1fr !important;
  }

  .winner-badges {
    flex-direction: column !important;
  }

  .container {
    padding: 0 12px;
  }
}

/* 404 Error Page Styling */
.error-404-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 30px 10px 60px;
  min-height: 60vh;
}

.error-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 48px 36px;
  max-width: 680px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.cat-illustration-box {
  position: relative;
  display: inline-block;
  margin-bottom: 20px;
}

.cat-404-img {
  width: 120px;
  height: 120px;
  object-fit: contain;
  border-radius: 24px;
  box-shadow: 0 8px 20px rgba(30, 58, 138, 0.12);
  transition: transform 0.25s ease;
}

.cat-404-img:hover {
  transform: rotate(-5deg) scale(1.05);
}

.cat-status-badge {
  position: absolute;
  bottom: -6px;
  right: -10px;
  background: #ef4444;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 4px 8px;
  border-radius: 20px;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.35);
}

.error-title {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 12px;
  letter-spacing: -0.5px;
}

.error-desc {
  font-size: 0.96rem;
  color: var(--text-sub);
  line-height: 1.65;
  margin-bottom: 28px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.error-action-btns {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.btn-primary-action {
  background: var(--primary-light);
  color: #ffffff;
  padding: 10px 22px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  transition: background-color 0.18s, transform 0.15s;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.btn-primary-action:hover {
  background: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-secondary-action {
  background: #f1f5f9;
  color: var(--text-main);
  border: 1px solid var(--border);
  padding: 10px 18px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  transition: all 0.18s;
}

.btn-secondary-action:hover {
  background: #e2e8f0;
  color: var(--primary);
}

.quick-nav-section {
  border-top: 1px solid var(--border);
  padding-top: 28px;
  text-align: left;
}

.quick-nav-heading {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 14px;
}

.quick-nav-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.quick-nav-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  text-decoration: none;
  transition: all 0.18s ease;
}

.quick-nav-card:hover {
  background: #ffffff;
  border-color: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.quick-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
}

.quick-nav-card strong {
  display: block;
  font-size: 0.88rem;
  color: var(--text-main);
  margin-bottom: 2px;
}

.quick-nav-card p {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.35;
  margin: 0;
}

@media (max-width: 640px) {
  .error-card {
    padding: 32px 18px;
  }

  .error-title {
    font-size: 1.35rem;
  }

  .quick-nav-grid {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Mobile Header & Layout Responsive Enhancements [아사히나]
   ========================================================================== */
@media (max-width: 768px) {
  .header-top-inner {
    padding: 6px 12px;
    gap: 8px;
  }

  .brand-wrap {
    gap: 8px;
  }

  .brand-logo {
    width: 30px;
    height: 30px;
  }

  .brand-title {
    font-size: 1.15rem;
  }

  .lang-switcher {
    gap: 2px;
    padding: 2px;
    border-radius: 6px;
  }

  .lang-btn {
    font-size: 0.7rem;
    padding: 2px 6px;
    min-width: 24px;
  }

  .header-nav-inner {
    padding: 0 12px;
  }

  .nav-links-top {
    gap: 4px;
    padding: 5px 0;
  }

  .nav-links-top a {
    font-size: 0.82rem;
    padding: 5px 8px;
  }

  .container {
    margin: 14px auto;
    padding: 0 12px;
    width: 100%;
    max-width: 100%;
  }

  .hero {
    padding: 1.4rem 1.15rem;
    margin-bottom: 1.4rem;
    border-radius: 12px;
  }

  .hero h1 {
    font-size: 1.35rem;
    line-height: 1.35;
    word-break: keep-all;
  }

  .hero p {
    font-size: 0.88rem;
    line-height: 1.55;
    word-break: keep-all;
  }

  .compare-header-card {
    padding: 16px 14px;
    margin-bottom: 14px;
    border-radius: 12px;
  }

  .compare-header-card h1 {
    font-size: 1.35rem !important;
    line-height: 1.35;
    word-break: keep-all;
  }
}

@media (max-width: 640px) {
  .header-top-inner {
    padding: 6px 10px;
    gap: 6px;
  }

  .brand-wrap {
    gap: 6px;
  }

  .brand-logo {
    width: 28px;
    height: 28px;
  }

  .brand-title {
    font-size: 1.05rem;
  }

  .lang-switcher {
    gap: 1px;
    padding: 2px;
    border-radius: 6px;
  }

  .lang-btn {
    font-size: 0.68rem;
    padding: 2px 4px;
    min-width: 20px;
    border-radius: 4px;
  }

  .header-nav-inner {
    padding: 0 10px;
  }

  .nav-links-top {
    gap: 4px;
    padding: 5px 0;
  }

  .nav-links-top a {
    font-size: 0.82rem;
    padding: 4px 7px;
  }

  .container {
    margin: 12px auto;
    padding: 0 12px;
    width: 100%;
    max-width: 100%;
  }

  .hero {
    padding: 1.35rem 1rem;
    margin-bottom: 1.2rem;
    border-radius: 12px;
  }

  .hero h1 {
    font-size: 1.3rem;
    line-height: 1.35;
    word-break: keep-all;
  }

  .hero p {
    font-size: 0.85rem;
    line-height: 1.55;
    word-break: keep-all;
  }

  .compare-header-card {
    padding: 16px 12px;
    margin-bottom: 14px;
    border-radius: 12px;
  }

  .compare-header-card h1 {
    font-size: 1.28rem !important;
    line-height: 1.35;
    word-break: keep-all;
  }
}

@media (max-width: 360px) {
  .header-top-inner {
    padding: 5px 6px;
    gap: 4px;
  }

  .brand-title {
    font-size: 0.95rem;
  }

  .lang-btn {
    font-size: 0.62rem;
    padding: 2px 3px;
    min-width: 18px;
  }
}

/* ==========================================================================
   Mobile Responsive Enhancements: Calculator, Charts & Period Chips [아사히나]
   ========================================================================== */
@media (max-width: 768px) {

  /* 시뮬레이터 카드 패딩 컴팩트화: 불필요한 좌우 여백을 줄여 본문/차트 가로폭 극대화 */
  .calculator-box {
    padding: 16px 12px !important;
    margin: 16px 0 !important;
    border-radius: 14px !important;
  }

  .roadmap-section,
  .tier-section {
    padding: 16px 12px !important;
    margin-top: 18px !important;
    border-radius: 14px !important;
  }

  /* calculator-box 내부 중첩 카드 껍질 제거 (클러스터 1과 동일한 1겹 카드 구조) */
  .calculator-box .roadmap-section,
  .calculator-box .tier-section {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    border-radius: 0 !important;
  }

  /* 박스 안의 박스 중첩 패딩/보더 제거: 모바일에서 차트가 좌우 꽉 차게 렌더링 */
  .chart-container-box,
  .roadmap-chart-container,
  .tax-chart-container {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 4px 0 !important;
    margin: 6px 0 !important;
    border-radius: 0 !important;
    width: 100% !important;
  }

  /* 기간 선택 칩(period-chips) 모바일 최적화: 가로 스크롤 및 아래 요소 겹침 완벽 방지 */
  .period-chips-wrap {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 8px !important;
    margin-top: 14px !important;
    margin-bottom: 14px !important;
    width: 100% !important;
  }

  .period-chips-wrap .control-label {
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    color: #475569 !important;
    margin: 0 !important;
  }

  .period-chips {
    display: flex !important;
    width: 100% !important;
    max-width: 100% !important;
    gap: 6px !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    padding: 2px 2px 6px 2px !important;
  }

  .period-chips::-webkit-scrollbar {
    display: none !important;
    height: 0 !important;
  }

  .chip-btn {
    flex-shrink: 0 !important;
    padding: 6px 12px !important;
    font-size: 0.82rem !important;
    border-radius: 18px !important;
  }

  /* 결과 카드 그리드 여백 안정화 */
  .calc-result-grid {
    margin-top: 14px !important;
  }

  /* SVG 차트 모바일 반응형 표시 */
  .chart-svg,
  .ssr-roadmap-svg,
  .ssr-tax-svg {
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
}

/* =========================================================
   [아사히나] 클러스터 3 (tax-compare) 스펙 그리드 & 표 가독성 고도화
   ========================================================= */
.info-metric-grid.four-col {
  grid-template-columns: repeat(4, 1fr);
}

.info-metric-item,
.info-metric-label,
.info-metric-val,
.info-metric-sub {
  word-break: keep-all;
}

.info-metric-sub {
  margin-top: auto;
  padding-top: 6px;
}

@media (max-width: 768px) {
  .info-metric-grid.four-col {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* 5열 압축 테이블 & 숫자 정렬 */
.stat-perf-table .num-col {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.stat-perf-table th.num-col {
  text-align: right;
}

.cell-sub-tax {
  display: block;
  font-size: 0.74rem;
  font-weight: 500;
  margin-top: 2px;
  color: #64748b;
}

/* 모바일 가로 스크롤 시 첫 번째 기준 열(연차) Sticky 고정 */
.sticky-first-col th:first-child,
.sticky-first-col td:first-child {
  position: sticky;
  left: 0;
  background: #ffffff;
  z-index: 2;
  border-right: 1px solid #e2e8f0;
  white-space: nowrap;
}

.sticky-first-col th:first-child {
  background: #f8fafc;
}

.sticky-first-col tr[style*="background: #f1f5f9"] td:first-child {
  background: #f1f5f9;
}

/* 핵심 세제 요약표 배지 & 모바일 카드 스택 */
.tax-summary-table td,
.tax-summary-table th {
  word-break: keep-all;
  vertical-align: top;
  line-height: 1.5;
}

.tax-badge {
  display: inline-block;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  margin-bottom: 4px;
}

.tax-badge-red {
  background: #fee2e2;
  color: #b91c1c;
}

.tax-badge-green {
  background: #d1fae5;
  color: #047857;
}

.tax-badge-purple {
  background: #ede9fe;
  color: #6d28d9;
}

.tax-badge-blue {
  background: #dbeafe;
  color: #1d4ed8;
}

.tax-badge-gray {
  background: #f1f5f9;
  color: #475569;
}

@media (max-width: 640px) {
  .tax-summary-table {
    min-width: 100% !important;
  }

  .tax-summary-table thead {
    display: none;
  }

  .tax-summary-table,
  .tax-summary-table tbody,
  .tax-summary-table tr,
  .tax-summary-table td {
    display: block;
    width: 100%;
    box-sizing: border-box;
  }

  .tax-summary-table tr {
    border-bottom: 2px solid #e2e8f0;
    padding: 10px 0;
  }

  .tax-summary-table tr:last-child {
    border-bottom: none;
  }

  .tax-summary-table td {
    border-bottom: 1px dashed #f1f5f9;
    padding: 8px 12px;
  }

  .tax-summary-table td:first-child {
    background: #f8fafc;
    font-size: 0.92rem;
    color: #0f172a;
    border-bottom: 1px solid #e2e8f0;
  }

  .tax-summary-table td[data-label]::before {
    content: attr(data-label);
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 4px;
  }
}

/* ==========================================================================
   Cluster 4: Portfolio Mix Controls, Badges & Insight Card [아사히나]
   ========================================================================== */
.mix-controls-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px 16px;
  margin-top: 14px;
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

.mix-best-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 7px;
  font-size: 0.72rem;
  font-weight: 700;
  color: #065f46;
  background: #d1fae5;
  border: 1px solid #6ee7b7;
  border-radius: 999px;
  vertical-align: middle;
}

.mix-insight-card {
  margin: 20px 0;
  padding: 18px 20px;
  background: linear-gradient(135deg, #f8fafc 0%, #f0fdf4 100%);
  border: 1px solid #bbf7d0;
  border-radius: 12px;
}

.mix-insight-card h3 {
  margin: 0 0 10px 0;
  font-size: 1.05rem;
  color: #065f46;
}

.mix-insight-card ul {
  margin: 0;
  padding-left: 18px;
}

.mix-insight-card li {
  margin-bottom: 6px;
  line-height: 1.6;
  color: #1e293b;
}

/* 연관 분석 더보기 & 전체 목록 액션 바 [아사히나] */
.related-actions-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: -12px;
  margin-bottom: 2rem;
}

.btn-load-more {
  padding: 11px 22px;
  font-size: 0.92rem;
  font-weight: 700;
  color: #0f172a;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.18s ease;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
}

.btn-load-more:hover {
  background: #f8fafc;
  border-color: #2563eb;
  color: #2563eb;
}

.btn-view-all-link {
  padding: 11px 20px;
  font-size: 0.9rem;
  font-weight: 700;
  color: #2563eb;
  background: #eff6ff;
  border-radius: 999px;
  text-decoration: none;
  transition: background 0.18s ease;
}

.btn-view-all-link:hover {
  background: #dbeafe;
}

/* 차트 인터랙티브 툴팁 & 스케일 토글 [아사히나] */
.chart-container-box {
  position: relative;
}

.chart-tooltip {
  position: absolute;
  pointer-events: none;
  z-index: 20;
  background: rgba(15, 23, 42, 0.94);
  color: #f8fafc;
  padding: 8px 11px;
  border-radius: 8px;
  font-size: 0.78rem;
  line-height: 1.45;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.22);
  white-space: nowrap;
  display: none;
}

.chart-tooltip-date {
  font-weight: 700;
  color: #93c5fd;
  margin-bottom: 2px;
}

.chart-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.scale-toggle-group {
  display: inline-flex;
  background: #f1f5f9;
  border-radius: 8px;
  padding: 2px;
  gap: 2px;
}

.scale-btn {
  border: none;
  background: transparent;
  font-size: 0.76rem;
  font-weight: 600;
  color: #64748b;
  padding: 4px 10px;
  border-radius: 6px;
  cursor: pointer;
}

.scale-btn.active {
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
}

.tm-start-ym-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
  font-size: 0.78rem;
  font-weight: 500;
  white-space: nowrap;
}

.tm-start-ym-badge strong {
  font-weight: 700;
  color: #1d4ed8;
}

.tm-end-ym-sub {
  color: #64748b;
  font-size: 0.74rem;
}

/* =========================================================
   Cluster 6: ETF Overlap Analysis Styles
   ========================================================= */
.ov-preset-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.ov-preset-btn {
  padding: 6px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 999px;
  background: #ffffff;
  color: #334155;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.ov-preset-btn:hover {
  border-color: #2563eb;
  color: #2563eb;
}

.ov-preset-btn.active {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff;
}

.ov-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.ov-card-sub {
  margin-top: 6px;
  font-size: 0.78rem;
  color: #64748b;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.ov-tier-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.74rem;
}

.ov-tier-badge.tier-high {
  background: #fee2e2;
  color: #b91c1c;
}

.ov-tier-badge.tier-medium {
  background: #fef3c7;
  color: #b45309;
}

.ov-tier-badge.tier-low {
  background: #dcfce7;
  color: #15803d;
}

.ov-callout {
  margin-top: 14px;
  padding: 13px 16px;
  border-radius: 10px;
  font-size: 0.92rem;
  line-height: 1.55;
  border-left: 4px solid #3b82f6;
  background: #eff6ff;
  color: #1e293b;
}

.ov-callout-warn {
  border-left-color: #dc2626;
  background: #fef2f2;
}

.ov-callout-good {
  border-left-color: #059669;
  background: #ecfdf5;
}

.ov-callout-yield {
  border-left-color: #d97706;
  background: #fffbeb;
}

.ov-callout-kr {
  border-left-color: #4f46e5;
  background: #eef2ff;
}

.ov-charts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  margin-top: 18px;
}

.ov-perf-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.ov-perf-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.ov-horizon-btns {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
}

.ov-horizon-btn {
  padding: 5px 11px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background: #ffffff;
  color: #334155;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.ov-horizon-btn:hover:not(:disabled) {
  border-color: #7c3aed;
  color: #7c3aed;
}

.ov-horizon-btn.active {
  background: #7c3aed;
  border-color: #7c3aed;
  color: #ffffff;
}

.ov-chart-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin-bottom: 10px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
  line-height: 1.4;
}

.ov-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.ov-legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  flex-shrink: 0;
}

.ov-legend-line {
  width: 16px;
  height: 3px;
  border-radius: 2px;
  flex-shrink: 0;
}

.ov-legend-dash {
  width: 16px;
  height: 0;
  border-top: 2px dashed;
  flex-shrink: 0;
}

.ov-scroll-box {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.ov-table {
  width: 100%;
  word-break: keep-all;
}

.ov-table th {
  white-space: nowrap;
}

.ov-table th,
.ov-table td {
  padding: 11px 16px;
  line-height: 1.5;
  vertical-align: middle;
}

.ov-table td:not(:first-child) {
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.ov-perf-table th.ov-etf-col {
  white-space: normal;
  min-width: 115px;
}

.ov-date-nowrap {
  white-space: nowrap;
}

.ov-name-cell .ov-hname {
  margin-left: 8px;
}

.ov-table tbody tr:hover {
  background: #f8fafc;
}

.chart-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px;
  min-width: 0;
}

.chart-title {
  margin: 0 0 10px;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
}

.interactive-svg-chart {
  display: block;
  width: 100%;
  height: auto;
}

.chart-tooltip {
  position: absolute;
  z-index: 20;
  pointer-events: none;
  background: rgba(15, 23, 42, 0.94);
  color: #f8fafc;
  padding: 8px 11px;
  border-radius: 8px;
  font-size: 0.78rem;
  line-height: 1.4;
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.25);
  min-width: 150px;
}

.ov-table-block {
  margin-top: 22px;
}

.ov-unique-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.ov-hname {
  color: #64748b;
  font-size: 0.82rem;
  margin-left: 4px;
}

.ov-empty-note {
  padding: 14px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  color: #475569;
  font-size: 0.9rem;
}

@media (max-width: 768px) {

  .ov-kpi-grid,
  .ov-charts-grid,
  .ov-unique-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {

  .ov-table th,
  .ov-table td {
    padding: 8px 10px;
    font-size: 0.8rem;
  }

  .ov-name-cell {
    min-width: 132px;
  }

  .ov-name-cell .ov-hname {
    display: block;
    margin-left: 0;
    margin-top: 2px;
    font-size: 0.74rem;
    line-height: 1.3;
  }

  .ov-perf-table th,
  .ov-perf-table td {
    white-space: nowrap;
  }
}

/* Global Readability Guards across Clusters 1-6 */
.table-scroll-wrapper .data-table th,
.stat-perf-table th {
  white-space: nowrap;
  word-break: keep-all;
}

.calc-title,
.chart-title,
.roadmap-title,
.calculator-box h2,
.calculator-box h3,
.section-card h2,
.section-card h3 {
  word-break: keep-all;
}

/* Ticker Badges & Conditional Time Machine Link Badges */
.header-badges-row,
.card-badges-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.card-badges-row {
  margin-bottom: 6px;
}

.card-badges-row .badge {
  margin-bottom: 0;
}

.ticker-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
  line-height: 1.3;
  white-space: nowrap;
}

.ticker-badge-link {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #93c5fd;
  text-decoration: none;
  transition: all 0.15s ease;
}

.ticker-badge-link:hover {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
}


/* Footer Links & E-E-A-T Trust Pages [아사히나] */
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 22px;
  margin-bottom: 14px;
}

.footer-links a {
  color: #cbd5e1;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s ease;
}

.footer-links a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.contact-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px 24px;
  margin: 20px 0;
}

.contact-card h3 {
  margin-top: 0;
  margin-bottom: 8px;
}

.contact-email-text {
  margin: 6px 0;
  font-size: 1.1rem;
  font-weight: 700;
}

.contact-email-link {
  color: #2563eb;
  text-decoration: none;
}

.contact-email-link:hover {
  text-decoration: underline;
}

.contact-note {
  margin: 6px 0 0;
  font-size: 0.88rem;
  color: #64748b;
}

/* Data Source & Methodology Box [아사히나] */
.data-source-box {
  margin-top: 28px;
  padding: 18px 20px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 4px solid #2563eb;
  border-radius: 10px;
  font-size: 0.88rem;
  line-height: 1.6;
  color: #475569;
}

.data-source-title {
  font-weight: 700;
  color: #0f172a;
  font-size: 0.95rem;
  margin-bottom: 6px;
}

.data-source-meta {
  margin: 0 0 6px !important;
  color: #334155;
}

.data-source-note {
  margin: 0 0 8px !important;
  color: #64748b;
  font-size: 0.84rem;
}

.data-source-link {
  display: inline-block;
  font-weight: 600;
  color: #2563eb;
  text-decoration: none;
}

.data-source-link:hover {
  text-decoration: underline;
}

/* Single-column layout for E-E-A-T / Legal pages [아사히나] */
.layout-grid.layout-single {
  grid-template-columns: minmax(0, 1fr);
  max-width: 860px;
  margin: 0 auto;
}
