/* ===============================
   タイトル画像
=============================== */
/*タイトル背景画像*/
.title-area{
  
  height:20vh;   /*画面の20% */
  min-height:180px; /*小さくなりすぎ防止*/


  background-image:url("../pic2026/data1.png");
  background-size:cover;
  background-position:center;

  display:flex;
  align-items:center;
  padding-left:10%;

  margin-top:80px;
}

/*タイトルの文字*/
.title-area h1{
  color:#008080;
  font-size:clamp(22px, 5vw, 32px);
  font-family: "Noto Serif JP", serif;
}

/* ===============================
   スマホ対応タイトル画像
=============================== */

@media (max-width: 1024px){

  /* タイトル画像縮小 */
  .title-area{
    height:13vh;
    min-height:100px;

    background-image:url("../pic2026/data2.png"); /* スマホ用画像 */
    background-position:center;/* 中央に */

    justify-content:center;
    padding-left:0;           /* 左余白消す */
    text-align:center;        /* 文字中央 */

  }
}

/* ===============================
   メインコンテンツ
=============================== */
/* メインコンテンツ */
.content{
  flex:1;
  padding:40px;
}

/* タイトル */
h2{
  color:#0D716E;
  font-size:clamp(22px, 5vw, 32px);
  margin:20px 0;
  text-align: center;
  font-family: "Noto Serif JP", serif;
}

/* タイトル内タイトル */
h3{
  color:#5C2408;
  font-size: clamp(18px, 4vw, 26px);
  margin-bottom:10px;
  text-align: center;
}

/* テキスト */
p{
  color:#5C2408;
  font-size:clamp(14px, 2.5vw, 18px);
  text-align: center;
}

/* 黄色のボックス */
.content-box{
  background: rgba(255, 246, 133, 0.3);/* #FFF685を30%透過 */
  border:4px double #FFF685;/* 二重線 */
  border-radius:12px;

  padding:20px;
  margin:20px auto;
  width:min(90%, 800px);
  
  scroll-margin-top: 100px;
}

.graph {
  max-width: 100%;
  height: auto;
  display: block;
  flex-shrink: 0;

}

/*content-boxの中のドット背景*/
.inner-box {
  background:
    radial-gradient(
      circle,
      rgba(0, 0, 0, 0.1) 1px,
      transparent 1px
    ),
    #ffffff;                  /*白の上にドット*/

  background-size: 14px 14px; /* ドット間隔 */

  padding: 25px;
  border-radius: 12px;
  margin-top: 15px;

  /*少しカード感を出す*/
  box-shadow: 0 4px 8px rgba(0,0,0,0.08);

  /*中身レイアウト用*/
  display: flex;
  flex-direction: column;
}

/*ノートの方眼紙背景*/
.inner-box-note {
  background:
    /*横線*/
    linear-gradient(#e6e6e6 1px, transparent 1px),
    /*縦線*/
    linear-gradient(90deg, #e6e6e6 1px, transparent 1px),
    #ffffff;

  background-size: 20px 20px; /*方眼サイズ*/

  
  padding: 20px;

  border-radius: 12px;
  margin-top: 15px;

  box-shadow: 0 4px 8px rgba(0,0,0,0.08);

  display: flex;
  flex-direction: column;
}

/*横並びの親*/
.chat-group {
  display: flex;
  align-items: flex-start; /*上揃え*/
  margin-bottom: 8px;
}

/*左側：アイコンと吹き出しの間に隙間*/
.chat-group:not(.right) .bubble-group {
  margin-left: 20px;
}

/*アイコン側*/
.face-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 90px;
}

/*アイコンを大きめに*/
.face {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  border:4px solid #FFF685;
}

.right .face{
  border-color: rgba(105,196,208,0.5);
}

/*名前*/
.name {
  font-size: 12px;
  margin-top: 5px;
  text-align: center;
}

/*吹き出しの縦並び*/
.bubble-group {
  display: flex;
  flex-direction: column;
  gap: 8px; /*隙間*/
  align-items: flex-start;

}

/*吹き出し*/
.bubble {
  display: inline-block;
  max-width: 100%;
  padding: 12px;
  border-radius: 15px;
  position: relative;
  background: rgba(255, 246, 133, 0.3);
}

/*三角*/
.bubble::before {
  content: "";
  position: absolute;
  left: -20px;
  top: 15px;
  border: 10px solid transparent;
  border-right-color: rgba(255, 246, 133, 0.3);
}

.right {
  justify-content: flex-end;
}

.right .bubble-group {
  align-items: flex-end;
}

.right .bubble {
  background: rgba(105,196,208,0.3);
  margin-right: 20px;
}

/*三角を右に*/
.right .bubble::before {
  content: "";
  position: absolute;
  left: auto;              /*左指定を無効化*/
  right: -20px;            /*右側に出す*/
  top: 15px;
  border: 10px solid transparent;
  border-right-color: transparent; /*左用色を消す*/
  border-left-color: rgba(105,196,208,0.3);
}

.sp-br{
  display: none;
}

/* ===============================
   スクロール調整
=============================== */
html{
  scroll-behavior:smooth;
}

h2,h3,.content-box{
  scroll-margin-top:100px;
}

/* ===============================
   dataのみに適応
=============================== */

@media (max-width:768px){
  
  .content-box{
    width:100%;
    padding: 5px;
  }

  .inner-box-note {
    padding: 0px;
  }

  /*左側アイコンと吹き出しを近づける*/
  .chat-group:not(.right) .bubble-group {
    margin-left: 6px;
  }

  /*右側吹き出しとアイコンを近づける*/
  .right .bubble {
    margin-right: 6px;
  }

  /*吹き出し全体を少し小さく*/
  .bubble {
    padding: 8px 10px;     /*内側余白を縮小*/
    border-radius: 12px;
    font-size: 12px;       /*文字サイズ*/
    line-height: 1.4;      /*詰まりすぎ防止*/
  }


  /*吹き出しの三角を必ず縦中央に固定*/
  .bubble::before {
    border-width: 6px;          /*三角サイズを小さく*/
    left: -12px;                /*吹き出しに寄せる*/
    top: 50%;
    transform: translateY(-50%);
  }

  /*右側も同様に*/
  .right .bubble::before {
    border-width: 6px;
    right: -12px;
    left: auto;
    top: 50%;
    transform: translateY(-50%);
  }

  
  .face {
    width:45px;
    height: 45px;
    border-width: 1.5px;
  }
  
  
  /*アイコン下の文字を小さく*/
  .name {
    font-size: 10px;
    margin-top: 3px;
    line-height: 1.2;
  }

  /*アイコンエリア全体を少し詰める*/
  .face-wrap {
    width: 64px;
  }
  
  .sp-br{
    display: block;
  }
  
}
