.tool-hero--decay {
  background: radial-gradient(ellipse at 80% 42%, #514234, transparent 59%), #1d261d;
}
.decay-tool { display: grid; gap: .9rem; }
.decay-panel {
  min-width: 0;
  padding: clamp(.85rem, 3vw, 1.5rem);
  border: 1px solid #46574a;
  border-radius: .85rem;
  background: #1a251e;
}
.decay-panel h2 { margin: 0 0 .6rem; font-size: clamp(1.45rem, 5vw, 2.2rem); }
.decay-panel p { color: #d0daca; }
.decay-panel .decay-note { font-size: .92rem; }
.decay-panel a { color: #e0edb9; }
.decay-panel [role="status"] { color: #ffdcaa; }
.decay-panel [role="status"]:empty { display: none; }
.decay-controls { display: flex; flex-wrap: wrap; gap: .45rem; }
.decay-controls a, .decay-controls button {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: .5rem .75rem;
  border: 1px solid #586d55;
  border-radius: .55rem;
  background: #27362b;
  color: #f1f3e8;
  font: inherit;
}
.decay-controls button { cursor: pointer; }
.decay-controls [aria-pressed="true"] { border-color: #bacc89; background: #3f5636; color: #eff7d2; }
.decay-controls [data-screen-open][hidden] { display: none; }
.decay-inputs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .7rem;
  max-width: 46rem;
  margin: .75rem 0;
}
.decay-inputs label { display: grid; align-content: space-between; gap: .3rem; }
.decay-inputs input {
  width: 100%;
  min-height: 44px;
  padding: .45rem .6rem;
  border: 1px solid #677b66;
  border-radius: .5rem;
  background: #131c16;
  color: #fff8e9;
  font: inherit;
}
.decay-grades { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 152px), 1fr)); gap: .55rem; }
.decay-grade {
  --grade: #bf9b69;
  padding: .55rem .7rem .75rem;
  border: 1px solid #4d5b4e;
  border-top: 3px solid var(--grade);
  border-radius: .55rem;
  background: #232f26;
}
.decay-grade--wood { --grade: #e4ac77; }
.decay-grade--stone { --grade: #bcd29f; }
.decay-grade--metal { --grade: #a4cbd9; }
.decay-grade--armored { --grade: #d4b6e6; }
.decay-grade h3 { display: flex; align-items: center; gap: .38rem; margin: 0 0 .4rem; font-size: 1.04rem; }
.decay-grade img { flex: none; }
.decay-grade dl, .decay-team-result { margin: 0; }
.decay-grade dl { display: grid; gap: .4rem; }
.decay-grade dt, .decay-team-result dt { color: #ccd9c9; font-size: .9rem; }
.decay-grade dd, .decay-team-result dd { margin: .1rem 0 0; }
.decay-grade output, .decay-team-result output { color: #e2efbf; font-weight: 700; font-variant-numeric: tabular-nums; }
.decay-team-result { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 140px), 1fr)); gap: .5rem; margin-top: .9rem; }
.decay-team-result div { padding: .65rem; background: #243429; border: 1px solid #4c5d4b; border-radius: .5rem; overflow-wrap: anywhere; }
.decay-team-result output { font-size: 1.4rem; }
.decay-tool :focus-visible { outline: 2px solid #dfeaaf; outline-offset: 2px; }
@media (max-width: 480px) {
  .decay-inputs { grid-template-columns: 1fr; }
  .decay-grade dl { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .decay-controls a, .decay-controls button { transition: background-color .18s ease, border-color .18s ease; }
  .decay-controls a:hover, .decay-controls button:hover { background-color: #384f36; border-color: #bacc89; }
}
