
/* Root */
.tfmp{background:#121212;color:#fff;font-family:Arial,sans-serif;padding:20px;box-sizing:border-box}
.tfmp .tfmp{padding:0} /* prevent nesting padding if inserted inside styled block */
.tfmp .tfmp-alert{display:none;margin:10px 0;padding:10px;border-radius:6px;background:#3a1f1f;border:1px solid #6b2b2b;color:#ffd5d5}
.tfmp h1{text-align:center;color:#00d2ff;font-size:1.8rem}
.tfmp .form-group{margin-bottom:12px}
.tfmp label{display:block;margin-bottom:6px;font-weight:bold}
.tfmp input,.tfmp select,.tfmp .tfmp-btn{width:100%;padding:10px;margin:5px 0;border-radius:6px;border:1px solid #555;background:#2e2e2e;color:#fff;box-sizing:border-box}
.tfmp .tfmp-btn{background:#007bff;font-weight:bold;cursor:pointer;border:1px solid #2b6cc4}
.tfmp .tfmp-btn:hover{background:#0056b3}
.tfmp .form-grid{display:grid;grid-template-columns:repeat(2,minmax(220px,1fr));gap:14px}
@media (max-width:680px){.tfmp .form-grid{grid-template-columns:1fr}}
.tfmp .results-container{display:flex;flex-wrap:wrap;gap:20px;justify-content:center;margin-top:20px}
.tfmp .card{flex:1 1 calc(100% - 20px);background:#1e1e1e;border-radius:10px;padding:20px;box-shadow:0 4px 8px rgba(0,0,0,.3)}
@media (min-width:768px){.tfmp .card{flex:1 1 calc(50% - 20px)} .tfmp h1{font-size:2rem}}
.tfmp .card h2{font-size:1.5rem;color:#28a745;margin-bottom:10px}
.tfmp .highlight{font-size:2rem;font-weight:bold;color:#28a745}
.tfmp .bar-container{background:#2c2c2c;border-radius:5px;margin:15px 0;overflow:hidden;height:20px;position:relative}
.tfmp .bar{height:100%;position:absolute}
.tfmp .bar-original{width:100%;background:#ff4d4d}
.tfmp .bar-new{background:#28a745;height:100%}
.tfmp .chart-wrap{height:380px;margin-top:20px}
.tfmp .chart-wrap canvas{width:100% !important;height:100% !important}
.tfmp small{opacity:.75}
.tfmp .meta{opacity:.9}

/* iPhone polish */
@media (max-width:480px){
  .tfmp .chart-wrap{ height:min(55vh,360px); min-height:240px; }
  .tfmp .card h2{ font-size:1.25rem; }
  .tfmp .highlight{ font-size:1.6rem; }
  .tfmp input,.tfmp select,.tfmp .tfmp-btn{ font-size:16px; } /* prevent iOS zoom on focus */
}
