/* ==========================================================
   Cloud & DevOps page styles
   Loaded by templates/views/assets/dev-ops.html
   ========================================================== */

.do-stage {
	display: grid;
	grid-template-columns: 1.6fr 1fr;
	gap: 16px;
	height: 480px;
	padding: 22px;
	color: #e7eaee;
	background: radial-gradient(60% 60% at 20% 0%, rgba(0, 181, 226, 0.18), transparent 60%), #0e1820;
}
.do-lanes {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 12px;
}
.do-lane {
	display: flex;
	flex-direction: column;
	border-radius: 16px;
	background: rgba(255, 255, 255, 0.04);
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.do-lane header {
	padding: 14px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.do-lane header b {
	display: block;
	font: 400 15px/1.2 var(--font-display);
	color: #fff;
}
.do-lane header span {
	font: 400 11px/1 var(--font-mono);
	color: #7d8691;
}
.do-slot {
	flex: 1;
	position: relative;
}
.do-lane footer {
	padding: 12px 14px;
	font: 400 11px/1.4 var(--font-mono);
	color: #7d8691;
	border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.do-pkg {
	position: absolute;
	left: 14px;
	top: 40%;
	z-index: 2;
	padding: 10px 14px;
	border-radius: 12px;
	font: 400 13px/1 var(--font-mono);
	font-style: normal;
	color: #04231a;
	background: var(--mint);
	box-shadow:
		0 0 0 6px rgba(0, 195, 137, 0.18),
		0 14px 30px -10px rgba(0, 195, 137, 0.7);
	transition: transform 1s var(--ease);
}
.do-stage[data-step='1'] .do-pkg {
	transform: translateX(0) translateY(-8px);
}
.do-stage[data-step='2'] .do-pkg {
	transform: translateX(calc(100% + 85px));
}
.do-stage[data-step='3'] .do-pkg {
	transform: translateX(calc(200% + 170px));
}
.do-log {
	padding: 16px;
	border-radius: 16px;
	font: 400 12.5px/1.8 var(--font-mono);
	background: #091117;
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.do-log header {
	margin-bottom: 10px;
	color: #7d8691;
}
.do-log p {
	margin: 0;
	opacity: 0.2;
	transition: opacity 0.4s;
	color: #c9ced6;
}
.do-log p:not(.a) {
	color: var(--mint);
}
.do-stage[data-step='0'] .do-log .a,
.do-stage[data-step='1'] .do-log :is(.a, .b),
.do-stage[data-step='2'] .do-log :is(.a, .b, .c),
.do-stage[data-step='3'] .do-log p {
	opacity: 1;
}

/* pipeline pin */
.do-pipe-stick {
	position: sticky;
	top: 0;
	min-height: 100vh;
	display: flex;
	align-items: center;
	padding: calc(var(--header-h) + 20px) 0 40px;
}
.do-pipe .e-head {
	margin-bottom: 48px;
}
.do-track {
	position: relative;
	height: 24px;
	margin: 0 calc(100% / 12);
}
.do-rail {
	position: absolute;
	left: 0;
	right: 0;
	top: 11px;
	height: 2px;
	background: var(--line-strong);
}
.do-rail i {
	position: absolute;
	inset: 0;
	transform-origin: left;
	transform: scaleX(var(--p, 0));
	background: linear-gradient(90deg, var(--tone), var(--tone-2));
}
.do-dot {
	position: absolute;
	top: 2px;
	left: calc(var(--p, 0) * 100%);
	width: 20px;
	height: 20px;
	margin-left: -10px;
	border-radius: 50%;
	background: var(--tone-2);
	box-shadow:
		0 0 0 8px color-mix(in srgb, var(--tone-2) 22%, transparent),
		0 0 24px var(--tone-2);
}
.do-stations {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: 12px;
	margin-top: 24px;
}
.do-stations > div {
	padding: 20px 18px;
	border-radius: 18px;
	background: #fff;
	box-shadow: 0 0 0 1px var(--line);
	opacity: 0.4;
	transition:
		opacity 0.4s,
		box-shadow 0.4s,
		transform 0.4s var(--ease);
}
.do-stations small {
	font: 400 11.5px/1 var(--font-mono);
	color: var(--subtle);
}
.do-stations b {
	display: block;
	margin-top: 10px;
	font: 400 1.1rem/1.25 var(--font-display);
}
.do-stations p {
	margin-top: 8px;
	font-size: 13.5px;
	line-height: 1.55;
	color: var(--muted);
}
.do-pipe[data-step='0'] .do-stations > div:nth-child(1),
.do-pipe[data-step='1'] .do-stations > div:nth-child(2),
.do-pipe[data-step='2'] .do-stations > div:nth-child(3),
.do-pipe[data-step='3'] .do-stations > div:nth-child(4),
.do-pipe[data-step='4'] .do-stations > div:nth-child(5),
.do-pipe[data-step='5'] .do-stations > div:nth-child(6) {
	opacity: 1;
	transform: translateY(-6px);
	box-shadow:
		0 0 0 1.5px color-mix(in srgb, var(--tone) 40%, transparent),
		var(--shadow-md);
}
.do-pipe[data-step='1'] .do-stations > div:nth-child(-n + 1),
.do-pipe[data-step='2'] .do-stations > div:nth-child(-n + 2),
.do-pipe[data-step='3'] .do-stations > div:nth-child(-n + 3),
.do-pipe[data-step='4'] .do-stations > div:nth-child(-n + 4),
.do-pipe[data-step='5'] .do-stations > div:nth-child(-n + 5) {
	opacity: 0.8;
}

/* simulator */
.do-sim {
	display: grid;
	grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.9fr);
	gap: 20px;
}
.do-sim-map {
	position: relative;
	display: grid;
	justify-items: center;
	gap: 46px;
	padding: 32px 24px;
	border-radius: 26px;
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
}
.do-lb {
	padding: 14px 22px;
	border-radius: 16px;
	text-align: center;
	color: #fff;
	background: var(--ink);
}
.do-lb b {
	display: block;
	font: 400 15px/1.2 var(--font-display);
}
.do-lb small {
	color: #9aa3ae;
	font-size: 12px;
}
.do-srvs {
	position: relative;
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 14px;
	width: 100%;
}
.do-srvs::before {
	content: '';
	position: absolute;
	left: 16%;
	right: 16%;
	top: -78px;
	height: 95px;
	border: 2px dashed var(--line-strong);
	border-bottom: 0;
	border-radius: 14px 14px 0 0;
}
.do-srv {
	position: relative;
	padding: 18px 14px;
	border-radius: 16px;
	text-align: center;
	background: #fff;
	box-shadow: 0 0 0 1.5px rgba(0, 166, 118, 0.35);
	transition:
		box-shadow 0.4s,
		background 0.4s,
		opacity 0.4s;
}
.do-srv i {
	display: block;
	width: 12px;
	height: 12px;
	margin: 0 auto 10px;
	border-radius: 50%;
	background: #00c389;
	box-shadow: 0 0 0 5px rgba(0, 195, 137, 0.18);
	animation: g-blink 1.6s ease-in-out infinite;
}
@keyframes g-blink {
	50% {
		box-shadow: 0 0 0 8px rgba(0, 195, 137, 0.04);
	}
}
.do-srv b {
	display: block;
	font: 400 15px/1.2 var(--font-display);
}
.do-srv small {
	color: var(--muted);
	font-size: 12.5px;
}
.do-sim[data-phase='1'] .s2,
.do-sim[data-phase='2'] .s2 {
	background: #fff2ef;
	box-shadow: 0 0 0 1.5px rgba(226, 87, 74, 0.6);
}
.do-sim[data-phase='1'] .s2 i,
.do-sim[data-phase='2'] .s2 i {
	background: #e2574a;
	box-shadow: 0 0 0 6px rgba(226, 87, 74, 0.2);
}
.do-sim[data-phase='3'] .s2 {
	background: #fff8ec;
	box-shadow: 0 0 0 1.5px rgba(226, 160, 74, 0.6);
}
.do-sim[data-phase='3'] .s2 i {
	background: #e2a04a;
	box-shadow: 0 0 0 6px rgba(226, 160, 74, 0.2);
}
.do-sim[data-phase='2'] .do-srv:not(.s2),
.do-sim[data-phase='3'] .do-srv:not(.s2) {
	box-shadow:
		0 0 0 2px #00a676,
		0 12px 24px -12px #00a676;
}
.do-alert {
	position: absolute;
	top: 24px;
	right: 24px;
	max-width: 240px;
	padding: 12px 14px;
	border-radius: 14px;
	color: #fff;
	background: #c4423a;
	box-shadow: var(--shadow-lg);
	font-size: 13px;
	opacity: 0;
	transform: translateY(-8px);
	transition:
		opacity 0.4s,
		transform 0.4s var(--ease);
}
.do-alert b {
	display: block;
	font-weight: 400;
}
.do-alert span {
	opacity: 0.85;
	font-size: 12px;
}
.do-sim[data-phase='1'] .do-alert,
.do-sim[data-phase='2'] .do-alert {
	opacity: 1;
	transform: none;
}
.do-btn[disabled] {
	opacity: 0.6;
	cursor: progress;
}
.do-sim-log {
	padding: 22px;
	border-radius: 26px;
	color: #c9ced6;
	background: var(--ink);
}
.do-sim-log header {
	display: flex;
	justify-content: space-between;
	padding-bottom: 14px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	font: 400 11.5px/1 var(--font-mono);
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: #7d8691;
}
.do-sim-log header b {
	font-weight: 400;
	color: #fff;
}
.do-sim-log ol {
	display: grid;
	gap: 10px;
	margin-top: 16px;
}
.do-sim-log li {
	display: grid;
	grid-template-columns: 54px 1fr;
	gap: 10px;
	font: 400 13px/1.5 var(--font-mono);
	animation: ap-in 0.4s var(--ease);
}
.do-sim-log li em {
	font-style: normal;
	color: #7d8691;
}
.do-sim-log li.bad span {
	color: #ff8a80;
}
.do-sim-log li.ok span {
	color: var(--mint);
}
.do-sim-log li.idle {
	display: block;
	color: #7d8691;
}
@keyframes ap-in {
	from {
		opacity: 0;
		transform: translateY(-6px);
	}
}

/* cost */
.do-cost {
	padding: clamp(22px, 3vw, 40px);
	border-radius: 28px;
	background: #fff;
	box-shadow:
		0 0 0 1px var(--line),
		var(--shadow-sm);
}
.do-cost-top {
	display: grid;
	grid-template-columns: auto 1fr auto;
	gap: 16px;
	align-items: center;
	font: 400 12px/1 var(--font-mono);
	letter-spacing: 0.05em;
	text-transform: uppercase;
	color: var(--muted);
}
.do-cost input {
	width: 100%;
	accent-color: var(--tone);
	height: 28px;
	cursor: pointer;
}
.do-bars {
	display: grid;
	gap: 14px;
	margin-top: 30px;
}
.do-bar {
	display: grid;
	grid-template-columns: 240px 1fr 54px;
	gap: 16px;
	align-items: center;
	font-size: 15px;
	color: var(--ink-2);
}
.do-bar > div {
	height: 14px;
	border-radius: 14px;
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
	overflow: hidden;
}
.do-bar i {
	display: block;
	height: 100%;
	width: calc(var(--w, 0) * 1%);
	border-radius: inherit;
	background: linear-gradient(90deg, var(--tone), var(--tone-2));
	transition: width 0.25s;
}
.do-bar:nth-child(2) i {
	background: linear-gradient(90deg, #e2774a, #e2a04a);
}
.do-bar em {
	font-style: normal;
	font: 400 13px/1 var(--font-mono);
	color: var(--subtle);
	text-align: right;
}
.do-total {
	display: grid;
	grid-template-columns: auto auto 1fr;
	gap: 10px 20px;
	align-items: baseline;
	margin-top: 28px;
	padding-top: 22px;
	border-top: 1px solid var(--line);
}
.do-total span {
	font: 400 12px/1 var(--font-mono);
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--subtle);
}
.do-total b {
	font: 400 2.4rem/1 var(--font-display);
	letter-spacing: -0.03em;
	color: #0b6b4f;
}
.do-total small {
	color: var(--muted);
	font-size: 13px;
	line-height: 1.5;
}

@media (max-width: 1000px) {
	.do-stage {
		grid-template-columns: 1fr;
		height: auto;
	}
	.do-lanes {
		min-height: 260px;
	}
	.do-stage[data-step='2'] .do-pkg {
		transform: translateX(calc(100% + 40px));
	}
	.do-stage[data-step='3'] .do-pkg {
		transform: translateX(calc(200% + 80px));
	}
	.do-stations {
		grid-template-columns: repeat(3, 1fr);
	}
	.do-sim {
		grid-template-columns: 1fr;
	}
	.do-bar {
		grid-template-columns: 1fr 50px;
	}
	.do-bar span {
		grid-column: 1 / -1;
	}
}
@media (max-width: 640px) {
	.do-lane header span,
	.do-lane footer {
		display: none;
	}
	.do-lane header b {
		font-size: 12.5px;
	}
	.do-pkg {
		left: 6px;
		padding: 7px 8px;
		font-size: 10.5px;
	}
	.do-stage[data-step='2'] .do-pkg {
		transform: translateX(calc(100% + 20px));
	}
	.do-stage[data-step='3'] .do-pkg {
		transform: translateX(calc(200% + 40px));
	}
	.do-stations {
		grid-template-columns: 1fr 1fr;
		gap: 8px;
	}
	.do-stations p {
		display: none;
	}
	.do-stations > div {
		padding: 14px;
	}
	.do-track {
		margin: 0 8px;
	}
	.do-alert {
		position: static;
		max-width: none;
	}
	.do-srv {
		padding: 12px 6px;
	}
	.do-srv b {
		font-size: 13px;
	}
	.do-cost-top {
		grid-template-columns: 1fr 1fr;
	}
	.do-cost-top input {
		grid-column: 1 / -1;
		grid-row: 2;
	}
	.do-total {
		grid-template-columns: auto 1fr;
	}
	.do-total small {
		grid-column: 1 / -1;
	}
}
/* hero mockup: a deploy in a terminal + region health */
.ht {
	padding: 16px 18px 6px;
	font: 400 11.5px/1.95 var(--font-mono);
	color: #c9ced6;
	min-height: 250px;
}
.ht div {
	opacity: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	animation: ht-line 10s infinite;
}
.ht .p {
	color: #7ce7ff;
}
.ht .ok {
	color: #3ee0a8;
}
.ht .dim {
	color: #6f7883;
}
.ht .w {
	color: #ffbe98;
}
.ht div:nth-child(1) {
	animation-delay: 0s;
}
.ht div:nth-child(2) {
	animation-delay: 0.6s;
}
.ht div:nth-child(3) {
	animation-delay: 1.2s;
}
.ht div:nth-child(4) {
	animation-delay: 1.8s;
}
.ht div:nth-child(5) {
	animation-delay: 2.4s;
}
.ht div:nth-child(6) {
	animation-delay: 3.2s;
}
.ht div:nth-child(7) {
	animation-delay: 4s;
}
@keyframes ht-line {
	0% {
		opacity: 0;
		transform: translateX(-6px);
	}
	3%,
	88% {
		opacity: 1;
		transform: none;
	}
	95%,
	100% {
		opacity: 0;
	}
}
.ht-bar {
	height: 4px;
	margin: 4px 0 2px;
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.08);
	overflow: hidden;
}
.ht-bar i {
	display: block;
	height: 100%;
	width: 0;
	background: linear-gradient(90deg, #00c389, #7ce7ff);
	animation: ht-fill 10s infinite;
}
@keyframes ht-fill {
	0%,
	24% {
		width: 0;
	}
	40%,
	88% {
		width: 100%;
	}
	100% {
		width: 100%;
	}
}
.hr {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 8px;
	padding: 12px 18px 18px;
	border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.hr div {
	padding: 10px 12px;
	border-radius: 10px;
	background: rgba(255, 255, 255, 0.04);
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.07);
	font: 400 10px/1 var(--font-mono);
	color: #9aa3ae;
}
.hr div b {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-top: 8px;
	font: 400 13px/1 var(--font-display);
	color: #fff;
}
.hr div b::before {
	content: '';
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: #00c389;
	box-shadow: 0 0 0 3px rgba(0, 195, 137, 0.2);
}
.hr div span {
	display: flex;
	gap: 2px;
	align-items: flex-end;
	height: 16px;
	margin-top: 9px;
}
.hr div span i {
	flex: 1;
	border-radius: 1px;
	background: rgba(124, 231, 255, 0.55);
}
