:root {
  --primary-color: #2c5aa0;
  --secondary-color: #4a90e2;
  --accent-color: #e85d04;
  --text-dark: #1a1a2e;
  --text-light: #f8f9fa;
  --bg-light: #ffffff;
  --bg-gray: #f4f6f9;
  --border-color: #e0e4e8;
  --shadow: 0 4px 20px rgba(0,0,0,0.08);
  --shadow-hover: 0 8px 30px rgba(0,0,0,0.12);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font-main: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

body {
  font-family: var(--font-main);
  color: var(--text-dark);
  line-height: 1.8;
  background: var(--bg-light);
  font-size: 16px;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
}

header {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: var(--text-light);
  padding: 1.2rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.site-title {
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin: 0;
}

.site-title a {
  color: var(--text-light);
  text-decoration: none;
  transition: var(--transition);
}

.site-title a:hover {
  opacity: 0.9;
}

nav {
  flex: 1;
  display: flex;
  justify-content: flex-end;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 0.3rem;
  align-items: center;
  flex-wrap: wrap;
  max-width: 900px;
  justify-content: center;
}

.nav-item a {
  color: var(--text-light);
  text-decoration: none;
  padding: 0.6rem 1rem;
  border-radius: 6px;
  transition: var(--transition);
  font-size: 0.9rem;
  font-weight: 500;
  white-space: nowrap;
  display: block;
}

.nav-item a:hover,
.nav-item a.active {
  background: rgba(255,255,255,0.2);
  backdrop-filter: blur(10px);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.hamburger span {
  width: 28px;
  height: 3px;
  background: var(--text-light);
  transition: var(--transition);
  border-radius: 3px;
}

.hero {
  position: relative;
  min-height: 550px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(44,90,160,0.95) 0%, rgba(74,144,226,0.85) 100%);
}

.hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -1;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  color: var(--text-light);
  padding: 3rem 2rem;
  max-width: 900px;
}

.hero h1 {
  font-size: 3.2rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  line-height: 1.2;
  text-shadow: 2px 2px 8px rgba(0,0,0,0.3);
  letter-spacing: -1px;
}

.hero p {
  font-size: 1.3rem;
  line-height: 1.8;
  margin-bottom: 2rem;
  text-shadow: 1px 1px 4px rgba(0,0,0,0.2);
  font-weight: 400;
}

.cta-button {
  display: inline-block;
  background: var(--accent-color);
  color: var(--text-light);
  padding: 1rem 2.5rem;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(232,93,4,0.3);
}

.cta-button:hover {
  background: #d64f00;
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(232,93,4,0.4);
}

main {
  padding: 4rem 0;
}

.content-wrapper {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3rem;
  align-items: start;
}

.main-content {
  background: var(--bg-light);
  padding: 3rem;
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.page-hero {
  position: relative;
  width: calc(100% + 6rem);
  margin: -3rem -3rem 3rem -3rem;
  height: 400px;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
}

.page-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(26,26,46,0.95), transparent);
  padding: 2.5rem;
  color: var(--text-light);
}

.page-hero-overlay h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.8rem;
  line-height: 1.3;
}

.page-hero-overlay p {
  font-size: 1.1rem;
  opacity: 0.95;
  line-height: 1.7;
}

.section {
  margin: 3rem 0;
}

.section h2 {
  font-size: 2rem;
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  padding-bottom: 0.8rem;
  border-bottom: 3px solid var(--secondary-color);
  font-weight: 700;
}

.section h3 {
  font-size: 1.5rem;
  color: var(--text-dark);
  margin: 2rem 0 1rem 0;
  font-weight: 600;
}

.section p {
  margin-bottom: 1.3rem;
  line-height: 1.9;
  color: #333;
}

.section ul, .section ol {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

.section li {
  margin-bottom: 1rem;
  line-height: 1.8;
  color: #333;
}

.section strong {
  color: var(--primary-color);
  font-weight: 600;
}

.sidebar {
  position: sticky;
  top: 120px;
}

.sidebar-section {
  background: var(--bg-light);
  padding: 2rem;
  border-radius: 12px;
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
}

.sidebar-section h3 {
  font-size: 1.3rem;
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  font-weight: 600;
  border-bottom: 2px solid var(--secondary-color);
  padding-bottom: 0.6rem;
}

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

.toc-list li {
  margin-bottom: 0.8rem;
}

.toc-list a {
  color: var(--text-dark);
  text-decoration: none;
  transition: var(--transition);
  display: block;
  padding: 0.5rem 0.8rem;
  border-radius: 6px;
  font-size: 0.95rem;
}

.toc-list a:hover {
  background: var(--bg-gray);
  color: var(--secondary-color);
  padding-left: 1.2rem;
}

.ad-space {
  background: linear-gradient(135deg, var(--bg-gray) 0%, #e8ecf1 100%);
  padding: 3rem 1.5rem;
  border-radius: 8px;
  text-align: center;
  color: #666;
  font-size: 0.95rem;
  border: 2px dashed var(--border-color);
  min-height: 250px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.related-links {
  list-style: none;
}

.related-links li {
  margin-bottom: 1rem;
}

.related-links a {
  color: var(--text-dark);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem;
  border-radius: 8px;
  transition: var(--transition);
  font-size: 0.95rem;
  border: 1px solid var(--border-color);
}

.related-links a:hover {
  background: var(--bg-gray);
  border-color: var(--secondary-color);
  transform: translateX(4px);
}

.related-links a::before {
  content: "→";
  color: var(--secondary-color);
  font-weight: bold;
  font-size: 1.2rem;
}

.intro-section {
  background: linear-gradient(135deg, var(--bg-gray) 0%, #e8f4f8 100%);
  padding: 2.5rem;
  border-radius: 12px;
  margin: 2rem 0;
  border-left: 5px solid var(--secondary-color);
}

.intro-section p {
  font-size: 1.1rem;
  line-height: 2;
  color: var(--text-dark);
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
}

.news-card {
  background: var(--bg-light);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  border: 1px solid var(--border-color);
}

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

.news-card h3 {
  font-size: 1.2rem;
  color: var(--primary-color);
  padding: 1.5rem;
  margin: 0;
  background: var(--bg-gray);
  font-weight: 600;
}

.news-card p {
  padding: 1.5rem;
  line-height: 1.8;
  color: #333;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin: 3rem 0;
}

.stat-card {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: var(--text-light);
  padding: 2.5rem;
  border-radius: 12px;
  text-align: center;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

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

.stat-number {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  display: block;
}

.stat-label {
  font-size: 1.1rem;
  opacity: 0.95;
  font-weight: 500;
}

.highlight-box {
  background: linear-gradient(135deg, #fff5e6 0%, #ffe6cc 100%);
  border-left: 5px solid var(--accent-color);
  padding: 2rem;
  border-radius: 8px;
  margin: 2rem 0;
}

.highlight-box h3 {
  color: var(--accent-color);
  margin-top: 0;
  font-size: 1.4rem;
}

footer {
  background: linear-gradient(135deg, #1a1a2e 0%, #2c2c44 100%);
  color: var(--text-light);
  padding: 3rem 0 1.5rem 0;
  margin-top: 5rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-section h3 {
  font-size: 1.3rem;
  margin-bottom: 1.2rem;
  color: var(--text-light);
  font-weight: 600;
}

.footer-section ul {
  list-style: none;
}

.footer-section li {
  margin-bottom: 0.8rem;
}

.footer-section a {
  color: rgba(255,255,255,0.8);
  text-decoration: none;
  transition: var(--transition);
  font-size: 0.95rem;
}

.footer-section a:hover {
  color: var(--secondary-color);
  padding-left: 5px;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
}

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    height: calc(100vh - 70px);
    background: var(--primary-color);
    flex-direction: column;
    padding: 2rem;
    gap: 0;
    transition: left 0.3s ease;
    overflow-y: auto;
  }
  
  .nav-menu.active {
    left: 0;
  }
  
  .nav-item {
    width: 100%;
  }
  
  .nav-item a {
    display: block;
    padding: 1rem;
    font-size: 1.1rem;
  }
  
  .hero h1 {
    font-size: 2.2rem;
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  .content-wrapper {
    grid-template-columns: 1fr;
    display: flex;
    flex-direction: column;
  }

  .sidebar {
    order: -1;
  }

  .main-content {
    padding: 2rem;
    order: 0;
  }
  
  .page-hero {
    width: calc(100% + 4rem);
    margin: -2rem -2rem 2rem -2rem;
    height: 300px;
  }
  
  .page-hero-overlay {
    padding: 1.5rem;
  }
  
  .page-hero-overlay h1 {
    font-size: 1.8rem;
  }
  
  
  .news-grid {
    grid-template-columns: 1fr;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .site-title {
    font-size: 1.4rem;
  }
  
  .hero h1 {
    font-size: 1.8rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .section h2 {
    font-size: 1.6rem;
  }
  
  .main-content {
    padding: 1.5rem;
  }
}
