/* ReacThemes HR — Employee Portal styles */

.reachr-portal {
	max-width: 960px;
	margin: 0 auto;
	font-size: 15px;
}

/* ── Navigation ─────────────────────────────────────────── */

.reachr-portal-nav {
	display: flex;
	gap: 0;
	border-bottom: 2px solid #2271b1;
	border-top: none;
	margin-bottom: 24px;
	flex-wrap: wrap;
	align-items: center;
	background: #f6f7f7;
}

.reachr-portal-tab {
	padding: 10px 20px;
	text-decoration: none;
	color: #444;
	font-weight: 500;
	font-size: 14px;
	border-bottom: 2px solid transparent;
	margin-bottom: -2px;
	transition: color 0.15s, border-color 0.15s;
}

.reachr-portal-tab:hover {
	color: #2271b1;
}

.reachr-portal-tab--active {
	color: #2271b1;
	border-bottom-color: #2271b1;
}

/* ── Notices ─────────────────────────────────────────────── */

.reachr-portal-notice {
	background: #f0f6fc;
	border-left: 4px solid #2271b1;
	padding: 16px 20px;
	border-radius: 0 4px 4px 0;
	margin-bottom: 16px;
}

.reachr-portal-notice.reachr-portal-error {
	background: #fce8e8;
	border-left-color: #d63638;
}

/* ── Greeting ────────────────────────────────────────────── */

.reachr-portal-greeting {
	font-size: 20px;
	font-weight: 600;
	color: #1d2327;
	margin-bottom: 20px;
	display: flex;
	align-items: center;
	gap: 10px;
}

.reachr-portal-emp-id {
	font-size: 12px;
	font-weight: 400;
	background: #f0f0f1;
	color: #646970;
	padding: 3px 10px;
	border-radius: 20px;
}

/* ── Summary cards ───────────────────────────────────────── */

.reachr-portal-cards {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	margin-bottom: 24px;
}

.reachr-portal-card {
	flex: 1;
	min-width: 160px;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 6px;
	padding: 16px 20px;
	display: flex;
	flex-direction: column;
	gap: 6px;
	box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.reachr-portal-card__label {
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #646970;
}

.reachr-portal-card__value {
	font-size: 22px;
	font-weight: 700;
	color: #1d2327;
}

/* ── Two-column row ──────────────────────────────────────── */

.reachr-portal-row {
	display: flex;
	gap: 20px;
	flex-wrap: wrap;
	margin-bottom: 24px;
}

.reachr-portal-box {
	flex: 1;
	min-width: 260px;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 6px;
	padding: 20px;
	box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.reachr-portal-box h3 {
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #646970;
	margin: 0 0 12px;
	padding-bottom: 8px;
	border-bottom: 1px solid #f0f0f1;
}

/* ── Key-value table ─────────────────────────────────────── */

.reachr-portal-kv {
	width: 100%;
	border-collapse: collapse;
}

.reachr-portal-kv th,
.reachr-portal-kv td {
	padding: 5px 4px;
	font-size: 13px;
	text-align: left;
	vertical-align: top;
}

.reachr-portal-kv th {
	color: #646970;
	font-weight: 400;
	width: 44%;
	white-space: nowrap;
}

/* ── Section title ───────────────────────────────────────── */

.reachr-portal-section-title {
	font-size: 16px;
	font-weight: 600;
	margin: 0 0 16px;
	color: #1d2327;
}

/* ── Data table ──────────────────────────────────────────── */

.reachr-portal-table-wrap {
	overflow-x: auto;
	border: 1px solid #ddd;
	border-radius: 6px;
	margin-bottom: 16px;
}

.reachr-portal-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
}

.reachr-portal-table thead th {
	background: #2271b1;
	color: #fff;
	padding: 10px 12px;
	text-align: left;
	font-size: 12px;
	font-weight: 600;
	white-space: nowrap;
}

.reachr-portal-table tbody tr:nth-child(even) {
	background: #f9f9f9;
}

.reachr-portal-table tbody td {
	padding: 10px 12px;
	border-bottom: 1px solid #f0f0f1;
	font-size: 13px;
}

.reachr-portal-table__totals td {
	background: #f6f7f7;
	font-weight: 600;
	padding: 10px 12px;
	font-size: 13px;
	border-top: 2px solid #ddd;
}

/* ── Loan progress bar ───────────────────────────────────── */

.reachr-portal-progress {
	background: #f0f0f1;
	border-radius: 4px;
	height: 6px;
	overflow: hidden;
	margin: 10px 0 4px;
}

.reachr-portal-progress__bar {
	background: #2271b1;
	height: 100%;
	border-radius: 4px;
	transition: width 0.3s;
}

/* ── Pagination ──────────────────────────────────────────── */

.reachr-portal-pagination {
	display: flex;
	align-items: center;
	gap: 12px;
	justify-content: center;
	margin-top: 8px;
	font-size: 13px;
	color: #646970;
}

/* ── Buttons ─────────────────────────────────────────────── */

.reachr-portal-btn {
	display: inline-block;
	padding: 8px 18px;
	background: #2271b1;
	color: #fff;
	text-decoration: none;
	border-radius: 4px;
	font-size: 14px;
	font-weight: 500;
	margin-top: 12px;
	border: none;
	cursor: pointer;
	transition: background 0.15s;
}

.reachr-portal-btn:hover {
	background: #135e96;
	color: #fff;
}

.reachr-portal-btn--sm {
	padding: 5px 12px;
	font-size: 12px;
	margin-top: 0;
}

.reachr-portal-btn--xs {
	padding: 3px 10px;
	font-size: 11px;
	margin-top: 0;
}

/* ── Utilities ───────────────────────────────────────────── */

.green { color: #00a32a; }
.blue  { color: #2271b1; }
.red   { color: #d63638; }
.reachr-muted { color: #9ca3af; }
.muted { color: #9ca3af; }

.reachr-portal-empty {
	color: #646970;
	font-style: italic;
	padding: 12px 0;
}

/* ── Badges ──────────────────────────────────────────────── */

.reachr-badge {
	display: inline-block;
	padding: 2px 8px;
	border-radius: 20px;
	font-size: 11px;
	font-weight: 600;
	white-space: nowrap;
}

.reachr-badge--green  { background: #d1fae5; color: #065f46; }
.reachr-badge--blue   { background: #dbeafe; color: #1e40af; }
.reachr-badge--red    { background: #fee2e2; color: #991b1b; }
.reachr-badge--orange { background: #fff7ed; color: #9a3412; }
.reachr-badge--gray   { background: #f3f4f6; color: #374151; }

/* ── Status badges ───────────────────────────────────────── */

.reachr-status {
	display: inline-block;
	padding: 2px 10px;
	border-radius: 20px;
	font-size: 11px;
	font-weight: 600;
	white-space: nowrap;
}

.reachr-status--present { background: #d1fae5; color: #065f46; }
.reachr-status--absent  { background: #fee2e2; color: #991b1b; }
.reachr-status--half    { background: #fff7ed; color: #9a3412; }
.reachr-status--leave   { background: #e0e7ff; color: #3730a3; }

/* ── Upcoming holidays ───────────────────────────────────── */

.reachr-att-holidays {
	margin-bottom: 20px;
}

.reachr-att-holidays__title {
	font-size: 13px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #646970;
	margin-bottom: 10px;
}

.reachr-att-holidays__list {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.reachr-att-hday {
	flex: 1;
	min-width: 160px;
	background: #fff;
	border: 1px solid #e5e7eb;
	border-left: 4px solid #9ca3af;
	border-radius: 6px;
	padding: 10px 14px;
}

.reachr-att-hday--today {
	border-left-color: #00a32a;
	background: #f0fdf4;
}

.reachr-att-hday--soon {
	border-left-color: #f59e0b;
	background: #fffbeb;
}

.reachr-att-hday__date {
	font-size: 11px;
	color: #6b7280;
	margin-bottom: 2px;
}

.reachr-att-hday__name {
	font-size: 13px;
	font-weight: 600;
	color: #1d2327;
	margin-bottom: 6px;
}

.reachr-att-hday__badges {
	display: flex;
	gap: 4px;
	flex-wrap: wrap;
}

/* ── Today off notice ────────────────────────────────────── */

.reachr-att-offday {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 14px 18px;
	border-radius: 8px;
	margin-bottom: 20px;
	border: 1px solid transparent;
}

.reachr-att-offday--holiday {
	background: #eff6ff;
	border-color: #bfdbfe;
}

.reachr-att-offday--weekend {
	background: #fffbeb;
	border-color: #fde68a;
}

.reachr-att-offday__icon {
	font-size: 24px;
	flex-shrink: 0;
}

.reachr-att-offday__sub {
	font-size: 11px;
	color: #6b7280;
	margin-left: 8px;
}

.reachr-att-offday__msg {
	font-size: 13px;
	color: #374151;
	margin-top: 2px;
}

/* ── Timer card ──────────────────────────────────────────── */

.reachr-timer-card {
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 10px;
	overflow: hidden;
	margin-bottom: 24px;
	box-shadow: 0 2px 8px rgba(0,0,0,.07);
}

.reachr-timer-card__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px;
	padding: 14px 20px;
	border-bottom: 1px solid #f0f0f1;
	background: #f9fafb;
}

.reachr-timer-card__date {
	font-size: 15px;
	font-weight: 600;
	color: #1d2327;
}

.reachr-timer-card__office {
	font-size: 12px;
	color: #6b7280;
	margin-top: 2px;
}

.reachr-timer-card__checkin-info {
	display: flex;
	align-items: center;
	gap: 6px;
	flex-wrap: wrap;
}

.reachr-timer-card__checkin-label {
	font-size: 12px;
	color: #6b7280;
}

.reachr-timer-card__checkin-time {
	font-size: 15px;
	font-weight: 700;
	color: #1d2327;
}

.reachr-timer-card__body {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 28px 20px 24px;
	gap: 20px;
}

/* ── Timer display ───────────────────────────────────────── */

.reachr-timer-display {
	text-align: center;
}

.reachr-timer-display__label {
	font-size: 11px;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: #9ca3af;
	margin-bottom: 4px;
}

.reachr-timer-display__clock {
	font-size: 48px;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	letter-spacing: -1px;
	color: #2271b1;
	line-height: 1;
}

.reachr-timer-display--paused .reachr-timer-display__clock {
	color: #d97706;
}

.reachr-timer-display--done .reachr-timer-display__clock {
	color: #1d2327;
}

.reachr-timer-display__dot {
	margin-top: 6px;
	font-size: 12px;
	font-weight: 600;
}

.reachr-timer-display__dot--live {
	color: #00a32a;
	animation: reachrPulseTxt 2s infinite;
}

.reachr-timer-display__dot--paused {
	color: #d97706;
}

@keyframes reachrPulseTxt {
	0%, 100% { opacity: 1; }
	50%       { opacity: 0.4; }
}

/* ── Timer action buttons ────────────────────────────────── */

.reachr-timer-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	justify-content: center;
}

.reachr-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 10px 28px;
	border-radius: 6px;
	border: none;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: opacity 0.15s, transform 0.1s;
	letter-spacing: 0.2px;
	min-width: 130px;
}

.reachr-btn:active {
	transform: scale(0.97);
}

.reachr-btn--checkin {
	background: #00a32a;
	color: #fff;
}

.reachr-btn--checkin:hover {
	background: #007a1e;
	color: #fff;
}

.reachr-btn--pause {
	background: #fff7ed;
	color: #d97706;
	border: 2px solid #fbbf24;
}

.reachr-btn--pause:hover {
	background: #fef3c7;
}

.reachr-btn--resume {
	background: #00a32a;
	color: #fff;
}

.reachr-btn--resume:hover {
	background: #007a1e;
	color: #fff;
}

.reachr-btn--checkout {
	background: #f3f4f6;
	color: #374151;
	border: 1px solid #d1d5db;
}

.reachr-btn--checkout:hover {
	background: #e5e7eb;
}

/* ── Timer done / day-off ────────────────────────────────── */

.reachr-timer-done {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 15px;
	font-weight: 600;
	color: #065f46;
	background: #d1fae5;
	padding: 10px 24px;
	border-radius: 6px;
}

.reachr-timer-done small {
	font-size: 12px;
	font-weight: 400;
	color: #374151;
}

/* ── Live dot in table ───────────────────────────────────── */

.reachr-live-dot {
	color: #00a32a;
	font-size: 11px;
	font-weight: 600;
	animation: reachrPulseTxt 2s infinite;
}

/* ── Attendance table specifics ──────────────────────────── */

.reachr-att-month-title {
	font-size: 15px;
	font-weight: 600;
	color: #1d2327;
	margin: 0 0 12px;
}

.reachr-att-table .reachr-att-date {
	white-space: nowrap;
}

.reachr-att-star {
	color: #f59e0b;
	margin-left: 4px;
}

.reachr-att-tag {
	display: block;
	font-size: 10px;
	font-weight: 500;
	margin-top: 1px;
}

.reachr-att-tag--hol  { color: #1e40af; }
.reachr-att-tag--wknd { color: #6b7280; }

.reachr-att-time,
.reachr-att-dur {
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

.reachr-att-row--today   { font-weight: 600; }
.reachr-att-row--holiday { background: #eff6ff !important; }
.reachr-att-row--weekend { background: #f9fafb !important; }

/* ── Responsive ──────────────────────────────────────────── */

@media (max-width: 640px) {
	.reachr-portal-cards {
		flex-direction: column;
	}
	.reachr-portal-row {
		flex-direction: column;
	}
	.reachr-portal-tab {
		padding: 8px 12px;
		font-size: 13px;
	}
	.reachr-timer-display__clock {
		font-size: 36px;
	}
	.reachr-btn {
		min-width: 110px;
		padding: 9px 18px;
		font-size: 13px;
	}
	.reachr-att-holidays__list {
		flex-direction: column;
	}
	.reachr-timer-card__header {
		flex-direction: column;
		align-items: flex-start;
	}
}

/* ── Leave Balance Card ──────────────────────────────────── */

.reachr-leave-balance-card {
	background: linear-gradient(135deg, #1e40af 0%, #2271b1 100%);
	border-radius: 10px;
	padding: 20px 24px;
	margin-bottom: 20px;
	color: #fff;
}

.reachr-leave-balance-card__title {
	font-size: 12px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .6px;
	opacity: .8;
	margin-bottom: 8px;
}

.reachr-leave-balance-card__nums {
	display: flex;
	align-items: baseline;
	gap: 12px;
	flex-wrap: wrap;
	margin-bottom: 12px;
}

.reachr-leave-balance-card__nums .used {
	font-size: 28px;
	font-weight: 700;
}

.reachr-leave-balance-card__nums .sep {
	font-size: 20px;
	opacity: .5;
}

.reachr-leave-balance-card__nums .quota {
	font-size: 15px;
	opacity: .7;
}

.reachr-leave-balance-card__nums .remaining {
	margin-left: auto;
	background: rgba(255,255,255,.2);
	padding: 4px 14px;
	border-radius: 20px;
	font-size: 13px;
	font-weight: 600;
}

.reachr-leave-balance-card__nums .remaining.is-zero {
	background: rgba(239,68,68,.3);
}

.reachr-leave-bar {
	height: 8px;
	background: rgba(255,255,255,.25);
	border-radius: 99px;
	overflow: hidden;
}

.reachr-leave-bar__fill {
	height: 100%;
	border-radius: 99px;
	background: rgba(255,255,255,.9);
	transition: width .4s;
}

.reachr-leave-bar__fill.is-warn { background: #fbbf24; }
.reachr-leave-bar__fill.is-over { background: #f87171; }

/* ── Leave Apply Card ────────────────────────────────────── */

.reachr-leave-apply-card {
	background: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 10px;
	overflow: hidden;
	margin-bottom: 24px;
	box-shadow: 0 1px 4px rgba(0,0,0,.06);
}

.reachr-leave-apply-card__head {
	background: #f9fafb;
	border-bottom: 1px solid #e5e7eb;
	padding: 12px 20px;
	font-size: 13px;
	font-weight: 600;
	color: #374151;
	text-transform: uppercase;
	letter-spacing: .4px;
}

.reachr-leave-form {
	padding: 18px 20px;
}

.reachr-leave-form__row {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin-bottom: 14px;
	align-items: flex-end;
}

.reachr-leave-form__field {
	display: flex;
	flex-direction: column;
	gap: 5px;
	flex: 1;
	min-width: 140px;
}

.reachr-leave-form__field--full {
	width: 100%;
	flex: unset;
}

.reachr-leave-form__field--days {
	flex: 0 0 90px;
	min-width: 80px;
}

.reachr-leave-form__field label {
	font-size: 11px;
	font-weight: 700;
	color: #6b7280;
	text-transform: uppercase;
	letter-spacing: .4px;
}

.reachr-leave-form__field input,
.reachr-leave-form__field select,
.reachr-leave-form__field textarea {
	padding: 8px 10px;
	border: 1px solid #d1d5db;
	border-radius: 6px;
	font-size: 13px;
	color: #1d2327;
	width: 100%;
	box-sizing: border-box;
}

.reachr-leave-form__field textarea {
	resize: vertical;
	min-height: 58px;
}

.reachr-leave-form__field input:focus,
.reachr-leave-form__field select:focus,
.reachr-leave-form__field textarea:focus {
	border-color: #2271b1;
	outline: 2px solid #2271b120;
}

.reachr-leave-days-badge {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 38px;
	background: #f3f4f6;
	border: 1px solid #d1d5db;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 700;
	color: #374151;
}

/* ── Half Day ────────────────────────────────────────────── */

.reachr-halfday-row {
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
	margin-bottom: 14px;
	padding: 10px 14px;
	background: #f9fafb;
	border: 1px solid #e5e7eb;
	border-radius: 6px;
}

.reachr-halfday-toggle {
	display: flex;
	align-items: center;
	gap: 8px;
	cursor: pointer;
	user-select: none;
}

.reachr-halfday-toggle input[type="checkbox"] {
	width: 16px;
	height: 16px;
	accent-color: #2271b1;
	cursor: pointer;
}

.reachr-halfday-toggle__label {
	font-size: 13px;
	font-weight: 600;
	color: #374151;
}

.reachr-halfday-options {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}

.reachr-halfday-opt {
	display: flex;
	align-items: center;
	gap: 6px;
	font-size: 13px;
	color: #374151;
	cursor: pointer;
	padding: 5px 12px;
	border: 1.5px solid #d1d5db;
	border-radius: 6px;
	background: #fff;
	transition: border-color .15s, background .15s;
}

.reachr-halfday-opt:has(input:checked) {
	border-color: #2271b1;
	background: #eff6ff;
	color: #1e40af;
}

.reachr-halfday-opt input[type="radio"] {
	accent-color: #2271b1;
}

@media (max-width: 640px) {
	.reachr-leave-form__row { flex-direction: column; }
	.reachr-leave-form__field--days { flex: unset; width: 100%; }
	.reachr-leave-balance-card__nums .remaining { margin-left: 0; }
	.reachr-halfday-row { flex-direction: column; align-items: flex-start; }
}
