.auth-pending body { visibility: hidden; }
.crawler-page { padding-top: 96px; padding-bottom: 60px; }
.page-heading { display: flex; justify-content: space-between; gap: 24px; align-items: flex-end; margin-bottom: 22px; }
.page-heading h1 { margin: 4px 0 8px; font-size: clamp(28px, 4vw, 42px); color: #15243a; }
.page-heading p { margin: 0; color: #64748b; }
.eyebrow { color: #2563eb !important; font-size: 12px; font-weight: 800; letter-spacing: .14em; }
.panel, .worker-card { background: #fff; border: 1px solid #e2e8f0; border-radius: 18px; box-shadow: 0 12px 35px rgba(15, 23, 42, .06); }
.worker-card { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 20px; margin-bottom: 22px; }
.worker-card p { margin: 0; color: #64748b; font-size: 14px; }
.status-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 8px; box-shadow: 0 0 0 4px rgba(148,163,184,.18); }
.status-dot.online { background: #22c55e; box-shadow: 0 0 0 4px rgba(34,197,94,.16); }
.status-dot.busy { background: #f59e0b; box-shadow: 0 0 0 4px rgba(245,158,11,.16); }
.status-dot.offline { background: #94a3b8; }
.panel { padding: 24px; margin-bottom: 24px; }
.panel-title { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 20px; }
.panel-title h2 { margin: 0 0 6px; font-size: 22px; color: #1e293b; }
.panel-title p { margin: 0; color: #64748b; font-size: 14px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.compact-grid { grid-template-columns: minmax(0, 2fr) minmax(220px, 1fr); }
.form-group { margin-bottom: 18px; }
.form-group > label { display: block; margin-bottom: 8px; font-weight: 700; color: #334155; }
.form-group textarea, .form-group input, .form-group select { width: 100%; box-sizing: border-box; border: 1px solid #cbd5e1; border-radius: 12px; padding: 11px 13px; font: inherit; background: #fff; color: #0f172a; transition: border-color .2s, box-shadow .2s; }
.form-group textarea:focus, .form-group input:focus, .form-group select:focus { outline: none; border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.form-group small { display: block; color: #64748b; margin-top: 7px; line-height: 1.5; }
.platform-options { display: flex; flex-wrap: wrap; gap: 12px; }
.platform-options label { display: inline-flex; gap: 8px; align-items: center; padding: 10px 14px; border: 1px solid #dbe4ef; border-radius: 999px; background: #f8fafc; cursor: pointer; }
.platform-options input { accent-color: #2563eb; }
.task-estimate { padding: 11px 14px; background: #eff6ff; border-radius: 10px; color: #1d4ed8; font-weight: 700; margin-bottom: 16px; }
.form-actions { display: flex; align-items: center; gap: 14px; }
.primary-btn, .secondary-btn, .action-btn { border: 0; border-radius: 10px; padding: 10px 16px; font-weight: 700; cursor: pointer; transition: transform .15s, opacity .15s; }
.primary-btn { background: #2563eb; color: #fff; }
.secondary-btn { background: #e2e8f0; color: #334155; }
.primary-btn:hover, .secondary-btn:hover, .action-btn:hover { transform: translateY(-1px); }
.primary-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
#form-message { font-size: 14px; color: #475569; }
#form-message.success { color: #15803d; }
#form-message.error { color: #b91c1c; }
.table-wrap { overflow-x: auto; }
.task-table { width: 100%; border-collapse: collapse; min-width: 980px; }
.task-table th { text-align: left; font-size: 12px; letter-spacing: .03em; color: #64748b; background: #f8fafc; border-bottom: 1px solid #e2e8f0; padding: 12px; }
.task-table td { padding: 14px 12px; border-bottom: 1px solid #edf2f7; vertical-align: top; color: #334155; font-size: 14px; }
.task-table tr:last-child td { border-bottom: 0; }
.task-id { font-weight: 800; color: #0f172a; }
.task-sub { margin-top: 5px; color: #64748b; font-size: 12px; max-width: 280px; word-break: break-word; }
.status-badge { display: inline-flex; align-items: center; border-radius: 999px; padding: 5px 9px; font-size: 12px; font-weight: 800; }
.status-pending { background: #f1f5f9; color: #475569; }
.status-running { background: #fff7ed; color: #c2410c; }
.status-success { background: #ecfdf5; color: #15803d; }
.status-failed { background: #fef2f2; color: #b91c1c; }
.status-cancelled { background: #f1f5f9; color: #64748b; }
.progress-track { width: 150px; height: 8px; background: #e2e8f0; border-radius: 999px; overflow: hidden; margin: 4px 0 6px; }
.progress-bar { height: 100%; background: #2563eb; border-radius: inherit; transition: width .3s; }
.progress-text { color: #64748b; font-size: 12px; max-width: 220px; }
.actions { display: flex; flex-wrap: wrap; gap: 7px; }
.action-btn { padding: 7px 10px; font-size: 12px; background: #e2e8f0; color: #334155; text-decoration: none; display: inline-block; }
.action-btn.download { background: #dcfce7; color: #166534; }
.action-btn.cancel { background: #fee2e2; color: #991b1b; }
.details-row td { background: #f8fafc; padding-top: 0; }
.task-details { white-space: pre-wrap; max-height: 260px; overflow: auto; border: 1px solid #e2e8f0; border-radius: 10px; background: #0f172a; color: #dbeafe; padding: 12px; font: 12px/1.55 Consolas, monospace; }
.empty-cell { text-align: center; color: #94a3b8 !important; padding: 36px !important; }
@media (max-width: 760px) {
    .crawler-page { padding-top: 76px; }
    .page-heading, .worker-card { align-items: flex-start; flex-direction: column; }
    .form-grid, .compact-grid { grid-template-columns: 1fr; }
    .panel { padding: 18px; }
}
