:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #172033;
  background: #f5f7fb;
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: #f5f7fb; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .52; }
.shell { width: min(920px, calc(100% - 28px)); margin: 0 auto; padding: 52px 0 80px; }
.hero { position: relative; margin-bottom: 26px; }
.eyebrow { margin: 0 0 8px; color: #a51a64; font-size: 12px; font-weight: 800; letter-spacing: .14em; }
h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(30px, 6vw, 48px); letter-spacing: -.04em; }
h2 { margin-bottom: 0; font-size: 24px; }
.title-row { display: flex; align-items: center; gap: 15px; margin-bottom: 10px; }
.title-row h1 { margin-bottom: 0; }
.brand-logo { display: block; width: clamp(60px, 8vw, 72px); height: clamp(60px, 8vw, 72px); flex: none; object-fit: contain; }
.hero > p:last-child { max-width: 680px; color: #657089; line-height: 1.7; }
.source-contact { position: absolute; z-index: 20; top: 0; right: 0; }
.source-button { min-height: 38px; border-color: #e2b5ce; color: #8d1555; background: #fff7fb; }
.source-popover { position: absolute; top: 47px; right: 0; width: 228px; border: 1px solid #e2d9e1; border-radius: 14px; padding: 12px 13px; background: #fff; box-shadow: 0 16px 42px rgba(33, 45, 78, .16); }
.source-popover::before { content: ""; position: absolute; top: -6px; right: 25px; width: 10px; height: 10px; border-top: 1px solid #e2d9e1; border-left: 1px solid #e2d9e1; background: #fff; transform: rotate(45deg); }
.source-popover p { margin-bottom: 8px; color: #69748a; font-size: 12px; }
.qq-copy-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.source-popover strong { color: #172033; font-size: 18px; letter-spacing: .02em; }
.source-popover .copy-qq-button { min-height: 30px; height: 30px; border-radius: 8px; padding: 0 10px; flex: none; font-size: 13px; }
#qq-copy-message { color: #247a58; font-size: 12px; text-align: center; }
#qq-copy-message:empty { display: none; }
#qq-copy-message:not(:empty) { display: block; margin-top: 7px; }
.panel, .task-card { border: 1px solid #e2e7f0; border-radius: 18px; background: #fff; box-shadow: 0 10px 34px rgba(33, 45, 78, .06); }
.submit-panel { padding: 24px; }
.fixed-settings { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 22px; }
.fixed-settings span { padding: 13px 15px; border-radius: 12px; background: #f7f8fc; }
.fixed-settings small, .fixed-settings b { display: block; }
.fixed-settings small { color: #7a8499; font-size: 12px; }
.fixed-settings b { margin-top: 4px; }
label { display: block; margin-bottom: 8px; font-weight: 750; }
textarea { width: 100%; resize: vertical; border: 1px solid #cfd6e4; border-radius: 12px; padding: 14px; color: #172033; background: #fbfcfe; line-height: 1.55; outline: none; }
input { width: 100%; min-height: 48px; border: 1px solid #cfd6e4; border-radius: 12px; padding: 0 14px; color: #172033; background: #fbfcfe; outline: none; }
input:focus, textarea:focus { border-color: #b9347b; box-shadow: 0 0 0 3px rgba(185, 52, 123, .12); }
.proxy-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 18px; }
.proxy-grid label { margin-bottom: 7px; }
.proxy-grid small { display: block; margin-top: 7px; color: #788299; font-size: 12px; line-height: 1.45; }
.proxy-label-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 7px; }
.proxy-label-row label { margin-bottom: 0; }
.proxy-test { min-height: 32px; padding: 0 11px; font-size: 12px; }
.proxy-test-result { display: block; min-height: 18px; margin-top: 7px; color: #667189; font-size: 12px; line-height: 1.45; }
.proxy-test-result.passed { color: #16704b; }
.proxy-test-result.failed { color: #a1263d; }
.remember-proxy-option { display: flex; align-items: flex-start; gap: 10px; margin: 4px 0 13px; border-radius: 11px; padding: 11px 12px; color: #344058; background: #f7f8fc; cursor: pointer; }
.remember-proxy-option input { width: 17px; height: 17px; min-height: 0; margin: 2px 0 0; padding: 0; flex: none; accent-color: #a51a64; }
.remember-proxy-option span, .remember-proxy-option small { display: block; }
.remember-proxy-option b { font-size: 13px; }
.remember-proxy-option small { margin-top: 3px; color: #788299; font-size: 12px; line-height: 1.45; }
.privacy { margin: 9px 0 18px; color: #788299; font-size: 13px; line-height: 1.55; }
.form-row, .section-heading, .task-top, .task-bottom, .result, .progress-copy { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.primary, .secondary { min-height: 40px; border-radius: 10px; padding: 0 17px; font-weight: 750; }
.primary { border: 1px solid #a51a64; color: #fff; background: #a51a64; }
.secondary { border: 1px solid #d4dae7; color: #344058; background: #fff; }
.message { color: #9c285f; font-size: 14px; }
.tasks-section { margin-top: 38px; }
.section-heading { margin-bottom: 16px; }
.connection { color: #7b859b; font-size: 13px; }
.connection::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: #b7bdc9; }
.connection.online { color: #247a58; }
.connection.online::before { background: #36b37e; }
.task-list { display: grid; gap: 14px; }
.task-card { padding: 20px; }
.task-top > div { display: flex; align-items: center; gap: 10px; min-width: 0; }
.task-top strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-top time, .task-bottom { color: #7a8499; font-size: 13px; }
.status { flex: none; border-radius: 999px; padding: 5px 9px; font-size: 12px; font-weight: 800; background: #fff1d8; color: #9b6200; }
.status-succeeded { color: #16704b; background: #ddf7ea; }
.status-failed, .status-cancelled { color: #a1263d; background: #fde5e9; }
.progress-copy { margin-top: 18px; font-size: 13px; color: #5f6a81; }
.progress { height: 7px; margin: 7px 0 18px; overflow: hidden; border-radius: 99px; background: #e9edf4; }
.progress i { display: block; height: 100%; border-radius: inherit; background: #a51a64; transition: width .25s ease; }
.error { margin: 14px 0; border-radius: 10px; padding: 12px; color: #9d2840; background: #fff1f3; line-height: 1.5; }
.result { margin: 15px 0; border-radius: 12px; padding: 12px; background: #f7f8fc; }
.result a { min-width: 0; overflow-wrap: anywhere; color: #235cad; line-height: 1.45; }
.task-bottom { margin-top: 14px; }
.empty { border: 1px dashed #cfd6e4; border-radius: 14px; padding: 44px 20px; text-align: center; color: #8790a4; }

@media (max-width: 640px) {
  .shell { padding-top: 30px; }
  .source-contact { position: relative; display: flex; justify-content: flex-end; margin-bottom: 14px; }
  .source-popover { top: 45px; width: min(280px, calc(100vw - 28px)); }
  .title-row { gap: 12px; }
  .brand-logo { width: 58px; height: 58px; }
  .submit-panel, .task-card { padding: 16px; }
  .fixed-settings { grid-template-columns: 1fr; }
  .proxy-grid { grid-template-columns: 1fr; }
  .task-top, .result { align-items: flex-start; flex-direction: column; }
  .result .primary { width: 100%; }
}
