/* styles.css — onefox.com.ua
   Тема: слонова кістка + лісовий зелений. Світла, editorial/tech.
   Mobile-first. Брейкпоінти: 480 / 768 / 1024 / 1280. */

/* ==========================================================================
   1. Design tokens
   ========================================================================== */
:root {
    /* Поверхні */
    --paper: #f6f3ea;
    --bg: var(--paper);
    --surface: #fffdf7;
    --surface-alt: #eee9dc;
    --surface-code: #ece6d6;
    --surface-hover: #e9e3d3;

    /* Бордери та тіні */
    --border: #d8d0bd;
    --border-soft: #e5ddcb;
    --shadow-sm: 0 1px 2px rgba(45, 40, 25, 0.06);
    --shadow-md: 0 6px 18px -8px rgba(45, 40, 25, 0.14);
    --shadow-lg: 0 16px 36px -16px rgba(45, 40, 25, 0.22);

    /* Текст */
    --text-main: #1c1f1a;
    --text-body: #2b2e28;
    --text-muted: #5b6052;

    /* Акценти */
    --primary: #1f5a46;
    --primary-hover: #15402f;
    --primary-light: #e2ece5;
    --accent: #8a5b1f;
    --accent-bg: #f5e9cc;
    --focus: #1f5a46;

    /* Типографіка */
    --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

    --fs-base: 1rem;
    --fs-body: 1.0625rem;
    --fs-small: 0.875rem;
    --fs-xs: 0.75rem;
    --fs-h1: clamp(1.25rem, 1.05rem + 0.9vw, 2rem);
    --fs-h2: clamp(1.2rem, 1.05rem + 0.5vw, 1.5rem);
    --fs-h3: clamp(1.05rem, 1rem + 0.25vw, 1.2rem);

    --lh-body: 1.65;
    --lh-text: 1.75;
    --lh-heading: 1.3;

    /* Spacing scale */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    --space-16: 64px;

    /* Радіуси */
    --radius-xs: 4px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-pill: 999px;

    /* Розміри */
    --container: 1180px;
    --article-max: 68ch;
    --sidebar-w: 300px;
    --tap-min: 44px;
    --header-h: 64px;

    --transition: 0.18s ease;
}

/* ==========================================================================
   2. Reset / base
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body {
    min-height: 100vh;
    background-color: var(--bg);
    color: var(--text-body);
    font-family: var(--font-sans);
    font-size: var(--fs-base);
    line-height: var(--lh-body);
    overflow-x: hidden;
    overflow-wrap: break-word;
}

img,
picture,
video,
canvas,
svg,
iframe,
embed,
object {
    display: block;
    max-width: 100%;
    height: auto;
}

iframe {
    width: 100%;
    border: 0;
}

::selection {
    background: var(--primary-light);
    color: var(--text-main);
}

/* ==========================================================================
   3. Links, focus, generic elements
   ========================================================================== */
a {
    color: var(--primary);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.2em;
    text-decoration-color: rgba(31, 90, 70, 0.35);
    transition: color var(--transition), text-decoration-color var(--transition), background-color var(--transition);
}

a:hover {
    color: var(--primary-hover);
    text-decoration-color: currentColor;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 3px;
    border-radius: var(--radius-xs);
}

button,
input,
select,
textarea {
    font: inherit;
    color: inherit;
}

button {
    cursor: pointer;
    background: none;
    border: 0;
}

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

em,
i {
    font-style: italic;
}

hr {
    border: 0;
    border-top: 1px solid var(--border-soft);
    margin: var(--space-10) 0;
}

abbr[title] {
    text-decoration: underline dotted;
    cursor: help;
}

/* ==========================================================================
   4. Header
   ========================================================================== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 253, 247, 0.92);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-soft);
}

.header-inner {
    max-width: var(--container);
    margin: 0 auto;
    padding: var(--space-3) var(--space-5);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3) var(--space-4);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    min-height: var(--tap-min);
    font-family: var(--font-serif);
    font-weight: 700;
    font-size: 1.125rem;
    letter-spacing: -0.01em;
    color: var(--text-main);
    text-decoration: none;
}

.logo:hover {
    color: var(--primary);
}

.logo-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
    flex-shrink: 0;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
    font-size: var(--fs-small);
    font-weight: 500;
    -webkit-overflow-scrolling: touch;
}

.main-nav::-webkit-scrollbar {
    display: none;
}

.main-nav a {
    display: inline-flex;
    align-items: center;
    min-height: var(--tap-min);
    padding: 0 var(--space-1);
    color: var(--text-muted);
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
}

.main-nav a:hover {
    color: var(--primary);
    border-bottom-color: var(--border);
}

.main-nav a.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

.lang-switcher {
    display: inline-flex;
    gap: var(--space-1);
    padding: 3px;
    background: var(--surface-alt);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
}

.lang-switcher a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    min-height: 32px;
    padding: 0 var(--space-2);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 6px;
}

.lang-switcher a:hover {
    color: var(--primary);
    background: var(--surface-hover);
}

.lang-switcher a.active {
    background: var(--surface);
    color: var(--text-main);
    box-shadow: var(--shadow-sm);
}

/* ==========================================================================
   5. Main / hero
   ========================================================================== */
main {
    max-width: var(--container);
    margin: 0 auto;
    padding: var(--space-8) var(--space-5) var(--space-16);
}

.hero {
    max-width: var(--article-max);
    margin: 0 auto var(--space-10);
}

.hero-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-2) var(--space-3);
    margin-bottom: var(--space-4);
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px var(--space-3);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--primary);
    background: var(--primary-light);
    border: 1px solid rgba(31, 90, 70, 0.15);
    border-radius: var(--radius-pill);
}

.reading-time {
    font-size: var(--fs-small);
    font-weight: 500;
    color: var(--text-muted);
}

.article-title {
    font-family: var(--font-serif);
    font-size: var(--fs-h1);
    font-weight: 700;
    line-height: var(--lh-heading);
    letter-spacing: -0.015em;
    color: var(--text-main);
    margin-bottom: var(--space-4);
    overflow-wrap: anywhere;
    hyphens: auto;
    text-wrap: balance;
}

.lead {
    font-size: 1.0625rem;
    line-height: var(--lh-text);
    color: var(--text-muted);
    font-weight: 400;
    margin-bottom: var(--space-6);
    overflow-wrap: anywhere;
}

.meta-panel {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-4) var(--space-8);
    padding: var(--space-4) 0;
    margin-bottom: var(--space-8);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border-soft);
}

.meta-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.meta-item .label {
    font-size: var(--fs-xs);
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.meta-item .value {
    font-size: var(--fs-small);
    font-weight: 600;
    color: var(--text-main);
    overflow-wrap: anywhere;
}

.hero-visual {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--surface-alt);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-md);
}

.hero-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ==========================================================================
   6. Layout: content + sidebar (mobile-first)
   ========================================================================== */
.content-wrapper {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-10);
    align-items: start;
}

.content-body {
    min-width: 0;
    max-width: var(--article-max);
    width: 100%;
}

.sidebar {
    order: 2;
    min-width: 0;
    width: 100%;
}

.sidebar-sticky {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
    position: static;
}

/* ==========================================================================
   7. Article content
   ========================================================================== */
.content-body > * + * {
    margin-top: 0;
}

.content-body p {
    font-family: var(--font-serif);
    font-size: var(--fs-body);
    line-height: var(--lh-text);
    color: var(--text-body);
    margin-bottom: var(--space-5);
    overflow-wrap: anywhere;
    hyphens: auto;
}

.content-body h2 {
    font-family: var(--font-serif);
    font-size: var(--fs-h2);
    font-weight: 700;
    line-height: var(--lh-heading);
    letter-spacing: -0.01em;
    color: var(--text-main);
    margin: var(--space-10) 0 var(--space-4);
    padding-bottom: var(--space-2);
    border-bottom: 1px solid var(--border-soft);
    overflow-wrap: anywhere;
}

.content-body h3 {
    font-family: var(--font-sans);
    font-size: var(--fs-h3);
    font-weight: 700;
    line-height: var(--lh-heading);
    color: var(--text-main);
    margin: var(--space-8) 0 var(--space-3);
    overflow-wrap: anywhere;
}

.content-body h4 {
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-main);
    margin: var(--space-6) 0 var(--space-2);
}

.content-body ul,
.content-body ol {
    margin: 0 0 var(--space-5);
    padding-left: var(--space-6);
    font-family: var(--font-serif);
    font-size: var(--fs-body);
    line-height: var(--lh-text);
    color: var(--text-body);
}

.content-body ul {
    list-style: none;
    padding-left: 0;
}

.content-body ul > li {
    position: relative;
    padding-left: var(--space-6);
}

.content-body ul > li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 0.65em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
}

.content-body ol {
    list-style: decimal;
}

.content-body ol > li::marker {
    color: var(--primary);
    font-weight: 700;
}

.content-body li {
    margin-bottom: var(--space-2);
    overflow-wrap: anywhere;
}

.content-body li > ul,
.content-body li > ol {
    margin-top: var(--space-2);
    margin-bottom: 0;
}

.content-body a {
    font-weight: 500;
}

.content-body strong {
    font-family: var(--font-sans);
    font-weight: 700;
    color: var(--text-main);
}

.content-body blockquote {
    position: relative;
    margin: var(--space-8) 0;
    padding: var(--space-5) var(--space-5) var(--space-5) var(--space-6);
    background: var(--surface-alt);
    border-left: 3px solid var(--primary);
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.0625rem;
    line-height: var(--lh-text);
    color: var(--text-main);
    overflow-wrap: anywhere;
}

.content-body blockquote p {
    margin-bottom: var(--space-3);
    font-style: italic;
    color: var(--text-main);
}

.content-body blockquote p:last-child {
    margin-bottom: 0;
}

.content-body blockquote cite {
    display: block;
    margin-top: var(--space-3);
    font-family: var(--font-sans);
    font-size: var(--fs-small);
    font-style: normal;
    font-weight: 600;
    color: var(--accent);
}

.content-body img {
    margin: var(--space-6) 0;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-soft);
}

.content-body figure {
    margin: var(--space-8) 0;
}

.content-body figcaption {
    margin-top: var(--space-2);
    font-size: var(--fs-small);
    color: var(--text-muted);
}

.content-body code {
    font-family: var(--font-mono);
    font-size: 0.875em;
    padding: 0.1em 0.35em;
    color: var(--text-main);
    background: var(--surface-code);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-xs);
    overflow-wrap: anywhere;
}

.content-body pre {
    margin: var(--space-6) 0;
    padding: var(--space-4);
    overflow-x: auto;
    background: var(--surface-code);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    -webkit-overflow-scrolling: touch;
}

.content-body pre code {
    display: block;
    padding: 0;
    font-size: 0.875rem;
    line-height: 1.6;
    background: none;
    border: 0;
    white-space: pre;
    overflow-wrap: normal;
}

.content-body table {
    display: block;
    width: 100%;
    max-width: 100%;
    margin: var(--space-6) 0;
    overflow-x: auto;
    border-collapse: collapse;
    font-size: var(--fs-small);
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    -webkit-overflow-scrolling: touch;
}

.content-body th,
.content-body td {
    padding: var(--space-3) var(--space-4);
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--border-soft);
    min-width: 8ch;
    overflow-wrap: anywhere;
}

.content-body th {
    font-weight: 700;
    color: var(--text-main);
    background: var(--surface-alt);
    white-space: nowrap;
}

.content-body tbody tr:nth-child(even) td {
    background: rgba(238, 233, 220, 0.4);
}

.content-body tbody tr:hover td {
    background: var(--primary-light);
}

.content-body tr:last-child td {
    border-bottom: 0;
}

/* ==========================================================================
   8. Info box
   ========================================================================== */
.info-box {
    margin: var(--space-8) 0;
    padding: var(--space-5);
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-left: 3px solid var(--accent);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.info-box-title {
    margin-bottom: var(--space-3);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: 0.01em;
}

.info-box ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.info-box li {
    position: relative;
    padding-left: var(--space-5);
    font-size: 0.95rem;
    line-height: var(--lh-body);
    color: var(--text-body);
    overflow-wrap: anywhere;
}

.info-box li::before {
    content: "";
    position: absolute;
    left: 2px;
    top: 0.6em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
}

/* ==========================================================================
   9. Sidebar cards
   ========================================================================== */
.author-card,
.toc-card {
    padding: var(--space-5);
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.author-header {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-3);
}

.author-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--surface);
    box-shadow: 0 0 0 1px var(--border);
    flex-shrink: 0;
}

.author-badge {
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.author-name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-main);
    overflow-wrap: anywhere;
}

.author-bio {
    margin-bottom: var(--space-4);
    font-size: var(--fs-small);
    line-height: 1.55;
    color: var(--text-muted);
    overflow-wrap: anywhere;
}

.author-socials {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
}

.author-socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: var(--tap-min);
    height: var(--tap-min);
    color: var(--text-muted);
    background: var(--surface-alt);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    text-decoration: none;
}

.author-socials a:hover {
    color: var(--primary);
    background: var(--primary-light);
    border-color: rgba(31, 90, 70, 0.2);
}

.toc-title {
    margin-bottom: var(--space-3);
    font-size: var(--fs-xs);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.toc-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.toc-list li {
    border-top: 1px solid var(--border-soft);
}

.toc-list li:first-child {
    border-top: 0;
}

.toc-list li a {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    min-height: var(--tap-min);
    padding: var(--space-2) 0;
    font-size: var(--fs-small);
    font-weight: 500;
    color: var(--text-body);
    text-decoration: none;
}

.toc-list li a span {
    flex-shrink: 0;
    min-width: 1.75em;
    font-family: var(--font-mono);
    font-size: var(--fs-xs);
    font-weight: 700;
    color: var(--accent);
}

.toc-list li a:hover {
    color: var(--primary);
}

/* ==========================================================================
   10. Related section & cards
   ========================================================================== */
.related-section {
    margin-top: var(--space-12);
    padding-top: var(--space-10);
    border-top: 1px solid var(--border);
}

.section-header {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    margin-bottom: var(--space-6);
}

.section-header h2 {
    font-family: var(--font-serif);
    font-size: var(--fs-h2);
    font-weight: 700;
    line-height: var(--lh-heading);
    color: var(--text-main);
    white-space: nowrap;
}

.section-line {
    flex-grow: 1;
    height: 1px;
    min-width: var(--space-6);
    background: var(--border);
}

.cards-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
}

.card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: var(--space-5);
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.card:hover {
    border-color: rgba(31, 90, 70, 0.3);
    box-shadow: var(--shadow-md);
}

@media (hover: hover) {
    .card:hover {
        transform: translateY(-2px);
    }
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: var(--space-2);
    margin-bottom: var(--space-3);
}

.tag {
    display: inline-flex;
    align-items: center;
    padding: 3px var(--space-2);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--primary);
    background: var(--primary-light);
    border-radius: var(--radius-xs);
}

.tag.warning {
    color: var(--accent);
    background: var(--accent-bg);
}

.card-meta .date {
    font-size: var(--fs-xs);
    color: var(--text-muted);
}

.card h3 {
    margin-bottom: var(--space-2);
    font-family: var(--font-serif);
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.35;
    color: var(--text-main);
    overflow-wrap: anywhere;
}

.card p {
    flex-grow: 1;
    margin-bottom: var(--space-4);
    font-size: var(--fs-small);
    line-height: 1.6;
    color: var(--text-muted);
    overflow-wrap: anywhere;
}

.card-footer {
    display: flex;
    align-items: center;
}

.read-more {
    display: inline-flex;
    align-items: center;
    min-height: var(--tap-min);
    font-size: var(--fs-small);
    font-weight: 700;
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}

.read-more:hover {
    color: var(--primary-hover);
}

/* ==========================================================================
   11. Footer
   ========================================================================== */
.site-footer {
    margin-top: var(--space-16);
    background: var(--surface);
    border-top: 1px solid var(--border-soft);
}

.footer-inner {
    max-width: var(--container);
    margin: 0 auto;
    padding: var(--space-10) var(--space-5) var(--space-8);
    display: flex;
    flex-direction: column;
    gap: var(--space-6);
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
}

.brand-title {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-main);
}

.brand-desc {
    font-size: var(--fs-small);
    color: var(--text-muted);
    max-width: 52ch;
    overflow-wrap: anywhere;
}

.footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2) var(--space-5);
    font-size: var(--fs-small);
    font-weight: 500;
}

.footer-nav a {
    display: inline-flex;
    align-items: center;
    min-height: var(--tap-min);
    color: var(--text-muted);
    text-decoration: none;
}

.footer-nav a:hover {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}

.footer-copy {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
    padding-top: var(--space-5);
    border-top: 1px solid var(--border-soft);
}

.footer-copy p {
    font-size: var(--fs-xs);
    line-height: 1.55;
    color: var(--text-muted);
    overflow-wrap: anywhere;
}

/* ==========================================================================
   12. Generic utilities for typical content
   ========================================================================== */
.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ==========================================================================
   13. Breakpoints: 480px
   ========================================================================== */
@media (min-width: 480px) {
    .header-inner {
        padding-left: var(--space-6);
        padding-right: var(--space-6);
    }

    main {
        padding-left: var(--space-6);
        padding-right: var(--space-6);
    }

    .cards-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ==========================================================================
   14. Breakpoints: 768px
   ========================================================================== */
@media (min-width: 768px) {
    :root {
        --fs-body: 1.125rem;
    }

    body {
        font-size: 1.0625rem;
    }

    .main-nav {
        overflow: visible;
    }

    .main-nav a {
        padding: 0 var(--space-1);
    }

    .content-body p,
    .content-body ul,
    .content-body ol {
        font-size: var(--fs-body);
    }

    .content-body h2
{
        font-size: var(--fs-h2);
        margin-top: var(--space-10);
        margin-bottom: var(--space-4);
    }

    .content-body h3 {
        font-size: var(--fs-h3);
        margin-top: var(--space-8);
        margin-bottom: var(--space-3);
    }

    .cards-grid {
        gap: var(--space-6);
    }

    .card {
        padding: var(--space-6);
    }

    .footer-inner {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-between;
        align-items: flex-start;
    }

    .footer-copy {
        width: 100%;
    }
}

/* ==========================================================================
   15. Breakpoints: 1024px
   ========================================================================== */
@media (min-width: 1024px) {
    .cards-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .related-section {
        margin-top: var(--space-16);
        padding-top: var(--space-12);
    }

    .footer-inner {
        padding-top: var(--space-12);
        padding-bottom: var(--space-10);
    }
}

/* ==========================================================================
   16. Reduced motion
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .card:hover {
        transform: none;
    }
}

/* ==========================================================================
   17. Print
   ========================================================================== */
@media print {
    .site-header,
    .site-footer,
    .related-section,
    .main-nav,
    .toc {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
        font-size: 11pt;
    }

    a {
        color: inherit;
        text-decoration: underline;
    }

    .content-body a[href]::after {
        content: " (" attr(href) ")";
        font-size: 0.85em;
    }

    .card,
    .content-body {
        box-shadow: none;
        border: 0;
    }
}
===end file===
===end file===
===end file===
===end file===
===end file===
===end file===