/* ================= Base ================= */

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Roboto', sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: #444;
  background-color: #fafafa;
}

h1, h2 {
  font-family: 'Oswald', sans-serif;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 30px;

}


h2 {
  margin-bottom: 8px;
  
}

p {
  margin-top: 0;
}

/* ================= Navigation ================= */

.navigation {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #ffffff;
  border-bottom: 1px solid #e5e5e5;
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-weight: bold;
  letter-spacing: 0.5px;
}

.navigation nav a {
  margin-left: 18px;
  text-decoration: none;
  color: #555;
  font-size: 13px;
}

.navigation nav a:hover {
  color: #000;
}

/* ================= Hero ================= */

.hero {
  height: 70vh;
  min-height: 420px;
}

.hero-slide {
  height: 100%;
  background-image: url("../image/swim.png");
  background-size: cover;
  background-position: center;
  position: relative;
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
}

.hero-text {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: #ffffff;
  text-align: center;
  padding: 0 20px;
}

.hero-text h1 {
  font-size: 36px;
  margin-bottom: 10px;
}

.hero-text p {
  font-size: 16px;
  opacity: 0.9;
}

/* ================= Intro ================= */

.intro {
  background: #ffffff;
  padding: 80px 20px;
}

.intro-inner {
  max-width: 900px;
  margin: 0 auto;
}

.intro-text {
  max-width: 600px;
}

/* ================= Demo Sections ================= */

.demo {
  padding: 90px 20px;
}

.demo:nth-of-type(even) {
  background-color: #ffffff;
}

.demo-inner {
  max-width: 1000px;
  margin: 0 auto;
}

.demo-description {
  
  margin-bottom: 30px;
  font-size: 14px;
  color: #666;
  
}



/* ================= Chart Container ================= */

.chart-container {
  margin: 30px 0 15px 0;
  display: flex;
  justify-content: center;
}

/* ================= Legend ================= */

.legend {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 10px;
}

.legend div {
  display: flex;
  align-items: center;
  margin: 5px 12px;
  font-size: 12px;
}

.legend div span:first-child {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 6px;
}

/* ================= Footer ================= */

footer {
  background: #111;
  color: #aaa;
  padding: 50px 20px;
  font-size: 12px;
  text-align: center;
}

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

footer a {
  color: #b5b9bb;
  text-decoration: none;
}

footer a:hover {
  text-decoration: underline;
}


/* ================= D3 / Popup (保留你原有语义) ================= */

circle {
  transition: r 0.2s, stroke-width 0.2s;
}

.entrants circle {
  fill: none;
  stroke: #aaa;
  stroke-dasharray: 2 2;
}

.finishers circle {
  fill: #aaa;
}

.winners circle {
  stroke: #fff;
  stroke-width: 1px;
}

.entrants circle:hover,
.finishers circle:hover {
  stroke: #555;
  stroke-width: 1.5px;
}

.gender-labels text {
  fill: #444;
}

.flourish-popup {
  pointer-events: none;
}

.flourish-popup td:first-child {
  text-align: right;
  padding-right: 0.2em;
  font-weight: bold;
}
