/*
Theme Name: Project
Theme URI: https://example.com
Author: Uw bedrijf
Author URI: https://example.com
Description: Responsive WordPress thema met uploadbaar logo (579 x 659 px) en een menu dat over het onderste, witte gedeelte van het logo wordt getoond. Menu-items verwijzen naar door u zelf in te vullen pagina's (Kozijnen, Service, Montage, Contact). Inclusief een Facebook-icoon in de footer.
Version: 1.0
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: project
*/

/* ==========================================================================
   0. Custom properties / tokens
   ========================================================================== */
:root {
    --color-bg: #96b5c7;          /* diepe antraciet/blauw achtergrond achter het (witte) logo */
    --color-bg-alt: #f5f6f7;      /* lichte pagina-achtergrond */
    --color-text: #1b1f24;
    --color-text-muted: #5b636c;
    --color-accent: #c8802a;      /* warme koper/messing tint - verwijst naar kozijnbeslag */
    --color-white: #ffffff;
    --color-menu-text: #000000;   /* zwarte menutekst, zoals gevraagd */
    --font-display: 'Poppins', 'Segoe UI', Arial, sans-serif;
    --font-body: 'Inter', 'Segoe UI', Arial, sans-serif;
    --logo-ratio: 579 / 659;      /* breedte / hoogte van het logo */
    --container-width: 1180px;
}

/* ==========================================================================
   1. Basis / reset
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

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

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

.container {
    width: 100%;
    max-width: var(--container-width);
    margin-inline: auto;
    padding-inline: 24px;
}

/* ==========================================================================
   2. Header + logo met overlappend menu
   ========================================================================== */
.site-header {
    background: var(--color-bg);
    display: flex;
    justify-content: center;
    padding-block: 28px;
}

/*
 * De logo-wrapper houdt exact de verhouding van het logo aan (579 x 659).
 * Het menu wordt er absoluut overheen gepositioneerd, in het witte
 * onderste gedeelte van het logo, 15px vanaf de onderrand, gecentreerd.
 * Doordat alles procentueel schaalt blijft de positie kloppen op elk scherm.
 */
.branding {
    position: relative;
    width: min(260px, 60vw);
    aspect-ratio: var(--logo-ratio);
}

.custom-logo-link,
.site-branding-fallback {
    display: block;
    width: 100%;
    height: 100%;
}

.custom-logo-link img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Placeholder wanneer er nog geen logo is geupload via Customizer */
.site-branding-fallback {
    background: var(--color-white);
    border-radius: 4px;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    color: var(--color-text-muted);
    font-size: 12px;
    text-align: center;
    padding-bottom: 15px;
}

.primary-menu-wrap {
    position: absolute;
    left: 50%;
    bottom: 0%;                    /* pas dit percentage aan om hoger/lager te plaatsen (px / 659 * 100) */
    transform: translateX(-50%);
    width: 100%;
    display: flex;
    justify-content: center;
}

.primary-menu {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 0;
    margin: 0;
    padding: 6px 18px;
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(4px);
    border-radius: 999px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
    animation: kozijn-menu-in 0.6s ease-out 0.15s both;
}

@keyframes kozijn-menu-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .primary-menu {
        animation: none;
    }
}

.primary-menu li {
    display: flex;
    align-items: center;
}

.primary-menu li + li::before {
    content: "|";
    color: var(--color-menu-text);
    margin-inline: 8px;
    font-weight: 400;
    opacity: 0.6;
}

.primary-menu a {
    position: relative;
    color: var(--color-menu-text);
    font-family: var(--font-display);
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-size: clamp(9px, 1.6vw, 13px);
    white-space: nowrap;
    padding-block: 3px;
    transition: color 0.2s ease;
}

.primary-menu a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: -2px;
    width: 0;
    height: 2px;
    background: var(--color-accent);
    transform: translateX(-50%);
    transition: width 0.25s ease;
}

.primary-menu a:hover,
.primary-menu a:focus-visible {
    color: var(--color-accent);
    outline: none;
}

.primary-menu a:hover::after,
.primary-menu a:focus-visible::after {
    width: 100%;
}

/* Mobiel menu-knop (verschijnt alleen als het menu niet meer past) */
.menu-toggle { display: none; }

/* ==========================================================================
   3. Pagina-inhoud
   ========================================================================== */
.site-main {
    padding-block: 56px;
}

.page-header {
    margin-bottom: 32px;
    border-bottom: 3px solid var(--color-accent);
    padding-bottom: 16px;
}

.page-title {
    font-family: var(--font-display);
    font-size: clamp(28px, 4vw, 42px);
    margin: 0;
    color: var(--color-text);
}

.page-content {
    font-size: 17px;
    max-width: 760px;
}

.page-content p:first-child { margin-top: 0; }

.entry-content img {
    border-radius: 6px;
    margin-block: 20px;
}

/* Homepage: titel en tekst gecentreerd tonen.
   WordPress zet automatisch de class "home" op <body> voor de homepage,
   dus deze regels gelden alleen daar - de andere pagina's blijven links uitgelijnd. */
.home .page-header {
    text-align: center;
    border-bottom: none;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.home .page-content {
    text-align: center;
    margin-inline: auto;
}

/* ==========================================================================
   4. Footer
   ========================================================================== */
.site-footer {
    background: var(--color-bg);
    color: var(--color-black);
    padding-block: 28px;
    text-align: center;
    font-size: 14px;
}

.site-footer a { color: var(--color-accent); }

.footer-inner p {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: var(--color-white);
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.social-icon:hover,
.social-icon:focus-visible {
    background: var(--color-accent);
    color: var(--color-white);
    transform: translateY(-2px);
    outline: none;
}

/* ==========================================================================
   5. Responsive aanpassingen
   ========================================================================== */
@media (max-width: 480px) {
    .branding { width: 72vw; }
    .primary-menu li + li::before { margin-inline: 5px; }
}

@media (min-width: 1024px) {
    .branding { width: 300px; }
}
