/* =============== Base Layout =============== */
.ltf-wrap { max-width: 900px; margin: 24px auto; padding: 0 16px; font-family: 'Hannari', serif; color: #373737; }
.ltf-hero { margin: 0; padding: 0; }
.ltf-hero-img { width: 100%; height: auto; display: block; border-radius: 10px 10px 0 0; margin: 0; }


.ltf-control-card { margin-top: 20px; padding: 0 0 1.5em 0; border-radius: 16px; background: #fff; box-shadow: 0 4px 16px rgba(0,0,0,.06); border: 5px solid #ececf2; }
.ltf-control-head { display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 12px; margin: 1.2em 0 .2em 0; }
.ltf-title { position: relative; padding: 1rem 0.5rem 1rem 0; font-size: 1.2rem; font-weight: bold; text-align: center; }
.ltf-title:before, .ltf-title:after { position: absolute; height: 4.8rem; content: ''; right: 48px; }
.ltf-title:before { border-left: solid 1px; transform: rotate(-80deg); top: -29px; }
.ltf-title:after { border-right: solid 1px; transform: rotate(80deg); top: 20px; }
.ltf-responsive { display: flex; flex-direction: row; }
.ltf-amount { font-weight: 700; font-size: 18px; line-height: 1; padding: .3em 1em .7em 1em; border: 3px solid #4f46e5; border-radius: 5px; background-color: #fff; border-style: double; color: #4f46e5; }
.ltf-amount span { font-size: 2.5em; }
.ltf-slider-row { margin-top: 8px; padding: 0 1em; }
.ltf-slider-box { position: relative; padding: 1em; }


/* + / - ボタン */
.ltf-incdec { margin-left: 8px; display: flex; flex-direction: column-reverse; gap: 8px; justify-content: center; }
.ltf-btn { padding: 4px 7px 6px 7px; border: 1px solid #4f46e5; border-radius: 5px; background: #ffffff; box-shadow: 2px 2px #c59efa; cursor: pointer; font-size: 16px; font-weight: 700; line-height: 1; color: #4f46e5; }
.ltf-btn:hover { background: #f1f1f6; }
.ltf-btn:active { transform: translateY(1px); }


/* スライダー */
#ltf-range { width: 100%; appearance: none; height: 6px; border-radius: 999px; background: linear-gradient(to right, #b3b0fa 0%, #b3b0fa var(--range-progress, 0%), #e4e7f0 var(--range-progress, 0%), #e4e7f0 100%); outline: none; }
#ltf-range::-webkit-slider-thumb { appearance: none; width: 22px; height: 22px; background: #4f46e5; border-radius: 50%; box-shadow: 0 2px 8px rgba(79,70,229,.4); cursor: pointer; }
#ltf-range::-moz-range-thumb { width: 22px; height: 22px; background: #4f46e5; border: none; border-radius: 50%; box-shadow: 0 2px 8px rgba(79,70,229,.4); cursor: pointer; }


/* アクションボタン */
.ltf-actions { margin-top: 8px; display: flex; justify-content: center; gap: 1em; }
.ltf-actions button { box-shadow: 0 2px 5px 0 rgba(0, 0, 0, .2), 0 2px 10px 0 rgba(0, 0, 0, .1); }
.ltf-primary, .ltf-secondary { padding: 12px 20px; border-radius: 999px; font-weight: 700; cursor: pointer; width: 27%; }
.ltf-primary { border: none; background: linear-gradient(135deg, #b562eb, #7E23ED); color: #fff; }
.ltf-primary:hover, .ltf-secondary:hover { box-shadow: 0 4px 10px 0 rgba(0, 0, 0, .2), 0 4px 20px 0 rgba(0, 0, 0, .1); }


/* 結果領域 */
.ltf-result-area { margin-top: 20px; }
.ltf-loading { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px; border-radius: 16px; border: 1px dashed #d8dbe8; background: #fff; }
.ltf-result-body { display: flex; justify-content: center; align-items: center; gap: 1.5em; }
.ltf-loading-text { color: #4b5563; font-weight: 600; text-align: center; }


/* ローディングアニメーション */
#ltf-loading-video { display: block; margin: 0 auto; width: 100px; height: 100px; }


/* 結果 */
.ltf-result { display: grid; grid-template-columns: 180px 1fr; gap: 16px; align-items: center; padding: 16px; border: 1px solid #edeef5; border-radius: 16px; background: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.05); background-image: radial-gradient(#e6ddff 2px, #ffffff 2px); background-size: 20px 20px;}
.ltf-result-media img { display: block; }
.ltf-result-title { position: relative; padding: 0.5rem; border-radius: 0.2rem; margin-bottom: 0.5rem; color: white; font-weight: bold; font-size: 26px; text-align: center; background-image: linear-gradient(315deg, #a853eb, #4f46e5); z-index: 0;}
.ltf-result-title:before { position: absolute; inset: 5px -5px -5px 5px; border: 2px solid #66c5dd;content: ''; z-index: -1; }
.ltf-result-text { position: relative; color: #373737; line-height: 1.6; font-size: 1.5rem; background: #f1f1ff; border-radius: 10px; padding: .5em 1em; }
.ltf-result-text:after { content: ""; position: absolute; bottom: 20px; right: 0; border-style: solid; border-width: 0 0 16px 16px; border-color: transparent transparent transparent #f1f1ff; translate: 100% calc(-50% - 0.4px); transform: skew(0, 45deg); transform-origin: left; }

@media (max-width: 640px) { 
    .ltf-result { grid-template-columns: 1fr; } 
    .ltf-wrap { padding: 0; }
    .ltf-control-head { flex-direction: column; gap: 3px; }
    .ltf-title { padding: 0; }
    .ltf-title:before, .ltf-title:after { height: 1.6rem; bottom: 5px; }
    .ltf-title:before { transform: rotate(-35deg); left: -14px; right: unset; top: unset; }
    .ltf-title:after { transform: rotate(35deg); right: -14px; top: unset; }
    .ltf-amount { padding: .2em 1em .4em 1em; }
    .ltf-incdec { right: unset; justify-self: center; }
    .ltf-primary, .ltf-secondary { padding: 7px 20px; width: 42%; }
    .ltf-result-title { font-size: 20px; }
    .ltf-result-body { gap: 1em; flex-direction: column; }
    .ltf-result-media img { width: 120px !important; }
    .ltf-result-text { font-size: 1.2rem; }
}
