/* main.css */

/* 共通スタイル */
body {
  background-color: #e0ecef;
  font-family: sans-serif;
  color: #16778f;
}

div.header{
  display: flex;
  align-items: center;
  justify-content: center;
}


/* Bootstrap のレスポンシブに合わせたい場合は .container への独自指定を減らす */
.container {
  text-align: center;
}

/* スタート画面の調整 */
header.container {
  margin: 0 !important;
}

/* ヘッダー画像・トップ画像のサイズ指定 */
.head-img, .front-img {
  max-width: 450px;
  height: auto;
  margin: 20px auto 20px auto;
}
.head-img{
  width: 85%;
}
.front-img {
  width: 70%;
  border-radius: 15px; /* お好みで値を調整（例: 50% にすると円形） */
}

.logo-container h2{
  margin: 0;
}

/* C-labロゴ用のフレキシブルデザイン */
.flex-logo {
  max-width: 100%;
  max-height: 150px;
  margin-top: 15px;
}

div.top-disp-area{
  text-align: center;
}

p.top-disp{
  max-width: 260px;
  margin: 10px 0 20px 0;
  text-align: left;
}

/* 質問部分 */
.question {
  font-size: 1.2rem;
}

div.question_header h1 {
  letter-spacing: 8px;
}

/* 選択肢レイアウト */
#options {
  display: flex;
  flex-direction: column; /* 子要素を縦に並べる */
  gap: 1rem;
  align-items: center;
  justify-items: center;
  width: 100%;
  margin: 20px 0;
}

/* カードスタイル */
.option-card {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  height: 200px;
  padding: 0.4rem;
  cursor: pointer;
  background-color: #ffffff;
  position: relative;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.5);
  border: 1px solid #bbb;
  border-radius: 8px;
}

.option-card:hover {
  transform: translateY(-2px);
}

/* ラジオボタンを非表示にしてカスタムデザイン */
.option-card input[type="radio"] {
  display: none;
}

.option-card img {
  width: auto;
  height: 80%;
  object-fit: contain;
  margin-bottom: 0.5rem;
  transition: transform 0.3s;
}

.option-card:hover img {
  transform: scale(1.05);
}

.option-text {
  font-size: 1rem;
  color: #16778f;
  width: 90%;
  padding-top: 2px;
  border-radius: 8px 8px 8px 8px;
}

/* 選択状態のカード */
.option-card input[type="radio"]:checked ~ .option-text {
  color: #ff5500;
}

.result-header{
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.line-title {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 20px !important;
  margin-bottom: 10px !important;
  width: 30%;
}

/* 中央の文字（span）の左右に余白を取る */
.line-title span {
  margin: 0 16px;
}

/* 疑似要素で左右の線を作る */
.line-title::before,
.line-title::after {
  content: "";
  flex: 1;                        /* 余ったスペースを線で埋める */
  border-bottom: 1px solid #16778f;  /* 下線を引くイメージで線を作成 */
}

.result-parent{
  display: flex;
  align-items: center;
  justify-content: center;
}

.result-div{
  padding: 1.5rem !important;
  max-width: 875px;;
}

.result-div p{
  padding: 0 1rem 0 1rem;
}

/* ボタン類 */
.button-group {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 20px;
}

#startBtn, #contactBtn{
  color: #fff;
  background: linear-gradient(to bottom, #2193b0, #2d9dba);
}

.btn {
  width: 220px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.2);
  border: 1px solid #bbb;
  border-radius: 4px;
}

#startBtn span {
  position: relative;
  top: -4px;
}

.btn:hover {
  transform: translateY(-2px);
  color: #333;
  border: 1px solid #bbb;
  border-radius: 4px;
}

.btn:active {
  /* ボックスシャドウを小さく、または無くす */
  box-shadow: 0 2px 0 #6bab57;
  /* 少し下に移動して押し込まれた感じを出す */
  transform: translateY(2px);
}

.btn-secondary{
  background: linear-gradient(to bottom, #f0f0f0, #dcdcdc);
  color: #333;
}

div.question_header {
  margin-top: 1rem;
}

.line-title span{
  font-size: 1.8rem;
  margin: 10px;
  font-weight: normal;
}

.result-image{
  max-height: 380px;
}

/* 結果表示 */
.result {
  margin-top: 30px;
  padding: 30px;
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  text-align: center;
}

.result strong {
  font-size: 2rem;
  color: #28a745;
}

div.resultbox{
  padding: 90px 20px 30px 20px;
}

h2.result-title1{
  margin-top: 10px;
  font-size: 1.4rem;
  color: #fff;
  background-color: #2798b5;
  padding: 15px 0 15px 0;
  margin-bottom: 30px;
  text-align: center;
}

h2.result-title2{
  margin-top: 10px;
  font-size: 1.5rem;
  color: #452a1c;
  padding: 15px 0 15px 25px;
  margin-bottom: 30px;
  border-left: 2px solid #452a1c;
  text-align: left;
}

.shadow {
  box-shadow: 0 .5rem 1rem rgba(0, 0, 0, 0.15) !important;
}

.rounded-sm {
  border-radius: 0.3rem !important;
}


.rounded {
  border-radius: 1.5rem !important;
}

.option-card {
  height: 50px;
  max-width: 850px;
}
.option-card img {
  display: none;
}

/* 768px未満の場合 */
@media (max-width: 379px) {
  div.question h2 {
    font-size: 1.5rem;
  }
  div.question_header h2{
    font-size: 2.3rem;
  }
  div.question_header h1 {
    font-size: 3.8rem;
  }

  .option-text {
    font-size: 0.9rem! important;
  }

  .line-title {
    width: 55%;
  }
}

/* 768px未満の場合 */
@media (min-width: 380px) and (max-width: 767px) {
  div.question h2 {
    font-size: 1.5rem;
  }
  div.question_header h2{
    font-size: 2.3rem;
  }
  div.question_header h1 {
    font-size: 3.8rem;
  }
  .line-title {
    width: 45%;
  }
}

/* 768px以上 991px以下の場合 */
@media (min-width: 768px) and (max-width: 991px) {
  #options {
    grid-template-columns: repeat(2, minmax(167px, 1fr));
  }
  div.question h2 {
    font-size: 2rem;
  }
  div.question_header h2{
    font-size: 3rem;
  }
  div.question_header h1 {
    font-size: 5rem;
  }

  .option-text {
    font-size: 1.1rem;
  }
  .line-title {
    width: 35%;
  }
}

/* 992px以上 1199px以下の場合 */
@media (min-width: 992px) and (max-width: 1199px) {
  div.question h2 {
    font-size: 2rem;
  }
  div.question_header h2{
    font-size: 3rem;
  }
  div.question_header h1 {
    font-size: 5rem;
  }
   .option-text {
    font-size: 1.3rem;
  }
  .line-title {
    width: 30%;
  }
}

/* 1200px以上 1399px以下の場合 */
@media (min-width: 1200px) and (max-width: 1399px) {
  div.question h2 {
    font-size: 2rem;
  }
  div.question_header h2{
    font-size: 3rem;
  }
  div.question_header h1 {
    font-size: 5rem;
  }
  .option-text {
    font-size: 1.5rem;
  }
  .line-title {
    width: 25%;
  }
}

/* 1400px以上の場合 */
@media (min-width: 1400px) {
  div.question h2 {
    font-size: 2rem;
  }
  div.question_header h2{
    font-size: 3rem;
  }
  div.question_header h1 {
    font-size: 5rem;
  }

  .option-text {
    font-size: 1.6rem;
  }
  .line-title {
    width: 20%;
  }
}

p.left{
  text-align: left;
}