/**
 * Layout CSS - レイアウト修正と調整
 * 全体的なレイアウトの問題を解決
 */

/* ====================================
   ページヘッダー（下層ページ）
==================================== */
.page-header {
  position: relative;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 80px 0 60px;
  margin: 0;
  text-align: center;
  color: white;
  overflow: hidden;
}

.page-header h1 {
  color: white;
  margin-bottom: 20px;
}

.page-header .breadcrumb {
  color: rgba(255, 255, 255, 0.9);
}

/* ====================================
   パンくずリスト
==================================== */
.breadcrumb {
  padding: 15px 0;
  background: rgba(255, 255, 255, 0.1);
  margin-bottom: 0;
}

.breadcrumb ul {
  display: flex;
  align-items: center;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.breadcrumb li {
  display: flex;
  align-items: center;
  gap: 10px;
}

.breadcrumb li::after {
  content: '›';
  margin-left: 10px;
  opacity: 0.7;
}

.breadcrumb li:last-child::after {
  display: none;
}

.breadcrumb a {
  color: rgba(255, 255, 255, 0.9);
  transition: color 0.3s;
  text-decoration: none;
}

.breadcrumb a:hover {
  color: white;
}

/* ====================================
   セクション間隔調整
==================================== */
.about-intro,
.philosophy-section,
.company-info,
.history-section,
.access-section,
.services-intro,
.service-detail,
.pricing-section,
.process-section,
.case-study-section,
.contact-section,
.works-archive,
.work-detail,
.recruit-message,
.company-culture,
.job-positions,
.benefits,
.selection-process,
.apply-section,
.news-archive {
  padding: 60px 0;
}

/* ====================================
   CTAセクション
==================================== */
.cta-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 80px 0;
  text-align: center;
  color: white;
  margin-top: 80px;
}

.cta-content h2 {
  font-size: 32px;
  margin-bottom: 20px;
  color: white;
}

.cta-content p {
  font-size: 18px;
  margin-bottom: 30px;
  opacity: 0.95;
}

.cta-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ====================================
   カード要素共通
==================================== */
.work-item,
.job-card,
.news-item,
.feature-card,
.area-item,
.case-item {
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.3s;
}

.work-item:hover,
.job-card:hover,
.news-item:hover,
.feature-card:hover,
.area-item:hover,
.case-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ====================================
   グリッドレイアウト共通
==================================== */
.works-grid,
.culture-grid,
.benefits-grid {
  display: grid;
  gap: 30px;
  margin-top: 40px;
}

.works-grid {
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.culture-grid,
.benefits-grid {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* ====================================
   スムーススクロール時のオフセット
==================================== */
:target::before {
  content: "";
  display: block;
  height: 90px;
  margin-top: -90px;
}

/* ====================================
   サービスページ特有の調整
==================================== */
.service-title {
  margin-bottom: 20px !important;
  line-height: 1.2 !important;
}

.service-tagline {
  margin-bottom: 20px !important;
  line-height: 1.5 !important;
}

.service-icon {
  margin-bottom: 20px !important;
}

.service-header {
  margin-bottom: 60px !important;
}

/* OnePriceWeb価格セクション調整 */
.oneprice-amount {
  margin-bottom: 12px !important;
  line-height: 1.4 !important;
}

.price-number {
  line-height: 1.1 !important;
}

.price-note {
  margin-top: 8px !important;
  line-height: 1.4 !important;
}

/* ====================================
   WordPress固有
==================================== */
.wp-block-image img {
  height: auto;
}

.aligncenter {
  text-align: center;
  margin: 32px auto;
}

.alignleft {
  float: left;
  margin-right: 24px;
  margin-bottom: 16px;
}

.alignright {
  float: right;
  margin-left: 24px;
  margin-bottom: 16px;
}

/* ====================================
   モバイル対応
==================================== */
@media (max-width: 768px) {
  .page-header {
    padding: 60px 0 40px;
  }
  
  .section,
  .about-intro,
  .philosophy-section,
  .company-info,
  .services-intro,
  .contact-section,
  .works-archive,
  .recruit-message,
  .news-archive {
    padding: 40px 0;
  }
  
  .cta-section {
    margin-top: 60px;
    padding: 60px 0;
  }
  
  .works-grid,
  .culture-grid,
  .benefits-grid {
    grid-template-columns: 1fr;
  }
  
  /* サービスページモバイル対応 */
  .service-title {
    font-size: 28px !important;
    margin-bottom: 16px !important;
    line-height: 1.3 !important;
  }
  
  .service-tagline {
    font-size: 16px !important;
    margin-bottom: 24px !important;
    line-height: 1.6 !important;
  }
  
  .service-icon {
    font-size: 48px !important;
    margin-bottom: 16px !important;
  }
  
  .service-header {
    margin-bottom: 40px !important;
  }
  
  .oneprice-amount {
    font-size: 20px !important;
    margin-bottom: 12px !important;
  }
  
  .price-number {
    font-size: 48px !important;
  }
  
  .oneprice-highlight {
    padding: 40px 20px !important;
    margin-bottom: 40px !important;
  }
}

@media (max-width: 480px) {
  .header-container {
    padding: 0 15px;
  }
  
  .page-header {
    padding: 40px 0 30px;
  }
  
  .cta-buttons {
    flex-direction: column;
    align-items: center;
  }
  
  .cta-buttons .btn {
    width: 100%;
    max-width: 300px;
  }
}