/* Reusable receipt-row modal shell. Row and hover-card visuals live in receipt-row-shared.css. */

#receipt-row-modal .modal-dialog {
	width: calc(100vw - 16px);
	max-width: 1680px;
}

#receipt-row-modal .modal-content {
	--receipt-row-modal-row-height: 116px;
	--receipt-row-modal-head-height: 52px;
	border-radius: 6px;
	overflow: hidden;
}

.receipt-row-modal-scope {
	--receipt-row-modal-row-height: 116px;
	--receipt-row-modal-head-height: 52px;
}

#receipt-row-modal .modal-header {
	border-bottom-color: #dce7ee;
}

#receipt-row-modal .modal-title {
	display: flex;
	align-items: center;
	gap: 8px;
	min-width: 0;
}

#receipt-row-modal-title-text {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.receipt-row-modal-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 10px 12px;
	border-bottom: 1px solid #dce7ee;
	background: #f7fafc;
}

.receipt-row-modal-view-toggle {
	display: inline-flex;
	align-items: stretch;
	width: auto;
	max-width: 100%;
	vertical-align: middle;
}

.receipt-row-modal-view-toggle .input-group-addon {
	display: flex;
	align-items: center;
	flex: 0 0 auto;
	width: auto;
	white-space: nowrap;
	font-weight: 700;
}

.receipt-row-modal-view-toggle .input-group-btn {
	display: flex;
	align-items: stretch;
	flex: 0 0 auto;
	width: auto;
	white-space: nowrap;
}

.receipt-row-modal-view-toggle .input-group-btn > .btn-group {
	display: inline-flex;
	align-items: stretch;
	flex-wrap: nowrap;
}

.receipt-row-modal-view-toggle .input-group-btn > .btn-group > .btn {
	min-width: 64px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	box-shadow: var(--bs3-btn-shadow-current);
}

.receipt-row-modal-view-toggle .input-group-btn > .btn-group > .btn:hover,
.receipt-row-modal-view-toggle .input-group-btn > .btn-group > .btn:focus-visible {
	box-shadow: var(--bs3-btn-hover-shadow-current);
}

.receipt-row-modal-view-toggle .input-group-btn > .btn-group > .btn:active {
	box-shadow: var(--bs3-btn-active-shadow-current);
}

.receipt-row-modal-view-toggle .input-group-btn > .btn-group > .btn.active {
	box-shadow:
		0 1px 0 color-mix(in srgb, var(--bs3-btn-tone-border-current) 55%, black),
		inset 0 2px 5px color-mix(in srgb, var(--bs3-btn-tone-border-current) 30%, black);
}

.receipt-row-modal-view-toggle .btn[disabled] {
	cursor: not-allowed;
	opacity: 0.52;
	box-shadow: none;
}

.receipt-row-modal-toolbar-right {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 10px;
	min-width: 0;
}

.receipt-row-modal-open-link {
	flex: 0 0 auto;
	font-weight: 700;
	box-shadow: var(--bs3-btn-shadow-current);
}

.receipt-row-modal-open-link:hover,
.receipt-row-modal-open-link:focus-visible {
	box-shadow: var(--bs3-btn-hover-shadow-current);
}

.receipt-row-modal-open-link:active {
	box-shadow: var(--bs3-btn-active-shadow-current);
}

.receipt-row-modal-open-link.disabled,
.receipt-row-modal-open-link[aria-disabled="true"] {
	pointer-events: none;
	cursor: not-allowed;
	opacity: 0.54;
	box-shadow: none;
}

#receipt-row-modal .modal-body {
	padding: 0;
	background: #fff;
}

.receipt-row-modal-body-inner {
	position: relative;
	padding: 12px;
}

.receipt-row-modal-body-inner.is-loading > :not(.receipt-row-modal-loading--overlay) {
	pointer-events: none;
}

.receipt-row-modal-table-scroll {
	width: 100%;
	overflow-x: auto;
	overflow-y: visible;
}

.receipt-row-modal-table {
	min-width: 1080px;
	margin-bottom: 0;
	margin-top: 0 !important;
	border-collapse: collapse !important;
	border-spacing: 0 !important;
	background: #fff !important;
}

#receipt-row-modal #receiptstab.receipt-row-modal-table thead th,
.receipt-row-modal-scope .receipt-row-modal-table thead th {
	height: var(--receipt-row-modal-head-height);
	border-left: 0 !important;
	border-right: 0 !important;
}

#receipt-row-modal #receiptstab.receipt-row-modal-table tbody tr,
.receipt-row-modal-scope .receipt-row-modal-table tbody tr {
	height: var(--receipt-row-modal-row-height);
	background: #fff !important;
	border: 0 !important;
	box-shadow: none !important;
	transform: none !important;
	transition: none !important;
}

#receipt-row-modal #receiptstab.receipt-row-modal-table tbody tr:hover:not(.period-separator),
.receipt-row-modal-scope .receipt-row-modal-table tbody tr:hover:not(.period-separator) {
	background: #fff !important;
	box-shadow: none !important;
	transform: none !important;
}

#receipt-row-modal #receiptstab.receipt-row-modal-table.table-hover > tbody > tr:hover > td,
#receipt-row-modal #receiptstab.receipt-row-modal-table.table-striped > tbody > tr:nth-of-type(odd) > td,
.receipt-row-modal-scope .receipt-row-modal-table.table-hover > tbody > tr:hover > td,
.receipt-row-modal-scope .receipt-row-modal-table.table-striped > tbody > tr:nth-of-type(odd) > td {
	background: #fff !important;
}

#receipt-row-modal #receiptstab.receipt-row-modal-table tbody tr td,
.receipt-row-modal-scope .receipt-row-modal-table tbody tr td {
	height: var(--receipt-row-modal-row-height);
	padding: 12px 8px !important;
	border-top: 1px solid #dce7ee !important;
	border-right: 0 !important;
	border-bottom: 1px solid #dce7ee !important;
	border-left: 0 !important;
	border-radius: 0 !important;
	vertical-align: middle !important;
	background: #fff !important;
}

#receipt-row-modal #receiptstab.receipt-row-modal-table tbody tr td:first-child,
#receipt-row-modal #receiptstab.receipt-row-modal-table tbody tr td:last-child,
.receipt-row-modal-scope .receipt-row-modal-table tbody tr td:first-child,
.receipt-row-modal-scope .receipt-row-modal-table tbody tr td:last-child {
	border-radius: 0 !important;
}

.receipt-row-modal-table tbody td.planning-cell,
.receipt-row-modal-table tbody td.eigene-stunden-cell {
	overflow: visible !important;
}

.receipt-row-modal-loading {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: calc(var(--receipt-row-modal-head-height) + var(--receipt-row-modal-row-height));
	color: #4f6f83;
	font-weight: 700;
}

.receipt-row-modal-loading--overlay {
	position: absolute;
	inset: 12px;
	min-height: 0;
	z-index: 30;
	border-radius: 4px;
	background: rgba(255, 255, 255, 0.82);
	box-shadow: inset 0 0 0 1px rgba(220, 231, 238, 0.62);
	backdrop-filter: blur(1px);
}

.receipt-row-modal-loading .glyphicon {
	animation: receipt-row-modal-spin 0.8s linear infinite;
}

@keyframes receipt-row-modal-spin {
	to {
		transform: rotate(360deg);
	}
}

@media (max-width: 767px) {
	#receipt-row-modal .modal-dialog {
		width: calc(100vw - 12px);
		margin: 6px;
	}

	.receipt-row-modal-toolbar {
		align-items: stretch;
		flex-direction: column;
	}

	.receipt-row-modal-toolbar-right {
		justify-content: space-between;
	}
}
