/* =========================================================
 事例_下層
 ========================================================= */

/* base */
body {
  margin: 0;
}
p {
  margin: 5px 0;
}
a {
  text-decoration: none !important;
}
table td {
  font-size: 16px;
}
td:nth-child(1) {
  text-align: right;
  padding-right: 15px;
}

@media (min-width: 576px) {
  .case_info,
  .case_contents,
  .case_other {
    margin: 0 80px;
  }
}

/* ===== Case: content max width 1180 (exclude FV and CTA) ===== */
.case_info,
.case_contents,
.case_other {
  max-width: 1180px; /* content width (padding除く) */
  box-sizing: content-box; /* 合計幅 = 内容幅 + padding */
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}
@media (min-width: 993px) {
  .case_info,
  .case_contents,
  .case_other {
    padding-left: 80px;
    padding-right: 80px;
  }
}

/* ---------------------------------
  case_info
---------------------------------- */
section.case_info {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
}
p.case_info_title--Num {
  margin: 0;
  color: #f29600;
  font-weight: bold;
  font-size: 24px;
}
.case_info--flex {
  line-height: normal;
}
.case_info--flex h3 {
  font-size: 40px;
  margin: 0;
}
p.case_info_company_title {
  text-align: right;
  font-size: 20px;
  font-weight: bold;
}
.case_info_company--under {
  border: solid 1px #000000;
  width: 250px;
}

/* ---------------------------------
  case_contents
---------------------------------- */
.case_contents_box {
  margin-top: 120px;
  display: flex;
}
.case_contents__box_img img {
  object-fit: cover;
  width: 320px;
  height: 350px;
  overflow: hidden;
  clip-path: polygon(0 10%, 100% 0, 100% 90%, 0% 100%);
  display: block;
}
.case_contents_box_text {
  margin-left: 50px;
}
p.case_contents_box_text-ttl {
  font-size: 28px;
  font-weight: bold;
  padding: 5px 0;
}
p.case_contents_box_text-ttl span {
  font-size: 24px;
}
.case_contents_box_text
  > p.case_contents_box_text-ttl
  + p.case_contents_box_text-maintxt
  + p.case_contents_box_text-ttl {
  margin-top: 16px;
}

.case_contents_box_text-maintxt,
.case_contents_box_text-maintxt p {
  line-height: normal;
  font-size: 16px;
}

.case_contents_box_text-maintxt--bold {
  font-weight: bold;
  font-size: 16px;
}

/* reverse レイアウト */
.case_contents_box--reverse {
  flex-direction: row-reverse;
  align-items: end;
  margin-top: 60px;
}
.case_contents_box--reverse .case_contents_box_text {
  margin: 0 50px 0 0;
}

/* ---------------------------------
  コメントブロック
---------------------------------- */
.case_contents_box_comment {
  margin-top: 80px;
  background: #fffaf4;
  padding: 20px 40px;
}
.case_contents_box_comment--flex {
  display: flex;
}
.case_contents_box_comment--left {
  width: 180px;
}
p.case_contents_box_comment--left-ttl {
  font-size: 24px;
  font-weight: bold;
}
p.case_contents_box_comment--left-name {
  font-size: 20px;
  font-weight: bold;
  margin: 7px 0 0 0;
}
p.case_contents_box_comment--left-position {
  color: #7f7f7f;
  font-size: 16px;
  font-weight: bold;
}
.case_contents_box_comment--right {
  border-left: solid 1px #f29600;
  padding-left: 20px;
}
p.case_contents_box_comment--right-ttl {
  font-size: 20px;
  font-weight: bold;
}
p.case_contents_box_comment--right-txt {
  font-size: 16px;
}

/* ---------------------------------
  case_other （見出し）
---------------------------------- */
section.case_other {
  margin-top: 100px;
}
p.case_other-ttl {
  font-size: 32px;
  font-weight: bold;
  color: #f29600;
}

/* =========================================================
 事例_下層_その他の事例（topと同じCSS）
 ========================================================= */
.main_case_contents_box_sub {
  display: flex;
  margin: 40px 0px;
  justify-content: center;
}
.main_case_contents_box_sub img {
  width: 335px;
  height: 260px;
  object-fit: cover;
  clip-path: polygon(0 15%, 100% 0, 100% 85%, 0% 100%);
  display: block;
  transition: transform 0.3s ease-in-out;
}
.case_contents_box_img img {
  width: 341px;
  height: 423px;
  object-fit: cover;
  clip-path: polygon(0 10%, 100% 0, 100% 90%, 0% 100%);
  display: block;
  max-width: none;
}

.main_case_contents_box_img a {
  display: inline-block;
}
.main_case_contents_box_img a:hover img {
  transform: scale(1.1);
  object-fit: cover;
}

.main_case_contents_box_sub--flex {
  margin: 10px;
}
.main_case_contents_box_sub--flex:nth-child(1) {
  transform: translateY(0);
}
.main_case_contents_box_sub--flex:nth-child(2) {
  transform: translateY(-42px);
}
.main_case_contents_box_sub--flex:nth-child(3) {
  transform: translateY(-84px);
}

.main_case_contents_box_sub_text p {
  margin: 10px 0 0px;
  font-size: 20px;
  font-weight: bold;
}
.main_case_contents_box_sub_tag-area {
  display: flex;
}

.tag {
  border: 1px solid #000;
  margin: 10px 8px 0 0;
  display: inline-block;
}
.tag p {
  font-size: 14px;
  font-weight: bold;
  padding: 4px 8px;
  margin: 0 !important;
}

.main_case__contents_button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: #000;
  padding: 4px 0;
  border: none;
  float: right;
}
.main_case__contents_button::after {
  content: "";
  display: inline-block;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: #f29600;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 10px;
  /* inline SVG: right chevron */
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><polyline points='9 6 15 12 9 18'/></svg>");
}

/* =========================================================
 事例_下層_お問い合わせ（topと同じCSS）
 ========================================================= */
section.main_contact {
  background: #f29600;
  margin-top: 330px;
  padding-bottom: 70px;
  width: 100%;
  position: relative;
  z-index: 0;
}
.main_contact::before {
  content: "";
  position: absolute;
  inset: auto -10% 0 0%;
  height: 270px;
  background: #f29600;
  transform: skewY(-6deg);
  transform-origin: left bottom;
  z-index: -1;
  width: 100%;
}
.main_contact::after {
  content: "";
  position: absolute;
  top: -55%;
  left: -12%;
  width: 65vw;
  height: 170px;
  background: #e8641f;
  clip-path: polygon(0 0, 10% 0, 138% 70%, 0 55%);
  z-index: -2;
}
.main_contact_contents {
  margin: 150px 90px 0;
  color: #fff;
  display: flex;
  align-items: baseline;
}
.main_contact_contents_textbox {
  width: 60%;
}
.main_contact_contents_textbox_title p {
  font-size: 48px;
  font-weight: bold;
  margin: 10px 0;
}
.main_contact_contents_textbox_text p {
  font-size: 16px;
}

.main_contact_contents_contact-area_box {
  background: #fff;
  font-weight: bold;
  padding: 10px 60px 10px 20px;
  margin: 10px;
  border-radius: 40px;
  position: relative;
}
.main_contact_contents_contact-area_box p {
  margin: 5px;
}

.buy {
  color: #f29600 !important;
}
.sell {
  color: #1a3261 !important;
}

.buy::after,
.sell::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 8px;
  width: 35px;
  height: 35px;
  transform: translateY(-50%);
  background-repeat: no-repeat;
  background-size: contain;
  background-position: center;
  border-radius: 50%;
  pointer-events: none;
  transition: transform 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
  will-change: transform;
}
.buy::after {
  background-image: url("/Users/森川詩音/Studio/ma/wp-content/uploads/img/contact_buy.png");
}
.sell::after {
  background-image: url("/Users/森川詩音/Studio/ma/wp-content/uploads/img/contact_sell.png");
}

.buy:hover::after,
.sell:hover::after {
  transform: translateY(-50%) translateX(-14px);
}

/* =========================================================
   Responsive
 ========================================================= */

/* ≤ 992px */
@media (max-width: 992px) {
  .main_features_contents__box,
  .main_service_contents_box,
  .main_case_contents_box,
  .main_contact_contents {
    flex-direction: column;
  }

  .main_features_contents img,
  .main_service_contents_box img,
  .main_case_contents_box_img img {
    width: 100%;
    height: auto;
  }

  .main_features_contents__box_text,
  .main_features_contents__box_text--reverse,
  .main_service_contents_box_text,
  .main_service_contents_box_text--reverse {
    margin: 20px !important;
  }

  .main_service_contents_consulting_all_flex {
    flex-wrap: wrap;
  }
  .main_service_contents_consulting_all__flex_box {
    width: calc(50% - 32px);
  }
  .main_faq_contents {
    width: 85%;
  }
  .main_contact_contents_textbox {
    width: 100%;
  }

  section.case_info {
    display: block;
  }
  .case_info_company {
    justify-items: right;
    margin-top: 30px;
  }
}

/* ≤ 576px */
@media (max-width: 576px) {
  .br-sp {
    display: inline;
  }
  .case_info,
  .case_contents,
  .case_other {
    margin: 0;
    padding: 0;
  }

  .main_visual_child {
    position: relative;
    overflow: hidden;
    aspect-ratio: 6 / 2;
    margin-top: 40px;
  }
  .main_visual_child img {
    position: absolute;
    top: 0;
    left: 50%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 10%;
    transform-origin: top center;
    transform: translateX(-50%) scale(1);
  }

  section.case_info {
    margin: 0 20px;
  }
  p.case_info_title--Num {
    font-size: 16px;
  }
  .case_info--flex h3 {
    font-size: 24px;
  }
  p.case_info_company_title {
    font-size: 15px;
  }
  table td {
    font-size: 14px;
  }

  .case_contents_box {
    margin-top: 50px;
    display: block;
  }
  .case_contents_box_img {
    width: 100%;
    margin-top: 50px;
  }
  .case_contents_box_img img {
    width: 100%;
    height: 210px;
    clip-path: polygon(0 20%, 100% 0, 100% 80%, 0% 100%);
  }
  .case_contents_box_text {
    margin: 0 20px;
  }
  .case_contents_box_text
    > p.case_contents_box_text-ttl
    + p.case_contents_box_text-maintxt
    + p.case_contents_box_text-ttl {
    margin-top: 25px;
  }
  p.case_contents_box_text-ttl {
    font-size: 20px;
  }
  p.case_contents_box_text-ttl span {
    font-size: 17px;
  }
  p.case_contents_box_text-maintxt {
    font-size: 15px;
  }

  .case_contents_box--reverse {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
  }
  .case_contents_box--reverse .case_contents_box_text {
    margin: 0 20px;
  }

  .case_contents_box_comment {
    margin-top: 60px;
  }
  .case_contents_box_comment--flex {
    display: block;
  }
  .case_contents_box_comment--left {
    display: flex;
    align-items: baseline;
    width: 100%;
    margin-bottom: 5px;
  }
  p.case_contents_box_comment--left-ttl {
    width: 25%;
    font-size: 16px;
  }
  p.case_contents_box_comment--left-name {
    width: 35%;
  }
  p.case_contents_box_comment--left-position {
    width: 40%;
    font-size: 14px;
  }
  .case_contents_box_comment--right {
    border-top: solid 1px #f29600;
    border-left: none;
    padding: 5px 0;
  }
  p.case_contents_box_comment--right-ttl {
    font-size: 16px;
  }
  p.case_contents_box_comment--right-txt {
    font-size: 15px;
  }

  section.case_other {
    margin-top: 60px;
  }
  p.case_other-ttl {
    font-size: 20px;
    margin: 0 20px;
  }
  .main_case_contents_box_sub--flex {
    margin: 10px 20px 20px 20px;
  }

  .main_case_title {
    margin: 80px 24px;
  }
  .main_case_title p {
    font-size: 32px;
  }
  .main_case_contents_box_text {
    margin: 0 20px;
  }
  .main_case_contents_box_text p {
    font-size: 20px;
  }
  .tag p {
    font-size: 10px;
  }

  .main_case_contents_box_sub {
    margin: 0 20px;
    max-width: 100%;
    display: flex;
    justify-content: center;
    flex-direction: column;
  }
  .main_case_contents_box_sub_text {
    font-size: 20px;
  }
  .main_case_contents_box_sub--flex:nth-child(2) {
    transform: none;
  }
  .main_case_contents_box_sub--flex:nth-child(3) {
    transform: none;
  }
  .main_case_contents_box_sub--flex:nth-child(4) {
    transform: none;
  }

  section.main_contact {
    margin-top: 120px;
  }
  .main_contact_contents {
    margin: 100px 24px 0;
  }
  .main_contact_contents_textbox_title p {
    font-size: 32px;
  }
  .main_contact_contents_contact-area {
    width: 100%;
    padding-top: 10px;
  }

  .main_contact::before {
    height: 330px;
  }
  .main_contact::after {
    top: -14%;
    width: 54vw;
    clip-path: polygon(0 0, 20% 0, 348% 70%, 0 55%);
  }
}

/* Case04 image: bleed to right edge on desktop */
@media (min-width: 993px) {
  .case_contents_box--reverse .case_contents_box_img {
    position: relative;
    overflow: visible;
  }
}
/* 1340px(=1180+160)以上の時だけ右端までブリード */
@media (min-width: 1340px) {
  .case_contents_box--reverse .case_contents_box_img img[src$="case04.jpg"] {
    width: 100%;
    height: auto;
    object-fit: cover;
    object-position: center;
    display: block;
    margin-right: calc((100vw - 1340px) / -2);
  }
}

/* Cases: 3-column equal widths on desktop */
@media (min-width: 993px) {
  .main_case_contents_box_sub {
    display: flex;
    flex-wrap: nowrap;
    gap: 24px;
    padding: 0;
    box-sizing: border-box;
  }
  .main_case_contents_box_sub--flex {
    flex: 0 0 calc((100% - 48px) / 3);
    max-width: calc((100% - 48px) / 3);
    margin: 0;
  }
  .main_case_contents_box_sub img {
    width: 100%;
    height: auto;
    display: block;
  }
}
/* Tablet: 2 columns */
@media (min-width: 577px) and (max-width: 992px) {
  .main_case_contents_box_sub {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
  }
  .main_case_contents_box_sub--flex {
    flex: 0 0 calc((100% - 16px) / 2);
    max-width: calc((100% - 16px) / 2);
  }
}
/* Phone: 1 column */
@media (max-width: 576px) {
  .main_case_contents_box_sub {
    display: block;
  }
}

/* 提供サービス（reverse）: テキスト50%・右余白解消 */
@media (min-width: 993px) {
  .case_contents_box--reverse {
    position: relative;
    align-items: center;
  }
  .case_contents_box--reverse .case_contents_box_text {
    flex: 0 0 50%;
    max-width: 50%;
  }
  /* 画像列をコンテンツ右パディング分だけ広げ、負のマージンで相殺して右端までフィット */
  .case_contents_box--reverse .case_contents_box_img {
    flex: 0 0 calc(50% + 80px);
    max-width: calc(50% + 80px);
    margin-right: -80px;
  }
  .case_contents_box--reverse .case_contents_box_img img {
    width: 100%;
    height: auto;
    object-fit: cover;
    object-position: center;
    display: block;
  }
}

.pan {
  margin-top: 9.3em;
}
