/* ===================================
   Reset & Base
   =================================== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: "Noto Sans JP", sans-serif;
  font-weight: 400;
  line-height: 1.8;
  color: #333;
  background-color: #fff;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
}

/* ===================================
   Utility
   =================================== */
.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 80px 0;
}

.section--gray {
  background-color: #f5f5f5;
}

.section--dark {
  background-color: #1a2744;
}

.section__title {
  font-size: 1.625rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 40px;
  color: #1a2744;
}

.section__title--white {
  color: #fff;
}

/* Placeholder images */
.placeholder-img {
  background-color: #d0d0d0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #888;
  font-size: 0.875rem;
}

.placeholder-img::after {
  content: attr(data-label);
}

.placeholder-icon {
  background-color: #e0e0e0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #888;
  font-size: 0.75rem;
}

.placeholder-icon::after {
  content: attr(data-label);
}

/* Buttons */
.btn {
  display: inline-block;
  font-family: inherit;
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: opacity 0.3s;
}

.btn:hover {
  opacity: 0.8;
}

.btn--primary {
  background-color: #1a2744;
  color: #fff;
  padding: 12px 32px;
}

.btn--accent {
  background-color: #e8a735;
  color: #fff;
  padding: 16px 48px;
  font-size: 1.125rem;
  border-radius: 6px;
}

.btn--outline {
  background-color: transparent;
  color: #1a2744;
  border: 2px solid #1a2744;
  padding: 12px 40px;
}

/* ===================================
   Header
   =================================== */
.header {
  background-color: #1a2744;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.header__logo {
  color: #fff;
  font-size: 1.25rem;
  font-weight: 700;
}

.header__hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 32px;
  height: 24px;
  position: relative;
  z-index: 110;
}

.header__hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: #fff;
  position: absolute;
  left: 0;
  transition: transform 0.3s, opacity 0.3s;
}

.header__hamburger span:nth-child(1) { top: 0; }
.header__hamburger span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.header__hamburger span:nth-child(3) { bottom: 0; }

.header__hamburger.is-open span:nth-child(1) {
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
}

.header__hamburger.is-open span:nth-child(2) {
  opacity: 0;
}

.header__hamburger.is-open span:nth-child(3) {
  bottom: 50%;
  transform: translateY(50%) rotate(-45deg);
}

.header__nav-list {
  display: flex;
  gap: 28px;
}

.header__nav-list a {
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  transition: opacity 0.3s;
}

.header__nav-list a:hover {
  opacity: 0.7;
}

/* ===================================
   Hero
   =================================== */
.hero {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: center;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background-color: #c8d0d8;
  z-index: 0;
}

.hero__bg::after {
  content: "Hero: 住宅の外観写真";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #999;
  font-size: 1rem;
}

.hero__inner {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 60px 20px;
  width: 100%;
}

.hero__title {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.5;
  color: #1a2744;
  margin-bottom: 16px;
}

.hero__sub {
  font-size: 0.9375rem;
  color: #444;
  margin-bottom: 32px;
}

.hero__search {
  background-color: rgba(26, 39, 68, 0.9);
  border-radius: 8px;
  padding: 24px;
  max-width: 640px;
}

.hero__search-label {
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 500;
  margin-bottom: 8px;
}

.hero__search-icons {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.hero__search-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: none;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  padding: 10px 14px;
  color: #fff;
  font-size: 0.75rem;
  font-family: inherit;
  cursor: pointer;
  transition: border-color 0.3s;
}

.hero__search-icon:hover {
  border-color: #e8a735;
}

.hero__search-icon-img {
  width: 36px;
  height: 36px;
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
}

.hero__search-area {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 12px;
}

.hero__search-select {
  flex: 1;
  min-width: 200px;
  padding: 10px 12px;
  font-family: inherit;
  font-size: 0.9375rem;
  border: none;
  border-radius: 4px;
}

.hero__search-btn {
  white-space: nowrap;
}

/* ===================================
   About
   =================================== */
.about__text {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 40px;
  font-size: 0.9375rem;
  line-height: 2;
}

.about__image {
  width: 100%;
  height: 360px;
  border-radius: 8px;
}

/* ===================================
   Pest Types
   =================================== */
.pest-types__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.pest-types__card {
  background-color: #fff;
  border-radius: 8px;
  padding: 28px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: box-shadow 0.3s;
}

.pest-types__card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.pest-types__icon {
  width: 64px;
  height: 64px;
}

.pest-types__name {
  font-weight: 700;
  font-size: 0.9375rem;
  color: #1a2744;
}

/* ===================================
   Knowledge
   =================================== */
.knowledge__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.knowledge__card {
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow 0.3s;
}

.knowledge__card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.knowledge__thumb {
  width: 100%;
  height: 180px;
}

.knowledge__card-title {
  padding: 16px;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.6;
  color: #333;
}

/* ===================================
   Points
   =================================== */
.points__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.points__item {
  text-align: center;
}

.points__icon {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
}

.points__heading {
  font-size: 1.0625rem;
  font-weight: 700;
  color: #1a2744;
  margin-bottom: 12px;
}

.points__text {
  font-size: 0.875rem;
  line-height: 1.8;
  color: #555;
}

/* ===================================
   Companies
   =================================== */
.companies__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 40px;
}

.companies__card {
  background-color: #fff;
  border-radius: 8px;
  padding: 24px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  transition: box-shadow 0.3s;
}

.companies__card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.companies__logo {
  width: 80px;
  height: 80px;
}

.companies__name {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #333;
}

.companies__more {
  text-align: center;
}

/* ===================================
   Column
   =================================== */
.column__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

.column__card {
  background-color: #fff;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #e8e8e8;
  transition: box-shadow 0.3s;
}

.column__card:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.column__thumb {
  width: 100%;
  height: 160px;
}

.column__body {
  padding: 16px;
}

.column__date {
  font-size: 0.75rem;
  color: #999;
  margin-bottom: 8px;
}

.column__card-title {
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.6;
  color: #333;
}

.column__more {
  text-align: center;
}

/* ===================================
   CTA
   =================================== */
.cta {
  text-align: center;
}

.cta__title {
  color: #fff;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 20px;
}

.cta__text {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.9375rem;
  margin-bottom: 32px;
  line-height: 2;
}

/* ===================================
   Footer
   =================================== */
.footer {
  background-color: #1a2744;
  color: #fff;
  padding: 48px 0 24px;
}

.footer__inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.footer__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 40px;
  margin-bottom: 40px;
}

.footer__logo {
  font-size: 1.125rem;
  font-weight: 700;
  color: #fff;
  white-space: nowrap;
}

.footer__nav-list {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
}

.footer__nav-list a {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.8);
  transition: opacity 0.3s;
}

.footer__nav-list a:hover {
  opacity: 0.7;
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer__sns a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.875rem;
  font-weight: 700;
}

.footer__copyright {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
}

/* ===================================
   Responsive — Tablet
   =================================== */
@media (max-width: 768px) {
  .section {
    padding: 56px 0;
  }

  .section__title {
    font-size: 1.375rem;
    margin-bottom: 28px;
  }

  /* Header */
  .header__hamburger {
    display: block;
  }

  .header__nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    max-width: 320px;
    height: 100vh;
    background-color: #1a2744;
    padding: 80px 24px 40px;
    transition: right 0.3s;
    z-index: 105;
  }

  .header__nav.is-open {
    right: 0;
  }

  .header__nav-list {
    flex-direction: column;
    gap: 0;
  }

  .header__nav-list li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .header__nav-list a {
    display: block;
    padding: 16px 0;
    font-size: 1rem;
  }

  /* Hero */
  .hero {
    min-height: 400px;
  }

  .hero__title {
    font-size: 1.5rem;
  }

  .hero__search-icons {
    gap: 8px;
  }

  .hero__search-icon {
    padding: 8px 10px;
    font-size: 0.6875rem;
  }

  .hero__search-icon-img {
    width: 28px;
    height: 28px;
  }

  /* Grids → 2 columns */
  .pest-types__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .knowledge__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .points__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .companies__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .column__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  /* About */
  .about__image {
    height: 240px;
  }

  /* Footer */
  .footer__top {
    flex-direction: column;
    gap: 24px;
  }
}

/* ===================================
   Responsive — Mobile
   =================================== */
@media (max-width: 480px) {
  html {
    font-size: 15px;
  }

  .section {
    padding: 48px 0;
  }

  /* Hero */
  .hero {
    min-height: 360px;
  }

  .hero__title {
    font-size: 1.375rem;
  }

  .hero__search {
    padding: 16px;
  }

  .hero__search-select {
    min-width: 0;
    width: 100%;
  }

  .hero__search-btn {
    width: 100%;
  }

  /* Grids → 1 column */
  .knowledge__grid,
  .column__grid {
    grid-template-columns: 1fr;
  }

  .points__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .companies__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* About */
  .about__text {
    text-align: left;
  }

  .about__image {
    height: 200px;
  }

  /* Knowledge */
  .knowledge__thumb {
    height: 160px;
  }

  /* CTA */
  .cta__title {
    font-size: 1.25rem;
  }

  .btn--accent {
    padding: 14px 32px;
    font-size: 1rem;
    width: 100%;
  }

  /* P0: iOS form auto-zoom prevention */
  .form__input,
  .form__select,
  .form__textarea,
  .hero__search-select {
    font-size: 16px;
  }

  /* P1: tap targets — radio / checkbox */
  .form__radio,
  .form__checkbox {
    min-height: 44px;
    padding: 8px 0;
  }

  .form__input,
  .form__select {
    padding: 14px 12px;
  }

  /* P1: CTA phone button */
  .btn--outline {
    width: 100%;
  }

  /* P2: hero search icons */
  .hero__search-icons {
    justify-content: center;
  }

  /* P2: pest-types compact */
  .pest-types__card {
    padding: 20px 8px;
  }

  .pest-types__icon {
    width: 48px;
    height: 48px;
  }

  /* P2: column thumb */
  .column__thumb {
    height: 120px;
  }

  /* Footer */
  .footer__bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}

/* ===================================
   Sub-page Components
   下層ページ用コンポーネント（追記）
   =================================== */

/* --- Container variant ------------ */
.container--narrow {
  max-width: 780px;
}

/* --- Hero sub-page ---------------- */
.hero--sub {
  min-height: auto;
  padding: 0;
}

.hero--sub .hero__bg {
  position: absolute;
  inset: 0;
}

.hero--sub .hero__bg::after {
  content: none;
}

.hero--sub .hero__inner {
  padding: 48px 20px 32px;
}

.hero--sub .hero__title {
  font-size: 1.625rem;
  margin-bottom: 0;
}

/* --- Breadcrumb ------------------- */
.breadcrumb {
  max-width: 1100px;
  margin: 0 auto;
  padding: 12px 20px;
}

.breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
  list-style: none;
  font-size: 0.75rem;
  color: #888;
}

.breadcrumb__item {
  display: flex;
  align-items: center;
}

.breadcrumb__item:not(:last-child)::after {
  content: ">";
  margin: 0 8px;
  color: #d0d0d0;
}

.breadcrumb__link {
  color: #888;
  transition: color 0.3s;
}

.breadcrumb__link:hover {
  color: #1a2744;
}

.breadcrumb__current {
  color: #333;
}

/* --- Figure ----------------------- */
.article-body figure {
  margin: 24px 0;
}

.article-body figcaption {
  font-size: 0.8125rem;
  color: #888;
  margin-top: 8px;
  text-align: center;
}

/* --- Hamburger overlay ------------ */
.header__overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 104;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.header__overlay.is-open {
  opacity: 1;
  pointer-events: auto;
}

/* --- 2-Column Layout ------------- */
.layout--2col {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 40px;
  align-items: start;
}

.layout__sidebar {
  position: sticky;
  top: 80px;
}

/* --- Article Body ----------------- */
.article-body h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1a2744;
  border-bottom: 3px solid #e8a735;
  padding-bottom: 12px;
  margin: 56px 0 24px;
  line-height: 1.4;
}

.article-body h2:first-child {
  margin-top: 0;
}

.article-body h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: #1a2744;
  border-left: 4px solid #e8a735;
  padding-left: 12px;
  margin: 40px 0 16px;
  line-height: 1.4;
}

.article-body h4 {
  font-size: 1rem;
  font-weight: 700;
  color: #333;
  margin: 32px 0 12px;
  line-height: 1.4;
}

.article-body p {
  font-size: 0.9375rem;
  line-height: 2;
  margin-bottom: 20px;
}

.article-body ul,
.article-body ol {
  padding-left: 24px;
  margin-bottom: 20px;
}

.article-body ul {
  list-style: disc;
}

.article-body ol {
  list-style: decimal;
}

.article-body li {
  font-size: 0.9375rem;
  line-height: 1.8;
  margin-bottom: 8px;
}

.article-body strong {
  font-weight: 700;
  color: #1a2744;
}

.article-body blockquote {
  border-left: 4px solid #e8a735;
  padding: 16px 20px;
  margin: 24px 0;
  background-color: #f9f9f9;
  color: #555;
  font-size: 0.9375rem;
  line-height: 1.8;
}

.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 0.875rem;
}

.article-body th {
  background-color: #1a2744;
  color: #fff;
  font-weight: 700;
  padding: 12px;
  text-align: left;
}

.article-body td {
  border: 1px solid #e0e0e0;
  padding: 12px;
  line-height: 1.6;
}

.article-body tr:nth-child(even) td {
  background-color: #f9f9f9;
}

.article-body a {
  color: #1a2744;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.3s;
}

.article-body a:hover {
  color: #e8a735;
}

.article-body__citation {
  font-size: 0.8125rem;
  color: #888;
}

.article-body__summary {
  background-color: #f5f5f5;
  border-radius: 8px;
  padding: 20px;
  margin: 24px 0;
  font-size: 0.9375rem;
  line-height: 1.8;
}

/* --- TOC (Table of Contents) ------ */
.toc {
  background-color: #f5f5f5;
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 40px;
}

.toc__title {
  font-size: 1rem;
  font-weight: 700;
  color: #1a2744;
  margin-bottom: 12px;
}

.toc__list {
  list-style: decimal;
  padding-left: 20px;
  margin: 0;
}

.toc__item {
  margin-bottom: 8px;
  font-size: 0.875rem;
  line-height: 1.6;
}

.toc__link {
  color: #1a2744;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.3s;
}

.toc__link:hover {
  color: #e8a735;
}

.toc__sublist {
  list-style: decimal;
  padding-left: 16px;
  margin-top: 8px;
}

/* --- FAQ Accordion ---------------- */
.faq__list {
  margin: 0;
  padding: 0;
}

.faq__item {
  border-bottom: 1px solid #e8e8e8;
}

.faq__item:first-child {
  border-top: 1px solid #e8e8e8;
}

.faq__question {
  display: block;
  width: 100%;
  font-size: 0.9375rem;
  font-weight: 700;
  color: #333;
  padding: 16px 32px 16px 0;
  cursor: pointer;
  position: relative;
  list-style: none;
}

.faq__question::-webkit-details-marker {
  display: none;
}

.faq__question::before {
  content: "Q.";
  color: #e8a735;
  font-weight: 700;
  margin-right: 8px;
}

.faq__question::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid #888;
  border-bottom: 2px solid #888;
  transform: translateY(-70%) rotate(45deg);
  transition: transform 0.3s;
}

.faq__item[open] .faq__question::after {
  transform: translateY(-30%) rotate(-135deg);
}

.faq__answer {
  padding: 0 0 16px 28px;
  font-size: 0.9375rem;
  line-height: 1.8;
  color: #555;
}

.faq__answer::before {
  content: "A.";
  color: #1a2744;
  font-weight: 700;
  margin-right: 8px;
}

/* --- Form elements ---------------- */
.form {
  max-width: 640px;
  margin: 0 auto;
}

.form__group {
  margin-bottom: 24px;
}

.form__label {
  display: block;
  font-size: 0.875rem;
  font-weight: 700;
  color: #333;
  margin-bottom: 8px;
}

.form__required {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  background-color: #e8a735;
  color: #fff;
  padding: 2px 8px;
  border-radius: 2px;
  margin-left: 8px;
  vertical-align: middle;
}

.form__input,
.form__select,
.form__textarea {
  width: 100%;
  padding: 12px;
  font-family: inherit;
  font-size: 0.9375rem;
  color: #333;
  background-color: #fff;
  border: 1px solid #d0d0d0;
  border-radius: 4px;
  transition: border-color 0.3s;
}

.form__input:focus,
.form__select:focus,
.form__textarea:focus {
  outline: none;
  border-color: #1a2744;
}

.form__input::placeholder,
.form__textarea::placeholder {
  color: #999;
}

.form__textarea {
  min-height: 160px;
  resize: vertical;
}

.form__radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.form__radio {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9375rem;
  color: #333;
  cursor: pointer;
}

.form__radio input[type="radio"] {
  accent-color: #1a2744;
}

.form__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.8125rem;
  color: #555;
  line-height: 1.6;
}

.form__checkbox input[type="checkbox"] {
  margin-top: 3px;
  accent-color: #1a2744;
}

.form__hint {
  font-size: 0.75rem;
  color: #888;
  margin-top: 4px;
}

.form__error {
  font-size: 0.75rem;
  color: #d32f2f;
  margin-top: 4px;
}

.form__submit {
  text-align: center;
  margin-top: 32px;
}

.form__note {
  font-size: 0.8125rem;
  color: #555;
  margin-top: 24px;
  line-height: 1.8;
}

.form__note ul {
  list-style: disc;
  padding-left: 20px;
}

.form__note li {
  margin-bottom: 6px;
}

/* --- Related Articles ------------- */
.related-articles {
  background-color: #f5f5f5;
  padding: 48px 0;
}

.related-articles__title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1a2744;
  margin-bottom: 24px;
}

.related-articles__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* --- Pagination ------------------- */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 4px;
  margin-top: 48px;
}

.pagination__item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  font-size: 0.875rem;
  font-weight: 500;
  color: #333;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  transition: background-color 0.3s, color 0.3s;
}

.pagination__item:hover {
  background-color: #f5f5f5;
}

.pagination__item--active {
  background-color: #1a2744;
  border-color: #1a2744;
  color: #fff;
}

.pagination__item--active:hover {
  background-color: #1a2744;
}

.pagination__item--disabled {
  color: #d0d0d0;
  border-color: #e8e8e8;
  pointer-events: none;
}

/* ===================================
   Sub-page Responsive — Tablet
   =================================== */
@media (max-width: 768px) {
  .hero--sub .hero__inner {
    padding: 36px 20px 24px;
  }

  .hero--sub .hero__title {
    font-size: 1.375rem;
  }

  .article-body h2 {
    font-size: 1.25rem;
    margin: 40px 0 20px;
  }

  .article-body h3 {
    font-size: 1rem;
    margin: 32px 0 12px;
  }

  .toc {
    padding: 20px;
    margin-bottom: 32px;
  }

  .layout--2col {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .layout__sidebar {
    position: static;
  }

  .related-articles {
    padding: 36px 0;
  }

  .related-articles__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}

/* ===================================
   Sub-page Responsive — Mobile
   =================================== */
@media (max-width: 480px) {
  .hero--sub .hero__inner {
    padding: 28px 20px 20px;
  }

  .hero--sub .hero__title {
    font-size: 1.25rem;
  }

  .breadcrumb__list {
    font-size: 0.6875rem;
  }

  .breadcrumb__item:not(:last-child)::after {
    margin: 0 6px;
  }

  .article-body h2 {
    font-size: 1.1875rem;
    margin: 36px 0 16px;
  }

  .article-body h3 {
    margin: 28px 0 12px;
  }

  .article-body .table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 24px -20px;
    padding: 0 20px;
  }

  .article-body table {
    min-width: 480px;
  }

  .toc summary {
    cursor: pointer;
    font-size: 1rem;
    font-weight: 700;
    color: #1a2744;
    padding: 4px 0;
  }

  .form__radio-group {
    flex-direction: column;
    gap: 12px;
  }

  .related-articles__grid {
    grid-template-columns: 1fr;
  }

  .pagination {
    gap: 2px;
    margin-top: 36px;
  }

  .pagination__item {
    width: 36px;
    height: 36px;
    font-size: 0.8125rem;
  }
}

/* ============================================================
   レスポンシブ監査（docs/99_responsive_audit.md）に基づく追加修正
   2026-05-05 適用
============================================================ */

/* P1: figure 共通スタイル（全 pillar ページの本文画像用） */
.article-body figure {
  margin: 24px 0;
}

.article-body figcaption {
  font-size: 0.8125rem;
  color: #888;
  margin-top: 8px;
  text-align: center;
}

/* P2: 1024px ブレークポイント — companies__grid を 3 列に */
@media (max-width: 1024px) and (min-width: 769px) {
  .companies__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* P0/P1/P2: 480px 以下の追加修正 */
@media (max-width: 480px) {
  /* P0: iOS フォーム自動ズーム防止 */
  .form__input,
  .form__select,
  .form__textarea,
  .hero__search-select {
    font-size: 16px;
  }

  /* P1: タップ領域 */
  .form__radio,
  .form__checkbox {
    min-height: 44px;
    padding: 8px 0;
  }

  .form__input,
  .form__select {
    padding: 14px 12px;
  }

  /* P1: アウトラインボタンをモバイルで全幅 */
  .btn--outline {
    width: 100%;
    box-sizing: border-box;
  }

  /* P2: pest-types カード縮小 */
  .pest-types__card {
    padding: 20px 8px;
  }

  .pest-types__icon {
    width: 48px;
    height: 48px;
  }

  /* P2: pest-types グリッドを 480px でも 2 列に維持しつつ余白調整 */
  .pest-types__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  /* P2: column サムネ高さ縮小 */
  .column__thumb {
    height: 120px;
  }

  /* P2: ボタン高さの余裕確保 */
  .btn--primary,
  .btn--accent {
    padding: 14px 28px;
  }

  /* Hero 検索アイコンの 5 個目折返し対策 */
  .hero__search-icons {
    justify-content: center;
  }
}

/* P2: 400px 以下 — companies__grid を 1 列に */
@media (max-width: 400px) {
  .companies__grid {
    grid-template-columns: 1fr;
  }
}

/* /search/ /area/ 検索結果カードのレスポンシブ調整 */
@media (max-width: 480px) {
  .search-results__item {
    padding: 16px !important;
  }

  .search-results__item .btn {
    display: block;
    margin: 8px 0 0;
  }
}

/* Hero検索フォーム（form化対応） */
.hero__search-icon {
  cursor: pointer;
}

.hero__search-icon-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.hero__search-icon:has(.hero__search-icon-input:checked) {
  outline: 2px solid var(--accent, #f5a623);
  outline-offset: 2px;
  border-radius: 8px;
}

/* フッター会社情報ブロック */
.footer__company {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 16px;
  margin-top: 16px;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.75);
}

.footer__company-name {
  margin: 0 0 4px;
  font-weight: 500;
}

.footer__company-address,
.footer__company-contact {
  margin: 0 0 4px;
}

.footer__company a {
  color: rgba(255, 255, 255, 0.85);
}

.footer__company a:hover {
  color: #fff;
}
