.restart-notifier {
	display: none;
}

.restart-notifier.restart-notifier--visible {
	display: block;
	animation: rn-fade-in 220ms ease-out;
}

.restart-notifier__backdrop {
	display: none;
}

.restart-notifier.restart-notifier--modal .restart-notifier__backdrop {
	display: block;
	position: fixed;
	inset: 0;
	background: rgba(15, 23, 42, 0.5);
	backdrop-filter: blur(2px);
	z-index: 5000;
	pointer-events: auto;
}

.restart-notifier__card {
	box-sizing: border-box;
	max-width: 520px;
	padding: 18px 18px 14px;
	border-radius: 14px;
	background: linear-gradient(
		165deg,
		var(--card-bg, #ffffff) 0%,
		color-mix(in srgb, var(--card-bg, #ffffff) 92%, #eff6ff) 100%
	);
	color: var(--text-color, #111);
	box-shadow: 0 14px 38px rgba(15, 23, 42, 0.2);
	border: 1px solid color-mix(in srgb, var(--border-color, rgba(0, 0, 0, 0.12)) 72%, #ffffff);
}

.restart-notifier.restart-notifier--modal .restart-notifier__card {
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	z-index: 5001;
	width: min(92vw, 520px);
	pointer-events: auto;
	animation: rn-modal-pop 230ms cubic-bezier(0.2, 0.85, 0.2, 1);
}

.restart-notifier.restart-notifier--minimized .restart-notifier__card {
	position: fixed;
	top: 18px;
	right: 18px;
	left: auto;
	bottom: auto;
	transform: none;
	z-index: 3999;
	width: auto;
	min-width: 150px;
	max-width: 240px;
	padding: 10px 13px;
	pointer-events: auto;
	animation: rn-chip-slide 180ms ease-out;
}

.restart-notifier__title-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
}

.restart-notifier__status-dot {
	width: 10px;
	height: 10px;
	border-radius: 999px;
	background: #f59e0b;
	box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.2);
	flex: 0 0 auto;
}

.restart-notifier__title {
	font-weight: 700;
	font-size: 15px;
	letter-spacing: 0.01em;
	margin-bottom: 4px;
}

.restart-notifier__meta {
	font-size: 12px;
	opacity: 0.78;
	margin-bottom: 8px;
	text-transform: uppercase;
	letter-spacing: 0.05em;
}

.restart-notifier__message {
	font-size: 13px;
	line-height: 1.45;
	margin-bottom: 10px;
}

.restart-notifier__countdown {
	font-variant-numeric: tabular-nums;
	font-size: 20px;
	font-weight: 700;
	letter-spacing: 0.04em;
	margin: 2px 0 0;
	color: #b91c1c;
	text-shadow: 0 0 8px rgba(220, 38, 38, 0.25);
	animation: rn-countdown-breathe 1.8s ease-in-out infinite;
}

.restart-notifier__progress {
	margin-top: 8px;
}

.restart-notifier__progress-head {
	display: flex;
	justify-content: space-between;
	gap: 8px;
	font-size: 12px;
	margin-bottom: 6px;
}

.restart-notifier__progress-pct {
	font-weight: 700;
	color: #0f172a;
}

.restart-notifier__progress-eta {
	opacity: 0.85;
}

.restart-notifier__progress-bar {
	height: 8px;
	border-radius: 999px;
	background: #e2e8f0;
	overflow: hidden;
}

.restart-notifier__progress-fill {
	display: block;
	height: 100%;
	width: 0;
	border-radius: 999px;
	background: linear-gradient(90deg, #0ea5e9, #2563eb);
	transition: width 240ms ease;
}

.restart-notifier.restart-notifier--urgent .restart-notifier__countdown {
	color: #dc2626;
	text-shadow:
		0 0 10px rgba(220, 38, 38, 0.55),
		0 0 20px rgba(239, 68, 68, 0.38);
	animation: rn-countdown-urgent 700ms ease-in-out infinite;
}

.restart-notifier.restart-notifier--urgent .restart-notifier__card {
	border-color: #fca5a5;
	box-shadow: 0 14px 38px rgba(220, 38, 38, 0.2);
}

.restart-notifier.restart-notifier--bilingual .restart-notifier__title,
.restart-notifier.restart-notifier--bilingual .restart-notifier__meta,
.restart-notifier.restart-notifier--bilingual .restart-notifier__message {
	font-family: "Noto Sans Arabic", "Cairo", "Tajawal", "Segoe UI", Arial, sans-serif;
	letter-spacing: 0;
	word-spacing: 0.02em;
	line-height: 1.6;
}

.restart-notifier.restart-notifier--bilingual .restart-notifier__message {
	font-size: 13.5px;
}

@keyframes rn-fade-in {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

@keyframes rn-modal-pop {
	from {
		opacity: 0;
		transform: translate(-50%, -46%) scale(0.96);
	}
	to {
		opacity: 1;
		transform: translate(-50%, -50%) scale(1);
	}
}

@keyframes rn-chip-slide {
	from {
		opacity: 0;
		transform: translateY(-8px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes rn-countdown-breathe {
	0%,
	100% {
		transform: scale(1);
	}
	50% {
		transform: scale(1.03);
	}
}

@keyframes rn-countdown-urgent {
	0%,
	100% {
		transform: scale(1);
		filter: brightness(1);
	}
	50% {
		transform: scale(1.08);
		filter: brightness(1.15);
	}
}

.restart-notifier__actions {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	margin-top: 12px;
}

.server-restart-page {
	padding: 8px 0;
	width: 100%;
}

.server-restart-page__card {
	width: min(1180px, calc(100vw - 72px));
	padding: 22px;
	border-radius: 14px;
	background: var(--card-bg, #ffffff);
	border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
	box-shadow: 0 10px 28px rgba(15, 23, 42, 0.1);
}

.server-restart-page__eyebrow {
	font-size: 12px;
	opacity: 0.7;
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin-bottom: 8px;
}

.server-restart-page__title {
	margin: 0 0 10px;
	font-weight: 700;
}

.server-restart-page__desc {
	margin: 0;
	font-size: 14px;
	line-height: 1.55;
}

.server-restart-page__form {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 12px;
	margin-top: 14px;
}

.server-restart-page__field label {
	display: block;
	font-size: 12px;
	opacity: 0.75;
	margin-bottom: 6px;
}

.server-restart-page__field--wide {
	grid-column: 1 / -1;
}

.server-restart-page__ops {
	border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
	border-radius: 10px;
	padding: 12px;
	background: color-mix(in srgb, var(--card-bg, #fff) 94%, #eef2ff);
}

.server-restart-page__checks {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 8px 12px;
	margin: 10px 0;
}

.server-restart-page__checks label {
	font-size: 13px;
	display: flex;
	align-items: flex-start;
	gap: 8px;
	line-height: 1.4;
}

.server-restart-page__checks input[type="checkbox"] {
	appearance: none;
	-webkit-appearance: none;
	width: 16px;
	height: 16px;
	min-width: 16px;
	min-height: 16px;
	margin: 1px 0 0;
	border: 1.5px solid #94a3b8;
	border-radius: 4px;
	background: #fff;
	display: inline-grid;
	place-content: center;
	cursor: pointer;
	transition: all 120ms ease;
}

.server-restart-page__checks input[type="checkbox"]::before {
	content: "";
	width: 8px;
	height: 8px;
	transform: scale(0);
	transition: transform 120ms ease;
	background: #ffffff;
	clip-path: polygon(14% 44%, 0 65%, 40% 100%, 100% 18%, 82% 0, 38% 62%);
}

.server-restart-page__checks input[type="checkbox"]:checked {
	background: #2563eb;
	border-color: #2563eb;
}

.server-restart-page__checks input[type="checkbox"]:checked::before {
	transform: scale(1);
}

.server-restart-page__checks input[type="checkbox"]:focus-visible {
	outline: 2px solid rgba(37, 99, 235, 0.3);
	outline-offset: 2px;
}

@media (max-width: 900px) {
	.server-restart-page__card {
		width: calc(100vw - 32px);
		padding: 18px;
	}
}

.server-restart-page__status {
	margin-top: 14px;
	padding: 10px 12px;
	border-radius: 10px;
	background: color-mix(in srgb, var(--card-bg, #fff) 92%, #f1f5f9);
	border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
	font-size: 12px;
	line-height: 1.4;
}

.server-restart-page__status--ok {
	border-color: #86efac;
	background: #f0fdf4;
}

.server-restart-page__status--warn {
	border-color: #fdba74;
	background: #fff7ed;
}

.server-restart-page__progress {
	margin-top: 12px;
	padding: 10px 12px;
	border-radius: 10px;
	background: color-mix(in srgb, var(--card-bg, #fff) 94%, #f0f9ff);
	border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
}

.server-restart-page__progress-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	margin-bottom: 8px;
}

.server-restart-page__progress-title {
	font-size: 13px;
	font-weight: 700;
}

.server-restart-page__progress-pct {
	font-size: 12px;
	font-weight: 700;
	color: #0369a1;
}

.server-restart-page__progress-bar {
	height: 10px;
	border-radius: 999px;
	background: #e2e8f0;
	overflow: hidden;
}

.server-restart-page__progress-fill {
	display: block;
	height: 100%;
	width: 0;
	border-radius: 999px;
	background: linear-gradient(90deg, #0284c7, #2563eb);
	transition: width 280ms ease;
}

.server-restart-page__progress-msg {
	margin-top: 8px;
	font-size: 12px;
	line-height: 1.4;
}

.server-restart-page__git {
	margin-top: 14px;
	padding: 12px;
	border-radius: 10px;
	background: color-mix(in srgb, var(--card-bg, #fff) 94%, #ecfeff);
	border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
}

.server-restart-page__git-title {
	font-size: 13px;
	font-weight: 700;
	margin-bottom: 8px;
}

.server-restart-page__git-controls {
	display: grid;
	grid-template-columns: minmax(120px, 1fr) minmax(120px, 1fr) auto auto auto;
	gap: 8px;
	align-items: center;
}

.server-restart-page__git-status {
	margin-top: 10px;
	font-size: 12px;
	line-height: 1.4;
	opacity: 0.9;
}

@media (max-width: 900px) {
	.server-restart-page__git-controls {
		grid-template-columns: 1fr;
	}
}

.server-restart-page__logs {
	margin-top: 14px;
	padding: 12px;
	border-radius: 10px;
	background: color-mix(in srgb, var(--card-bg, #fff) 95%, #f8fafc);
	border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
}

.server-restart-page__logs-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	margin-bottom: 8px;
	flex-wrap: wrap;
}

.server-restart-page__logs-title {
	font-size: 13px;
	font-weight: 700;
}

.server-restart-page__logs-tools {
	display: flex;
	align-items: center;
	gap: 8px;
}

.server-restart-page__logs-meta {
	font-size: 12px;
	opacity: 0.75;
}

.server-restart-page__logs-table-wrap {
	overflow-x: auto;
	max-height: 300px;
	overflow-y: auto;
	border: 1px solid color-mix(in srgb, var(--border-color, rgba(0, 0, 0, 0.12)) 65%, #fff);
	border-radius: 8px;
}

.server-restart-page__logs-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 12px;
}

.server-restart-page__logs-table th,
.server-restart-page__logs-table td {
	padding: 8px;
	border-bottom: 1px solid color-mix(in srgb, var(--border-color, rgba(0, 0, 0, 0.12)) 70%, #fff);
	vertical-align: top;
	text-align: left;
}

.server-restart-page__chip {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 999px;
	font-size: 11px;
	font-weight: 700;
}

.server-restart-page__chip--ok {
	background: #dcfce7;
	color: #166534;
}

.server-restart-page__chip--warn {
	background: #fee2e2;
	color: #991b1b;
}

.server-restart-page__logs-pagination {
	display: flex;
	justify-content: flex-end;
	gap: 6px;
	margin-top: 8px;
}

.server-restart-page__actions {
	margin-top: 16px;
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}
