/*
Theme Name: Tegendraads
Description: Een modern, mobile-first block thema (FSE) voor Tegendraads Rotterdam, gebaseerd op het Bricolage Grotesque & Baloo Da 2 design system.
Author: Antigravity AI
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 7.4
*/

/* Core Custom Classes that cannot be achieved via Theme.json blocks directly */

html { scroll-behavior: smooth; }

/* The SPLIT Hero Section Wrapper */
.td-hero-split {
    position: relative;
    height: calc(100vh - 90px);
    width: 100%;
    overflow: hidden;
}

/* Background layers */
.td-hero-bg-top {
    position: absolute; top: 0; left: 0; width: 100%; height: 50%;
    background-size: cover; background-position: center bottom;
}
.td-hero-bg-bottom {
    position: absolute; bottom: 0; left: 0; width: 100%; height: 50%;
    background-size: cover; background-position: center top;
}
.td-hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.15); pointer-events: none;
}

/* The absolute positioned interactive box */
.td-hero-center-box {
    position: absolute; top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 40px 80px rgba(0,0,0,0.3);
    width: 90%; max-width: 900px; height: 250px;
    z-index: 10;
}

/* Forcing WP Columns to act rigidly as 50/50 Flex Row without collapsing on mobile */
.td-hero-columns {
    display: flex !important;
    flex-wrap: nowrap !important; /* Force row on mobile */
    height: 100%;
    margin-bottom: 0 !important;
}
.td-hero-columns > .wp-block-column {
    flex: 1 !important; /* Force 50% split */
    height: 100%;
    margin-bottom: 0 !important;
}

/* Brand Blocks inner layout */
.td-brand-block { display: flex; flex-direction: column; }
.td-brand-top, .td-brand-bottom {
    height: 50% !important;
    display: flex !important; flex-direction: column !important;
    align-items: center; justify-content: space-between;
}
.td-brand-top { padding-top: 20px !important; }
.td-brand-bottom { padding-bottom: 20px !important; }

/* QR Block */
.td-qr-block {
    display: flex !important; flex-direction: column !important;
    align-items: center; justify-content: center;
}
.td-qr-code img { width: 100px; height: 100px; }


/* --- Photo Cards Grid Component --- */
.cards-grid { 
    display: grid; grid-template-columns: 1fr; gap: 60px; 
}

/* Specific component wrapper */
.td-style-card {
    position: relative; width: 100%; max-width: 450px; margin: 0 auto;
    height: 600px; box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}
.td-card-img-top, .td-card-img-bottom { height: 50%; width: 100%; background-size: cover; }
.td-card-img-top { background-position: center bottom; }
.td-card-img-bottom { background-position: center top; }

.td-card-center-block {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 75%; aspect-ratio: 1/1; display: flex; flex-direction: column;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}
.td-ccb-top, .td-ccb-bottom { height: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; margin:0; padding:0;}


/* --- Responsive Adjustments --- */
@media (min-width: 768px) {
    .td-hero-center-box { height: 380px; }
    .td-brand-top { padding-top: 30px !important; }
    .td-brand-bottom { padding-bottom: 30px !important; }
    .td-qr-code img { width: 160px; height: 160px; }
    
    .cards-grid { grid-template-columns: repeat(2, 1fr); gap: 40px; }
    .td-style-card { height: 800px; }
}

/* --- Block Validation Fixes ---
   These classes replace inline styles that caused block recovery errors.
*/
.td-hero-bg-top { background-image: url('assets/img/about.png'); }
.td-hero-bg-bottom { background-image: url('assets/img/hero-bg.png'); }
.td-card-img-top { background-image: url('assets/img/about.png'); }
.td-card-img-bottom { background-image: url('assets/img/hero-bg.png'); }

.td-location-text, .td-subtitle-text, .td-ccb-location, .td-ccb-subtitle {
    font-size: 0.9rem; font-weight: 600; text-transform: uppercase; margin: 0;
}
.td-location-text, .td-ccb-location { margin-bottom: 5px; }
.td-subtitle-text, .td-ccb-subtitle { margin-top: 5px; }

.td-brand-name-top, .td-brand-name-bottom {
    font-size: 3rem; line-height: 0.75; margin: 0; text-transform: lowercase; font-family: var(--wp--preset--font-family--heading); font-weight: 800;
}
.td-brand-name-top { margin-bottom: 4px; }
.td-brand-name-bottom { margin-top: 4px; }

.td-qr-text { font-size: 1rem; font-weight: 600; margin-top: 20px; text-align: center; }

.td-section-padding { padding: 80px 0; }
.td-section-title { font-size: 2.5rem; margin-bottom: 35px; }
.td-lead-text { font-size: 1.3rem; font-weight: 600; margin-bottom: 25px; }

.td-ccb-title-top, .td-ccb-title-bottom {
    font-size: 3rem; line-height: 0.85; margin: 5px 0; font-family: var(--wp--preset--font-family--heading); font-weight:800; text-transform: lowercase;
}

@media (min-width: 768px) {
    .td-brand-name-top, .td-brand-name-bottom { font-size: 6rem; }
    .td-section-padding { padding: 120px 0; }
}
