/* Element-level base styles: page background, typography, links, code. */
html {
    min-height: 100%;
}

body {
    min-height: 100vh;
    color: var(--app-text);
    background-color: var(--app-bg);
    background-image:
        radial-gradient(circle at 15% -10%, rgba(86, 211, 100, 0.06), transparent 36rem),
        radial-gradient(circle at 100% 0%, rgba(88, 166, 255, 0.07), transparent 32rem);
    background-attachment: fixed;
    font-family: var(--app-font-sans);
    font-size: 16px;
    line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--app-text-strong);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 {
    font-size: 1.9rem;
}

h2 {
    font-size: 1.45rem;
}

h3 {
    font-size: 1.2rem;
}

h4 {
    font-size: 1.05rem;
}

h5,
h6 {
    font-size: 0.95rem;
}

p {
    margin: 0;
}

a {
    color: var(--app-link);
    text-underline-offset: 0.2em;
}

a:hover {
    color: var(--app-link-hover);
}

strong,
b {
    color: var(--app-text-strong);
    font-weight: 700;
}

hr {
    height: 1px;
    border: 0;
    background: var(--app-border);
}

code,
kbd,
samp,
pre {
    font-family: var(--app-font-mono);
    font-size: 0.9em;
}

:not(pre) > code {
    padding: 0.12em 0.4em;
    border-radius: var(--app-radius-sm);
    background: var(--app-link-soft);
    color: var(--app-text-strong);
}

pre {
    padding: 1rem 1.1rem;
    overflow: auto;
    border: 1px solid var(--app-border);
    border-radius: var(--app-radius);
    background: var(--app-bg-soft);
}

pre code {
    padding: 0;
    background: none;
    color: var(--app-text);
}

/* Shared typographic helpers used across templates. */
.app-display {
    font-size: clamp(2rem, 1.3rem + 2.4vw, 2.9rem);
    font-weight: 800;
    letter-spacing: -0.03em;
}

.app-lead {
    color: var(--app-muted);
    font-size: 1.1rem;
}

.app-muted {
    color: var(--app-muted);
}

.app-small {
    font-size: 0.85rem;
}

.app-mono {
    font-family: var(--app-font-mono);
}
