/* Tire Size Calculator — asphalt + signal yellow */
.ty-inputs { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 12px; align-items: center; }
@media (max-width: 700px) { .ty-inputs { grid-template-columns: minmax(0, 1fr); } .ty-swap { justify-self: center; transform: rotate(90deg); } }
.ty-tire { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 14px 16px 16px; margin: 0; background: var(--raised); min-width: 0; }
.ty-tire legend { font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 0 6px; }
.ty-tire:last-of-type legend { color: var(--link); }
.ty-text { font: 750 26px/1 var(--mono) !important; text-align: center; letter-spacing: .02em; min-height: 56px !important; }
.ty-text.bad { border-color: var(--bad) !important; box-shadow: 0 0 0 3px color-mix(in oklab, var(--bad) 18%, transparent) !important; }
.ty-parts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.ty-parts label { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; font-weight: 650; color: var(--muted); position: relative; }
.ty-parts input { text-align: center; font-weight: 650; padding-right: 26px; }
.ty-parts small { position: absolute; right: 9px; bottom: 13px; color: var(--muted); font-size: 12px; }
.ty-swap { width: 46px; height: 46px; padding: 0; border-radius: 50%; font-size: 20px; }

.ty-verdict { margin: 16px 0; padding: 14px 18px; border-radius: var(--r); font-size: 16px; line-height: 1.5; background: var(--raised); border: 1px solid var(--line); }
.ty-verdict.good { background: color-mix(in oklab, #22c55e 12%, var(--surface)); border-color: color-mix(in oklab, #22c55e 40%, var(--line)); }
.ty-verdict.warn { background: color-mix(in oklab, #f59e0b 14%, var(--surface)); border-color: color-mix(in oklab, #f59e0b 45%, var(--line)); }

.ty-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 18px; align-items: start; }
@media (max-width: 820px) { .ty-grid { grid-template-columns: minmax(0, 1fr); } }
.ty-visual { margin: 0; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 12px; background: var(--raised); }
.ty-visual svg { display: block; width: 100%; height: auto; }
.ty-visual .t { fill: #27272a; stroke: #52525b; stroke-width: 3; }
.ty-visual .w { fill: #d4d4d8; stroke: #a1a1aa; stroke-width: 2; }
.ty-visual .b .w { fill: color-mix(in oklab, var(--accent-2) 55%, #e4e4e7); }
.ty-visual .h { fill: #71717a; }
.ty-visual .ground { stroke: var(--line-strong); stroke-width: 1; }
.ty-visual figcaption { display: flex; justify-content: space-around; font-size: 13px; font-weight: 650; color: var(--muted); }
.ty-visual figcaption .b { color: var(--link); }
.ty-table-wrap { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: auto; }
.ty-table { width: 100%; border-collapse: collapse; font-size: 14.5px; font-variant-numeric: tabular-nums; }
.ty-table th, .ty-table td { padding: 10px 12px; text-align: right; border-bottom: 1px solid var(--line); vertical-align: top; white-space: nowrap; }
.ty-table thead th { background: var(--tint); font-family: var(--mono); font-size: 13px; }
.ty-table th[scope=row] { text-align: left; font-weight: 600; color: var(--ink-2); white-space: normal; }
.ty-table td small { display: block; color: var(--muted); font-size: 12px; }
.ty-table td.big { color: var(--warn); font-weight: 700; }
.ty-table tbody tr:last-child > * { border-bottom: 0; }

.ty-speedo { margin-top: 18px; }
.ty-speedo-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 560px) { .ty-speedo-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ty-speedo-row div { border-radius: var(--r); padding: 12px 14px; background: var(--accent); color: #fff; }
.ty-speedo-row span { display: block; font-size: 12.5px; opacity: .8; font-weight: 600; }
.ty-speedo-row b { display: block; font: 800 28px/1.1 var(--display); font-variant-numeric: tabular-nums; }
.ty-speedo-row small { font-size: 12px; opacity: .8; }
.ty-speedo-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.ty-speedo-head .panel-h { margin: 0; }
.ty-kmh { margin: 0; padding: 5px 10px; font-size: 13.5px; }
