/* ==========================================================================
   Administratiekantoor SLS – style.css
   ========================================================================== */

/* Fonts (lokaal gehost, AVG-vriendelijk) ---------------------------------- */
@font-face {
    font-family: "Nunito";
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url("../fonts/nunito-latin.woff2") format("woff2");
}

/* Variabelen -------------------------------------------------------------- */
:root {
    --color-text: #262626;
    --color-heading: #333333;
    --color-link: #333333;
    --color-accent: #65bc7b;
    --color-black: #000000;
    --color-button-hover: #232323;
    --color-bg: #ffffff;

    --font-base: "Nunito", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
    --font-size-base: 18px;
    --line-height-base: 1.5;

    --site-width: 1100px;
    --gutter: 30px;
    --column-gap: 4%;

    --ease-out: cubic-bezier(.22, 1, .36, 1);
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font-base);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    -webkit-font-smoothing: antialiased;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

p {
    margin: 0 0 20px;
}

a {
    color: var(--color-link);
    text-decoration: none;
    transition: color .2s ease;
}

a:hover,
a:focus-visible {
    color: var(--color-accent);
}

:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

address {
    font-style: normal;
}

/* Toegankelijkheid -------------------------------------------------------- */
.visually-hidden {
    position: absolute !important;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    z-index: 100;
    padding: 10px 16px;
    background: var(--color-black);
    color: #fff;
    border-radius: 0 0 6px 6px;
    transition: top .2s ease;
}

.skip-link:focus {
    top: 0;
    color: #fff;
}

/* Layout ------------------------------------------------------------------ */
.container {
    width: 100%;
    max-width: calc(var(--site-width) + var(--gutter) * 2);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.site-header {
    padding-top: 55px;
}

.logo {
    max-width: 400px;
    margin: 0 auto;
    font-size: inherit; /* h1 bevat alleen het logo */
    line-height: 0;
}

.site-main {
    padding: 50px 0 60px;
}

.grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    column-gap: var(--column-gap);
    align-items: start;
}

/* Contactkaart ------------------------------------------------------------ */
.contact-card {
    padding: 15px;
    border: 3px solid var(--color-black);
    border-radius: 10px;
    overflow: hidden;
    background: var(--color-bg);
    transition: box-shadow .3s ease, transform .3s ease;
}

.contact-card:hover {
    box-shadow: 0 12px 30px rgba(0, 0, 0, .08);
}

.contact-card__title {
    margin: 0 0 20px;
    color: var(--color-heading);
    font-size: 20px;
    font-weight: 400;
    line-height: 1.4;
}

.contact-card a:not(.button) {
    word-break: break-word;
}

/* Knop -------------------------------------------------------------------- */
.button {
    position: relative;
    display: block;
    width: 100%;
    padding: 13px 29px;
    overflow: hidden;
    background: var(--color-black);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    line-height: 17px;
    letter-spacing: .5px;
    text-align: center;
    text-transform: uppercase;
    border-radius: 0;
    transition: background-color .25s ease, transform .25s var(--ease-out), box-shadow .25s ease;
}

/* Glans-effect bij hover */
.button::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .22) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform .6s var(--ease-out);
}

.button:hover,
.button:focus-visible {
    background: var(--color-button-hover);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .2);
}

.button:hover::after,
.button:focus-visible::after {
    transform: translateX(100%);
}

.button:active {
    transform: translateY(0);
}

/* Naar boven-knop --------------------------------------------------------- */
.to-top {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 50;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    background: #333;
    color: #fff;
    border-radius: 6px 6px 0 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(12px);
    transition: opacity .3s ease, transform .3s var(--ease-out), visibility .3s, background-color .2s ease;
}

.to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.to-top:hover,
.to-top:focus-visible {
    background: var(--color-accent);
    color: #fff;
}

/* Animaties (alleen met JS, zodat content zonder JS altijd zichtbaar is) -- */
.js .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .8s var(--ease-out), transform .8s var(--ease-out);
    transition-delay: var(--reveal-delay, 0s);
}

.js .reveal--zoom {
    transform: scale(.94);
}

.js .reveal--right {
    transform: translateX(30px);
}

.js .reveal.is-visible {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition-duration: .01ms !important;
        transition-delay: 0s !important;
        animation-duration: .01ms !important;
    }

    .js .reveal {
        opacity: 1;
        transform: none;
    }
}

/* Responsive -------------------------------------------------------------- */
@media (max-width: 800px) {
    :root {
        --gutter: 20px;
    }

    .site-header {
        padding-top: 35px;
    }

    .site-main {
        padding-top: 35px;
    }

    .grid {
        grid-template-columns: 1fr;
        row-gap: 30px;
    }

    /* Contactgegevens op mobiel bovenaan */
    .contact-card {
        order: -1;
    }

    /* Uitgevulde tekst; afbreken voorkomt grote gaten tussen woorden */
    .intro p {
        text-align: justify;
        -webkit-hyphens: auto;
        hyphens: auto;
    }

    .js .reveal--right {
        transform: translateY(24px);
    }
}

@media (max-width: 480px) {
    :root {
        --font-size-base: 16px;
        --gutter: 16px;
    }

    .logo {
        max-width: 280px;
    }

    .contact-card {
        padding: 20px;
    }
}
