/* web-summit.sgit.ai: one stylesheet, in the house style of sgit.ai, coding.sgit.ai and ux.sgit.ai.
   Colour is written only between tokens:start and tokens:end; the validate gate fails on a literal
   colour anywhere else. Light is the default; dark follows the reader's system setting. */

/* tokens:start */
:root {
    --bg          : #faf9f5;
    --surface     : #ffffff;
    --surface-2   : #f2f0e9;
    --line        : #e5e1d5;
    --line-2      : #d5d0c2;
    --ink         : #1c1d21;
    --ink-2       : #5c5f66;
    --accent      : #0f766e;
    --accent-dk   : #115e59;
    --accent-ink  : #ffffff;
    --accent-soft : #e6f4f1;
    --focus       : #0f766e;
    --code-bg     : #f2f0e9;
    --nav-bg      : rgb(250 249 245 / 0.92);
    --shadow      : 0 1px 2px rgb(28 29 33 / 0.05), 0 4px 14px rgb(28 29 33 / 0.04);
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg          : #141412;
        --surface     : #1c1c19;
        --surface-2   : #24241f;
        --line        : #34332d;
        --line-2      : #46453d;
        --ink         : #ecebe6;
        --ink-2       : #a9a59b;
        --accent      : #5fd4c8;
        --accent-dk   : #8be3d9;
        --accent-ink  : #0b1f1d;
        --accent-soft : #14302d;
        --focus       : #5fd4c8;
        --code-bg     : #24241f;
        --nav-bg      : rgb(20 20 18 / 0.92);
        --shadow      : 0 1px 2px rgb(0 0 0 / 0.4);
    }
}
/* tokens:end */

:root {
    --sans    : ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --mono    : ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace;
    --measure : 46rem;
    --wide    : 72rem;
    --radius  : 10px;
    --gutter  : 16px;
}

*, *::before, *::after { box-sizing: border-box; }

/* The canvas takes the site colour, so a pinch-zoom out on iOS does not show white. */
html { -webkit-text-size-adjust: 100%; background: var(--bg); scroll-behavior: smooth; }

body {
    margin        : 0;
    background    : var(--bg);
    color         : var(--ink);
    font-family   : var(--sans);
    font-size     : 1.0625rem;
    line-height   : 1.65;
    overflow-wrap : anywhere;
}

a { color: var(--accent-dk); text-underline-offset: 0.15em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.015em; }
h1 { font-size: clamp(1.8rem, 5vw, 2.5rem); margin: 0 0 0.6rem; }
h2 { font-size: 1.4rem; margin: 2.2rem 0 0.6rem; }
h3 { font-size: 1.1rem; }

code, pre { font-family: var(--mono); }
p code, li code, td code {
    background: var(--code-bg); border: 1px solid var(--line); border-radius: 4px;
    padding: 0.08em 0.35em; font-size: 0.86em;
}
pre { background: var(--code-bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 0.9rem 1rem; overflow-x: auto; font-size: 0.88rem; line-height: 1.5; }
pre code { background: none; border: 0; padding: 0; font-size: inherit; }

.skip { position: absolute; left: -999px; top: 0; background: var(--accent); color: var(--accent-ink); padding: 0.5rem 1rem; z-index: 100; }
.skip:focus { left: 0; }

/* ---------- top nav ---------- */
nav.site { position: sticky; top: 0; z-index: 50; background: var(--nav-bg); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
nav.site .row { max-width: var(--wide); margin: 0 auto; display: flex; flex-wrap: wrap; align-items: center; gap: 0.2rem 1rem; padding: 0.55rem var(--gutter); }
nav.site .brand { font-weight: 800; font-size: 1.05rem; letter-spacing: -0.02em; color: var(--ink); text-decoration: none; white-space: nowrap; }
nav.site .brand span { color: var(--accent); }
nav.site .parent, nav.site .gh, nav.site .ver {
    border: 1px solid var(--line-2); border-radius: 6px; padding: 0.25rem 0.65rem;
    font-size: 0.78rem; white-space: nowrap; background: var(--surface); color: var(--ink); text-decoration: none;
}
nav.site .parent { border-color: var(--accent); color: var(--accent-dk); }
nav.site .parent:hover { background: var(--accent); color: var(--accent-ink); }
nav.site .ver { color: var(--ink-2); font-family: var(--mono); }
nav.site .gh:hover, nav.site .ver:hover { border-color: var(--accent); }
nav.site .links { display: flex; flex-wrap: wrap; gap: 0 0.2rem; margin-left: 0.4rem; }
nav.site .links a { color: var(--ink-2); font-size: 0.92rem; text-decoration: none; padding: 0.55rem 0.55rem; }
nav.site .links a:hover { color: var(--ink); }
nav.site .links a[aria-current="page"] { color: var(--ink); font-weight: 600; box-shadow: inset 0 -2px 0 var(--accent); }
nav.site .gh { margin-left: auto; }

/* ---------- page ---------- */
main { max-width: var(--measure); margin: 0 auto; padding: 2rem var(--gutter) 3rem; }
main.home { max-width: var(--wide); }
.lead { font-size: 1.2rem; line-height: 1.55; color: var(--ink-2); max-width: 40rem; margin: 0.4rem 0 1rem; }
.meta { color: var(--ink-2); font-size: 0.9rem; }
.asof { display: inline-block; margin: 0 0 1rem; padding: 0.2rem 0.65rem; font-size: 0.82rem; color: var(--accent-dk); background: var(--accent-soft); border-radius: 999px; }

.hero { padding: 1.2rem 0 0.4rem; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); gap: 0.9rem; margin: 1.2rem 0; }
.card { display: block; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem; box-shadow: var(--shadow); color: var(--ink); text-decoration: none; }
.card:hover { border-color: var(--accent); }
.card b { display: block; font-size: 1.05rem; color: var(--accent-dk); margin-bottom: 0.2rem; }
.card span { color: var(--ink-2); font-size: 0.95rem; }

table { border-collapse: collapse; width: 100%; display: block; overflow-x: auto; font-size: 0.95rem; }
th, td { border: 1px solid var(--line); padding: 0.45rem 0.7rem; text-align: left; vertical-align: top; }
th { background: var(--surface-2); }

ul { padding-left: 1.3rem; }
li { margin: 0.25rem 0; }

footer { border-top: 1px solid var(--line); color: var(--ink-2); font-size: 0.88rem; }
footer .row { max-width: var(--wide); margin: 0 auto; padding: 1rem var(--gutter); display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; }
.agent-block { max-width: var(--wide); margin: 0 auto; padding: 0 var(--gutter) 2rem; }
.agent-block pre { white-space: pre-wrap; font-size: 0.8rem; color: var(--ink-2); }

@media (max-width: 40rem) {
    nav.site .gh { display: none; }
    main { padding-top: 1.4rem; }
}
