* { box-sizing: border-box; }
body {
    font-family: Segoe UI, Arial, sans-serif;
    background: #f4f5f7;
    margin: 0;
    color: #222;
}
.topbar {
    background: #1f2a44;
    color: #fff;
    padding: 24px 32px;
}
.topbar h1 { margin: 0 0 4px; font-size: 24px; }
.topbar p { margin: 0 0 12px; opacity: .8; font-size: 14px; }
.topnav a {
    color: #cfe0ff; text-decoration: none; margin-right: 18px; font-weight: 600; font-size: 14px;
}
.topnav a:hover { color: #fff; text-decoration: underline; }
.container { max-width: 1200px; margin: 0 auto; padding: 24px 32px 64px; }

.upload-card {
    background: #fff;
    border-radius: 10px;
    padding: 20px 24px;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
    margin-bottom: 20px;
}
.upload-card h2 { margin: 0 0 12px; font-size: 16px; }
.upload-card form { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.upload-card label { font-weight: 600; font-size: 14px; flex-basis: 100%; }
.upload-card input[type=file] { flex: 1; min-width: 220px; }
.upload-card button {
    background: #2f6fed; color: #fff; border: none;
    padding: 10px 18px; border-radius: 6px; font-weight: 600; cursor: pointer;
}
.upload-card button:hover { background: #2559c4; }
.upload-card .hint { margin: 8px 0 0; font-size: 12px; color: #777; }
.upload-card label.mt { margin-top: 4px; }

.error { color: #c0362c; margin: 12px 0; font-weight: 600; }
.muted { color: #888; font-size: 12px; }

.results { margin-top: 28px; }
.results-header {
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 12px; margin-bottom: 16px;
}
.results-header h2 { font-size: 18px; margin: 0; }
.download-btn {
    background: #1f8a4c; color: #fff; text-decoration: none;
    padding: 10px 18px; border-radius: 6px; font-weight: 600;
}
.download-btn:hover { background: #17703c; }

.table-wrap { overflow-x: auto; background: #fff; border-radius: 10px; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.records-table { border-collapse: collapse; width: 100%; font-size: 13px; }
.records-table th, .records-table td {
    padding: 8px 10px; border-bottom: 1px solid #eee; text-align: left; white-space: nowrap;
}
.records-table th { background: #f7f8fa; font-weight: 700; }
.records-table tr:hover { background: #fafbff; }
.thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 4px; }

.hint { font-size: 12px; color: #777; margin-top: 10px; }
.hint code { background: #eee; padding: 1px 5px; border-radius: 3px; }
