/* iAnnexation site: parchment and burnt-brown, matching the app's own screens */
:root {
    --parchment: #eec751;
    --parchment-light: #f8e094;
    --paper: #fdf6dc;
    --brown: #6b2b0d;
    --brown-dark: #4d1c05;
    --ink: #1a1a1a;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: -apple-system, "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--ink);
    background: var(--parchment);
}

header.site {
    background: var(--brown);
    color: var(--parchment-light);
    text-align: center;
    padding: 1.25rem 1rem 0.5rem;
}

header.site h1 {
    margin: 0 0 0.75rem;
    font-size: 2.2rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

header.site h1 a { color: inherit; text-decoration: none; }

nav.site {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    padding-bottom: 0.75rem;
}

nav.site a {
    background: var(--parchment-light);
    color: var(--brown);
    border: 2px solid var(--brown-dark);
    border-radius: 10px;
    padding: 0.35rem 0.9rem;
    font-weight: 800;
    text-decoration: none;
}

nav.site a:hover,
nav.site a[aria-current="page"] {
    background: #dcae59;
}

main {
    max-width: 46rem;
    margin: 1.5rem auto;
    padding: 1.5rem 1.5rem 2rem;
    background: var(--paper);
    border: 3px solid var(--brown);
    border-radius: 14px;
}

h2, h3 { color: var(--brown); line-height: 1.25; }
h2 { margin-top: 2rem; }
main > h2:first-child { margin-top: 0; }

a { color: var(--brown); }

table {
    border-collapse: collapse;
    width: 100%;
    margin: 1rem 0;
    font-size: 0.95rem;
}

th, td {
    border: 1px solid var(--brown);
    padding: 0.4rem 0.6rem;
    text-align: left;
}

th { background: var(--parchment-light); color: var(--brown-dark); }

.table-wrap { overflow-x: auto; }

.note {
    background: var(--parchment-light);
    border-left: 5px solid var(--brown);
    padding: 0.6rem 1rem;
    margin: 1rem 0;
}

/* Citations and the References page */
sup.cite { font-size: 0.7em; line-height: 0; }
sup.cite a { text-decoration: none; font-weight: 700; }
sup.cite a:hover { text-decoration: underline; }

blockquote {
    margin: 1rem 0;
    padding: 0.6rem 1rem;
    border-left: 5px solid var(--brown);
    background: var(--parchment-light);
    font-style: italic;
}

ol.refs { padding-left: 2rem; }
ol.refs li { margin-bottom: 1rem; scroll-margin-top: 1rem; }
ol.refs li::marker { color: var(--brown); font-weight: 800; }
ol.refs li:target { background: var(--parchment-light); outline: 2px solid var(--brown); border-radius: 6px; }
.ref-note { display: block; font-size: 0.92rem; color: #4a3b2a; margin-top: 0.2rem; }

/* App store badges: shown at Apple's recommended size, unmodified */
.store-badges { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.store-badges img { display: block; height: 48px; width: auto; }

/* Screenshots: figure.shot holds one image, figure.shot.pair holds two side by side */
figure.shot {
    margin: 1.5rem auto;
    text-align: center;
    scroll-margin-top: 1rem;
}

figure.shot img {
    display: block;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    border: 3px solid var(--brown);
    border-radius: 18px;
}

figure.shot img { height: auto; }
figure.shot.ipad img { max-width: 460px; }

figure.shot.pair .shots {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

figure.shot.pair .shots > * { flex: 1 1 220px; max-width: 280px; margin: 0; }

figure.shot figcaption {
    margin-top: 0.5rem;
    font-size: 0.92rem;
    color: #4a3b2a;
}

/* Numbered callouts that explain a marked-up screenshot */
ol.callouts { list-style: none; counter-reset: callout; padding-left: 0; }
ol.callouts li { counter-increment: callout; position: relative; padding-left: 2.2rem; margin-bottom: 0.5rem; }
ol.callouts li::before {
    content: counter(callout);
    position: absolute;
    left: 0;
    top: 0.1rem;
    width: 1.6rem;
    height: 1.6rem;
    line-height: 1.6rem;
    text-align: center;
    border-radius: 50%;
    background: var(--brown);
    color: var(--parchment-light);
    font-weight: 800;
    font-size: 0.85rem;
}

footer.site {
    text-align: center;
    padding: 1rem 1rem 2rem;
    color: var(--brown-dark);
    font-size: 0.9rem;
}

.pager {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    font-weight: 700;
}
