/* Free tool pages. Loaded after landing.css. */
.crumbs { max-width: 1160px; margin: 0 auto; padding: 18px 20px 0; font-size: 14px; color: var(--muted); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--accent); }
.crumbs span[aria-hidden] { margin: 0 6px; }

.tool-head { max-width: 760px; margin: 0 auto; padding: 28px 20px 8px; text-align: center; }
.tool-head h1 { font-size: clamp(32px, 4.4vw, 48px); line-height: 1.08; }
.tool-head .lead { margin: 14px auto 0; font-size: 18px; }

.tool { max-width: 760px; margin: 24px auto 0; padding: 0 20px; }
.panel { background: #fff; border: 1px solid var(--line); border-radius: 22px; padding: 24px; box-shadow: 0 10px 30px rgba(28, 31, 88, .07); }
.panel + .panel { margin-top: 16px; }
.panel h2 { font-size: 22px; margin-bottom: 10px; }
.fields { display: grid; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > label, .field > .lbl { font-weight: 700; font-size: 14.5px; }
.field input[type=text], .field input[type=number], .field input[type=date], .field select, .field textarea {
  font: inherit; font-size: 17px; color: var(--ink); background: #fff; border: 1.5px solid #d5d6e0; border-radius: 12px; padding: 12px 14px; width: 100%; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(84, 91, 254, .18); }
.field textarea { min-height: 120px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 15px; }
.mono, .field input.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .04em; }
.field .hint { font-size: 13.5px; color: var(--muted); margin: 0; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.seg { display: flex; flex-wrap: wrap; gap: 6px; background: var(--soft); border-radius: 14px; padding: 4px; }
.seg label { flex: 1 1 auto; text-align: center; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: block; padding: 9px 12px; border-radius: 10px; font-weight: 600; font-size: 14.5px; color: var(--accent-dark); }
.seg input:checked + span { background: #fff; color: var(--ink); box-shadow: 0 1px 4px rgba(28, 31, 88, .15); }
.seg input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 1px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.chips button { font: inherit; font-weight: 700; padding: 8px 16px; border-radius: 100px; border: 1.5px solid #d5d6e0; background: #fff; color: var(--ink); cursor: pointer; }
.chips button.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chips select { width: auto; padding: 8px 12px; font-size: 15px; border-radius: 100px; }

.out { margin-top: 20px; border-top: 1px dashed #d5d6e0; padding-top: 18px; }
.res { margin: 0; display: flex; flex-direction: column; gap: 2px; }
.res > div { display: flex; justify-content: space-between; gap: 16px; padding: 7px 0; }
.res dt { color: var(--muted); }
.res dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.res .sub { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 10px; }
.res .total { font-size: 20px; }
.res .total dt { color: var(--ink); font-weight: 700; }
.res .total dd { font-family: "Fraunces", Georgia, serif; font-size: 26px; }
.words { margin: 10px 0 0; background: var(--bg); border-radius: 12px; padding: 10px 14px; font-weight: 600; font-size: 15px; }
.words.big { font-size: 20px; line-height: 1.4; }
.verdict { display: flex; flex-direction: column; gap: 4px; border-radius: 14px; padding: 12px 16px; margin-bottom: 10px; }
.verdict.ok { background: #e7f6ef; color: var(--ok); }
.verdict.bad { background: #fdecec; color: #b42318; }
.verdict span { color: var(--ink); font-size: 14.5px; }
.ok { color: var(--ok); font-weight: 700; }
.bad { color: #b42318; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.tbl { width: 100%; border-collapse: collapse; font-size: 15px; text-align: left; }
.tbl th, .tbl td { padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl th { background: var(--bg); font-size: 13.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.tbl tr:last-child td { border-bottom: 0; }
.tbl td:first-child { font-weight: 700; white-space: nowrap; }

.prose { max-width: 720px; margin: 0 auto; padding: 56px 20px 0; text-align: left; }
.prose h2 { font-size: clamp(24px, 3vw, 30px); line-height: 1.2; margin: 36px 0 12px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 18px; margin: 22px 0 6px; }
.prose p, .prose li { color: #2f3260; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose .table-wrap { margin: 16px 0; }
.prose .note { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--sun); border-radius: 12px; padding: 12px 16px; }
.formula { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 15px; }

.sample { margin: 20px 0; background: #f4efe1; border-radius: 18px; padding: 16px; }
.sample img { border-radius: 6px; box-shadow: 0 10px 30px rgba(0, 0, 0, .14); background: #fff; margin: 0 auto; }
.sample figcaption { font-size: 14px; color: var(--muted); text-align: center; margin-top: 10px; }

.cta-band { max-width: 760px; margin: 56px auto 0; padding: 0 20px; }
.cta-band > div { background: var(--ink); color: #fff; border-radius: 26px; padding: 32px 28px; text-align: center; }
.cta-band h2 { color: #fff; font-size: clamp(24px, 3vw, 32px); }
.cta-band p { color: #c9caf0; margin: 10px auto 20px; max-width: 32em; }

.related { max-width: 1160px; margin: 0 auto; padding: 64px 20px 24px; }
.related > h2 { font-size: 26px; text-align: center; margin-bottom: 20px; }
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.tool-card { display: flex; flex-direction: column; gap: 4px; background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 18px 20px; text-decoration: none; color: var(--ink); transition: transform .15s, box-shadow .15s; }
.tool-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(28, 31, 88, .12); }
.tool-card .ic { width: 38px; height: 38px; border-radius: 12px; background: var(--soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; margin-bottom: 6px; }
.tool-card b { font-size: 16.5px; }
.tool-card span { color: var(--muted); font-size: 14.5px; line-height: 1.45; }

.faq-wrap { max-width: 760px; margin: 0 auto; padding: 56px 20px 0; }
.faq-wrap > h2 { font-size: clamp(24px, 3vw, 30px); text-align: center; }
.faq-wrap .faq { margin-top: 20px; }
.foot .tools-nav { flex-basis: 100%; font-size: 14px; color: var(--muted); gap: 6px 16px; }
.foot .tools-nav b { color: var(--ink); }

/* HSN / SAC finder */
.search-row { display: flex; gap: 8px; }
.search-row input { flex: 1; min-width: 0; }
.status { min-height: 1.4em; margin: 12px 0 0; font-size: 14px; color: var(--muted); }
.hits { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.hit { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }
.hit-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hit .code { font: 700 19px ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .03em; color: var(--ink); background: var(--soft); border: 0; border-radius: 10px; padding: 3px 10px; cursor: copy; }
.tag { font-size: 12.5px; font-weight: 700; color: var(--muted); background: var(--bg); border-radius: 100px; padding: 3px 10px; }
.tag.good { color: var(--ok); background: #e7f6ef; }
.hit-desc { margin: 8px 0 0; font-weight: 600; }
.hit-path { margin: 6px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.5; }
.hit-path a { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-weight: 700; text-decoration: none; }
.hit .row { margin-top: 10px; }
.hits .none { background: #fff; border: 1px dashed #d5d6e0; border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 6px; color: var(--muted); }
.hits .none b { color: var(--ink); }
.chapters { list-style: none; padding: 0; margin: 14px 0 0; columns: 2; column-gap: 24px; font-size: 14.5px; }
.chapters li { break-inside: avoid; padding: 4px 0; }
.chapters a { text-decoration: none; color: var(--ink); }
.chapters a b { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--accent); margin-right: 6px; }
.chapters a:hover { color: var(--accent); }
@media (max-width: 640px) { .chapters { columns: 1; } .search-row .btn { width: auto; } }

[hidden] { display: none !important; }
@media (max-width: 640px) {
  .two { grid-template-columns: 1fr; }
  .panel { padding: 18px; border-radius: 18px; }
  .tool, .prose, .cta-band, .faq-wrap, .crumbs, .tool-head { padding-left: 16px; padding-right: 16px; }
  .res .total dd { font-size: 22px; }
  .chips button { padding: 8px 13px; }
  .row .btn { width: auto; }
}

/* Late fee calculator */
.check { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15px; cursor: pointer; }
.check input { width: 20px; height: 20px; accent-color: var(--accent); }
[data-for][hidden] { display: none; }
.disclaimer { max-width: 720px; margin: 8px auto 32px; padding: 0 20px; font-size: 13.5px; color: var(--muted); }
.disclaimer a { color: var(--muted); }

/* phone: 16px fields stop iOS from zooming in when a field is tapped */
@media (max-width: 860px) {
  input, select, textarea { font-size: 16px !important; }
  .updates input { font-size: 16px; }
}
