﻿:root {
    --bg: #f3efe6;
    --card: rgba(255, 252, 246, 0.88);
    --ink: #1f2933;
    --muted: #556371;
    --line: rgba(31, 41, 51, 0.12);
    --accent: #d97706;
    --accent-ink: #fffaf0;
    --success: #166534;
    --warning: #b45309;
    --danger: #b91c1c;
    --shadow: 0 18px 50px rgba(31, 41, 51, 0.12);
    --font: "IBM Plex Sans", "Noto Sans SC", sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font);
    color: var(--ink);
    background:
        radial-gradient(circle at top left, rgba(217, 119, 6, 0.14), transparent 32%),
        radial-gradient(circle at bottom right, rgba(20, 83, 45, 0.12), transparent 24%),
        var(--bg);
}

.page {
    width: min(920px, calc(100% - 32px));
    margin: 0 auto;
    padding: 40px 0 56px;
}

.hero {
    padding: 24px 0 8px;
}

.eyebrow {
    margin: 0 0 8px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--warning);
}

h1 {
    margin: 0;
    font-size: clamp(32px, 5vw, 52px);
    line-height: 1.05;
}

h2,
h3 {
    margin: 0;
}

.lead {
    margin: 16px 0 0;
    max-width: 680px;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.7;
}

.panel {
    margin-top: 24px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: var(--card);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
}

.label {
    display: block;
    margin-bottom: 12px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}

textarea {
    width: 100%;
    min-height: 200px;
    resize: vertical;
    padding: 18px;
    border: 1px solid rgba(31, 41, 51, 0.16);
    border-radius: 18px;
    font: inherit;
    color: var(--ink);
    background: rgba(255, 255, 255, 0.84);
}

textarea:focus {
    outline: 2px solid rgba(217, 119, 6, 0.28);
    border-color: rgba(217, 119, 6, 0.45);
}

.actions,
.task-header,
.resolve-group-header,
.group-toolbar,
.result-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.actions,
.task-header {
    margin-top: 18px;
}

.actions {
    justify-content: flex-start;
    align-items: flex-start;
    flex-wrap: wrap;
}

.actions .hint {
    flex-basis: 100%;
}

.progress-widget {
    padding: 18px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.72);
    margin-bottom: 20px;
}

.progress-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.progress-percent {
    font-size: 28px;
    font-weight: 700;
    color: var(--accent);
}

.progress-bar-track {
    height: 12px;
    border-radius: 999px;
    background: rgba(31, 41, 51, 0.08);
    overflow: hidden;
    margin-top: 14px;
}

.progress-bar-fill {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #d97706, #14532d);
    transition: width 0.25s ease;
}

.tab-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

button,
.download,
.page-button,
.tab-button,
.accordion-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 20px;
    border: 0;
    border-radius: 999px;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

button,
.page-button,
.tab-button.active {
    background: var(--accent);
    color: var(--accent-ink);
}

.button-secondary,
.page-button,
.tab-button,
.accordion-toggle {
    background: rgba(31, 41, 51, 0.08);
    color: var(--ink);
}

button:disabled,
.page-button:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.download {
    margin-top: 16px;
    background: #14532d;
    color: #f0fdf4;
}

.hint {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.badge,
.group-tag {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0 14px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    background: rgba(180, 83, 9, 0.14);
    color: var(--warning);
}

.badge.success,
.group-tag.single,
.result-item-status.success {
    background: rgba(22, 101, 52, 0.14);
    color: var(--success);
}

.badge.failed,
.result-item-status.failed {
    background: rgba(185, 28, 28, 0.14);
    color: var(--danger);
}

.empty-state {
    padding: 40px 20px;
    border: 1px dashed rgba(31, 41, 51, 0.16);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.6);
    text-align: center;
}

.empty-state p {
    margin: 10px auto 0;
    max-width: 460px;
    color: var(--muted);
    line-height: 1.7;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.metric-card {
    padding: 14px 16px;
    border-radius: 16px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.82);
}

.metric-card.success {
    background: rgba(22, 101, 52, 0.08);
}

.metric-card.failed {
    background: rgba(185, 28, 28, 0.08);
}

.metric-card.running {
    background: rgba(180, 83, 9, 0.08);
}

.metric-label {
    display: block;
    color: var(--muted);
    font-size: 13px;
}

.metric-card strong {
    display: block;
    margin-top: 6px;
    font-size: 26px;
    line-height: 1;
}

.resolve-list,
.result-list {
    list-style: none;
    padding: 0;
    margin: 20px 0 0;
    display: grid;
    gap: 12px;
}

.resolve-group,
.result-item {
    padding: 16px 18px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.78);
}

.resolve-source {
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 13px;
    word-break: break-all;
}

.group-title-wrap {
    min-width: 0;
    flex: 1;
}

.group-header-actions,
.result-item-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.group-toolbar {
    margin-top: 16px;
    flex-wrap: wrap;
}

.accordion-toggle {
    min-height: 38px;
    padding: 0 14px;
}

.accordion-body {
    margin-top: 16px;
}

.option-list {
    display: grid;
    gap: 10px;
    margin-top: 16px;
}

.option-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid rgba(31, 41, 51, 0.08);
    background: rgba(255, 255, 255, 0.92);
    cursor: pointer;
}

.option-checkbox,
.group-select-all {
    margin-top: 3px;
    width: 16px;
    height: 16px;
    accent-color: var(--accent);
}

.option-content {
    display: grid;
    gap: 4px;
}

.option-title {
    font-weight: 700;
}

.option-link,
.result-meta,
.pagination-info,
.select-all-toggle {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.6;
    word-break: break-all;
}

.select-all-toggle {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.pagination.compact {
    margin-top: 0;
}

.page-button {
    min-height: 38px;
    padding: 0 14px;
}

.result-item-title-wrap {
    min-width: 0;
    flex: 1;
}

.result-item strong {
    display: block;
}

.result-item-status {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    background: rgba(180, 83, 9, 0.14);
    color: var(--warning);
}

.result-meta {
    margin: 0;
}

.hidden {
    display: none;
}

@media (max-width: 700px) {
    .page {
        width: min(100% - 20px, 920px);
        padding-top: 24px;
    }

    .actions,
    .task-header,
    .resolve-group-header,
    .group-toolbar,
    .pagination,
    .tab-bar,
    .progress-head,
    .result-item-header {
        flex-direction: column;
        align-items: stretch;
    }

    .group-header-actions,
    .result-item-title-wrap {
        width: 100%;
    }

    .metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    button,
    .download,
    .page-button,
    .tab-button,
    .accordion-toggle {
        width: 100%;
    }
}
