/* ======================================================
   PROJECT: Atelier de Monistique
   VERSION: 1.6.3 - PORTRET FRAME (3:4) & STYLING
   ====================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
    height: 100%;
    font-family: 'Montserrat', sans-serif;
    color: #1a1a1a;
    background-color: #ffffff;
}

body { 
    display: flex; 
    flex-direction: column; 
    min-height: 100vh;
}

h1, h2 { font-family: 'Playfair Display', serif; text-transform: uppercase; letter-spacing: 3px; }

/* --- BEVEILIGING AFBEELDINGEN & MEDIA --- */
img, video {
    -webkit-touch-callout: none; 
    -webkit-user-select: none; 
    -moz-user-select: none; 
    -ms-user-select: none; 
    user-select: none; 
    -webkit-user-drag: none; 
}

img { pointer-events: none; }

/* --- HEADER (GECENTREERD) --- */
header {
    position: fixed; top: 0; left: 0; width: 100%; height: 130px; 
    display: flex; flex-direction: column; justify-content: center; align-items: center;
    padding: 10px 0; background: #ffffff; z-index: 1000; border-bottom: 1px solid #f0f0f0;
}

.logo-link { display: flex; align-items: center; text-decoration: none; margin-bottom: 5px; pointer-events: auto; }
.site-logo { width: 55px; height: 55px; border-radius: 50%; border: 1.5px solid #b08d57; object-fit: cover; background-color: #fff; }

nav ul { display: flex; list-style: none; gap: 25px; }
nav ul li a { text-decoration: none; color: #1a1a1a; font-size: 0.7rem; letter-spacing: 2px; }
nav ul li a:hover, nav ul li a.active { color: #b08d57; }

/* --- MAIN LAYOUT --- */
main { flex: 1; margin-top: 130px; padding: 20px 8%; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.portfolio-body main { padding-top: 10px; justify-content: flex-start; align-items: stretch; }
.portfolio-body { overflow-y: auto !important; }

/* --- SPLIT LAYOUT --- */
.page-split-container { display: flex; align-items: center; justify-content: space-between; width: 100%; gap: 40px; text-align: left; }
.page-text-content { flex: 1.2; }
.page-image-content { flex: 0.8; display: flex; justify-content: flex-end; }
.index-title { font-size: 5rem; line-height: 0.95; margin-bottom: 15px; }

/* --- STYLED FRAME (Aangepast voor foto's en 3:4) --- */
.styled-frame { 
    width: 420px; 
    aspect-ratio: 1/1; /* Standaard is vierkant */
    border: 1px solid #1a1a1a; 
    background: #ffffff; /* Wit i.v.m. de rand */
    padding: 15px; /* Creëert een mooie witte passe-partout rand */
    display: flex; align-items: center; justify-content: center; 
    text-align: center; color: #ccc;
}

/* De speciale 3:4 portret modifier */
.styled-frame.portrait {
    width: 360px; /* Iets smaller op laptop, anders wordt de foto te dominant hoog */
    aspect-ratio: 3/4;
}

/* Zorgt dat afbeeldingen netjes de binnenkant van het kader vullen */
.styled-frame img { 
    width: 100%; height: 100%; object-fit: cover; display: block; 
}

/* --- PORTFOLIO TABS & GRID --- */
.portfolio-tabs { display: flex; width: 100%; border-bottom: 1px solid #f0f0f0; margin-bottom: 25px; margin-top: 10px; }
.tab-button { flex: 1; background: none; border: none; padding: 12px; font-family: 'Montserrat', sans-serif; font-size: 0.75rem; letter-spacing: 2px; text-transform: uppercase; cursor: pointer; color: #999; position: relative; text-align: center; }
.tab-button.active { color: #1a1a1a; font-weight: bold; }
.tab-button.active::after { content: ''; position: absolute; bottom: -1px; left: 0; width: 100%; height: 3px; background: #b08d57; }
.tab-content { display: none; }
.tab-content.active { display: grid; }
.portfolio-grid { grid-template-columns: repeat(3, 1fr); gap: 40px; width: 100%; padding-bottom: 40px; }

/* --- ART FRAME & TEKST UITLIJNING --- */
.portfolio-item { display: flex; flex-direction: column; align-items: center; width: 100%; position: relative; }
.art-frame { width: 100%; aspect-ratio: 1/1; background: #ffffff; border: 1px solid #1a1a1a; padding: 15px; display: flex; align-items: center; justify-content: center; margin-bottom: 12px; cursor: zoom-in; }
.art-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.art-info { text-align: center; width: 100%; }
.art-title { font-weight: bold; text-transform: uppercase; font-size: 0.8rem; letter-spacing: 1px; }

/* --- VIDEO TAB BUTTON --- */
.video-tab-btn { position: absolute; top: -12px; left: 20px; background-color: #ffffff; border: 1px solid #1a1a1a; color: #b08d57; padding: 3px 12px; font-family: 'Montserrat', sans-serif; font-size: 0.65rem; font-weight: bold; letter-spacing: 2px; text-transform: uppercase; cursor: pointer; z-index: 10; transition: 0.3s; }
.video-tab-btn:hover { background-color: #b08d57; color: #ffffff; border-color: #b08d57; }

/* --- IMAGE POPUP OVERLAY --- */
.image-popup-overlay { visibility: hidden; opacity: 0; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 2000; background: #ffffff; padding: 20px; border: 1px solid #1a1a1a; box-shadow: 0 10px 40px rgba(0,0,0,0.3); max-width: 90vw; max-height: 90vh; pointer-events: none; transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out; }
.image-popup-overlay.show { visibility: visible; opacity: 1; }
.image-popup-overlay img { max-width: 100%; max-height: calc(90vh - 40px); object-fit: contain; display: block; }

/* --- VIDEO POPUP OVERLAY --- */
.video-popup-overlay { visibility: hidden; opacity: 0; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 2000; background: #ffffff; padding: 35px 20px 20px 20px; border: 1px solid #1a1a1a; box-shadow: 0 10px 40px rgba(0,0,0,0.3); max-width: 90vw; max-height: 90vh; pointer-events: auto; transition: opacity 0.3s ease-in-out, visibility 0.3s ease-in-out; }
.video-popup-overlay.show { visibility: visible; opacity: 1; }
.video-popup-overlay video { max-width: 100%; max-height: calc(90vh - 55px); display: block; background: #000; }
.close-video { position: absolute; top: 8px; right: 12px; font-size: 1.5rem; cursor: pointer; color: #999; font-weight: bold; line-height: 1; transition: 0.3s; }
.close-video:hover { color: #1a1a1a; }

/* --- CONTACT --- */
.contact-container { width: 100%; max-width: 550px; text-align: center; display: flex; flex-direction: column; gap: 20px; }
.contact-form { display: flex; flex-direction: column; gap: 15px; }
.contact-form input, .contact-form textarea { width: 100%; padding: 15px; border: 1px solid #1a1a1a; font-family: 'Montserrat', sans-serif; font-size: 0.85rem; background-color: #f9f9f9; }
.contact-form textarea { height: 130px; resize: none; }
.contact-form button { padding: 18px; background: #1a1a1a; color: #fff; border: none; cursor: pointer; font-family: 'Montserrat', sans-serif; font-weight: bold; letter-spacing: 2px; text-transform: uppercase; transition: 0.3s; }
.contact-form button:hover { background: #b08d57; }

/* --- FOOTER --- */
footer { flex-shrink: 0; height: 50px; display: flex; align-items: center; justify-content: center; font-size: 0.65rem; color: #ccc; border-top: 1px solid #f0f0f0; background: #fff; }

/* --- MOBIELE OPTIMALISATIE --- */
@media (max-width: 768px) {
    header { height: auto; padding: 15px 5%; position: relative; }
    main { margin-top: 0; padding: 40px 5%; justify-content: flex-start; }
    nav ul { gap: 15px; flex-wrap: wrap; justify-content: center; }
    .page-split-container { flex-direction: column-reverse; text-align: center; gap: 30px; }
    
    /* Zorgt dat kaders meeschalen op mobiel */
    .styled-frame { width: 100%; max-width: 300px; height: auto; aspect-ratio: 1/1; }
    /* Specifieke correctie voor de 3:4 portretfoto op mobiel */
    .styled-frame.portrait { max-width: 260px; aspect-ratio: 3/4; }
    
    .index-title { font-size: 3rem; }
    .portfolio-grid { grid-template-columns: 1fr; }
    
    .image-popup-overlay { pointer-events: auto; cursor: zoom-out; width: 95vw; max-width: 95vw; max-height: 90vh; padding: 10px; }
    .image-popup-overlay img { width: 100%; max-height: calc(90vh - 20px); }
    .video-popup-overlay { width: 95vw; max-width: 95vw; max-height: 90vh; padding: 30px 10px 10px 10px; }
    .video-popup-overlay video { width: 100%; max-height: calc(90vh - 40px); }
    
    html, body { overflow: auto !important; }
}