/* ===== Root ===== */
:root {
  --nlab-dark: #1f2933;
  --nlab-blue: #1e6fff;
  --nlab-hover: #3ca370;
  --nlab-soft: #f6f8fb;
  --nlab-border: #e5e9f0;
  --nlab-text: #3f4a56;
}

/* ===== Base ===== */
body {
  font-family: 'Mulish', 'Noto Sans JP', sans-serif;
  color: var(--nlab-text);
  line-height: 1.75;
  font-size: 1.05rem;
  background: #ffffff;
}

a {
  color: var(--nlab-hover);
  text-decoration: none;
}

a:hover {
  color: #24784e;
  text-decoration: none;
}


/* ===== name bar hidden===== */
.nnlab-topbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 34px;
  background: #f5f6f8;
  color: #6b7280;
  font-size: 0.95rem;
  line-height: 34px;

  /* ↓これ削除 */
  /* padding-left: 2.5rem; */

  z-index: 1040;
}

.nnlab-topbar.hide {
  transform: translateY(-100%);
}


/* ===== Navbar ===== */

.nnlab-brand {
  display: flex;
  flex-direction: column;   /* ← 縦並びにする */
  align-items: flex-start;  /* ← 左揃え */
  line-height: 1.1;
}

.nnlab-site-title {
  font-size: 0.8rem;
  color: #4b5563;
  margin-top: 2px;
  margin-left: 8px;
  letter-spacing: 0.05em;
}

#nlabNavbar {
  top: 34px;
  background: #ffffff;
  box-shadow: none;
  transition: top 0.3s ease, box-shadow 0.3s ease;
  z-index: 1030;
}

#nlabNavbar.scrolled {
  top: 0;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.10);
}

.nnlab-logo {
  height: 70px;
  width: auto;
  max-width: 260px;
  object-fit: contain;
  background: transparent;
  padding: 0;
}

/* PC表示のときだけ、メニューを少し右へ移動 */
@media (min-width: 992px) {
  #navbarResponsive .navbar-nav {
    margin-left: 50px;
  }
}
/* Navigation colors:
   normal = black, active page = blue, hover/open = green */
#nlabNavbar .nav-link {
  color: #1f2933;
  /* font-size: 1.5rem; */
  font-weight: 600;
  letter-spacing: 0.02em;
  padding-left: 0.85rem;
  padding-right: 0.85rem;
  transition: color 0.2s ease;
}

#nlabNavbar .nav-link.active {
  color: var(--nlab-blue) !important;
  font-weight: 700;
}

#nlabNavbar .nav-link:hover,
#nlabNavbar .nav-link.show,
#nlabNavbar .nav-item.dropdown:hover > .nav-link {
  color: var(--nlab-hover) !important;
}

/* Active page has priority over hover/open */
#nlabNavbar .nav-link.active:hover,
#nlabNavbar .nav-link.active.show,
#nlabNavbar .nav-item.dropdown:hover > .nav-link.active {
  color: var(--nlab-blue) !important;
  font-weight: 700;
}

/* Dropdown menu */
#nlabNavbar .dropdown-menu {
  border: 1px solid var(--nlab-border);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.10);
}

#nlabNavbar .dropdown-item {
  color: #1f2933;
  font-weight: 500;
}

#nlabNavbar .dropdown-item:hover,
#nlabNavbar .dropdown-item:focus {
  color: var(--nlab-hover);
  background: #f6f8fb;
}

#nlabNavbar .dropdown-item.active,
#nlabNavbar .dropdown-item:active {
  color: #ffffff;
  background: var(--nlab-blue);
}

/* PC only: open dropdown on hover */
@media (min-width: 992px) {
  #nlabNavbar .dropdown:hover > .dropdown-menu {
    display: block;
    margin-top: -4px;
  }
}

/* Language switcher */
.nnlab-language {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-weight: 600;
  white-space: nowrap;
}

.nnlab-language .lang {
  color: #6b7280;
  padding: 3px 8px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.nnlab-language .lang:hover {
  color: var(--nlab-hover);
}

.nnlab-language .lang.active {
  color: var(--nlab-blue);
  font-weight: 700;
}

/* ===== Hero Carousel ===== */
.carousel-item {
  transition: transform 0.6s ease-in-out;
}

.nnlab-front-visual {
  padding-top: 0px;
  background: #ffffff;
  margin-bottom: 3rem;
}

.nnlab-front-visual .carousel {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  background: #ffffff;
}

.nnlab-front-visual .carousel-inner {
  background: #ffffff;
}

#labHeroCarousel .carousel-item {
  height: 580px;
  background: #ffffff;
  position: relative;
}

#labHeroCarousel .carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: #ffffff;
  filter: blur(0.px); /* ぼかし効果で文字を読みやすくする */
}

.hero-slide-title {
  position: absolute;
  left: 50%;
  top: 20%;
  transform: translate(-50%, -50%);
  z-index: 2;
  width: 80%;
  white-space: nowrap;
  color: #1f2933;
  font-size: clamp(2rem, 3vw, 3.5rem);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-align: center;
  line-height: 1.25;
  text-shadow:
    -1px -1px 0 #ffffff,
     1px -1px 0 #ffffff,
    -1px  1px 0 #ffffff,
     1px  1px 0 #ffffff;
  pointer-events: none;
}

/* ===== Lab Intro ===== */
.nnlab-intro {
  max-width: 1000px;
  margin: 3rem auto 4rem;
  padding: 0 1rem;
  text-align: center;
}

.nnlab-kicker {
  color: var(--nlab-blue);
  font-weight: 700;
  letter-spacing: 0.08em;
  margin-bottom: 0.4rem;
}

.nnlab-intro h1 {
  color: #111827;
  font-size: 1.4rem;
  font-weight: 500;
  line-height: 1.25;
  margin-bottom: 1rem;
}

.nnlab-intro p {
  max-width: 700px;
  margin: 0.5rem auto 0;
  color: #4b5563;
  font-size: 1.05rem;
  line-height: 1.9;
  text-align: justify;
  text-justify: inter-ideograph;
  hyphens: auto;
}

/* ===== Shared Layout ===== */
main > div,
main > section {
  max-width: 1120px;
  margin-left: auto;
  margin-right: auto;
}

.nnlab-heading {
  text-align: center;
  margin-top: 3rem;
  margin-bottom: 3rem;
}

.nnlab-heading span {
  display: inline-block;
  color: #555555dd;
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.05em;
  padding-bottom: 0.2rem;
  /* border-bottom: 1px solid #ddd; */
}


/* ===== Research Cards ===== */
.nnlab-card-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
}

.nnlab-focus-card {
  border: 1px solid var(--nlab-border);
  border-radius: 16px;
  padding: 1.8rem;
  background: #ffffff;
  box-shadow: 0 0.5rem 1.5rem rgba(31, 41, 51, 0.06);
  display: flex;
  flex-direction: column;
  text-align: center;
}

.nnlab-focus-card img {
  width: 100%;
  max-width: 240px;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto 1.2rem;
}

.nnlab-focus-card h3 {
  font-size: 1.2rem;
  font-weight: 600;
  margin-bottom: 0.8rem;
}

.nnlab-focus-card p {
  text-align: justify;
  font-size: 1.03rem;
  line-height: 1.7;
}

/* ===== News & Updates ===== */
.nnlab-updates {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1.2rem;
}

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

.nnlab-update-list li {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1.5rem;
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--nlab-border);
}

.nnlab-update-date {
  color: #6b7280;
  font-weight: 500;
}

.nnlab-update-text {
  color: #1f2933;
}

/* ===== Page Banner ===== */
/* ===== Page Banner ===== */
.nnlab-banner {
  height: 280px;
  padding-top: 0;
  margin-top: 0;

  display: flex;
  align-items: center;
  justify-content: center;

  background-size: cover;
  background-position: center center;
  color: #111827;
  text-align: center;
}

.nnlab-banner .container {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

.nnlab-banner h1 {
  margin: 0;
  padding-left: 0;
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #111827;
  text-shadow: none;
}

body {
  padding-top: 135px;
}

/* ===== Research Topics ===== */
.nnlab-topic-area {
  max-width: 1000px;
  margin: 3.5rem auto 4.5rem;
  padding: 0 1.2rem;
}

.nnlab-topic-block {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--nlab-border);
}

/* 最後だけ線を消す（重要） */
.nnlab-topic-block:last-child {
  border-bottom: none;
}

.nnlab-topic-block h3 {
  font-size: 1.3rem;
  font-weight: 600;
  color: #111827;
  margin-bottom: 0.8rem;
  padding-left: 0.8rem;              /* 文字と線の間 */
  border-left: 5px solid var(--nlab-blue);  /* 青い縦棒 */

  margin-bottom: 1rem;
} 

.nnlab-topic-row {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 2rem;
  align-items: center;
}


.nnlab-topic-row.nnlab-row-flip {
  grid-template-columns: 1fr 240px;
}

.nnlab-row-flip .nnlab-topic-visual {
  order: 2;
}

.nnlab-row-flip .nnlab-topic-copy {
  order: 1;
}

.nnlab-topic-visual img {
  width: 100%;
  max-width: 240px;
  height: auto;
  display: block;
}

.nnlab-topic-visual figure {
  display: inline-block;   /* ← これが重要 */
}


.nnlab-caption {
  font-size: 0.82rem;
  line-height: 1.35;
  margin-top: 0.35rem;
  color: #6b7280;
  max-width: 100%;      /* ← 長すぎる行を防ぐ */
  text-align: justify;
  text-justify: inter-word;   /* ← 英語用 */
  hyphens: auto;
}

.nnlab-topic-copy h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 0.4rem;
}

.nnlab-topic-copy p {
  color: #4b5563;
  font-size: 1rem;
  line-height: 1.8;
  margin: 0;
  text-align: justify;              /* ← これが本体 */
  text-justify: inter-word;         /* ← 英文用（推奨） */
  white-space: normal;
}

@media (max-width: 767.98px) {
  .nnlab-topic-row,
  .nnlab-topic-row.nnlab-row-flip {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .nnlab-row-flip .nnlab-topic-visual,
  .nnlab-row-flip .nnlab-topic-copy {
    order: initial;
  }

  .nnlab-topic-visual img {
    width: 180px;
    height: 180px;
    margin: 0 auto;
  }
}

/* ===== Publications ===== */.nnlab-output-area {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3.5rem 1.2rem;
}

.nnlab-output-year {
  margin-bottom: 3rem;
}

.nnlab-output-year h2 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #111827;
  padding-left: 0.8rem;
  border-left: 5px solid var(--nlab-blue);
  margin-bottom: 1rem;
}

.nnlab-output-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
  border-top: 1px solid var(--nlab-border);
}

.nnlab-output-list li {
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--nlab-border);
}

.nnlab-output-list a {
  display: block;
  color: #111827;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.55;
  text-decoration: none;
}

.nnlab-output-list a:hover {
  color: var(--nlab-blue);
  text-decoration: none;
}

.nnlab-output-authors {
  margin-top: 0.6rem;
  color: #4b5563;
  font-size: 1.02rem;
  line-height: 1.6;
}

.nnlab-output-source {
  margin-top: 0.25rem;
  color: #6b7280;
  font-size: 1rem;
  font-style: italic;
  line-height: 1.6;
}

.nnlab-output-title {
  display: block;
  color: #111827;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.55;
  margin-bottom: 0.4rem;
    pointer-events: none;
}
/* ===== conference ===== */
.conference-category {
  margin: 1.4rem 0 0.8rem;
  color:#4b5563;
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.conference-category + .nnlab-output-list {
  margin-bottom: 2rem;
}

/* ===== awards ===== */
.nnlab-award-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nnlab-award-list li {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 1.5rem;
  padding: 1.4rem 0;
}

.nnlab-award-year {
  color: #111827;
  font-weight: 700;
}

.nnlab-award-title {
  color: #111827;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.55;
}

.nnlab-award-recipient {
  margin-top: 0.25rem;
  color: #4b5563;
  font-size: 1.02rem;
  line-height: 1.6;
}

.nnlab-award-desc {
  margin-top: 0.25rem;
  color: #6b7280;
  font-size: 1rem;
  font-style: italic;
  line-height: 1.6;
}

/* ===== Member ===== */
.member-section {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4rem 1rem;
}

.member-section h2 {
  font-size: 1.6rem;
  font-weight: 500;
  color: #333;
  margin-bottom: 2rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid #222;
}

.member-group {
  margin-bottom: 3rem;
}

.member-group h3 {
  font-size: 1.4rem;
  font-weight: 600;
  border-left: 4px solid var(--nlab-blue);
  padding-left: 12px;
  margin-bottom: 1.2rem;
  color: #111;
}

.member-item {
  display: grid;
  grid-template-columns: 260px 1fr;
  column-gap: 2rem;
  padding: 1.4rem 0;
  border-bottom: 1px solid #e5e5e5;
  line-height: 1.5;
}

.member-name {
  font-size: 1.3rem;
  font-weight: 600;
  color: #111;
  line-height: 1.45;
}

.member-role {
  margin-top: 0.35rem;
  font-size: 1.05rem;
  font-weight: 500;
  color: #444;
  line-height: 1.55;
}

.member-affiliation {
  margin-top: 0.15rem;
  font-size: 1rem;
  color: #666;
  line-height: 1.55;
}

.member-detail {
  font-size: 1rem;
  color: #555;
  line-height: 1.6;
}

.member-keywords {
  font-size: 1.05rem;
  font-weight: 600;
  color: #111;
  line-height: 1.45;
  margin-bottom: 0.45rem;
  
}

.member-detail p {
  margin-bottom: 0.7rem;
  font-size: 1.05rem;
  color: #555;
  line-height: 1.6;
}

.member-links {
  margin-top: 0.7rem;
  margin-bottom: 0;
}

.member-links a {
  font-size: 0.95rem;
  color: #111;
  font-weight: 500;
}

.member-links a:hover {
  color: #51be78;
}

.member-links span {
  color: #aaa;
  margin: 0 0.5rem;
}

.empty-note {
  font-size: 0.95rem;
  color: #555;
  line-height: 1.6;
  padding: 1.4rem 0;
  border-bottom: 1px solid #e5e5e5;
  
}

.member-profiles {
  margin-top: 1rem;
  font-size: 0.95rem;
  font-weight: 550;
}

.member-profiles a {
  color: #333;
  font-weight: 550;
}

.member-profiles a:hover {
  color: #51be78;
}

.member-profiles span {
  margin: 0 0.4rem;
  color: #aaa;
}



/* ===== Philosophy ===== */
.Philosophy-section {
  max-width: 900px;
  margin: 3.5rem auto;
  padding: 0 1.2rem;
}

.Philosophy-intro {
  max-width: 760px;
  margin: 0 auto 2.5rem;
  text-align: center;
}

.Philosophy-intro p {
  font-size: 1.05rem;
  line-height: 1.9;
  color: #4b5563;
  text-align: justify;   
  text-justify: inter-word;   /* ← 英文用（推奨） */
}

.Philosophy-item {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--nlab-border);
}

.Philosophy-icon {
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #f3f6fb;
  display: flex;
  align-items: center;
  justify-content: center;
}

.Philosophy-icon svg {
  width: 26px;
  height: 26px;
  stroke: var(--nlab-blue);
  stroke-width: 1.8;
  fill: none;
}

.Philosophy-text h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 0.4rem;
}

.Philosophy-text p {
  font-size: 1.02rem;
  line-height: 1.75;
  color: #4b5563;
  margin: 0;
}


/* ===== Contact ===== */
/* ===== Contact ===== */
.nnlab-contact-area {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4rem 1.2rem 5rem;  /* ← 少し広げる */
}

.nnlab-contact-card {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 3rem;

  padding: 0;              /* ← 余白削除 */
  border: none;            /* ← 枠消す */
  border-radius: 0;        /* ← 角丸消す */
  background: transparent; /* ← 背景消す */
  box-shadow: none;        /* ← 影消す */
}

.nnlab-contact-info {
  padding-right: 1rem;
}

.nnlab-contact-form {
  padding-left: 1rem;
}

.nnlab-contact-info h2,
.nnlab-contact-form h2 {
  font-size: 1.2rem;
  font-weight: 700;
  color: #111827;
  padding-left: 0.8rem;
  border-left: 4px solid var(--nlab-blue);
  margin-bottom: 1.2rem;
}

.nnlab-contact-info p,
.nnlab-contact-form p {
  color: #4b5563;
  line-height: 1.8;
  margin-bottom: 1.5rem;
}

.nnlab-contact-button {
  display: inline-block;
  padding: 0.85rem 1.8rem;
  background: var(--nlab-blue);
  color: #ffffff;
  font-weight: 600;
  border-radius: 0;
}

.nnlab-contact-button:hover {
  color: #ffffff;
  background: #1557d8;
}

@media (max-width: 767.98px) {
  .nnlab-contact-card {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 1.8rem;
  }
}

@media (max-width: 575.98px) {
  .Philosophy-item {
    gap: 1rem;
  }

  .Philosophy-icon {
    flex-basis: 44px;
    width: 44px;
    height: 44px;
  }

  .Philosophy-icon svg {
    width: 22px;
    height: 22px;
  }
}
/* ===== access link ===== */

.access-link {
  margin-top: 8px;
}

.access-link a {
  color: #2f6fff;
  text-decoration: none;
  font-weight: 500;
}

.access-link a:hover {
  text-decoration: underline;
}


/* ===== Footer ===== */.nnlab-footer {
  width: 100%;
  max-width: none;
  background: #f3f4f6;
  color: #4b5563;
  padding: 2.5rem 1rem;
  margin-top: 3rem;
  border-top: 1px solid var(--nlab-border);
}

.nnlab-footer .container {
  max-width: 1120px;
  margin: 0 auto;
}

.nnlab-footer a {
  color: #090b0f;
}

.nnnlab-footer-main {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.nnnlab-footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.35rem 0.75rem;
  font-size: 0.9rem;
}

.nnlab-copyright {
  margin: 1rem 0 0;
  color: #6b7280;
  font-size: 0.9rem;
}



/* ===== Responsive ===== */
@media (max-width: 991.98px) {
  #nlabNavbar .container {
    position: relative;
  }

  .nnlab-logo {
    height: 48px;
    max-width: 180px;
  }

  .navbar-brand {
    margin-right: 0;
  }

  .navbar-toggler {
    margin-left: auto;
    padding: 0.25rem 0.5rem;
    border: none;
  }

  .navbar-toggler:focus {
    box-shadow: none;
  }

  #navbarResponsive {
    position: absolute;
    top: 64px;
    right: 12px;
    left: auto;
    width: 240px;
    background: #ffffff;
    border: 1px solid var(--nlab-border);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    z-index: 2000;
  }

  #navbarResponsive .navbar-nav {
    align-items: flex-start;
  }

  #navbarResponsive .nav-link {
    padding: 0.45rem 0.2rem;
  }

  #navbarResponsive .nnlab-language {
    margin-left: 0 !important;
    margin-top: 0.8rem;
    justify-content: flex-start;
  }

  .nnlab-card-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .nnlab-focus-overview {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .nnlab-focus-card {
    width: 80%;
    margin: 0 auto;
    padding: 1.4rem;
  }

  .nnlab-focus-card img {
    max-width: 220px;
  }
}

@media (max-width: 575.98px) {
  body {
    font-size: 1rem;
  }

  .hero-slide-title {
    width: 90%;
    white-space: normal;
    font-size: clamp(1.5rem, 7vw, 2.2rem);
  }

  .nnlab-output-area {
    padding: 2.5rem 1rem;
  }

  .nnlab-output-year h2 {
    font-size: 1.3rem;
  }

  .nnlab-output-list a {
    font-size: 1.05rem;
  }

  .nnlab-output-authors,
  .nnlab-output-source {
    font-size: 0.95rem;
  }

  .nnlab-update-list li {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }

  .nnlab-focus-card {
    width: 100%;
  }
}
@media (max-width: 575.98px) {
  .nnlab-award-list li {
    grid-template-columns: 1fr;
    gap: 0.3rem;
  }
}

@media (max-width: 767.98px) {
  .nnlab-contact-info,
  .nnlab-contact-form {
    padding-left: 0;
    padding-right: 0;
  }
}