/* ==========================================================================
   Empere Bulk Quote — form + category CTA
   Loaded only on the Get a Quote page and on product category archives.
   Every rule is scoped to .emp-quote / .emp-quote-cta.
   !important is used only where global theme/plugin rules already use it
   (button backgrounds, p font-size).
   ========================================================================== */

.emp-quote,
.emp-quote-cta {
	--eq-gold: #d79e0b;
	--eq-gold-hi: #e9b225;
	--eq-gold-tint: #fdf5e1;
	--eq-ink: #15171a;
	--eq-navy: #1b1c26;
	--eq-text: #3c4048;
	--eq-muted: #6b7079;
	--eq-line: #e2e4e8;
	--eq-soft: #f5f6f8;
	--eq-red: #c62828;
	--eq-green: #1f7a3a;
}

.emp-quote *,
.emp-quote *::before,
.emp-quote *::after { box-sizing: border-box; }

/* The plugin stylesheet hides `.page-id-8637 .site-main > :last-child` (meant for a
   reviews block after the old form). Keep the page article itself visible. */
body.emp-quote-page .site-main > article.page { display: block !important; }

/* ---------- Card ---------- */
.emp-quote {
	margin: 24px 0 48px;
	padding: 34px;
	border: 1px solid var(--eq-line);
	border-radius: 16px;
	background: #fff;
	box-shadow: 0 2px 4px rgba(16, 18, 22, .03), 0 12px 32px rgba(16, 18, 22, .06);
	color: var(--eq-text);
	font-size: 15px;
	line-height: 1.55;
}
.emp-quote p { font-size: 15px !important; line-height: 1.6; margin: 0; }

.emp-quote__head { margin-bottom: 26px; }
.emp-quote__kicker {
	display: inline-block;
	font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
	color: var(--eq-gold);
}
.emp-quote h2.emp-quote__title {
	margin: 4px 0 8px; padding: 0; border: 0;
	font-size: 28px; line-height: 1.2; font-weight: 700; letter-spacing: -.02em; color: var(--eq-ink); text-transform: none;
}
.emp-quote p.emp-quote__intro { color: var(--eq-muted); font-size: 14.5px !important; max-width: 46em; }

/* ---------- Sections ---------- */
.emp-quote__section {
	margin: 0 0 22px; padding: 22px 0 0; min-width: 0;
	border: 0; border-top: 1px solid var(--eq-line);
}
.emp-quote__legend {
	display: flex; align-items: center; gap: 10px;
	float: left; width: 100%; margin: 0 0 16px; padding: 0;
	font-size: 16px; font-weight: 700; color: var(--eq-ink);
}
.emp-quote__legend + * { clear: both; }
.emp-quote__legend span {
	display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
	background: var(--eq-ink); color: var(--eq-gold); font-size: 13px; font-weight: 700;
}

.emp-quote__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; clear: both; }

.emp-quote__field { position: relative; margin: 0 0 16px; }
.emp-quote__field > label {
	display: block; margin: 0 0 6px;
	font-size: 13.5px; font-weight: 700; color: var(--eq-ink);
}
.emp-quote__field abbr { color: var(--eq-red); text-decoration: none; border: 0; }

.emp-quote input[type="text"],
.emp-quote input[type="email"],
.emp-quote input[type="tel"],
.emp-quote input[type="search"],
.emp-quote input[type="number"],
.emp-quote select,
.emp-quote textarea {
	display: block; width: 100%; margin: 0;
	padding: 11px 14px;
	border: 1px solid #d5d8de; border-radius: 10px !important; /* theme rounds text inputs with !important */
	background: #fff; box-shadow: none;
	font-family: inherit; font-size: 15px; line-height: 1.4; color: var(--eq-ink);
	transition: border-color .15s, box-shadow .15s;
}
.emp-quote input[type="text"],
.emp-quote input[type="email"],
.emp-quote input[type="tel"],
.emp-quote input[type="search"],
.emp-quote select { height: 46px; }
.emp-quote textarea { min-height: 96px; resize: vertical; }
.emp-quote input:focus,
.emp-quote select:focus,
.emp-quote textarea:focus {
	outline: none; border-color: var(--eq-gold);
	box-shadow: 0 0 0 3px rgba(215, 158, 11, .2);
}
.emp-quote input::placeholder,
.emp-quote textarea::placeholder { color: #9aa0a8; opacity: 1; }

.emp-quote input[type="file"] {
	display: block; width: 100%; padding: 9px 10px;
	border: 1px dashed #c9ccd3; border-radius: 10px; background: var(--eq-soft);
	font-size: 13.5px; color: var(--eq-text); cursor: pointer;
}
.emp-quote input[type="file"]::file-selector-button {
	margin-right: 10px; padding: 7px 12px; border: 0; border-radius: 8px;
	background: var(--eq-ink); color: #fff; font-weight: 700; font-size: 12.5px; cursor: pointer;
}
.emp-quote__help { display: block; margin-top: 6px; font-size: 12.5px; color: var(--eq-muted); }

/* Field errors */
.emp-quote__field.has-error input,
.emp-quote__field.has-error select,
.emp-quote__field.has-error textarea { border-color: var(--eq-red); }
.emp-quote__error { display: block; margin-top: 5px; font-size: 12.5px; font-weight: 600; color: var(--eq-red); }

/* Honeypot */
.emp-quote__hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Product picker ---------- */
.emp-quote__picker {
	position: relative; margin: 0 0 16px; padding: 14px;
	border: 1px solid var(--eq-line); border-radius: 12px; background: var(--eq-soft);
}
.emp-quote__picker.has-error { border-color: var(--eq-red); }
.emp-quote__picker-bar { display: flex; align-items: center; gap: 12px; }
.emp-quote__picker-bar .emp-quote__filter { flex: 1; height: 42px; }
.emp-quote__count {
	flex: none; padding: 4px 10px; border-radius: 999px;
	background: var(--eq-ink); color: var(--eq-gold); font-size: 12.5px; font-weight: 700;
}
.emp-quote__count:empty { display: none; }
.emp-quote p.emp-quote__picker-hint { margin: 10px 2px 8px; font-size: 13px !important; color: var(--eq-muted); }

.emp-quote__products {
	max-height: 380px; overflow-y: auto; margin: 0; padding: 0; list-style: none;
	border-radius: 10px; background: #fff; border: 1px solid var(--eq-line);
	overscroll-behavior: contain;
}
.emp-quote__products:empty { display: none; }
.emp-quote__products li { margin: 0; }
.emp-quote__picker.is-loading .emp-quote__empty::before {
	content: ""; display: inline-block; width: 14px; height: 14px; margin-right: 8px; vertical-align: -2px;
	border: 2px solid #c9ccd3; border-top-color: var(--eq-gold); border-radius: 50%;
	animation: emp-quote-spin .7s linear infinite;
}
@keyframes emp-quote-spin { to { transform: rotate(360deg); } }
.emp-quote p.emp-quote__empty { margin: 8px 2px 2px; font-size: 13.5px !important; color: var(--eq-muted); }

.emp-quote-product {
	display: grid; grid-template-columns: minmax(0, 1fr) 96px; align-items: center; gap: 12px;
	padding: 8px 12px; border-bottom: 1px solid #eef0f2;
	transition: background-color .15s;
}
.emp-quote-product:last-child { border-bottom: 0; }
.emp-quote-product[hidden] { display: none; }
.emp-quote-product:hover { background: #fafafb; }
.emp-quote-product.is-selected { background: var(--eq-gold-tint); }

.emp-quote-product__pick { display: flex; align-items: center; gap: 12px; margin: 0; min-width: 0; cursor: pointer; font-weight: 400; }
.emp-quote-product__pick input[type="checkbox"] { flex: none; width: 18px; height: 18px; margin: 0; accent-color: var(--eq-ink); cursor: pointer; }
.emp-quote-product__img {
	flex: none; display: grid; place-items: center; width: 44px; height: 44px;
	border-radius: 8px; background: var(--eq-soft); overflow: hidden;
}
.emp-quote-product__img img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.emp-quote-product__info { display: flex; flex-direction: column; min-width: 0; }
.emp-quote-product__name {
	font-size: 14px; font-weight: 600; line-height: 1.35; color: var(--eq-ink);
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.emp-quote-product__sku { font-size: 12px; color: var(--eq-muted); }
.emp-quote-product__qty { margin: 0; }
.emp-quote .emp-quote-product__qty input[type="number"] { height: 38px; padding: 6px 10px; text-align: center; font-size: 14px; }

/* ---------- Checkbox, errors, submit ---------- */
.emp-quote__check { display: inline-flex; align-items: center; gap: 10px; margin: 2px 0 0; font-size: 14px; font-weight: 500; cursor: pointer; }
.emp-quote__check input { width: 18px; height: 18px; margin: 0; accent-color: var(--eq-ink); }

.emp-quote__errors {
	margin: 0 0 16px; padding: 12px 14px; border-radius: 10px;
	background: #fdecec; color: var(--eq-red); font-size: 14px; font-weight: 600;
}
.emp-quote__notice {
	margin: 0 0 20px; padding: 14px 16px; border-radius: 10px;
	background: #fdecec; color: var(--eq-red); font-size: 14.5px; font-weight: 600;
}
.emp-quote__notice.is-success { background: #e8f5ec; color: var(--eq-green); }

.emp-quote__submit { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; padding-top: 6px; }
.emp-quote button.emp-quote__btn {
	display: inline-flex; align-items: center; justify-content: center;
	min-height: 50px; padding: 0 34px; margin: 0;
	border: 0 !important; border-radius: 10px !important;
	background: var(--eq-gold) !important; color: var(--eq-ink) !important;
	font-family: inherit; font-size: 16px; font-weight: 700; line-height: 1; letter-spacing: 0; text-transform: none;
	box-shadow: none !important; cursor: pointer;
	transition: background-color .2s, transform .2s;
}
.emp-quote button.emp-quote__btn:hover,
.emp-quote button.emp-quote__btn:focus { background: var(--eq-gold-hi) !important; color: var(--eq-ink) !important; transform: translateY(-1px); }
.emp-quote button.emp-quote__btn:focus-visible { outline: 3px solid rgba(215, 158, 11, .45); outline-offset: 2px; }
.emp-quote button.emp-quote__btn:disabled { opacity: .65; cursor: progress; transform: none; }
.emp-quote__note { font-size: 13px; color: var(--eq-muted); }

/* ---------- Responsive ---------- */
@media (max-width: 767.98px) {
	.emp-quote { margin: 12px 0 32px; padding: 22px 16px; border-radius: 14px; }
	.emp-quote h2.emp-quote__title { font-size: 24px; }
	.emp-quote__grid { grid-template-columns: minmax(0, 1fr); }
	.emp-quote__picker { padding: 10px; }
	.emp-quote-product { grid-template-columns: minmax(0, 1fr) 76px; gap: 8px; padding: 8px; }
	.emp-quote-product__img { width: 38px; height: 38px; }
	.emp-quote__submit { flex-direction: column; align-items: stretch; }
	.emp-quote button.emp-quote__btn { width: 100%; }
	.emp-quote__note { text-align: center; }
}

/* ==========================================================================
   Category page CTA
   ========================================================================== */
.emp-quote-cta {
	display: flex; align-items: center; justify-content: space-between; gap: 16px 24px;
	margin: 0 0 24px; padding: 16px 20px;
	border: 1px solid #f2dfa8; border-radius: 12px; background: var(--eq-gold-tint);
}
.emp-quote-cta__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.emp-quote-cta__text strong { font-size: 15.5px; font-weight: 700; color: var(--eq-ink); line-height: 1.35; }
.emp-quote-cta__text span { font-size: 13.5px; color: var(--eq-text); line-height: 1.45; }
.emp-quote-cta a.emp-quote-cta__btn {
	flex: none; display: inline-flex; align-items: center; min-height: 42px; padding: 0 20px;
	border-radius: 8px; background: var(--eq-navy); color: #fff;
	font-size: 14px; font-weight: 700; text-decoration: none; white-space: nowrap;
	transition: background-color .2s, color .2s;
}
.emp-quote-cta a.emp-quote-cta__btn:hover,
.emp-quote-cta a.emp-quote-cta__btn:focus { background: var(--eq-gold); color: var(--eq-ink); }

@media (max-width: 575.98px) {
	.emp-quote-cta { flex-direction: column; align-items: stretch; }
	.emp-quote-cta a.emp-quote-cta__btn { justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
	.emp-quote *,
	.emp-quote-cta * { transition: none !important; animation: none !important; }
}

/* ==========================================================================
   Product page: pack price, pricing table, "Better price" box, Get Quote
   dialog. Scoped to .ep-pp / .epq-*; uses the product page colour tokens
   (--ep-blue / --ep-blue-dark from content-single-product.php) with
   fallbacks for the dialog, which is printed outside that wrapper.
   ========================================================================== */
.ep-pp,
.epq-box,
.epq-dialog {
	--epq-blue: var(--ep-blue, #1B75BC);
	--epq-blue-dark: var(--ep-blue-dark, #12558A);
	--epq-ink: #1c1c28;
	--epq-text: #23232b;
	--epq-muted: #6b7280;
	--epq-line: #e6e6ee;
}

/* ---------- Price block: price per piece first ---------- */
.custom-product-price.ep-pack-price { line-height: 1.35; }
.ep-pp { display: flex; flex-direction: column; gap: 6px; }
.ep-pp-main { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; }
.ep-pp .ep-pp-amount .woocommerce-Price-amount { font-size: 30px; font-weight: 800; line-height: 1.15; color: var(--epq-blue-dark); }
.ep-pp-unit { font-size: 17px; font-weight: 700; color: var(--epq-blue-dark); }
.ep-pp-tax { font-size: 14px; font-weight: 400; color: #888; }
.ep-pp-was .woocommerce-Price-amount { font-size: 16px; font-weight: 500; color: #9a9aa8; }
.ep-pp-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; font-size: 16px; font-weight: 600; color: var(--epq-text); }
.ep-pp-pack .woocommerce-Price-amount { font-size: 17px; font-weight: 700; color: var(--epq-text); }
.ep-pp-pack > span:not(.woocommerce-Price-amount) { font-weight: 500; color: var(--epq-muted); }
.ep-pp-pcs {
	padding: 3px 10px; border-radius: 999px; font-size: 13.5px; font-weight: 700;
	background: #eaf3fb; border: 1px solid #cfe3f4; color: var(--epq-blue-dark);
}
.ep-pp-ex { font-size: 14px; font-weight: 600; color: #1e8e3e; }
.ep-pp-ex .woocommerce-Price-amount { font-size: inherit; font-weight: inherit; color: inherit; }

/* ---------- Pricing table + quote box ---------- */
.epq-box {
	border: 1px solid var(--epq-line); border-radius: 12px; background: #fff; overflow: hidden;
	font-size: 15px; color: var(--epq-text);
}
.epq-table { width: 100%; margin: 0; border-collapse: collapse; border: 0; }
.epq-table th,
.epq-table td { padding: 12px 18px; border: 0; border-bottom: 1px solid #f0f0f5; text-align: left; vertical-align: middle; background: none; }
.epq-table thead th { font-size: 14.5px; font-weight: 700; color: var(--epq-ink); background: #fafaff; border-bottom-color: var(--epq-line); }
.epq-table th + th,
.epq-table td + td { border-left: 1px solid #f0f0f5; }
.epq-table .epq-num { text-align: right; }
.epq-table td.epq-qty { color: var(--epq-blue); font-weight: 600; }
.epq-table .woocommerce-Price-amount { font-size: 15px; font-weight: 600; color: var(--epq-text); }
.epq-per { font-size: 13px; color: var(--epq-muted); }
.epq-box p.epq-taxnote { margin: 0; padding: 6px 18px 0; font-size: 12.5px; color: var(--epq-muted); }
.epq-pack {
	display: flex; justify-content: space-between; align-items: center; gap: 12px;
	padding: 12px 18px; border-bottom: 1px solid #f0f0f5; font-size: 15px; color: #555;
}
.epq-pack strong { color: var(--epq-ink); font-weight: 700; }

.epq-quote { margin: 0; padding: 14px 18px 18px; }
.epq-box p.epq-title { margin: 0 0 10px; font-size: 16px; font-weight: 700; color: var(--epq-blue); }
.epq-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 10px; align-items: center; }
.epq-field { position: relative; display: block; margin: 0; }
.epq-box input[type="number"],
.epq-box input[type="tel"] {
	display: block; width: 100%; height: 44px; margin: 0; padding: 0 14px;
	border: 1px solid #d8d8e2; border-radius: 6px !important; background: #fff; box-shadow: none;
	font-family: inherit; font-size: 15px; color: var(--epq-text);
}
.epq-box input:focus { outline: none; border-color: var(--epq-blue); box-shadow: 0 0 0 3px rgba(27, 117, 188, .15); }
.epq-box input[aria-invalid="true"] { border-color: #c62828; }
.epq-box .epq-field--target input { padding-left: 30px !important; } /* room for the ₹ prefix (theme pads inputs with !important) */
.epq-currency { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); font-size: 15px; color: var(--epq-muted); pointer-events: none; }
.epq-field--contact { margin-top: 10px; }
.epq-box button.epq-btn {
	height: 44px; margin: 0; padding: 0 26px; border: 0 !important; border-radius: 6px !important;
	background: var(--epq-blue) !important; color: #fff !important;
	font-family: inherit; font-size: 15px; font-weight: 700; line-height: 1; white-space: nowrap; cursor: pointer;
	transition: background-color .15s;
}
.epq-box button.epq-btn:hover,
.epq-box button.epq-btn:focus { background: var(--epq-blue-dark) !important; color: #fff !important; }
.epq-msg { display: block; margin-top: 8px; font-size: 13px; font-weight: 600; color: #c62828; }
.epq-msg[hidden] { display: none; }

@media (max-width: 600px) {
	.epq-table th,
	.epq-table td { padding: 10px 12px; font-size: 14px; }
	.epq-pack,
	.epq-quote { padding-left: 12px; padding-right: 12px; }
	.epq-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
	.epq-box button.epq-btn { grid-column: 1 / -1; width: 100%; order: 3; }
	.ep-pp .ep-pp-amount .woocommerce-Price-amount { font-size: 26px; }
}

/* ---------- Get Quote dialog ---------- */
html.epq-open { overflow: hidden; }
.epq-dialog {
	width: min(640px, calc(100vw - 32px)); max-height: calc(100vh - 32px); margin: auto; padding: 0;
	border: 0; border-radius: 14px; background: #fff; color: var(--epq-text);
	box-shadow: 0 24px 60px rgba(16, 18, 30, .25); overflow: auto;
}
.epq-dialog[open] { display: block; }
.epq-dialog:not([open]) { display: none; }
.epq-dialog::backdrop { background: rgba(16, 18, 30, .55); }
.epq-dialog * { box-sizing: border-box; }
.epq-d-form { margin: 0; }
.epq-d-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--epq-line); }
.epq-d-head h2 { margin: 0; padding: 0; border: 0; font-size: 20px; font-weight: 700; line-height: 1.3; color: var(--epq-ink); text-transform: none; }
.epq-dialog button.epq-d-close {
	width: 36px; height: 36px; margin: 0; padding: 0; border: 0 !important; border-radius: 50% !important;
	background: #f2f3f7 !important; color: var(--epq-ink) !important; font-size: 22px; line-height: 1; cursor: pointer;
}
.epq-dialog button.epq-d-close:hover { background: #e6e7ee !important; }
.epq-d-body { padding: 18px 22px 6px; }
.epq-d-product { display: flex; align-items: center; gap: 14px; padding: 12px; margin: 0 0 16px; border: 1px solid var(--epq-line); border-radius: 10px; background: #fafaff; }
.epq-d-product img { flex: none; width: 64px; height: 64px; object-fit: contain; border-radius: 6px; background: #fff; margin: 0; }
.epq-d-product div { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: 13.5px; color: var(--epq-muted); }
.epq-d-product strong { font-size: 15px; color: var(--epq-ink); line-height: 1.35; }
.epq-d-price { color: var(--epq-blue-dark); font-weight: 600; }
.epq-d-price .woocommerce-Price-amount { font-size: inherit; color: inherit; }
.epq-d-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; }
.epq-d-field { display: flex; flex-direction: column; gap: 5px; margin: 0; font-size: 13.5px; font-weight: 600; color: var(--epq-ink); }
.epq-d-field--full { grid-column: 1 / -1; }
.epq-d-field abbr { color: #c62828; text-decoration: none; border: 0; }
.epq-dialog input[type="text"],
.epq-dialog input[type="email"],
.epq-dialog input[type="tel"],
.epq-dialog input[type="number"],
.epq-dialog textarea {
	display: block; width: 100%; margin: 0; padding: 10px 12px;
	border: 1px solid #d8d8e2; border-radius: 6px !important; background: #fff; box-shadow: none;
	font-family: inherit; font-size: 15px; font-weight: 400; color: var(--epq-text);
}
.epq-dialog input { height: 44px; }
.epq-dialog textarea { min-height: 84px; resize: vertical; }
.epq-dialog input:focus,
.epq-dialog textarea:focus { outline: none; border-color: var(--epq-blue); box-shadow: 0 0 0 3px rgba(27, 117, 188, .15); }
.epq-d-field.has-error input,
.epq-d-field.has-error textarea { border-color: #c62828; }
.epq-d-hint { font-size: 12.5px; font-weight: 600; color: var(--epq-blue-dark); min-height: 1em; }
.epq-d-msg { font-size: 12.5px; font-weight: 600; color: #c62828; }
.epq-dialog p.epq-d-error { margin: 14px 0 0; padding: 10px 12px; border-radius: 8px; background: #fdecea; color: #c62828; font-size: 14px; font-weight: 600; }
.epq-d-foot { padding: 16px 22px 22px; }
.epq-dialog button.epq-d-submit {
	display: inline-flex; align-items: center; justify-content: center; min-height: 46px; margin: 0; padding: 0 28px;
	border: 0 !important; border-radius: 6px !important; background: var(--epq-blue) !important; color: #fff !important;
	font-family: inherit; font-size: 15.5px; font-weight: 700; cursor: pointer;
}
.epq-dialog button.epq-d-submit:hover,
.epq-dialog button.epq-d-submit:focus { background: var(--epq-blue-dark) !important; }
.epq-dialog button.epq-d-submit:disabled { opacity: .65; cursor: progress; }
.epq-d-done { padding: 32px 22px 26px; text-align: center; }
.epq-dialog p.epq-d-done-title { margin: 0 0 8px; font-size: 18px; font-weight: 700; color: #1e8e3e; }
.epq-dialog p.epq-d-done-text { margin: 0 0 18px; font-size: 15px; color: var(--epq-text); }
.epq-dialog [hidden] { display: none !important; }

@media (max-width: 560px) {
	.epq-d-grid { grid-template-columns: minmax(0, 1fr); }
	.epq-d-head,
	.epq-d-body,
	.epq-d-foot { padding-left: 16px; padding-right: 16px; }
	.epq-dialog button.epq-d-submit { width: 100%; }
}
