:root {
  /* ===== Base tokens ===== */
  --text: #0f172a;         /* 文字色（濃いネイビー） */
  --muted: #475569;        /* サブ文字色 */
  --border: #e2e8f0;       /* 罫線 */
  --bg: #ffffff;           /* 背景 */
  --bg-hover: #f1f5f9;     /* hover背景 */
  --cta: #4dbb9a;          /* CTA（お問い合わせ） */
  --cta-hover: #38a989;    /* CTA hover */
  --radius: 12px;          /* 角丸の基準 */
  --shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  --container: min(1280px, 92%);

  /* ===== Color variables（直書き色を全て吸収） ===== */
  --white: #fff;
  --black: #000;

  /* Header / Nav */
  --nav-cta-text: var(--white);

  /* Hero */
  --hero-text: var(--white);
  --hero-overlay: rgba(0, 0, 0, 0.3);
  --hero-home-panel: rgba(26, 59, 50, 0.5);
  --hero-company-panel: rgba(20, 60, 120, 0.6);
  --hero-book-panel: rgba(26, 59, 50, 0.5);

  /* Buttons */
  --btn-primary-bg: var(--cta);
  --btn-primary-hover: var(--cta-hover);
  --btn-primary-text: var(--white);

  /* Footer */
  --footer-bg: var(--bg);
  --footer-border: rgba(0, 0, 0, 0.12);
  --footer-text: var(--black);
  --footer-link: rgba(0, 0, 0, 0.92);
  --footer-tagline: rgba(0, 0, 0, 0.72);
  --footer-label: rgba(0, 0, 0, 0.6);
  --footer-title: rgba(42, 42, 42, 0.7);
  --footer-copyright: rgba(0, 0, 0, 0.65);

  /* Footer border (previously #e5e7eb) */
  --footer-border-strong: #e5e7eb;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", "Noto Sans JP", sans-serif;
  line-height: 1.7;
  letter-spacing: 0.02em;
  color: var(--text);
  background: var(--bg);
}

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

/* =========================================================
   Header: ヘッダー外枠（全幅）
   ========================================================= */
.header {
  white-space: nowrap;
  position: sticky;
  top: 0;
  z-index: 10;
  width: 100%;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

/* ヘッダー内（ロゴ＋ナビ） */
.header__inner {
  font-family: "Noto Sans JP", sans-serif;
  display: flex;
  text-decoration: none;
  align-items: center;
  gap: 24px;
  padding: 14px 0;
}

.tagline {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.logoimg {
  height: 48px;
  object-fit: contain;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  text-decoration: none;
  color: var(--text);
  display: inline-flex;
  align-items: center;
}

.nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 20px;
}

.nav__link {
  display: inline-block;
  padding: 10px 12px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--text);
  transition: background-color .2s ease, transform .15s ease;
}

.nav__link:hover {
  background: var(--bg-hover);
}

.nav__link--cta {
  background: var(--cta);
  color: var(--nav-cta-text);
  letter-spacing: 0.05em;
}

.nav__link--cta:hover {
  background: var(--cta-hover);
  transform: translateY(-2px);
}

/* =========================================================
   Container
   ========================================================= */
.container {
  width: var(--container);
  margin: 0 auto;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  border: 1px solid var(--border);
  background: var(--bg);
  border-radius: 10px;
  padding: 10px 12px;
}

/* =========================================================
   Hero
   ========================================================= */
.hero {
  position: relative;
  background-size: cover;
  background-position: center;
  padding: 120px 20px;
  color: var(--hero-text);
}

.hero--home {
  background-image: url("../images/forest.jpg");
}

.hero--company {
  background-image: url("../images/company.jpg");
}

.hero--book {
  background-image: url("../images/book.jpg");
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--hero-overlay);
}

.hero__inner {
  position: relative;
  max-width: 1100px;
  margin: 0 auto;
  text-align: left;
  padding: 40px 50px;
  border-radius: 16px;
  color: var(--hero-text);
}

.hero--home .hero__inner {
  background: var(--hero-home-panel);
}

.hero--company .hero__inner {
  background: var(--hero-company-panel);
}

.hero--book .hero__inner {
  background: var(--hero-book-panel);
}

.hero__title {
  font-size: 46px;
  margin-bottom: 16px;
}

.hero__text {
  font-family: "Noto Sans JP", sans-serif;
  font-size: 20px;
  margin-bottom: 24px;
}

.btn {
  display: inline-block;
  padding: 14px 26px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  transition: background-color .2s ease, transform .15s ease;
}

.btn-primary {
  background: var(--btn-primary-bg);
  color: var(--btn-primary-text);
  letter-spacing: 0.05em;
}

.btn-primary:hover {
  background: var(--btn-primary-hover);
  transform: translateY(-2px);
}

/* =========================================================
   Main layout（本文）
   ========================================================= */
.content {
  padding: 28px 0 56px;
}

/* =========================================================
   Card（共通部品）
   ========================================================= */

.card,
.news-item {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.card {
  box-shadow: var(--shadow);
}

/* 本文エリア */
.main h2 {
  margin: 0 0 16px;
  font-size: 22px;
}

.news {
  display: grid;
  gap: 14px;
}

.news-item h3 {
  margin: 0 0 8px;
  font-size: 16px;
}

.news-item p {
  margin: 0;
  color: var(--muted);
}

.news-item a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.section-title {
  margin: 28px 0 12px;
  font-size: clamp(18px, 1.6vw, 24px);
  font-weight: 800;
  color: var(--text);
  letter-spacing: .02em;

  /* 左のアクセント */
  padding-left: 12px;
  border-left: 4px solid var(--cta);
}

.company-section p {
  padding-left: 20px;
}

/* サイドバー (いったん無し)
.layout{
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 22px;
}

.sub .section{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  background: var(--bg);
}

.sub .section + .section{
  margin-top: 14px;
}

.sub h2{
  margin: 0 0 10px;
  font-size: 16px;
}

.sub ul{
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}

.sub a{
  color: var(--text);
  text-decoration: none;
}

.sub a:hover{
  text-decoration: underline;
  text-underline-offset: 3px;
}*/

/* ページトップ */
.page-top {
  display: flex;
  justify-content: center;
  margin: 40px;
}

.page-top a {
  color: var(--muted);
  text-decoration: none;
}

.page-top a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* book page */

.books {
  display: grid;
  gap: 18px;
}

.book-card {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 18px;
  align-items: start;
  scroll-margin-top: 100px;
}

.book-card__media img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.book-meta {
  margin: 10px 0 12px;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}

.book-meta>div {
  display: grid;
  grid-template-columns: 6em 1fr;
  gap: 10px;
}

.book-meta dt {
  font-weight: 700;
  color: var(--text);
}

.book-meta dd {
  margin: 0;
}

.book-lead {
  margin: 0;
}

@media (max-width: 760px) {
  .book-card {
    grid-template-columns: 1fr;
  }

  .book-card__media {
    max-width: 320px;
  }
}

/* Links page */
.link-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 10px;
}

.link-list a {
  color: var(--text);
  text-decoration: none;
}

.link-list a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* case page */
.case-card__media img{
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  object-fit: cover;
}

.case-card{
  scroll-margin-top: 100px; /* stickyヘッダー対策（#case_01等） */
}

@media (max-width: 900px){
  .layout--with-aside{
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   Modern Footer（メガフッター）
   ========================================================= */
.site-footer {
  margin-top: 56px;
  background: var(--footer-bg);
  border-top: 1px solid var(--footer-border-strong);
  color: var(--footer-text);
  padding: 40px 0 0;
}

.site-footer a {
  color: var(--footer-link);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 4列：左に会社情報＋右にナビ列 */
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 28px;
  padding-bottom: 28px;
}

/* 会社ブロック */
.footer-logo {
  display: inline-block;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: .04em;
}

.footer-tagline {
  margin: 8px 0 16px;
  color: var(--footer-tagline);
}

.footer-contact {
  display: grid;
  gap: 10px;
  margin: 0 0 18px;
}

.footer-label {
  display: inline-block;
  min-width: 3.5em;
  color: var(--footer-label);
}

.footer-cta {
  display: inline-block;
}

/* ナビ列 */
.footer-title {
  margin: 0 0 12px;
  font-size: 14px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--footer-title);
}

.footer-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.footer-bottom {
  border-top: 1px solid var(--footer-border);
  padding: 14px 0 18px;
}

.footer-bottom__inner {
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-footer .copyright {
  margin: 0;
  color: var(--footer-copyright);
  font-size: 12px;
}

/* Responsive */
@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   Responsive（スマホ）
   ========================================================= */
@media (max-width: 860px) {

  /* ロゴとナビを折り返す */
  .header__inner {
    flex-wrap: wrap;
    align-items: center;
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}
