/* =============================================
   モバイルアプリ開発サービスページ（/mobile）
   ============================================= */

/* 共通 */
.service__container {
  display: flex;
  flex-direction: column;
  gap: 122px;
}

@media screen and (max-width: 767px) {
  .service__container {
    gap: 90px;
  }
}

.section.service__lead,
.section.service__features,
.section.service__graph,
.section.service__flow {
  width: 100%;
}

/* ---------------------------------------------
   リードセクション
--------------------------------------------- */
.service__lead {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 40px;
  box-sizing: border-box;
  padding: 40px 20px;
  border-radius: 20px;
}

.service__leadText {
  flex: 1 1 480px;
  position: relative;
  z-index: 1;
}

.service__leadHead {
  font-size: 28px;
  line-height: 1.4;
  margin-bottom: 24px;
  font-weight: 600;
}

.service__leadCopy {
  font-size: 16px;
  line-height: 200%;
}

.service__leadImage {
  flex: 1 1 320px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.service__leadImage img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 8px;
}

/* ---------------------------------------------
   特長セクション
--------------------------------------------- */

.service__featuresItems {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-top: 48px;
}

.service__featuresItem {
  flex: 1 1 calc(33.333% - 32px);
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-radius: 12px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  position: relative;
}

.service__featuresItem::after {
  bottom: 1.8%;
  color: #ed3131;
  display: block;
  font-size: 120px;
  font-weight: 600;
  opacity: 0.1;
  position: absolute;
  right: 3.5%;
  z-index: 0;
}
.service__featuresItem span {
  font-weight: bold;
}

.service__featuresItem--speed:nth-child(1)::after {
  content: "1";
}

.service__featuresItem--cost:nth-child(2)::after {
  content: "2";
}
.service__featuresItem:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.service__featuresItemIcon img {
  width: 56px;
  height: 56px;
  margin-bottom: 16px;
}

.service__featuresItemHead {
  font-size: 18px;
  text-align: left;
  font-weight: 600;
  margin-bottom: 12px;
  line-height: 1.5;
}

.service__featuresItemText {
  font-size: 16px;
  line-height: 200%;
  text-align: left;
}

.service__featureDetail {
  font-size: 16px;
  line-height: 2;
  letter-spacing: 0.05em;
  margin-top: 40px;
  text-align: left;
}

/* ---------------------------------------------
   3つのポイント
--------------------------------------------- */
.service__pointsItems {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-top: 48px;
}

.service__pointsItem {
  flex: 1 1 calc(33.333% - 32px);
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-radius: 12px;
  padding: 40px 28px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.service__pointsItem:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.service__pointsItemIcon img {
  width: 64px;
  height: 64px;
  margin-bottom: 20px;
}

.service__pointsItemHead {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 14px;
  color: #ed3131;
}

.service__pointsItemText {
  font-size: 16px;
  line-height: 200%;
  text-align: left;
}

/* ---------------------------------------------
   開発フロー
--------------------------------------------- */
.service__flowItems {
  display: flex;
  flex-direction: column;
  gap: 40px;
  margin-top: 64px;
  padding-top: 80px;
  padding-bottom: 80px;
  margin-left: auto;
  margin-right: auto;
}

@media screen and (max-width: 767px) {
  .service__flowItems {
    margin-top: 64px;
    padding-top: 0px;
    padding-bottom: 0px;
  }
}

.service__flowItem {
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-radius: 20px;
  padding: 32px 10px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  position: relative;
}

@media screen and (max-width: 767px) {
  .service__flowItem {
    width: 100%;
    box-sizing: border-box;
  }
}

.service__flowItem::after {
  bottom: 1.8%;
  color: #ed3131;
  display: block;
  font-size: 80px;
  font-weight: 600;
  opacity: 0.1;
  position: absolute;
  right: 3.5%;
  z-index: 0;
}
@media screen and (max-width: 767px) {
  .service__flowItem::after {
    font-size: 60px;
  }
}

.service__flowItem--1::after {
  content: "1";
}
.service__flowItem--2::after {
  content: "2";
}
.service__flowItem--3::after {
  content: "3";
}
.service__flowItem--4::after {
  content: "4";
}
.service__flowItem--5::after {
  content: "5";
}
.service__flowItem--6 {
  content: "6";
}

.service__flowItem:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.service__flowNum img {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
}

.service__flowHead {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 12px;
  text-align:left;
  color: #ed3131;
}

.service__flowText {
  font-size: 16px;
  line-height: 200%;
  text-align: left;
}

/* ---------------------------------------------
   レスポンシブ
--------------------------------------------- */
@media (max-width: 767px) {
  .service__lead {
    flex-direction: column;
  }

  .service__featuresItem {
    flex: 1 1 100%;
  }
  .service__flowItems {
    grid-template-columns: 1fr;
  }

  .service__pointsItem {
    flex: 1 1 100%;
  }
}

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

.service__cta .button {
  max-width: 100% !important;
  font-size: 32px !important;
  font-weight: bold !important;
  padding: 40px 0 !important;
  border-width: 5px !important;
}

@media screen and (max-width: 767px) {
  .service__cta .button {
    border-width: 3px !important;
  }
}

.service__cta .button:hover {
  letter-spacing: 0.6em;
}

.service__cta .button::before,
.service__cta .button::after {
  display: none !important;
}

@media screen and (max-width: 767px) {
  .service__cta .button {
    padding: 20px 10px !important;
    font-size: 16px !important;
  }
  .service__cta .button:hover {
    letter-spacing: 0.03em;
  }
}

/* ---------------------------------------------
   ナンバリング（開発フロー）
--------------------------------------------- */
.service__flowNum {
  width: 72px;
  height: 72px;
  margin: 0 auto 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.service__flowNum img {
  width: 40px;
  height: auto;
}

#other__service {
  margin-bottom: 180px;
}

.other__serviceContainer {
  display: flex;
  align-items: center;
  gap: 40px;
}

@media screen and (max-width: 767px) {
  .other__serviceContainer {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }
}

.other__serviceTitle {
  font-size: 20px;
  font-weight: bold;
  letter-spacing: 0.05em;
  color: #000;
}

.other__serviceItems {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

@media screen and (max-width: 767px) {
  .other__serviceItems {
    flex-direction: column;
    align-items: flex-start;
  }
}

.other__serviceItem a {
  display: block;
  padding: 20px 20px;
  font-size: 18px;
  font-weight: 600;
  color: #505050;
  text-align: center;
  border: 1px solid #ed3131;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
  text-decoration: none;
  transition: all 0.3s ease;
}

@media screen and (max-width: 767px) {
  .other__serviceItem a {
    padding: 15px 15px;
    font-size: 16px;
  }
}

.other__serviceItem a:hover {
  background-color: #ed3131;
  color: #fff;
  transition: all 0.3s ease;
}

@media screen and (max-width: 767px) {
  .service__lead {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
  }

  .service__leadText {
    flex: 1 1;
  }

  .service__leadHead {
    font-size: 20px;
    line-height: 1.4;
    margin-bottom: 12px;
    font-weight: 600;
  }

  .service__leadCopy {
    font-size: 16px;
    line-height: 200%;
  }

  .service__leadImage {
    flex: 1 1;
    text-align: center;
  }

  .service__leadImage img {
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 8px;
  }

  /* ---------------------------------------------
         特長セクション
      --------------------------------------------- */
  .service__featuresItems {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    margin-top: 48px;
  }

  .service__featuresItem {
    flex: 1 1 calc(33.333% - 32px);
    position: relative;

    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 12px;
    padding: 32px 24px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  }

  .service__featuresItem:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  }

  .service__featuresItemIcon img {
    width: 56px;
    height: 56px;
    margin-bottom: 16px;
  }

  .service__featuresItemHead {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
  }

  .service__featuresItemText {
    font-size: 16px;
    line-height: 200%;
  }

  /* ---------------------------------------------
         3つのポイント
      --------------------------------------------- */
  .service__pointsItems {
    display: flex;
    flex-wrap: wrap;
    gap: 32px;
    margin-top: 48px;
  }

  .service__pointsItem {
    flex: 1 1 calc(33.333% - 32px);
    position: relative;

    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 12px;
    padding: 20px 28px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  }

  .service__pointsItem:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  }

  .service__pointsItemIcon img {
    width: 64px;
    height: 64px;
    margin-bottom: 20px;
  }

  .service__pointsItemHead {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 14px;
  }

  .service__pointsItemText {
    font-size: 16px;
    line-height: 200%;
  }

  /* ---------------------------------------------
         レスポンシブ
      --------------------------------------------- */
  @media (max-width: 767px) {
    .service__lead {
      flex-direction: column;
    }

    .service__featuresItem {
      flex: 1 1 100%;
    }

    .service__flowItems {
      grid-template-columns: 1fr;
    }

    .service__pointsItem {
      flex: 1 1 100%;
    }
  }

  /* ---------------------------------------------
         ナンバリング（開発フロー）
      --------------------------------------------- */
  .service__flowNum {
    width: 72px;
    height: 72px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  }

  .service__flowNum img {
    width: 40px;
    height: auto;
  }
}

.service__featuresItemsWrapper,
.service__pointsItemsWrapper,
.service__flowItemsWrapper {
  margin-top: 60px;
}

/* 3つのポイント：PC では必ず3列 */
@media (min-width: 768px) {
  .service__pointsItems {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }
}

/* =============================================
   開発フロー：タイムライン（中央線＋左右交互）
   ============================================= */
@media (min-width: 768px) {
  /* 親 ol に中央線 */
  .service__flowItems {
    /* 既存の grid 設定を打ち消し */
    display: block;
    position: relative;
    max-width: 900px;
  }
  .service__flowItems::before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 12px; /* 中央線を太く */
    height: 100%;
    background: #ed3131; /* 線色：アクセント */
  }

  /* 各ステップ */
  .service__flowItem {
    width: 43%;
    padding: 20px 32px;
    box-sizing: border-box;
  }

  /* 番号アイコンを中央に寄せる */
  .service__flowNum {
    position: absolute;
    top: 0;
    right: -36px; /* 奇数側：中央線に重ねる */
    z-index: 2;
  }

  /* アイコンを非表示 */
  .service__flowNum {
    display: none !important;
  }
}

/* === タイムライン調整 === */
.service__flowItem {
}
.service__flowItem:nth-child(odd) {
  margin-right: auto;
}
.service__flowItem:nth-child(even) {
  margin-left: auto;
}

ol,
ul {
  list-style: none;
}

/* ===================================================
   Estimate Simulator Styles
   =================================================== */
.estimate {
  margin: 0px auto 30px;
  max-width: 1000px;
  padding: 0 20px;
  box-sizing: border-box;
  width: 100%;
}

.estimate #contact {
  padding-bottom: 0;
}

.estimate__card {
  padding: 48px 40px;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}
.estimate__card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.08);
}

.estimate__title {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 32px;
  text-align: center;
  position: relative;
}
.estimate__title::after {
  content: "";
  width: 60px;
  height: 4px;
  background: #ed3131;
  position: absolute;
  left: 50%;
  bottom: -10px;
  transform: translateX(-50%);
  border-radius: 2px;
}

/* form rows */
.estimate__row {
  margin-bottom: 34px;
}
.estimate__row .estimate__label {
  font-size: 18px;
  font-weight: 600;
  display: block;
  margin-bottom: 10px;
  color: #333;
}

/* slider */
input[type="range"]#pagesRange {
  width: 100%;
  accent-color: #ed3131;
}
.estimate__sliderValue {
  font-size: 18px;
  font-family: monospace;
  color: #ed3131;
  font-weight: 700;
}

/* radios */
.estimate__radios {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.estimate__radios .estimate__label {
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* checkboxes row */
.estimate__row--check {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
@media (min-width: 576px) {
  .estimate__row--check {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .estimate__row--check .estimate__label {
    flex: 1 1 45%;
  }
}

/* breakdown */
.estimate__breakdown {
  list-style: none;
  padding: 0;
  margin: 32px 0 24px;
  border-top: 1px solid #e6e6e6;
  font-size: 16px;
}
.estimate__breakdown li {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px dashed #e6e6e6;
}

/* total */
.estimate__total {
  font-size: 24px;
  font-weight: 700;
  text-align: right;
  color: #ed3131;
  position: relative;
  z-index: 1;
}

/* responsive */
@media (max-width: 767px) {
  .estimate__card {
    padding: 32px 24px;
  }
  .estimate__title {
    font-size: 20px;
  }
}

/* custom radio & checkbox */
.estimate input[type="radio"],
.estimate input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-width: 3px;
  margin: 0;
  cursor: pointer;
  position: relative;
  display: inline-block;
  vertical-align: middle;
  background: #fff;
  transition: all 0.2s ease;
}
.estimate input[type="radio"] {
  border-radius: 50%;
}
.estimate input[type="checkbox"] {
  border-radius: 4px;
}

/* radio checkmark */
.estimate input[type="radio"]:checked::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ed3131;
}

/* checkbox checkmark */
.estimate input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 0;
  width: 7px;
  height: 12px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.estimate input[type="checkbox"]:checked {
  background: #ed3131;
  border-color: #ed3131;
}

/* spacing between custom control and .estimate__label text */
.estimate .estimate__label {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* fix alignment for custom control .estimate__labels */
.estimate__radios .estimate__label,
.estimate__row--check .estimate__label {
  display: flex;
  align-items: center;
  gap: 10px;
  line-height: 1.4;
  font-size: 17px;
}

@media screen and (max-width: 767px) {
  .estimate__radios .estimate__label,
  .estimate__row--check .estimate__label {
    font-size: 14px;
  }
}

/* provide space between control and text */
.estimate input[type="radio"],
.estimate input[type="checkbox"] {
  flex-shrink: 0;
}

/* consistent border for custom controls */
.estimate input[type="radio"],
.estimate input[type="checkbox"] {
  border: 2px solid #ed3131;
}
.estimate input[type="radio"]:checked,
.estimate input[type="checkbox"]:checked {
  border-color: #ed3131;
}

/* restore white background for unchecked checkbox */
.estimate input[type="checkbox"] {
  background: #fff;
}

.estimate__cta {
  text-align: center;
  margin-top: 40px;
}
.estimate__cta .button {
  font-size: 22px !important;
  padding: 18px 0 !important;
  max-width: 100% !important;
  font-weight: bold;
  box-sizing: border-box;
}

@media screen and (max-width: 767px) {
  .estimate {
    padding: 0;
  }
  .estimate__cta .button {
    font-size: 16px !important;
    box-sizing: border-box;
  }
}

.estimate__cta .button::before,
.estimate__cta .button::after {
  display: none !important;
}

.estimate__cta .button:hover {
  letter-spacing: 0.5em;
}

.contact__form--serivce {
  padding-top: 120px !important;
}

@media screen and (max-width: 767px) {
  .contact__form--serivce {
    padding-top: 90px !important;
  }
}
