@charset "utf-8";
/* ============================================================
   DDNA Lab. — データ駆動ネットワーキングアーキテクチャ研究室
   共通スタイルシート（明るいグリーン基調）
   ============================================================ */

:root {
  /* カラーパレット */
  --bg: #f6faf1;            /* 明るいグリーン系の背景 */
  --surface: #ffffff;       /* カード背景 */
  --surface-soft: #e9f6e0;  /* 淡いグリーン */
  --ink: #2f3a2c;           /* 本文（緑がかった濃色） */
  --ink-soft: #66735f;      /* 補助テキスト */
  --accent: #2f9e44;        /* メインアクセント（明るいグリーン） */
  --accent-deep: #2b8a3e;   /* 濃いグリーン（hover等） */
  --accent-warm: #82c91e;   /* ライム */
  --line: #ddecd2;          /* 罫線 */
  --footer-bg: #2c4526;     /* フッター（深い緑） */
  --radius: 14px;
  --shadow: 0 2px 10px rgba(59, 105, 48, .08);
  --shadow-lg: 0 8px 28px rgba(59, 105, 48, .13);
}

/* ---------- リセット・基本 ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI",
    "Yu Gothic", Meiryo, sans-serif;
  font-size: 16px;
  line-height: 1.9;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; border: 0; display: block; }

a { color: var(--accent-deep); text-decoration: none; }
a:hover { color: var(--accent); text-decoration: underline; }

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--accent-warm);
  outline-offset: 2px;
  border-radius: 4px;
}

.container {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 22px;
}

/* ---------- ヘッダー ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 22px;
  max-width: 1180px;
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  min-width: 0;
}
.brand:hover { text-decoration: none; color: var(--ink); }

.brand-mark {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
}

.brand-text { line-height: 1.35; min-width: 0; }

.brand-text .brand-ja {
  display: block;
  font-weight: 700;
  font-size: .95rem;
  letter-spacing: .02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-text .brand-en {
  display: block;
  font-size: .68rem;
  color: var(--ink-soft);
  letter-spacing: .06em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ナビゲーション */
.global-nav ul {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.global-nav a {
  display: block;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--ink);
  font-size: .92rem;
  font-weight: 600;
  white-space: nowrap;
}

.global-nav a:hover {
  background: var(--surface-soft);
  color: var(--accent-deep);
  text-decoration: none;
}

.global-nav a[aria-current="page"] {
  background: var(--accent);
  color: #fff;
}

.lang-switch {
  display: inline-block;
  padding: 7px 14px;
  border: 1.5px solid var(--accent);
  border-radius: 999px;
  color: var(--accent-deep);
  font-size: .85rem;
  font-weight: 700;
  white-space: nowrap;
}
.lang-switch:hover {
  background: var(--accent);
  color: #fff;
  text-decoration: none;
}

/* ハンバーガー（モバイル） */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  height: 2.5px;
  background: var(--accent);
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* ---------- ヒーロー ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 900px 420px at 85% -10%, rgba(130, 201, 30, .20), transparent 60%),
    radial-gradient(ellipse 700px 380px at 8% 110%, rgba(47, 158, 68, .16), transparent 60%),
    linear-gradient(160deg, #f4fbea 0%, #e8f6d8 55%, #ddf0c8 100%);
  padding: 72px 0 64px;
  text-align: center;
}

.hero-deco {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: .5;
  pointer-events: none;
}

.hero .container { position: relative; }

.hero-kicker {
  display: inline-block;
  margin: 0 0 14px;
  padding: 6px 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--accent-deep);
  font-size: .85rem;
  font-weight: 700;
  letter-spacing: .12em;
}

.hero h1 {
  margin: 0 0 6px;
  font-size: clamp(1.5rem, 4.2vw, 2.5rem);
  line-height: 1.4;
  letter-spacing: .03em;
}

.hero .hero-en {
  margin: 0 0 22px;
  color: var(--ink-soft);
  font-size: clamp(.85rem, 2vw, 1.05rem);
  letter-spacing: .08em;
}

.hero-lead {
  max-width: 640px;
  margin: 0 auto 30px;
  font-size: 1.02rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
}

/* ボタン */
.btn {
  display: inline-block;
  padding: 13px 30px;
  border-radius: 999px;
  font-weight: 700;
  font-size: .98rem;
  transition: transform .15s, box-shadow .15s;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(135deg, var(--accent-deep) 0%, var(--accent-warm) 100%);
  color: #fff;
  box-shadow: 0 6px 18px rgba(47, 158, 68, .32);
}
.btn-primary:hover { color: #fff; box-shadow: 0 9px 24px rgba(47, 158, 68, .4); }

.btn-ghost {
  background: #fff;
  color: var(--accent-deep);
  border: 1.5px solid var(--accent);
}
.btn-ghost:hover { background: var(--surface-soft); color: var(--accent-deep); }

/* ---------- ページヘッダー（下層） ---------- */
.page-header {
  background:
    radial-gradient(ellipse 700px 300px at 90% -20%, rgba(130, 201, 30, .18), transparent 60%),
    linear-gradient(160deg, #f4fbea 0%, #e3f4d0 100%);
  padding: 46px 0 38px;
}

.page-header h1 {
  margin: 0;
  font-size: clamp(1.5rem, 3.6vw, 2.1rem);
  letter-spacing: .04em;
}

.page-header .page-sub {
  margin: 6px 0 0;
  color: var(--ink-soft);
  font-size: .9rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}

/* ---------- セクション ---------- */
.section { padding: 56px 0; }
.section + .section { padding-top: 0; }

.section-title {
  position: relative;
  margin: 0 0 30px;
  padding-left: 18px;
  font-size: 1.45rem;
  letter-spacing: .04em;
}
.section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 1.2em;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--accent), var(--accent-warm));
}

.section-sub {
  margin: -22px 0 26px;
  padding-left: 18px;
  color: var(--ink-soft);
  font-size: .92rem;
}

/* ---------- カード ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 28px;
}

.card + .card { margin-top: 22px; }

.card h3 { margin-top: 0; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 22px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px 26px;
  transition: transform .18s, box-shadow .18s;
}
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  margin-bottom: 16px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--surface-soft), #d7efc2);
  color: var(--accent-deep);
}
.feature-icon svg { width: 28px; height: 28px; }

.feature-card h3 { margin: 0 0 10px; font-size: 1.08rem; }
.feature-card p { margin: 0; color: var(--ink-soft); font-size: .95rem; }

/* リンク付きカード */
a.feature-card { display: block; color: inherit; }
a.feature-card:hover { text-decoration: none; color: inherit; }
.feature-card .more {
  display: inline-block;
  margin-top: 14px;
  color: var(--accent-deep);
  font-weight: 700;
  font-size: .9rem;
}

/* ---------- ニュース ---------- */
.news-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.news-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 18px;
  padding: 16px 6px;
  border-bottom: 1px dashed var(--line);
}

.news-date {
  flex: 0 0 auto;
  font-family: "SF Mono", Consolas, monospace;
  font-size: .88rem;
  font-weight: 700;
  color: var(--accent-deep);
  background: var(--surface-soft);
  border-radius: 6px;
  padding: 2px 10px;
}

.news-tag {
  flex: 0 0 auto;
  font-size: .75rem;
  font-weight: 700;
  color: #fff;
  background: var(--accent);
  border-radius: 999px;
  padding: 2px 12px;
}

.news-body { flex: 1 1 300px; margin: 0; }

/* ---------- 研究テーマ ---------- */
.research-block {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 30px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px;
  margin-bottom: 26px;
}

.research-block.reverse { grid-template-columns: .9fr 1.1fr; }
.research-block.reverse .research-text { order: 2; }
.research-block.reverse .research-figure { order: 1; }

.research-block h3 { margin: 0 0 12px; font-size: 1.2rem; }
.research-block p { margin: 0 0 10px; font-size: .97rem; }

.research-figure figure { margin: 0; }
.research-figure img {
  border-radius: 10px;
  border: 1px solid var(--line);
  margin: 0 auto;
}
.research-figure figcaption {
  margin-top: 10px;
  text-align: center;
  color: var(--ink-soft);
  font-size: .82rem;
}

.badge {
  display: inline-block;
  margin: 2px 6px 2px 0;
  padding: 3px 14px;
  background: var(--surface-soft);
  border: 1px solid #c4e6a8;
  border-radius: 999px;
  color: var(--accent-deep);
  font-size: .8rem;
  font-weight: 700;
}

/* ---------- 論文カード ---------- */
.paper-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 6px solid var(--accent);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 28px;
  margin-bottom: 20px;
}

.paper-card h3 { margin: 0 0 10px; font-size: 1.05rem; color: var(--accent-deep); }
.paper-card p { margin: 0 0 10px; font-size: .95rem; }
.paper-card p:last-child { margin-bottom: 0; }
.paper-card .cite {
  padding-top: 8px;
  border-top: 1px dashed var(--line);
  color: var(--ink-soft);
  font-size: .85rem;
}

/* ---------- 受賞・実績 ---------- */
.award-card {
  position: relative;
  background: linear-gradient(135deg, #fbfdf6, #f2f9e4);
  border: 1px solid #d3e8b5;
  border-left: 6px solid var(--accent-warm);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 28px 26px 64px;
  margin-bottom: 20px;
}

.award-card::before {
  content: "🏆";
  position: absolute;
  left: 22px;
  top: 26px;
  font-size: 1.5rem;
}

.award-card h3 { margin: 0 0 8px; font-size: 1.05rem; color: var(--accent-deep); }
.award-card p { margin: 0 0 10px; font-size: .95rem; }
.award-card p:last-child { margin-bottom: 0; }
.award-card .cite {
  padding-top: 8px;
  border-top: 1px dashed #d3e8b5;
  color: var(--ink-soft);
  font-size: .85rem;
}

/* ---------- 構成員 ---------- */
.member-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.member-table th,
.member-table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.member-table th {
  width: 32%;
  background: var(--surface-soft);
  color: var(--accent-deep);
  font-size: .95rem;
  white-space: nowrap;
}

.member-table tr:last-child th,
.member-table tr:last-child td { border-bottom: 0; }

.note { color: var(--ink-soft); font-size: .85rem; }

/* ---------- 定義リスト風（recruit等） ---------- */
.info-item { margin-bottom: 14px; }
.info-item dt {
  font-weight: 700;
  color: var(--accent-deep);
  margin-bottom: 4px;
}
.info-item dd { margin: 0; }

/* ---------- アクセス ---------- */
.step-list {
  counter-reset: step;
  list-style: none;
  margin: 0;
  padding: 0;
}

.step-list li {
  position: relative;
  padding: 4px 0 26px 58px;
}

.step-list li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--accent-deep), var(--accent-warm));
  color: #fff;
  font-weight: 800;
  font-size: 1.05rem;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(47, 158, 68, .3);
}

.step-list li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 19.5px;
  top: 44px;
  bottom: 2px;
  width: 2px;
  background: var(--line);
}

.step-list h3 { margin: 0 0 6px; font-size: 1.05rem; }
.step-list p { margin: 0; font-size: .95rem; }

.map-figure { margin: 26px 0 0; }
.map-figure img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  margin: 0 auto;
}
.map-figure figcaption {
  margin-top: 10px;
  text-align: center;
  color: var(--ink-soft);
  font-size: .85rem;
}

/* ---------- 問い合わせ ---------- */
.contact-box {
  background: linear-gradient(135deg, #f3faeb, #e6f4d5);
  border: 1px solid #cfe9b4;
  border-radius: var(--radius);
  padding: 28px 30px;
  text-align: center;
}
.contact-box .email {
  display: inline-block;
  margin: 10px 0 4px;
  padding: 10px 26px;
  background: #fff;
  border: 1.5px dashed var(--accent);
  border-radius: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--accent-deep);
}

/* ---------- CTA帯 ---------- */
.cta-band {
  background:
    radial-gradient(ellipse 600px 300px at 15% 120%, rgba(130, 201, 30, .35), transparent 60%),
    linear-gradient(135deg, #23682f 0%, var(--accent) 55%, var(--accent-warm) 100%);
  border-radius: var(--radius);
  color: #fff;
  text-align: center;
  padding: 44px 30px;
  box-shadow: var(--shadow-lg);
}
.cta-band h2 { margin: 0 0 10px; font-size: 1.4rem; }
.cta-band p { margin: 0 0 22px; opacity: .95; }
.cta-band .btn {
  background: #fff;
  color: var(--accent-deep);
}
.cta-band .btn:hover { color: var(--accent-deep); }

/* ---------- フッター ---------- */
.site-footer {
  margin-top: 60px;
  background: var(--footer-bg);
  color: #e8f2e0;
  padding: 40px 0 26px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 26px;
  align-items: start;
}

.site-footer h2 { margin: 0 0 6px; font-size: 1.05rem; color: #fff; }
.site-footer p { margin: 0; font-size: .88rem; opacity: .85; }

.footer-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
}
.footer-nav a { color: #bfe3a4; font-size: .88rem; }
.footer-nav a:hover { color: #fff; }

.copyright {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, .15);
  text-align: center;
  font-size: .82rem;
  font-style: normal;
  opacity: .7;
}

/* ---------- ユーティリティ ---------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.lead { font-size: 1.02rem; }

/* ---------- レスポンシブ ---------- */
@media (max-width: 900px) {
  .nav-toggle { display: flex; }

  .global-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    display: none;
  }
  .global-nav.open { display: block; }

  .global-nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px 16px 16px;
  }
  .global-nav a { border-radius: 10px; padding: 12px 14px; }

  .research-block,
  .research-block.reverse { grid-template-columns: 1fr; }
  .research-block.reverse .research-text { order: 1; }
  .research-block.reverse .research-figure { order: 2; }

  .footer-grid { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  body { font-size: 15px; }
  .brand-text .brand-ja { font-size: .82rem; white-space: normal; }
  .brand-text .brand-en { display: none; }
  .hero { padding: 52px 0 46px; }
  .card, .research-block { padding: 22px 18px; }
  .award-card { padding: 22px 20px 22px 56px; }
  .paper-card { padding: 22px 20px; }
  .member-table th { width: auto; display: block; border-bottom: 0; }
  .member-table td { display: block; padding-top: 6px; }
}

/* ---------- 印刷 ---------- */
@media print {
  .site-header, .site-footer, .hero-actions, .cta-band, .nav-toggle { display: none; }
  body { background: #fff; }
  .card, .research-block, .award-card, .paper-card { box-shadow: none; }
}
