/*
 * 10-header.css - header (zona header-footer).
 * Desktop: valorile calculate pe live (layout Divi 2039 + Supreme Mega Menu), la 1920/1536/1440/1366.
 * Mobil (< 981px): design propriu (.er-mhdr, .er-mpanel).
 * Sectiuni: 1. bara de sus  2. bara meniului  3. dropdown / mega-panou  4. breadcrumbs  5. mobil
 */

.er-header { position: relative; z-index: 100; background: #fff; }

/* =============================================================================================
 * 1. Bara de sus (Divi: et_pb_section_0_tb_header): 89.6px la toate latimile desktop
 * =========================================================================================== */
.er-hdr-top {
	background: #fff;
	border-bottom: 1px solid var(--er-border);
}
.er-hdr-top__row {
	display: flex;
	align-items: center;
	padding: 5px 0;
}
/* Coloanele Divi (73% / 14% / 15% + 3% spatiu) depasesc 100%: flexbox le micsoreaza proportional, ca pe live. */
.er-hdr-top__col { position: relative; }
.er-hdr-top__col--main { width: 73%; margin-right: 3%; }
.er-hdr-top__col--social { width: 14%; margin-right: 3%; }
.er-hdr-top__col--account { width: 15%; height: 78.6px; }

.er-hdr-logo {
	width: 11%;
	margin-top: -7px;
	padding-bottom: 10px;
}
.er-hdr-logo a, .er-hdr-logo img { display: block; }
.er-hdr-logo img { width: 100%; height: auto; }

.er-hdr-search {
	width: 70%;
	margin: -50px 0 0 auto;
	border: 1px solid rgba(0, 0, 0, .1);
	border-radius: 20px;
	overflow: hidden;
	background: #fff;
}
.er-search__form { position: relative; display: flex; margin: 0; }
.er-search .er-search__input {
	display: block;
	width: 100%;
	height: 41px;
	margin: 0;
	padding: 10.01px;
	border: 0;
	border-radius: 20px;
	background: transparent;
	font-family: var(--er-font-pop);
	font-size: 14px;
	font-weight: 300;
	line-height: normal;
	color: var(--er-text);
}
.er-search .er-search__input::placeholder { color: rgba(0, 0, 0, .18); opacity: 1; }
.er-search .er-search__input:focus { color: var(--er-text); outline: none; }
.er-hdr-search:focus-within { border-color: rgba(0, 0, 0, .25); }
/* Butonul de trimitere e ascuns ca pe live (Enter trimite formularul); vizibil doar pe mobil. */
.er-hdr-search .er-search__submit { display: none; }

/* Retele sociale (Divi social media follow, 44px cu bordura #dedede) */
.er-social { display: flex; justify-content: flex-end; line-height: 26px; }
.er-social__item { display: block; }
.er-social__item + .er-social__item { margin-left: 8px; }
.er-social__link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 5px;
	border: 1px solid #dedede;
	border-radius: 50%;
	color: #000;
	font-size: 16px;
	transition: background-color .3s, border-color .3s, color .3s;
}
.er-social__link--facebook { background: #fff; }
.er-social__link:hover { background: #000; border-color: #000; color: #fff; } /* inainte auriu */

/* "Contul meu" / "Cosul meu" (blurb-uri Divi cu icoana la stanga) */
.er-hdr-blurb {
	position: absolute;
	left: 0;
	display: flex;
	height: 26px;
	color: var(--er-black);
}
.er-hdr-blurb--account { top: 15px; }
.er-hdr-blurb--cart { top: 47px; }
.er-hdr-blurb__icon {
	position: relative;
	display: block;
	width: 32px;
	flex: none;
	font-size: 26px;
	line-height: 26px;
	color: #000;
}
.er-hdr-blurb__icon > .er-icon { position: absolute; left: 10px; top: -4px; vertical-align: top; }
.er-hdr-blurb--cart .er-hdr-blurb__icon > .er-icon { top: -6px; }
.er-hdr-blurb__text {
	display: block;
	padding-left: 15px;
	font-size: 16px;
	font-weight: 300;
	line-height: 16px;
	letter-spacing: -1px;
	color: #000;
	white-space: nowrap;
}

/* Bulina cu numarul de produse din cos (nu exista pe live; apare doar cand cosul nu e gol) */
.er-cart-count {
	position: absolute;
	min-width: 17px;
	height: 17px;
	padding: 0 4px;
	border-radius: 9px;
	background: #000;
	color: #fff;
	font-family: var(--er-font-mont);
	font-size: 10px;
	font-weight: 600;
	line-height: 17px;
	letter-spacing: 0;
	text-align: center;
}
.er-cart-count[hidden] { display: none; }
.er-cart-count--desktop { left: 30px; top: -14px; }

/* =============================================================================================
 * 2. Bara meniului (Divi: et_pb_section_1_tb_header + Supreme Mega Menu): 126px
 * =========================================================================================== */
.er-hdr-nav {
	position: relative;
	z-index: 99;
	background: #fff;
}
.er-hdr-nav.is-stuck {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
}
.admin-bar .er-hdr-nav.is-stuck { top: 32px; }
.er-hdr-nav__row { padding: 27px 0; }
.er-nav { position: relative; display: flex; justify-content: center; }
.er-nav__list {
	display: flex;
	line-height: 30px;
	font-size: 14px;
}
.er-nav__item {
	position: relative;
	display: block;
	margin-right: 34px;
}
.er-nav__item:last-child { margin-right: 0; }
.er-nav__item--mega { position: static; }
.er-nav__link {
	display: flex;
	margin: 7px 16px 5px;
	padding: 0 4px 0 1px;
	border: 0 solid #fc1e25;
	color: #000;
}
/* Hover ca pe live: linie rosie de 1px doar sub elementele fara submeniu. */
.er-nav__item:not(.er-nav__item--has-sub) > .er-nav__link:hover { border-bottom-width: 1px; }
.er-nav__icon-slot { position: relative; display: flex; align-items: center; }
.er-nav__item--has-sub .er-nav__link > .er-nav__icon-slot:last-child { width: 16px; font-size: 16px; }
.er-nav__text-wrap { display: flex; align-items: center; }
.er-nav__text {
	display: block;
	margin-right: 7px;
	font-family: var(--er-font-lato);
	font-size: 20px;
	font-weight: 300;
	letter-spacing: 1px;
	text-transform: uppercase;
	text-align: left;
	color: #000;
}
.er-nav__item.is-current > .er-nav__link .er-nav__text { color: #000; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 6px; } /* inainte auriu */
.er-nav__badge {
	display: block;
	margin: -23px 0 2px;
	padding: 0 4px;
	background: #000;
	color: #fff;
	font-family: var(--er-font-mont);
	font-size: 14px;
	font-weight: 600;
	line-height: 30px;
}
.er-nav__chev { color: #000; }
.er-nav__chev--up { display: none; }
.er-nav__item--has-sub:hover .er-nav__chev--down,
.er-nav__item--has-sub.is-open .er-nav__chev--down { display: none; }
.er-nav__item--has-sub:hover .er-nav__chev--up,
.er-nav__item--has-sub.is-open .er-nav__chev--up { display: inline-block; }

/*
 * Sub 1920px meniul cu valorile de pe live nu incape in rand (are nevoie de ~1728px = 90% din 1920):
 * pe live iese din ecran (scroll orizontal pana la 1756px la 1366, ultimul element taiat intre 1500 si 1900).
 * Aici spatiile si fontul scad proportional cu ecranul, ca toate elementele sa incapa in rand.
 * Aspectul ramane acelasi (aceeasi inaltime: bara 126px, header 215.6px). La 1920 valorile sunt cele de pe live.
 */
@media (min-width: 981px) and (max-width: 1919px) {
	.er-nav__item { margin-right: 1vw; }
	.er-nav__item:last-child { margin-right: 0; }
	.er-nav__link { margin-left: .5vw; margin-right: .5vw; }
	.er-nav__text { margin-right: 5px; font-size: clamp(13px, 1.33vw, 20px); letter-spacing: .05em; }
	.er-nav__badge { padding: 0 3px; font-size: clamp(11px, .95vw, 14px); }
}
/* Siguranta: nimic din bara meniului nu produce scroll orizontal. */
@media (min-width: 981px) {
	.er-hdr-nav-holder { overflow-x: clip; }
}

/* =============================================================================================
 * 3. Dropdown "Colectii" si mega-panoul "Bijuterii" (apar la hover, fadeIn 300ms ca pe live)
 * =========================================================================================== */
.er-dropdown, .er-mega {
	position: absolute;
	z-index: 1;
	opacity: 0;
	visibility: hidden;
	transition: opacity .3s ease-in-out, visibility .3s ease-in-out;
	line-height: 26px;
}
.er-dropdown { width: 350px; }
.er-mega { left: 0; width: 100%; }
.er-nav__item--has-sub:hover > .er-dropdown,
.er-nav__item--has-sub:hover > .er-mega,
.er-nav__item--has-sub.is-open > .er-dropdown,
.er-nav__item--has-sub.is-open > .er-mega {
	opacity: 1;
	visibility: visible;
	z-index: 1000;
}
.er-dropdown__list, .er-mega__row {
	padding: 10px;
	background: #fff;
	box-shadow: 0 2px 18px 0 rgba(0, 0, 0, .3);
}
.er-dropdown__list > li { display: list-item; padding: 5px 10px; }
.er-dropdown__link {
	display: flex;
	font-family: var(--er-font-lato);
	font-size: 20px;
	font-weight: 300;
	line-height: 26px;
	letter-spacing: 2px;
	color: #000;
}

.er-mega__row { display: flex; align-items: flex-start; }
.er-mega__col {
	width: 15.6%;
	margin-right: 5.5%;
	padding-left: 10px;
	flex: none;
}
.er-mega__col:last-child { margin-right: 0; }
.er-mega__title {
	margin: 20px 0 10px;
	padding-bottom: 10px;
	font-family: var(--er-font-pop);
	font-size: 16px;
	font-weight: 300;
	line-height: 16px;
	letter-spacing: -1px;
	color: #454545;
}
.er-mega__list > li { display: flex; margin-left: 2px; }
.er-mega__list > li + li { margin-top: 8px; }
.er-mega__link {
	display: flex;
	font-family: var(--er-font-pop);
	font-size: 16px;
	font-weight: 300;
	line-height: 1.2;
	letter-spacing: -1px;
	color: #333;
	transition: color .3s;
}
.er-mega__link:hover { color: #555; }
/* CSS custom live: ultimul link din fiecare coloana ("Descopera toate produsele") e subliniat, 14px. */
.er-mega__list > li:last-child .er-mega__link { font-size: 14px; text-decoration: underline; color: #333; }

/* =============================================================================================
 * 4. Breadcrumbs (ermara_breadcrumbs(), modulul Divi "Woo Breadcrumbs" de pe live)
 * =========================================================================================== */
.er-breadcrumbs { background-color: rgba(12, 113, 195, .03); }
.er-breadcrumbs__row { display: flow-root; }
.er-breadcrumbs .woocommerce-breadcrumb {
	margin: 0 0 14px;
	font-size: 14px;
	line-height: 23.8px;
	color: #767676;
}
.er-breadcrumbs .woocommerce-breadcrumb a { color: #767676; }
.er-breadcrumbs .woocommerce-breadcrumb a:hover { color: #333; }
.er-breadcrumbs--product { padding-top: 10px; }
.er-breadcrumbs--product .er-breadcrumbs__row { padding: 13px 0; }
.er-breadcrumbs--product .woocommerce-breadcrumb { font-family: var(--er-font-pop); font-weight: 300; }
.er-breadcrumbs--archive .er-breadcrumbs__row { padding: 10px 0 0; }
.er-breadcrumbs--archive .woocommerce-breadcrumb { font-family: var(--er-font); font-weight: 500; }

/* =============================================================================================
 * 5. Mobil (< 981px): header propriu
 * =========================================================================================== */
@media (max-width: 980px) {
	.er-header {
		position: sticky;
		top: 0;
		z-index: 1000;
		box-shadow: 0 1px 0 var(--er-border);
	}
	.er-mhdr__bar {
		display: grid;
		grid-template-columns: 1fr auto 1fr;
		align-items: center;
		height: 60px;
		padding: 0 6px;
	}
	.er-mhdr__btn {
		position: relative;
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 44px;
		height: 44px;
		padding: 0;
		border: 0;
		background: none;
		color: #000;
		font-size: 22px;
		cursor: pointer;
		-webkit-tap-highlight-color: transparent;
	}
	.er-mhdr__left { display: flex; justify-self: start; align-items: center; }
	.er-mhdr__burger { font-size: 30px; }
	.er-mhdr__logo { display: block; justify-self: center; }
	.er-mhdr__logo img { display: block; width: auto; height: 42px; }
	.er-mhdr__icons { display: flex; justify-self: end; align-items: center; }
	.er-cart-count--mobile { top: 4px; right: 2px; }
	/* Favorite (inimioara contur, aceeasi grosime ca icoanele de cont / cos) */
	.er-mhdr__fav .er-fav__icon { display: block; width: 22px; height: 22px; }
	.er-mhdr__fav .er-fav__icon path { stroke-width: 1.4; }
	.er-mhdr__fav .er-fav-count { position: absolute; top: 4px; right: 2px; }
	/* Telefoane inguste: 5 icoane + logo incap pe 320-380px */
	@media (max-width: 380px) {
		.er-mhdr__bar { padding: 0 2px; }
		.er-mhdr__btn { width: 38px; }
		.er-mhdr__logo img { height: 38px; }
	}
	.er-mhdr__search {
		padding: 0 var(--er-gutter-mobile) 12px;
		background: #fff;
	}
	.er-mhdr__search[hidden] { display: none; }
	.er-mhdr__search .er-search__form {
		border: 1px solid rgba(0, 0, 0, .15);
		border-radius: 22px;
		overflow: hidden;
	}
	.er-mhdr__search .er-search__form:focus-within { border-color: var(--er-gold); }
	.er-mhdr__search .er-search__input { height: 44px; padding: 0 16px; font-size: 16px; }
	.er-mhdr__search .er-search__submit {
		display: inline-flex;
		align-items: center;
		justify-content: center;
		width: 48px;
		flex: none;
		border: 0;
		background: none;
		color: #000;
		font-size: 20px;
		cursor: pointer;
	}

	/* Panoul meniului */
	.er-mpanel { position: fixed; inset: 0; z-index: 100000; }
	.er-mpanel[hidden] { display: none; }
	.er-mpanel__overlay { position: absolute; inset: 0; background: rgba(0, 0, 0, .45); }
	.er-mpanel__box {
		position: absolute;
		top: 0;
		bottom: 0;
		left: 0;
		display: flex;
		flex-direction: column;
		width: min(88vw, 380px);
		background: #fff;
		box-shadow: 4px 0 24px rgba(0, 0, 0, .18);
		animation: er-mpanel-in .22s ease-out;
	}
	@keyframes er-mpanel-in { from { transform: translateX(-100%); } to { transform: none; } }
	.er-mpanel__head {
		display: flex;
		align-items: center;
		justify-content: space-between;
		height: 60px;
		padding: 0 6px 0 var(--er-gutter-mobile);
		border-bottom: 1px solid var(--er-border);
		flex: none;
	}
	.er-mpanel__logo img { display: block; width: auto; height: 38px; }
	.er-mpanel__close { font-size: 30px; }
	.er-mmenu { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
	.er-mmenu__item { border-bottom: 1px solid #f0f0f0; }
	.er-mmenu__row { display: flex; align-items: stretch; }
	.er-mmenu__link {
		display: flex;
		align-items: center;
		flex: 1;
		min-height: 50px;
		padding: 8px var(--er-gutter-mobile);
		font-family: var(--er-font-lato);
		font-size: 16px;
		font-weight: 400;
		line-height: 1.3;
		letter-spacing: 1px;
		text-transform: uppercase;
		color: #000;
	}
	.er-mmenu__item.is-current > .er-mmenu__row > .er-mmenu__link { color: #000; text-decoration: underline; text-underline-offset: 5px; } /* inainte auriu */
	.er-mmenu__toggle {
		display: flex;
		align-items: center;
		justify-content: center;
		width: 52px;
		flex: none;
		border: 0;
		border-left: 1px solid #f0f0f0;
		background: none;
		color: #000;
		font-size: 22px;
		cursor: pointer;
	}
	.er-mmenu__toggle .er-icon { transition: transform .2s; }
	.er-mmenu__toggle[aria-expanded="true"] .er-icon { transform: rotate(180deg); }
	.er-mmenu__sub { background: #fafafa; }
	.er-mmenu__sub[hidden] { display: none; }
	.er-mmenu__sub .er-mmenu__item { border-bottom: 0; border-top: 1px solid #f0f0f0; }
	.er-mmenu__sub .er-mmenu__link {
		min-height: 44px;
		padding-left: 28px;
		font-family: var(--er-font);
		font-size: 15px;
		text-transform: none;
		letter-spacing: 0;
		color: #333;
	}
	.er-mmenu__sub .er-mmenu__sub .er-mmenu__link { padding-left: 42px; font-size: 14px; color: #555; }
	/* Grup fara link (titlurile coloanelor din mega-meniul "Bijuterii"): tot randul e butonul de pliere */
	.er-mmenu__toggle--full {
		flex: 1;
		justify-content: space-between;
		gap: 12px;
		min-height: 44px;
		padding: 8px 18px 8px 28px;
		border-left: 0;
		font-family: var(--er-font);
		font-size: 15px;
		font-weight: 600;
		letter-spacing: .5px;
		text-align: left;
		text-transform: uppercase;
		color: #333;
	}
	.er-mmenu__toggle--full .er-icon { flex: none; font-size: 20px; }
	/* NEW / TOP: negru cu alb si ridicate, ca pe desktop (cerinta 2026-11-05; inainte aurii, pe linie). */
	.er-mmenu__badge {
		display: inline-block;
		position: relative;
		top: -9px;
		margin-left: 4px;
		padding: 1px 5px;
		border-radius: 0;
		background: #000;
		color: #fff;
		font-family: var(--er-font-mont);
		font-size: 10px;
		font-weight: 600;
		line-height: 1.4;
		letter-spacing: .3px;
		vertical-align: baseline;
	}
	.er-mpanel__foot {
		flex: none;
		padding: 12px var(--er-gutter-mobile) calc(12px + env(safe-area-inset-bottom));
		border-top: 1px solid var(--er-border);
		background: var(--er-gray-bg);
	}
	/* legaturile din bara de sus a desktopului, pe doua coloane (lasa loc meniului pe ecrane scunde) */
	.er-mpanel__foot { display: grid; grid-template-columns: repeat(2, max-content); justify-content: space-between; column-gap: 16px; }
	.er-mpanel__contact {
		display: flex;
		align-items: center;
		gap: 10px;
		min-width: 0;
		min-height: 44px;
		font-size: 15px;
		color: #000;
		white-space: nowrap;
	}
	.er-mpanel__contact .er-icon { width: 20px; font-size: 18px; color: #555; }
	body.er-noscroll { overflow: hidden; }

	/* Breadcrumbs pe mobil */
	.er-breadcrumbs--product { padding-top: 0; }
	.er-breadcrumbs--product .er-breadcrumbs__row, .er-breadcrumbs--archive .er-breadcrumbs__row { padding: 10px 0; }
	.er-breadcrumbs .woocommerce-breadcrumb { margin: 0; font-size: 13px; line-height: 1.6; }
	/* tinta de atingere ~40px fara sa creasca randul */
	.er-breadcrumbs .woocommerce-breadcrumb a { display: inline-block; padding: 10px 6px; margin: -10px -6px; }
}
@media (max-width: 782px) {
	.admin-bar .er-header { top: 0; }
}
@media (min-width: 601px) and (max-width: 782px) {
	.admin-bar .er-header { top: 46px; }
}
@media (min-width: 783px) and (max-width: 980px) {
	.admin-bar .er-header { top: 32px; }
}
@media (min-width: 981px) {
	.er-mpanel { display: none !important; }
}
