/* ============================================
   Job Application History Mobile
   ============================================ */

.history-guest-screen {
	min-height: calc(100vh - 154px);
	padding: 16px 16px 96px;
	background: #f4f4f5;
}

.history-login-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
	width: 100%;
	padding: 16px;
	background: #ffffff;
	border: 1px solid #e4e4e7;
	border-radius: 12px;
	box-shadow:
		0 1px 3px rgba(16, 24, 40, 0.1),
		0 1px 2px -1px rgba(0, 0, 0, 0.1);
}

.history-login-copy {
	width: 100%;
	color: #09090b;
	text-align: center;
}

.history-login-copy h1 {
	margin: 0 0 4px;
	overflow: hidden;
	font-size: 16px;
	font-weight: 600;
	line-height: 24px;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.history-login-copy p {
	max-width: 296px;
	margin: 0 auto;
	font-size: 12px;
	font-weight: 400;
	line-height: 16px;
}

.history-whatsapp-login {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	min-height: 40px;
	padding: 8px 16px;
	color: #18181b;
	background: #f4f4f5;
	border: 0;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 500;
	line-height: 20px;
}

.history-whatsapp-login i {
	font-size: 16px;
	line-height: 1;
}

.history-account-screen {
	display: flex;
	flex-direction: column;
	height: calc(100vh - 154px);
	min-height: 0;
	color: #09090b;
	overflow: hidden;
}

.history-empty-state span {
	margin: 0;
	color: #18181b;
	font-size: 14px;
	line-height: 20px;
}

.history-empty-state {
	display: flex;
	align-items: center;
	flex-direction: column;
	gap: 8px;
	padding: 64px 24px;
	text-align: center;
}

.history-empty-state strong {
	color: #09090b;
	font-size: 16px;
}

.history-search {
	padding: 16px;
	border-bottom: 1px solid rgba(39, 71, 84, 0.1);
}
.history-search input {
	width: 100%;
	min-height: 40px;
	padding: 10px 12px 10px 40px;
	border: 1px solid #e4e4e7;
	border-radius: 8px;
	font-size: 14px;
}
.history-search .bi-search {
	color: #71717a;
	font-size: 1rem;
}
.history-tabs,
.history-detail-tabs {
	display: flex;
	gap: 4px;
	margin: 16px;
	padding: 4px;
	background: #f4f4f5;
	border-radius: 8px;
}
.history-tabs button,
.history-detail-tabs button {
	flex: 1;
	padding: 6px 12px;
	border: 0;
	border-radius: 4px;
	background: transparent;
	color: #71717a;
	font-size: 14px;
}
.history-tabs button.is-active,
.history-detail-tabs button.is-active {
	background: #fff;
	color: #09090b;
	box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
}
.history-card-list {
	flex: 1 1 auto;
	min-height: 0;
	overflow-y: auto;
	padding: 0 16px 16px;
	background: #f4f4f5;
}
.history-card-list > [data-history-items] {
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.history-status-badge {
	display: inline-flex;
	align-self: flex-start;
	padding: 3px 8px;
	border-radius: 999px;
	font-size: 10px;
	font-weight: 600;
	line-height: 12px;
}
.history-status-badge.is-applied,
.history-status-badge.is-offering,
.history-status-badge.is-stage {
	color: #a1a1aa;
	background: #2747541a;
}
.history-status-badge.is-screening,
.history-status-badge.is-assessment {
	color: #a16207;
	background: #e8c46880;
}
.history-status-badge.is-hired {
	color: #047857;
	background: #2a9d901a;
}
.history-status-badge.is-rejected {
	color: #ef4444;
	background: #dc26261f;
}
.history-empty-state--compact {
	align-items: stretch;
	gap: 16px;
	padding: 16px;
	background: #fff;
	border: 1px solid #e4e4e7;
	border-radius: 12px;
	box-shadow:
		0 1px 3px rgba(16, 24, 40, 0.1),
		0 1px 2px -1px rgba(0, 0, 0, 0.1);
}
.history-empty-state-content {
	display: flex;
	flex-direction: column;
	gap: 4px;
	color: #09090b;
	text-align: center;
}
.history-empty-state-content strong {
	overflow: hidden;
	font-size: 16px;
	line-height: 24px;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.history-empty-state-content span {
	font-size: 12px;
	line-height: 16px;
}
.history-empty-state-action {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 40px;
	padding: 8px 16px;
	color: #18181b;
	background: #f4f4f5;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 500;
	line-height: 20px;
	text-decoration: none;
}
.history-empty-state-action i {
	font-size: 16px;
	line-height: 1;
}
.history-detail-screen {
	min-height: calc(100vh - 74px);
	padding-bottom: 120px;
	background: #f4f4f5;
}
.history-detail-tabs {
	margin: 0;
	padding: 4px;
	border-radius: 8px;
}
.history-detail-tabs-section {
	padding: 16px;
	margin-top: 2px;
	margin-bottom: 8px;
	background: #fff;
}
.history-detail-panel {
	display: none;
	padding: 16px;
	background: #fff;
}
.history-detail-panel.is-active {
	display: block;
}

.history-detail-panel.job-detail {
	padding: 0;
	background: #f4f4f5;
}

.history-detail-panel h3 {
	margin: 0 0 16px;
	color: #3f3f46;
	font-size: 12px;
}
.history-timeline {
	position: relative;
}
.history-timeline:before {
	position: absolute;
	top: 8px;
	bottom: 8px;
	left: 8px;
	border-left: 1px dashed #a1a1aa;
	content: "";
}
.history-timeline-item {
	position: relative;
	display: flex;
	gap: 16px;
	margin-bottom: 24px;
}
.history-timeline-marker {
	z-index: 1;
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	margin-top: 2px;
	background: #d4d4d8;
	border-radius: 50%;
}
.history-timeline-item.is-current .history-timeline-marker {
	background: #fff;
	border: 3px solid #feb022;
}
.history-timeline-content {
	flex: 1;
	min-width: 0;
}
.history-timeline-heading {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 8px;
}
.history-timeline-heading time {
	color: #71717a;
	font-size: 12px;
	text-align: right;
}
.history-timeline-content p {
	margin: 8px 0 0;
	font-size: 12px;
	line-height: 16px;
	white-space: pre-line;
}
.history-incomplete-notice {
	color: #71717a;
	font-size: 12px;
}
.history-detail-footer {
	position: fixed;
	right: 0;
	bottom: 0;
	left: 50%;
	z-index: 1040;
	display: flex;
	flex-direction: column;
	gap: 8px;
	width: 100%;
	max-width: 430px;
	transform: translateX(-50%);
	padding: 16px;
	background: #fff;
	border-bottom: 1px solid #e3e3e3;
	box-shadow: 0 0 12px rgba(0, 0, 0, 0.12);
}
.history-detail-share {
	width: 100%;
}
.history-detail-share button {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	width: 100%;
	height: 40px;
	padding: 8px 16px;
	color: #18181b;
	background: #f4f4f5;
	border: 0;
	border-radius: 8px;
	font-size: 14px;
	font-weight: 500;
	line-height: 20px;
}
.history-job-card-link {
	margin: 0;
}
.history-job-card {
	margin-bottom: 0;
	padding: 12px;
}
.history-job-card .job-card-header {
	padding: 0;
}
.history-job-card .job-header-content {
	width: 100%;
}
.history-job-card .job-title {
	margin: 8px 0 4px;
	font-size: 14px;
	line-height: 20px;
}
.history-job-card .job-location {
	margin-bottom: 0;
	color: #3f3f46;
}
.history-job-card .job-footer {
	margin-top: 12px;
	margin-bottom: 0;
}
.history-job-card .time-badge {
	flex-shrink: 0;
}

/* ------------------------------------------------------------------
   Attention & pending actions (Scope 1)
   Visual state is semantic: active/current highlighted, pending attention,
   resolved success + dimmed, past/info neutral and non-actionable.
   ------------------------------------------------------------------ */
.history-card-badges {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
}

.history-attention-badge {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 2px 8px;
	border-radius: 999px;
	background: #fff4e5;
	color: #b45309;
	font-size: 11px;
	font-weight: 600;
}

.history-attention-filter {
	margin: 12px;
}

.history-attention-filter-button {
	border: 1px solid #e4e4e7;
	background: #fff;
	color: #3f3f46;
	border-radius: 999px;
	padding: 6px 14px;
	font-size: 13px;
	font-weight: 500;
}

.history-attention-filter-button.is-active {
	border-color: #b45309;
	background: #fff4e5;
	color: #b45309;
}

.attention-card {
	margin-top: 12px;
	padding: 12px;
	border: 1px solid #e4e4e7;
	border-radius: 12px;
	background: #fff;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.attention-card.is-dimmed {
	background: #fafafa;
	color: #71717a;
}

.attention-card.is-pending {
	border-color: #f0b775;
	box-shadow: 0 0 0 1px rgba(240, 183, 117, 0.25);
}

.attention-card.is-resolved {
	border-color: #b7e4d0;
}

.attention-card-meta {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}

.attention-chip {
	display: inline-flex;
	align-items: center;
	padding: 2px 8px;
	border-radius: 999px;
	background: #f4f4f5;
	color: #52525b;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.02em;
}

.attention-state {
	font-size: 11px;
	font-weight: 600;
	color: #71717a;
}

.attention-title {
	margin: 0;
	font-size: 14px;
	line-height: 20px;
	font-weight: 600;
	overflow-wrap: anywhere;
}

.attention-description {
	margin: 0;
	font-size: 13px;
	line-height: 19px;
	color: #52525b;
	overflow-wrap: anywhere;
}

.attention-deadline {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	font-weight: 500;
	color: #b45309;
}

.attention-action {
	align-self: stretch;
}

.history-detail-primary {
	width: 100%;
}

.history-detail-secondary {
	margin-top: 8px;
	text-align: center;
}

.history-detail-secondary-link {
	font-size: 13px;
	font-weight: 500;
	color: #52525b;
}

.bottom-nav-icon-wrap {
	position: relative;
}

.bottom-nav-badge {
	position: absolute;
	top: -4px;
	right: -8px;
	min-width: 16px;
	height: 16px;
	padding: 0 4px;
	border-radius: 999px;
	background: #dc2626;
	color: #fff;
	font-size: 10px;
	font-weight: 700;
	line-height: 16px;
	text-align: center;
}
