.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: .4rem; padding-block: 1rem; color: var(--ink-500); font-size: .78rem; }
.breadcrumbs a { color: var(--link); text-underline-offset: .18em; }
.tool-hero { padding: clamp(1.75rem, 4vw, 3.5rem) 0; background: radial-gradient(circle at 90% 0%, var(--brand-100), transparent 38%), linear-gradient(145deg, #f9fcfb, var(--brand-050)); border-block: 1px solid var(--line-200); }
.tool-heading { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1.5rem 3rem; }
.tool-heading h1 { margin: .35rem 0 0; font-size: clamp(2rem, 6vw, 3.5rem); line-height: 1.2; letter-spacing: -.035em; }
.tool-heading > div:first-child > p:last-child { max-width: 42rem; margin-top: .8rem; color: var(--ink-700); }
.local-badge { display: flex; align-items: center; gap: .7rem; padding: .75rem 1rem; color: var(--brand-800); background: rgb(255 255 255 / .78); border: 1px solid var(--brand-100); border-radius: var(--radius-md); }
.local-badge > span { width: 1.75rem; height: 1.75rem; display: grid; place-items: center; color: #fff; background: var(--brand-700); border-radius: 50%; font-weight: 800; }
.local-badge strong, .local-badge small { display: block; line-height: 1.35; }
.local-badge small { color: var(--ink-500); font-size: .72rem; }
.tool-section { padding: clamp(2rem, 5vw, 4.5rem) 0; background: var(--canvas); }
.tool-layout { display: grid; gap: 1rem; align-items: start; }
.editor-panel, .result-panel { padding: clamp(1.1rem, 3vw, 1.75rem); background: var(--surface); border: 1px solid var(--line-200); border-radius: var(--radius-lg); }
.editor-panel { box-shadow: var(--shadow); }
.panel-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.panel-heading h2, .result-panel h2 { margin: .25rem 0 0; font-size: 1.2rem; }
.text-button { min-height: 2.75rem; padding: .45rem .75rem; color: var(--link); background: transparent; border: 0; border-radius: var(--radius-sm); text-decoration: underline; text-underline-offset: .18em; cursor: pointer; }
#counter-text { width: 100%; min-height: 19rem; margin-top: 1rem; padding: 1rem; resize: vertical; color: var(--ink-950); background: #fff; border: 2px solid var(--line-300); border-radius: var(--radius-md); font: inherit; line-height: 1.75; }
#counter-text:hover { border-color: var(--brand-700); }
#counter-text:focus { border-color: var(--brand-700); outline: 2px solid var(--focus); outline-offset: 2px; }
.editor-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem; margin-top: .85rem; }
.editor-actions > p { color: var(--ink-500); font-size: .8rem; }
.editor-actions > div { display: flex; flex-wrap: wrap; gap: .5rem; }
.primary-action, .secondary-action { min-height: 2.75rem; padding: .55rem .9rem; border-radius: var(--radius-md); font-weight: 700; cursor: pointer; }
.primary-action { color: #fff; background: var(--brand-700); border: 1px solid var(--brand-700); }
.secondary-action { color: var(--ink-700); background: var(--surface); border: 1px solid var(--line-300); }
.primary-action:disabled, .secondary-action:disabled { cursor: not-allowed; opacity: .48; }
.primary-count { display: flex; align-items: baseline; gap: .5rem; padding: 1.2rem 0; border-bottom: 1px solid var(--line-200); }
.primary-count strong { color: var(--brand-700); font-size: clamp(3.2rem, 9vw, 5rem); font-variant-numeric: tabular-nums; line-height: 1; }
.primary-count span { color: var(--ink-700); font-weight: 700; }
.stat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; margin-top: 1rem; }
.stat-grid > div { padding: .85rem; background: var(--canvas); border: 1px solid var(--line-200); border-radius: var(--radius-md); }
.stat-grid span, .stat-grid strong { display: block; }
.stat-grid > div > span { color: var(--ink-500); font-size: .72rem; }
.stat-grid strong { margin-top: .15rem; font-size: 1.25rem; font-variant-numeric: tabular-nums; }
.stat-grid strong small { color: var(--ink-500); font-size: .65rem; font-weight: 500; }
.count-options { display: grid; gap: .35rem; padding: 1rem 0 0; margin: 1.1rem 0 0; border: 0; border-top: 1px solid var(--line-200); }
.count-options legend { padding-top: 1rem; font-size: .78rem; font-weight: 700; }
.count-options label { min-height: 2.75rem; display: flex; align-items: center; gap: .55rem; font-size: .86rem; }
.count-options input { width: 1.1rem; height: 1.1rem; accent-color: var(--brand-700); }
.goal-control { padding-top: 1rem; border-top: 1px solid var(--line-200); }
.goal-control > label { font-size: .78rem; font-weight: 700; }
.goal-control > div:first-of-type { display: flex; align-items: center; gap: .5rem; margin-top: .45rem; }
.goal-control input { width: 8rem; min-height: 2.75rem; padding: .5rem .7rem; border: 1px solid var(--line-300); border-radius: var(--radius-md); }
.progress-track { height: .55rem; overflow: hidden; margin-top: .8rem !important; background: var(--line-200); border-radius: 999px; }
.progress-track span { width: 0; height: 100%; display: block; background: var(--brand-700); border-radius: inherit; transition: width 180ms ease; }
.goal-control > p { margin-top: .45rem; color: var(--ink-500); font-size: .75rem; }
.guide-section { padding: clamp(3.5rem, 7vw, 6rem) 0; }
.reading-layout { display: grid; gap: 2rem; align-items: start; }
.guide-content > h2, .faq-section h2, .related-section h2 { margin-top: .35rem; font-size: clamp(1.75rem, 4vw, 2.5rem); line-height: 1.3; }
.steps { display: grid; gap: .75rem; padding: 0; margin: 2rem 0 0; list-style: none; }
.steps li { display: flex; gap: 1rem; padding: 1.1rem; background: var(--canvas); border: 1px solid var(--line-200); border-radius: var(--radius-lg); }
.steps li > span { width: 2rem; height: 2rem; flex: 0 0 auto; display: grid; place-items: center; color: #fff; background: var(--brand-700); border-radius: 50%; font-size: .8rem; font-weight: 800; }
.steps h3 { font-size: 1rem; }
.steps p { margin-top: .2rem; color: var(--ink-700); font-size: .88rem; }
.definition-section { margin-top: 3rem; }
.definition-section h2 { font-size: 1.45rem; }
.definition-section dl { margin: 1rem 0 0; border-top: 1px solid var(--line-200); }
.definition-section dl > div { display: grid; gap: .3rem 1rem; padding: 1rem 0; border-bottom: 1px solid var(--line-200); }
.definition-section dt { font-weight: 700; }
.definition-section dd { margin: 0; color: var(--ink-700); }
.note { margin-top: 1rem; padding: 1rem; color: var(--ink-700); background: var(--accent-050); border-left: 4px solid var(--accent-700); border-radius: 0 var(--radius-md) var(--radius-md) 0; font-size: .84rem; }
.privacy-note { padding: 1.4rem; background: var(--brand-050); border: 1px solid var(--brand-100); border-radius: var(--radius-lg); }
.privacy-mark { width: 2.2rem; height: 2.2rem; display: grid; place-items: center; color: #fff; background: var(--brand-700); border-radius: 50%; font-weight: 800; }
.privacy-note h2 { margin-top: .8rem; font-size: 1.1rem; }
.privacy-note p { margin-top: .5rem; color: var(--ink-700); font-size: .86rem; }
.faq-section { padding: clamp(3.5rem, 7vw, 6rem) 0; background: var(--canvas); }
.reading-width { max-width: 52rem; }
.faq-list { margin-top: 1.5rem; border-top: 1px solid var(--line-300); }
.faq-list details { border-bottom: 1px solid var(--line-300); }
.faq-list summary { min-height: 3.5rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .8rem 0; font-weight: 700; cursor: pointer; list-style: none; }
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary::after { content: "+"; color: var(--brand-700); font-size: 1.3rem; }
.faq-list details[open] summary::after { content: "−"; }
.faq-list details p { padding: 0 0 1rem; color: var(--ink-700); }
.related-section { padding: clamp(3.5rem, 7vw, 5rem) 0; }
.related-grid { display: grid; gap: 1rem; margin-top: 1.5rem; }
.related-grid article { display: flex; gap: 1rem; padding: 1.25rem; background: var(--surface); border: 1px solid var(--line-200); border-radius: var(--radius-lg); }
.related-grid article div > span { color: var(--ink-500); font-size: .7rem; font-weight: 700; }
.related-grid h3 { margin-top: .1rem; font-size: 1rem; }
.related-grid h3 a { color: var(--link); text-underline-offset: .18em; }
.related-grid p { margin-top: .25rem; color: var(--ink-700); font-size: .85rem; }
@media (min-width: 58rem) { .tool-layout { grid-template-columns: minmax(0, 1.45fr) minmax(18rem, .55fr); } .result-panel { position: sticky; top: 5.5rem; } }
@media (min-width: 52rem) { .reading-layout { grid-template-columns: minmax(0, 1fr) 18rem; } .privacy-note { position: sticky; top: 5.5rem; } .definition-section dl > div { grid-template-columns: 9rem minmax(0, 1fr); } .related-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 40rem) { .tool-heading { align-items: stretch; } .local-badge { width: 100%; } #counter-text { min-height: 16rem; } .editor-actions, .editor-actions > div { align-items: stretch; flex-direction: column; width: 100%; } .editor-actions button { width: 100%; } }
@media (prefers-reduced-motion: reduce) { .progress-track span { transition: none; } }
