/* removeme.io public pages (PRD 02 §9): small, WCAG 2.1 AA. JS only for Turnstile and the contact email link. */
*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    font-size: 1.125rem;
    line-height: 1.5;
    color: #1a1a1a;
    background: #ffffff;
}

.page { max-width: 36rem; margin: 0 auto; padding: 1.5rem 1rem 2rem; }
.page-footer { max-width: 36rem; margin: 0 auto; padding: 1rem; border-top: 1px solid #d0d0d0; font-size: 1rem; display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
/* Wider column for long reading pages with tables (the privacy policy). */
.wide .page, .wide .page-footer { max-width: 48rem; }

h1 { font-size: 1.75rem; line-height: 1.25; margin: 0 0 1rem; }
h2 { font-size: 1.25rem; margin: 1.5rem 0 0.5rem; }

a { color: #0b4fa8; }
a:hover { color: #083a7a; }

:focus-visible { outline: 3px solid #f2a900; outline-offset: 2px; }

fieldset { border: 0; margin: 1.5rem 0; padding: 0; }
legend { font-weight: 700; font-size: 1.25rem; padding: 0; }
.hint { color: #4a4a4a; margin: 0.25rem 0 1rem; }

.field { margin-bottom: 1.25rem; }
label { display: block; font-weight: 600; margin-bottom: 0.25rem; }

input[type="tel"], input[type="email"] {
    width: 100%;
    font: inherit;
    padding: 0.625rem 0.75rem;
    border: 2px solid #5a5a5a;
    border-radius: 4px;
    background: #ffffff;
    color: inherit;
}
input[aria-invalid="true"] { border-color: #b00020; }

.field-error { color: #b00020; font-weight: 600; margin: 0 0 0.25rem; }

.error-summary { border: 3px solid #b00020; padding: 1rem; margin: 1rem 0; }
.error-summary h2 { margin-top: 0; }
.error-summary ul { margin: 0; padding-left: 1.25rem; }
.error-summary a { color: #b00020; font-weight: 600; }

button {
    font: inherit;
    font-weight: 700;
    padding: 0.75rem 1.5rem;
    border: 0;
    border-radius: 4px;
    background: #0b4fa8;
    color: #ffffff;
    cursor: pointer;
    width: 100%;
}
button:hover { background: #083a7a; }

.reference { font-size: 1.25rem; }

/* Privacy policy */
.policy h2 { margin-top: 2rem; }
.effective-date { color: #4a4a4a; margin-top: -0.5rem; }

/* Buyer API docs: code samples and hashes. */
h3 { font-size: 1.125rem; margin: 1.5rem 0 0.5rem; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.9em; background: #f2f4f7; border-radius: 3px; padding: 0.05em 0.3em; }
pre { background: #f2f4f7; border: 1px solid #d0d0d0; border-radius: 4px; padding: 0.75rem 1rem; overflow-x: auto; font-size: 0.875rem; line-height: 1.45; }
pre code { background: none; padding: 0; font-size: inherit; }
code.hash { word-break: break-all; }
code.ws { white-space: pre; }
.docs nav ul { columns: 2; }
@media (max-width: 37.49rem) { .docs nav ul { columns: 1; } }

/*
 * Tables: full width, a thin outer border and a line between rows. Columns
 * size to their content; .fit-first / .fit-last keep that column on one
 * line so the others share the remaining width.
 */
.table-wrap { margin: 1rem 0 1.5rem; }
table { width: 100%; border-collapse: collapse; border: 1px solid #c4c4c4; font-size: inherit; line-height: inherit; }
th, td { text-align: left; vertical-align: top; padding: 0.625rem 0.75rem; }
thead th { font-weight: 700; background: #eef3fa; border-bottom: 2px solid #8a8a8a; }
tbody tr + tr td { border-top: 1px solid #d0d0d0; }
th:first-child, td:first-child { min-width: 8em; }
.fit-first th:first-child, .fit-first td:first-child,
.fit-last th:last-child, .fit-last td:last-child { width: 1%; white-space: nowrap; }

/* Narrow screens: each row becomes a card, each cell labelled with its column header (data-label). */
@media (max-width: 37.49rem) {
    table, thead, tbody, tr, th, td { display: block; }
    table { border: 0; }
    thead { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
    tbody tr { border: 1px solid #c4c4c4; border-radius: 4px; margin-bottom: 0.75rem; padding: 0.25rem 0; }
    tbody tr + tr td { border-top: 0; }
    td { padding: 0.375rem 0.75rem; }
    th:first-child, td:first-child { min-width: 0; }
    .fit-first td:first-child, .fit-last td:last-child { width: auto; white-space: normal; }
    td::before { content: attr(data-label); display: block; font-size: 0.875rem; font-weight: 700; color: #4a4a4a; }
}

/* Honeypot: off-screen rather than display:none so naive bots still fill it. */
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

@media (min-width: 40rem) {
    button { width: auto; }
}
