/* if_world_were_village.css - Page Specific Styles */

.if-world-were-village-page {
  --village-blue: #3b82f6;
  --village-light: #60a5fa;
  --village-bg: #fff7ed;
}

.if-world-were-village-page .main-content {
  background: transparent;
  box-shadow: none;
}

.if-world-were-village-page .page-title {
  color: var(--village-blue);
  font-size: 2rem;
  font-weight: bold;
  position: relative;
  display: inline-block;
  margin-bottom: 2rem;
  padding-bottom: 0.5rem;
}

.if-world-were-village-page .page-title::after {
  content: "";
  display: block;
  width: 100%;
  height: 3px;
  background: var(--village-light);
  position: absolute;
  bottom: 0;
  left: 0;
}

.if-world-were-village-page .story-text {
  font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  line-height: 2.4;
  letter-spacing: 0.05em;
  font-size: 1.05rem;
  color: #334155;
  margin-bottom: 2rem;
}

.if-world-were-village-page .opening-question {
  background: linear-gradient(to bottom, #fff7ed, #ffffff);
  padding: 3rem 2rem;
  border-radius: 16px;
  margin-bottom: 4rem;
  text-align: center;
  border: 1px solid #ffedd5;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.03);
  position: relative;
}

.if-world-were-village-page .opening-question p {
  margin-bottom: 1.5rem;
  font-weight: 500;
  color: #431407;
}

.if-world-were-village-page .opening-highlight {
  font-size: 1.2rem;
  font-weight: bold;
  margin-top: 2rem !important;
  color: var(--village-blue);
}

.if-world-were-village-page .opening-note {
  text-align: center;
  margin-bottom: 4rem;
  font-weight: bold;
  font-size: 1.1rem;
  color: #c2410c;
  line-height: 1.8;
}

.if-world-were-village-page .story-text p {
  margin-bottom: 2rem;
}

.if-world-were-village-page .story-citation {
  text-align: right;
  margin-top: 2rem;
  color: #64748b;
  font-size: 0.9rem;
}

.if-world-were-village-page .note-header {
  font-weight: bold;
  color: #475569;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.if-world-were-village-page .note-title {
  color: #334155;
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px dashed #cbd5e1;
  padding-bottom: 0.5rem;
  display: inline-block;
}

.if-world-were-village-page .morrie-quote {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-left: 5px solid #ea580c;
  border-radius: 8px;
  padding: 2rem;
  margin: 2rem 0;
  font-style: italic;
  color: #7c2d12;
  box-shadow: 0 4px 6px -1px rgba(254, 215, 170, 0.4);
}

.if-world-were-village-page .morrie-quote i {
  color: #fb923c;
  font-size: 1.5rem;
  margin-right: 0.5rem;
}

.if-world-were-village-page .quote-highlight {
  font-weight: bold;
  color: #be123c;
  display: block;
  margin-top: 0.5rem;
  font-size: 1.1rem;
}

.if-world-were-village-page .final-message {
  text-align: center;
  padding: 2rem;
  background: #f8fafc;
  border-radius: 12px;
  margin-top: 3rem;
  font-weight: bold;
  color: #1e3a8a;
}

.if-world-were-village-page .message-note {
  font-size: 0.9rem;
  font-weight: normal;
  margin-top: 0.5rem;
  display: block;
  color: #64748b;
}

.if-world-were-village-page .visual-summary {
  background: #f8fafc;
  border-top: 4px solid var(--village-blue);
  padding: 3rem 1.5rem;
  margin-top: 4rem;
  border-radius: 8px;
}

.if-world-were-village-page .summary-title {
  text-align: center;
  color: #1e40af;
  font-size: 1.5rem;
  margin-bottom: 3rem;
  font-weight: bold;
}

.if-world-were-village-page .chart-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.if-world-were-village-page .chart-card {
  background: white;
  padding: 1.5rem;
  border-radius: 12px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.if-world-were-village-page .chart-label {
  font-weight: bold;
  color: #475569;
  margin-bottom: 1rem;
  display: block;
}

.if-world-were-village-page .pie-chart {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  margin: 0 auto 1rem;
  position: relative;
}

.if-world-were-village-page .pie-chart::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70%;
  height: 70%;
  background: white;
  border-radius: 50%;
}

.if-world-were-village-page .chart-gender {
  background: conic-gradient(#ec4899 0% 52%, #3b82f6 52% 100%);
}

.if-world-were-village-page .chart-age {
  background: conic-gradient(#f59e0b 0% 30%, #10b981 30% 100%);
}

.if-world-were-village-page .chart-race {
  background: conic-gradient(#854d0e 0% 70%, #fcd34d 70% 100%);
}

.if-world-were-village-page .legend {
  font-size: 0.9rem;
  color: #64748b;
  text-align: left;
  margin-top: 1rem;
}

.if-world-were-village-page .legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.3rem;
}

.if-world-were-village-page .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.if-world-were-village-page .dot-female { background: #ec4899; }
.if-world-were-village-page .dot-male { background: #3b82f6; }
.if-world-were-village-page .dot-adult { background: #10b981; }
.if-world-were-village-page .dot-child { background: #f59e0b; }
.if-world-were-village-page .dot-poc { background: #854d0e; }
.if-world-were-village-page .dot-white { background: #fcd34d; }

/* Wealth Bar Chart Custom Styles */
.if-world-were-village-page .wealth-highlight {
  margin-top: 3rem;
  background: white;
  padding: 2.5rem 2rem;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  border: 1px solid #e2e8f0;
}

.if-world-were-village-page .wealth-label {
  text-align: center;
  font-size: 1.2rem;
  margin-bottom: 2rem !important;
}

.if-world-were-village-page .bar-chart-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.if-world-were-village-page .bar-row {
  width: 100%;
}

.if-world-were-village-page .wealth-percent-high {
  font-weight: bold;
  color: #ef4444;
}

.if-world-were-village-page .wealth-fill-high {
  width: 59%;
  background: #ef4444;
}

.if-world-were-village-page .wealth-fill-mid {
  width: 39%;
  background: #94a3b8;
}

.if-world-were-village-page .wealth-fill-low {
  width: 2%;
  background: #cbd5e1;
}

.if-world-were-village-page .bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  margin-bottom: 0.2rem;
}

.if-world-were-village-page .bar-track {
  height: 8px;
  background: #e2e8f0;
  border-radius: 4px;
  overflow: hidden;
}

.if-world-were-village-page .bar-fill {
  height: 100%;
  border-radius: 4px;
}

.if-world-were-village-page .highlight-box {
  background: #fff1f2;
  border: 2px solid #fda4af;
  padding: 2rem;
  border-radius: 8px;
  margin: 3rem 0;
  text-align: center;
}

.if-world-were-village-page .literacy-icon {
  font-size: 2rem;
  color: #be123c;
  margin-bottom: 1rem;
}

.if-world-were-village-page .literacy-title {
  font-weight: bold;
  margin-bottom: 0.5rem;
}


/* Sidebar structure overrides */
.if-world-were-village-page .sidebar-widget h3 {
  border-bottom-color: #bfdbfe;
  color: #1e40af;
}

.if-world-were-village-page .sidebar-advice {
  background: #ffffff;
  border: 1px solid #3b82f6;
  border-radius: 8px;
  padding: 1.5rem;
}

.if-world-were-village-page .sidebar-advice .header {
  color: #1d4ed8;
  border-bottom: 2px solid #3b82f6;
  font-weight: 800;
  margin-bottom: 0.8rem;
  padding-bottom: 0.4rem;
}

.if-world-were-village-page .recommendations-list li a.active {
    background: #eff6ff;
    color: #2563eb;
    border-left-color: #2563eb;
}

.if-world-were-village-page .footer-nav-wrap {
  margin-top: 2rem;
  text-align: center;
}
