:root {
  color-scheme: light;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  color: #19291f;
  background: #f4f7f4;
  --green: #174a34;
  --muted: #4f6256;
  --border: #d6e0d8;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
.shell { max-width: 53rem; margin: auto; padding: 2.5rem 1.5rem; }
header { display: flex; align-items: center; gap: .65rem; font-weight: 650; margin-bottom: 1.75rem; }
.mark { display: inline-flex; align-items: center; gap: 3px; justify-content: center; width: 34px; height: 34px; border-radius: 10px; background: var(--green); }
.mark i { width: 2px; height: 9px; background: #d5ebaf; border-radius: 4px; }
.mark i:nth-child(2), .mark i:nth-child(4) { height: 14px; }
.mark i:nth-child(3) { height: 19px; }
.tool, .result { padding: clamp(1.15rem, 5vw, 2.5rem); border: 1px solid var(--border); border-radius: 17px; background: white; }
.tool { box-shadow: 0 8px 30px #20462c0b; }
h1 { margin: 0 0 1.75rem; font-size: clamp(1.9rem, 5.5vw, 3rem); letter-spacing: -.055em; line-height: 1.08; }
label { display: block; font-size: .9rem; font-weight: 650; margin-bottom: .5rem; }
.input-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .65rem; }
input, button { font: inherit; min-height: 48px; border-radius: 9px; }
input[type=url] { width: 100%; border: 1px solid #aebfb2; padding: .65rem .85rem; color: inherit; background: #fbfcfb; }
input::placeholder { color: #64746a; }
button { padding: .6rem .95rem; border: 1px solid #b8c9bc; background: white; color: var(--green); font-weight: 650; cursor: pointer; }
button:hover:not(:disabled) { background: #edf5ee; }
.primary, .primary:hover:not(:disabled) { color: white; background: var(--green); border-color: var(--green); padding-inline: 1.15rem; }
.primary:hover:not(:disabled) { background: #216444; }
:focus-visible { outline: 3px solid #3e8260; outline-offset: 3px; }
button:disabled { opacity: .66; cursor: wait; }
.hint, footer, #empty { color: var(--muted); font-size: .9rem; line-height: 1.5; }
#link-help { margin: .55rem 0 1rem; }
.file-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0 .65rem; position: relative; }
#file-help { min-width: 0; overflow-wrap: anywhere; }
.upload { color: var(--green); cursor: pointer; text-decoration: underline; text-underline-offset: .2em; min-height: 44px; display: flex; align-items: center; margin: 0; }
#file { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; }
.file-row:focus-within .upload { outline: 3px solid #3e8260; outline-offset: 3px; }
#notice:not(:empty) { margin: .8rem 0 0; padding: .75rem; background: #edf5ee; border-radius: 8px; overflow-wrap: anywhere; }
#notice[data-error] { color: #832e24; background: #fbefed; }
progress { width: 100%; height: 9px; accent-color: var(--green); margin-top: .85rem; }
.result { margin-top: 1rem; }
.result-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .7rem; }
h2 { margin: 0; font-size: 1.15rem; }
.actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.actions button { font-size: .875rem; min-height: 44px; }
#transcript { margin-top: 1rem; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.75; max-height: 32rem; overflow: auto; }
footer { padding: 1rem .15rem 0; }
footer p { margin: .3rem 0; }
footer a { color: var(--green); }
#copy-status:empty, #notice:empty { display: none; }
@media (max-width: 38rem) {
  .shell { padding: 1.1rem .85rem; }
  header { margin-bottom: 1rem; }
  .input-row { grid-template-columns: minmax(0, 1fr); }
}
