/* 設備一覧ページ専用スタイル */

/* ページヒーローセクション */
.page-hero {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.301) 0%, rgba(62, 200, 255, 0) 100%), url('../img/equipments/IMG_2976.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: white;
  padding: 100px 0 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* 背景画像がない場合のフォールバック */
.page-hero.no-image {
  background: linear-gradient(135deg, #a7cf387e 0%, #3aa5089d 100%);
}

.page-title {
  font-size: 3.5em;
  font-weight: 700;
  margin-bottom: 20px;
  position: relative;
  z-index: 2;
  text-shadow: 2px 2px 8px #1462b1cc;
  color: #fff;
}

.page-subtitle {
  font-size: 1.3em;
  opacity: 0.9;
  position: relative;
  z-index: 2;
  max-width: 600px;
  margin: 0 auto;
}

/* 設備セクション */
.equipment-section {
  padding: 60px 0;
  background: #f8f9fa;
}

/* 工場セクション */
.factory-section {
  margin-bottom: 80px;
  position: relative;
}

.factory-section:last-child {
  margin-bottom: 0;
}

.factory-title {
  text-align: center;
  font-size: 2.5em;
  margin-bottom: 40px;
  color: #2c3e50;
  position: relative;
  padding-bottom: 20px;
}

.factory-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 5px;
  background: linear-gradient(90deg, #3498db, #1462b1);
  border-radius: 3px;
}

/* 本社工場と福井工場の区別 */
.factory-section:nth-child(1) .factory-title {
  color: #1462b1;
}

.factory-section:nth-child(1) .factory-title::after {
  background: linear-gradient(90deg, #1462b1, #3498db);
}

.factory-section:nth-child(2) .factory-title {
  color: #e74c3c;
}

.factory-section:nth-child(2) .factory-title::after {
  background: linear-gradient(90deg, #e74c3c, #c0392b);
}

/* 工場セクション間の区切り線 */
.factory-section:not(:last-child)::after {
  content: '';
  position: absolute;
  bottom: -50px;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #bdc3c7, transparent);
}

.section-title {
  text-align: center;
  font-size: 2em;
  margin-bottom: 40px;
  color: #1462b1;
  position: relative;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #3498db, #1462b1);
  border-radius: 2px;
}

/* 設備カテゴリ */
.equipment-category {
  margin-bottom: 80px;
  background: white;
  border-radius: 20px;
  padding: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.equipment-category:hover {
  transform: translateY(-5px);
}

.category-header {
  text-align: center;
  margin-bottom: 40px;
  padding-bottom: 30px;
  border-bottom: 2px solid #f1f3f4;
}

.category-icon {
  font-size: 3em;
  margin-bottom: 20px;
  display: block;
}

.category-title {
  font-size: 2em;
  color: #2c3e50;
  margin-bottom: 10px;
}

.category-description {
  color: #7f8c8d;
  font-size: 1.1em;
}

/* 設備グリッド */
.equipment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
}

/* フィーチャーカードが複数ある場合の調整 */
.equipment-grid:has(.equipment-card.featured:nth-child(2)) {
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

/* 設備カード */
.equipment-card {
  background: white;
  border-radius: 15px;
  padding: 25px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.equipment-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #3498db, #1462b1);
  transform: scaleX(0);
  transition: transform 0.3s ease;
}

.equipment-card:hover::before {
  transform: scaleX(1);
}

.equipment-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
  border-color: #3498db;
}

.equipment-card.featured {
  grid-column: span 1;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border: 2px solid #3498db;
}

.equipment-card.featured::before {
  background: linear-gradient(90deg, #e74c3c, #c0392b);
}

/* 設備画像 */
.equipment-image {
  margin-bottom: 20px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.equipment-image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.equipment-card:hover .equipment-image img {
  transform: scale(1.05);
}

/* 設備情報 */
.equipment-info {
  position: relative;
}

.equipment-name {
  font-size: 1.3em;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 15px;
  line-height: 1.3;
}

.equipment-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.equipment-count {
  background: linear-gradient(135deg, #3498db, #1462b1);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9em;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.equipment-maker {
  background: #ecf0f1;
  color: #2c3e50;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9em;
  font-weight: 500;
  border: 1px solid #bdc3c7;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .page-hero {
    padding: 80px 0 40px;
  }

  .page-title {
    font-size: 2.5em;
  }

  .page-subtitle {
    font-size: 1.1em;
  }

  .equipment-section {
    padding: 60px 0;
  }

  .section-title {
    font-size: 2em;
    margin-bottom: 40px;
  }

  .equipment-category {
    padding: 30px 20px;
    margin-bottom: 60px;
  }

  .category-title {
    font-size: 1.6em;
  }

  .equipment-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .equipment-card.featured {
    grid-column: span 1;
  }

  .equipment-card {
    padding: 20px;
  }

  .equipment-name {
    font-size: 1.2em;
  }

  .equipment-details {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

@media (max-width: 480px) {
  .page-title {
    font-size: 2em;
  }

  .equipment-category {
    padding: 20px 15px;
  }

  .category-icon {
    font-size: 2.5em;
  }

  .category-title {
    font-size: 1.4em;
  }
}

/* アニメーション */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.equipment-card {
  animation: fadeInUp 0.6s ease forwards;
}

.equipment-card:nth-child(1) { animation-delay: 0.1s; }
.equipment-card:nth-child(2) { animation-delay: 0.2s; }
.equipment-card:nth-child(3) { animation-delay: 0.3s; }
.equipment-card:nth-child(4) { animation-delay: 0.4s; }
.equipment-card:nth-child(5) { animation-delay: 0.5s; }
.equipment-card:nth-child(6) { animation-delay: 0.6s; }
.equipment-card:nth-child(7) { animation-delay: 0.7s; }
.equipment-card:nth-child(8) { animation-delay: 0.8s; }

/* タイムライン形式の設備表示（代替案） */
.equipment-timeline {
  position: relative;
  padding: 40px 0;
}

.equipment-timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #3498db, #1462b1);
  transform: translateX(-50%);
  border-radius: 2px;
}

.timeline-item {
  position: relative;
  margin-bottom: 60px;
  width: 45%;
  animation: slideInLeft 0.8s ease-out;
}

.timeline-item:nth-child(even) {
  margin-left: 55%;
  animation: slideInRight 0.8s ease-out;
}

.timeline-item::before {
  content: '';
  position: absolute;
  top: 20px;
  width: 20px;
  height: 20px;
  background: #3498db;
  border: 4px solid #fff;
  border-radius: 50%;
  box-shadow: 0 0 0 4px #3498db;
}

.timeline-item:nth-child(even)::before {
  left: -60px;
}

.timeline-item:nth-child(odd)::before {
  right: -60px;
}

.timeline-card {
  background: white;
  border-radius: 15px;
  padding: 25px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  border-left: 5px solid #3498db;
  transition: all 0.3s ease;
}

.timeline-item:nth-child(even) .timeline-card {
  border-left: none;
  border-right: 5px solid #3498db;
}

.timeline-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.timeline-card.featured {
  border-left-color: #e74c3c;
  background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
}

.timeline-item:nth-child(even) .timeline-card.featured {
  border-left-color: transparent;
  border-right-color: #e74c3c;
}

.timeline-image {
  width: 100%;
  height: 200px;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 15px;
}

.timeline-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.timeline-card:hover .timeline-image img {
  transform: scale(1.05);
}

.timeline-title {
  font-size: 1.3em;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 10px;
}

.timeline-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.timeline-count {
  background: #3498db;
  color: white;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.9em;
  font-weight: 600;
}

.timeline-maker {
  color: #7f8c8d;
  font-size: 0.9em;
  font-weight: 500;
}

.timeline-description {
  color: #555;
  font-size: 0.95em;
  line-height: 1.5;
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .equipment-timeline::before {
    left: 30px;
  }
  
  .timeline-item {
    width: calc(100% - 60px);
    margin-left: 60px !important;
  }
  
  .timeline-item::before {
    left: -45px !important;
    right: auto !important;
  }
  
  .timeline-item .timeline-card {
    border-left: 5px solid #3498db !important;
    border-right: none !important;
  }
}

/* リスト形式の設備表示（代替案） */
.equipment-list {
  background: white;
  border-radius: 15px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.list-header {
  background: linear-gradient(135deg, #3498db, #1462b1);
  color: white;
  padding: 20px 25px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.list-header-icon {
  font-size: 2em;
}

.list-header-content h3 {
  font-size: 1.4em;
  margin-bottom: 5px;
}

.list-header-content p {
  opacity: 0.9;
  font-size: 0.95em;
}

.list-item {
  display: flex;
  align-items: center;
  padding: 20px 25px;
  border-bottom: 1px solid #f1f3f4;
  transition: all 0.3s ease;
  cursor: pointer;
}

.list-item:last-child {
  border-bottom: none;
}

.list-item:hover {
  background: #f8f9fa;
  transform: translateX(5px);
}

.list-item.featured {
  background: linear-gradient(135deg, #fff5f5 0%, #fff 100%);
  border-left: 4px solid #e74c3c;
}

.list-item-image {
  width: 80px;
  height: 80px;
  border-radius: 10px;
  overflow: hidden;
  margin-right: 20px;
  flex-shrink: 0;
}

.list-item-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.list-item-content {
  flex: 1;
}

.list-item-title {
  font-size: 1.1em;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 5px;
}

.list-item-details {
  display: flex;
  gap: 15px;
  align-items: center;
  font-size: 0.9em;
}

.list-item-count {
  background: #3498db;
  color: white;
  padding: 3px 10px;
  border-radius: 15px;
  font-weight: 600;
}

.list-item-maker {
  color: #7f8c8d;
  font-weight: 500;
}

.list-item-specs {
  color: #95a5a6;
  font-size: 0.85em;
}

.list-item-arrow {
  color: #bdc3c7;
  font-size: 1.2em;
  transition: all 0.3s ease;
}

.list-item:hover .list-item-arrow {
  color: #3498db;
  transform: translateX(5px);
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .list-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  
  .list-item-image {
    width: 100%;
    height: 150px;
    margin-right: 0;
  }
  
  .list-item-details {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }
}

/* モザイク形式の設備表示（代替案） */
.equipment-mosaic {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  padding: 20px 0;
}

.mosaic-item {
  position: relative;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
  background: white;
}

.mosaic-item:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.mosaic-item.featured {
  grid-column: span 2;
  grid-row: span 2;
}

.mosaic-image {
  width: 100%;
  height: 200px;
  position: relative;
  overflow: hidden;
}

.mosaic-item.featured .mosaic-image {
  height: 300px;
}

.mosaic-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.mosaic-item:hover .mosaic-image img {
  transform: scale(1.1);
}

.mosaic-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(52, 152, 219, 0.9) 0%, rgba(20, 98, 177, 0.9) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2em;
  font-weight: 600;
}

.mosaic-item:hover .mosaic-overlay {
  opacity: 1;
}

.mosaic-content {
  padding: 20px;
  position: relative;
}

.mosaic-badge {
  position: absolute;
  top: -15px;
  right: 20px;
  background: #e74c3c;
  color: white;
  padding: 5px 15px;
  border-radius: 20px;
  font-size: 0.8em;
  font-weight: 600;
  box-shadow: 0 3px 10px rgba(231, 76, 60, 0.3);
}

.mosaic-title {
  font-size: 1.2em;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 10px;
  line-height: 1.3;
}

.mosaic-item.featured .mosaic-title {
  font-size: 1.5em;
}

.mosaic-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.mosaic-count {
  background: #3498db;
  color: white;
  padding: 4px 12px;
  border-radius: 15px;
  font-size: 0.9em;
  font-weight: 600;
}

.mosaic-maker {
  color: #7f8c8d;
  font-size: 0.9em;
  font-weight: 500;
}

.mosaic-specs {
  color: #95a5a6;
  font-size: 0.85em;
  line-height: 1.4;
}

.mosaic-item.featured .mosaic-specs {
  font-size: 0.95em;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .equipment-mosaic {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .mosaic-item.featured {
    grid-column: span 1;
    grid-row: span 1;
  }
  
  .mosaic-item.featured .mosaic-image {
    height: 200px;
  }
  
  .mosaic-item.featured .mosaic-title {
    font-size: 1.2em;
  }
}

/* モザイク形式のスタイル */
.mosaic-section {
  margin-bottom: 80px;
}

.mosaic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 30px;
  margin-bottom: 60px;
}

.mosaic-item {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  position: relative;
}

.mosaic-item:hover {
  transform: translateY(-8px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.mosaic-image {
  width: 100%;
  height: 250px;
  overflow: hidden;
  position: relative;
}

.mosaic-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.mosaic-item:hover .mosaic-image img {
  transform: scale(1.05);
}

.mosaic-info {
  padding: 25px;
}

.mosaic-name {
  font-size: 1.4em;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 15px;
  line-height: 1.3;
}

.mosaic-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.mosaic-count {
  background: linear-gradient(135deg, #3498db, #1462b1);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9em;
  font-weight: 500;
}

.mosaic-maker {
  color: #7f8c8d;
  font-size: 0.95em;
  font-weight: 500;
}

.mosaic-category {
  color: #95a5a6;
  font-size: 0.85em;
  font-weight: 400;
  border-top: 1px solid #ecf0f1;
  padding-top: 12px;
}

/* 表形式のスタイル */
.table-section {
  margin-bottom: 80px;
  background: white;
  border-radius: 15px;
  padding: 40px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.equipment-table-container {
  overflow-x: auto;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.equipment-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  font-size: 0.95em;
  border: 2px solid #1462b1;
}

.equipment-table th {
  background: linear-gradient(135deg, #1462b1, #3498db);
  color: white;
  padding: 15px 12px;
  text-align: center;
  font-weight: 600;
  font-size: 1em;
  border: 2px solid #1462b1;
}

.equipment-table th:first-child {
  border-top-left-radius: 8px;
}

.equipment-table th:last-child {
  border-top-right-radius: 8px;
}

/* すべての表セルを強制的に統一 */
.equipment-table td,
.equipment-table td[rowspan],
.equipment-table td:first-child,
.equipment-table td:nth-child(2),
.equipment-table td:nth-child(3),
.equipment-table td:last-child {
  padding: 12px;
  border: 2px solid #1462b1;
  vertical-align: middle;
  text-align: center;
  font-weight: normal !important;
  color: #2c3e50 !important;
}

.equipment-table tr:hover {
  background-color: #f8f9fa;
}

.equipment-table tr:last-child td {
  border-bottom: 2px solid #1462b1;
}

/* カテゴリ列の背景色のみ変更 */
.equipment-table td:first-child,
.equipment-table td[rowspan] {
  background-color: #f8f9fa;
  border-right: 2px solid #1462b1;
}

/* すべてのセル内のテキストを強制的に統一 */
.equipment-table td *,
.equipment-table td[rowspan] * {
  font-weight: normal !important;
  color: #2c3e50 !important;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
  .mosaic-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .mosaic-image {
    height: 200px;
  }
  
  .mosaic-info {
    padding: 20px;
  }
  
  .mosaic-name {
    font-size: 1.2em;
  }
  
  .table-section {
    padding: 20px;
  }
  
  .equipment-table {
    font-size: 0.85em;
  }
  
  .equipment-table th,
  .equipment-table td {
    padding: 8px 6px;
  }
}

@media (max-width: 480px) {
  .mosaic-grid {
    gap: 15px;
  }
  
  .mosaic-image {
    height: 180px;
  }
  
  .mosaic-info {
    padding: 15px;
  }
  
  .mosaic-name {
    font-size: 1.1em;
  }
  
  .mosaic-details {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  .table-section {
    padding: 15px;
  }
  
  .equipment-table {
    font-size: 0.8em;
  }
  
  .equipment-table th,
  .equipment-table td {
    padding: 6px 4px;
  }
}

