/*
  Mainstop band kit.

  Every hand built page composes from these parts. If a page needs a shape that
  is not here, add it here rather than inventing a one off. Framework and
  rationale: docs/REVALIS-REFERENCE.md and docs/DESIGN.md.
*/

/* ============================================================ section head */
.ms-eyebrow {
	display: block;
	font: 600 12px/1 var(--ms-font-body);
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--ms-muted);
	margin: 0 0 14px;
}
.ms-on-dark .ms-eyebrow { color: rgba(244, 247, 243, 0.62); }
.ms-lede { font: 400 19px/1.6 var(--ms-font-body); color: var(--ms-muted); max-width: 62ch; margin: 0; }
.ms-on-dark .ms-lede { color: rgba(244, 247, 243, 0.78); }
.ms-center { text-align: center; }
.ms-center .ms-lede { margin-left: auto; margin-right: auto; }

/* ============================================================== actions */
.ms-arrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font: 600 15px/1 var(--ms-font-body);
	color: var(--ms-forest);
	text-decoration: none;
}
.ms-arrow svg { width: 15px; height: 15px; flex: 0 0 auto; }
.ms-on-dark .ms-arrow { color: var(--ms-brass); }
@media (prefers-reduced-motion: no-preference) {
	.ms-arrow svg { transition: transform 0.22s ease; }
	.ms-arrow:hover svg { transform: translate(2px, -2px); }
}

.ms-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	min-height: 48px;
	padding: 0 26px;
	border: 0;
	border-radius: var(--ms-radius);
	background: var(--ms-brass);
	color: var(--ms-deep);
	font: 700 15px/1 var(--ms-font-body);
	text-decoration: none;
	cursor: pointer;
}
.ms-btn:hover { background: #dcb45f; color: var(--ms-deep); }
.ms-btn-outline {
	background: transparent;
	border: 1px solid var(--ms-forest);
	color: var(--ms-forest);
}
.ms-btn-outline:hover { background: var(--ms-forest); color: var(--ms-bone); }
.ms-on-dark .ms-btn-outline { border-color: rgba(244, 247, 243, 0.34); color: var(--ms-bone); }
.ms-on-dark .ms-btn-outline:hover { background: var(--ms-bone); color: var(--ms-deep); }

/* ========================================================= browse by type */
.ms-types { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; }
.ms-type {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	padding: 30px 12px;
	border: 1px solid rgba(244, 247, 243, 0.16);
	border-radius: var(--ms-radius-lg);
	text-decoration: none;
	color: var(--ms-bone);
}
.ms-type-ring {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 74px;
	height: 74px;
	border: 1px solid rgba(244, 247, 243, 0.34);
	border-radius: 50%;
	color: var(--ms-bone);
}
.ms-type-ring svg { width: 30px; height: 30px; }
.ms-type-name { font: 600 17px/1.2 var(--ms-font-body); }
.ms-type-count { font: 400 13px/1 var(--ms-font-body); color: rgba(244, 247, 243, 0.6); }
@media (prefers-reduced-motion: no-preference) {
	.ms-type, .ms-type-ring { transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease; }
}
.ms-type:hover { border-color: rgba(244, 247, 243, 0.4); }
.ms-type:hover .ms-type-ring { background: var(--ms-bone); color: var(--ms-deep); border-color: var(--ms-bone); }
@media (max-width: 900px) { .ms-types { grid-template-columns: repeat(2, 1fr); } }

/* ============================================================ card grids */
.ms-cardgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 1024px) { .ms-cardgrid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px)  { .ms-cardgrid { grid-template-columns: 1fr; } }

.ms-scard {
	display: flex;
	flex-direction: column;
	background: var(--ms-white);
	border: 1px solid var(--ms-border);
	border-radius: var(--ms-radius-lg);
	overflow: hidden;
	text-decoration: none;
	color: inherit;
}
.ms-scard-body { padding: 26px 24px 20px; display: flex; flex-direction: column; gap: 9px; }
.ms-scard h3 { font: 700 21px/1.25 var(--ms-font-head); color: var(--ms-ink); margin: 0; }
.ms-scard p { font: 400 15px/1.6 var(--ms-font-body); color: var(--ms-muted); margin: 0; }
.ms-scard-img { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--ms-sage); }
.ms-scard-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ms-scard-foot { margin-top: auto; padding: 16px 24px; border-top: 1px solid var(--ms-border); }
@media (prefers-reduced-motion: no-preference) {
	.ms-scard { transition: box-shadow 0.28s ease, transform 0.28s ease; }
	.ms-scard-img img { transition: transform 0.4s ease; }
	.ms-scard:hover { transform: translateY(-3px); box-shadow: 0 1px 2px rgba(18,36,29,0.06), 0 8px 24px rgba(18,36,29,0.08); }
	.ms-scard:hover .ms-scard-img img { transform: scale(1.05); }
}

/* ====================================================== trust commitments */
/* The dark band. Where the reference puts invented statistics, this puts
   promises the business can actually be held to. */
.ms-trust-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 34px 44px; }
.ms-trust-item { display: flex; flex-direction: column; gap: 8px; }
.ms-trust-ico {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: var(--ms-radius);
	background: rgba(227, 235, 226, 0.12);
	color: var(--ms-brass);
	margin-bottom: 4px;
}
.ms-trust-ico svg { width: 22px; height: 22px; }
.ms-trust-item h3 { font: 700 19px/1.3 var(--ms-font-head); color: var(--ms-bone); margin: 0; }
.ms-trust-item p { font: 400 15px/1.6 var(--ms-font-body); color: rgba(244,247,243,0.74); margin: 0; max-width: 42ch; }
@media (max-width: 700px) { .ms-trust-grid { grid-template-columns: 1fr; gap: 26px; } }

/* ============================================================== features */
.ms-features { display: grid; grid-template-columns: repeat(2, 1fr); gap: 30px 40px; }
.ms-feature { display: flex; flex-direction: column; gap: 8px; }
.ms-feature-ico {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	background: var(--ms-sage);
	color: var(--ms-forest);
	margin-bottom: 4px;
}
.ms-feature-ico svg { width: 22px; height: 22px; }
.ms-feature h3 { font: 700 18px/1.3 var(--ms-font-head); color: var(--ms-ink); margin: 0; }
.ms-feature p { font: 400 15px/1.6 var(--ms-font-body); color: var(--ms-muted); margin: 0; }
@media (max-width: 700px) { .ms-features { grid-template-columns: 1fr; gap: 24px; } }

/* ========================================================= organic crops */
/* The one place the composition is allowed to feel hand placed. */
.ms-organic { position: relative; min-height: 460px; }
.ms-organic img { display: block; object-fit: cover; }
.ms-organic-a { width: 62%; aspect-ratio: 1 / 1; border-radius: 50%; overflow: hidden; }
.ms-organic-b {
	position: absolute;
	right: 0;
	bottom: 0;
	width: 46%;
	aspect-ratio: 3 / 4;
	border-radius: 999px 999px var(--ms-radius-lg) var(--ms-radius-lg);
	overflow: hidden;
	border: 6px solid var(--ms-bone);
}
.ms-organic-a img, .ms-organic-b img { width: 100%; height: 100%; }
@media (max-width: 900px) {
	.ms-organic { min-height: 300px; }
	.ms-organic-a { width: 66%; }
	.ms-organic-b { width: 44%; }
}

/* ================================================================ steps */
/* A hairline runs behind the row and the numbers sit on it. */
.ms-steprow { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; }
.ms-steprow::before {
	content: "";
	position: absolute;
	left: 0; right: 0; top: 21px;
	height: 1px;
	background: var(--ms-border);
}
.ms-on-dark .ms-steprow::before { background: rgba(244,247,243,0.18); }
.ms-step2 { position: relative; display: flex; flex-direction: column; gap: 10px; }
.ms-step2-n {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	background: var(--ms-forest);
	color: var(--ms-bone);
	font: 700 14px/1 var(--ms-font-body);
	position: relative;
	z-index: 1;
}
.ms-step2-k { font: 600 11px/1 var(--ms-font-body); letter-spacing: 0.1em; text-transform: uppercase; color: var(--ms-muted); }
.ms-step2 h3 { font: 700 18px/1.3 var(--ms-font-head); color: var(--ms-ink); margin: 0; }
.ms-step2 p { font: 400 15px/1.6 var(--ms-font-body); color: var(--ms-muted); margin: 0; }
@media (max-width: 900px) {
	.ms-steprow { grid-template-columns: repeat(2, 1fr); gap: 30px 20px; }
	.ms-steprow::before { display: none; }
}
@media (max-width: 520px) { .ms-steprow { grid-template-columns: 1fr; } }

/* ============================================================= checklist */
.ms-check { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.ms-check li { display: flex; gap: 13px; align-items: flex-start; font: 400 16px/1.55 var(--ms-font-body); color: var(--ms-ink); }
.ms-check-dot {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: var(--ms-forest);
	color: var(--ms-bone);
	margin-top: 1px;
}
.ms-check-dot svg { width: 13px; height: 13px; }

/* =========================================================== stat / fact */
.ms-facts { display: flex; gap: 56px; flex-wrap: wrap; }
.ms-fact-n { font: 700 46px/1 var(--ms-font-head); color: var(--ms-ink); letter-spacing: -0.02em; }
.ms-fact-l { font: 400 15px/1.5 var(--ms-font-body); color: var(--ms-muted); margin-top: 6px; max-width: 26ch; }

/* ================================================================ video */
.ms-video {
	position: relative;
	border-radius: var(--ms-radius-lg);
	overflow: hidden;
	background: var(--ms-deep);
	aspect-ratio: 16 / 9;
}
.ms-video img, .ms-video video { width: 100%; height: 100%; object-fit: cover; display: block; }
.ms-video video { position: absolute; inset: 0; }
.ms-video-play {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 0;
	background: rgba(18, 36, 29, 0.18);
	cursor: pointer;
	padding: 0;
}
.ms-video-disc {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 84px;
	height: 84px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.92);
	color: var(--ms-deep);
	backdrop-filter: blur(6px);
}
.ms-video-disc svg { width: 26px; height: 26px; margin-left: 4px; }
.ms-video.is-playing .ms-video-play { display: none; }
@media (prefers-reduced-motion: no-preference) {
	.ms-video-play, .ms-video-disc { transition: background-color 0.25s ease, transform 0.25s ease; }
	.ms-video-play:hover { background: rgba(18, 36, 29, 0.3); }
	.ms-video-play:hover .ms-video-disc { transform: scale(1.06); }
}
.ms-video-cap { font: 400 14px/1.5 var(--ms-font-body); color: var(--ms-muted); margin: 12px 0 0; text-align: center; }

/* ========================================================= insights promo */
.ms-promo {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 14px;
	padding: 32px 28px;
	border-radius: var(--ms-radius-lg);
	background: var(--ms-deep);
	color: var(--ms-bone);
}
.ms-promo h3 { font: 700 22px/1.28 var(--ms-font-head); color: var(--ms-bone); margin: 0; }
.ms-promo p { font: 400 15px/1.6 var(--ms-font-body); color: rgba(244,247,243,0.76); margin: 0; }
.ms-promo .ms-arrow { color: var(--ms-brass); }

/* ============================================================== contact */
.ms-contact-row {
	display: flex;
	align-items: center;
	gap: 14px;
	padding: 18px 20px;
	border: 1px solid var(--ms-border);
	border-radius: var(--ms-radius-lg);
	background: var(--ms-white);
	text-decoration: none;
	color: inherit;
}
.ms-contact-row .ms-ci {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	flex: 0 0 auto;
	border-radius: var(--ms-radius);
	background: var(--ms-sage);
	color: var(--ms-forest);
}
.ms-contact-row .ms-ci svg { width: 21px; height: 21px; }
.ms-contact-row b { display: block; font: 600 12px/1 var(--ms-font-body); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ms-muted); margin-bottom: 5px; }
.ms-contact-row span { font: 500 16px/1.35 var(--ms-font-body); color: var(--ms-ink); }
.ms-contact-row .ms-ci-wa { background: var(--ms-forest); color: var(--ms-bone); }
.ms-contact-row:hover { border-color: var(--ms-forest); }

/* ================================================================ motion */
/* Fail safe. The hidden state applies ONLY under .ms-js, a class set by an
   inline head script. If JavaScript is blocked, slow or broken, every band is
   simply visible with no animation. A page that animates is worth less than a
   page that is never blank. */\n/* Fail safe: the hidden state applies ONLY under .ms-js, which is set by an\n   inline head script. If JavaScript is blocked, slow or broken, every band is\n   simply visible with no animation. A page that animates is worth less than a\n   page that is never blank. */
/* Three recipes, matching DESIGN.md. Amplitude is deliberately lower than the
   reference: 32px and 0.96 rather than 120px and 0.8, because this is a phone
   on mobile data before it is anything else. */
@media (prefers-reduced-motion: no-preference) {
	.ms-js .ms-rise, .ms-js .ms-fade, .ms-js .ms-settle { will-change: transform, opacity; }
	.ms-js .ms-rise   { opacity: 0; transform: translateY(32px) scale(0.96); }
	.ms-js .ms-fade   { opacity: 0; }
	.ms-js .ms-settle { opacity: 0; transform: translateY(20px); }
	.ms-js .ms-rise.is-in   { opacity: 1; transform: none; transition: opacity 0.6s cubic-bezier(0.68,0,0,0.99), transform 0.6s cubic-bezier(0.68,0,0,0.99); }
	.ms-js .ms-fade.is-in   { opacity: 1; transition: opacity 0.8s ease; }
	.ms-js .ms-settle.is-in { opacity: 1; transform: none; transition: opacity 0.5s ease 0.25s, transform 0.5s cubic-bezier(0.2,0.8,0.2,1) 0.25s; }
	.ms-js .ms-rise.is-in, .ms-js .ms-fade.is-in, .ms-js .ms-settle.is-in { will-change: auto; }
}
@media (prefers-reduced-motion: reduce) {
	.ms-js .ms-rise, .ms-js .ms-fade, .ms-js .ms-settle { opacity: 1 !important; transform: none !important; }
}
