*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 32px 16px;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: #0b1120;
    color: #e5e7eb;
}

.app {
    max-width: 980px;
    margin: 0 auto;
    background: radial-gradient(120% 160% at 0 0, #1e293b 0, #020617 55%);
    border-radius: 16px;
    padding: 24px 24px 32px;
    box-shadow:
        0 18px 45px rgba(0, 0, 0, 0.7),
        0 0 0 1px rgba(148, 163, 184, 0.25);
}

h1 {
    margin: 0 0 20px;
    font-size: 24px;
    font-weight: 650;
    letter-spacing: 0.03em;
    color: #e5e7eb;
}

.panel {
    background: rgba(15, 23, 42, 0.9);
    border-radius: 12px;
    padding: 16px 16px 20px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    margin-bottom: 16px;
}

label {
    display: block;
    font-size: 13px;
    color: #cbd5f5;
    margin-bottom: 6px;
}

input[type="text"] {
    width: 100%;
    padding: 10px 11px;
    border-radius: 8px;
    border: 1px solid rgba(148, 163, 184, 0.55);
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
}

input[type="text"]::placeholder {
    color: #6b7280;
}

input[type="text"]:focus {
    outline: 2px solid #4f46e5;
    outline-offset: 1px;
}

.buttons {
    margin-top: 14px;
    display: flex;
    gap: 8px;
}

.buttons.align-right {
    justify-content: flex-end;
}

.btn {
    border-radius: 999px;
    padding: 7px 18px;
    font-size: 13px;
    border: none;
    cursor: pointer;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.08) inset,
        0 12px 30px rgba(15, 23, 42, 0.85);
    transition: transform 0.08s ease, box-shadow 0.08s ease, background 0.12s ease, opacity 0.12s ease;
}

.btn.primary {
    background: linear-gradient(135deg, #4f46e5, #22c55e);
    color: #f9fafb;
}

.btn.danger {
    background: linear-gradient(135deg, #b91c1c, #f97316);
    color: #fef2f2;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.12) inset,
        0 16px 40px rgba(15, 23, 42, 0.95);
}

.btn:active {
    transform: translateY(0);
    box-shadow:
        0 0 0 rgba(0, 0, 0, 0.6);
}

.message {
    margin: 10px 0 16px;
    padding: 10px 12px;
    border-radius: 9px;
    font-size: 13px;
    background: rgba(17, 24, 39, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.5);
}

.file-block {
    margin-top: 16px;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.45);
    background: rgba(15, 23, 42, 0.97);
    overflow: hidden;
}

.file-header {
    padding: 10px 12px;
    border-bottom: 1px solid rgba(30, 64, 175, 0.8);
    background: linear-gradient(90deg, rgba(30, 64, 175, 0.4), rgba(15, 23, 42, 0.95));
    font-size: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    align-items: baseline;
}

.file-header .mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 11px;
    color: #e5e7eb;
}

.file-header .count {
    font-size: 11px;
    color: #bfdbfe;
}

.table-wrapper {
    max-height: 360px;
    overflow: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

thead {
    position: sticky;
    top: 0;
    background: #020617;
    z-index: 1;
}

th, td {
    padding: 6px 8px;
    border-bottom: 1px solid rgba(31, 41, 55, 0.9);
}

th {
    text-align: left;
    font-weight: 500;
    color: #cbd5f5;
}

td {
    color: #e5e7eb;
}

tr:nth-child(even) td {
    background: rgba(15, 23, 42, 0.65);
}

tr:nth-child(odd) td {
    background: rgba(15, 23, 42, 0.4);
}

.mono {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.small {
    font-size: 11px;
    word-break: break-all;
}

.center {
    text-align: center;
}

input[type="checkbox"] {
    cursor: pointer;
}

@media (max-width: 640px) {
    body {
        padding: 16px 8px;
    }
    .app {
        padding: 16px;
    }
    th:nth-child(3),
    th:nth-child(4),
    td:nth-child(3),
    td:nth-child(4) {
        display: none;
    }
}
