@charset "utf-8";
/* ---------------------- main -------------------------------- */

main {
  background-color: #f1f8ff;
  > .pageTitle {
    color: #132f56;
    display: grid;
    gap: 16px 0;
    width: 42.5%;
    padding-top: 64px;
    text-align: center;
    margin-inline: auto;
    > .ribbon {
      font-size: clamp(12px, 1.66vw, 32px);
      font-weight: bold;
      --r: 0.8em; /* control the ribbon shape */
      padding-inline: calc(var(--r) + 0.3em);
      line-height: 1.8;
      clip-path: polygon(
        0 0,
        100% 0,
        calc(100% - var(--r)) 50%,
        100% 100%,
        0 100%,
        var(--r) 50%
      );
      background-color: #8fd7ff;
    }
    > p {
      font-size: clamp(10px, 0.833vw, 16px);
    }
  }
}

section {
  margin-inline: auto;
  padding: 32px 0;
}

.mainContactBar {
  background-color: white;
  container: cq-mainContactBar / inline-size;
  padding: 42px 0;
  > .barContent {
    width: 73.95%;
    display: grid;
    gap: 16px 0;
    margin-inline: auto;
    padding-bottom: 32px;
    > h2 {
      color: #132f56;
      font-size: clamp(19px, 1.66vw, 32px);
      text-align: center;
    }
    > .contactBox {
      > a {
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 8px;
        white-space: nowrap;
      }
      > .phone {
        width: 32.18%;
        margin-inline: auto;
        color: #6dc300;
        > img {
          width: 19.25%;
        }
        > div {
          > p {
            &:first-of-type {
              font-size: clamp(32px, 2.5vw, 48px);
              font-weight: 700;
            }
            &:nth-of-type(2) {
              position: relative;
              font-size: clamp(14px, 1.25vw, 24px);
              &::after {
                position: absolute;
                top: 100%;
                left: 0;
                content: "(定休日) 日・祝";
                font-size: clamp(14px, 1.25vw, 24px);
              }
            }
          }
        }
      }
    }
  }
}
@container cq-mainContactBar (width < 900px) {
  .mainContactBar {
    > .barContent {
      margin-bottom: 0;
      > .contactBox {
        display: grid;
        > .phone,
        > .mail {
          width: 100%;
        }
      }
    }
  }
}

.mainLinkSection {
  padding: 128px 0;
  > .linkButtonBox {
    display: flex;
    justify-content: center;
    gap: 0 128px;
    > a {
      position: relative;
      width: 20%;
      padding: 8px 24px;
      border-radius: 100vmax;
      color: white;
      font-size: clamp(10px, 0.9375vw, 18px);
      font-weight: 600;
      text-align: center;
      &::after {
        position: absolute;
        content: "→";
        right: 12px;
      }
    }
    > .exampleButton {
      background-color: #8c67c7;
    }
    > .priceButton {
      background-color: #c767a1;
    }
  }
}

.mainContentSection {
  width: 60%;
  display: grid;
  gap: 64px 0;
  > .errorsBox {
    background-color: #dfdfdf;
    > li {
      font-size: clamp(12px, 0.833vw, 16px);
      padding: 8px;
      color: rgb(255, 109, 109);
      font-weight: bold;
    }
  }
  > form {
    display: grid;
    row-gap: 16px;
    > h4 {
      text-align: center;
      font-size: clamp(12px, 1.25vw, 24px);
    }
    > label,
    > input,
    > select,
    > span,
    > p {
      font-size: clamp(12px, 0.833vw, 16px);
      padding: 8px;
    }
    > .requiredMark::after {
      margin: 0 0 0 8px;
      content: "必須";
      padding: 0 6px;
      background-color: #ffab5e;
      color: white;
    }
    > p {
      &:nth-of-type(even) {
        background-color: #33333311;
      }
    }
    > .formButtonBox {
      display: flex;
      justify-content: center;
      gap: 32px;
      padding: 96px 0;
      > button {
        width: fit-content;
        padding: 12px 24px;
        background-color: #4c7fcb;
        color: white;
        border-style: none;
        border-radius: 5px;
        font-size: clamp(12px, 1.25vw, 24px);
        cursor: pointer;
      }
    }
  }
  > #sendDoneMessage {
    text-align: center;
    font-size: clamp(12px, 1.25vw, 24px);
  }
  > #sendDoneMessage2 {
    text-align: center;
    font-size: clamp(12px, 1.25vw, 24px);
  }
}

/* --------------------- マウスホバー ---------------------- */
/* transition */
:is(.phone, .mail).hoverScale {
  transition: scale 0.3s;
}
.linkButtonBox.hoverBgColor {
  > a {
    transition: opacity 0.3s;
  }
}
.formButtonBox.hoverBgColor {
  > button {
    transition: opacity 0.3s;
  }
}
/*  */
@media (any-hover: hover) {
  :is(.phone, .mail).hoverScale:hover {
    scale: 1.05;
  }
  .linkButtonBox.hoverBgColor {
    > a:hover {
      opacity: 0.8;
    }
  }
  .formButtonBox.hoverBgColor {
    > button:hover {
      opacity: 0.8;
    }
  }
}

/* メディアクエリ ////////////////////////////////*/
@media (width <= 520px) {
  main {
    background-color: revert;
    > .pageTitle {
      gap: 32px 0;
      width: 85%;
      padding-top: 32px;
    }
  }
  .mainContactBar:not(:last-child) {
    display: none;
  }
  .mainLinkSection {
    display: none;
  }
  .mainContentSection {
    width: 90%;
    row-gap: 16px;
  }
}
