/* Sounion 3D – theme styles (same layout as the new Ancient Athens 3D site).
   Main colours come from the palette (Appearance → Editor → Styles → Colors). */

:root {
	--snn-base: var(--wp--preset--color--base, #F4EFE4);
	--snn-ink: var(--wp--preset--color--contrast, #1E2328);
	--snn-accent: var(--wp--preset--color--accent-1, #495E73);
	--snn-sand: var(--wp--preset--color--accent-2, #ECE5D6);
	--snn-dark: var(--wp--preset--color--accent-3, #3A4B5C);
	--snn-muted: var(--wp--preset--color--accent-4, #59616A);
	--snn-line: var(--wp--preset--color--accent-5, #E0D8C7);
	--snn-white: var(--wp--preset--color--accent-6, #FFFFFF);
	--snn-titleband: var(--wp--preset--color--accent-8, #EAE3D3);
	--snn-gold: var(--wp--preset--color--accent-9, #CEB07C);
	--snn-tile-edge: rgba(206, 176, 124, 0.8);
	--snn-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
	--snn-serif: var(--wp--preset--font-family--source-serif-4, 'Source Serif 4', Georgia, serif);
	--snn-top-h: 78px;
	--snn-wide: var(--wp--style--global--wide-size, 1240px);
}
@media (max-width: 860px) {
	:root { --snn-top-h: 60px; }
}

/* ======================================================================
   Page frame: no gaps between header, banner, title band, content, footer
   ====================================================================== */

.wp-site-blocks > * { margin-block-start: 0 !important; }
.wp-site-blocks > p:empty,
.wp-site-blocks > br { display: none; }

.snn-main { padding-top: 40px; padding-bottom: 64px; }
.snn-cover-rule + .snn-main { padding-top: 48px; }

/* ======================================================================
   Header: scrolls away with the page, then slides back in fixed and
   slimmer (as on the Film Cameras site). The class is set by sounion.js.
   ====================================================================== */

header.wp-block-template-part:has(.snn-top) { position: relative; z-index: 100; }

.snn-top {
	background: var(--snn-accent);
	box-shadow: 0 2px 6px rgba(20, 30, 40, 0.22);
}
header.wp-block-template-part.is-sticky .snn-top {
	position: fixed;
	left: 0;
	right: 0;
	top: var(--wp-admin--admin-bar--height, 0px);
	z-index: 100;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
	animation: snn-slide-down 0.35s ease-out;
}
header.wp-block-template-part.is-sticky .snn-top__inner { height: 60px; }
header.wp-block-template-part.is-sticky .snn-logo__img { max-height: 44px; }
@keyframes snn-slide-down {
	from { transform: translateY(-100%); }
	to { transform: translateY(0); }
}
@media (max-width: 600px) {
	header.wp-block-template-part.is-sticky .snn-top { top: 0; }
}
@media (prefers-reduced-motion: reduce) {
	header.wp-block-template-part.is-sticky .snn-top { animation: none; }
}

.snn-top__inner {
	max-width: 1440px;
	margin: 0 auto;
	padding: 0 32px;
	height: var(--snn-top-h);
	box-sizing: border-box;
	display: flex;
	align-items: center;
	gap: 24px;
	transition: height 0.2s ease;
}
.snn-logo {
	flex: 0 0 auto;
	font-family: var(--snn-serif);
	font-size: 1.5rem;
	font-weight: 600;
	color: #FFFFFF !important;
	white-space: nowrap;
	text-decoration: none !important;
}
.snn-logo--img { display: flex; align-items: center; height: 100%; }
.snn-logo__img { display: block; width: auto; height: auto; max-height: 62px; max-width: 230px; transition: max-height 0.2s ease; }

/* Menu: one row, centred; About – Contact last */
.snn-top__nav { flex: 1 1 auto; min-width: 0; }
.snn-links {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 8px 24px;
	flex-wrap: nowrap;
	justify-content: center;
}
.snn-links li { flex: 0 0 auto; }
.snn-links a {
	display: inline-block;
	padding: 10px 0;
	color: #FFFFFF;
	font-size: 0.9375rem;
	font-weight: 500;
	white-space: nowrap;
	text-decoration: none;
}
.snn-links a:hover { color: var(--snn-gold); text-decoration: none; }
.snn-links a.is-current { box-shadow: inset 0 -2px 0 var(--snn-gold); }

.snn-top__tools { flex: 0 0 auto; display: flex; align-items: center; gap: 10px; padding-left: 8px; border-left: 1px solid rgba(255, 255, 255, 0.22); }

/* No focus frame when a link or button is clicked with the mouse (keyboard users still see it) */
.snn-links a:focus:not(:focus-visible),
.snn-lang:focus:not(:focus-visible),
.snn-logo:focus:not(:focus-visible),
.snn-sbtn:focus:not(:focus-visible),
.snn-mbtn:focus:not(:focus-visible),
.snn-footer a:focus:not(:focus-visible) { outline: none; }
.snn-links a:focus-visible,
.snn-lang:focus-visible,
.snn-logo:focus-visible,
.snn-sbtn:focus-visible,
.snn-mbtn:focus-visible { outline: 2px solid var(--snn-gold); outline-offset: 2px; }

/* Search: an icon in the header that opens a search bar below it */
.snn-sbtn,
.snn-mbtn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: var(--snn-gold);
	cursor: pointer;
}
.snn-sbtn:hover, .snn-sbtn[aria-expanded="true"] { color: #FFFFFF; }
.snn-sbar { background: var(--snn-titleband); border-bottom: 1px solid var(--snn-line); }
.snn-sbar__inner { max-width: 1440px; margin: 0 auto; padding: 12px 32px; box-sizing: border-box; display: flex; justify-content: flex-end; }
.snn-search { margin: 0; }
.snn-search input {
	height: 44px;
	width: 360px;
	max-width: 100%;
	box-sizing: border-box;
	padding: 0 12px;
	border: 1px solid var(--snn-line);
	border-radius: 0;
	background: var(--snn-white);
	font: inherit;
	font-size: 1rem;
	color: var(--snn-ink);
}

/* Language switch: flag in the header, flag + name in the mobile menu */
.snn-lang {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 4px;
	color: #FFFFFF !important;
	font-size: 0.9375rem;
	font-weight: 600;
	text-decoration: none !important;
}
.snn-lang__flag { display: block; width: 26px; height: auto; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.6); }
.snn-top__tools .snn-lang__flag + .snn-lang__name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Mobile menu panel */
.snn-mbtn { display: none; }
.snn-mpanel {
	background: var(--snn-white);
	border-bottom: 1px solid var(--snn-line);
	padding: 12px 20px 20px;
	max-height: calc(100vh - var(--snn-top-h));
	overflow-y: auto;
}
.snn-mpanel .snn-search input { width: 100%; height: 48px; font-size: 1.0625rem; }
.snn-mpanel .snn-links { flex-direction: column; justify-content: flex-start; gap: 0; margin-top: 8px; }
.snn-mpanel .snn-links a { display: block; padding: 13px 0; font-size: 1.0625rem; border-bottom: 1px solid var(--snn-line); white-space: normal; }
.snn-mpanel .snn-links a, .snn-mpanel .snn-lang { color: var(--snn-ink) !important; }
.snn-mpanel .snn-links a.is-current { box-shadow: inset 3px 0 0 var(--snn-gold); padding-left: 12px; }
.snn-mpanel .snn-lang__flag { box-shadow: 0 0 0 1px var(--snn-line); }
.snn-mpanel__langs { padding-top: 12px; }

/* The menu needs about 1220px; below that it moves into the ☰ panel */
@media (max-width: 1220px) {
	.snn-top__inner { padding: 0 8px 0 20px; gap: 4px; }
	.snn-top__nav, .snn-top__tools, .snn-sbar { display: none !important; }
	.snn-mbtn { display: inline-flex; }
	.snn-mbtn--first { margin-left: auto; }
}
@media (max-width: 860px) {
	.snn-top__inner { padding: 0 8px 0 16px; }
	.snn-logo { font-size: 1.3rem; }
	.snn-logo__img { max-height: 46px; max-width: 200px; }
}
@media (min-width: 1221px) {
	.snn-mpanel { display: none !important; }
}

/* ======================================================================
   Banner, title band, breadcrumbs
   ====================================================================== */

.snn-cover {
	height: clamp(280px, 40vw, 520px);
	box-sizing: border-box;
	padding: 0 24px clamp(28px, 4vw, 56px);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: flex-end;
	text-align: center;
	background-color: var(--snn-accent);
	background-size: cover;
	background-position: center;
	background-attachment: fixed;
}
@media (hover: none), (max-width: 860px) {
	.snn-cover { background-attachment: scroll; }
}
.snn-cover__frame {
	max-width: 1000px;
	padding: 18px 36px 20px;
	background: rgba(20, 24, 30, 0.58);
}
.snn-cover__title {
	margin: 0;
	font-family: var(--snn-serif);
	font-size: clamp(2.1rem, 1.4rem + 3vw, 3.9rem);
	font-weight: 600;
	line-height: 1.1;
	color: #FFFFFF;
	text-shadow: var(--snn-shadow);
}
.snn-cover__sub {
	margin: 12px 0 0;
	font-size: clamp(1.05rem, 0.9rem + 0.6vw, 1.3rem);
	color: #FFFFFF;
}
.snn-cover-rule { height: 4px; background: var(--snn-gold); }

/* page without a featured image */
.snn-cover--plain { height: auto; padding: 40px 24px 12px; background: var(--snn-titleband); }
.snn-cover--plain .snn-cover__frame { background: none; padding: 0; }
.snn-cover--plain .snn-cover__title,
.snn-cover--plain .snn-cover__sub { color: var(--snn-ink); text-shadow: none; }

/* search results, 404 */
.snn-cover--list { height: auto; min-height: 170px; padding-top: 36px; background: linear-gradient(180deg, #5A7088 0%, var(--snn-accent) 100%); background-attachment: scroll; }

.snn-titleband {
	background: var(--snn-titleband);
	border-bottom: 1px solid var(--snn-line);
	padding: 14px 32px;
}
@media (max-width: 860px) { .snn-titleband { padding: 14px 16px; } }

.snn-crumbs { max-width: var(--snn-wide); margin: 0 auto; }
.snn-crumbs ol {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	font-size: 0.9375rem;
	color: var(--snn-muted);
}
.snn-crumbs li + li::before { content: "›"; margin-right: 4px; }
.snn-crumbs a { color: var(--snn-muted); }
.snn-crumbs a:hover { color: var(--snn-accent); }
.snn-crumbs [aria-current] { color: var(--snn-ink); }

/* ======================================================================
   Footer
   ====================================================================== */

.snn-footer { background: var(--snn-dark); }
.snn-footer__inner {
	max-width: var(--snn-wide);
	margin: 0 auto;
	padding: 48px 32px 28px;
	box-sizing: border-box;
	display: grid;
	grid-template-columns: 1.4fr 1fr 1fr 1fr;
	gap: 32px;
}
@media (max-width: 960px) { .snn-footer__inner { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .snn-footer__inner { grid-template-columns: 1fr; padding: 40px 20px 24px; } }
.snn-footer p { margin: 0; font-size: 0.9375rem; line-height: 1.6; color: #C3CBD3; }
.snn-footer .snn-footer__name { font-family: var(--snn-serif); font-size: 1.25rem; font-weight: 600; color: #FFFFFF; margin-bottom: 10px; }
.snn-footer .snn-footer__title { font-weight: 600; color: var(--snn-gold); margin-bottom: 6px; }
.snn-footer a { color: #E8ECF0; }
.snn-footer a:hover { color: #FFFFFF; }
.snn-footer__list { list-style: none; margin: 0; padding: 0; font-size: 0.9375rem; line-height: 2; }
.snn-footer__bottom {
	max-width: var(--snn-wide);
	margin: 0 auto;
	padding: 20px 32px 32px;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	gap: 20px;
	flex-wrap: wrap;
	border-top: 1px solid rgba(255, 255, 255, 0.14);
	font-size: 0.875rem;
	color: #C3CBD3;
}
@media (max-width: 560px) { .snn-footer__bottom { padding: 20px 20px 28px; } }

/* social icons (coloured tiles) */
.snn-social { display: flex; gap: 10px; flex-wrap: wrap; }
.snn-social__link { display: inline-flex; align-items: center; justify-content: center; width: 46px; height: 46px; color: #FFFFFF !important; background: var(--snn-ink); }
.snn-social__link:hover { filter: brightness(1.12); }
.snn-social--youtube { background: #E62117; }
.snn-social--facebook { background: #1877F2; }
.snn-social--instagram { background: #C13584; }
.snn-social--x { background: #000000; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35); }

/* ======================================================================
   Content: text, images, galleries
   ====================================================================== */

.wp-block-post-content > :first-child { margin-top: 0; }
.wp-block-post-content h2 { margin-top: 2.2em; }

/* intro panel: sand with a thin gold edge */
.snn-panel {
	background: var(--snn-sand);
	border-left: 3px solid var(--snn-tile-edge);
	padding: 22px 28px !important;
}
.snn-panel > :first-child { margin-top: 0; }
.snn-panel > :last-child { margin-bottom: 0; }

/* image shadow (as on the old site); style "No shadow" removes it */
.wp-block-post-content .wp-block-image img { box-shadow: var(--snn-shadow); }
.wp-block-post-content .wp-block-image.is-style-no-shadow img,
.wp-block-post-content .snn-cards .wp-block-image img { box-shadow: none; }

/* captions: a discreet band under the image, as wide as the image */
.wp-block-post-content .wp-block-image figcaption {
	margin: 0 !important;
	padding: 7px 12px 8px !important;
	background: rgba(73, 94, 115, 0.07);
	border-bottom: 1px solid rgba(206, 176, 124, 0.55);
	color: var(--snn-muted);
	font-size: 0.9375rem;
	line-height: 1.45;
	text-align: center;
}
.wp-block-post-content figure.wp-block-image:not(.wp-block-gallery figure):not(.alignfull):not(.alignwide):has(> figcaption) { width: fit-content; max-width: 100%; margin-left: auto; margin-right: auto; }
.wp-block-post-content figure.wp-block-image:has(> figcaption) > img,
.wp-block-post-content figure.wp-block-image:has(> figcaption) > a > img { display: block; }

/* links in text: blue with a gold underline */
.wp-block-post-content :is(p, li, figcaption) a:not(.wp-element-button) {
	text-decoration: underline;
	text-decoration-color: var(--snn-gold);
	text-decoration-thickness: 3px;
	text-underline-offset: 4px;
}
.wp-block-post-content :is(p, li, figcaption) a:not(.wp-element-button):hover { color: #7E6230; }

/* galleries: two columns, 16:9 crops, captions below the images */
.wp-block-gallery.has-nested-images { gap: 24px !important; }
.wp-block-gallery.has-nested-images figure.wp-block-image { justify-content: flex-start; }
.wp-block-gallery.has-nested-images figure.wp-block-image:has(figcaption)::before { display: none; }
.wp-block-gallery.has-nested-images figure.wp-block-image figcaption {
	position: static;
	flex-basis: 100%;
	max-height: none;
	overflow: visible;
	margin: 0;
	padding: 8px 10px 6px !important;
	background: none;
	color: var(--snn-muted);
	text-shadow: none;
	text-align: center;
	font-size: 0.9375rem;
	line-height: 1.45;
}
.wp-block-gallery.has-nested-images.is-cropped figure.wp-block-image:not(#individual-image) img { aspect-ratio: 16 / 9; height: auto; flex: none; }

/* home page: picture cards linking to the sections */
.snn-cards { gap: 24px !important; margin-top: 1.5em; }
.snn-cards > .wp-block-column {
	background: var(--snn-white);
	border: 1px solid var(--snn-line);
	border-bottom: 3px solid var(--snn-gold);
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.snn-cards > .wp-block-column:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(30, 35, 40, 0.14); }
.snn-cards .wp-block-image { margin: 0; }
.snn-cards .wp-block-image img { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; }
.snn-cards h3 { margin: 0; padding: 14px 16px 16px; font-size: 1.125rem; text-align: center; }
.snn-cards h3 a { color: var(--snn-ink); text-decoration: none; }
.snn-cards h3 a:hover { color: var(--snn-accent); }
@media (max-width: 781px) {
	.snn-cards { flex-wrap: wrap !important; }
	.snn-cards > .wp-block-column { flex-basis: calc(50% - 12px) !important; flex-grow: 0; }
}

/* Support box (About page) – as on the new Ancient Athens 3D site */
.snn-supportbox {
	max-width: 760px;
	margin: 40px auto !important;
	padding: 28px !important;
	box-sizing: border-box;
	background: var(--snn-accent);
	color: #FFFFFF;
}
.snn-supportbox h3 { margin-top: 0; color: #FFFFFF; }
.snn-supportbox > p { color: #DDE3E9; }
.snn-support-row {
	display: flex;
	flex-wrap: wrap;
	gap: 10px 14px;
	align-items: center;
	justify-content: space-between;
	margin-top: 12px !important;
	padding: 14px 16px;
	background: rgba(255, 255, 255, 0.07);
	border: 1px solid rgba(206, 176, 124, 0.65);
}
.snn-support-row > * { margin: 0 !important; }
.snn-support-row p { color: #DDE3E9; font-size: 0.9375rem; line-height: 1.45; }
.snn-support-row strong { color: #FFFFFF; font-family: var(--snn-serif); font-size: 1.125rem; font-weight: 600; }
.snn-support-row .wp-block-button__link { padding: 8px 16px; font-size: 0.9375rem; }
.snn-paypal { margin: 0; }
.snn-paypal button {
	border: 0;
	cursor: pointer;
	font-family: inherit;
	font-weight: 600;
	background: var(--snn-gold);
	color: var(--snn-ink);
}
.snn-paypal button:hover { background: #BC9C63; }

/* Footer: "Visit Ancient Athens 3D" box */
.snn-footer .snn-aa3dbox {
	display: block;
	max-width: 260px;
	margin: 4px 0 14px;
	background: #FFFFFF;
	border-bottom: 3px solid var(--snn-gold);
	text-decoration: none !important;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.snn-footer .snn-aa3dbox:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3); }
.snn-aa3dbox img { display: block; width: 100%; height: auto; }
.snn-footer .snn-aa3dbox span { display: block; padding: 8px 12px; color: var(--snn-ink); font-size: 0.9375rem; font-weight: 600; }
.snn-footer .snn-aa3dbox:hover span { color: var(--snn-accent); }

/* search results */
.snn-results .wp-block-post { padding: 18px 0; border-bottom: 1px solid var(--snn-line); }
.snn-results .wp-block-post-title { margin: 0 0 6px; }
.snn-results .wp-block-post-title a { color: var(--snn-accent); }

/* no rounded corners anywhere */
.wp-element-button, .wp-block-button__link, .wp-block-search__input, .wp-block-search__button { border-radius: 0 !important; }

/* screen-reader text */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ======================================================================
   Lightbox (click a picture): large picture with its caption
   ====================================================================== */
.wp-block-image a[data-snn-lb] { cursor: zoom-in; }
html.snn-lb-open { overflow: hidden; }
.snn-lb {
	position: fixed;
	inset: 0;
	z-index: 100000;
	background: rgba(15, 16, 18, 0.94);
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 56px 72px 24px;
	box-sizing: border-box;
}
.snn-lb[hidden] { display: none; }
.snn-lb__img { max-width: 100%; max-height: calc(100vh - 170px); object-fit: contain; box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5); }
.snn-lb__cap { max-width: 900px; margin: 14px 0 0; color: #E9ECEF; font-size: 1rem; line-height: 1.5; text-align: center; }
.snn-lb__count { color: #9AA3AC; font-size: 0.875rem; margin-top: 6px; }
.snn-lb__btn {
	position: absolute;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	border: 0;
	border-radius: 0;
	background: rgba(255, 255, 255, 0.08);
	color: #FFFFFF;
	cursor: pointer;
}
.snn-lb__btn:hover { background: rgba(255, 255, 255, 0.18); }
.snn-lb__btn:focus:not(:focus-visible) { outline: none; }
.snn-lb__btn[hidden] { display: none; }
.snn-lb__close { top: 12px; right: 12px; }
.snn-lb__prev { left: 12px; top: 50%; transform: translateY(-50%); }
.snn-lb__next { right: 12px; top: 50%; transform: translateY(-50%); }
@media (max-width: 700px) {
	.snn-lb { padding: 56px 8px 16px; }
	.snn-lb__prev, .snn-lb__next { top: auto; bottom: 12px; transform: none; }
}
