.life-workspace {
	padding: 18px 18px 24px;
}

.life-workspace .page-head,
.life-workspace .tool-surface {
	width: 100%;
	max-width: 1180px;
}

.life-tool {
	display: grid;
	gap: 12px;
}

.life-panel {
	border: 1px solid var(--line);
	border-radius: 8px;
	background: var(--panel);
	box-shadow: var(--shadow);
	overflow: hidden;
}

.life-panel-head {
	min-height: 46px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 0 14px;
	border-bottom: 1px solid #e2e6f0;
	background: #ffffff;
}

.life-panel-title {
	margin: 0;
	color: #0f1f35;
	font-size: 15px;
	font-weight: 800;
	line-height: 1.3;
}

.life-meta {
	color: #1f6c8f;
	font-size: 12px;
	font-weight: 800;
	line-height: 1.3;
	text-align: right;
}

.life-form {
	display: grid;
	gap: 14px;
	padding: 14px;
}

.life-field-grid {
	display: grid;
	grid-template-columns: minmax(140px, .8fr) minmax(110px, .6fr) minmax(120px, .7fr) minmax(220px, 1.5fr);
	gap: 12px;
	align-items: end;
}

.life-form label {
	display: grid;
	gap: 6px;
	min-width: 0;
}

.life-form label span,
.countdown-grid span,
.countdown-state small,
.progress-value span {
	color: #5b667a;
	font-size: 12px;
	font-weight: 800;
	line-height: 1.35;
}

.date-input-wrap {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr) 40px;
	gap: 6px;
	min-width: 0;
}

.life-form input[type="text"],
.life-form input[type="time"],
.life-form select {
	width: 100%;
	height: 40px;
	border: 1px solid #cfd6e6;
	border-radius: 7px;
	background: #ffffff;
	color: #111827;
	padding: 0 10px;
	outline: 0;
}

.native-date-picker {
	position: absolute;
	right: 0;
	bottom: 0;
	width: 40px;
	height: 40px;
	opacity: 0;
	pointer-events: none;
}

.date-picker-button {
	width: 40px;
	height: 40px;
	border: 1px solid #c7cedf;
	border-radius: 7px;
	background: #ffffff;
	color: #223651;
	display: inline-grid;
	place-items: center;
}

.date-picker-button:hover {
	background: #eef2fb;
}

.date-picker-button:focus-visible {
	outline: 0;
	border-color: #2f6fed;
	box-shadow: 0 0 0 3px rgba(47, 111, 237, 0.13);
}

.date-picker-icon {
	width: 18px;
	height: 18px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.life-form select {
	padding-right: 30px;
}

.life-form input:focus,
.life-form select:focus {
	border-color: #2f6fed;
	box-shadow: 0 0 0 3px rgba(47, 111, 237, 0.13);
}

.life-form-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
}

.save-toggle {
	min-height: 38px;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: #344054;
	font-weight: 750;
}

.save-toggle input {
	width: 16px;
	height: 16px;
	margin: 0;
	accent-color: #2f6fed;
}

.life-actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 8px;
}

.life-button {
	min-height: 38px;
	border: 1px solid #c7cedf;
	border-radius: 7px;
	background: #ffffff;
	color: #111827;
	font-weight: 800;
	padding: 0 14px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	white-space: nowrap;
}

.life-button.primary {
	background: #2458d6;
	color: #ffffff;
	border-color: #1d4cbc;
}

.life-button:hover {
	background: #eef2fb;
}

.life-button.primary:hover {
	background: #1d4cbc;
}

.life-message {
	min-height: 20px;
	margin: 0;
	color: #3f5576;
	font-size: 13px;
	line-height: 1.45;
}

.life-message.is-error {
	color: #c2410c;
	font-weight: 750;
}

.life-result {
	display: grid;
	gap: 12px;
}

.life-countdown-panel {
	position: relative;
	display: grid;
	grid-template-columns: minmax(280px, .9fr) minmax(0, 1.1fr);
	gap: 12px;
	border: 1px solid #cdd8ea;
	border-radius: 8px;
	background: linear-gradient(135deg, #ffffff 0%, #f7fbff 56%, #fff9ef 100%);
	box-shadow: var(--shadow);
	padding: 16px;
	overflow: hidden;
}

.life-countdown-panel::before {
	content: "";
	position: absolute;
	inset: 0 auto 0 0;
	width: 5px;
	background: linear-gradient(180deg, #2458d6, #13a06f, #d97706);
}

.countdown-state {
	display: grid;
	align-content: center;
	gap: 8px;
	min-width: 0;
	padding-left: 5px;
}

.countdown-state span {
	color: #28506f;
	font-size: 13px;
	font-weight: 850;
	line-height: 1.35;
}

.countdown-state strong {
	color: #091527;
	font-family: var(--font-mono);
	font-size: clamp(34px, 6vw, 62px);
	font-weight: 850;
	line-height: 1;
	letter-spacing: 0;
	overflow-wrap: anywhere;
}

.countdown-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 10px;
}

.countdown-grid article {
	display: grid;
	align-content: center;
	min-height: 116px;
	border: 1px solid #dbe2ed;
	border-radius: 8px;
	background: rgba(255, 255, 255, .86);
	padding: 12px;
	min-width: 0;
}

.countdown-grid strong {
	display: block;
	margin-top: 8px;
	color: #0c1728;
	font-family: var(--font-mono);
	font-size: 26px;
	font-weight: 850;
	line-height: 1.12;
	letter-spacing: 0;
	overflow-wrap: anywhere;
}

.life-progress-body {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 140px;
	align-items: center;
	gap: 14px;
	padding: 14px;
}

.progress-track {
	position: relative;
	height: 18px;
	border-radius: 999px;
	background: #e8edf5;
	overflow: hidden;
}

.progress-track span {
	position: absolute;
	inset: 0 auto 0 0;
	width: 0;
	border-radius: inherit;
	background: linear-gradient(90deg, #2458d6, #13a06f 58%, #d97706);
	transition: width .25s ease;
}

.progress-value {
	display: grid;
	gap: 4px;
	justify-items: end;
	min-width: 0;
}

.progress-value strong {
	color: #0f1f35;
	font-family: var(--font-mono);
	font-size: 20px;
	line-height: 1.1;
	overflow-wrap: anywhere;
}

.life-detail-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 10px;
	margin: 0;
	padding: 14px;
}

.life-detail-grid div {
	border: 1px solid #dbe2ed;
	border-radius: 8px;
	background: #ffffff;
	padding: 12px;
	min-width: 0;
}

.life-detail-grid dt {
	color: #667085;
	font-size: 12px;
	font-weight: 800;
	line-height: 1.35;
}

.life-detail-grid dd {
	margin: 7px 0 0;
	color: #102033;
	font-size: 17px;
	font-weight: 850;
	line-height: 1.25;
	overflow-wrap: anywhere;
}

.note-panel {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	padding: 14px;
}

.note-panel p {
	margin: 0;
	color: #5b667a;
	font-size: 12px;
	line-height: 1.5;
}

.note-panel a {
	flex: 0 0 auto;
	color: #2458d6;
	font-size: 12px;
	font-weight: 850;
	text-decoration: none;
}

.note-panel a:hover {
	text-decoration: underline;
	text-underline-offset: 3px;
}

@media (max-width: 1080px) {
	.life-field-grid,
	.life-countdown-panel,
	.life-progress-body {
		grid-template-columns: 1fr;
	}

	.life-detail-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.progress-value {
		justify-items: start;
	}
}

@media (max-width: 760px) {
	.life-workspace {
		padding: 16px 12px 22px;
	}

	.life-form-row,
	.note-panel {
		display: grid;
		grid-template-columns: 1fr;
	}

	.life-actions {
		display: grid;
		grid-template-columns: 1fr;
		justify-content: stretch;
	}

	.life-button {
		width: 100%;
	}

	.countdown-grid,
	.life-detail-grid {
		grid-template-columns: 1fr;
	}

	.countdown-grid article {
		min-height: 92px;
	}
}
