/* Simple tool pages: one title, one line, numbered steps, the tool, one big answer. */
.tool-page { max-width: 560px; margin: 0 auto; padding: 28px 18px 56px; }
.tool-page h1 { font-size: clamp(1.9rem, 7vw, 2.6rem); line-height: 1.08; margin: 0 0 10px; letter-spacing: -0.01em; }
.tool-lead { font-size: 1.1rem; line-height: 1.45; color: var(--text-soft, rgba(245,247,251,.7)); margin: 0 0 18px; }
.tool-steps { list-style: none; counter-reset: step; margin: 0 0 22px; padding: 0; display: grid; gap: 8px; }
.tool-steps li { counter-increment: step; display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 1rem; }
.tool-steps li::before { content: counter(step); flex: none; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--accent, #ff263d); color: #fff; font-weight: 800; font-size: .9rem; }
.tool-card { background: var(--surface, #101218); border: 1px solid var(--border, rgba(255,255,255,.08)); border-radius: 18px; padding: 18px; }
.tool-field { display: grid; gap: 6px; margin-bottom: 14px; font-weight: 700; font-size: 1rem; }
.tool-field small { font-weight: 500; color: var(--text-faint, rgba(245,247,251,.46)); }
.tool-card input[type=number], .tool-card input[type=email], .tool-card select, .tool-card textarea {
  width: 100%; min-height: 54px; padding: 12px 14px; font: inherit; font-size: 1.15rem; color: var(--text, #f5f7fb);
  background: var(--bg-raised, #0b0c10); border: 1.5px solid rgba(255,255,255,.14); border-radius: 12px; }
.tool-card input:focus, .tool-card select:focus, .tool-card textarea:focus { outline: none; border-color: var(--accent, #ff263d); box-shadow: 0 0 0 3px rgba(255,38,61,.25); }
.tool-row { display: grid; grid-template-columns: 1fr 120px; gap: 10px; }
.tool-check { display: flex; gap: 10px; align-items: center; font-weight: 600; margin: 4px 0 14px; }
.tool-check input { width: 22px; height: 22px; accent-color: var(--accent, #ff263d); }
.tool-go { width: 100%; min-height: 56px; border: 0; border-radius: 14px; background: var(--accent-action, #ce1b30); color: #fff; font: inherit; font-size: 1.15rem; font-weight: 800; cursor: pointer; }
.tool-go:hover { background: var(--accent, #ff263d); }
.tool-link { background: none; border: 0; color: var(--text-soft, rgba(245,247,251,.7)); font: inherit; font-size: .95rem; text-decoration: underline; cursor: pointer; padding: 10px 0 0; }
.tool-options { margin: 0 0 14px; }
.tool-options > summary { cursor: pointer; font-weight: 700; color: var(--text-soft, rgba(245,247,251,.7)); padding: 6px 0 12px; }
.tool-error { color: #ff8a95; font-weight: 700; margin: 12px 0 0; }
.tool-error:empty { display: none; }
.tool-answer { margin-top: 18px; padding: 20px 18px; border-radius: 18px; background: linear-gradient(180deg, rgba(255,38,61,.12), rgba(255,38,61,.03)); border: 1.5px solid rgba(255,38,61,.45); text-align: center; }
.tool-answer[hidden] { display: none; }
.tool-answer .big { display: block; font-size: clamp(2.6rem, 13vw, 3.6rem); font-weight: 900; line-height: 1; letter-spacing: -0.02em; }
.tool-answer .big-label { display: block; margin-top: 6px; font-weight: 700; color: var(--text-soft, rgba(245,247,251,.7)); }
.tool-answer .say { font-size: 1.08rem; line-height: 1.45; margin: 14px 0 0; }
.tool-answer .zone { display: inline-block; margin-top: 10px; padding: 4px 12px; border-radius: 999px; font-weight: 800; background: rgba(255,255,255,.08); }
.tool-answer .zone.good { background: rgba(60,207,142,.18); color: #7ff0bd; }
.tool-answer .zone.warn { background: rgba(245,197,66,.18); color: #f5d27a; }
.tool-answer .zone.bad { background: rgba(255,38,61,.2); color: #ff9aa4; }
.tool-answer .zone.low { background: rgba(79,140,255,.18); color: #9dc0ff; }
.tool-macros { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0 0; }
.tool-macros div { background: rgba(0,0,0,.25); border-radius: 12px; padding: 10px 6px; }
.tool-macros dt { font-size: .85rem; color: var(--text-soft, rgba(245,247,251,.7)); font-weight: 700; }
.tool-macros dd { margin: 2px 0 0; font-size: 1.35rem; font-weight: 900; }
.tool-answer .tool-more-detail { text-align: left; margin-top: 14px; color: var(--text-soft, rgba(245,247,251,.7)); font-size: .95rem; }
.tool-answer .tool-more-detail summary { cursor: pointer; font-weight: 700; }
.tool-answer .tool-more-detail p, .tool-answer .tool-more-detail li { margin: 8px 0; }
.tool-second { width: 100%; min-height: 50px; margin-top: 14px; border-radius: 14px; border: 1.5px solid rgba(255,255,255,.2); background: transparent; color: var(--text, #f5f7fb); font: inherit; font-weight: 800; cursor: pointer; }
.tool-email { margin-top: 14px; text-align: left; }
.tool-email[hidden] { display: none; }
.tool-email form { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.tool-email button { min-height: 54px; padding: 0 16px; border: 0; border-radius: 12px; background: var(--text, #f5f7fb); color: #000; font: inherit; font-weight: 800; cursor: pointer; }
.tool-email p { margin: 0 0 8px; font-weight: 700; }
.tool-email small { display: block; margin-top: 6px; color: var(--text-faint, rgba(245,247,251,.46)); }
.tool-week { margin-bottom: 12px; }
.tool-week-label { font-weight: 800; font-size: .95rem; margin-bottom: 6px; display: flex; justify-content: space-between; }
.tool-week-label span { color: var(--text-faint, rgba(245,247,251,.46)); font-weight: 600; }
.tool-days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.tool-days label { display: grid; gap: 3px; text-align: center; font-size: .75rem; font-weight: 700; color: var(--text-faint, rgba(245,247,251,.46)); }
.tool-card .tool-days input { min-height: 46px; padding: 6px 2px; text-align: center; font-size: 1rem; }
.tool-week.this .tool-week-label { color: var(--accent, #ff263d); }
.tool-more { max-width: 560px; margin: 0 auto 40px; padding: 0 18px; }
.tool-more > summary { cursor: pointer; font-weight: 800; padding: 14px 16px; border: 1px solid var(--border, rgba(255,255,255,.08)); border-radius: 14px; background: var(--surface, #101218); }
.tool-more[open] > summary { margin-bottom: 18px; }
.tool-more .article-body { max-width: none; }
.tool-app { max-width: 560px; margin: 0 auto 48px; padding: 0 18px; text-align: center; color: var(--text-soft, rgba(245,247,251,.7)); }
.tool-app a { color: var(--accent, #ff263d); font-weight: 800; }
.tool-card .tool-days input { padding: 6px 0; font-size: 1rem; -moz-appearance: textfield; appearance: textfield; min-width: 0; }
.tool-days input::-webkit-outer-spin-button, .tool-days input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.tool-days { gap: 4px; }
@media (max-width: 380px) { .tool-page { padding-left: 12px; padding-right: 12px; } .tool-card { padding: 14px 12px; } }
/* Throwing program generator output */
#tpg-result:empty { display: none; }
#tpg-result { margin-top: 18px; max-width: 100%; overflow-x: auto; }
@media (max-width: 640px) {
  #tpg-result table, #tpg-result tbody, #tpg-result tr, #tpg-result td { display: block; width: 100%; }
  #tpg-result thead { display: none; }
  #tpg-result tr { margin: 0 0 10px; padding: 10px 12px; border: 1px solid var(--border, rgba(255,255,255,.08)); border-radius: 12px; background: var(--surface, #101218); }
  #tpg-result td { border: 0; padding: 3px 0; }
  #tpg-result td[data-label]::before { content: attr(data-label) ": "; font-weight: 800; color: var(--text-soft, rgba(245,247,251,.7)); }
  #tpg-result td:first-child { font-weight: 900; font-size: 1.05rem; }
  #tpg-result td:first-child::before { content: ""; }
}
@media print { .tool-page { max-width: none; } }
@media (max-width: 640px) {
  #tpg-result caption { display: block; width: 100%; text-align: left; font-weight: 900; font-size: 1.05rem; line-height: 1.3; margin: 14px 0 8px; }
}
