/* Adam Milo – "Image/Video + Text" block
 * Values read from Figma (file "Global+israel sites") via the Figma API:
 *  - "Fit"  Frame 1973342756 (2816:8729): text 850 + image, gap 72, image radius 16 + shadow
 *  - "Risk" Frame 1973342754 (2804:8020): video in a browser-window frame, gap 56
 *  - Sections: white, padding 100 (desktop) / 32 (mobile, Fit – mobile 2865:11758)
 */

.amms-section {
	--amms-title-color: #212529;
	--amms-line-color: #E96835;
	--amms-gap: 72px;
	background-color: var(--amms-section-bg, #fff);
	padding: 100px 0;
	font-family: Poppins, sans-serif;
}

.amms-section .amms-row {
	display: flex;
	align-items: flex-start;
	gap: var(--amms-gap);
}
/* side switch: the text is first in the HTML; media left = reverse */
.amms-section.amms-media-left .amms-row {
	flex-direction: row-reverse;
}
/* vertical alignment of the media to the text */
.amms-section.amms-valign-center .amms-media {
	align-self: center;
}
.amms-section.amms-valign-top .amms-media {
	align-self: flex-start;
}

/* ---------- Text ---------- */
.amms-section .amms-text {
	flex: 0 1 850px;                    /* Figma: 850px text column */
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 24px;                          /* Figma: gap 24 */
}
.amms-section.amms-no-media .amms-text {
	flex-basis: 100%;
}
.amms-section .amms-title {
	margin: 0;
	color: var(--amms-title-color);
	font-family: Poppins, sans-serif;
	font-size: 32px;                    /* Poppins Bold 32, normal */
	font-weight: 700;
	line-height: 1.5;
}
.amms-section .amms-line {
	display: block;
	width: 66px;                        /* Figma: 66 x 5 */
	height: 5px;
	background-color: var(--amms-line-color);
}

/* rich content */
.amms-section .amms-content {
	color: #000;
	font-size: 16px;
	line-height: 1.5;
}
.amms-section .amms-content > :first-child { margin-top: 0; }
.amms-section .amms-content > :last-child  { margin-bottom: 0; }
.amms-section .amms-content p {
	margin: 0 0 16px;
	color: #000;
	font-size: 16px;
	line-height: 1.5;
}
/* sub-titles (Fit: "AMPQ | Personality and Work Style") – Bold 18 / 36, gap 4 to text */
.amms-section .amms-content h3,
.amms-section .amms-content h4,
.amms-section .amms-content h5 {
	margin: 16px 0 4px;
	color: #212529;
	font-family: Poppins, sans-serif;
	font-size: 18px;
	font-weight: 700;
	line-height: 36px;
}
.amms-section .amms-content h3 + p,
.amms-section .amms-content h4 + p,
.amms-section .amms-content h5 + p {
	margin-top: 0;
}
/* numbered steps (Risk: "Candidate Risk Report") */
.amms-section .amms-content ol,
.amms-section .amms-content ul {
	margin: 0 0 16px;
	padding-left: 24px;
}
/* the theme removes list markers site-wide – bring them back here */
.amms-section .amms-content ol,
.amms-section .amms-content ol > li {
	list-style: decimal outside;
}
.amms-section .amms-content ul,
.amms-section .amms-content ul > li {
	list-style: disc outside;
}
.amms-section .amms-content li {
	margin-bottom: 24px;                /* Figma: mb 24 */
	font-size: 16px;
	line-height: 28px;
}
.amms-section .amms-content li:last-child {
	margin-bottom: 0;
}
.amms-section .amms-content ol > li::marker {
	font-size: 18px;
	font-weight: 700;
	color: #212529;
}
.amms-section .amms-content li > strong:first-child,
.amms-section .amms-content li > b:first-child {
	display: inline-block;
	vertical-align: top;               /* keeps the list number on the first line when the title wraps */
	margin-bottom: 4px;
	color: #212529;
	font-size: 18px;
	line-height: 28px;
}

/* ---------- Media ---------- */
.amms-section .amms-media {
	flex: 1 1 0;
	min-width: 0;
}
.amms-section .amms-media-box {
	position: relative;
	overflow: hidden;
	background: #e9ecef;
}
.amms-section.amms-ratio-fixed .amms-media-box {
	aspect-ratio: var(--amms-ratio);
}
.amms-section .amms-img,
.amms-section .amms-video {
	display: block;
	width: 100%;
	height: auto;
}
.amms-section.amms-ratio-fixed .amms-img,
.amms-section .amms-video {
	position: absolute;
	inset: 0;
	height: 100%;
	object-fit: cover;                  /* Figma: CROP, centered */
}
.amms-section .amms-media-box.amms-has-video .amms-img {
	position: absolute;
	inset: 0;
	height: 100%;
	object-fit: cover;
}
.amms-section .amms-video {
	opacity: 0;
	transition: opacity .6s ease;
}
.amms-section .amms-video-ready .amms-video {
	opacity: 1;
}
.amms-section .amms-video-ready .amms-img {
	opacity: 0;
	transition: opacity .6s ease;
}

/* Frame: rounded + shadow (Fit) */
.amms-section.amms-frame-plain .amms-media-box {
	border-radius: 16px;
	box-shadow: 17px 14px 42.6px rgba(0, 0, 0, .15);
}

/* Frame: browser window (Risk) – white card r13.7, padding 11.1/8.6/8.6,
   bar 10.3 high: 3 orange dots + #C6DFE3 pill, media r12 */
.amms-section.amms-frame-browser .amms-frame {
	display: flex;
	flex-direction: column;
	gap: 13.7px;
	padding: 11.13px 8.56px 8.56px;
	background: #fff;
	border-radius: 13.7px;
	box-shadow: 14.55px 11.98px 36.47px rgba(0, 0, 0, .15);
}
.amms-section .amms-browser-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	height: 10.27px;
}
.amms-section .amms-dots {
	display: flex;
	gap: 7.7px;
	padding: 0 6.85px;
}
.amms-section .amms-dots i {
	display: block;
	width: 10.27px;
	height: 10.27px;
	border-radius: 50%;
	background: #E96835;
}
.amms-section .amms-pill {
	display: block;
	width: 146.38px;
	max-width: 40%;
	height: 10.27px;
	border-radius: 64px;
	background: #C6DFE3;
}
.amms-section.amms-frame-browser .amms-media-box {
	border-radius: 12px;
}

/* ---------- Laptop ---------- */
@media (max-width: 1199px) {
	.amms-section .amms-row {
		gap: min(var(--amms-gap), 48px);
	}
}

/* ---------- Tablet (incl. iPad 1024) / mobile: image first, then text (Figma "Fit – mobile") ---------- */
@media (max-width: 1024px) {
	.amms-section {
		padding: 32px 0;
	}
	.amms-section .amms-row,
	.amms-section.amms-media-left .amms-row {
		flex-direction: column-reverse;    /* media on top */
		gap: 32px;
	}
	.amms-section .amms-text,
	.amms-section .amms-media {
		flex: 0 0 auto;
		width: 100%;
		align-self: stretch !important;
	}
	/* tablets: same layout as mobile, but the image/video is not stretched
	   to the full tablet width – max 640px, centered */
	.amms-section .amms-media {
		max-width: 640px;
		margin-left: auto;
		margin-right: auto;
	}
}
