/* ========================================
  共通（スマホ・PC 共通）
======================================== */

/* カテゴリ タイトル */
.p-category__ttl {
  margin: 5px 10px 30px;
  font-size: 18px;
}

/* カテゴリ フリーテキスト */
.p-category-free {
  margin: 0 10px 40px;
  line-height: 2;
}
.p-category-free h2 {
  margin-top: 0;
  font-size: 18px;
}

/* カテゴリ一覧 */
.p-category-list {
  box-sizing: border-box;
  display: flex;
  flex-wrap: wrap;
  margin-top: 20px;
  margin-bottom: 20px;
}

.p-category-list__item {
  box-sizing: border-box;
  font-size: 12px;
}

.p-category-list__link {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin: 0 10px 0 0;
  text-decoration: none;
}

.p-category-list__img {
  margin-right: 10px;
  margin-bottom: 0;
}

.p-category-list__img img {
  object-fit: cover;
  border-radius: 50%;
  image-rendering: auto;
}

.p-category-list__name {
  overflow: hidden;
  text-overflow: ellipsis;
}

.p-category-list__link:hover,
.p-category-list__name:hover {
  text-decoration: none;
}


/* ========================================
  スマホ（max-width: 648px）
======================================== */
@media (max-width: 648px) {
  .p-category-list {
    justify-content: space-between;
    margin-left: 0;
    margin-right: 0;
    padding: 0;
  }

  .p-category-list__item {
    width: calc(50% - 5px);
    margin-bottom: 15px;
    padding-left: 0;
    padding-right: 0;
    text-align: left;
  }

  .p-category-list__link::before {
    content: "";
    position: absolute;
    top: 50%;
    right: 5px;
    margin-top: -6px;
    width: 8px;
    height: 8px;
    border-right: 1px solid #aaaaaa;
    border-bottom: 1px solid #aaaaaa;
    transform: rotate(-45deg);
    transition: all 0.3s cubic-bezier(.25,.46,.45,.94);
  }

  .p-category-list__img {
    width: 55px;
  }
  .p-category-list__img img {
    width: 50px;
    height: 50px;
  }

  .p-category-list__name {
    flex: 1;
    padding-right: 0;
  }
}


/* ========================================
  PC（min-width: 649px）
======================================== */
@media (min-width: 649px) {
  .p-category-list__item {
    width: 33.3%;
    margin-bottom: 60px;
    padding-left: 15px;
    padding-right: 15px;
  }

  .p-category-list__img {
    width: 75px;
  }
  .p-category-list__img img {
    width: 70px;
    height: 70px;
  }

  .p-category-list__name {
    width: 105px;
    padding-right: 20px;
  }
}


/* ========================================
  Shop Header（不足クラスの復元・モバイル優先）
======================================== */
.shop-header__container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 24px 10px;
}

.shop-header__image {
  margin: 0;
  overflow: hidden;
  border-radius: 8px;
  background: #f5f5f5;
}

.shop-header__image img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  aspect-ratio: 16 / 9; /* スマホは横長で安定 */
}

.shop-header__content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.shop-header__description {
  margin: 0;
  color: #333;
  line-height: 1.8;
  font-size: 14px;
}

.shop-header__link {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 4px;
  background: #222;
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  transition: background-color .2s ease, opacity .2s ease;
}

.shop-header__link:hover {
  background: #000;
  opacity: .9;
}

.shop-header__link:focus-visible {
  outline: 2px solid #000;
  outline-offset: 2px;
}

/* ========================================
  PC（min-width: 649px）
======================================== */
@media (min-width: 649px) {
  .shop-header__container {
    display: grid;
    grid-template-columns: 1fr 1.2fr; /* 画像：テキスト */
    align-items: center;
    gap: 24px;
    margin: 32px 10px;
  }

  .shop-header__image img {
    aspect-ratio: 4 / 3; /* PCはやや縦長で安定 */
  }

  .shop-header__description {
    font-size: 16px;
  }
}

/* 大きめ画面の読みやすさ調整 */
@media (min-width: 1200px) {
  .shop-header__content {
    max-width: 60ch;
  }
}