/*
Theme Name: Hillegom Online
Theme URI: https://hillegomonline.nl
Author: Hillegom Online Team
Author URI: https://hillegomonline.nl
Description: Modern, schaalbaar WordPress thema voor lokale nieuwssite met focus op fotoreportages, evenementen en community content. Mobile-first, fluid responsive design geoptimaliseerd voor alle schermformaten.
Version: 2.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: hillegom-online
Tags: news, local, community, photography, events, responsive, accessibility-ready
*/

/* =====================================================
   CSS CUSTOM PROPERTIES (VARIABELEN)
   ===================================================== */
:root {
	/* Brand Kleuren */
	--primary-green: #F0FDFF;
	--primary-green-light: #F5FEFF;
	--blue-text: #1C7FC3;
	--yellow-accent: #FDFE00;
	--films-bg: #FDF3CC;
	
	/* Neutrale Kleuren */
	--white: #FFFFFF;
	--black: #000000;
	--gray-light: #F5F5F5;
	--gray-medium: #CCCCCC;
	--gray-dark: #333333;
	--light-gray: #E5E5E5;
	--light-bg: #FAFAFA;
	--text-color: #333333;
	
	/* Typografie */
	--font-primary: 'Myriad Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
	--font-size-base: 16px;
	--font-size-xs: 0.75rem;
	--font-size-sm: 0.875rem;
	--font-size-lg: 1.125rem;
	--font-size-xl: 1.25rem;
	--line-height: 1.6;
	
	/* Layout */
	--container-max: 1600px;
	--container-width: 1600px;
	--container-width-ultra: 1920px;
	--container-width-large: 1400px;
	--container-width-standard: 1200px;
	--sidebar-width: 320px;
	--header-height: 150px;
	
	/* Spacing */
	--spacing-xs: 0.5rem;
	--spacing-sm: 1rem;
	--spacing-md: 2rem;
	--spacing-lg: 3rem;
	--spacing-xl: 4rem;
	--spacing-2xl: 5rem;
	
	/* Border & Radius */
	--border-radius: 8px;
	--border-thin: 1px;
	
	/* Shadows */
	--shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
	--shadow-md: 0 4px 8px rgba(0,0,0,0.15);
	--shadow-lg: 0 8px 16px rgba(0,0,0,0.2);
	
	/* Transitions */
	--transition-speed: 0.3s;
}

/* =====================================================
   RESET & BASE STYLES
   ===================================================== */
*, *::before, *::after {
	box-sizing: border-box;
}

html {
	font-size: var(--font-size-base);
	scroll-behavior: smooth;
}

body {
	margin: 0;
	padding: 0;
	font-family: var(--font-primary);
	line-height: var(--line-height);
	color: var(--gray-dark);
	background-color: var(--white);
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow-x: hidden;
}

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

a {
	color: var(--blue-text);
	text-decoration: none;
	transition: color var(--transition-speed);
}

a:hover, a:focus {
	color: var(--yellow-accent);
	text-decoration: underline;
}

/* =====================================================
   TYPOGRAPHY
   ===================================================== */
h1, h2, h3, h4, h5, h6 {
	font-family: var(--font-primary);
	font-weight: 700;
	line-height: 1.2;
	margin: 0 0 var(--spacing-sm);
	color: var(--blue-text);
}

h1 { font-size: clamp(2rem, 4vw, 2.5rem); }
h2 { font-size: clamp(1.75rem, 3.5vw, 2rem); }
h3 { font-size: clamp(1.5rem, 3vw, 1.75rem); }
h4 { font-size: 1.5rem; }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

p {
	margin: 0 0 var(--spacing-sm);
}

/* =====================================================
   LAYOUT CONTAINERS
   ===================================================== */
.site {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.site-main {
	flex: 1;
}

.site-container {
	max-width: var(--container-max);
	width: 100%;
	margin: 0 auto;
	padding-left: 10px;
	padding-right: 10px;
}

.content-wrapper {
	display: grid;
	grid-template-columns: 1fr 320px;
	gap: 40px;
	margin-top: 0;
}

/* =====================================================
   HOMEPAGE LAYOUT
   ===================================================== */

/* Full width sections (recent posts, fotoreportages) */
.full-width-content {
	width: 100%;
	margin-bottom: 3rem;
}

/* Two column layout (agenda + sidebar) */
.content-sidebar-wrapper {
	display: -ms-grid;
	display: grid;
	-ms-grid-columns: 1fr 2rem 320px;
	grid-template-columns: 1fr 320px;
	gap: 2rem;
	-ms-grid-column-gap: 2rem;
	align-items: start;
	-ms-grid-rows: auto;
}

/* IE11 Grid positioning */
.content-sidebar-wrapper > .main-content-area {
	-ms-grid-column: 1;
}

.content-sidebar-wrapper > .homepage-sidebar {
	-ms-grid-column: 3;
}

.main-content-area {
	min-width: 0;
}

.homepage-sidebar {
	position: -webkit-sticky;
	position: sticky;
	top: 118px; /* 56px header + 50px menu + 12px spacing */
	-webkit-align-self: start;
	-ms-flex-item-align: start;
	align-self: start;
	max-height: calc(100vh - 118px);
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
}

/* Adjust sticky top for logged in users */
body.admin-bar .homepage-sidebar {
	top: 150px; /* +32px admin bar */
	max-height: calc(100vh - 150px);
}

@media screen and (max-width: 782px) {
	body.admin-bar .homepage-sidebar {
		top: 164px; /* +46px admin bar on mobile */
		max-height: calc(100vh - 164px);
	}
}

/* Adjust when header/menu not sticky */
body.no-sticky-header .homepage-sidebar,
body.no-sticky-menu .homepage-sidebar {
	top: 20px;
	max-height: calc(100vh - 20px);
}

/* Responsive: Stack on tablets and mobile */
@media (max-width: 992px) {
	.content-sidebar-wrapper {
		-ms-grid-columns: 1fr;
		grid-template-columns: 1fr;
		gap: 2rem;
	}
	
	.homepage-sidebar {
		position: relative;
		top: 0;
		margin-top: 2rem;
		max-height: none;
		overflow-y: visible;
	}
	
	.content-sidebar-wrapper > .homepage-sidebar {
		-ms-grid-column: 1;
		-ms-grid-row: 2;
	}
}

.main-content {
	min-width: 0;
}

.sidebar {
	position: sticky;
	top: calc(var(--header-height) + 20px);
	height: fit-content;
	align-self: start;
}

/* =====================================================
   BUTTONS
   ===================================================== */
.btn {
	display: inline-block;
	padding: 12px 28px;
	background: var(--blue-text);
	color: var(--white);
	text-decoration: none;
	border-radius: 25px;
	font-weight: 600;
	font-size: 14px;
	transition: all var(--transition-speed);
	border: 2px solid var(--blue-text);
	cursor: pointer;
	text-align: center;
}

.btn:hover, .btn:focus {
	background: #155a8a;
	border-color: #155a8a;
	transform: translateY(-2px);
	box-shadow: 0 4px 8px rgba(28, 127, 195, 0.3);
	text-decoration: none;
	color: var(--white);
}

.btn-secondary {
	background: transparent;
	color: var(--blue-text);
	border: 2px solid var(--blue-text);
	padding: 10px 24px;
}

.btn-secondary:hover, .btn-secondary:focus {
	background: var(--blue-text);
	color: var(--white);
}

/* =====================================================
   ACCESSIBILITY
   ===================================================== */
.skip-link {
	position: absolute;
	left: -9999px;
	top: 2rem;
	z-index: 999999;
	text-decoration: underline;
}

.skip-link:focus {
	left: 1rem;
	background: var(--white);
	padding: 15px 23px;
	box-shadow: var(--shadow-md);
	border-radius: var(--border-radius);
}

.screen-reader-text {
	clip: rect(1px, 1px, 1px, 1px);
	position: absolute !important;
	height: 1px;
	width: 1px;
	overflow: hidden;
	word-wrap: normal !important;
}

.screen-reader-text:focus {
	background-color: var(--white);
	border-radius: var(--border-radius);
	box-shadow: var(--shadow-md);
	clip: auto !important;
	color: var(--blue-text);
	display: block;
	font-size: 1rem;
	font-weight: 700;
	height: auto;
	left: 5px;
	line-height: normal;
	padding: 15px 23px 14px;
	text-decoration: none;
	top: 5px;
	width: auto;
	z-index: 100000;
}

/* =====================================================
   RESPONSIVE BREAKPOINTS
   ===================================================== */

/* Large Desktop */
@media (min-width: 1800px) {
	.site-container {
		max-width: 1800px;
	}
}

/* Ultra Wide */
@media (min-width: 2000px) {
	.site-container {
		max-width: 1920px;
	}
}
/* Responsive Padding - Match Header */
@media (min-width: 480px) {
	.site-container {
		padding-left: 15px;
		padding-right: 15px;
	}
}

@media (min-width: 768px) {
	.site-container {
		padding-left: 15px;
		padding-right: 15px;
	}
}

@media (min-width: 992px) {
	.site-container {
		padding-left: 16px;
		padding-right: 16px;
	}
}

@media (min-width: 1200px) {
	.site-container {
		padding-left: 20px;
		padding-right: 20px;
	}
}

@media (min-width: 1920px) {
	.site-container {
		padding-left: 30px;
		padding-right: 30px;
	}
}
/* Responsive Padding - Match Header */
@media (min-width: 480px) {
	.site-container {
		padding-left: 15px;
		padding-right: 15px;
	}
}

@media (min-width: 768px) {
	.site-container {
		padding-left: 15px;
		padding-right: 15px;
	}
}

@media (min-width: 992px) {
	.site-container {
		padding-left: 16px;
		padding-right: 16px;
	}
}

@media (min-width: 1200px) {
	.site-container {
		padding-left: 20px;
		padding-right: 20px;
	}
}

@media (min-width: 1920px) {
	.site-container {
		padding-left: 30px;
		padding-right: 30px;
	}
}

/* Laptop & Smaller Desktop */
@media (max-width: 1200px) {
	.content-wrapper {
		grid-template-columns: 1fr 280px;
		gap: 30px;
	}
}

/* Tablet Landscape */
@media (max-width: 1024px) {
	.content-wrapper {
		grid-template-columns: 1fr;
		gap: 30px;
	}
	
	.sidebar {
		position: static;
	}
}

/* Tablet Portrait */
@media (max-width: 768px) {
	:root {
		--spacing-md: 1rem;
		--spacing-lg: 2rem;
	}
	
	h1 { font-size: 2rem; }
	h2 { font-size: 1.75rem; }
	h3 { font-size: 1.5rem; }
}

/* Mobile */
@media (max-width: 480px) {
	.btn {
		padding: 10px 20px;
		font-size: 13px;
	}
}

/* =====================================================
   UTILITY CLASSES
   ===================================================== */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.hidden { display: none; }
.clearfix::after {
	content: "";
	display: table;
	clear: both;
}

/* =====================================================
   PRINT STYLES
   ===================================================== */
@media print {
	.site-header,
	.sidebar,
	.site-footer,
	.btn,
	.skip-link {
		display: none;
	}
	
	.content-wrapper {
		grid-template-columns: 1fr;
	}
	
	a {
		color: var(--black);
		text-decoration: underline;
	}
	
	body {
		font-size: 12pt;
	}
}
