.notice-section {
  h3 {
    margin-bottom: 1em;
  }
}

.managed-pricing__grid {
  gap: 60px 0;
}

/* ============================================================
   スペック
   ============================================================ */

.managed-specs {
  padding: 100px 0 100px;
  background: #ffffff;
}

.managed-specs__intro {
  text-align: center;
  margin-bottom: 20px;
}

.managed-specs__title {
  margin-bottom: 24px;
}

.managed-specs__subtitle {
  font-size: 22px;
  text-align: center;
}

.managed-specs__content {
  max-width: 1200px;
  margin: 0 auto;
}

.managed-specs__description {
  text-align: center;
  margin-bottom: 60px;
}

.managed-specs__table-wrapper {
  margin-bottom: 16px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  max-width: 1000px;
  &:has(.managed-specs__group:nth-child(2)) {
    max-width: 1200px;
  }
  margin-inline: auto;
}

.managed-specs__group {
  display: flex;
  flex-direction: column;
}

.managed-specs__row {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  border-bottom: 1px solid #dbe5f3;
  min-height: 100px;
}

.managed-specs__row:first-child {
  border-top: 1px solid #dbe5f3;
}

.managed-specs__cell {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-weight: 500;
  border-right: 1px solid #dbe5f3;
  border-left: 1px solid #dbe5f3;
  padding: 10px 0;
}

.managed-specs__cell:first-child {
  border-right: none;
}

/* 項目名セル */

.managed-specs__label {
  color: #000000;
  position: relative;
  padding-right: 45px;
}

/* 左グループの奇数行項目名 - 青 */

.managed-specs__group--left
  .managed-specs__row:nth-child(odd)
  .managed-specs__label {
  background: #6574e8;
}

/* 左グループの偶数行項目名 - 水色 */

.managed-specs__group--left
  .managed-specs__row:nth-child(even)
  .managed-specs__label {
  background: #fff2b9;
}

/* 右グループの奇数行項目名 - 青 */

.managed-specs__group--right
  .managed-specs__row:nth-child(odd)
  .managed-specs__label {
  background: #6574e8;
}

/* 右グループの偶数行項目名 - 水色 */

.managed-specs__group--right
  .managed-specs__row:nth-child(even)
  .managed-specs__label {
  background: #fff2b9;
}

/* 値セル */

.managed-specs__value {
  background: #f2f4f8;
  color: #111111;
}

.managed-specs__label {
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.managed-specs__tooltip-btn {
  position: absolute;
  top: 50%;
  right: 23px;
  /* transform で中央寄せすると子要素の position: fixed の基準が
     viewport ではなく button になってしまうため、margin-top で代替 */
  margin-top: -12.5px;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: opacity 0.2s;
}

.managed-specs__tooltip-btn img {
  width: 25px;
  height: 25px;
  display: block;
}

.managed-specs__tooltip-btn:hover {
  opacity: 0.8;
}

/* ツールチップ吹き出し本体 (data-tooltip 属性のテキストを表示)
   .managed-specs__tooltip-btn と .managed-options__tooltip-btn 両方に共通適用。
   position: fixed で viewport 基準。位置 (top/left) は JS が
   getBoundingClientRect から計算して --tooltip-top / --tooltip-left に設定。
   非表示時は -9999px に逃がして親 overflow に影響させない。 */
.managed-specs__tooltip-btn::before {
  content: attr(data-tooltip);
  position: fixed;
  top: var(--tooltip-top, -9999px);
  left: var(--tooltip-left, -9999px);
  width: max-content;
  max-width: 280px;
  padding: 10px 14px;
  background: #333333;
  color: #ffffff;
  font-size: 14px;
  font-weight: 400;
  text-align: left;
  line-height: 1.5;
  border-radius: 6px;
  white-space: pre-wrap;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.18s ease, visibility 0.18s ease;
  z-index: 9999;
}

/* 三角矢印 */
.managed-specs__tooltip-btn::after,
.managed-options__tooltip-btn::after {
  content: "";
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #333333;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.18s ease, visibility 0.18s ease;
  z-index: 20;
}

.managed-specs__tooltip-btn:hover::before,
.managed-specs__tooltip-btn:focus-visible::before,
.managed-specs__tooltip-btn:hover::after,
.managed-specs__tooltip-btn:focus-visible::after {
  opacity: 1;
  visibility: visible;
}

.managed-specs__note {
  text-align: right;
}

.managed-pricing__specs + .managed-pricing__btn {
  margin-top: auto;
}

.managed-pricing__info:has(.managed-pricing_price-table) {
  background-color: initial;
}
.managed-pricing_price-table {
  th {
    font-weight: normal;
  }
}

@media (max-width: 768px) {
  .managed-pricing__grid {
    gap: 60px 15px;
  }
}

@media (max-width: 1024px) {
  .managed-specs__subtitle {
    font-size: 20px;
  }
}

@media (max-width: 768px) {
  /* managed-specs */

  .managed-specs__table-wrapper {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .managed-specs__tooltip-btn {
    right: 10px;
  }

  .managed-specs__tooltip-btn img {
    width: 18px;
    height: 18px;
  }

  .managed-specs__cell {
    padding: 16px 12px;
    text-align: left;
    justify-content: flex-start;
    font-size: 14px;
  }

  .managed-specs__label {
    justify-content: flex-start;
  }

  .managed-specs {
    padding: 60px 0 60px;
  }

  .managed-specs__intro {
    margin-bottom: 40px;
  }

  .managed-specs__description {
    margin-bottom: 40px;
  }

  .managed-specs__row {
    height: auto !important;
    min-height: 60px;
  }

  .managed-specs__note {
    font-size: 12px;
  }
}

/* ---- */

.managed-mv__description > div {
  font-size: 80%;
}
.managed-about__content {
  display: grid;
  grid: auto-flow / 1fr 1fr 1fr;
  gap: 50px;
  & > div {
    background-color: white;
    text-align: center;
    border-radius: 50px;
    padding: 30px;
    & > div {
      width: 100%;
      margin-inline: auto;
    }
  }
  img {
    margin-inline: auto;
    height: 100px;
  }
}

.managed-survey {
  .managed-survey__graphs {
    & > div:first-child {
      display: flex;
    }
    & > div:not(:first-child) {
      border: solid 1px;
      border-top-width: 0;
    }
    input {
      display: none;
    }
    label {
      display: block;
      flex: 1;
      border: solid 1px grey;
      background-color: lightgrey;
      color: grey;
      border-top-left-radius: 10px;
      border-top-right-radius: 10px;
      font-weight: 600;
      text-align: center;
      padding: 5px 0;
      font-size: 16pt;
    }
    input:checked + label {
      border: solid 1px blue;
      background-color: white;
      color: blue;
    }
    img {
      display: none;
      margin-inline: auto;
    }

    div:has(#ping:checked) + div > img#ping-image {
      display: block;
    }

    div:has(#jitter:checked) + div > img#jitter-image {
      display: block;
    }

    div:has(#speed:checked) + div > img#speed-image {
      display: block;
    }
  }
}

.managed-pricing {
  margin-block: 20px;
}
.managed-pricing__service_header {
  grid-column: span 2;
  margin-bottom: 10px;
  text-align: center;
  font-size: 20px;
  &.managed {
    background-color: #f8bfd2;
  }
  &.private {
    background-color: #fbda94;
  }
}

.managed-pricing__features li {
  font-size: 16px;
}
.managed-pricing__card {
  &.managed {
    .managed-pricing__btn,
    .managed-pricing__header {
      color: #000;
      background-color: #f8bfd2;
    }
  }
  &.private {
    .managed-pricing__btn,
    .managed-pricing__header {
      color: #000;
      background-color: #fbda94;
    }
  }

  .managed-pricing__btn::after {
    background: url("../../img/common/icon_arrow-black.svg") center / contain
      no-repeat;
  }
}

.managed-reasons {
  ul {
    list-style-type: none;
    li {
      background-color: #fff2b9;
      border-radius: 20px;
      padding-left: 100px;
      position: relative;
      width: 80%;
      margin-inline: auto;
      margin-block: 20px;
      padding-block: 10px;
      &::before {
        content: attr(data-number);
        color: #6574e8;
        background-color: white;
        position: absolute;
        left: 40px;
        top: 15px;
        font-size: 32px;
        width: 50px;
        height: 50px;
        border-radius: 25px;
        text-align: center;
      }
      div {
        font-size: 16px;
      }
      div:first-child {
        font-size: 24px;
        font-weight: 700;
      }
    }
  }
}

.fx-flow {
  padding: 100px 0 0;
  background-color: #fff2b9;
  .fx_flow__list {
    display: flex;
    & > div {
      background-color: white;
      position: relative;
      height: 300px;
      width: 18%;
      display: inline-block;
      margin-left: 5%;
      text-align: center;
      padding: 40px 15px 20px;
      flex: 1;
      &::before {
        font-size: 18px;
        content: attr(data-number);
        position: absolute;
        left: 0;
        top: 0;
        width: 20px;
        color: white;
        background-color: #6574e8;
      }
      &:first-child::before {
        background-color: #ff9900;
      }

      &::after {
        content: "";
        position: absolute;
        top: 0;
        left: 100%;

        width: 15%;
        height: 300px;

        background-color: white;

        /* 左上、左下、右の中央を結んで三角形に切り抜く */
        clip-path: polygon(0% 0%, 0% 100%, 100% 50%);
      }

      img {
        margin-inline: auto;
        height: 33%;
        width: auto;
      }
      h3 {
        height: 70px;
      }
    }
  }
}

.managed-trial-top-cta.white {
  background-color: #ffffff;
}

.managed-trial-top-cta.apply {
  margin-block: 20px;
  .managed-trial-cta__card-btn {
    &.managed {
      background-color: #1877f2;
    }
    &.private {
      background-color: #72b935;
    }
  }
}

.managed-subpage-header {
  background-image: none;
  background-color: #6574e8;
}

/* -- */

.managed-pricing__grid {
  grid-template-columns: 1fr 1fr;
}

.managed-pricing__features li {
  grid-template-columns: none;
}

.managed-pricing {
  .managed-pricing__nav-link {
    display: flex;
    gap: 40px;
    max-width: 600px;
    padding: 40px 0 0;
    margin: 0 auto;
    .btn {
      width: 250px;
      height: 50px;
      margin: 0 auto 20px;
      border-radius: 10px;
      line-height: 50px;
      &.cloud {
        background-color: #6574e8;
        &:hover, &:focus-visible:hover {
          background-color: #fff;
          outline: 2px solid #6574e8;
          a {
            color: #6574e8;
          }
        }
      }
      &.server {
        background-color: #72b935;
        &:hover, &:focus-visible:hover {
          background-color: #fff;
          outline: 2px solid #72b935;
          a {
            color: #72b935;
          }
        }
      }
      a {
        display: inline-block;
        width: 100%;
        height: 100%;
        font-size: 20px;
        font-weight: 700;
        color: #fff;
      }
    }
  }
  h3 {
    margin-inline: auto;
    text-align: center;
    &#cloud,
    &#server {
      border-style: solid;
      border-width: 5px;
      border-radius: 10px;
      width: 250px;
      margin: 120px auto 40px;
      padding: 5px;
    }
    &#cloud {
      border-color: #6574e8;
    }
    &#server {
      border-color: #72b935;
    }
    & + div {
      text-align: center;
      margin-bottom: 20px;
    }
  }
}

@media (max-width: 480px) {
  .managed-pricing__nav-link {
    flex-direction: column;
  }
}

.managed-pricing {
  .managed-pricing__title + div {
    text-align: center;
    margin-top: -50px;
    margin-bottom: 30px;
  }
  table {
    margin: 30px 0 0;
    text-align: center;
    th {
      padding: 10px;
      border: 1px solid lightgrey;
      color: white;
    }
    td {
      border: 1px solid lightgrey;
      padding: 20px 10px;
      line-height: 2em;
    }
    tr td:first-of-type {
      font-weight: 600;
    }
    #cloud ~ & {
      th {
        background-color: #6574e8;
      }
      tr:first-child {
        th:first-child {
          width: 20%;
        }
        th:nth-child(2) {
          width: 20%;
        }
        th:last-child {
          width: 20%;
        }
      }
      tr:not(:first-of-type) th {
        background-color: #eef0fd;
        color: #111111;
      }
    }
    #server ~ & {
      margin: 0 auto;
      th {
        background-color: #72b935;
      }
      tr:first-child {
        th:first-child {
          width: 20%;
        }
        th:last-child {
          width: 20%;
        }
      }
    }
    ul {
      padding: 0 50px;
      list-style: disc inside;
      text-indent: 22px hanging;
      text-align: left;
      &.notabene {
        list-style: "\203b";
        color: red;
        li {
          margin-left: 11px;
          padding-left: 11px;
        }
      }
    }
  }
}

@media (max-width: 480px) {
  .managed-pricing table ul {
    padding: initial;
  }
}

.managed-trial-top-cta:not(.apply) .managed-trial-cta__grid {
  grid-template-columns: 1fr;
}

/* =============================================================
   ご利用までの流れ (PC_専用サーバー)
   ============================================================= */

.managed-steps {
  padding: 100px 0;
  background: #ffffff;
}

.managed-steps__lead {
  text-align: center;
  margin: 0 0 60px;
}

.managed-steps__lead a {
  color: #6574e8;
  text-decoration: underline;
}

.managed-steps__list {
  list-style: none;
  max-width: 720px;
  margin: 0 auto;
  padding: 0;
  position: relative;
}

.managed-steps__list::before {
  content: "";
  position: absolute;
  top: 24px;
  bottom: 72px;
  left: 38px;
  width: 2px;
  background: #6574e8;
  z-index: 0;
}

@media (max-width: 480px) {
  .managed-steps__list::before {
    left: 30px;
    bottom: 120px;
  }
}

.managed-steps__item {
  display: grid;
  grid-template-columns: 76px 1fr;
  column-gap: 24px;
  position: relative;
}

.managed-steps__item:not(:last-child) {
  margin-bottom: 40px;
}

.managed-steps__badge {
  position: relative;
  z-index: 1;
  justify-self: center;
  align-self: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  background: #6574e8;
  color: #ffffff;
  font-family: "Barlow", sans-serif;
  font-size: 16px;
  font-weight: 700;
  border-radius: 5px;
}

.managed-steps__step-title {
  font-size: 20px;
  font-weight: 700;
  margin: 4px 0 8px;
}

.managed-steps__text {
  font-size: 15px;
  margin: 0;
}

.managed-steps__btn.btn-more-link {
  width: auto;
  max-width: none;
  height: 52px;
  padding: 0 28px;
  margin: 16px 0 0;
  border: 2px solid #6574e8;
}

/* managed専用でオーバーライド */
.btn-more-link {
  border: 2px solid #6574e8;
  color: #6574e8;
  &:hover,
  &:focus-visible {
    background-color: #6574e8;
  }
  &::after {
    background: url("../../img/common/icon_arrow-violet.svg") center / contain
      no-repeat;
  }
}

.managed-steps__btn.managed-pricing__btn {
  max-width: none;
  margin: 16px 0 0;
  font-size: 20px;
}

.managed-consultation {
  background: #ffffff;
  text-align: center;
  img {
    display: inline;
  }
  .sp {
    display: none;
  }
  @media (max-width: 768px) {
    .pc {
      display: none;
    }
    .sp {
      display: initial;
    }
  }
}

.managed-trial-top-cta {
  background-color: white;
}

.managed-subpage-header {
  background-image: none;
  background-color: #6574e8;
}
