/**
 * Quote & Cut Advanced - hole operations wizard styles.
 */

/* ------------------------------------------------------ per-part block */

.quoteandcut-hole-ops {
	margin-top: 12px;
	padding: 12px 14px;
	border: 1px solid #d7dde6;
	border-radius: 8px;
	background: #f8fafc;
}

.quoteandcut-hole-ops h4 {
	margin: 0 0 4px;
	font-size: 14px;
}

.quoteandcut-hole-ops__intro {
	margin: 0 0 10px;
	font-size: 12.5px;
	line-height: 1.5;
	color: #4b5563;
}

.quoteandcut-hole-ops__notices {
	display: none;
	margin: 0 0 10px;
	padding: 8px 10px;
	border-radius: 6px;
	background: #fef3c7;
	color: #7c5806;
	font-size: 12.5px;
}

.quoteandcut-hole-ops__open {
	display: inline-block;
	padding: 8px 14px;
	border: 1px solid #3d4b5f;
	border-radius: 6px;
	background: #fff;
	color: #1f2937;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 0.15s ease, border-color 0.15s ease;
}

.quoteandcut-hole-ops__open:hover {
	border-color: #1f2937;
	background: #eef2f7;
}

.quoteandcut-hole-ops__open:focus-visible {
	border-color: #1f2937;
	background: #eef2f7;
	outline: 2px solid #93c5fd;
	outline-offset: 2px;
}

.quoteandcut-hole-ops__summary {
	margin: 10px 0 0;
	padding: 0;
	list-style: none;
	font-size: 12.5px;
	color: #1f2937;
}

.quoteandcut-hole-ops__summary li {
	position: relative;
	margin: 2px 0;
	padding-left: 16px;
}

.quoteandcut-hole-ops__summary li::before {
	position: absolute;
	top: 6px;
	left: 2px;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #2563eb;
	content: "";
}

/* ------------------------------------------------------------- overlay */

.quoteandcut-hole-wizard-overlay {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 20px;
}

.quoteandcut-hole-wizard-overlay[hidden] {
	display: none;
}

.quoteandcut-hole-wizard-overlay__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(17, 24, 39, 0.58);
}

body.quoteandcut-hole-wizard-open {
	overflow: hidden;
}

.quoteandcut-hole-wizard {
	position: relative;
	display: flex;
	flex-direction: column;
	width: min(1180px, 100%);
	max-height: min(820px, calc(100vh - 40px));
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 24px 60px rgba(15, 23, 42, 0.35);
	overflow: hidden;
}

.quoteandcut-hole-wizard__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 14px 18px;
	border-bottom: 1px solid #e5e9f0;
}

.quoteandcut-hole-wizard__title {
	margin: 0;
	font-size: 17px;
	font-weight: 700;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.quoteandcut-hole-wizard__close {
	flex: 0 0 auto;
	width: 34px;
	height: 34px;
	border: 0;
	border-radius: 6px;
	background: transparent;
	font-size: 23px;
	line-height: 1;
	color: #4b5563;
	cursor: pointer;
}

.quoteandcut-hole-wizard__close:hover,
.quoteandcut-hole-wizard__close:focus-visible {
	background: #eef2f7;
	color: #111827;
	outline: 2px solid #93c5fd;
	outline-offset: 1px;
}

.quoteandcut-hole-wizard__body {
	display: flex;
	flex: 1 1 auto;
	min-height: 0;
}

/* ---------------------------------------------------------- drawing area */

.quoteandcut-hole-wizard__stage {
	display: flex;
	flex: 1 1 62%;
	flex-direction: column;
	min-width: 0;
	padding: 14px;
	background: #f1f5f9;
}

.quoteandcut-hole-wizard__view-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 8px;
}

.quoteandcut-hole-wizard__view-label {
	font-size: 12px;
	font-weight: 700;
	color: #475569;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.quoteandcut-hole-wizard__zoom-controls {
	display: inline-flex;
	align-items: stretch;
	border: 1px solid #cbd5e1;
	border-radius: 7px;
	background: #fff;
	overflow: hidden;
}

.quoteandcut-hole-wizard__zoom {
	min-width: 34px;
	height: 30px;
	padding: 0 9px;
	border: 0;
	border-right: 1px solid #e2e8f0;
	background: #fff;
	color: #334155;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
}

.quoteandcut-hole-wizard__zoom:last-child {
	border-right: 0;
}

.quoteandcut-hole-wizard__zoom--fit {
	font-size: 11.5px;
	font-weight: 600;
}

.quoteandcut-hole-wizard__zoom:hover,
.quoteandcut-hole-wizard__zoom:focus-visible {
	background: #eff6ff;
	color: #1d4ed8;
	outline: 0;
}

.quoteandcut-hole-wizard__canvas-wrap {
	position: relative;
	flex: 1 1 auto;
	min-height: 0;
	border-radius: 8px;
	background: #fff;
	overflow: hidden;
}

.quoteandcut-hole-wizard__canvas {
	display: block;
	width: 100%;
	height: 100%;
	min-height: clamp(160px, calc(100vh - 360px), 390px);
	background: #fff;
	cursor: grab;
	touch-action: none;
}

.quoteandcut-hole-wizard__canvas.is-panning {
	cursor: grabbing;
}

.quoteandcut-hole-wizard__tooltip {
	position: absolute;
	z-index: 3;
	max-width: 260px;
	padding: 6px 8px;
	border-radius: 5px;
	background: rgba(15, 23, 42, 0.94);
	box-shadow: 0 4px 12px rgba(15, 23, 42, 0.18);
	color: #fff;
	font-size: 11.5px;
	line-height: 1.35;
	pointer-events: none;
}

.quoteandcut-hole-wizard__tooltip[hidden] {
	display: none;
}

.quoteandcut-hole-wizard__legend {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 10px;
	font-size: 12px;
	color: #374151;
}

.quoteandcut-hole-wizard__chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 3px 9px;
	border: 1px solid #dbe2ea;
	border-radius: 999px;
	background: #fff;
}

.quoteandcut-hole-wizard__chip-dot,
.quoteandcut-hole-wizard__state-dot {
	display: inline-block;
	width: 9px;
	height: 9px;
	border-radius: 50%;
	flex: 0 0 auto;
}

.quoteandcut-hole-wizard__state-dot.is-available {
	border: 2px dashed #2563eb;
	background: #fff;
}

.quoteandcut-hole-wizard__state-dot.is-attention {
	border: 2px solid #d97706;
	background: #fffbeb;
}

.quoteandcut-hole-wizard__legend-note {
	flex-basis: 100%;
	margin: 4px 0 0;
	font-size: 11.5px;
	line-height: 1.45;
	color: #6b7280;
}

/* ------------------------------------------------------------ side panel */

.quoteandcut-hole-wizard__panel {
	flex: 1 1 38%;
	min-width: 320px;
	max-width: 440px;
	padding: 18px;
	border-left: 1px solid #e5e9f0;
	background: #fff;
	overflow-y: auto;
}

.quoteandcut-hole-wizard__panel-title,
.quoteandcut-hole-wizard__hole-title {
	margin: 0 0 6px;
	font-size: 16px;
	line-height: 1.35;
}

.quoteandcut-hole-wizard__prompt,
.quoteandcut-hole-wizard__hole-meta {
	margin: 0 0 12px;
	font-size: 13px;
	line-height: 1.5;
	color: #4b5563;
}

.quoteandcut-hole-wizard__prompt--subtle {
	font-size: 12px;
	color: #64748b;
}

.quoteandcut-hole-wizard__back {
	display: inline-flex;
	align-items: center;
	margin: 0 0 12px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #2563eb;
	font-size: 12.5px;
	font-weight: 600;
	cursor: pointer;
}

.quoteandcut-hole-wizard__back::before {
	margin-right: 5px;
	content: "←";
}

.quoteandcut-hole-wizard__back:hover,
.quoteandcut-hole-wizard__back:focus-visible {
	color: #1d4ed8;
	text-decoration: underline;
	outline: 0;
}

.quoteandcut-hole-wizard__groups {
	margin: 0;
	padding: 0;
	list-style: none;
}

.quoteandcut-hole-wizard__groups li {
	margin: 0 0 8px;
}

.quoteandcut-hole-wizard__group {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	width: 100%;
	padding: 10px 11px;
	border: 1px solid #dbe2ea;
	border-radius: 7px;
	background: #fff;
	text-align: left;
	cursor: pointer;
	transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.quoteandcut-hole-wizard__group:hover,
.quoteandcut-hole-wizard__group:focus-visible {
	border-color: #60a5fa;
	background: #eff6ff;
	box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.08);
	outline: 0;
}

.quoteandcut-hole-wizard__group.is-attention {
	border-color: #f0c36d;
	background: #fffbeb;
}

.quoteandcut-hole-wizard__group-main {
	font-size: 13.5px;
	font-weight: 650;
	color: #1f2937;
}

.quoteandcut-hole-wizard__group-status {
	font-size: 11.5px;
	line-height: 1.25;
	color: #64748b;
	text-align: right;
}

.quoteandcut-hole-wizard__op-group {
	margin: 0 0 16px;
	padding: 12px;
	border: 1px solid #e2e8f0;
	border-radius: 8px;
	background: #f8fafc;
}

.quoteandcut-hole-wizard__op-name {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-bottom: 5px;
	font-size: 12px;
	font-weight: 700;
	color: #374151;
	text-transform: uppercase;
	letter-spacing: 0.03em;
}

.quoteandcut-hole-wizard__instruction,
.quoteandcut-hole-wizard__pricing-note {
	margin: 0 0 8px;
	font-size: 11.5px;
	line-height: 1.45;
	color: #475569;
}

.quoteandcut-hole-wizard__pricing-note {
	color: #64748b;
}

.quoteandcut-hole-wizard__choice {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	width: 100%;
	margin-top: 6px;
	padding: 9px 10px;
	border: 1px solid #dbe2ea;
	border-radius: 6px;
	background: #fff;
	color: #1f2937;
	font-size: 13px;
	text-align: left;
	cursor: pointer;
	transition: border-color 0.15s ease, background-color 0.15s ease;
}

.quoteandcut-hole-wizard__choice:hover,
.quoteandcut-hole-wizard__choice:focus-visible {
	border-color: #60a5fa;
	background: #eff6ff;
	outline: 0;
}

.quoteandcut-hole-wizard__choice.is-selected {
	border-color: #2563eb;
	background: #dbeafe;
	box-shadow: inset 3px 0 0 #2563eb;
}

.quoteandcut-hole-wizard__choice-label {
	font-weight: 650;
}

.quoteandcut-hole-wizard__choice-price {
	font-size: 11.5px;
	color: #64748b;
	white-space: nowrap;
}

.quoteandcut-hole-wizard__hint {
	margin: 0 0 12px;
	padding: 10px 11px;
	border: 1px solid #fde68a;
	border-radius: 7px;
	background: #fffbeb;
	color: #92400e;
	font-size: 12.5px;
	line-height: 1.5;
}

.quoteandcut-hole-wizard__hint strong {
	display: block;
	margin-bottom: 4px;
}

.quoteandcut-hole-wizard__hint ul {
	margin: 4px 0 0 18px;
	padding: 0;
}

.quoteandcut-hole-wizard__hint li {
	margin: 3px 0;
}

.quoteandcut-hole-wizard__individual-review {
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid #e2e8f0;
}

.quoteandcut-hole-wizard__individual-review h5 {
	margin: 0 0 4px;
	font-size: 12.5px;
	color: #334155;
}

.quoteandcut-hole-wizard__individual-review p {
	margin: 0 0 8px;
	font-size: 11.5px;
	line-height: 1.45;
	color: #64748b;
}

.quoteandcut-hole-wizard__individual-review ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

.quoteandcut-hole-wizard__individual-review li {
	margin: 0 0 6px;
}

.quoteandcut-hole-wizard__individual-hole {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	width: 100%;
	padding: 8px 9px;
	border: 1px solid #dbe2ea;
	border-radius: 6px;
	background: #fff;
	color: #1f2937;
	font-size: 12px;
	text-align: left;
	cursor: pointer;
}

.quoteandcut-hole-wizard__individual-hole small {
	font-size: 10.5px;
	color: #64748b;
	text-align: right;
}

.quoteandcut-hole-wizard__individual-hole:hover,
.quoteandcut-hole-wizard__individual-hole:focus-visible {
	border-color: #60a5fa;
	background: #eff6ff;
	outline: 0;
}

.quoteandcut-hole-wizard__panel-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 12px;
}

/* -------------------------------------------------------------- footer */

.quoteandcut-hole-wizard__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	padding: 12px 18px;
	border-top: 1px solid #e5e9f0;
	background: #f8fafc;
}

.quoteandcut-hole-wizard__summary {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr) auto;
	align-items: center;
	gap: 8px 16px;
	min-width: 0;
	font-size: 12.5px;
	color: #1f2937;
}

.quoteandcut-hole-wizard__summary-status {
	display: flex;
	flex-direction: column;
	gap: 1px;
}

.quoteandcut-hole-wizard__summary-status strong {
	font-size: 12.5px;
}

.quoteandcut-hole-wizard__summary-status span {
	font-size: 11px;
	color: #64748b;
}

.quoteandcut-hole-wizard__summary-items {
	display: flex;
	flex-wrap: wrap;
	gap: 5px 12px;
	min-width: 0;
}

.quoteandcut-hole-wizard__summary-item {
	display: inline-flex;
	align-items: center;
	gap: 5px;
	font-size: 11.5px;
	white-space: nowrap;
}

.quoteandcut-hole-wizard__estimate {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	min-width: 150px;
}

.quoteandcut-hole-wizard__estimate span {
	font-size: 10.5px;
	color: #64748b;
}

.quoteandcut-hole-wizard__estimate strong {
	font-size: 16px;
	line-height: 1.2;
	color: #0f172a;
}

.quoteandcut-hole-wizard__estimate small {
	max-width: 250px;
	margin-top: 1px;
	font-size: 9.5px;
	line-height: 1.3;
	color: #64748b;
	text-align: right;
}

.quoteandcut-hole-wizard__limit-note {
	grid-column: 1 / -1;
	padding: 6px 8px;
	border: 1px solid #f0c36d;
	border-radius: 5px;
	background: #fffbeb;
	color: #92400e;
	font-size: 11px;
	line-height: 1.4;
}

.quoteandcut-hole-wizard__actions {
	display: flex;
	gap: 8px;
	flex: 0 0 auto;
}

.quoteandcut-hole-wizard__button {
	padding: 9px 16px;
	border: 1px solid transparent;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
}

.quoteandcut-hole-wizard__button--primary {
	background: #1f2937;
	color: #fff;
}

.quoteandcut-hole-wizard__button--primary:hover,
.quoteandcut-hole-wizard__button--primary:focus-visible {
	background: #111827;
	outline: 2px solid #93c5fd;
	outline-offset: 1px;
}

.quoteandcut-hole-wizard__button--secondary {
	border-color: #cbd5e1;
	background: #fff;
	color: #1f2937;
}

.quoteandcut-hole-wizard__button--secondary:hover,
.quoteandcut-hole-wizard__button--secondary:focus-visible {
	background: #eef2f7;
	outline: 2px solid #bfdbfe;
	outline-offset: 1px;
}

/* ----------------------------------------------------------- responsive */

@media (max-width: 900px) {
	.quoteandcut-hole-wizard__body {
		flex-direction: column;
		overflow-y: auto;
	}

	.quoteandcut-hole-wizard__stage {
		flex: 0 0 auto;
	}

	.quoteandcut-hole-wizard__canvas {
		min-height: 320px;
	}

	.quoteandcut-hole-wizard__panel {
		width: auto;
		max-width: none;
		min-width: 0;
		border-top: 1px solid #e5e9f0;
		border-left: 0;
	}

	.quoteandcut-hole-wizard__summary {
		grid-template-columns: 1fr auto;
	}

	.quoteandcut-hole-wizard__summary-items {
		grid-column: 1 / -1;
		grid-row: 2;
	}
}

@media (max-width: 640px) {
	.quoteandcut-hole-wizard-overlay {
		padding: 8px;
	}

	.quoteandcut-hole-wizard {
		max-height: calc(100vh - 16px);
		border-radius: 9px;
	}

	.quoteandcut-hole-wizard__header,
	.quoteandcut-hole-wizard__footer {
		padding-right: 12px;
		padding-left: 12px;
	}

	.quoteandcut-hole-wizard__stage,
	.quoteandcut-hole-wizard__panel {
		padding: 12px;
	}

	.quoteandcut-hole-wizard__canvas {
		min-height: 250px;
	}

	.quoteandcut-hole-wizard__group {
		align-items: flex-start;
		flex-direction: column;
		gap: 4px;
	}

	.quoteandcut-hole-wizard__group-status {
		text-align: left;
	}

	.quoteandcut-hole-wizard__footer {
		align-items: stretch;
		flex-direction: column;
	}

	.quoteandcut-hole-wizard__summary {
		grid-template-columns: 1fr;
	}

	.quoteandcut-hole-wizard__summary-items {
		grid-column: auto;
		grid-row: auto;
	}

	.quoteandcut-hole-wizard__estimate {
		align-items: flex-start;
	}

	.quoteandcut-hole-wizard__estimate small {
		text-align: left;
	}

	.quoteandcut-hole-wizard__actions {
		justify-content: flex-end;
	}
}
