/* ==========================================================================
   Base Styles & CSS Variables
   ========================================================================== */
:root {
  --primary-color: #003366;      /* CTAOディープブルー */
  --accent-color: #0088cc;       /* シアン/ブルー */
  --text-main: #222222;
  --text-muted: #666666;
  --bg-main: #ffffff;
  --bg-card: #ffffff;
  --border-color: #e2e8f0;
  --radius-sm: 6px;
  --radius-md: 12px;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-md: 0 6px 16px rgba(0,0,0,0.08);
  --max-width: 1200px;
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

body {
  font-family: var(--font-family);
  color: var(--text-main);
  background-color: var(--bg-main);
  line-height: 1.6;
}

a {
  color: var(--accent-color);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0.85rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.logo-img {
  height: 38px;
  width: auto;
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-color);
  letter-spacing: -0.02em;
}

.site-nav ul {
  display: flex;
  list-style: none;
  gap: 1.5rem;
  align-items: center;
}

.site-nav a {
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.5rem 0.25rem;
  position: relative;
}

.site-nav a.active,
.site-nav a:hover {
  color: var(--accent-color);
  text-decoration: none;
}

.site-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 3px;
  background-color: var(--accent-color);
}

.site-nav .nav-internal {
  background-color: var(--primary-color);
  color: #fff !important;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-sm);
}

.site-nav .nav-internal:hover {
  opacity: 0.9;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background-color: var(--text-main);
  transition: 0.3s;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  position: relative;
  background-image: url('../../pic/4LSTs.jpg');
  background-size: cover;
  background-position: center 45%;
  background-repeat: no-repeat;
  color: #ffffff;
  min-height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2.5rem 1.5rem;
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    180deg,
    rgba(10, 25, 47, 0.45) 0%,
    rgba(0, 51, 102, 0.65) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 850px;
  margin: 0 auto;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
  color: #ffffff;
}

.hero-subtitle {
  font-size: 1.2rem;
  font-weight: 400;
  opacity: 0.95;
  line-height: 1.6;
}

/* ==========================================================================
   Main Layout & Components
   ========================================================================== */
.main-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 3.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}

h2, h3 {
  color: var(--primary-color);
  font-size: 1.6rem;
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--border-color);
}

h2::after, h3::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60px;
  height: 2px;
  background-color: var(--accent-color);
}

.lead-text p {
  font-size: 1.05rem;
  margin-bottom: 1rem;
}

/* --- メディアギャラリー (動画・カードの整列) --- */
.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.video-container, .embed-container {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-container video,
.embed-container iframe {
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: cover;
}

.card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-grow: 1;
}

.card-body h4 {
  font-size: 1rem;
  color: var(--primary-color);
}

.card-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.card-link {
  font-size: 0.875rem;
  font-weight: 600;
  margin-top: auto;
}

.brochure-card {
  align-items: center;
  text-align: center;
  padding-top: 1.5rem;
}

.brochure-image img {
  height: 160px;
  width: auto;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-sm);
}

.download-links {
  list-style: none;
  font-size: 0.875rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

/* --- 新着情報 --- */
.news-scroll-box {
  max-height: 420px;
  overflow-y: auto;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1rem 1.5rem;
}

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

.news-item {
  display: grid;
  grid-template-columns: 100px 110px 1fr;
  align-items: baseline;
  gap: 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px dashed var(--border-color);
}

.news-item:last-child {
  border-bottom: none;
}

.news-item time {
  font-size: 0.875rem;
  color: var(--text-muted);
  font-family: monospace;
}

.badge {
  display: inline-block;
  padding: 0.2em 0.6em;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 4px;
  text-align: center;
}

.badge-pub { background: #e0f2fe; color: #0369a1; }
.badge-event { background: #fef3c7; color: #b45309; }
.badge-press { background: #fee2e2; color: #b91c1c; }
.badge-info { background: #f3f4f6; color: #374151; }

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.5rem;
    box-shadow: var(--shadow-md);
  }

  .site-nav.is-active {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .news-item {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background-color: #ffffff;
  border-top: 1px solid var(--border-color);
  padding: 2.5rem 1.5rem;
  margin-top: 4rem;
  text-align: center;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.footer-logo {
  height: 38px !important; /* ロゴの高さを適切なサイズに固定 */
  width: auto !important;
}

.copyright {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Member Table Styles
   ========================================================================== */
.member-table {
  width: 100%;
  margin-top: 1rem;
}

.table-header-row th {
  background-color: var(--primary-color) !important;
  color: #ffffff !important;
  font-size: 1.05rem;
  padding: 0.85rem 1rem;
  text-align: left;
}

.table-header-row th a {
  color: #ffffff !important;
  text-decoration: underline;
}

.subgroup-header-row td {
  background-color: #e2e8f0;
  color: var(--primary-color);
  font-weight: 700;
  padding: 0.6rem 1rem;
}

.member-row td {
  padding: 0.5rem 1rem;
  border-bottom: 1px solid var(--border-color);
}

.member-name {
  font-weight: 600;
  width: 240px;
}

.rep-star {
  color: #e53e3e;
  font-weight: bold;
  margin-left: 0.2rem;
}

.member-note {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Publications & Sub-navigation Styles
   ========================================================================== */
.sub-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  background-color: #f8fafc;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  margin-bottom: 2rem;
}

.sub-nav a {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--primary-color);
  padding: 0.25rem 0.6rem;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.sub-nav a:hover {
  background-color: var(--primary-color);
  color: #ffffff;
  text-decoration: none;
}

.modern-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.modern-table th,
.modern-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  text-align: left;
}

.modern-table th {
  background-color: #f1f5f9;
  color: var(--primary-color);
  font-weight: 700;
}

.conf-block {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
}

.conf-title {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  border-bottom: 2px solid var(--accent-color);
  padding-bottom: 0.25rem;
}

.btn-link {
  display: inline-block;
  padding: 0.6rem 1.2rem;
  background-color: var(--primary-color);
  color: #ffffff !important;
  border-radius: var(--radius-sm);
  font-weight: 600;
  text-decoration: none;
}

.btn-link:hover {
  opacity: 0.9;
  text-decoration: none;
}

/* ==========================================================================
   Document Page Styles
   ========================================================================== */
.doc-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  align-items: end;
  margin-top: 1rem;
}

.doc-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.doc-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.doc-cover-link img {
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-sm);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  margin-bottom: 0.75rem;
}

.doc-card-title {
  font-weight: 700;
  color: var(--primary-color);
}

.doc-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.doc-list > li {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-color);
}

.doc-list > li:last-child {
  border-bottom: none;
}

.link-group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.35rem;
}

.doc-link-btn {
  display: inline-block;
  font-size: 0.85rem;
  padding: 0.25rem 0.6rem;
  background-color: #f1f5f9;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--primary-color);
  font-weight: 600;
  text-decoration: none;
}

.doc-link-btn:hover {
  background-color: var(--primary-color);
  color: #ffffff;
  text-decoration: none;
}

/* ==========================================================================
   Contact Page Styles
   ========================================================================== */
.contact-table {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
}

.contact-row td {
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--border-color);
}

.contact-name {
  font-weight: 600;
  width: 220px;
  white-space: nowrap;
}

.contact-email a {
  color: var(--primary-color);
  font-family: var(--font-mono, monospace);
  text-decoration: none;
}

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

.at-mark {
  color: var(--accent-color, #2b6cb0);
  font-weight: bold;
  padding: 0 1px;
}

/* ==========================================================================
   Uncopyable Emoji-style @ Mark
   ========================================================================== */
.email-display {
  font-family: var(--font-mono, monospace);
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.at-icon {
  user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
  pointer-events: none;
}

.at-icon::before {
  content: "@";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.35em;
  height: 1.35em;
  background-color: #e2e8f0;
  color: #1e293b;
  font-size: 0.85em;
  font-weight: bold;
  border-radius: 50%;
  border: 1px solid #cbd5e1;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

/* Google Material Symbols (Icons) */
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200');

/* Header & Navigation Styles */
.site-header {
  background-color: #ffffff;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.header-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.main-navigation ul {
  display: flex;
  list-style: none;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 0.85rem;
  color: var(--text-color, #334155);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: var(--radius-sm, 6px);
  text-decoration: none;
  transition: all 0.2s ease;
}

.nav-link:hover {
  background-color: #f1f5f9;
  color: var(--primary-color, #1e3a8a);
  text-decoration: none;
}

.nav-link.active {
  background-color: #e2e8f0;
  color: var(--primary-color, #1e3a8a);
}

.nav-icon {
  font-size: 1.2rem !important;
}

/* ==========================================================================
   Internal Page Styles
   ========================================================================== */
.internal-section {
  padding: 3rem 1rem;
}

.internal-card {
  margin: 2rem auto;
  padding: 2.5rem 2rem;
  background: var(--bg-card, #ffffff);
  border: 1px solid var(--border-color, #e2e8f0);
  border-radius: var(--radius-md, 8px);
  max-width: 420px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.lock-icon-wrapper .material-symbols-outlined {
  font-size: 3rem;
  color: var(--primary-color, #1e3a8a);
}

.btn-login {
  background-color: var(--primary-color, #1e3a8a);
  color: #ffffff !important;
  text-decoration: none;
  border-radius: var(--radius-sm, 6px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.btn-login:hover {
  background-color: #1e40af;
  transform: translateY(-1px);
  text-decoration: none;
}
