/* ==========================================================================
   Mekansm Kit — Home 2026 (Simpler. Smarter. Better.)
   Konten tetap di widget Elementor; file ini hanya mengatur tampilan & efek.
   Warna & font mengikuti Global Colors / Global Fonts situs (variabel --e-global-*).
   ========================================================================== */

:root {
	--mk-ink: var(--e-global-color-primary, #1d1d1f);
	--mk-text: var(--e-global-color-text, #404040);
	--mk-muted: #6e6e73; /* 4.6:1 di #F5F5F7 — Border2 (#86868B) terlalu pucat untuk teks */
	--mk-accent: var(--e-global-color-accent, #ec0303);
	--mk-bg: var(--e-global-color-b1adf25, #f5f5f7);
	--mk-white: var(--e-global-color-secondary, #ffffff);
	--mk-line: var(--e-global-color-90b9e10, #e0e0e0);
	--mk-ease: cubic-bezier(0.22, 0.61, 0.36, 1);
	--mk-fast: 0.25s;
	--mk-slow: 0.7s;
	--mk-sbw: 0px; /* lebar scrollbar, diisi mk.js */
}

/* ---------------------------------------------------------------- utilities */

.mk-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.mk-eyebrow {
	margin: 0 0 12px;
	font-size: 14px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--mk-muted);
}

.mk-round-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: rgba(210, 210, 215, 0.64);
	color: var(--mk-ink);
	cursor: pointer;
	transition: background var(--mk-fast) var(--mk-ease), opacity var(--mk-fast), transform var(--mk-fast) var(--mk-ease);
}
.mk-round-btn:hover { background: rgba(210, 210, 215, 0.9); }
.mk-round-btn:active { transform: scale(0.94); }
.mk-round-btn:focus-visible,
.mk-pill-btn:focus-visible,
.mk-card__hit:focus-visible,
.mk-fact__toggle:focus-visible {
	outline: 2px solid var(--mk-accent);
	outline-offset: 3px;
}
.mk-round-btn[disabled] { opacity: 0.35; cursor: default; }

.mk-pill-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 10px 18px;
	border: 0;
	border-radius: 999px;
	background: rgba(232, 232, 237, 0.9);
	color: var(--mk-ink);
	font: inherit;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: background var(--mk-fast) var(--mk-ease), color var(--mk-fast);
}
.mk-pill-btn:hover { background: #dcdce1; color: var(--mk-ink); }
.mk-pill-btn--dark { background: var(--mk-ink); color: #fff; }
.mk-pill-btn--dark:hover { background: var(--mk-accent); color: #fff; }

/* Elementor buttons with these classes (set in Advanced → CSS Classes) */
.mk-btn-pill .elementor-button {
	border-radius: 999px;
	padding: 16px 30px;
	transition: transform var(--mk-fast) var(--mk-ease), background-color var(--mk-fast), color var(--mk-fast);
}
.mk-btn-pill .elementor-button:hover { transform: translateY(-1px); }
.mk-btn-pill .elementor-button-icon svg { width: 14px; height: 14px; }

.mk-link-arrow .elementor-button {
	padding: 16px 4px;
	background: transparent;
}
.mk-link-arrow .elementor-button:hover .elementor-button-text { text-decoration: underline; text-underline-offset: 4px; }

/* ---------------------------------------------------------------- 1. hero */

.mk-hero { isolation: isolate; }
/* overlay di atas video latar, konten di atas overlay */
.e-con.mk-hero::before { z-index: 1; }
.e-con.mk-hero > .e-con { position: relative; z-index: 2; }
.mk-hero__title .elementor-heading-title { text-wrap: balance; }
.mk-hero__lead { max-width: 620px; }

/* ---------------------------------------------------------------- 2. manifesto — kata menyala saat scroll */

.mk-words .elementor-heading-title { text-wrap: pretty; }
.mk-words .mk-w {
	opacity: 0.18;
	transition: opacity 0.35s linear;
}
.mk-words .mk-w.is-lit { opacity: 1; }
.elementor-editor-active .mk-words .mk-w { opacity: 1; }

/* ---------------------------------------------------------------- 3. facts — kartu +/× (Apple "Facts") */

.mk-scroller,
.e-con.mk-scroller {
	min-width: 0;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x mandatory;
	scroll-padding-inline: 0;
	scrollbar-width: none;
	-webkit-overflow-scrolling: touch;
}
.mk-scroller::-webkit-scrollbar { display: none; }
.mk-scroller > .e-con,
.mk-scroller > .elementor-element { scroll-snap-align: start; flex-shrink: 0; }

.mk-bleed-right,
.e-con.mk-bleed-right {
	min-width: 0;
	/* dari tepi kiri konten sampai tepi kanan layar */
	width: calc(50% + 50vw - var(--mk-sbw) / 2) !important;
	max-width: none !important;
	padding-right: max(16px, calc(50vw - 50% - var(--mk-sbw) / 2)) !important;
}

/* penuh selebar layar (kiri & kanan), mis. marquee lokasi */
.mk-bleed-both,
.e-con.mk-bleed-both {
	min-width: 0;
	width: calc(100vw - var(--mk-sbw)) !important;
	max-width: none !important;
	margin-left: calc(50% - 50vw + var(--mk-sbw) / 2) !important;
	margin-right: 0 !important;
}

.mk-scroller-nav {
	display: flex;
	justify-content: flex-end;
	gap: 14px;
	margin-top: 28px;
}

.mk-fact {
	position: relative;
	overflow: hidden;
	cursor: pointer;
	transition: transform var(--mk-slow) var(--mk-ease), box-shadow var(--mk-slow) var(--mk-ease);
}
.mk-fact:hover { transform: scale(1.012); box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12); }

/* lapisan putih untuk keadaan terbuka */
.mk-fact::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 2;
	background: var(--mk-white);
	opacity: 0;
	transition: opacity 0.45s var(--mk-ease);
	pointer-events: none;
}
.mk-fact > .e-con-inner > *,
.mk-fact > .elementor-element,
.mk-fact > .e-con { position: relative; z-index: 3; }

.mk-fact__more {
	position: absolute !important;
	inset: 0;
	z-index: 4 !important;
	opacity: 0;
	visibility: hidden;
	transform: translateY(12px);
	transition: opacity 0.45s var(--mk-ease), transform 0.45s var(--mk-ease), visibility 0s linear 0.45s;
}
.mk-fact__front { transition: opacity 0.3s var(--mk-ease); }

.mk-fact.is-open::after { opacity: 1; }
.mk-fact.is-open .mk-fact__front { opacity: 0; }
.mk-fact.is-open .mk-fact__more {
	opacity: 1;
	visibility: visible;
	transform: none;
	transition-delay: 0.1s, 0.1s, 0s;
}
.mk-fact.is-open:hover { transform: none; }

.mk-fact__toggle {
	position: absolute;
	right: 20px;
	bottom: 20px;
	z-index: 5;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: var(--mk-white);
	color: var(--mk-ink);
	cursor: pointer;
	transition: transform 0.45s var(--mk-ease), background var(--mk-fast), color var(--mk-fast);
}
.mk-fact__toggle svg { width: 18px; height: 18px; }
.mk-fact:hover .mk-fact__toggle { background: var(--mk-accent); color: #fff; }
.mk-fact.is-open .mk-fact__toggle { transform: rotate(45deg); background: var(--mk-ink); color: #fff; }

/* Editor: tampilkan teks detail di bawah judul agar bisa diedit langsung */
.elementor-editor-active .mk-fact__more {
	position: relative !important;
	inset: auto;
	opacity: 1;
	visibility: visible;
	transform: none;
	margin-top: 16px;
	padding: 16px !important;
	border-radius: 16px;
	background: rgba(255, 255, 255, 0.92);
	outline: 1px dashed var(--mk-accent);
}

/* ---------------------------------------------------------------- 4. solutions (Nested Tabs, gaya Apple) */

.mk-solutions .e-n-tabs-heading { gap: 2px; }
.mk-solutions .e-n-tab-title {
	justify-content: flex-start;
	text-align: start;
	border: 0 !important;
	background: transparent !important;
	transition: color var(--mk-fast) var(--mk-ease), padding var(--mk-fast) var(--mk-ease);
}
.mk-solutions .e-n-tab-title[aria-selected="true"] { padding-inline-start: 18px; }
.mk-solutions .e-n-tab-title::before {
	content: "";
	position: absolute;
	left: 0;
	top: 50%;
	width: 4px;
	height: 0;
	border-radius: 4px;
	background: var(--mk-accent);
	transform: translateY(-50%);
	transition: height var(--mk-fast) var(--mk-ease);
}
.mk-solutions .e-n-tab-title { position: relative; }
.mk-solutions .e-n-tab-title[aria-selected="true"]::before { height: 60%; }

.mk-sol {
	overflow: hidden;
	animation: mk-sol-in 0.6s var(--mk-ease) both;
}
.mk-sol .elementor-widget-button .elementor-button { border-radius: 999px; }
@keyframes mk-sol-in {
	from { opacity: 0; transform: translateY(14px) scale(0.99); }
	to { opacity: 1; transform: none; }
}

/* ---------------------------------------------------------------- 5–7. Story Cards (widget) */

.elementor-widget-mk-stories { min-width: 0; width: 100%; max-width: 100%; }

.mk-stories {
	min-width: 0;
	--mk-card-w: 372px;
	--mk-card-gap: 24px;
	--mk-card-r: 28px;
	--mk-card-bg: #fff;
	position: relative;
	color: var(--mk-ink);
}
.mk-stories--landscape { --mk-card-w: 520px; }

.mk-stories__track {
	display: flex;
	gap: var(--mk-card-gap);
	margin: 0;
	padding: 4px 0 8px;
	list-style: none;
}
.mk-stories--carousel .mk-stories__track {
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	overscroll-behavior-x: contain;
	scrollbar-width: none;
}
.mk-stories--carousel .mk-stories__track::-webkit-scrollbar { display: none; }
.mk-stories--bleed .mk-stories__track {
	width: calc(50% + 50vw - var(--mk-sbw) / 2);
	padding-right: max(16px, calc(50vw - 50% - var(--mk-sbw) / 2));
}
.mk-stories--grid .mk-stories__track {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
}

.mk-stories__item {
	flex: 0 0 var(--mk-card-w);
	margin: 0;
	padding: 0;
	scroll-snap-align: start;
}
.mk-stories__item::before { content: none; }

.mk-card {
	position: relative;
	display: flex;
	flex-direction: column;
	height: 100%;
	aspect-ratio: 400 / 710;
	overflow: hidden;
	border-radius: var(--mk-card-r);
	background: var(--mk-card-bg);
	color: var(--mk-ink);
	isolation: isolate;
	transition: transform 0.5s var(--mk-ease), box-shadow 0.5s var(--mk-ease);
}
.mk-stories--landscape .mk-card { aspect-ratio: 4 / 3; }
.mk-stories--grid .mk-card { aspect-ratio: 400 / 600; }
.mk-card:hover { transform: scale(1.015); box-shadow: 0 16px 48px rgba(0, 0, 0, 0.14); }

.mk-stories .mk-card__media { margin: 0; overflow: hidden; }
.mk-stories .mk-card__media img,
.mk-modal .mk-card__media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 1.2s var(--mk-ease);
}
.mk-card:hover .mk-card__media img { transform: scale(1.04); }

.mk-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
	gap: 14px;
	padding: 28px 30px 30px;
}
.mk-card__author { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 600; line-height: 1.2; }
.mk-card__author img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: #fff; }
.mk-card__title { margin: 0; font-size: 22px; font-weight: 700; line-height: 1.2; letter-spacing: -0.3px; color: inherit; }
.mk-card__text {
	display: -webkit-box;
	margin: 0;
	overflow: hidden;
	font-size: 17px;
	font-weight: 500;
	line-height: 1.4;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	color: inherit;
}
.mk-card__meta {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: auto;
	font-size: 15px;
	font-weight: 500;
	opacity: 0.85;
}
.mk-card__meta time { display: inline-flex; align-items: center; gap: 6px; }
.mk-card__meta .mk-icon { width: 16px; height: 16px; }
.mk-card__video::before { content: "•"; margin-right: 8px; }

/* full: foto penuh, teks putih di atas gradasi */
.mk-card--full { background: #111; color: #fff; }
.mk-stories .mk-card--full .mk-card__media { position: absolute; inset: 0; z-index: -2; }
.mk-card--full::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(180deg, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, 0.78) 100%);
}
.mk-card--full .mk-card__body { justify-content: flex-end; }
.mk-card--full .mk-card__meta { margin-top: 0; }

/* top: foto di atas, kartu putih */
.mk-card--top .mk-card__media { flex: 0 0 42%; }
.mk-card--top .mk-card__text { -webkit-line-clamp: 5; }

/* text: kartu teks besar */
.mk-card--text .mk-card__author { color: var(--mk-muted); font-weight: 500; }
.mk-card--text .mk-card__text {
	margin: auto 0;
	font-size: clamp(20px, 2vw, 26px);
	font-weight: 500;
	line-height: 1.32;
	-webkit-line-clamp: 10;
}
.mk-card--text .mk-card__meta { margin-top: 0; color: var(--mk-muted); }

.mk-card__hit {
	position: absolute;
	inset: 0;
	z-index: 3;
	width: 100%;
	padding: 0;
	border: 0;
	border-radius: inherit;
	background: transparent;
	cursor: pointer;
}

.mk-stories__nav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-top: 32px;
}
.mk-stories__dots { display: flex; gap: 10px; }
.mk-stories__dots span {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: #c7c7cc;
	transition: background var(--mk-fast), transform var(--mk-fast);
}
.mk-stories__dots span.is-active { background: var(--mk-ink); transform: scale(1.1); }
.mk-stories__arrows { display: flex; gap: 14px; margin-left: auto; }
.mk-stories--empty p { color: var(--mk-muted); }

/* ---------------------------------------------------------------- pop-up (dialog) */

.mk-modal {
	width: min(920px, calc(100vw - 32px));
	max-width: none;
	max-height: calc(100dvh - 48px);
	margin: auto;
	padding: 0;
	border: 0;
	border-radius: 32px;
	background: #fff;
	color: var(--mk-ink);
	box-shadow: 0 40px 120px rgba(0, 0, 0, 0.3);
	overflow: hidden;
}
.mk-modal::backdrop {
	background: rgba(245, 245, 247, 0.55);
	-webkit-backdrop-filter: blur(24px) saturate(1.4);
	backdrop-filter: blur(24px) saturate(1.4);
}
.mk-modal[open] { animation: mk-modal-in 0.5s var(--mk-ease) both; }
.mk-modal.is-closing { animation: mk-modal-out 0.25s ease-in both; }
@keyframes mk-modal-in { from { opacity: 0; transform: translateY(40px) scale(0.98); } to { opacity: 1; transform: none; } }
@keyframes mk-modal-out { to { opacity: 0; transform: translateY(24px) scale(0.98); } }

.mk-modal__panel { display: flex; flex-direction: column; max-height: calc(100dvh - 48px); }
.mk-modal__bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 28px 32px 0;
}
.mk-modal__content {
	overflow-y: auto;
	padding: 24px clamp(24px, 8%, 104px) 40px;
	outline: none;
}
.mk-modal__author { margin-bottom: 16px; color: var(--mk-muted); font-weight: 500; }
.mk-modal__title { margin: 0 0 12px; font-size: clamp(26px, 3vw, 34px); font-weight: 700; line-height: 1.15; letter-spacing: -0.6px; color: var(--mk-ink); }
.mk-modal__text { font-size: clamp(18px, 1.8vw, 22px); line-height: 1.45; color: var(--mk-ink); }
.mk-modal__text p { margin: 0 0 0.8em; }
.mk-modal__date { margin: 4px 0 28px; font-size: 15px; font-weight: 600; color: var(--mk-muted); }
.mk-modal__media { margin: 0 0 24px; overflow: hidden; border-radius: 20px; background: #000; }
.mk-modal__media img { display: block; width: 100%; height: auto; }
.mk-modal__media--video { position: relative; aspect-ratio: 16 / 9; }
.mk-modal__media--video iframe,
.mk-modal__media--video video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.mk-modal__cta { margin: 8px 0 0; }
.mk-modal__pager {
	display: flex;
	justify-content: center;
	gap: 14px;
	padding: 0 0 24px;
}
.mk-modal__share.is-copied::after { content: " ✓"; }

body.mk-modal-open { overflow: hidden; }

/* ---------------------------------------------------------------- 8. lokasi proyek — marquee */

.mk-marquee,
.e-con.mk-marquee { overflow: hidden; }
.mk-marquee__inner {
	display: flex;
	gap: inherit;
	width: max-content;
	animation: mk-marquee var(--mk-marquee-dur, 50s) linear infinite;
}
.mk-marquee:hover .mk-marquee__inner,
.mk-marquee:focus-within .mk-marquee__inner { animation-play-state: paused; }
.mk-marquee__inner > * { flex-shrink: 0; }
@keyframes mk-marquee { to { transform: translateX(calc(-50% - var(--mk-marquee-gap, 12px))); } }

.mk-place { overflow: hidden; transition: transform 0.5s var(--mk-ease); }
.mk-place:hover { transform: translateY(-4px); }

/* ---------------------------------------------------------------- logos */

.mk-logos .elementor-widget-image img {
	filter: grayscale(1);
	opacity: 0.6;
	transition: filter var(--mk-fast), opacity var(--mk-fast);
}
.mk-logos .elementor-widget-image:hover img { filter: none; opacity: 1; }

/* ---------------------------------------------------------------- /updates/ page */

.mk-updates-page { background: var(--mk-bg); }
.mk-updates-page__inner { max-width: 1280px; margin: 0 auto; padding: clamp(48px, 8vw, 120px) 16px; }
.mk-updates-page__head { margin-bottom: 40px; }
.mk-updates-page__title { margin: 0 0 12px; font-size: clamp(40px, 5vw, 56px); font-weight: 700; line-height: 1.1; letter-spacing: -2px; color: var(--mk-ink); }
.mk-updates-page__lead { max-width: 640px; margin: 0; font-size: 20px; color: var(--mk-text); }

/* ---------------------------------------------------------------- responsive */

@media (max-width: 1024px) {
	.mk-stories { --mk-card-w: 320px; }
	.mk-stories--landscape { --mk-card-w: 440px; }
}
@media (max-width: 767px) {
	.mk-stories { --mk-card-w: 78vw; --mk-card-gap: 14px; --mk-card-r: 22px; }
	.mk-stories--landscape { --mk-card-w: 84vw; }
	.mk-stories--landscape .mk-card { aspect-ratio: 4 / 4.6; }
	.mk-card__body { padding: 22px; }
	.mk-modal { border-radius: 24px; width: calc(100vw - 16px); max-height: calc(100dvh - 16px); }
	.mk-modal__panel { max-height: calc(100dvh - 16px); }
	.mk-modal__bar { padding: 16px 16px 0; }
	.mk-modal__content { padding: 16px 20px 28px; }
	.mk-fact__toggle { right: 16px; bottom: 16px; }
	.mk-fact:hover { transform: none; box-shadow: none; }
}

@media (prefers-reduced-motion: reduce) {
	.mk-marquee__inner { animation: none; }
	.mk-marquee { overflow-x: auto; }
	.mk-words .mk-w { opacity: 1; transition: none; }
	.mk-card, .mk-card__media img, .mk-fact, .mk-sol, .mk-modal[open] { transition: none; animation: none; }
}
