/* ══════════════════════════════════════════════════════════════
   Νέο header — top bar + κύρια γραμμή  (inc/header/header.php)
   Από 1024px και πάνω: όλα σε μία γραμμή. Κάτω από 1024px: έκδοση κινητού.
   Φορτώνει σε όλες τις σελίδες, με δικό του URL (cache-busting), εκτός style.css.
   ══════════════════════════════════════════════════════════════ */

:root {
	--vm-navy:        #0E2338; /* top bar, κείμενο και εικονίδια header */
	--vm-blue:        #1559A0; /* badge καλαθιού, focus */
	--vm-line:        #DCE3EA; /* διαχωριστικά */
	--vm-line-strong: #C5CED8; /* περίγραμμα πεδίων/κουμπιών */
	--vm-surface:     #F3F6F9; /* hover εικονιδίων */
	--vm-muted:       #4A5B6C; /* εικονίδιο αναζήτησης */
	--vm-topbar-sep:  #2E4560; /* διαχωριστικό μέσα στη σκούρα μπάρα */
}

#masthead.vm-hdr {
	padding: 0;
	margin: 0;
	border: 0;
	background: #ffffff;
}

/* ── Top bar ─────────────────────────────────────────────────── */

.vm-hdr .vm-topbar {
	background: var(--vm-navy);
	color: #ffffff;
}

.vm-hdr .vm-topbar__inner {
	box-sizing: content-box;
	max-width: 1260px;
	margin: 0 auto;
	padding: 0 20px;
	min-height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.vm-hdr .vm-topbar__msgs {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	justify-content: center;
	gap: 0 32px;
	font-size: 15px;
	line-height: 1.3;
	white-space: nowrap;
}

.vm-hdr .vm-topbar__msg {
	margin: 0;
	padding: 10px 0;
}

.vm-hdr .vm-topbar__msg--main {
	font-weight: 700;
}

.vm-hdr .vm-topbar__short,
.vm-hdr .vm-topbar__b2b {
	display: none;
}

/* ── Κύρια γραμμή ────────────────────────────────────────────── */

.vm-hdr .vm-hdr__bar {
	background: #ffffff;
	border-bottom: 1px solid var(--vm-line);
}

.vm-hdr .vm-hdr__inner {
	box-sizing: content-box;
	max-width: 1260px;
	margin: 0 auto;
	padding: 14px 20px;
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	gap: 20px;
}

.vm-hdr .vm-hdr__svg {
	display: block;
	width: 24px;
	height: 24px;
	flex: 0 0 auto;
}

/* Μενού (ανοίγει το TapTap) */
.vm-hdr .vm-hdr__menu {
	flex: 0 0 48px;
	width: 48px;
	height: 48px;
	margin: 0;
	padding: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--vm-line-strong);
	border-radius: 10px;
	background: #ffffff;
	color: var(--vm-navy);
	cursor: pointer;
	box-shadow: none;
}

.vm-hdr .vm-hdr__menu:hover {
	background: var(--vm-surface);
	color: var(--vm-navy);
}

/* Λογότυπο */
.vm-hdr .vm-hdr__logo {
	flex: 0 0 auto;
	line-height: 0;
}

.vm-hdr .vm-hdr__logo .custom-logo-link {
	display: block;
}

.vm-hdr .vm-hdr__logo img.custom-logo {
	display: block;
	height: 44px;
	width: auto;
	max-width: none;
	max-height: none;
	margin: 0;
}

/* Αναζήτηση (FiboSearch) */
.vm-hdr .vm-hdr__search {
	flex: 1 1 auto;
	min-width: 180px;
}

.vm-hdr .vm-hdr__search .dgwt-wcas-search-wrapp {
	width: 100%;
	max-width: none;
	min-width: 0;
	margin: 0;
}

.vm-hdr .vm-hdr__search .dgwt-wcas-sf-wrapp {
	padding: 0;
	background: transparent;
}

.vm-hdr .vm-hdr__search input[type="search"].dgwt-wcas-search-input {
	height: 48px;
	padding: 0 14px 0 44px;
	border: 1px solid var(--vm-line-strong);
	border-radius: 10px;
	background: #ffffff;
	box-shadow: none;
	color: var(--vm-navy);
	font-size: 16px;
	line-height: 46px;
}

.vm-hdr .vm-hdr__search input[type="search"].dgwt-wcas-search-input:focus {
	border-color: var(--vm-blue);
	box-shadow: 0 0 0 3px rgba(21, 89, 160, 0.15);
	outline: none;
}

.vm-hdr .vm-hdr__search .dgwt-wcas-sf-wrapp .dgwt-wcas-ico-magnifier {
	left: 14px;
	max-width: 20px;
	max-height: 20px;
	fill: var(--vm-muted);
	opacity: 1;
}

/* Εικονίδια δεξιά: τηλέφωνο · Χονδρική · λογαριασμός · καλάθι */
.vm-hdr .vm-hdr__tools {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	gap: 4px;
	padding-left: 16px;
	border-left: 1px solid var(--vm-line);
}

.vm-hdr .vm-hdr__item {
	position: relative;
	flex: 0 0 84px;
	box-sizing: border-box;
	width: 84px;
	height: 56px;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 4px;
	border-radius: 10px;
	color: var(--vm-navy);
	text-decoration: none;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.1;
	white-space: nowrap;
}

.vm-hdr .vm-hdr__item:hover,
.vm-hdr .vm-hdr__item:focus {
	background: var(--vm-surface);
	color: var(--vm-navy);
}

.vm-hdr .vm-hdr__menu:focus-visible,
.vm-hdr .vm-hdr__item:focus-visible,
.vm-hdr .vm-topbar__b2b:focus-visible {
	outline: 2px solid var(--vm-blue);
	outline-offset: 2px;
}

/* Καλάθι: το εικονίδιο είναι δικό μας, από το Side Cart κρατάμε μόνο τον αριθμό */
.vm-hdr .vm-hdr__cart-icon {
	position: relative;
	display: block;
}

.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-cont {
	position: absolute;
	top: -7px;
	right: -11px;
	pointer-events: none; /* το κλικ το παίρνει το <a>, που είναι κι αυτό trigger */
}

.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-cont:has(.vm-hdr-cart-empty) {
	display: none;
}

.vm-hdr .vm-hdr__cart-icon .xoo-wsc-cart-trigger,
.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-bkcont {
	display: block;
	position: static;
	margin: 0;
	padding: 0;
}

.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-subt,
.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-bki {
	display: none !important;
}

.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-count {
	position: static;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 18px;
	height: 18px;
	padding: 0 5px;
	border-radius: 999px;
	background: var(--vm-blue) !important;
	color: #ffffff !important;
	font-size: 11px;
	font-weight: 700;
	line-height: 1;
	transform: none;
}

/* Οι B2B πελάτες δεν βλέπουν «Χονδρική» (όπως και στο παλιό header) */
.b2bking_b2b_user .vm-hdr .vm-hdr-b2b {
	display: none !important;
}

/* TapTap: το δικό του κουμπί κρύβεται· φαίνεται μόνο το Χ όσο το μενού είναι ανοιχτό */
body.vm-hdr-on .taptap-menu-button-wrapper:not(.taptap-menu-active) {
	display: none !important;
}

body.vm-hdr-on .taptap-menu-button-wrapper.taptap-menu-active {
	position: fixed !important;
	top: 20px !important;
	left: 20px !important;
	right: auto !important;
	width: auto !important;
}

body.vm-hdr-on.admin-bar .taptap-menu-button-wrapper.taptap-menu-active {
	top: 52px !important;
}

/* ── Κινητό / tablet (κάτω από 1024px) ───────────────────────── */

@media (max-width: 1023px) {

	/* Κοινή «ευθεία» 18px αριστερά/δεξιά για μπάρα, header και περιεχόμενο σελίδας */
	.vm-hdr .vm-topbar__inner {
		justify-content: space-between;
		min-height: 34px;
		padding: 0 0 0 18px;
	}

	.vm-hdr .vm-topbar__msgs {
		justify-content: flex-start;
		min-width: 0;
		font-size: 13px;
	}

	.vm-hdr .vm-topbar__msg {
		min-width: 0;
		padding: 8px 0;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.vm-hdr .vm-topbar__msg--extra,
	.vm-hdr .vm-topbar__long {
		display: none;
	}

	.vm-hdr .vm-topbar__short {
		display: inline;
	}

	.vm-hdr .vm-topbar__b2b {
		flex: 0 0 auto;
		display: flex;
		align-items: center;
		gap: 6px;
		height: 34px;
		margin-left: auto;
		padding: 0 18px 0 14px;
		border-left: 1px solid var(--vm-topbar-sep);
		color: #ffffff;
		text-decoration: none;
		font-size: 13px;
		font-weight: 700;
		white-space: nowrap;
	}

	.vm-hdr .vm-topbar__b2b:hover {
		color: #ffffff;
		background: rgba(255, 255, 255, 0.08);
	}

	.vm-hdr .vm-topbar__b2b .vm-hdr__svg {
		width: 15px;
		height: 15px;
		stroke-width: 2;
	}

	/* Τα εικονίδια είναι κεντραρισμένα σε κουτιά, οπότε το padding είναι μικρότερο από 18px:
	   η γραμμή του μενού ξεκινά και το καλάθι τελειώνει ακριβώς στα 18px. */
	.vm-hdr .vm-hdr__inner {
		gap: 0;
		padding: 8px 10px 8px 6px;
	}

	.vm-hdr .vm-hdr__menu {
		flex-basis: 40px;
		width: 40px;
		height: 44px;
		border: 0;
		background: transparent;
	}

	.vm-hdr .vm-hdr__logo {
		margin-left: 4px;
		margin-right: auto;
	}

	.vm-hdr .vm-hdr__logo img.custom-logo {
		height: 38px;
	}

	.vm-hdr .vm-hdr__search {
		flex: 0 0 auto;
		min-width: 0;
	}

	/* το FiboSearch κλειδώνει το wrapper στα 20px και το εικονίδιο (44px) έπεφτε πάνω στον λογαριασμό */
	/* Αναζήτηση · λογαριασμός · καλάθι: κουτιά 32×44 χωρίς κενό → ίδια απόσταση ~16px ανάμεσα στα εικονίδια.
	   Το FiboSearch κλειδώνει το wrapper στα 20px, γι' αυτό το !important. */
	.vm-hdr .vm-hdr__search .dgwt-wcas-search-wrapp.dgwt-wcas-layout-icon {
		width: 32px !important;
		min-width: 32px;
	}

	.vm-hdr .vm-hdr__search .dgwt-wcas-search-icon {
		display: flex;
		align-items: center;
		justify-content: center;
		width: 32px;
		height: 44px;
		margin: 0;
	}

	/* Το γεμάτο μεγεθυντικό του FiboSearch αντικαθίσταται με περίγραμμα, ίδιο με τα υπόλοιπα εικονίδια */
	.vm-hdr .vm-hdr__search .dgwt-wcas-search-icon svg {
		display: none;
	}

	.vm-hdr .vm-hdr__search .dgwt-wcas-search-icon::before {
		content: "";
		display: block;
		position: relative;
		top: 1px; /* οπτική ευθυγράμμιση με λογαριασμό/καλάθι */
		width: 22px;
		height: 22px;
		background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230E2338' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.5-3.5'/%3E%3C/svg%3E") center / 22px 22px no-repeat;
	}

	.vm-hdr .vm-hdr__tools {
		gap: 0;
		padding-left: 0;
		border-left: 0;
	}

	.vm-hdr .vm-hdr__item--phone,
	.vm-hdr .vm-hdr__item--b2b,
	.vm-hdr .vm-hdr__label {
		display: none;
	}

	.vm-hdr .vm-hdr__item {
		flex-basis: 32px;
		width: 32px;
		height: 44px;
	}

	.vm-hdr .vm-hdr__cart-icon .xoo-wsc-sc-cont {
		top: -6px;
		right: -9px;
	}

	.vm-hdr .vm-hdr__svg {
		width: 22px;
		height: 22px;
	}

	body.vm-hdr-on .taptap-menu-button-wrapper.taptap-menu-active {
		top: 12px !important;
		left: 12px !important;
	}
}

/* Πολύ στενά κινητά (320px): να χωράνε μήνυμα και «Χονδρική» στη μπάρα */
@media (max-width: 374px) {

	.vm-hdr .vm-topbar__msgs,
	.vm-hdr .vm-topbar__b2b {
		font-size: 12px;
	}

	.vm-hdr .vm-topbar__b2b {
		padding: 0 18px 0 10px;
	}
}

@media (max-width: 359px) {

	.vm-hdr .vm-topbar__b2b .vm-hdr__svg {
		display: none;
	}
}

/* Μενού TapTap στο κινητό: μικρότερα μόνο τα κεντρικά (style.css τα έχει όλα 20px κάτω από 600px),
   για να χωράει το «ΕΞΟΠΛΙΣΜΟΣ ΑΙΣΘΗΤΙΚΗΣ – SPA – TATTOO» με το βελάκι. Οι υποκατηγορίες μένουν 15px. */
@media (max-width: 599px) {

	/* Το TapTap βάζει το βελάκι ΕΞΩ από το δεξί άκρο του li· με όριο πλάτους μένει στην οθόνη
	   και το μακρύ όνομα σπάει σε δύο ισόρροπες γραμμές. */
	.taptap-by-bonfire #menu-mega-menu > li {
		max-width: min(calc(100% - 40px), 220px);
		margin-left: auto;
		margin-right: auto;
	}

	.taptap-by-bonfire #menu-mega-menu > li > a {
		font-size: 17px !important; /* ο κανόνας του style.css έχει !important */
		text-wrap: balance;
	}
}

/* ══════════════════════════════════════════════════════════════
   Αναζήτηση: Webmate Smart Search (.wmss) μέσα στο header
   Χρώματα/μεγέθη μέσω των --wmss-* του plugin· ίδια εμφάνιση με την παλιά μπάρα.
   ══════════════════════════════════════════════════════════════ */

.vm-hdr .vm-hdr__search .wmss {
	--wmss-text: var(--vm-navy);
	--wmss-muted: var(--vm-muted);
	--wmss-border: var(--vm-line-strong);
	--wmss-line: var(--vm-line);
	--wmss-accent: var(--vm-blue);
	--wmss-hover: var(--vm-surface);
	--wmss-radius: 10px;
	--wmss-height: 48px;
	--wmss-font-size: 16px;
	--wmss-z: 1001;
}

.vm-hdr .vm-hdr__search .wmss__list {
	min-width: 420px; /* η στενή μπάρα στα 1024px δεν κόβει τα ονόματα */
}

@media (max-width: 1023px) {

	/* Εικονίδιο στο ίδιο κουτί 32×44 με λογαριασμό/καλάθι, 1px πιο κάτω (οπτική ευθυγράμμιση) */
	.vm-hdr .vm-hdr__search .wmss {
		width: auto;
	}

	.vm-hdr .vm-hdr__search .wmss__open {
		width: 32px;
		height: 44px;
		color: var(--vm-navy);
	}

	.vm-hdr .vm-hdr__search .wmss__open .wmss__svg {
		position: relative;
		top: 1px;
	}

	.vm-hdr .vm-hdr__search .wmss__list {
		min-width: 0;
	}
}
