/* Apollon Child: header & footer (πιστή αναπαραγωγή των Elementor templates 138/151). */

:root {
	--ap-primary: #1751C4;
	--ap-white: #FFFFFF;
	--ap-menu-bg: #F8F9FF;
	--ap-bar-bg: #E8F1FC;
	--ap-hover: #CFCFCF;
	--ap-shadow: 0 4px 4px 2px rgba(0, 0, 0, .5);
	--ap-font-display: "Dela Gothic One", sans-serif;
	--ap-font-text: "Chivo", sans-serif;
}

/* ---------- Header ---------- */

.ap-header {
	position: relative;
	z-index: 50;
	background: var(--ap-menu-bg);
	border-bottom: 2px solid var(--ap-primary);
}

.ap-header__inner {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 20px;
	min-height: 140px;
	padding: 10px;
	box-sizing: border-box;
}

.ap-header :where(ul, li) {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ap-nav {
	flex: 0 1 520px;
	max-width: 520px;
}

.ap-right {
	display: contents;
}

.ap-menu {
	display: flex;
	justify-content: center;
}

.ap-menu > li {
	position: relative;
}

.ap-menu > li > a {
	position: relative;
	display: flex;
	align-items: center;
	padding: 13px 20px;
	font-family: var(--ap-font-display);
	font-size: 14px;
	font-weight: 400;
	line-height: 20px;
	letter-spacing: .8px;
	color: var(--ap-primary);
	text-decoration: none;
	white-space: nowrap;
}

.ap-menu > li > a::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 3px;
	background: var(--ap-primary);
	opacity: 0;
	transition: opacity .3s;
}

.ap-menu > li > a:hover::after,
.ap-menu > li > a:focus-visible::after,
.ap-menu > li.current-menu-item > a::after,
.ap-menu > li.current-menu-ancestor > a::after,
.ap-menu > li:hover > a::after {
	opacity: 1;
}

.ap-caret {
	display: inline-flex;
	margin-left: 10px;
}

.ap-caret .ap-icon {
	width: .63em;
	height: 1em;
	fill: currentColor;
}

.ap-menu .sub-menu {
	position: absolute;
	top: 100%;
	left: 0;
	z-index: 60;
	min-width: 100%;
	background: var(--ap-white);
	border-bottom: 2px solid var(--ap-primary);
	box-shadow: var(--ap-shadow);
	opacity: 0;
	visibility: hidden;
	transform: translateY(4px);
	transition: opacity .2s, transform .2s, visibility .2s;
}

.ap-menu > li:hover > .sub-menu,
.ap-menu > li:focus-within > .sub-menu {
	opacity: 1;
	visibility: visible;
	transform: none;
}

.ap-menu .sub-menu li:not(:last-child),
.ap-mobile__menu li:not(:last-child) {
	border-bottom: 2px solid var(--ap-primary);
}

.ap-menu .sub-menu a,
.ap-mobile__menu a {
	display: block;
	padding: 13px 20px;
	font-family: var(--ap-font-display);
	font-size: 16px;
	font-weight: 400;
	line-height: 20px;
	color: var(--ap-primary);
	text-decoration: none;
	white-space: nowrap;
}

.ap-menu .sub-menu a:hover,
.ap-menu .sub-menu a:focus-visible,
.ap-mobile__menu a:hover,
.ap-mobile__menu a:focus-visible,
.ap-mobile__menu .current-menu-item > a {
	background: var(--ap-hover);
}

.ap-logo {
	flex: 0 0 150px;
	display: flex;
	justify-content: center;
}

.ap-logo img {
	display: block;
	width: 119px;
	height: auto;
}

.ap-social {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 20px;
}

.ap-social a {
	display: inline-flex;
	color: var(--ap-primary);
}

.ap-social .ap-icon {
	width: auto;
	height: 35px;
	fill: currentColor;
}

.ap-social--header {
	position: absolute;
	top: 0;
	right: 0;
	width: 180px;
	height: 140px;
	padding: 10px;
	box-sizing: border-box;
}

.ap-burger,
.ap-mobile {
	display: none;
}

/*
 * 1201–1599px: στο Elementor τα μενού έπεφταν πάνω στα εικονίδια (π.χ. MY APOLLON πάνω στο Facebook,
 * χειρότερα όταν είσαι συνδεδεμένος και εμφανίζεται και το ΑΠΟΣΥΝΔΕΣΗ). Εδώ τα εικονίδια πάνε μικρά
 * στην πάνω δεξιά γωνία και τα μενού παίρνουν όλο το πλάτος των πλευρών τους.
 */
@media (min-width: 1201px) and (max-width: 1599px) {
	.ap-header__inner {
		display: grid;
		grid-template-columns: 1fr auto 1fr;
		gap: 12px;
	}
	.ap-nav {
		max-width: none;
		min-width: 0;
	}
	.ap-nav--left .ap-menu {
		justify-content: flex-end;
	}
	.ap-right {
		display: flex;
		align-items: center;
		min-width: 0;
	}
	.ap-nav--right .ap-menu {
		justify-content: flex-start;
	}
	.ap-menu > li > a {
		padding: 13px 16px;
		font-size: 13px;
	}
	.ap-social--header {
		top: 10px;
		right: 14px;
		width: auto;
		height: auto;
		padding: 0;
		gap: 12px;
	}
	.ap-social--header .ap-icon {
		height: 24px;
	}
}

/*
 * ≥1600px: ίδια διάταξη με το Elementor (κουτιά 520px εκατέρωθεν του λογότυπου), αλλά τα μενού μεγαλώνουν όσο
 * χρειάζεται χωρίς να ακουμπούν το λογότυπο. Για συνδεδεμένους (εμφανίζεται και το ΑΠΟΣΥΝΔΕΣΗ)
 * τα εικονίδια πάνε στην πάνω δεξιά γωνία.
 */
@media (min-width: 1600px) {
	.ap-header__inner {
		display: grid;
		grid-template-columns: 1fr auto 1fr;
	}
	.ap-nav {
		width: max-content;
		min-width: 520px;
		max-width: none;
	}
	.ap-nav--left {
		justify-self: end;
	}
	.ap-nav--right {
		justify-self: start;
	}
	.logged-in .ap-social--header {
		top: 10px;
		right: 14px;
		width: auto;
		height: auto;
		padding: 0;
		gap: 12px;
	}
	.logged-in .ap-social--header .ap-icon {
		height: 24px;
	}
}

@media (min-width: 1201px) and (max-width: 1360px) {
	.ap-menu > li > a {
		padding: 13px 9px;
		font-size: 12px;
		letter-spacing: .5px;
	}
	.ap-caret {
		margin-left: 6px;
	}
}

/* ≤1200px: λογότυπο + στρογγυλό κουμπί μενού, εικονίδια από κάτω (όπως στο κινητό του Elementor). */
@media (max-width: 1200px) {
	.ap-header__inner {
		display: grid;
		grid-template-columns: 1fr 1fr;
		grid-template-areas:
			"logo burger"
			"social social";
		gap: 0;
		min-height: 0;
		padding: 10px;
	}
	.ap-nav {
		display: none;
	}
	.ap-right {
		display: contents;
	}
	.ap-logo {
		grid-area: logo;
		justify-self: center;
	}
	.ap-burger {
		grid-area: burger;
		justify-self: center;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 58px;
		height: 58px;
		padding: 0;
		border: 0;
		border-radius: 50%;
		background: var(--ap-primary);
		color: var(--ap-white);
		cursor: pointer;
	}
	.ap-burger .ap-icon {
		width: 26px;
		height: 26px;
		fill: currentColor;
	}
	.ap-burger__close,
	.ap-burger[aria-expanded="true"] .ap-burger__open {
		display: none;
	}
	.ap-burger[aria-expanded="true"] .ap-burger__close {
		display: inline-flex;
	}
	.ap-burger__open {
		display: inline-flex;
	}
	.ap-social--header {
		grid-area: social;
		position: static;
		width: auto;
		height: 70px;
		padding: 0;
	}
	.ap-mobile:not([hidden]) {
		display: block;
		position: absolute;
		top: 100%;
		left: 0;
		right: 0;
		max-height: 75vh;
		overflow-y: auto;
		background: var(--ap-white);
		border-bottom: 2px solid var(--ap-primary);
		box-shadow: var(--ap-shadow);
	}
	.ap-mobile__menu li {
		position: relative;
	}
	.ap-mobile__menu .menu-item-has-children > a {
		padding-right: 64px;
	}
	.ap-subtoggle {
		position: absolute;
		top: 0;
		right: 0;
		width: 56px;
		height: 46px;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		padding: 0;
		border: 0;
		background: transparent;
		color: var(--ap-primary);
		cursor: pointer;
	}
	.ap-subtoggle .ap-icon {
		width: 12px;
		height: 18px;
		fill: currentColor;
		transition: transform .2s;
	}
	.ap-subtoggle[aria-expanded="true"] .ap-icon {
		transform: rotate(180deg);
	}
	.ap-mobile__menu .sub-menu {
		display: none;
		border-top: 2px solid var(--ap-primary);
	}
	.ap-mobile__menu .is-open > .sub-menu {
		display: block;
	}
	.ap-mobile__menu .sub-menu a {
		padding-left: 40px;
	}
}

@media (max-width: 767px) {
	.ap-header__inner {
		padding: 0 10px;
	}
	.ap-logo {
		padding: 10px 0;
	}
	.ap-burger {
		width: 46px;
		height: 46px;
	}
	.ap-burger .ap-icon {
		width: 22px;
		height: 22px;
	}
}

/* ---------- Τίτλος σελίδας ---------- */

/*
 * Οι τίτλοι των σελίδων του MY APOLLON («ΤΟ ΠΡΟΦΙΛ ΜΟΥ», «ΚΑΡΤΕΛΑ ΠΑΙΔΙΟΥ» κ.λπ.) έβγαιναν
 * με τη default γραμματοσειρά του συστήματος σε γκρι. Μπαίνουν στην ταυτότητα του συλλόγου:
 * Dela Gothic One, μπλε.
 */
.page-header .entry-title {
	font-family: var(--ap-font-display);
	font-size: clamp(26px, 5vw, 40px);
	font-weight: 400;
	line-height: 1.2;
	color: var(--ap-primary);
}

/* ---------- Footer ---------- */

.ap-footer :where(h2, p) {
	margin: 0;
}

.ap-footer__main {
	display: flex;
	justify-content: center;
	gap: 20px;
	padding: 10px;
	background: var(--ap-primary);
}

.ap-footer__col {
	flex: 0 1 500px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 20px;
	padding: 10px;
	min-width: 0;
}

.ap-footer__title {
	text-align: center;
	font-family: var(--ap-font-display);
	font-size: 26px;
	font-weight: 400;
	line-height: 1.2;
	color: var(--ap-white);
	text-transform: none;
}

.ap-footer__text {
	font-family: var(--ap-font-text);
	font-size: 18px;
	font-weight: 400;
	line-height: 1;
	color: var(--ap-white);
	text-decoration: none;
	text-align: left;
}

.ap-footer__text:hover,
.ap-footer__text:focus-visible {
	color: var(--ap-white);
	text-decoration: underline;
}

.ap-footer__email {
	padding-bottom: 2px;
	border-bottom: 1px solid var(--ap-white);
}

.ap-footer__email:hover {
	text-decoration: none;
}

.ap-social--footer a {
	color: var(--ap-white);
}

.ap-social--footer .ap-icon {
	height: 50px;
}

.ap-footer__bar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-evenly;
	gap: 10px 26px;
	padding: 10px;
	background: var(--ap-bar-bg);
}

.ap-footer__credit,
.ap-footer__menu a {
	font-family: var(--ap-font-text);
	font-size: 16px;
	line-height: 1.2;
	color: var(--ap-primary);
}

.ap-footer__credit {
	font-weight: 600;
}

.ap-footer__menu {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px 26px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.ap-footer__menu a {
	font-weight: 300;
	text-decoration: none;
}

.ap-footer__menu a:hover,
.ap-footer__menu a:focus-visible,
.ap-footer__menu .current-menu-item > a {
	text-decoration: underline;
}

@media (max-width: 1024px) {
	.ap-footer__main {
		flex-direction: column;
		align-items: center;
	}
	.ap-footer__col {
		flex-basis: auto;
		width: 100%;
		max-width: 500px;
	}
}

@media (max-width: 767px) {
	.ap-footer__text {
		text-align: center;
		line-height: 1.2;
	}
	.ap-footer__bar {
		flex-direction: column;
		text-align: center;
	}
	.ap-footer__menu {
		flex-direction: column;
		align-items: center;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ap-menu > li > a::after,
	.ap-menu .sub-menu,
	.ap-subtoggle .ap-icon {
		transition: none;
	}
}

/* GTranslate: το πλωτό κουμπί γλώσσας δεν χρειάζεται μέσα στα panels (κάλυπτε το μενού και κουμπιά στο κινητό). */
body.gp-on .gtranslate_wrapper,
body.apollon-panel .gtranslate_wrapper {
	display: none !important;
}
