.p-company-anchor .c-lower-anchor__list > li {
  flex: 0 0 240px;
}

.p-company-profile {
  padding-block: 120px 200px;
  background: var(--color-white);
}

.p-company-profile__table {
  width: 880px;
  max-width: 100%;
  margin: 96px auto 0;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
}

.p-company-profile__term {
  border-bottom: 2px solid var(--color-border-subtle);
  padding: 16px 0;
  display: flex;
  align-items: center;
  font-size: var(--font-size-md-plus);
  line-height: 36.8px;
  font-weight: var(--font-weight-medium);
  letter-spacing: 0.1em;
}

.p-company-profile__description {
  min-height: 64px;
  border-bottom: 1px solid var(--color-border-subtle);
  padding: 16px 0 16px 56px;
  margin: 0;
  display: flex;
  align-items: center;
  font-size: var(--font-size-base);
  line-height: var(--line-height-loose);
  letter-spacing: 0.1em;
}

.p-company-profile__lines {
  display: grid;
}

.p-company-profile__line-group {
  margin-top: 16px;
}

.p-company-profile,
.p-company-numbers,
.p-company-history {
  scroll-margin-top: var(--header-height);
}

.p-company-profile__access {
  width: 880px;
  max-width: 100%;
  min-height: 200px;
  margin: 80px auto 0;
  padding: 40px;
  position: relative;
  z-index: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  color: var(--color-white);
  text-align: center;
}

.p-company-profile__access img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* テキストを画像上に重ねるCTA型バナーのため、画像を背面に固定します。 */
  position: absolute;
  inset: 0;
  z-index: -2;
  transition: transform 0.3s ease;
}

.p-company-profile__access::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--color-overlay-dark);
}

.p-company-profile__access:hover img {
  transform: scale(1.05);
}

.p-company-profile__access-title {
  font-family: var(--font-family-display-en);
  font-size: var(--font-size-4xl);
  line-height: var(--line-height-none);
  letter-spacing: 0.12em;
}

.p-company-profile__access-text {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-size: var(--font-size-lg-plus);
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-medium);
  letter-spacing: 0.1em;
}

.p-company-profile__access .c-line-link__icon {
  position: relative;
  border: 0;
  background: var(--color-white);
  color: var(--color-text);
  transition: background-color 0.2s ease, color 0.2s ease;
}

.p-company-profile__access .c-line-link__icon svg {
  width: 13px;
  height: 8px;
  display: block;
}

.p-company-profile__access .c-line-link__icon img {
  position: relative;
  inset: auto;
  z-index: auto;
  width: 13px;
  height: 8px;
  object-fit: contain;
  transition: none;
}

.p-company-profile__access:hover .c-line-link__icon {
  color: var(--color-white);
  background: var(--color-primary);
}

.p-company-profile__access .c-line-link__icon img {
  position: relative;
  inset: auto;
  z-index: auto;
  width: 13px;
  height: 8px;
  object-fit: contain;
  transition: filter 0.2s ease;
}

.p-company-profile__access:hover .c-line-link__icon img {
  filter: brightness(0) invert(1);
}

.p-company-numbers {
  padding-block: 200px;
  background: var(--color-section-background-light);
}

.p-company-numbers__grid {
  width: 1112px;
  max-width: 100%;
  margin: 80px auto 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px;
}

.p-company-number {
  width: 344px;
  flex: 0 0 344px;
  aspect-ratio: 1;
  border: 1px solid var(--color-border-subtle);
  border-radius: 50%;
  background: var(--color-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.p-company-number__label {
  font-size: var(--font-size-xl);
  line-height: var(--line-height-normal);
  letter-spacing: 0.1em;
}

.p-company-number__label-small {
  font-size: var(--font-size-md);
  line-height: var(--line-height-normal);
}

.p-company-number__value {
  margin-top: 24px;
  font-family: var(--font-family-number);
  font-size: 60px;
  line-height: var(--line-height-none);
  font-weight: var(--font-weight-light);
  letter-spacing: 0;
}

.p-company-number__unit {
  margin-top: 8px;
  font-size: var(--font-size-xl);
  line-height: 1.3;
  letter-spacing: 0.1em;
}

.p-company-history {
  padding-block: 200px;
  background: var(--color-white);
}

.p-company-history__lead {
  margin-top: 32px;
  text-align: center;
  font-size: var(--font-size-base);
  line-height: var(--line-height-relaxed);
  font-weight: var(--font-weight-normal);
  letter-spacing: 0.1em;
}

.p-company-history__body {
  width: 1028px;
  max-width: 100%;
  margin: 80px auto 0;
}

.p-company-history__columns {
  display: grid;
  grid-template-columns: 510px 510px;
  gap: 8px;
  position: sticky;
  top: var(--header-height);
  z-index: 10;
}

.p-company-history__column-label {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-block: 8px;
  background: var(--color-section-background-light);
  font-size: var(--font-size-lg-plus);
  line-height: var(--line-height-normal);
  letter-spacing: 0.1em;
}

.p-company-history__column-label--company {
  background: rgba(239, 242, 246, 1);
}

.p-company-history__item {
  margin-top: 40px;
  display: grid;
  grid-template-columns: 370px 1fr 370px;
  gap: 48px;
  align-items: start;
}

.p-company-history__side-title,
.p-company-history__company-title {
  padding-block: 8px;
  border-bottom: 1px solid rgba(189, 193, 208, 1);
  font-size: var(--font-size-lg-plus);
  line-height: var(--line-height-normal);
  font-weight: var(--font-weight-normal);
  letter-spacing: 0.1em;
}

.p-company-history__events {
  margin-top: 24px;
  display: grid;
  gap: 16px;
}

.p-company-history__event {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 0;
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  letter-spacing: 0.1em;
}

.p-company-history__era {
  position: relative;
  height: 100%;
}

.p-company-history__era::after {
  content: "";
  width: 1px;
  position: absolute;
  top: 72px;
  bottom: 0;
  left: 50%;
  background: var(--color-border-light);
}

.p-company-history__era-label {
  display: block;
  font-family: var(--font-family-number);
  font-size: 56px;
  line-height: var(--line-height-none);
  font-weight: var(--font-weight-light);
  letter-spacing: 0.1em;
  text-align: center;
}

.p-company-history__company-detail {
  margin-top: 24px;
  padding-left: 16px;
  display: grid;
  gap: 16px;
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  letter-spacing: 0.1em;
}

.p-company-history__company-detail li {
  position: relative;
}

.p-company-history__company-detail li::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-border-light);
  position: absolute;
  top: 10px;
  left: -16px;
}

.p-company-history__photo {
  width: 256px;
  aspect-ratio: 256 / 181;
  margin-top: 24px;
  margin-bottom: 96px;
  overflow: hidden;
}

.p-company-history__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.p-company-links {
  padding-block: 120px;
  background: var(--color-section-background-light);
}

@media (max-width: 1279px) {
  .p-company-history__body {
    width: 100%;
  }

  .p-company-history__columns {
    grid-template-columns: 1fr 1fr;
  }

  /* 年代ラベルをスマホ同様に上部に配置し、左右の内容を並べる */
  .p-company-history__item {
    grid-template-columns: minmax(0, 1fr) 8px minmax(0, 1fr);
    gap: 24px;
    margin-top: 80px;
  }

  .p-company-history__era {
    position: relative;
    min-height: 200px;
  }

  .p-company-history__era-label {
    font-size: 42px;
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translate(-50%, -100%);
    white-space: nowrap;
  }

  .p-company-history__era::after {
    top: 0;
  }
}

@media (max-width: 767px) {
  .p-company-anchor .c-lower-anchor__list > li {
    flex: 0 0 100%;
  }
  .p-company-profile,
  .p-company-numbers,
  .p-company-history,
  .p-company-links {
    padding-block: var(--sp-section-padding);
  }

  .p-company-profile__table {
    margin-top: var(--sp-section-gap);
    grid-template-columns: 1fr;
  }

  .p-company-profile__term {
    padding: 20px 0 0;
    border-bottom: 0;
    font-size: var(--font-size-lg);
    line-height: var(--line-height-normal);
  }

  .p-company-profile__description {
    min-height: auto;
    padding: 8px 0 20px;
    line-height: var(--line-height-relaxed);
    border-bottom: 1px solid var(--color-border-subtle);
  }

  .p-company-profile__access {
    min-height: 168px;
    margin-top: var(--sp-section-gap);
    padding: 32px 20px;
  }

  .p-company-profile__access-title {
    font-size: var(--font-size-2xl);
  }

  .p-company-profile__access-text {
    font-size: var(--font-size-base);
  }

  .p-company-numbers__grid {
    margin-top: var(--sp-section-gap);
    gap: 16px;
  }

  .p-company-number {
    width: calc((100% - 16px) / 2);
    flex-basis: calc((100% - 16px) / 2);
    min-height: 0;
  }

  .p-company-number__label,
  .p-company-number__unit {
    font-size: var(--font-size-md);
  }

  .p-company-number__label-small {
    font-size: var(--font-size-xs);
  }

  .p-company-number__value {
    margin-top: 16px;
    font-size: var(--font-size-4xl);
  }

  .p-company-history__lead {
    text-align: left;
  }

  .p-company-history__body {
    margin-top: var(--sp-section-gap);
  }

  .p-company-history__column-label {
    font-size: var(--font-size-base);
  }

  .p-company-history__item {
    margin-top: 64px;
    grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr);
    gap: 8px;
  }

  .p-company-history__side-title,
  .p-company-history__company-title {
    font-size: var(--font-size-md);
    padding-block: 6px;
  }

  .p-company-history__side-title br,
  .p-company-history__company-title br {
    display: none;
  }

  .p-company-history__era {
    min-height: 200px;
    position: relative;
  }

  .p-company-history__era-label {
    font-size: var(--font-size-3xl);
    letter-spacing: 0.05em;
    text-align: center;
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translate(-50%, -100%);
  }

  .p-company-history__era::after {
    top: 0;
  }

  .p-company-history__event {
    grid-template-columns: 1fr;
    font-size: var(--font-size-xs);
  }

  .p-company-history__company-detail {
    font-size: var(--font-size-xs);
    padding-left: 12px;
  }

  .p-company-history__company-detail li::before {
    width: 6px;
    height: 6px;
    top: 6px;
    left: -12px;
  }

  .p-company-history__photo {
    width: 100%;
    max-width: 256px;
    margin-bottom: 80px;
  }
}
