:root {
  --brand: #1368ce;
  --text-main: #222;
  --text-sub: #555;
  --bg-light: #f5f6fa;
  --border-soft: #e0e4ef;
}

/* ========== ベース ========== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Noto Sans JP", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: #fff;
  color: var(--text-main);
  line-height: 1.6;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

/* 共通コンテナ */
.container {
  width: min(1120px, 92%);
  margin: 0 auto;
}

/* ========== ヘッダー ========== */
header {
  background: #fff;
  border-bottom: 1px solid #ddd;
  position: sticky;
  top: 0;
  z-index: 100;
}

.container.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
}

/* ロゴ */
.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #000;
}

.brand-logo img {
  height: 40px;
}

/* PCメニュー */
.menu {
  display: flex;
  align-items: center;
  gap: 16px;
}

.menu a {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  font-size: 0.95rem;
  padding: 6px 0;
  position: relative;
}

.menu a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -3px;
  width: 0;
  height: 2px;
  background: var(--brand);
  transition: width 0.25s ease;
}

.menu a:hover::after {
  width: 100%;
}

/* ハンバーガー（スマホ） */
.menu-toggle {
  display: none;            /* PC では非表示 */
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  background: #333;
  border-radius: 2px;
}

/* スマホメニュー */
.menu-mobile {
  display: none;
  flex-direction: column;
  background: #fff;
  border-bottom: 1px solid #ddd;
  box-shadow: 0 3px 10px rgba(0,0,0,0.06);
}

.menu-mobile a {
  padding: 12px 5%;
  text-decoration: none;
  color: #333;
  font-weight: 500;
  border-top: 1px solid #f0f0f0;
}

.menu-mobile a:hover {
  background: #eef5ff;
  color: var(--brand);
}

.menu-mobile.open {
  display: flex;
}

/* ========== HERO スライダー ========== */
.hero {
  background: #101623;
  padding: 20px 0 40px;
}

.hero-inner {
  padding-top: 10px;
  padding-bottom: 10px;
}

.hero-slider {
  position: relative;
  width: 100%;
  height: min(70vh, 520px);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0,0,0,0.24);
}

/* スライド画像 */
.slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slide.active {
  opacity: 1;
}

/* キャプション */
.hero-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.hero-caption h1 {
  margin: 0;
  text-align: center;
  color: #fff;
  font-size: 1.4rem;
  line-height: 1.6;
  letter-spacing: 0.12em;
  text-shadow: 0 4px 12px rgba(0,0,0,0.8);
  font-family: "Times New Roman", "Noto Serif JP", serif;
}

/* ========== セクション共通 ========== */
.section {
  padding: 40px 0 50px;
}

.section-title {
  font-size: 1.6rem;
  border-left: 4px solid var(--brand);
  padding-left: 10px;
  margin: 10px 0 24px;
}

/* グリッド・カード */
.grid {
  display: grid;
  gap: 20px;
}

.cols-3 {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.card {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.card h3 {
  margin-top: 0;
  margin-bottom: 8px;
}

.card .meta {
  font-size: 0.95rem;
  color: var(--text-sub);
}

/* ========== 下部リンクカード ========== */
.link-section {
  background: var(--bg-light);
  padding: 40px 0 50px;
}

.link-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.link-card {
  display: block;
  text-align: center;
  padding: 22px 12px;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border-soft);
  text-decoration: none;
  color: var(--text-main);
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease,
              background 0.2s ease, color 0.2s ease;
}

.link-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.12);
  background: #eef5ff;
  color: var(--brand);
}

/* ========== フッター & トップへ戻る ========== */
footer {
  background: #f8f8f8;
  text-align: center;
  padding: 18px 0;
  font-size: 0.9rem;
  color: #666;
}

#toTop {
  position: fixed;
  right: 18px;
  bottom: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--brand);
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  display: none;
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
}

#toTop.show {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ========== 下層ページ共通 ========== */

/* ページタイトル帯 */
.page-hero {
  width: 100%;
  padding: 60px 0 40px;
  text-align: center;
  background: var(--bg-light);
}

.page-hero h1 {
  font-size: 2rem;
  font-weight: 700;
  margin: 0;
}

/* コンテンツ共通余白 */
.page-content {
  padding: 40px 0 70px;
}

/* 会社概要テーブル */
.company-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0 40px;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.company-table th,
.company-table td {
  border-bottom: 1px solid #eee;
  padding: 16px;
  font-size: 0.98rem;
}

.company-table th {
  width: 30%;
  background: #f3f5fc;
  font-weight: 600;
}

.company-table tr:last-child th,
.company-table tr:last-child td {
  border-bottom: none;
}

/* 企業理念ボックス */
.philosophy-box {
  background: #eef5ff;
  padding: 25px 20px;
  border-left: 5px solid var(--brand);
  font-size: 1.05rem;
  line-height: 1.8;
  border-radius: 8px;
  margin-bottom: 40px;
}

/* 沿革 */
.history {
  list-style: none;
  padding: 0;
  margin: 0 0 50px;
}

.history li {
  padding: 12px 0;
  border-bottom: 1px solid #eee;
  font-size: 0.98rem;
}

.history span {
  font-weight: 700;
  margin-right: 12px;
  color: var(--brand);
}

.history li:last-child {
  border-bottom: none;
}

/* ========== ご挨拶ページ ========== */
.greeting-wrapper {
  display: flex;
  gap: 40px;
  align-items: flex-start;
  margin-bottom: 50px;
  flex-wrap: wrap;
}

.greeting-photo {
  flex: 0 0 260px;
  text-align: center;
}

.greeting-photo img {
  width: 260px;
  border-radius: 8px;
  object-fit: cover;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.greeting-message {
  flex: 1;
  font-size: 1.02rem;
  line-height: 1.9;
  color: var(--text-sub);
}

.greeting-sign {
  margin-top: 20px;
  font-weight: 700;
  text-align: right;
  line-height: 1.6;
}

/* ========== 設備ページ ========== */
.equipment-description {
  margin: 0 0 40px;
  font-size: 1.02rem;
  line-height: 1.9;
  color: var(--text-sub);
}

.equipment-gallery {
  display: grid;
  gap: 32px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  margin-bottom: 70px;
}

.equip-item {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  padding: 20px;
  text-align: center;
}

.equip-item img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 15px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.equip-item h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
}

.equip-item p {
  font-size: 0.95rem;
  color: var(--text-sub);
  line-height: 1.7;
}

/* ========== 取扱い鋼材ページ ========== */
.materials-description {
  margin: 0 0 40px;
  font-size: 1.02rem;
  color: var(--text-sub);
  line-height: 1.9;
}

.materials-gallery {
  display: grid;
  gap: 32px;
  margin-bottom: 70px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.material-item {
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  text-align: center;
}

.material-item img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 15px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.material-item h3 {
  margin-bottom: 10px;
  font-size: 1.15rem;
}

.material-item p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-sub);
}

/* ========== 取扱い製品ページ ========== */
.products-description {
  margin: 0 0 40px;
  font-size: 1.02rem;
  color: var(--text-sub);
  line-height: 1.9;
}

.products-gallery {
  display: grid;
  gap: 32px;
  margin-bottom: 70px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.product-item {
  background: #fff;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  text-align: center;
}

.product-item img {
  width: 100%;
  border-radius: 10px;
  margin-bottom: 15px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.product-item h3 {
  margin-bottom: 12px;
  font-size: 1.15rem;
}

.product-item p {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-sub);
}

/* ========== 採用情報ページ ========== */
.recruit-lead {
  margin: 0 0 40px;
  font-size: 1.02rem;
  line-height: 1.9;
  color: var(--text-sub);
}

.recruit-feature {
  margin-bottom: 60px;
}

.recruit-box {
  display: flex;
  gap: 30px;
  margin-bottom: 50px;
  align-items: center;
}

.recruit-box.reverse {
  flex-direction: row-reverse;
}

.recruit-box img {
  width: 45%;
  border-radius: 10px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.recruit-box .text {
  width: 55%;
}

.recruit-box h3 {
  margin-bottom: 12px;
  font-size: 1.25rem;
}

.recruit-box p {
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text-sub);
}

/* 募集要項テーブル */
.recruit-table table {
  width: 100%;
  margin: 0 0 80px;
  border-collapse: collapse;
  background: #fff;
  box-shadow: 0 3px 10px rgba(0,0,0,0.08);
  border-radius: 10px;
  overflow: hidden;
}

.recruit-table th,
.recruit-table td {
  padding: 16px 18px;
  border-bottom: 1px solid #eee;
  font-size: 0.98rem;
}

.recruit-table th {
  width: 26%;
  background: #f4f6fb;
  font-weight: 700;
  color: #333;
}

.recruit-table tr:last-child td,
.recruit-table tr:last-child th {
  border-bottom: none;
}

/* ========== NEWS一覧ページ ========== */
.news-list {
  margin: 40px 0 70px;
  display: grid;
  gap: 26px;
}

.news-item {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 18px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.news-item img {
  width: 180px;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
}

.news-item .date {
  font-size: 0.9rem;
  color: #777;
  margin-bottom: 4px;
}

.news-item h3 {
  margin: 5px 0;
  font-size: 1.15rem;
}

.news-item h3 a {
  text-decoration: none;
  color: var(--brand);
}

.news-item .desc {
  font-size: 0.95rem;
  color: var(--text-sub);
  line-height: 1.6;
}

/* ========== レスポンシブ調整 ========== */
@media (max-width: 900px) {
  .hero-slider {
    height: 60vh;
  }

  .hero-caption h1 {
    font-size: 1.15rem;
    letter-spacing: 0.08em;
  }
}

@media (max-width: 768px) {
  .container.nav {
    padding-inline: 5%;
  }

  .menu {
    display: none;          /* PCメニュー非表示 */
  }

  .menu-toggle {
    display: flex;          /* ハンバーガー表示 */
  }

  .hero {
    padding-top: 10px;
  }

  .hero-slider {
    height: 55vh;
  }

  .hero-caption h1 {
    font-size: 1.05rem;
  }

  .greeting-wrapper {
    flex-direction: column;
  }

  .greeting-photo {
    margin: 0 auto 10px;
  }

  .recruit-box,
  .recruit-box.reverse {
    flex-direction: column;
  }

  .recruit-box img,
  .recruit-box .text {
    width: 100%;
  }

  .news-item {
    flex-direction: column;
  }

  .news-item img {
    width: 100%;
    height: auto;
  }
}
.products-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 40px;
}

.product-item {
  text-align: center;
}

.product-item img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.product-item h3 {
  margin-top: 10px;
  font-size: 1rem;
  font-weight: 600;
}
/* =========================
   画像拡大モーダル
========================= */
.image-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 9999;
  justify-content: center;
  align-items: center;
}

.image-modal.active {
  display: flex;
}

.image-modal img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

/* × ボタン */
.image-modal-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 40px;
  color: #fff;
  cursor: pointer;
  line-height: 1;
}

/* クリックできることを分かりやすく */
.product-item img {
  cursor: zoom-in;
}
/* =========================
   画像拡大モーダル
========================= */
.image-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;

  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

.image-modal.active {
  opacity: 1;
  visibility: visible;
}

/* フェードイン用 */
.image-modal-content {
  text-align: center;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    transform: scale(0.95);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.image-modal img {
  max-width: 90vw;
  max-height: 80vh;
  object-fit: contain;
}

/* 製品名 */
#modal-title {
  margin-top: 12px;
  color: #fff;
  font-size: 1.1rem;
  letter-spacing: 0.05em;
}

/* × ボタン（白丸） */
.image-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;

  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;

  background: #fff;
  color: #000;
  font-size: 26px;
  font-weight: bold;
  cursor: pointer;

  display: flex;
  align-items: center;
  justify-content: center;
}

/* hover */
.image-modal-close:hover {
  background: #f0f0f0;
}

/* 画像がクリック可能と分かるように */
.product-item img {
  cursor: zoom-in;
}
/* ハンバーガーボタン */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: #000;
}

/* スマホ表示 */
@media (max-width: 768px) {
  .menu {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .menu-mobile {
    display: none;
    flex-direction: column;
    background: #fff;
  }

  .menu-mobile.open {
    display: flex;
  }
}
.equipment-highlight {
  text-align: center;
  margin-bottom: 40px;
}

.equipment-highlight img {
  max-width: 100%;
  height: auto;
}

.equipment-highlight h3 {
  margin-top: 12px;
}
