/* ============================================================
   Foto's — "Het Album" + uploadpagina + lightbox
   Alle klassen gebruiken de bestaande --wd-* design tokens.
   ============================================================ */

/* ---------- Album: tafel & boek ---------- */

.wd-album-tafel {
	background: var(--wd-bruin);
	padding: 40px 36px 48px;
	position: relative;
}

.wd-album-boek {
	display: grid;
	grid-template-columns: 1fr 1fr;
	max-width: 860px;
	margin: 0 auto;
	background: var(--wd-creme);
	border-radius: 4px 8px 8px 4px;
	box-shadow:
		0 2px 0 rgba(0, 0, 0, 0.15),
		0 8px 0 rgba(0, 0, 0, 0.08),
		0 20px 50px rgba(0, 0, 0, 0.35),
		inset 3px 0 8px rgba(84, 59, 50, 0.08);
	position: relative;
	min-height: 480px;
}

/* De rug van het boek (midden) */
.wd-album-boek::before {
	content: "";
	position: absolute;
	left: 50%;
	top: 0;
	bottom: 0;
	width: 2px;
	background: linear-gradient(90deg, transparent, rgba(84, 59, 50, 0.15), transparent);
	transform: translateX(-50%);
	pointer-events: none;
	z-index: 5;
}

/* Pagina's */
.wd-album-pagina {
	padding: 32px 28px;
	position: relative;
}

.wd-album-pagina--links {
	border-radius: 4px 0 0 4px;
	padding-right: 36px;
}

.wd-album-pagina--rechts {
	border-radius: 0 8px 8px 0;
	padding-left: 36px;
}

/* Paginanummer */
.wd-album-pagina-nr {
	position: absolute;
	bottom: 12px;
	font-family: var(--wd-label);
	font-size: 11px;
	letter-spacing: 0.14em;
	color: var(--wd-inkt-zachter);
}

.wd-album-pagina--links .wd-album-pagina-nr { left: 28px; }
.wd-album-pagina--rechts .wd-album-pagina-nr { right: 28px; }

/* ---------- Album: hoofdstuk kop ---------- */

.wd-album-kicker {
	font-family: var(--wd-label);
	letter-spacing: 0.42em;
	text-transform: uppercase;
	font-size: 11px;
	color: var(--wd-oker);
	text-align: center;
	margin: 0 0 4px;
}

.wd-album-titel {
	font-family: var(--wd-serif);
	font-style: italic;
	font-weight: 500;
	font-size: 28px;
	color: var(--wd-bordeaux);
	text-align: center;
	margin: 0 0 4px;
}

/* Titel zonder tijdregel eronder: zelfde afstand tot de polaroids. */
.wd-album-titel--solo {
	margin-bottom: 22px;
}

.wd-album-tijd {
	font-family: var(--wd-label);
	letter-spacing: 0.14em;
	text-transform: uppercase;
	font-size: 12px;
	color: var(--wd-inkt-zachter);
	text-align: center;
	margin: 0 0 22px;
}

/* ---------- Album: polaroids ---------- */

.wd-album-fotos {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 14px;
}

.wd-album-foto {
	background: var(--wd-veld);
	padding: 6px 6px 22px;
	box-shadow: 0 2px 8px rgba(84, 59, 50, 0.15);
	transform: rotate(-1.5deg);
	transition: transform 0.25s, box-shadow 0.25s;
	cursor: pointer;
	margin: 0;
	position: relative;
}

.wd-album-foto:nth-child(2) { transform: rotate(1.2deg); margin-top: 8px; }
.wd-album-foto:nth-child(3) { transform: rotate(0.8deg); margin-top: 3px; }
.wd-album-foto:nth-child(4) { transform: rotate(-1deg); margin-top: 10px; }

.wd-album-foto:hover {
	transform: rotate(0) scale(1.04);
	box-shadow: 0 8px 24px rgba(84, 59, 50, 0.25);
	z-index: 10;
}

.wd-album-foto img {
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	display: block;
}

.wd-album-foto figcaption {
	text-align: center;
	font-family: var(--wd-body);
	font-style: italic;
	font-size: 13px;
	color: var(--wd-inkt-zacht);
	padding-top: 5px;
}

/* Curated (fotograaf): oker rand + stempel */
.wd-album-foto--curated {
	border: 2px solid var(--wd-oker);
	padding: 4px 4px 20px;
}

.wd-album-foto--curated::after {
	content: "Fotograaf";
	position: absolute;
	top: -8px;
	right: -8px;
	font-family: var(--wd-label);
	font-size: 9px;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	background: var(--wd-oker);
	color: var(--wd-groen);
	padding: 3px 8px;
	border-radius: 2px;
}

/* ---------- Album: leeg / placeholder ---------- */

.wd-album-foto--leeg {
	background: repeating-linear-gradient(135deg, #f7ecd4, #f7ecd4 10px, #fbf3df 10px, #fbf3df 20px);
	border: 1px solid rgba(84, 59, 50, 0.18);
	box-shadow: 0 2px 8px rgba(84, 59, 50, 0.1);
	cursor: default;
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 1;
}

.wd-album-foto--leeg:hover {
	transform: rotate(-1.5deg);
	box-shadow: 0 2px 8px rgba(84, 59, 50, 0.1);
}

.wd-album-foto--leeg::before {
	content: "foto volgt";
	font-family: var(--wd-mono);
	font-size: 11px;
	letter-spacing: 0.1em;
	color: #a58e73;
}

.wd-album-foto--leeg figcaption { display: none; }

/* ---------- Album: binnenkort pagina ---------- */

.wd-album-binnenkort {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	min-height: 340px;
	padding: 20px;
}

.wd-album-binnenkort-icon {
	font-family: var(--wd-serif);
	font-size: 40px;
	color: var(--wd-inkt-zachter);
	margin-bottom: 12px;
}

.wd-album-binnenkort-titel {
	font-family: var(--wd-serif);
	font-style: italic;
	font-size: 24px;
	color: var(--wd-bordeaux);
	margin: 0 0 8px;
}

.wd-album-binnenkort p {
	font-size: 15px;
	color: var(--wd-inkt-zacht);
	max-width: 280px;
	line-height: 1.6;
	margin: 0 0 16px;
}

.wd-album-binnenkort .wd-knop { margin-top: 4px; }

/* ---------- Album: meer laden ---------- */

.wd-album-meerladen {
	text-align: center;
	padding: 28px 0 0;
}

.js .wd-album-spread--verborgen { display: none; }
.js .wd-album-meerladen.is-done { display: none; }

/* Volgende spread half zichtbaar ("peek"): uitnodiging om verder te bladeren.
   De hoogte wordt door fotos.js op de helft gezet; deze fade laat de
   onderste polaroids in de bruine tafel wegzakken. */
.js .wd-album-spread--peek {
	overflow: hidden;
}

.js .wd-album-spread--peek::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 130px;
	background: linear-gradient(to bottom, rgba(84, 59, 50, 0), var(--wd-bruin));
	pointer-events: none;
	z-index: 6;
}

/* Gevulde knop (zelfde huisstijl als .wd-knop ) — de oude transparante
   versie was vrijwel onzichtbaar op het crème kaartoppervlak. */
.wd-album-nav-knop {
	font-family: var(--wd-label);
	font-size: 13px;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--wd-creme);
	background: var(--wd-bordeaux);
	border: none;
	border-radius: 2px;
	padding: 15px 34px;
	cursor: pointer;
	transition: background 0.2s;
}

.wd-album-nav-knop:hover:not(:disabled) {
	background: var(--wd-bordeaux-donker);
}

.wd-album-nav-knop:disabled {
	opacity: 0.3;
	cursor: default;
}

/* ---------- Album: sectielabel (tussen secties) ---------- */

.wd-album-sectielabel {
	text-align: center;
	padding: 28px 46px 0;
}

.wd-album-sectielabel span {
	font-family: var(--wd-label);
	font-size: 12px;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--wd-inkt-zacht);
	opacity: 0.85;
}

/* ---------- Album: flourish (op de tafel) ---------- */

.wd-album-flourish {
	background: var(--wd-bruin);
	text-align: center;
	padding: 24px 0 32px;
}

.wd-flourish {
	display: block;
	width: 240px;
	aspect-ratio: 1356 / 593;
	margin: 0 auto;
	background: url(green-flourish.png) center / contain no-repeat;
	opacity: 0.85;
	filter: brightness(0.6) sepia(0.3);
}

/* ---------- Dankbericht ---------- */

.wd-dankbericht {
	padding: 48px 46px 40px;
	text-align: center;
	border-bottom: 1px solid var(--wd-rand-zacht);
}

.wd-dankbericht-kicker {
	font-family: var(--wd-label);
	letter-spacing: 0.42em;
	text-transform: uppercase;
	font-size: 12px;
	color: var(--wd-oker);
	margin: 0 0 18px;
}

.wd-dankbericht p:not(.wd-dankbericht-kicker) {
	font-family: var(--wd-serif);
	font-style: italic;
	font-size: 21px;
	line-height: 1.55;
	color: var(--wd-bordeaux);
	max-width: 620px;
	margin: 0 auto 14px;
}

.wd-dankbericht p:last-of-type { margin-bottom: 0; }
.wd-dankbericht .wd-knop { margin-top: 22px; }

/* ---------- Upload: dropzone ---------- */

/* Bestandskeuze: zonder JS een gewone file-input, met JS verborgen (dropzone neemt het over). */
input[data-file-input] {
	width: 100%;
	margin: 0 0 10px;
	padding: 8px;
	border: 1px solid var(--wd-rand);
	border-radius: 3px;
	background: var(--wd-veld);
	font-family: var(--wd-body);
	font-size: 14px;
	color: var(--wd-inkt-zacht);
}

.js input[data-file-input] { display: none; }

.wd-dropzone {
	border: 1px dashed var(--wd-rand);
	border-radius: 3px;
	background: var(--wd-veld);
	padding: 40px 24px;
	text-align: center;
	cursor: pointer;
	transition: border-color 0.2s, background 0.2s;
}

.wd-dropzone:hover,
.wd-dropzone.drag-over {
	border-color: var(--wd-oker);
	background: var(--wd-creme-licht);
}

.wd-dropzone-icon {
	font-family: var(--wd-serif);
	font-size: 36px;
	color: var(--wd-inkt-zachter);
	margin-bottom: 10px;
}

.wd-dropzone.drag-over .wd-dropzone-icon { color: var(--wd-oker); }

.wd-dropzone-titel {
	font-family: var(--wd-serif);
	font-style: italic;
	font-size: 20px;
	color: var(--wd-bordeaux);
	margin: 0 0 6px;
}

.wd-dropzone-sub {
	font-size: 15px;
	color: var(--wd-inkt-zacht);
	margin: 0;
}

.wd-dropzone-hint {
	font-family: var(--wd-mono);
	font-size: 11px;
	letter-spacing: 0.08em;
	color: var(--wd-inkt-zachter);
	margin: 10px 0 0;
}

.wd-dropzone input[type="file"] { display: none; }

/* ---------- Upload: preview ---------- */

.wd-preview-grid {
	display: none;
	grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
	gap: 10px;
	margin-top: 16px;
}

.wd-preview-grid.visible { display: grid; }

.wd-preview-item {
	position: relative;
	aspect-ratio: 1;
	border-radius: 2px;
	overflow: hidden;
	background: var(--wd-veld);
}

.wd-preview-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.wd-preview-remove {
	position: absolute;
	top: 2px;
	right: 2px;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	border: none;
	background: var(--wd-bordeaux);
	color: var(--wd-creme);
	font-size: 12px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 0;
	transition: opacity 0.2s;
}

.wd-preview-item:hover .wd-preview-remove,
.wd-preview-item:focus-within .wd-preview-remove { opacity: 1; }

.wd-preview-progress {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 3px;
	background: var(--wd-rand-zacht);
}

.wd-preview-progress-bar {
	height: 100%;
	background: var(--wd-oker);
	width: 0%;
	transition: width 0.3s;
}

.wd-preview-count {
	font-family: var(--wd-label);
	font-size: 12px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wd-groen);
	text-align: center;
	margin: 16px 0 0;
}

.wd-preview-count[hidden] { display: none; }

/* ---------- Upload: formulier (select) ---------- */

select.wd-invoer {
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23543B32' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
	padding-right: 36px;
	cursor: pointer;
}

.wd-veldlabel-optioneel {
	text-transform: none;
	letter-spacing: 0;
	color: var(--wd-inkt-zachter);
	font-family: var(--wd-body);
	font-style: italic;
}

/* ---------- Upload: tips ---------- */

.wd-tips {
	max-width: 460px;
	margin: 32px auto 0;
	padding: 20px 24px;
	background: var(--wd-creme-licht);
	border-radius: 3px;
	border: 1px solid var(--wd-rand-zacht);
}

.wd-tips h4 {
	font-family: var(--wd-label);
	font-size: 12px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wd-groen);
	margin: 0 0 10px;
}

.wd-tips ul {
	list-style: none;
	margin: 0;
	padding: 0;
	font-size: 15px;
	color: var(--wd-inkt-zacht);
}

.wd-tips ul li {
	padding: 3px 0 3px 18px;
	position: relative;
	line-height: 1.5;
}

.wd-tips ul li::before {
	content: "·";
	position: absolute;
	left: 4px;
	color: var(--wd-oker);
	font-size: 18px;
}

/* ---------- Lightbox ---------- */

.wd-lightbox {
	display: none;
	position: fixed;
	inset: 0;
	background: rgba(65, 77, 51, 0.94);
	z-index: 200;
	align-items: center;
	justify-content: center;
	flex-direction: column;
}

.wd-lightbox.open { display: flex; }

.wd-lightbox img {
	max-width: 88vw;
	max-height: 78vh;
	border-radius: 2px;
}

.wd-lightbox .lb-close {
	position: absolute;
	top: 20px;
	right: 28px;
	font-family: var(--wd-label);
	font-size: 13px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wd-licht);
	background: transparent;
	border: none;
	cursor: pointer;
	padding: 8px 16px;
}

.wd-lightbox .lb-close:hover { color: var(--wd-oker); }

.wd-lightbox .lb-info {
	color: var(--wd-licht);
	font-family: var(--wd-label);
	font-size: 12px;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	padding: 16px;
}

.wd-lightbox .lb-nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	font-family: var(--wd-serif);
	font-size: 48px;
	color: var(--wd-licht);
	background: transparent;
	border: none;
	cursor: pointer;
	opacity: 0.4;
	padding: 20px;
	user-select: none;
}

.wd-lightbox .lb-nav:hover { opacity: 1; color: var(--wd-oker); }
.wd-lightbox .lb-prev { left: 12px; }
.wd-lightbox .lb-next { right: 12px; }

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
	.wd-album-tafel { padding: 24px 16px 32px; }
	.wd-album-sectielabel { padding: 20px 26px 0; }
	.wd-dankbericht { padding-left: 26px; padding-right: 26px; }
}

@media (max-width: 760px) {
	.wd-album-boek { grid-template-columns: 1fr; }
	.wd-album-boek::before { display: none; }
	.wd-album-pagina--links { border-radius: 4px 4px 0 0; padding-right: 28px; }
	.wd-album-pagina--rechts {
		border-radius: 0 0 8px 8px;
		padding-left: 28px;
		border-top: 1px dashed var(--wd-rand);
	}
}

@media (max-width: 640px) {
	.wd-album-fotos { grid-template-columns: 1fr; }
	.wd-album-foto:nth-child(n) { margin-top: 0; transform: rotate(-1deg); }
	.wd-album-foto:nth-child(even) { transform: rotate(1deg); }
	.wd-dankbericht p:not(.wd-dankbericht-kicker) { font-size: 18px; }
	.wd-dropzone { padding: 28px 16px; }
	.wd-preview-grid { grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; }
}
