/* The investor deck's look, on every app page (loaded after Tailwind and its
   extras; the colors themselves are in scripts/build_tailwind.sh's theme):
   Oswald for headings, Public Sans for text, navy ink on warm paper, and a
   burnt-orange accent. tests/test_templates_css.py checks every page that
   loads Tailwind loads this too. */

/* Self-hosted, like the Tailwind build, so the look doesn't depend on a CDN
   (static/fonts/README.md: both are SIL Open Font License 1.1). */
@font-face {
    font-family: 'Oswald';
    font-style: normal;
    font-weight: 200 700;
    font-display: swap;
    src: url('../fonts/oswald-latin.woff2') format('woff2');
}

@font-face {
    font-family: 'Public Sans';
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url('../fonts/public-sans-latin.woff2') format('woff2');
}

@font-face {
    font-family: 'Public Sans';
    font-style: italic;
    font-weight: 100 900;
    font-display: swap;
    src: url('../fonts/public-sans-italic-latin.woff2') format('woff2');
}

body {
    font-family: 'Public Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
    color: #16212B;
}

h1, h2, h3, .font-display {
    font-family: 'Oswald', 'Arial Narrow', Arial, sans-serif;
    letter-spacing: 0.01em;
}

h1 { font-weight: 600; }

::selection { background: #F6C9AD; color: #16212B; }

/* A link to a section (/settings#mailbox) lands it below the fixed nav,
   not under it. */
html { scroll-padding-top: 5rem; }

/* Text on the accent is pure white: the theme's white is the paper tone
   #FFFDF8, which reads at 4.48:1 on #C2551F, just under WCAG AA's 4.5:1;
   white reads at 4.55:1. */
.bg-blue-600.text-white { color: #FFFFFF; }

a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible {
    outline: 2px solid #C2551F;
    outline-offset: 2px;
}

/* On a phone: form text at 16px, since iOS Safari zooms the whole page into
   any smaller field when it's tapped; buttons and menus at least 40px tall and
   tick boxes 20px, sized for a thumb; and the Quotes / Invoices / Pricebook
   style tab rows given room to tap. */
@media (max-width: 640px) {
    /* !important: Tailwind's text-xs / text-sm / w-4 on a field would otherwise win. */
    input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]):not([type=file]),
    select, textarea { font-size: 16px !important; min-height: 40px; }
    button, input[type=submit], input[type=button] { min-height: 40px; }
    input[type=checkbox], input[type=radio] { width: 1.25rem !important; height: 1.25rem !important; flex-shrink: 0; }
    nav.border-b > a { padding-top: 0.5rem; padding-bottom: 0.75rem; }
}
