.wrapper .block #inputBlock .table {
    width: 100%;
    display: table;
}

.wrapper .block #inputBlock .thead {
    display: table-header-group;
}

.wrapper .block #inputBlock .thead .tr {
    display: table-row;
}

.wrapper .block #inputBlock .thead .th {
    display: table-cell;
    color: #fff;
    background-color: #333;
    font-size: 125%;
    font-weight: 700;
    line-height: 1.3;
    padding-left: 6px;
    padding-right: 6px;
    padding-top: 11px;
    padding-bottom: 11px;
    border-left: 2px solid #fff;
    border-bottom: 3px solid #fff;
}

.wrapper .block #inputBlock .tbody .td:first-child {
    border-left: none;
    width:25%;
}

.wrapper .block #inputBlock .tbody {
    display: table-row-group;
}

.wrapper .block #inputBlock .tbody .tr {
    display: table-row;
}

.wrapper .block #inputBlock .tbody .td {
    display: table-cell;
    font-weight: 700;
    line-height: 1.3;
    padding-left: 6px;
    padding-right: 6px;
    padding-top: 16px;
    padding-bottom: 16px;
    border-bottom: 3px solid #fff;
    vertical-align: middle;
}

.wrapper .block #inputBlock .tbody .e {
    background-color: #eee;
    font-size: 125%;
    text-align: center;
}

.wrapper .block #inputBlock .tbody .v {
    background-color: #f9f9f9;
    font-size: 117%;
}




.wrapper .block #outputBlock .table {
    width: 100%;
    display: table;
}

.wrapper .block #outputBlock .tbody .td:first-child {
    border-left: none;
}

.wrapper .block #outputBlock .tbody {
}

.wrapper .block #outputBlock .tbody .tr {
}

.wrapper .block #outputBlock .tbody .td {
    display: block;
    width:100%;
    font-weight: 700;
    line-height: 1.3;
    padding-left: 4px;
    padding-right: 4px;
    vertical-align: middle;
    text-align: center;
    font-size: 117%;
    border-left: 2px solid #fff;
    border-bottom: 3px solid #fff;
    background-color: #eee;
	height:80px;
}
.wrapper .block #outputBlock .tbody .v {
    background-color: #f9f9f9;
}




	.wrapper .block #outputBlock .tbody .tr-responsive {
		display: grid!important;
	}
	.wrapper .block #outputBlock .tbody .td {
		width:100%;
		padding: 20px 0;
		        height: 100%;
	}



.form_txt{
	width:140px;
}

.label1 {
	font-weight: bold;
	font-size: 117%;
}

.label2 {
	font-size: 80%;
}

.value {
	font-weight: bold;
	color: #23ac38;
	font-size: 200%;
}

span.unit {
	font-size: 50%;
}

#inputBlock {
    background: #eff3f7;
	margin-bottom:40px;
}

#outputBlock {
    background: #fff;
}




.graphic{
	padding-top:30px;
	padding-bottom:0px;
}
.row {
	margin-bottom: 4px;
}
@keyframes expand {
	from {width: 0%;}
	to {width: 100%;}
}
@media screen and (min-width: 768px) {
	@keyframes expand {
		from {width: 0%;}
		to {width: calc(100%);}
	}
}
.chart {
	overflow: hidden;
	width: 0%;
	animation: expand 1.5s ease forwards;
	position: relative;
}
.row + .row .chart {
	animation-delay: .2s;
}
.row + .row + .row .chart {
	animation-delay: .4s;
}


.axisBlock1,
.axisBlock2{
	display: block;
	height: 12px;
	font-size: 14px;
	float: left;
	position: relative;
	overflow: hidden;
	opacity: 1;
	transition: opacity, .3s ease;
	cursor: pointer;
}
.axisBlock1 .blockValue,
.axisBlock2 .blockValue{
	display: none;
}
.axisBlock1 .blockLabel,
.axisBlock2 .blockLabel{
	display: block;
	line-height: 1em;
	position: absolute;
}
.axisBlock1 .blockLabel{
	font-size:12px;
	white-space: nowrap
}
.axisBlock1 .blockLabel:after{
	font-size:7px;
	content: "kg";
}
.axisBlock1 .blockLabelLast,
.axisBlock2 .blockLabelLast{
	display: block;
	line-height: 1em;
	position: absolute;
	right:0;
	font-size:12px;
	white-space: nowrap
}
.axisBlock1 .blockLabelLast:after{
	font-size:7px;
	content: "kg";
}


.chartBlock {
	display: block;
	height: 80px;
	color: #fff;
	font-size: .75em;
	float: left;
	background-color: #FF8C01;
	position: relative;
	overflow: hidden;
	opacity: 1;
	transition: opacity, .3s ease;
	cursor: pointer;
}
.chartBlock:nth-of-type(2),
.legend li:nth-of-type(2):before {
	background-color: #FFAA1C;
}
.chartBlock:nth-of-type(3),
.legend li:nth-of-type(3):before {
	background-color: #FFE733;
}
.chartBlock:nth-of-type(4),
.legend li:nth-of-type(4):before {
	background-color: #006B3E;
}
.chartBlock:nth-of-type(5),
.legend li:nth-of-type(5):before {
	background-color: #FFE733;
}
.chartBlock:nth-of-type(6),
.legend li:nth-of-type(6):before {
	background-color: #FFAA1C;
}
.chartBlock:nth-of-type(7),
.legend li:nth-of-type(7):before {
	background-color: #FF8C01;
}
.chartBlock:nth-of-type(8),
.legend li:nth-of-type(8):before {
	background-color: #ED2938;
}
.chartBlock .blockValue {
	display: none;
}
.chartBlock:hover {
	opacity: .65;
}


/* 低体重 */
.judge1 {
	position: absolute;
	top: 40%;
	left: 3.5%;
	color:#000;
	font-weight: bold;
}
/* 普通体重 */
.judge2 {
	position: absolute;
	top: 40%;
	left: 17.5%;
	color:#fff;
	font-weight: bold;
}
/* 肥満(1度) */
.judge3 {
	position: absolute;
	top: 40%;
	left: 33.5%;
	color:#000;
	font-weight: bold;
}
/* 肥満(2度) */
.judge4 {
	position: absolute;
	top: 40%;
	left: 47.5%;
	color:#000;
	font-weight: bold;
}
/* 肥満(3度) */
.judge5 {
	position: absolute;
	top: 40%;
	left: 61.5%;
	color:#000;
	font-weight: bold;
}
/* 肥満(4度) */
.judge6 {
	position: absolute;
	top: 40%;
	left: 81.5%;
	color:#000;
	font-weight: bold;
}
@media screen and (max-width: 480px) {
	.axisBlock1 .blockLabel{
		font-size:8px;
	}
	.axisBlock1 .blockLabel:after{
		font-size:5px;
		content: "kg";
	}
	.axisBlock1 .blockLabelLast{
		font-size:8px;
	}
	.axisBlock1 .blockLabelLast:after{
		font-size:5px;
		content: "kg";
	}

	.axisBlock2 .blockLabel{
		font-size:10px;
	}
	.axisBlock2 .blockLabelLast{
		font-size:10px;
	}


	/* 低体重 */
	.judge1 {
		left: 2.5%;
		font-size:80%;
	}
	/* 普通体重 */
	.judge2 {
		left: 16.5%;
		font-size:80%;
	}
	/* 肥満(1度) */
	.judge3 {
		left: 32.5%;
		font-size:80%;
	}
	/* 肥満(2度) */
	.judge4 {
		left: 46%;
		font-size:80%;
	}
	/* 肥満(3度) */
	.judge5 {
		left: 60%;
		font-size:80%;
	}
	/* 肥満(4度) */
	.judge6 {
		left: 80.5%;
		font-size:80%;
	}
}





.bmiBlock {
	display: block;
	height: 26px;
	float: left;
	position: relative;
	overflow: hidden;
	opacity: 1;
	transition: opacity, .3s ease;
	cursor: pointer;
}
.bmiBlock .blockValue {
	display: none;
}
.bmiArrow {
	position: absolute;
}




.x-axis {
    text-align: center;
	padding: 0;
}
.x-axis .title{
	font-size:150%;
	font-weight:bold;
}
/* プルダウンの基本スタイル */
.wrapper .block #inputBlock select {
    width: auto;
    font-size: 117%;
    font-weight: 700;
    line-height: 1.5;
    padding: 12px;
    border: 2px solid #333;
    background-color: #f9f9f9;
    color: #333;
    border-radius: 4px;
    box-shadow: none;
    outline: none;
    appearance: none; /* デフォルトのプルダウン矢印を非表示にする */
}

/* プルダウンのホバー効果 */
.wrapper .block #inputBlock select:hover {
    border-color: #23ac38;
    background-color: #e8f5e9;
}

/* プルダウン選択時の効果 */
.wrapper .block #inputBlock select:focus {
    border-color: #4CAF50;
    background-color: #e8f5e9;
    box-shadow: 0 0 4px rgba(76, 175, 80, 0.5);
}

/* プルダウン用の矢印の追加 */
.wrapper .block #inputBlock select::after {
    content: "▼";
    font-size: 0.8em;
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none; /* 矢印部分のクリックを無効化 */
}

/* モバイルでのスタイル調整 */
@media screen and (max-width: 480px) {
    .wrapper .block #inputBlock select {
        font-size: 100%;
        padding: 8px 6px;
    }
}


.form_txt_l {
    width: 140px;
}


.badge input {appearance: auto;}


:root{
  --card:#ffffff;
  --muted:#6b7280;
  --text:#333333;
  --line:rgba(17,24,39,.12);

  --acc:#6d28d9;
  --acc2:#db2777;

  --ok:#16a34a;
  --err:#dc2626;

  --shadow:0 12px 30px rgba(17,24,39,.12);
  --radius:18px;
}


.wrap{max-width:1100px; margin:20px auto; padding:0 14px 40px;}
.topbar{display:flex; align-items:center; justify-content:space-between; gap:12px; margin:8px 0 14px;}
.title{font-size:1.1rem; font-weight:800; letter-spacing:.02em;}
.ver{font-size:.85rem; color:var(--muted)}
.grid{display:grid; grid-template-columns: 1fr; gap:14px;}
@media(min-width:980px){ .grid{grid-template-columns: 1fr 1fr;} }

.card{
  background: linear-gradient(180deg, rgba(255,255,255,1), rgba(255,255,255,.98));
  border:1px solid var(--line);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
  padding:16px;
}

.card h2{margin:0 0 10px; font-size:1rem; display:flex; align-items:center; gap:10px;}
.cap{font-size:.86rem; color:var(--muted); line-height:1.5; margin-bottom:12px;}

.notice{
  font-size:.86rem;
  color:#4c1d95;
  background:rgba(109,40,217,.08);
  border:1px solid rgba(109,40,217,.18);
  padding:10px 12px;
  border-radius:14px;
  margin-bottom:12px;
}

.row{display:flex; gap:10px; flex-wrap:wrap;}

.btn-main,.btn-sub{
  border:1px solid var(--line);
  background:rgba(17,24,39,.03);
  color:var(--text);
  padding:10px 12px;
  border-radius:14px;
  font-weight:700;
  cursor:pointer;
  display:inline-flex;
  align-items:center;
  gap:8px;
}

.btn-main{
  background:linear-gradient(90deg, rgba(109,40,217,.18), rgba(219,39,119,.14));
  border-color:rgba(17,24,39,.14);
}

.btn-main:disabled{opacity:.45; cursor:not-allowed; filter:grayscale(100%);}
.btn-sub{background:rgba(17,24,39,.02)}

.upload-box{
  width:100%;
  border:1px dashed rgba(17,24,39,.22);
  border-radius:16px;
  padding:16px;
  text-align:center;
  cursor:pointer;
  display:block;
  background:rgba(17,24,39,.015);
}

.status-msg{margin-top:10px; font-size:.9rem; color:var(--muted);}
.status-msg.ok{color:var(--ok)}
.status-msg.err{color:var(--err)}

/* Preview */
.preview-container{
  position:relative;
  margin-top:12px;
  border-radius:16px;
  overflow:hidden;
  border:1px solid var(--line);
  background:#ffffff; /* 白ベース */
}

#inputImage{
  width:100%;
  display:block;
  max-height:420px;
  object-fit:contain;
  background:#ffffff; /* 白ベース */
}

#overlayCanvas{position:absolute; left:0; top:0; pointer-events:none;}

.roi-bubble{
  position:absolute;
  right:10px;
  bottom:10px;
  width:120px;
  height:120px;
  border-radius:16px;
  overflow:hidden;
  border:1px solid rgba(17,24,39,.14);
  background:rgba(255,255,255,.85);
  display:none;
  box-shadow:0 12px 26px rgba(17,24,39,.12);
}

.roi-bubble.show{display:block;}
#roiCanvas{width:100%; height:100%; display:block;}

/* Manual ROI */
.roi-handle{position:absolute; left:0; top:0; width:100%; height:100%; pointer-events:auto;}

.roi-box{
  position:absolute;
  border:2px solid rgba(219,39,119,.85);
  border-radius:12px;
  box-shadow:0 0 0 20000px rgba(17,24,39,.08);
  touch-action:none;
}

.roi-grip{
  position:absolute;
  width:14px;
  height:14px;
  background:rgba(219,39,119,.85);
  border-radius:6px;
  right:-7px;
  bottom:-7px;
  box-shadow:0 6px 16px rgba(17,24,39,.18);
}

.roi-tip{
  position:absolute;
  left:10px;
  top:10px;
  background:rgba(255,255,255,.92);
  border:1px solid rgba(17,24,39,.12);
  padding:6px 8px;
  border-radius:12px;
  font-size:.82rem;
  color:var(--text);
}

/* Result */
.result-header{display:flex; align-items:center; justify-content:space-between; gap:10px; flex-wrap:wrap; margin-bottom:10px;}

.badge{
  padding:7px 10px;
  border-radius:999px;
  font-weight:800;
  background:rgba(17,24,39,.03);
  border:1px solid var(--line);
}

.badge.spring{background:rgba(245,158,11,.14); border-color:rgba(245,158,11,.20)}
.badge.summer{background:rgba(59,130,246,.14); border-color:rgba(59,130,246,.20)}
.badge.autumn{background:rgba(217,119,6,.14); border-color:rgba(217,119,6,.20)}
.badge.winter{background:rgba(139,92,246,.14); border-color:rgba(139,92,246,.20)}

.big{font-size:1.7rem; font-weight:900;}
.small{font-size:.9rem; color:var(--muted);}

.meter{display:grid; gap:10px; margin-top:12px;}
.mrow{display:grid; grid-template-columns: 130px 1fr 60px; gap:10px; align-items:center;}
.mname{font-size:.9rem; color:#111827;}
.bar-bg{height:10px; border-radius:999px; background:rgba(17,24,39,.08); overflow:hidden;}
.bar-fill{height:100%; width:0%; border-radius:999px; background:rgba(109,40,217,.65);}
.mval{font-variant-numeric:tabular-nums; color:#111827; text-align:right;}

.palette{display:grid; grid-template-columns: repeat(2,1fr); gap:10px; margin-top:12px;}
@media(min-width:480px){ .palette{grid-template-columns: repeat(3,1fr);} }

.swatch{
  border:1px solid rgba(17,24,39,.12);
  border-radius:14px;
  overflow:hidden;
  background:rgba(255,255,255,1);
}

.swatch-top{height:48px;}
.swatch-bot{padding:8px 10px;}
.swatch-name{font-weight:800; font-size:.9rem; color:#111827;}
.swatch-hex{font-size:.82rem; color:var(--muted); margin-top:2px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono","Courier New", monospace;}

.advice-box{
  margin-top:14px;
  border:1px solid var(--line);
  background:rgba(17,24,39,.02);
  border-radius:16px;
  padding:12px;
}

.advice-title{font-weight:900; display:flex; gap:8px; align-items:center; margin-bottom:6px; color:#111827;}
.advice-content{white-space:pre-line; color:#111827; line-height:1.7; font-size:.95rem;}

.tag{
  display:inline-block;
  margin:6px 6px 0 0;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(109,40,217,.10);
  border:1px solid rgba(109,40,217,.16);
  color:#4c1d95;
  font-size:.85rem;
  font-weight:700;
}

/* Video */
video{
  width:100%;
  border-radius:16px;
  border:1px solid var(--line);
  display:none;
  background:#ffffff; /* 白ベース */
}
