/* Hallmark · existing results table · compact density · blue anchor.
   Results page only. Keep the market, sidebar and all business logic unchanged. */
html body .app-shell-resultcheck.resultcheck-compact {
    --result-surface: #ffffff;
    --result-heading: #f3f6fa;
    --result-line: #dde5ed;
    --result-ink: #162d45;
    --result-muted: #64748b;
    --result-winner: #f0faf5;
    --result-winner-hover: #e4f5ec;
    --result-hover: #f7f9fc;
    --result-link: #075bc8;
    --result-sales: #233e56;
    --result-discount: #64748b;
    --result-net: #153c61;
    --result-pending: #936009;
    --result-button: #f0f6ff;
    --result-button-line: #c9dbf2;
    --result-focus: #075bc8;
    background: #f5f7fa !important;
    color: var(--result-ink);
    font-family: var(--font-body, "Prompt", "Noto Sans Thai", sans-serif);
}

html body .app-shell-resultcheck.resultcheck-compact .resultcheck-topbar {
    background: var(--result-surface) !important;
    border-bottom: 1px solid var(--result-line) !important;
    box-shadow: none !important;
}
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-topbar h1 { font-size: 20px !important; }
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-content {
    max-width: 1280px !important;
    width: 100%;
    padding: 16px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-content > * + * { margin-top: 12px !important; }
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-toolbar {
    margin: 16px 16px 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    gap: 16px;
}
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-buttons {
    padding: 4px;
    gap: 4px;
    border: 1px solid var(--result-line);
    border-radius: 10px;
    background: var(--result-surface);
}
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-button {
    min-height: 32px;
    padding: 4px 16px;
    border: 0;
    border-radius: 6px;
    font-size: 13px;
}
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-button.is-active {
    background: var(--result-link);
    color: #fff;
}
html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-caption { color: var(--result-muted); font-size: 13px; }
html body .app-shell-resultcheck.resultcheck-compact .result-market-card {
    border: 1px solid var(--result-line) !important;
    border-radius: 12px !important;
    background: var(--result-surface) !important;
    box-shadow: none !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-market-card__header {
    padding: 8px 12px !important;
    gap: 8px !important;
    border-bottom: 1px solid var(--result-line);
    background: var(--result-surface) !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-market-card__identity {
    flex-wrap: wrap;
    gap: 4px 8px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-market-card__identity h2 {
    color: var(--result-ink) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.5;
}
html body .app-shell-resultcheck.resultcheck-compact .result-market-card__identity img {
    width: 24px !important;
    height: 16px !important;
    border-radius: 3px !important;
    box-shadow: none !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-market-chip {
    font-size: 11px !important;
    padding: 2px 6px !important;
    border: 0 !important;
    background: var(--result-heading) !important;
    color: var(--result-muted) !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-entry-controls {
    flex-wrap: wrap;
    gap: 6px !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-number-input {
    width: 52px !important;
    height: 32px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    font-variant-numeric: tabular-nums;
    color: var(--result-ink) !important;
    background: var(--result-heading) !important;
    border: 1px solid var(--result-line) !important;
    border-radius: 6px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-number-input::placeholder { font-size: 12px; color: var(--result-muted); }
html body .app-shell-resultcheck.resultcheck-compact .result-entry-controls button {
    min-height: 32px !important;
    padding: 4px 8px !important;
    font-size: 12px !important;
    border-radius: 6px !important;
    box-shadow: none !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-auto-status {
    max-width: 240px !important;
    padding: 4px 8px !important;
    font-size: 11px !important;
    line-height: 1.5 !important;
    border-radius: 6px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-table-wrap { overflow-x: auto; }
html body .app-shell-resultcheck.resultcheck-compact .result-table {
    min-width: 720px !important;
    width: 100% !important;
    table-layout: fixed;
    font-size: 13px !important;
    font-variant-numeric: tabular-nums;
}
html body .app-shell-resultcheck.resultcheck-compact .result-col-date { width: 16%; }
html body .app-shell-resultcheck.resultcheck-compact .result-col-amount { width: 11%; }
html body .app-shell-resultcheck.resultcheck-compact .result-col-discount { width: 10%; }
html body .app-shell-resultcheck.resultcheck-compact .result-col-net { width: 11%; }
html body .app-shell-resultcheck.resultcheck-compact .result-col-outcome { width: 17%; }
html body .app-shell-resultcheck.resultcheck-compact .result-col-customer { width: 18%; }
html body .app-shell-resultcheck.resultcheck-compact .result-col-details { width: 17%; }
html body .app-shell-resultcheck.resultcheck-compact .result-table th,
html body .app-shell-resultcheck.resultcheck-compact .result-table td {
    padding: 6px 8px !important;
    border: 0 !important;
    border-bottom: 1px solid var(--result-line) !important;
    line-height: 1.6 !important;
    vertical-align: middle;
}
html body .app-shell-resultcheck.resultcheck-compact .result-table thead th {
    background: var(--result-heading) !important;
    color: var(--result-muted) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-cell-date {
    white-space: normal !important;
    color: var(--result-muted) !important;
    font-size: 11px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-cell-customer { overflow-wrap: anywhere; white-space: normal !important; }
html body .app-shell-resultcheck.resultcheck-compact .result-cell-net { font-weight: 600 !important; }
html body .app-shell-resultcheck.resultcheck-compact .result-table tfoot th,
html body .app-shell-resultcheck.resultcheck-compact .result-table tfoot td {
    background: var(--result-heading) !important;
    border-bottom: 0 !important;
    font-weight: 600 !important;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-status-text { font-size: 12px !important; }
html body .app-shell-resultcheck.resultcheck-compact .result-status-text.is-waiting {
    display: inline-block;
    background: #fff4d9;
    color: #80570d !important;
    border-radius: 5px;
    padding: 4px 10px;
}
html body .app-shell-resultcheck.resultcheck-compact .result-status-text.is-lost,
html body .app-shell-resultcheck.resultcheck-compact .result-status-text.is-cancelled { color: var(--result-muted) !important; }
html body .app-shell-resultcheck.resultcheck-compact .result-status-text.is-won { color: #087443 !important; font-size: 14px !important; font-weight: 600; }
html body .app-shell-resultcheck.resultcheck-compact .result-row-actions { gap: 6px !important; }
html body .app-shell-resultcheck.resultcheck-compact .result-row-action {
    min-height: 28px !important;
    padding: 4px 8px !important;
    font-size: 11px !important;
    border-radius: 5px !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-row-action.is-primary {
    padding: 4px 8px !important;
    color: var(--result-link) !important;
    background: var(--result-button) !important;
    border: 1px solid var(--result-button-line) !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-row-action.is-danger {
    color: #b42332 !important;
    border-color: #e9b6bd !important;
    background: #fff !important;
}
html body .app-shell-resultcheck.resultcheck-compact .result-copy-action { min-height: 28px !important; font-size: 10px !important; }
html body .app-shell-resultcheck.resultcheck-compact button:focus-visible,
html body .app-shell-resultcheck.resultcheck-compact input:focus-visible,
html body .app-shell-resultcheck.resultcheck-compact .result-table-wrap:focus-visible { outline: 2px solid var(--result-focus) !important; outline-offset: 3px; }
html body .app-shell-resultcheck.resultcheck-compact button:disabled { opacity: .55; cursor: not-allowed; }
html body .app-shell-resultcheck.resultcheck-compact .result-empty-state {
    margin-top: 0 !important;
    padding: 64px 24px;
    border: 1px dashed var(--result-line);
    border-radius: 12px;
    background: var(--result-surface);
    color: var(--result-muted) !important;
}
html body:not(.light-theme) .app-shell-resultcheck.resultcheck-compact {
    --result-winner: #173e32;
    --result-winner-hover: #1d4b3d;
    background: #101d2b !important;
}
html body:not(.light-theme) .app-shell-resultcheck.resultcheck-compact .result-status-text.is-won { color: #86dfa0 !important; }
html body:not(.light-theme) .app-shell-resultcheck.resultcheck-compact .resultcheck-day-button.is-active { background: #075bc8; }
@media (max-width: 1024px) {
    html body .app-shell-resultcheck.resultcheck-compact .resultcheck-content { padding: 16px !important; }
    html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-toolbar { margin: 16px 16px 0 !important; }
    html body .app-shell-resultcheck.resultcheck-compact .result-market-card__header { padding: 8px 12px !important; }
    html body .app-shell-resultcheck.resultcheck-compact .result-table th,
    html body .app-shell-resultcheck.resultcheck-compact .result-table td { padding: 6px 8px !important; }
}
@media (max-width: 600px) {
    html body .app-shell-resultcheck.resultcheck-compact .resultcheck-content { padding: 12px !important; }
    html body .app-shell-resultcheck.resultcheck-compact .resultcheck-day-toolbar { margin: 12px 12px 0 !important; }
    html body .app-shell-resultcheck.resultcheck-compact .resultcheck-topbar h1 { font-size: 17px !important; }
    html body .app-shell-resultcheck.resultcheck-compact .result-market-card__identity { width: 100%; }
    html body .app-shell-resultcheck.resultcheck-compact .result-entry-controls { width: 100%; }
    html body .app-shell-resultcheck.resultcheck-compact .result-auto-status { flex-basis: 100%; max-width: 100% !important; }
}
