/* ===== Global reset & consistency ===== */
* {
    box-sizing: border-box;
}

/* 🔹 NIEUW: altijd scrollbar reserveren (voorkomt layout shift) */
html {
    font-size: 16px;
    height: 100%;
    overflow-y: scroll;
}

/* 🔹 AANGEPAST: body onderdeel van flex-structuur */
body {
    font-family: Arial, sans-serif;
    margin: 0;
    background: #f4f4f4;
    line-height: 1.6;
    min-height: 100vh;
}

/* 🔹 NIEUW: page wrapper voor sticky footer */
.page-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ===== Page width (same size on all pages) ===== */
.page {
    width: 90%;
    max-width: 1200px;
    min-width: 320px;
    margin: 0 auto;
    background: transparent;
}

/* ===== Header & Footer ===== */
header,
footer {
    background: #333;
    color: #fff;
	width: 100%;
	padding: 12px 20px;
    text-align: center;
}

/* 🔹 NIEUW: footer mag niet krimpen */
footer {
    flex-shrink: 0;
}

nav a {
    color: #fff;
    margin: 0 10px;
    text-decoration: none;
}

/* ===== Main layout ===== */
/* 🔹 AANGEPAST: main vult lege ruimte op */
main {
    display: flex;
    width: 100%;
    min-width: 0;
    padding: 15px;
    gap: 15px;
    flex-wrap: wrap;

    flex: 1;   /* ⭐ dit is de sleutel tegen korte pagina’s */
}

/* ===== Sidebars & Content ===== */
aside.sidebar {
    flex: 0 1 25%;
    min-width: 220px;
    background: #fff;
    padding: 15px;
}

article {
    flex: 0 1 70%;
    min-width: 0;
    background: #fff;
    padding: 20px;
}

aside.ads {
    flex: 1 1 0;
    min-width: 300px;
    background: #fff;
    padding: 15px;
    text-align: center;
}

/* ===== Typography ===== */
h1, h2, h3 {
    margin-top: 0;
}

ul, ol {
    padding-left: 18px;
}

/* ===== Buttons ===== */
a.cta-button {
    display: inline-block;
    background-color: #333;
    color: #fff;
    padding: 8px 14px;
    text-decoration: none;
    border-radius: 4px;
    margin-top: 15px;
}

/* ===== Ads ===== */
.ad {
    margin: 20px 0;
}

/* ===== Images ===== */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

.step-image {
    border: 1px solid #ccc;
    margin: 15px 0;
}

img.profile {
    float: right;
    max-width: 220px;
    margin: 0 0 15px 15px;
    border-radius: 6px;
}

/* ===== Figures ===== */
figure {
    margin: 20px 0;
}

figcaption {
    font-size: 0.9em;
    color: #555;
    text-align: center;
}

/* ===== Tables & Code Blocks (prevent overflow) ===== */
table {
    width: 100%;
    max-width: 100%;
    border-collapse: collapse;
}

pre {
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    main {
        flex-direction: column;
    }

    img.profile {
        float: none;
        display: block;
        margin: 0 auto 15px;
    }
}
