:root {
    --bg: #f5f6f7;
    --surface: #ffffff;
    --text: #1b1f23;
    --muted: #68717a;
    --line: #e1e4e8;
    --accent: #0b5cad;
    --danger: #c4320a;
    --good: #116b3f;
    --warn: #8a5a00;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font: 15px/1.5 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
}

a { color: inherit; }

.top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 18px max(16px, calc((100% - 1040px) / 2));
    background: var(--surface);
    border-bottom: 1px solid var(--line);
}

.top h1 { margin: 0; font-size: 22px; }
.top p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }

main { max-width: 1072px; margin: 0 auto; padding: 16px; }

button {
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface);
    color: var(--text);
    font: inherit;
    padding: 8px 14px;
    cursor: pointer;
}

button.primary { background: var(--accent); border-color: var(--accent); color: #fff; white-space: nowrap; }

.notice { padding: 10px 12px; background: #e7f1fb; border-radius: 6px; margin-top: 0; }

.sources {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 8px;
}

.source {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 10px 12px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 6px;
    font-size: 13px;
    overflow-wrap: anywhere;
}

.muted { color: var(--muted); }
.error { color: var(--danger); }

.links { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 14px 0; font-size: 14px; }
.links a { color: var(--accent); }

.filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    padding: 12px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 6px;
}

.filters input[type="search"] { flex: 1 1 240px; min-width: 0; }

.filters input[type="search"], .filters select {
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 8px 10px;
    font: inherit;
    background: var(--surface);
    color: var(--text);
}

.filters label { display: inline-flex; gap: 5px; align-items: center; font-size: 14px; }

.regions {
    flex: 1 0 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    margin: 4px 0 0;
    padding: 10px 0 0;
    border: 0;
    border-top: 1px solid var(--line);
}

.regions legend { float: left; width: 100%; padding: 0; margin-bottom: 4px; font-size: 13px; font-weight: 600; }

.count { margin: 14px 2px 8px; }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); }

.jobs { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 6px; }

.jobs li { display: grid; grid-template-columns: 36px 1fr 118px; gap: 8px; padding: 14px 12px; border-top: 1px solid var(--line); }
.jobs li:first-child { border-top: 0; }

.star { border: 0; background: none; color: #c6ccd2; font-size: 20px; line-height: 1; padding: 2px; height: 30px; }
.star.on { color: #e0a100; }

.body { min-width: 0; }
.title { font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.title:hover { text-decoration: underline; }

.meta { display: flex; flex-wrap: wrap; gap: 2px 10px; margin-top: 3px; color: var(--muted); font-size: 13px; }

.tags { display: flex; gap: 6px; margin-top: 6px; }
.tag { padding: 1px 7px; border-radius: 4px; font-size: 12px; background: #eef0f2; }
.tag.regular { background: #e3f4ea; color: var(--good); }
.tag.check { background: #fbf0d9; color: var(--warn); }
.tag.new { background: #e7f1fb; color: var(--accent); }

.deadline { display: flex; flex-direction: column; align-items: flex-end; text-align: right; font-size: 13px; }
.deadline strong { font-size: 15px; }
.deadline .soon { color: var(--danger); }

.pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; margin: 18px 0; }
.pages a { min-width: 34px; padding: 6px 8px; text-align: center; text-decoration: none; border-radius: 6px; background: var(--surface); border: 1px solid var(--line); }
.pages a.current { background: var(--accent); border-color: var(--accent); color: #fff; }

.footnote { color: var(--muted); font-size: 12px; text-align: center; }

@media (max-width: 620px) {
    .jobs li { grid-template-columns: 30px 1fr; }
    .deadline { grid-column: 2; flex-direction: row; gap: 8px; align-items: baseline; }
    .filters select { flex: 1 1 40%; }
}
