/* ===================================================================
  common.css
  全ページ共通：リセット / 変数 / 基本タイポグラフィ / 共通パーツ
=================================================================== */

/* -------------------------------------------------------------
  Reset
------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height-pc);
}
body, h1, h2, h3, h4, h5, h6, p, ul, ol, li, dl, dt, dd, figure, blockquote {
  margin: 0;
  padding: 0;
}
ul, ol {
  list-style: none;
}
img {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
  border: none;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  background: none;
  border: none;
  font: inherit;
  color: inherit;
  cursor: pointer;
  padding: 0;
}
table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* -------------------------------------------------------------
  Variables
------------------------------------------------------------- */
:root {
  /* Color */
  --color-main:  #020343;
  --color-sub1:  #025AA1;
  --color-sub2:  #75ABC5;
  --color-sub3:  #DDDDDD;
  --color-sub4:  #F3F3F3;
  --color-sub5:  #525252;
  --color-text:  #333333;
  --color-white: #FFFFFF;

  /* Layout */
  --content-width: 1200px;
  --side-padding: 20px;

  /* Header height */
  --header-height-pc: 100px;
  --header-height-sp: 60px;

  /* Breakpoint (参考値 / メディアクエリは直接数値指定) */
  --bp-tablet: 768px;
  --bp-sp: 480px;

  /* 1400px基準の左寄せガター（全ページで流用） */
  --gutter-1400: max(20px, calc((100vw - 1400px) / 2));
}

/* -------------------------------------------------------------
  Base
------------------------------------------------------------- */
body {
  font-family: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Hiragino Sans", sans-serif;
  font-weight: 400;
  color: var(--color-text);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

p {
  margin-bottom: 20px;
  line-height: 1.8;
}
p:last-child {
  margin-bottom: 0;
}

a {
  transition: opacity .3s ease, background-color .3s ease, color .3s ease;
}

/* -------------------------------------------------------------
  Utility（全ページ流用）
------------------------------------------------------------- */
.wrapper {
  width: 100%;
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 var(--side-padding);
}

.u-sp-only {
  display: none;
}
.u-pc-only {
  display: block;
}
@media (max-width: 768px) {
  .u-sp-only {
    display: block;
  }
  .u-pc-only {
    display: none;
  }
}

/* -------------------------------------------------------------
  section-heading（英語+日本語の重なり見出し／全ページ流用）
------------------------------------------------------------- */
.section-heading {
	margin-bottom: 50px;
  padding-left: max(0, calc((100vw - 1400px) / 2));
}
.section-heading__en {
  margin: 0;
  font-size: 80px;
  font-weight: 500;
  line-height: .8;
  color: var(--color-sub3);
}
.section-heading__ja {
  position: relative;
  margin: -35px 0 0 0;
  font-size: 40px;
  font-weight: 700;
  color: var(--color-main);
}
@media (max-width: 768px) {
  .section-heading {
  	margin-bottom: 30px;
    padding-left: 0;
  }
  .section-heading__en {
    font-size: 40px;
  }
  .section-heading__ja {
    margin-top: -14px;
    font-size: 26px;
    line-height: 1.4;
  }
}

/* -------------------------------------------------------------
  btn-more（「詳しく見る」ボタン／全ページ流用）
------------------------------------------------------------- */
.btn-more {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 140px;
  padding: 12px 20px;
  background: var(--color-white);
  color: var(--color-main);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  text-align: center;
  transition: background-color .5s ease, color .5s ease, border-color .5s ease;
}
.btn-more::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 10px;
  width: 7px;
  height: 7px;
  border-top: 1px solid currentColor;
  border-right: 1px solid currentColor;
  transform: translateY(-50%) rotate(45deg);
}
.btn-more:hover {
  background: var(--color-sub2);
  color: var(--color-main);
}
/* ホバー時に背景・文字（矢印含む）を反転させるバリエーション（全ページ流用） */
.btn-more--dark-hover:hover {
  background: var(--color-main);
  color: var(--color-white);
}

/* -------------------------------------------------------------
  contact-cta（お問い合わせ／全ページ共通・フッター直前に配置）
------------------------------------------------------------- */
.contact-cta {
  position: relative;
  overflow: hidden;
  margin-top: 100px;
  padding: 70px 0;
}
.contact-cta__bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.contact-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-main);
  opacity: .85;
  z-index: 1;
}
.contact-cta .wrapper {
  position: relative;
  z-index: 2;
  color: var(--color-white);
}

.contact-cta__heading {
  text-align: center;
  margin-bottom: 40px;
}
.contact-cta__heading-en {
  font-size: 18px;
  letter-spacing: .1em;
  margin-bottom: 0;
}
.contact-cta__heading-ja {
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
}

.contact-cta__row {
  display: flex;
  justify-content: center;
  align-items: center;
}

.contact-cta__tel {
  text-align: center;
  padding-right: 60px;
}
.contact-cta__label {
  font-size: 16px;
  margin-bottom: 4px;
}
.contact-cta__tel-number {
  display: flex;
  align-items: center;
  margin-bottom: 6px;
  line-height: 1.4;
}
.contact-cta__tel-label {
  font-size: 18px;
  margin-right: 10px;
}
.contact-cta__tel-link {
  font-size: 40px;
  font-weight: 700;
  letter-spacing: 3px;
}
.contact-cta__tel-hours {
  font-size: 16px;
}
.contact-cta__form {
  text-align: center;
  padding-left: 60px;
  border-left: 1px solid rgba(255, 255, 255, .4);
}
.contact-cta__btn {
  width: 280px;
  max-width: 100%;
  font-size: 16px;
  padding: 16px 34px 16px 20px;
}
.contact-cta__btn-icon {
  flex-shrink: 0;
  width: 24px;
  height: auto;
  margin-right: 10px;
  object-fit: contain;
}

/* 電話番号リンクはスマホのみ反応させる（PCではタップ発信の必要がないため無効化） */
@media (min-width: 769px) {
  .contact-cta__tel-link {
    pointer-events: none;
    cursor: default;
  }
}

@media (max-width: 768px) {
  .contact-cta {
    margin-top: 60px;
    padding: 40px 0;
  }
  .contact-cta__heading {
    margin-bottom: 30px;
  }
  .contact-cta__heading-ja {
    font-size: 26px;
  }
  .contact-cta__row {
    flex-direction: column;
  }
  .contact-cta__tel {
    padding-right: 0;
    margin-bottom: 30px;
  }
  .contact-cta__label {
    margin-bottom: 5px;
  }
  .contact-cta__tel-number {
    line-height: 1.4;
  }
  .contact-cta__tel-link {
    font-size: 30px;
  }
  .contact-cta__form {
    padding-left: 0;
    padding-top: 20px;
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, .4);
  }
}
body {
  padding-top: var(--header-height-pc);
}
@media (max-width: 768px) {
  html {
    scroll-padding-top: var(--header-height-sp);
  }

  body {
    padding-top: var(--header-height-sp);
  }
}

/* ===================================================================
  Header
=================================================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height-pc);
  background: var(--color-white);
  z-index: 1000;
  transition: box-shadow .3s ease;
}
.header.is-scrolled {
  box-shadow: 0 4px 12px rgba(0, 0, 0, .08);
}

.header__inner {
  position: relative;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 240px 1fr auto;
  grid-template-rows: auto auto;
  align-items: center;
  align-content: center;
  row-gap: 0;
  padding: 0 var(--side-padding);
}

/* ロゴ：行の高さ計算に影響させず、ヘッダー全体に対して常に縦中央に配置 */
.header__logo {
  position: absolute;
  left: var(--side-padding);
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  line-height: 0;
}
.header__logo a {
  display: block;
  line-height: 0;
}
.header__logo img {
  width: 280px;
  height: auto;
}

/* nav全体（PCではグリッドの子としてそのまま配置するためdisplay:contents） */
.gnav {
  display: contents;
}

/* 上段：建値・FAQ・採用情報 */
.gnav__secondary {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  line-height: 1;
  padding: 4px 0;
}
.gnav__secondary a {
  padding: 5px 10px;
  display: inline-block;
}
.gnav__secondary .is-recruit a {
  color: var(--color-white);
  border: 1px solid var(--color-sub1);
  background: var(--color-sub1);
  transition: .5s ease;
}
.gnav__secondary .is-recruit a:hover {
  background: var(--color-main);
}

/* 上段：JP / EN（デザイン通り、枠線で囲ったセットにする） */
.gnav__lang {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
  align-self: center;
  display: flex;
  font-size: 13px;
  line-height: 1;
  margin-left: 18px;
  border: 1px solid var(--color-main);
  overflow: hidden;
}
.gnav__lang a {
  display: inline-block;
  padding: 5px 10px;
}
.gnav__lang .is-current {
  background: var(--color-main);
  color: var(--color-white);
}
.gnav__lang-en {
  background: var(--color-white);
  color: var(--color-text);
}
.gnav__lang-en:hover {
  background: var(--color-sub2);
}

/* メインナビ */
.gnav__main {
  grid-column: 2 / 4;
  grid-row: 2;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 18px;
}
.gnav__item {
  position: relative;
}
.gnav__item > a {
  display: block;
  padding: 5px 0;
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
}

/* ドロップダウン（PC） */
.gnav__dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  background: var(--color-sub2);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity .25s ease, transform .25s ease, visibility .25s ease;
  z-index: 10;
}
.gnav__item.has-dropdown:hover .gnav__dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.gnav__dropdown a {
  display: block;
  padding: 14px 14px;
  font-size: 14px;
  color: var(--color-white);
}

@media (min-width: 769px) {
  .gnav__dropdown a:hover {
    background: var(--color-sub1);
  }
}

/* ハンバーガーボタン（PCでは非表示） */
.hamburger {
  display: none;
}

/* ===================================================================
  Header（タブレット・スマホ）
=================================================================== */
@media (max-width: 768px) {
  .header {
    height: var(--header-height-sp);
  }
  .header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  .header__logo {
    position: static;
    left: auto;
    top: auto;
    transform: none;
  }
  .header__logo img {
    width: 180px;
  }

  /* PCのグリッド配置を解除してオーバーレイ内で縦積みにする */
  .gnav {
    display: block;
    position: fixed;
    top: var(--header-height-sp);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height-sp));
    padding-bottom: 200px;
    background: var(--color-main);
    overflow-y: auto;
    visibility: hidden;
    opacity: 0;
    transform: translateY(-12px);
    transition: opacity .35s ease, transform .35s ease, visibility .35s ease;
  }
  .gnav.is-open {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
  }

  .gnav__lang {
    width: 140px;
    height: 38px;
    font-size: 15px;
    margin: 28px auto;
    border: 1px solid var(--color-white);
    overflow: hidden;
  }
  .gnav__lang li {
    flex: 1;
  }
  .gnav__lang a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--color-white);
  }
  .gnav__lang .is-current {
    background: var(--color-white);
    color: var(--color-main);
    font-weight: 700;
  }
  .gnav__lang-en {
    background: transparent;
  }
  .gnav__lang-en:hover {
    background: transparent;
  }

  .gnav__main {
    display: block;
    padding: 0 20px;
  }
  .gnav__item > a {
    padding: 18px 10px;
    color: var(--color-white);
    font-size: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .5);
  }
  .gnav__item.has-dropdown:first-of-type > a {
    border-top: 1px solid rgba(255, 255, 255, .5);
  }
  .gnav__item.has-dropdown > a {
    position: relative;
  }
  .gnav__item.has-dropdown > a::after {
    content: "+";
    position: absolute;
    right: 10px;
    font-size: 18px;
    transition: transform .3s ease;
  }
  .gnav__item.has-dropdown.is-open > a::after {
    content: "\2212"; /* − */
  }

  .gnav__dropdown {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    background: var(--color-white);
    max-height: 0;
    overflow: hidden;
    transition: max-height .35s ease;
  }
  .gnav__item.has-dropdown.is-open .gnav__dropdown {
    max-height: 600px;
  }
  .gnav__dropdown li:not(:last-of-type) {
    border-bottom: 1px dotted #CCC;
  }
  .gnav__dropdown a {
    display: block;
    padding: 10px 10px;
    font-size: 15px;
    color: var(--color-main);
    border-bottom: none;
  }

  .gnav__secondary {
    display: block;
    padding: 0 20px;
  }
  .gnav__secondary a {
    display: block;
    padding: 18px 10px;
    color: var(--color-white);
    font-size: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .5);
  }
  .gnav__secondary .is-recruit a {
    background: none;
    color: var(--color-white);
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, .5);
  }

  /* ハンバーガーボタン */
  .hamburger {
    display: block;
    position: relative;
    width: 24px;
    height: 18px;
    z-index: 1100;
  }
  .hamburger span {
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--color-main);
    transition: transform .3s ease, opacity .3s ease, top .3s ease;
  }
  .hamburger span:nth-child(1) {
    top: 0;
  }
  .hamburger span:nth-child(2) {
    top: 8px;
  }
  .hamburger span:nth-child(3) {
    top: 16px;
  }
  .hamburger.is-active span:nth-child(1) {
    top: 10px;
    transform: rotate(45deg);
  }
  .hamburger.is-active span:nth-child(2) {
    opacity: 0;
  }
  .hamburger.is-active span:nth-child(3) {
    top: 10px;
    transform: rotate(-45deg);
  }
}

/* -------------------------------------------------------------
  footer-links-top（フッター上のボタン3つ／全ページ共通）
------------------------------------------------------------- */
.footer-links-top {
  border-bottom: 1px solid var(--color-sub3);
}
.footer-links-top .wrapper {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 30px 0;
}
.footer-links-top__btn {
  width: 280px;
  border: 1px solid var(--color-main);
  justify-content: center;
  font-size: 15px;
  padding: 16px 34px 16px 20px;
}
.footer-links-top__btn:hover {
  background: #C5D9E4;
}
.footer-links-top__icon {
  flex-shrink: 0;
  margin-right: 10px;
  object-fit: contain;
}
.footer-links-top__icon--knowledge {
  width: 17px;
  height: auto;
}
.footer-links-top__icon--basic {
  width: 22px;
  height: auto;
}
.footer-links-top__icon--faq {
  width: 24px;
  height: auto;
}
@media (max-width: 768px) {
  .footer-links-top .wrapper {
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 40px 0;
  }
}

/* -------------------------------------------------------------
  footer（全ページ共通）
------------------------------------------------------------- */
.footer {
  padding-top: 50px;
}
.footer__row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 55px;
  margin-bottom: 18px;
}

.footer__company {
  flex-shrink: 0;
}
.footer__logo {
  height: 64px;
  width: auto;
  margin-bottom: 16px;
}
.footer__address,
.footer__tel,
.footer__fax {
  font-size: 14px;
  margin-bottom: 4px;
}

.footer__nav {
  display: flex;
  justify-content: end;
  flex: 1;
  gap: 30px;
}
.footer__nav-col {
  flex: 0 0 auto;
  min-width: 0;
}
.footer__nav-title {
  margin-bottom: 0;
  white-space: nowrap;
}
.footer__nav-title a {
  font-size: 14px;
  font-weight: 700;
  color: var(--color-main);
}
.footer__nav-title--spaced {
  margin-top: 10px;
}
.footer__nav-list li {
  margin-bottom: 0;
  white-space: nowrap;
}
.footer__nav-list li.lh {
  line-height: 1.2;
  margin-top: 6px;
}
.footer__nav-list a {
  font-size: 13px;
  color: var(--color-text);
}
.footer__nav-col--main-only .footer__nav-title {
  margin-bottom: 8px;
}

.footer__copyright {
  padding: 10px 0 20px;
}
.footer__copyright p {
  font-size: 12px;
  margin-bottom: 0;
}

@media (min-width: 769px) {
  .footer__tel a {
    pointer-events: none;
    cursor: default;
  }
}

@media (max-width: 768px) {
  .footer {
    padding: 30px 0 10px;
  }
  .footer__row {
    display: block;
    margin-bottom: 14px;
  }
  .footer__company {
    margin-bottom: 0;
    text-align: center;
  }
  .footer__logo {
    height: 42px;
    margin-bottom: 14px;
  }
  .footer__address,
  .footer__tel,
  .footer__fax {
    font-size: 14px;
  }
  .footer__nav {
    display: none;
  }
  .footer__copyright {
    padding: 12px 0 20px;
    text-align: center;
  }
}



/* -------------------------------------------------------------
  process-label（工程・部門ラベル／全ページ共通）
------------------------------------------------------------- */
.process-label {
  display: inline-block;
  width: auto;
  padding: 5px 15px;
  background: var(--color-white);
  color: var(--color-text);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  white-space: nowrap;
}

.process-label--blue {
  background: var(--color-sub1);
  color: var(--color-white);
}

/* -------------------------------------------------------------
  lower-mv（下層ページ共通メインビジュアル）
------------------------------------------------------------- */
.lower-mv {
  position: relative;
  width: 100%;
  height: 600px;
  overflow: hidden;
}

.lower-mv__image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.lower-mv__title-box {
  position: absolute;
  top: 50%;
  left: var(--gutter-1400);
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: calc(100% - 40px);
  max-width: 400px;
  min-height: 340px;
  padding: 50px 60px;
  background: rgba(255, 255, 255, .76);
}

.lower-mv__title {
  margin: 0 0 16px;
  color: var(--color-main);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.4;
}

.lower-mv__catch {
  margin: 0;
  color: #666666;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.4;
}

/* -------------------------------------------------------------
  lower-lead（下層ページ共通リード文）
------------------------------------------------------------- */
.lower-lead {
  padding: 80px 0;
}

.lower-lead p {
  margin: 0;
  font-size: 24px;
  text-align: center;
}

@media (max-width: 768px) {
  .lower-mv {
    height: 440px;
  }

  .lower-mv__title-box {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    max-width: calc(100% - 40px);
    min-height: 200px;
    padding: 30px 20px;
    text-align: center;
  }

  .lower-mv__title {
    margin-bottom: 6px;
    font-size: 30px;
    text-align: center;
  }

  .lower-mv__catch {
    font-size: 20px;
    text-align: center;
  }

  .lower-lead {
    padding: 40px 0;
  }

  .lower-lead p {
    font-size: 20px;
    line-height: 1.6;
    text-align: left;
  }
}

/* -------------------------------------------------------------
  lower-section-heading（下層ページ共通：英語＋日本語＋左線見出し）
------------------------------------------------------------- */
.lower-section-heading {
  display: flex;
  align-items: flex-end;
  gap: 20px;
  margin-bottom: 42px;
}

.lower-section-heading::before {
  content: "";
  display: block;
  flex: 0 0 60px;
  width: 60px;
  height: 1px;
  margin-bottom: 24px;
  background: var(--color-main);
}

.lower-section-heading__text,
.lower-section-heading__en,
.lower-section-heading__ja {
  display: block;
}

.lower-section-heading__text {
  min-width: 0;
}

.lower-section-heading__en {
  margin: 0 0 2px;
  color: var(--color-main);
  font-size: 18px;
  font-weight: 300;
  line-height: 1.4;
}

.lower-section-heading__ja {
  margin: 0;
  color: var(--color-main);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.25;
}

@media (max-width: 768px) {
  .lower-section-heading {
    align-items: center;
    gap: 12px;
    margin-bottom: 28px;
  }

  .lower-section-heading::before {
    flex-basis: 20px;
    width: 20px;
    margin-bottom: 0;
  }

  .lower-section-heading__en {
    font-size: 16px;
  }

  .lower-section-heading__ja {
    font-size: 24px;
  }
}

/* -------------------------------------------------------------
  lower-content-heading（下層ページ共通：コンテンツ内h3見出し）
------------------------------------------------------------- */
.lower-content-heading {
  margin-bottom: 16px;
  color: #0159A0;
  font-size: 26px;
  font-weight: 500;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .lower-content-heading {
    font-size: 22px;
  }
}


/* -------------------------------------------------------------
  page-top（ページトップへ戻る）
------------------------------------------------------------- */
.page-top {
  position: fixed;
  right: 30px;
  bottom: 30px;
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--color-main);
  color: var(--color-white);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition:
    opacity .3s ease,
    visibility .3s ease,
    transform .3s ease,
    background-color .3s ease,
    color .3s ease;
}

.page-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.page-top:hover {
  background: var(--color-sub2);
  color: var(--color-main);
}

.page-top__arrow {
  width: 10px;
  height: 10px;
  border-top: 2px solid currentColor;
  border-left: 2px solid currentColor;
  transform: translateY(3px) rotate(45deg);
}

@media (max-width: 768px) {
  .page-top {
    right: 15px;
    bottom: 15px;
    width: 42px;
    height: 42px;
  }

  .page-top__arrow {
    width: 9px;
    height: 9px;
  }
}

