@charset "utf-8";
/* ===========================
   Header Navigation Responsive
=========================== */

body {
	margin: 0;
	font-family: "Hiragino Kaku Gothic ProN",
	"Hiragino Sans",
	"Noto Sans JP",
	"Yu Gothic UI",
	"YuGothic",
	"Meiryo",
	sans-serif;
}
.pc {
	display: none;
}

/* Header Layout */
header {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	background: #fff;
	border-bottom: 1px solid #ddd;
	z-index: 1000;
}

.nav-container {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0.5rem 1rem;
}

/* Logo */
.logo img {
	height: 56px;
	display: block;
}

/* Navigation */
nav {
	flex: 1;
}

/* PC Menu */
ul.menu {
	list-style: none;
	margin: 0;
	padding: 0 50px 0 0;
	display: flex;
	justify-content: flex-end;
	gap: 50px;
	font-weight: 500;
}

ul.menu > li {
	position: relative;
}

ul.menu li a {
	display: block;
	padding: 1rem 0;
	text-decoration: none;
	color: #333;
	transition: all 0.3s;
	position: relative;
}

/* Hover underline */
ul.menu li a::after {
	content: "";
	position: absolute;
	bottom: 0.3rem;
	left: 50%;
	transform: translateX(-50%);
	width: 0%;
	height: 2px;
	background: #001f4d;
	transition: width 0.3s ease;
}

ul.menu li a:hover::after {
	width: 80%;
}



/* ====== 会社概要を押したら開閉だけする（リンク飛ばさない） ====== */

/* a をクリックしてもページ遷移しない */
.has-sub > a {
    pointer-events: none;
}

/* a を押したら sub-toggle をクリックしたのと同じ動作にする */
.has-sub > a {
    cursor: pointer;
}

.has-sub > a:active + .sub-toggle {
    pointer-events: auto;
}

/* ===========================
   PC Dropdown Redesigned
=========================== */
/* ドロップダウン内すべてのリストマーカーを非表示 */
ul.menu li ul,
ul.menu li ul li {
  list-style: none;
  padding-left: 0; /* 左の余白もリセット（見出しが揃う） */
  margin-left: 0;
}
ul.menu li ul {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	background: #fff;
	border: 1px solid #ddd;
	padding: 1rem;
	min-width: 480px;
	box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
	z-index: 2000;
}

ul.menu li:hover > ul {
	display: block;
}

/* 見出し（子要素の最初） */
ul.menu li ul > li:first-of-type > a {
	font-weight: bold;
	font-size: 1.1em;
	color: #001f4d;
	border-bottom: 2px solid #A7C9FF;
	margin-bottom: 0.8rem;
	padding-bottom: 0.5rem;
	display: inline-block;
	width: 100%;
}

/* 2番目以降を3列グリッド風に配置 */
ul.menu li ul li:not(:first-child) {
	display: inline-block;
	width: calc(33.333% - 1rem);
	margin: 0.5rem 0.5rem 0 0;
	vertical-align: top;
}

/* 子メニューリンク */
ul.menu li ul li a {
	display: block;
	padding: 0.4rem 0;
	color: #333;
	text-decoration: none;
	transition: color 0.3s;
}

/* 下線アニメーション無効化 */
ul.menu li ul li a::after {
	display: none;
}

/* ホバー時の色変更 */
ul.menu li ul li a:hover {
	color: #001f4d;
}
/*会社概要の子メニュの下*/
/* ===========================
   PC：smenu 専用デザイン
=========================== */
@media (min-width: 769px) {

  ul.menu li ul .smenu {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    border-top: 1px solid #E8E8E8;
    margin-bottom: 5px;
    padding-top: 5px;
  }

  ul.menu li ul .smenu li {
    width: 50%;
    font-size: 0.70em;
    margin: 0;
    padding: 0;
    font-weight: normal;
  }

}
/* Contact button */
.contact-btn2 {
	background-color: #1F286F;
	color: #fff;
	padding: 1rem 1.2rem;
	text-decoration: none;
	border-radius: 4px;
	font-weight: bold;
	white-space: nowrap;
}

/* Hamburger base hidden on PC */
#menu-toggle {
	display: none;
}

.hamburger {
	display: none;
}
/* ===========================
   PC：サブメニュー用のUIを非表示
=========================== */
@media (min-width: 769px) {
    .sub-toggle,
    .sub-arrow {
        display: none !important;
    }
}
/* ===========================
   Smartphone Navigation 修正版
   子メニューは非表示 → 親をタップで開閉
=========================== */

@media (max-width: 768px) {

    .pc {
        display: inherit;
    }
    .sp {
        display: none;
    }
/* 見出し（子要素の最初） */
  ul.menu li ul > li:first-of-type > a {
    display: none;
  }
    .nav-container {
        padding: 0.5rem;
    }

    /* Hamburger visible */
    .hamburger {
        display: flex;
        width: 33px;
        height: 22px;
        flex-direction: column;
        justify-content: space-between;
        cursor: pointer;
        margin-left: auto;
        margin-right: 5px;
    }

    .hamburger span {
        height: 3px;
        width: 100%;
        background: #333;
        border-radius: 2px;
        display: block;
    }

    /* Menu initially hidden */
    nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: #fff;
        border-top: 1px solid #ddd;
    }

    /* Toggle display */
    #menu-toggle:checked ~ nav {
        display: block;
    }

    /* Vertical menu */
    ul.menu {
        flex-direction: column;
        width: 100%;
        padding: 0;
        gap: 0;
    }

    /* 親メニューのスタイル */
    ul.menu > li {
        position: relative;
        width: 100%;
        border-bottom: 1px solid #ddd;
    }
    ul.menu > li > a {
        padding: 15px 15px;
        display: block;
        color: #333;
    }

    /* ===========================
       ▼ 親メニュー右側の矢印追加
    ============================ */

    /* ▼サブメニューを持つ親にだけ適用（クラス .has-sub） */
    ul.menu li.has-sub {
        position: relative;
    }

    /* ▼矢印ボタン */
    ul.menu li.has-sub .sub-arrow {
        position: absolute;
        right: 15px;
        top: 50%;
        transform: translateY(-50%);
        font-size: 1.1em;
        cursor: pointer;
    }

    /* ▼閉じているとき */
    ul.menu li.has-sub .sub-arrow::after {
	content: "▼";
	color: #71B0E4;
    }

    /* ▼チェックボックス（開閉用） */
    ul.menu li.has-sub .sub-toggle {
        display: none;
    }

    /* ▼開いたときの矢印 */
    ul.menu li.has-sub .sub-toggle:checked + .sub-arrow::after {
        content: "▲";
    }

    /* ===========================
       ▼ 子メニュー表示制御
    ============================ */

    /* 子メニューは最初隠す */
    ul.menu li.has-sub ul {
        display: none !important;
        padding: 0;
        margin: 0;
        border: none;
        box-shadow: none;
    }

    /* 開いたとき表示 */
    ul.menu li.has-sub .sub-toggle:checked ~ ul {
        display: block !important;
    }

    /* 子メニューのスタイル */

    /* PCのグリッド配置を無効化 */
    ul.menu li.has-sub ul li {
	display: block !important;
	width: 100% !important;
	margin: 0 !important;
	border-bottom: 1px solid #7198DD;
	background-color: #EDF4FF;
	padding-left: 30px;
	font-size: 0.9em;
    }
    /* hover 下線なし */
    ul.menu li a::after {
	height: 0;
	margin-left: 0px;
	
    }

    /* スマホ版 Contact ボタン */
    .contact-btn2 {
	padding: 0.8rem 1rem;
	margin-left: 10px;
	background-color: #EFF8FF;
	color: #1F286F;
    }


    /* 会社概要など、サブメニューを持つ親リンクをタップしても遷移しない */
    ul.menu li.has-sub > a {
        pointer-events: none; /* ← リンク機能を無効化 */
        color: #333;          /* 見た目はそのまま */
    }

    /* a タップで sub-toggle を押したのと同じ扱いにするためのクリック領域拡張 */
    ul.menu li.has-sub > a {
        position: relative;
    }

/* ▼ 会社概要の文字が潰れる不具合の修正 */
ul.menu li.has-sub > a::after {
    content: none !important;
    width: auto !important;
    height: auto !important;
}	
/* ▼ スマホ：会社概要の文字を押したら開閉するようにする */
ul.menu li.has-sub > a {
    pointer-events: auto !important; /* クリックを有効化 */
}

ul.menu li.has-sub > a {
    display: block;
}

/* a を押したら sub-arrow を押したのと同じ扱いにする */
ul.menu li.has-sub > a {
    cursor: pointer;
}

ul.menu li.has-sub > a:active + .sub-arrow {
    pointer-events: auto;
}	
}


