/* ==========================================================================
   LP Top Page Styles - 特集トップページ
   ========================================================================== */

/* Variables (共通変数を継承) */
:root {
  --lp-top-primary: #00a5bf;
  --lp-top-secondary: #ff6b35;
  --lp-top-text: #333;
  --lp-top-text-light: #666;
  --lp-top-bg: #f5f7fa;
  --lp-top-white: #fff;
  --lp-top-border: #e0e0e0;
  --lp-top-shadow: 0 2px 10px rgba(0,0,0,0.1);
  --lp-top-radius: 8px;
}

/* ==========================================================================
   Layout
   ========================================================================== */
body.page-template-page-lp-top {
  width: 100% !important;
  max-width: 100% !important;
}

.lp-top-page {
  max-width: 1200px !important;
  width: 100% !important;
  margin: 0 auto;
  padding: 0 16px 60px;
}

.lp-top-page * {
  box-sizing: border-box;
}

/* ==========================================================================
   Breadcrumb - パンくずリスト
   ========================================================================== */
.lp-top-breadcrumb {
  margin-bottom: 20px;
}

.lp-top-breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 13px;
}

.lp-top-breadcrumb__item {
  display: flex;
  align-items: center;
  color: var(--lp-top-text-light);
}

.lp-top-breadcrumb__item:not(:last-child)::after {
  content: ">";
  margin: 0 10px;
  color: var(--lp-top-text-light);
}

.lp-top-breadcrumb__item a {
  color: var(--lp-top-text-light);
  text-decoration: none;
  transition: color 0.3s;
}

.lp-top-breadcrumb__item a:hover {
  color: var(--lp-top-primary);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.lp-top-hero {
  margin-bottom: 40px;
  text-align: center;
}

.lp-top-hero__visual {
  margin-bottom: 25px;
}

.lp-top-hero__visual img {
  max-width: 100%;
  height: auto;
  border-radius: var(--lp-top-radius);
  box-shadow: var(--lp-top-shadow);
}

.lp-top-hero__title {
  font-size: 28px;
  font-weight: 800;
  color: var(--lp-top-text);
  margin: 0 0 15px;
  line-height: 1.4;
}

.lp-top-hero__lead {
  font-size: 16px;
  color: var(--lp-top-text-light);
  line-height: 1.8;
  margin: 0;
}

/* ==========================================================================
   Section
   ========================================================================== */
.lp-top-section {
  margin-bottom: 50px;
}

.lp-top-section__header {
  margin-bottom: 25px;
}

.lp-top-section__title {
  font-size: 22px;
  font-weight: 700;
  color: var(--lp-top-text);
  margin: 0;
  padding-left: 15px;
  border-left: 4px solid var(--lp-top-primary);
}

/* ==========================================================================
   Category Cards - カテゴリカード（画像付き + リンク一覧）
   ========================================================================== */
.lp-top-categories-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
}

.lp-top-categories-right {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.lp-top-category-card {
  background: var(--lp-top-white);
  border-radius: var(--lp-top-radius);
  box-shadow: var(--lp-top-shadow);
  overflow: hidden;
}

/* 大きいカード（エリア用） */
.lp-top-category-card--large .lp-top-category-card__header {
  display: flex;
  gap: 20px;
  padding: 20px;
  background: linear-gradient(135deg, var(--category-color), color-mix(in srgb, var(--category-color) 80%, #000));
  color: var(--lp-top-white);
}

.lp-top-category-card--large .lp-top-category-card__image {
  width: 200px;
  height: 130px;
  flex-shrink: 0;
  border-radius: 6px;
  overflow: hidden;
}

.lp-top-category-card--large .lp-top-category-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lp-top-category-card--large .lp-top-category-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.2);
  font-size: 40px;
}

.lp-top-category-card--large .lp-top-category-card__title-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.lp-top-category-card--large .lp-top-category-card__title {
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--lp-top-white);
}

.lp-top-category-card--large .lp-top-category-card__title i {
  font-size: 22px;
}

.lp-top-category-card--large .lp-top-category-card__desc {
  font-size: 14px;
  margin: 0;
  opacity: 0.9;
}

/* 小さいカード（世帯・プラン用） */
.lp-top-category-card--small {
  flex: 1;
}

.lp-top-category-card--small .lp-top-category-card__header--horizontal {
  display: flex;
  gap: 15px;
  padding: 15px;
  background: linear-gradient(135deg, var(--category-color), color-mix(in srgb, var(--category-color) 80%, #000));
  color: var(--lp-top-white);
}

.lp-top-category-card--small .lp-top-category-card__image {
  width: 100px;
  height: 70px;
  flex-shrink: 0;
  border-radius: 6px;
  overflow: hidden;
}

.lp-top-category-card--small .lp-top-category-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lp-top-category-card--small .lp-top-category-card__placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.2);
  font-size: 28px;
}

.lp-top-category-card--small .lp-top-category-card__title-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.lp-top-category-card--small .lp-top-category-card__title {
  font-size: 16px;
  font-weight: 700;
  margin: 0 0 5px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--lp-top-white);
}

.lp-top-category-card--small .lp-top-category-card__title i {
  font-size: 16px;
}

.lp-top-category-card--small .lp-top-category-card__desc {
  font-size: 12px;
  margin: 0;
  opacity: 0.9;
}

/* リンク一覧 */
.lp-top-category-card__links {
  padding: 20px;
}

.lp-top-category-card__links--simple {
  padding: 15px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* エリアグループ */
.lp-top-area-group {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  padding: 10px 0;
  border-bottom: 1px solid var(--lp-top-border);
}

.lp-top-area-group:last-child {
  border-bottom: none;
}

.lp-top-area-group__name {
  flex-shrink: 0;
  width: 70px;
  font-size: 13px;
  font-weight: 600;
  color: var(--category-color);
}

.lp-top-area-group__links {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 10px;
}

.lp-top-area-link {
  font-size: 14px;
  color: var(--lp-top-text);
  text-decoration: none;
  transition: color 0.3s;
}

.lp-top-area-link:hover {
  color: var(--category-color);
  text-decoration: underline;
}

.lp-top-area-link--disabled {
  font-size: 13px;
  color: #aaa;
}

/* シンプルリンク（世帯・プラン用） */
.lp-top-simple-link {
  display: inline-block;
  padding: 6px 12px;
  font-size: 13px;
  color: var(--lp-top-text);
  background: var(--lp-top-bg);
  border-radius: 20px;
  text-decoration: none;
  transition: all 0.3s;
}

.lp-top-simple-link:hover {
  background: var(--category-color);
  color: var(--lp-top-white);
}

.lp-top-simple-link--disabled {
  display: inline-block;
  padding: 6px 12px;
  font-size: 13px;
  color: #aaa;
  background: var(--lp-top-bg);
  border-radius: 20px;
}

/* ==========================================================================
   Recent Posts - おすすめ記事
   ========================================================================== */
.lp-top-recent-posts__list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.lp-top-recent-posts__item {
  display: block;
  background: var(--lp-top-white);
  border-radius: var(--lp-top-radius);
  box-shadow: var(--lp-top-shadow);
  overflow: hidden;
  text-decoration: none;
  color: var(--lp-top-text);
  transition: transform 0.3s, box-shadow 0.3s;
}

.lp-top-recent-posts__item:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.lp-top-recent-posts__thumb {
  aspect-ratio: 16/9;
  overflow: hidden;
}

.lp-top-recent-posts__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.lp-top-recent-posts__item:hover .lp-top-recent-posts__thumb img {
  transform: scale(1.05);
}

.lp-top-recent-posts__content {
  padding: 15px;
}

.lp-top-recent-posts__label {
  display: inline-block;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--lp-top-white);
  border-radius: 3px;
  margin-bottom: 8px;
}

.lp-top-recent-posts__title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lp-top-recent-posts__meta {
  display: flex;
  align-items: center;
}

.lp-top-recent-posts__date {
  font-size: 12px;
  color: var(--lp-top-text-light);
}

.lp-top-recent-posts__date i {
  margin-right: 5px;
}

.lp-top-recent-posts__empty {
  text-align: center;
  color: var(--lp-top-text-light);
  padding: 40px;
}

/* ==========================================================================
   Latest Posts - 最近の記事（ラベル付き）
   ========================================================================== */
.lp-top-latest-posts__list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.lp-top-latest-posts__item {
  display: block;
  background: var(--lp-top-white);
  border-radius: var(--lp-top-radius);
  box-shadow: var(--lp-top-shadow);
  overflow: hidden;
  text-decoration: none;
  color: var(--lp-top-text);
  transition: transform 0.3s, box-shadow 0.3s;
}

.lp-top-latest-posts__item:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.lp-top-latest-posts__thumb {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
}

.lp-top-latest-posts__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.lp-top-latest-posts__item:hover .lp-top-latest-posts__thumb img {
  transform: scale(1.05);
}

.lp-top-latest-posts__content {
  padding: 15px;
}

.lp-top-latest-posts__label {
  display: inline-block;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--lp-top-white);
  border-radius: 3px;
  margin-bottom: 8px;
}

.lp-top-latest-posts__title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lp-top-latest-posts__meta {
  display: flex;
  align-items: center;
}

.lp-top-latest-posts__date {
  font-size: 12px;
  color: var(--lp-top-text-light);
}

.lp-top-latest-posts__date i {
  margin-right: 5px;
}

.lp-top-latest-posts__empty {
  text-align: center;
  color: var(--lp-top-text-light);
  padding: 40px;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .lp-top-categories-grid {
    grid-template-columns: 1fr;
  }

  .lp-top-categories-right {
    flex-direction: row;
  }

  .lp-top-category-card--small {
    flex: 1;
  }

  .lp-top-recent-posts__list,
  .lp-top-latest-posts__list {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .lp-top-hero__title {
    font-size: 22px;
  }

  .lp-top-hero__lead {
    font-size: 14px;
  }

  .lp-top-section__title {
    font-size: 18px;
  }

  .lp-top-categories-right {
    flex-direction: column;
  }

  .lp-top-category-card--large .lp-top-category-card__header {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .lp-top-category-card--large .lp-top-category-card__image {
    width: 100%;
    height: 150px;
  }

  .lp-top-category-card--large .lp-top-category-card__title {
    justify-content: center;
  }

  .lp-top-area-group {
    flex-direction: column;
    gap: 8px;
  }

  .lp-top-area-group__name {
    width: auto;
  }

  .lp-top-recent-posts__list,
  .lp-top-latest-posts__list {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
  }

  .lp-top-recent-posts__title,
  .lp-top-latest-posts__title {
    font-size: 13px;
  }

  .lp-top-recent-posts__content,
  .lp-top-latest-posts__content {
    padding: 12px;
  }
}

@media (max-width: 480px) {
  .lp-top-page {
    padding: 0 12px 40px;
  }

  .lp-top-hero__title {
    font-size: 20px;
  }

  .lp-top-category-card--small .lp-top-category-card__header--horizontal {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .lp-top-category-card--small .lp-top-category-card__image {
    width: 100%;
    height: 100px;
  }

  .lp-top-category-card--small .lp-top-category-card__title {
    justify-content: center;
  }

  .lp-top-category-card__links--simple {
    justify-content: center;
  }

  .lp-top-recent-posts__list,
  .lp-top-latest-posts__list {
    grid-template-columns: 1fr;
  }
}
