@charset "utf-8";

 /*初期設定*/
html, body { 
  margin: 0px;
  padding: 0px;
  height: auto;
  min-height: 100vh;
  padding-bottom: 0px; /* フッターの高さ＋余白ぶん */
}

 body {
   font-family: 'Baumans','Hiragino Kaku Gothic ProN';
   display:flex;
   justify-content: center; /* 横中央寄せ */
   align-items: flex-start; /* 上寄せ */
   height: auto; /* 画面全体の高さ */
   overflow: auto;
}


/*全体*/
.wrapper {
  width: 390px;
  height: auto;
  margin: 0 auto;
  position: relative;
}

/* 背景 */
.background {
  position: fixed;          /* 常に画面いっぱいに表示 */
  top: 0;
  left: 0;
  width: 100%;             /* ビューポート全体幅 */
  height: 100%;            /* ビューポート全体高さ */
  background-color: #AB2022;
  z-index: 0;               /* 他要素より後ろ */
}

/* ヘッダーを画面上部に固定 */
.header {
  position: fixed;
  top: 0;
  left: 50%; /* ←中央基準 */
  transform: translateX(-50%); /* ←完全中央寄せ */
  width: 390px;
  height: 103px;
  background-image:url(img/header.png);
  z-index: 1000; /* ヘッダーアイコンより少し下に */
}

/*ヘッダー*/
.headericon {
  position: fixed;
  top: 71px;
  left: 50%; /* 画面中央を基準に */
  transform: translateX(-50%) translateX(-169px);
  width: 21px;
  height: 15px;
  background: none;
  border: none;
  display: flex; 
  justify-content: center; /* アイコンを範囲の中央に */
  align-items: center;
  cursor: pointer;
  padding: 0;
  z-index: 1000; /* ヘッダーより前に出す */
}

.headericon img {
  width: 100%;
  height: auto;
  display: block;
  pointer-events: none;
}

.headericon2{
  position: fixed;
  top:66px;
  left: calc(50% - 390px / 2 + 354px);
  width: 17px;
  height: 24px;
  background: none;
  border: none;
  display: flex; 
  justify-content: center;
  align-items: center;
  cursor: pointer;
  padding: 0;
  z-index: 1000;
}

.headericon2 img {
  width: 100%;
  height: auto;
  display: block;
  pointer-events: none;
}


/*フッター*/
.footer {
  position: fixed;
  width: 390px;
  bottom: 0;
  left: 50%;
  transform: translateX(calc(50%,-514px));
  overflow: hidden;
  z-index: 1000;
}

/* 本画像 */
.bookfooter {
  display: block;
  position: fixed;
  top: calc(100vh - 60px);
  left: 50%;
  left: calc(50% + 10px);
  transform: translateX(-50%);
  width: 392px;
  height: 478px;
  margin: 0;
  padding: 0;
  gap: 0px;
  z-index: 900;
  pointer-events: auto;
  cursor: pointer;
}

/* ボタン全体配置 */
.footerbuttons {
  position: fixed;
  display: flex;
  bottom: 45px; /* bookfooterの上に配置 */
  left: 50%;;
  transform: translateX(calc(-50% + 24px));
  width: 310px;
  gap: 10px;
  justify-content: center;
  align-items: center;
  width: 85%;
  max-width: 400px;
  z-index: 1001;
}
.footerbtn {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}
.footerbtn img {
  display: block;
  object-fit: contain;
}
.fusen1,.fusen2 {
  width: 55px;
  height: auto;
  background-color: #AB2022;
}
.footericon1,
.footericon2,
.footericon3,
.footericon4,
.footericon5 {
  position: absolute;
  top: 50%;
  left: 50%;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.footerbtn:active .fusen {
  transform: scale(0.95);
  transition: transform 0.1s;
}
/* 個別に位置を微調整 */
.footericon1{
  top: 55%;
  transform: translate(-50%, -50%);
}
.footericon2 {
  top: 51%;
  left: 52%;
  transform: translate(-50%, -50%);
}
.footericon3 {
  top: 46%;   /* 下に移動 */
  left: 52%;  /* 左に移動 */
  transform: translate(-50%, -50%);
}
.footericon4{
  top: 44%;
  left: 51%;
  transform: translate(-50%, -50%);
}
.footericon5{
  top: 42%;
  left: 51%;
  transform: translate(-50%, -50%);
}


/*プロフィール*/
.profile{
  position:relative;
  width:390px;
  height:200px;
  margin: 100px auto 0;
  background-image: url(img/profilehaikei.png);
  background-color:rgba(0,0,0, 0.3) ;
  background-blend-mode:multiply;
}
#profilemenu{
  position: absolute;
  top:57px;
  left:163px;
  font-family: Manufacturing Consent;
  font-weight:lighter;
  color:#9D9D9D;
  font-size: 32px;
}
.profileimage{
  position: absolute;
  top: 15px;
  left:16px;
  width: 88px;
	height: 88px;
	border-radius: 50%;
  background-image:url(img/profileimage.png);
  background-repeat: no-repeat;
}
.username {
  position: absolute;
  color: #C0C0C0;
  font-size: 18px;
  font-weight: medium;
  top: 20px;
  left:131px;
}
.acountname{
   position: absolute;
   color: #9D9D9D;
   font-size: 16px;
   font-weight: medium;
   top:40px;
   left:131px;
}

.follow{
  position: absolute;
  top:84px;
  left:131px;
  font-size: 13px;
  color: #999999;
}
.follow span{
  display: inline-block; /* 横並び */
}
.label:nth-of-type(1){
  margin-right: 8px;  /* 「フォロー中」と「3」の間 */
}
.number:nth-of-type(2) {
  margin-right: 24px; /* 「3」と「フォロワー」の間 */
}
.label:nth-of-type(3) {
  margin-right: 8px;  /* 「フォロワー」と「90」の間 */
}
.number:nth-of-type(4) {
  margin-right: 0;    /* 最後は不要 */
}

.editicon{
  position: absolute;
  top:12px;
  left: 353px;
  width:22px;
  height:22px;
  background:none;
  border: none;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}
.editicon img{
  width: 100%;
  height: auto;
  display: block;
  pointer-events: none;
}

.aboutme{
  position: absolute;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 13px;
  font-weight: lighter;
  line-height: 19px;
  top: 94px;
  left:18px;
  color: #ABABAB;
}

/*投稿*/
.postarea {
  display: flex;
  position: relative;
  width: 100%;
  justify-content: center;
  margin: auto;
  flex-direction: column; /* 縦に並べる */
  top: 4px;
  gap: 9px;
  margin-top: 20px;
  max-height: none;
  overflow: visible;
}
.postmenu {
  display: flex;
  position: relative;
  justify-content: space-between; /* 左右に配置 */
  transform: translateX(4px) translateY(-20px);
  gap: 12px;
  width: 132px;          /* %→親幅に合わせる（必要なら px に変更） */
  height: 33px;
  padding: 6px 10px;
  background-image: url("img/postline.png");
  background-repeat: no-repeat;
  background-size: auto 100%;
  box-sizing: border-box;
  position: relative;   /* sticky等にするときは親で指定 */
  z-index: 10;
}
.postmenu .post-left {
  display: flex;
  align-items: center;
  gap: 26px;
}
.post, .kensuu {
  position: static !important;
  margin: 0;
  color: #C8C8C8;
}
.kensuu{
  position: absolute;
  top:10px;
  left:68px;
  font-size: 12px;
  transform: translateY(1px);
}
.post span{
  font-size: 14px;
}

.mannenhitsu{
  position: relative;
  background: none;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.posticon .mannenhitsu img {
  width: 96px;
  height: 34px;
  object-fit: contain;
}

.posticon {
  display: flex;
  position: absolute;
  gap: 23px;
  align-items: center;
  justify-content: flex-end;
  top:1px;
  left:127px;
}
.posticon button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  background-color: transparent;
  cursor: pointer;
  color: #161616;
  font-family: 'Baumans';
  font-size: 10px;
  box-sizing: border-box;
}
.posticon1{
  width:30px;
  height:24px;
  background-color: #161616;
}
.posticon2{
  width:31px;
  height:24px;
  border-radius: 7px;
  background-color: #161616;
  color: #C3C3C3;
  font-size: 10px;
}
.posticon3{
  transform: translate(-3px,-2px);
  width:33px;
  height:11px;
}
.posticon img {
  display: block;
  pointer-events: none;
}
.posticonnumber1,.posticonnumber2 {
  position: absolute;
  font-size: 10px;
  color: #C3C3C3;
  pointer-events: none;
}
.posticonnumber1{
  top: 6px;
  left: 12px;
}
.posticonnumber2{
  top: 6px;
  left: 14px;
}
/*トップへ戻る*/
#topbutton {
  position: fixed;
  bottom: 15px;   /* ← 画面下から20px */
  width: 27px;
  height: 22px;
  left: 50%;
  transform: translateX(148px);
  background-color:transparent;
  border: none;
  cursor: pointer;
  z-index: 1000;
}

/*フィルター・スクロール*/
.filter-section {
  margin: auto;
  background-color: #C3C3C3;
  padding: 6px 0;
  position: sticky;
  top: 165px;
  overflow-x: auto;
}
.filter-scroll {
  display: flex;
  gap: 5px;
  padding: 0 8px;
  overflow-x: auto;
   transform: translateY(-26px);
}
.filter-scroll::-webkit-scrollbar {
  display: none;
}
.filteritem {
  height: 26px;
  padding: 0 11px;
  font-size: 12px;
  color: #c3c3c3;
  background-color: #AB2022;
  border: none;
  border-radius: 3px;
  white-space: nowrap;
  cursor: pointer;
  transition: 0.25s;
}
.filteritem:hover {
  background-color: #161616;
  color: #c3c3c3;
}
/* activeでON、解除でOFF */
.filteritem.active {
  background-color: #161616;
  color: #c3c3c3;
}
.filteritem:not(.active):hover {
  background-color: #AB2022; /* 通常時hoverの微妙な変化に */
  color: #c3c3c3;
}
.filteritem:focus {
  outline: none;
}


/* 投稿全体 */
.post-section {
  position: relative;
  width: 377px; /* ← ヘッダーと揃う幅に調整 */
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow: visible;
}

/* 各投稿ボックス */
.postboxkousatsu,
.postboxkansou{
  position: relative;
  width: 100%; /* ← 固定値ではなく親幅に合わせる */
  background-color: none;
  border-bottom: 1px solid #c3c3c3;
  color: #C3C3C3;
  padding: 38px 10px 0px 12px;
  transform: translateY(-28px);
  transition: 0.3s;
  box-sizing: border-box; /*padding含めて幅を計算 */

}
/* アイコン */
.post-usericon {
  position: absolute;
  top: 12px;
  left: 16px;
  
}
.post-usericon img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
}

/* 名前・時間・オプション */
.postusername {
  position: absolute;
  top: 10px;
  left: 60px;
  font-size: 14px;
  color: #C3C3C3;
}
.posttime {
  position: absolute;
  top: 12px;
  left: 230px;
  font-size: 13px;
}
.postoption {
  position: absolute;
  top: 9px;
  right: 12px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}
.postoption img {
  width: 15px;
  height: 3px;
}

/* アカウント名 */
.postacountname {
  position: absolute;
  top: 27px;
  left: 60px;
  font-size: 13px;
}

/* 本文 */
.postboxkousatsu p,
.postboxkansou p {
  font-size: 14px;
  line-height: 1.4em;
  color: #C3C3C3;

}
/* 投稿内の画像 */
.post-image {
  width: 100%;
  margin-bottom: 10px;
  display: flex;
  justify-content: center;
}

.post-image img {
  width: 100%;
  max-height: 220px;  /* ← 高さ制限、必要なら調整 */
  object-fit: cover;  /* トリミングして全体に収める */
  border-radius: 6px;
}

.post-actions {
  display: flex;
  justify-content: space-between; /* 横方向に等間隔配置 */
  align-items: center;
  padding: 10px 15px 0px 20px;
  margin-top: -20px;
}

/* ボタン領域を統一（見た目を揃える） */
.action-btn {
  width: 40px;   /* ボタンの見かけ上の幅 */
  height: 40px;  /* 高さも固定 */
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: transform 0.2s ease, opacity 0.2s ease;
  margin-bottom: 5px;
}

/* アイコン画像の調整 */
.action-btn img {
  object-fit: contain; /* 画像の比率を保ったまま収める */
  opacity: 0.85;
  display: block;
}

.action-btn.comment {
  display: flex;
  align-items: center;
}
.commentnumber {
  font-size: 10px;
  color: #161616;
   transform: translateX(5px);
}
/* ==== 投稿アイコンアニメーション ==== */



/* ホバー・タップ時：黒く塗りつぶされるように */
.action-btn:hover img,
.action-btn:active img {
  filter: brightness(0) invert(0); /* 真っ黒に変化 */
  opacity: 1;
  transform: scale(1.08);
}
/* 通常時 */
.action-btn img {
  opacity: 0.85;
  transition: opacity 0.25s ease, transform 0.2s ease;
}

/* ホバー時：少し浮く＆黒く */
.action-btn:hover img {
  opacity: 1;
  transform: scale(1.08);
  filter: brightness(0) invert(0);
}

/* 押した後（activeクラスがついた状態） */
.action-btn.active img {
  filter: none; /* 黒画像をそのまま表示 */
  transform: scale(1);
}



