/* ============================================================
   Iconic Riviera — Mobile & Performance overrides (v2.7)
   Slick, app-like polish on top of the desktop Imogen design.
   Loaded LAST so it wins the cascade.
   ============================================================ */

/* ============================================================
   POST BODY TEXT — justified everywhere (mobile AND desktop)
   Higher-specificity selectors so we beat the bundled CSS.
   ============================================================ */
body .eltdf-blog-single .eltdf-post-text-main p,
body .eltdf-blog-single .eltdf-post-text-main li,
body article.eltdf-post-content .eltdf-post-text-main p,
body article.eltdf-post-content .eltdf-post-text-main li {
	text-align: justify !important;
	text-justify: inter-word;
	-webkit-hyphens: auto;
	   -moz-hyphens: auto;
	        hyphens: auto;
}

/* Map-pin shortcode rendering */
.iconic-map-pin {
	display: inline-block;
	color: #055a8c;
	margin: 0 2px;
	text-decoration: none !important;
	transition: transform .15s ease, color .2s ease;
}
.iconic-map-pin:hover { color: #1167b1; transform: translateY(-2px); }
.iconic-map-pin i { font-size: 18px; vertical-align: middle; }

/* ============================================================
   Smart image rendering
   ============================================================ */
img { max-width: 100%; height: auto; }
img[loading="lazy"] { background: #f5f5f5; }

/* ---------- Hide floating side rails on tablets & smaller ---------- */
@media (max-width: 1024px) {
	.df-social-connect,
	.df-misc-section { display: none !important; }
}

/* ============================================================
   HERO + DESTINATION SECTIONS  (Start here / Monaco / etc.)
   ============================================================ */
@media (max-width: 1024px) {
	.video-section,
	.monaco-section {
		background-attachment: scroll !important;
		height: auto !important;
		min-height: 60vh !important;
		padding: 60px 0 !important;
		border-top-width: 6px !important;
		border-bottom-width: 6px !important;
	}
	.monaco-section-content {
		max-width: 88% !important;
		width: 88% !important;
		padding: 24px 18px 28px !important;
		margin: 0 auto !important;
	}
	.monaco-section-content h2 {
		font-size: 6.5em !important;
		line-height: 1 !important;
		margin: 0 0 10px !important;
	}
	.monaco-section-content p {
		font-size: 18px !important;
		line-height: 1.3 !important;
		margin: 0 0 18px !important;
	}
	/* Creative button — wraps cleanly, no overflow */
	a.creative-btn {
		display: inline-block !important;
		max-width: 92% !important;
		min-width: 0 !important;
		padding: 12px 20px !important;
		line-height: 1.1 !important;
		font-size: 28px !important;
		letter-spacing: 1px !important;
		white-space: normal !important;
		text-align: center !important;
		word-break: break-word !important;
		box-shadow: 3px 3px 0 0 rgba(0,0,0,.4) !important;
	}
	a.creative-btn span {
		display: inline !important;
		font-size: inherit !important;
		letter-spacing: inherit !important;
		line-height: inherit !important;
		white-space: normal !important;
	}
}
@media (max-width: 640px) {
	.video-section,
	.monaco-section {
		min-height: 55vh !important;
		padding: 50px 0 !important;
	}
	.monaco-section-content h2 { font-size: 5em !important; }
	.monaco-section-content p  { font-size: 16px !important; }
	a.creative-btn             { font-size: 22px !important; padding: 10px 16px !important; }
}
@media (max-width: 400px) {
	.video-section,
	.monaco-section          { min-height: 420px !important; padding: 40px 0 !important; }
	.monaco-section-content h2 { font-size: 4.2em !important; }
	a.creative-btn           { font-size: 20px !important; }
}

/* ============================================================
   MOBILE HEADER + SLIDE-IN MENU  (app-like)
   ============================================================ */
@media (min-width: 1025px) { .eltdf-mobile-header { display: none !important; } }

@media (max-width: 1024px) {
	body.iconic-mobile-menu-open { overflow: hidden; }

	/* Desktop header off, mobile header on */
	.eltdf-page-header,
	.eltdf-page-header .eltdf-menu-area { display: none !important; }

	.eltdf-mobile-header {
		display: block !important;
		position: sticky; top: 0; z-index: 9998;
		background: #fff;
		border-bottom: 1px solid rgba(0,0,0,.06);
		-webkit-backdrop-filter: saturate(180%) blur(10px);
		        backdrop-filter: saturate(180%) blur(10px);
	}
	.eltdf-mobile-header .eltdf-mobile-header-holder { padding: 0 !important; background: transparent !important; }
	.eltdf-mobile-header .eltdf-grid { max-width: 100% !important; padding: 0 16px !important; }
	.eltdf-mobile-header .eltdf-vertical-align-containers {
		display: flex !important; align-items: center; justify-content: space-between;
		min-height: 56px; position: relative;
	}
	.eltdf-mobile-header .eltdf-position-left,
	.eltdf-mobile-header .eltdf-position-center,
	.eltdf-mobile-header .eltdf-position-right {
		display: flex !important; align-items: center;
	}
	.eltdf-mobile-header .eltdf-position-center {
		position: absolute; left: 50%; transform: translateX(-50%);
	}
	.eltdf-mobile-logo-wrapper a { display: inline-flex; align-items: center; height: 56px; }
	.eltdf-mobile-logo-wrapper img { max-height: 32px !important; width: auto !important; height: auto !important; }

	/* Hamburger */
	.eltdf-mobile-menu-opener {
		display: inline-flex !important; align-items: center; justify-content: center;
		width: 44px; height: 44px;
		padding: 0; margin: 0;
		background: transparent !important; border: 0 !important;
		color: #0d0d0d !important; cursor: pointer;
		-webkit-tap-highlight-color: transparent;
	}
	.eltdf-mobile-menu-opener .eltdf-mobile-menu-icon { line-height: 1; }
	.eltdf-mobile-menu-opener i.fa { font-size: 22px; line-height: 1; }

	/* The slide-in panel itself */
	.eltdf-mobile-nav {
		display: block !important;
		position: fixed; top: 0; right: 0; height: 100vh; height: 100dvh;
		width: 85vw; max-width: 360px;
		background: #fff;
		box-shadow: -8px 0 28px rgba(0,0,0,.18);
		transform: translateX(100%);
		transition: transform .32s cubic-bezier(.2,.7,.2,1);
		z-index: 9999;
		padding: 80px 0 24px;
		overflow-y: auto;
		-webkit-overflow-scrolling: touch;
		border-top: 0 !important;
	}
	body.iconic-mobile-menu-open .eltdf-mobile-nav { transform: translateX(0); }

	/* Backdrop */
	.iconic-mobile-backdrop {
		position: fixed; inset: 0;
		background: rgba(11, 38, 59, .35);
		opacity: 0; visibility: hidden;
		transition: opacity .25s ease, visibility .25s ease;
		z-index: 9997;
	}
	body.iconic-mobile-menu-open .iconic-mobile-backdrop {
		opacity: 1; visibility: visible;
	}

	/* Close button (X) inside the panel */
	.iconic-mobile-close {
		position: absolute; top: 14px; right: 14px;
		width: 40px; height: 40px;
		display: flex; align-items: center; justify-content: center;
		background: transparent; border: 0;
		color: #0d0d0d; font-size: 22px; cursor: pointer;
		-webkit-tap-highlight-color: transparent;
	}

	.eltdf-mobile-nav .eltdf-grid { padding: 0 !important; max-width: 100% !important; }
	.eltdf-mobile-nav ul {
		list-style: none !important; padding: 0 !important; margin: 0 !important;
	}
	.eltdf-mobile-nav li {
		border: 0 !important; border-bottom: 1px solid rgba(0,0,0,.06) !important;
		margin: 0 !important; padding: 0 !important;
		text-decoration: none !important;
	}
	.eltdf-mobile-nav li:last-child { border-bottom: 0 !important; }
	.eltdf-mobile-nav li a {
		display: flex !important; align-items: center;
		padding: 16px 24px !important;
		color: #0d0d0d !important;
		font-family: 'Montserrat', sans-serif !important;
		font-size: 13px !important;
		font-weight: 500 !important;
		letter-spacing: 2px !important;
		text-transform: uppercase !important;
		text-decoration: none !important;
		border: 0 !important;
		-webkit-tap-highlight-color: rgba(5,90,140,.08);
		transition: color .2s ease, background .2s ease;
	}
	.eltdf-mobile-nav li a:hover,
	.eltdf-mobile-nav li a:active {
		color: #055a8c !important; background: rgba(5,90,140,.04) !important;
	}
	/* Kill any inherited rules that add lines, dashes, h6 styling */
	.eltdf-mobile-nav li a i,
	.eltdf-mobile-nav li a h6 {
		display: none !important;
	}
	.eltdf-mobile-nav li.menu-item-has-children > a::after {
		content: '›';
		margin-left: auto;
		font-size: 22px; font-weight: 300;
		color: rgba(0,0,0,.35);
	}
	.eltdf-mobile-nav .sub-menu { background: #f7f4ee; padding: 0 !important; }
	.eltdf-mobile-nav .sub-menu li a { padding-left: 40px !important; font-size: 12px !important; }

	/* Hide the floating language widget on mobile (it'll be inside the menu instead) */
	.iconic-header-language { display: none !important; }
}

/* ============================================================
   SINGLE POST  (justified, centered, readable on mobile)
   ============================================================ */
@media (max-width: 900px) {
	.innner-digger .eltdf-page-content-holder.eltdf-grid-col-12 {
		display: block !important;
		padding: 0 !important;
	}
	.eltdf-container { padding: 0 !important; }
	.eltdf-container-inner { padding: 24px 0 !important; }

	.side_left {
		max-width: calc(100% - 32px) !important;
		width: calc(100% - 32px) !important;
		flex: none !important;
		position: static !important;
		margin: 0 16px 24px !important;
		padding: 16px 18px !important;
		border-radius: 12px;
	}
	.side_right { display: none; }

	.eltdf-blog-single h1.entry-title.eltdf-post-title {
		font-size: 4.5em !important;
		padding: 0 16px !important;
		line-height: 1.05 !important;
		margin: 8px 0 18px !important;
	}
	.eltdf-blog-single,
	.eltdf-blog-single .eltdf-post-content,
	.eltdf-blog-single .eltdf-post-text-inner {
		padding: 0 !important;
	}
	.eltdf-blog-single .eltdf-post-text-main {
		padding: 0 18px !important;
		max-width: 680px;
		margin: 0 auto;
	}
	/* Justify body paragraphs for clean block alignment */
	.eltdf-blog-single .eltdf-post-text-main p {
		text-align: justify !important;
		text-justify: inter-word;
		hyphens: auto;
		-webkit-hyphens: auto;
		font-size: 17px !important;
		line-height: 1.65 !important;
		margin: 0 0 1.1em !important;
	}
	.eltdf-blog-single .eltdf-post-text-main h2,
	.eltdf-blog-single .eltdf-post-text-main h3,
	.eltdf-blog-single .eltdf-post-text-main h4 {
		text-align: center !important;
		margin: 1.2em 0 .5em !important;
		font-size: 3em !important;
	}
	.eltdf-blog-single .eltdf-post-text-main img,
	.eltdf-blog-single .eltdf-post-text-main figure {
		display: block; margin: 1em auto !important; max-width: 100% !important;
	}
	.eltdf-blog-single .eltdf-post-text-main .wp-block-image img {
		border-radius: 14px;
	}
}

/* ============================================================
   ARCHIVE GRID  →  responsive
   ============================================================ */
@media (max-width: 1024px) {
	.eltdf-blog-holder[style*="grid-template-columns"] {
		grid-template-columns: repeat(2, 1fr) !important;
		padding: 16px !important;
		gap: 20px !important;
	}
}
@media (max-width: 640px) {
	.eltdf-blog-holder[style*="grid-template-columns"] {
		grid-template-columns: 1fr !important;
		padding: 14px !important;
		gap: 24px !important;
	}
	.eltdf-blog-holder article { text-align: left !important; }
	.eltdf-blog-holder .eltdf-post-title { font-size: 24px !important; }
}

/* ============================================================
   FOOTER STACK
   ============================================================ */
@media (max-width: 900px) {
	.eltdf-footer-top-inner .eltdf-grid-row {
		display: block !important;
	}
	.eltdf-footer-top-inner .eltdf-column-content {
		width: 100% !important;
		max-width: 100% !important;
		flex: none !important;
		margin: 0 0 24px 0 !important;
		text-align: center;
		padding: 0 20px !important;
	}
}

/* ============================================================
   ACCESSIBILITY + PERF
   ============================================================ */
@media (max-width: 1024px) {
	a, button { -webkit-tap-highlight-color: rgba(5,90,140,.12); }
}
.video-section, .monaco-section { contain: layout paint; }
.iconic-preloader, .eltdf-smooth-transition-loader { will-change: opacity; }
