/* Fotodual Portada: shared look (fonts, base, header/menu, Instagram, footer).
   Loaded on the home template and, when enabled, on every page. */

/* Jost, self-hosted (SIL Open Font License, assets/fonts/jost/OFL.txt) */
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 300; font-display: swap; src: url('../fonts/jost/jost-latin-300-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/jost/jost-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/jost/jost-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/jost/jost-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Jost'; font-style: normal; font-weight: 800; font-display: swap; src: url('../fonts/jost/jost-latin-800-normal.woff2') format('woff2'); }

/* ---------- Base (override Divi defaults inside .fdh) ---------- */
body.fdh-noscroll { overflow: hidden; }

.fdh {
	--fdh-accent: #c8102e;
	--fdh-pad: clamp(20px, 6vw, 96px);
	font-family: 'Jost', 'Futura', Helvetica, Arial, sans-serif;
	color: #111111;
	font-size: 19px;
	font-weight: 400;
	line-height: 1.75;
	-webkit-font-smoothing: antialiased;
	background: #ffffff;
}
.fdh *, .fdh *::before, .fdh *::after { box-sizing: border-box; }
/* :where() keeps this reset weak, so the section rules always win over it */
.fdh :where(h1, h2, h3, p, ul, li, figure, blockquote) { margin: 0; padding: 0; }
.fdh h1, .fdh h2, .fdh h3 {
	font-family: inherit;
	color: #111111;
	font-weight: 800;
	line-height: 1.05;
	letter-spacing: 0.5px;
	text-transform: uppercase;
}
.fdh a { color: inherit; text-decoration: none; }
.fdh img { display: block; max-width: 100%; height: auto; }
.fdh a:focus-visible, .fdh button:focus-visible { outline: 2px solid var(--fdh-accent); outline-offset: 3px; }

.fdh-wrap { max-width: 1320px; margin: 0 auto; padding: 0 var(--fdh-pad); }

.fdh-btn {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	padding: 22px 30px;
	background: #111111;
	color: #ffffff !important;
	border: 2px solid #111111;
	font-weight: 600;
	font-size: 15px;
	letter-spacing: 4px;
	line-height: 1;
	text-transform: uppercase;
	transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.fdh-btn:hover { background: var(--fdh-accent); border-color: var(--fdh-accent); }
.fdh-btn--line { background: transparent; color: #111111 !important; }
.fdh-btn--line:hover { background: #111111; border-color: #111111; color: #ffffff !important; }

/* ---------- Header ---------- */
.fdh-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	padding: 40px var(--fdh-pad);
	color: #ffffff;
}
/* Over the home photos */
.fdh-header--overlay { position: absolute; top: 0; left: 0; right: 0; z-index: 5; background: transparent; }
/* White bar on the other pages */
.fdh-chrome { background: #ffffff; }
.fdh-header--solid {
	position: relative;
	z-index: 999;
	padding-top: 22px;
	padding-bottom: 22px;
	background: #ffffff;
	color: #111111;
	border-bottom: 1px solid #ece8e3;
}
.fdh-chrome--header {
	position: sticky;
	top: var(--wp-admin--admin-bar--height, 0px);
	z-index: 999;
}

.fdh-logo { display: block; color: inherit; line-height: 1; position: relative; z-index: 7; }
.fdh-logo img { max-height: 70px; width: auto; }
.fdh-header--solid .fdh-logo img { max-height: 56px; }
.fdh-logo__text { display: block; font-weight: 800; font-size: 22px; letter-spacing: 1px; }
.fdh-logo__text span { color: var(--fdh-accent); }
.fdh-logo__sub { display: block; margin-top: 6px; font-weight: 500; font-size: 10px; letter-spacing: 4px; text-transform: uppercase; }

.fdh-nav { display: flex; align-items: center; gap: clamp(18px, 2.6vw, 48px); }
.fdh-menu { display: flex; align-items: center; gap: clamp(18px, 2.6vw, 48px); list-style: none; }
.fdh-menu li { position: relative; list-style: none; }
.fdh .fdh-menu a {
	display: block;
	padding: 12px 0;
	color: inherit;
	font-weight: 600;
	font-size: 15px;
	letter-spacing: 4px;
	line-height: 1.2;
	text-transform: uppercase;
	transition: opacity 0.2s;
}
.fdh .fdh-menu a:hover { opacity: 0.6; }
.fdh-menu .current-menu-item > a, .fdh-menu .current-menu-ancestor > a { opacity: 0.6; }
.fdh-menu .wpml-ls-menu-item { display: none; } /* languages are shown as ES · PT · EN */
.fdh-menu .menu-item-has-children > a::after {
	content: '';
	display: inline-block;
	width: 6px;
	height: 6px;
	margin: 0 0 4px 10px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
}
.fdh-menu .sub-menu {
	position: absolute;
	top: 100%;
	left: -18px;
	min-width: 250px;
	padding: 10px 0;
	list-style: none;
	background: #ffffff;
	box-shadow: 0 10px 30px rgba(0,0,0,0.15);
	opacity: 0;
	visibility: hidden;
	transform: translateY(6px);
	transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
}
.fdh-menu li:hover > .sub-menu, .fdh-menu li:focus-within > .sub-menu { opacity: 1; visibility: visible; transform: none; }
.fdh .fdh-menu .sub-menu a { padding: 10px 18px; color: #111111; font-size: 13px; letter-spacing: 3px; }

.fdh-tools { display: flex; align-items: center; gap: 14px; }
.fdh-icon { display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center; color: inherit; }
.fdh-langs { display: flex; align-items: center; gap: 8px; color: inherit; font-weight: 600; font-size: 15px; letter-spacing: 3px; }
.fdh-langs a { opacity: 0.6; padding: 10px 2px; }
.fdh-langs a.is-current, .fdh-langs a:hover { opacity: 1; }

.fdh-burger {
	display: none;
	position: relative;
	z-index: 7;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	cursor: pointer;
	flex-direction: column;
	align-items: flex-end;
	justify-content: center;
	gap: 6px;
}
.fdh-burger span { display: block; width: 30px; height: 2px; background: currentColor; transition: transform 0.25s, width 0.25s; }
.fdh-burger span:first-child { width: 20px; }
.fdh-header.is-open .fdh-burger span:first-child { width: 30px; transform: translateY(4px) rotate(45deg); }
.fdh-header.is-open .fdh-burger span:last-child { transform: translateY(-4px) rotate(-45deg); }
.fdh-header.is-open { color: #ffffff; }
.fdh-header--solid.is-open .fdh-logo { visibility: hidden; }

/* ---------- Hide Divi's own header/footer when ours is used ---------- */
body.fdh-site { padding-top: 0 !important; }
body.fdh-site #page-container { padding-top: 0 !important; margin-top: 0 !important; }
body.fdh-site .et-l--header,
body.fdh-site #main-header,
body.fdh-site #top-header,
body.fdh-site .et-l--footer,
body.fdh-site #main-footer { display: none !important; }

/* ---------- Instagram (Smash Balloon): grey until hover/tap ---------- */
.fdh-insta #sb_instagram { padding-bottom: 0 !important; }
.fdh-insta #sb_instagram .sbi_photo_wrap { filter: grayscale(100%); transition: filter 0.4s ease; }
.fdh-insta #sb_instagram .sbi_item:hover .sbi_photo_wrap,
.fdh-insta #sb_instagram .sbi_item:focus-within .sbi_photo_wrap,
.fdh-insta #sb_instagram .sbi_item:active .sbi_photo_wrap { filter: none; }

/* ---------- Footer ---------- */
.fdh-footer {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	justify-content: space-between;
	align-items: center;
	padding: 48px var(--fdh-pad);
	color: #555555;
	font-size: 13px;
	letter-spacing: 2px;
	line-height: 1.5;
	text-transform: uppercase;
}
.fdh-social, .fdh-legal { display: flex; flex-wrap: wrap; gap: 18px; list-style: none; }
.fdh-legal li { list-style: none; }
.fdh-footer a:hover { color: #111111; }

/* ---------- Tablet / phone: full-screen menu ---------- */
@media (max-width: 1100px) {
	.fdh-burger { display: flex; }
	.fdh-header--overlay { padding-top: 28px; padding-bottom: 28px; }
	.fdh-header--solid { padding-top: 14px; padding-bottom: 14px; }
	.fdh-nav {
		position: fixed;
		inset: 0;
		z-index: 6;
		flex-direction: column;
		justify-content: center;
		gap: 32px;
		padding: 110px 24px 40px;
		overflow-y: auto;
		background: #111111;
		color: #ffffff;
		opacity: 0;
		visibility: hidden;
		transition: opacity 0.3s, visibility 0.3s;
	}
	.fdh-header.is-open .fdh-nav { opacity: 1; visibility: visible; }
	.fdh-menu { flex-direction: column; gap: 4px; text-align: center; }
	.fdh .fdh-menu a { font-size: 20px; }
	.fdh-menu .menu-item-has-children > a::after { display: none; }
	.fdh-menu .sub-menu { position: static; min-width: 0; padding: 0 0 8px; background: none; box-shadow: none; opacity: 1; visibility: visible; transform: none; }
	.fdh .fdh-menu .sub-menu a { padding: 6px 0; color: #ffffff; font-size: 15px; opacity: 0.75; }
}
@media (max-width: 800px) {
	.fdh-footer { justify-content: center; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
	.fdh *, .fdh *::before, .fdh *::after { transition: none !important; }
}
