* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #f6f7f9;
  color: #1a1a1a;
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
}
.wrap { max-width: 720px; margin: 0 auto; padding: 20px 16px 64px; }

.tool {
  background: #fff;
  border: 1px solid #e6e8eb;
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
h1 { font-size: 22px; margin: 0 0 4px; }
.sub { margin: 0 0 16px; color: #6b7280; font-size: 14px; }

.box { display: flex; gap: 8px; flex-wrap: wrap; }
#url {
  flex: 1 1 240px; min-width: 0; min-height: 46px;
  padding: 12px 14px; font-size: 16px;
  border: 1px solid #d1d5db; border-radius: 10px; outline: none;
  background: #fff;
}
#url:focus { border-color: #2563eb; }

button {
  font-size: 16px; min-height: 46px; padding: 0 18px;
  border: 0; border-radius: 10px;
  background: #2563eb; color: #fff; cursor: pointer; font-weight: 600;
}
button:disabled { opacity: .6; cursor: default; }

#copy, #download {
  background: #eef2ff; color: #2563eb; font-weight: 600;
  font-size: 14px; min-height: 38px; padding: 0 12px;
}

.result-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; margin: 16px 0 8px; flex-wrap: wrap;
}
.result-label { font-weight: 600; font-size: 14px; color: #374151; }
.result-actions { display: flex; gap: 8px; }

.text {
  white-space: pre-wrap; word-break: break-word; overflow-wrap: anywhere;
  background: #f9fafb; border: 1px solid #e6e8eb; border-radius: 10px;
  padding: 14px; max-height: 420px; overflow: auto;
  font-size: 15px; margin: 0;
}

.status { margin-top: 12px; font-size: 14px; color: #6b7280; min-height: 20px; }
.status.err { color: #b91c1c; }

.info { margin-top: 28px; }
.info h2 { font-size: 17px; margin: 22px 0 8px; }
.info p, .info li, .info dd { color: #374151; font-size: 15px; }
.info code { background: #eef2ff; padding: 1px 5px; border-radius: 5px; font-size: 13px; }
.info dt { font-weight: 600; margin-top: 10px; }
.info ul, .info ol { padding-left: 20px; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}

@media (max-width: 480px) {
  .box { flex-direction: column; }
  #url { width: 100%; }
  button { width: 100%; }
  .result-bar { flex-direction: column; align-items: stretch; }
  .result-actions { justify-content: flex-end; }
}
