/* WC Inquiry Systems — frontend, matched to the Durafinland Figma reference */
.wcinq-archive, .wcinq-system-archive, #wcinq-cart-list-wrap, .wcinq-cart-popup {
	--wcinq-orange: #F98613;
	--wcinq-navy: #111143;
	--wcinq-border: #E5E5E5;
	--wcinq-gray: #6b6b7a;
	color: var(--wcinq-navy);
}

/* ---------- Archive: topbar (search + sort) ---------- */
.wcinq-archive-topbar { display: flex; justify-content: flex-end; align-items: center; gap: 16px; margin-bottom: 32px; }
.wcinq-search-wrap { position: relative; flex: 0 1 420px; }
.wcinq-search { width: 100%; padding: 12px 44px 12px 16px; border: 1px solid #cfcfcf; border-radius: 4px; font-size: 15px; color: var(--wcinq-navy); background: #fff; }
.wcinq-search:focus { outline: none; border-color: var(--wcinq-navy); }
.wcinq-search-icon { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--wcinq-navy); pointer-events: none; }

/* Filter toggle (mobile only; hidden on desktop) */
.wcinq-filter-toggle-wrap { display: none; }
.wcinq-filter-toggle { background: var(--wcinq-navy); color: #fff; border: none; border-radius: 4px; padding: 12px 20px; font-weight: 600; font-size: 15px; cursor: pointer; white-space: nowrap; width: 100%; }

.wcinq-sort-wrap { position: relative; }
.wcinq-sort-toggle { background: var(--wcinq-navy); color: #fff; border: none; border-radius: 4px; padding: 12px 20px; font-weight: 600; font-size: 15px; cursor: pointer; white-space: nowrap; }
.wcinq-sort-menu { display: none; position: absolute; right: 0; top: calc(100% + 6px); background: #fff; border: 1px solid var(--wcinq-border); border-radius: 6px; box-shadow: 0 8px 24px rgba(17,17,67,.12); min-width: 200px; z-index: 20; overflow: hidden; }
.wcinq-sort-menu.is-open { display: block; }
.wcinq-sort-option { display: block; width: 100%; text-align: left; background: none; border: none; padding: 12px 16px; font-size: 14px; cursor: pointer; color: var(--wcinq-navy); }
.wcinq-sort-option:hover { background: #f7f7f7; }

/* ---------- Archive layout ---------- */
.wcinq-archive-layout { display: flex; gap: 48px; align-items: flex-start; }
.wcinq-archive-sidebar { width: 230px; flex-shrink: 0; }
.wcinq-archive-sidebar h4 { margin: 0 0 16px; font-size: 16px; font-weight: 700; color: var(--wcinq-navy); }
.wcinq-archive-sidebar h4:not(:first-child) { margin-top: 36px; }
.wcinq-filter-option { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 15px; color: var(--wcinq-navy); cursor: pointer; }
.wcinq-filter-option input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--wcinq-navy); border: 1px solid var(--wcinq-navy); flex-shrink: 0; margin: 0; }
.wcinq-archive-results { flex: 1; min-width: 0; }

.wcinq-grid { display: grid; grid-template-columns: repeat(var(--wcinq-columns, 2), 1fr); gap: 24px; }

/* ---------- Product card ---------- */
.wcinq-card { border: 1px solid var(--wcinq-border); border-radius: 6px; padding: 32px; background: #fff; display: flex; flex-direction: column; }
.wcinq-card-category { color: var(--wcinq-orange); font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 14px; }
.wcinq-card-title { font-size: 19px; font-weight: 700; line-height: 1.3; margin: 0 0 14px; color: var(--wcinq-navy); }
.wcinq-card-meta { margin-bottom: 18px; }
.wcinq-card-productno, .wcinq-card-description { font-size: 14px; line-height: 1.5; color: var(--wcinq-navy); margin: 0; }
.wcinq-card-rows { margin-bottom: 6px; }
.wcinq-card-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; padding: 7px 0; gap: 12px; }
.wcinq-card-row strong { font-weight: 700; color: var(--wcinq-navy); }
.wcinq-card-row span { color: var(--wcinq-navy); text-align: right; }
.wcinq-card-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; gap: 16px; flex-wrap: wrap; }
.wcinq-card-readmore { font-size: 15px; color: var(--wcinq-navy); }
.wcinq-desc-toggle { background: none; border: none; padding: 0 0 2px; cursor: pointer; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.wcinq-card-description .wcinq-desc-full p:first-child { margin-top: 0; }
.wcinq-card-description .wcinq-desc-full p:last-child { margin-bottom: 0; }
.wcinq-card-btn { background: none; border: none; padding: 0 0 2px; font-weight: 700; font-size: 15px; color: var(--wcinq-orange); border-bottom: 2px solid var(--wcinq-orange); cursor: pointer; white-space: nowrap; }
.wcinq-readmore-link { font-weight: 700; font-size: 15px; color: var(--wcinq-orange); text-decoration: none; border-bottom: 2px solid var(--wcinq-orange); padding-bottom: 2px; white-space: nowrap; }
.wcinq-readmore-link:hover { color: #d97210; border-color: #d97210; }
.wcinq-readmore-link span { display: inline-block; margin-left: 6px; }
.wcinq-card-pdf-row { margin: -4px 0 14px; }
.wcinq-product-pdf-link { font-weight: 600; font-size: 14px; color: var(--wcinq-navy); text-decoration: none; white-space: nowrap; }
.wcinq-product-pdf-link:hover { color: var(--wcinq-orange); }
.wcinq-product-pdf-link span { display: inline-block; margin-left: 6px; }
.wcinq-no-results { grid-column: 1 / -1; color: var(--wcinq-gray); padding: 40px 0; text-align: center; }

/* ---------- Filter Popup ---------- */
.wcinq-filter-popup { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 10000; display: none; align-items: center; justify-content: center; padding: 16px; }
.wcinq-filter-popup.is-open { display: flex; }
.wcinq-filter-popup-inner { background: #fff; width: 100%; max-width: 500px; border-radius: 12px; overflow: hidden; animation: wcinqSlideUp 0.3s ease-out; display: flex; flex-direction: column; }
.wcinq-filter-popup-header { padding: 20px; border-bottom: 1px solid var(--wcinq-border); display: flex; justify-content: space-between; align-items: center; }
.wcinq-filter-popup-header h3 { margin: 0; font-size: 18px; color: var(--wcinq-navy); }
#wcinq-filter-popup-close { background: none; border: none; font-size: 26px; cursor: pointer; color: var(--wcinq-gray); line-height: 1; }
.wcinq-filter-popup-content { padding: 20px; max-height: 60vh; overflow-y: auto; }
.wcinq-filter-group { margin-bottom: 24px; }
.wcinq-filter-group:last-child { margin-bottom: 0; }
.wcinq-filter-group h4 { margin: 0 0 12px; font-size: 15px; font-weight: 700; color: var(--wcinq-navy); }
.wcinq-filter-popup-footer { padding: 16px 20px; border-top: 1px solid var(--wcinq-border); }
#wcinq-filter-apply { background: var(--wcinq-orange); color: #fff; border: none; padding: 14px 24px; border-radius: 6px; font-weight: 700; cursor: pointer; width: 100%; font-size: 15px; }
#wcinq-filter-apply:hover { background: #d97210; }
@keyframes wcinqSlideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* ---------- Pagination / per-page ---------- */
.wcinq-archive-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 40px; flex-wrap: wrap; gap: 16px; }
.wcinq-pagination { display: flex; align-items: center; gap: 14px; }
.wcinq-page-link { background: none; border: none; font-size: 15px; color: var(--wcinq-navy); cursor: pointer; padding: 4px 2px; }
.wcinq-page-link.is-active { color: var(--wcinq-orange); font-weight: 700; text-decoration: underline; text-underline-offset: 4px; }
.wcinq-page-link:disabled { opacity: .35; cursor: default; }
.wcinq-perpage { font-size: 14px; color: var(--wcinq-navy); display: flex; align-items: center; gap: 12px; }
.wcinq-perpage-option { background: none; border: none; font-size: 14px; color: var(--wcinq-navy); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; padding: 2px; }
.wcinq-perpage-option.is-active { color: var(--wcinq-orange); font-weight: 700; }
.wcinq-perpage-mobile { display: none; }
@media (max-width: 860px) {
	.wcinq-perpage-desktop { display: none; }
	.wcinq-perpage-mobile { display: inline-block; }
}

/* ---------- System archive ---------- */
.wcinq-system-archive-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; margin-bottom: 32px; }
.wcinq-system-archive-header h2 { font-size: 26px; margin: 0; color: var(--wcinq-navy); }
.wcinq-btn-arrow span { display: inline-block; margin-left: 6px; }
.wcinq-system-archive-body { display: flex; gap: 48px; align-items: flex-start; }
.wcinq-system-pdfs { width: 230px; flex-shrink: 0; }
.wcinq-system-pdfs h4 { font-size: 16px; font-weight: 700; margin: 0 0 16px; }
.wcinq-system-pdf-item { margin-bottom: 16px; }
.wcinq-system-pdf-label { font-size: 14px; color: var(--wcinq-navy); margin-bottom: 4px; }
.wcinq-system-pdf-link { font-size: 14px; font-weight: 700; color: var(--wcinq-orange); text-decoration: underline; }
.wcinq-system-archive-body .wcinq-grid { flex: 1; }

/* ---------- Buttons ---------- */
.wcinq-btn-primary { display: inline-flex; align-items: center; margin-top: 0; padding: 14px 22px; background: var(--wcinq-orange); color: #fff; border: none; border-radius: 4px; cursor: pointer; font-weight: 700; font-size: 15px; text-decoration: none; }
.wcinq-btn-primary:hover { background: #d97210; color: #fff; }

/* ---------- Cart list page ---------- */
#wcinq-cart-list-wrap { max-width: 100%; }
.wcinq-cart-intro { font-size: 14px; color: var(--wcinq-gray); max-width: 620px; line-height: 1.6; margin: 0 0 24px; }
.wcinq-cart-list-header { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
#wcinq-cart-list-count-wrap { font-size: 18px; font-weight: 700; color: var(--wcinq-navy); }
#wcinq-clear-cart { font-size: 14px; color: var(--wcinq-gray); text-decoration: none; }
#wcinq-clear-cart.is-disabled { pointer-events: none; opacity: .5; }
.wcinq-cart-table { width: 100%; border-collapse: collapse; }
.wcinq-cart-table thead th { text-align: left; font-size: 14px; font-weight: 700; color: var(--wcinq-navy); padding: 12px 8px; border-bottom: 1px solid var(--wcinq-border); }
.wcinq-cart-table tbody td { padding: 18px 8px; border-bottom: 1px solid #eee; vertical-align: middle; font-size: 14px; color: var(--wcinq-navy); }
.wcinq-cart-cat { color: var(--wcinq-orange); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; margin-bottom: 4px; }
.wcinq-cart-title { font-weight: 700; font-size: 15px; }
.wcinq-remove-cart-item { background: none; border: none; cursor: pointer; font-size: 13px; color: var(--wcinq-gray); float: right; }
.wcinq-cart-empty-state { padding: 48px 0 16px; }
.wcinq-cart-empty-state h3 { font-size: 22px; margin: 0 0 12px; color: var(--wcinq-navy); }
.wcinq-cart-empty-state p { font-size: 14px; color: var(--wcinq-gray); margin: 0 0 20px; max-width: 520px; }
.wcinq-add-more-link { display: inline-block; margin-top: 20px; font-size: 15px; font-weight: 700; color: var(--wcinq-orange); text-decoration: underline; text-underline-offset: 3px; }

/* System rows in the cart list */
.wcinq-cart-system-link { color: #F98613; text-decoration: none; }
.wcinq-cart-system-link:hover { text-decoration: underline; }
.wcinq-cart-system-note { font-size: 13px; color: var(--wcinq-gray); line-height: 1.6; margin: 14px 0 0; font-style: italic; }

/* Toast for cart rule messages */
.wcinq-toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(10px); background: #F98613; color: #fff; padding: 12px 22px; border-radius: 6px; font-size: 14px; box-shadow: 0 8px 24px rgba(249,134,19,.35); opacity: 0; transition: opacity .25s ease, transform .25s ease; z-index: 100000; max-width: 90vw; text-align: center; }
.wcinq-toast.is-visible { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Cart popup ---------- */
.wcinq-cart-popup-overlay { position: fixed; inset: 0; background: rgba(17,17,67,.35); z-index: 99998; }
.wcinq-cart-popup { position: fixed; top: 90px; right: 40px; width: 420px; max-width: calc(100vw - 32px); max-height: 82vh; background: #fff; border-radius: 12px; box-shadow: 0 24px 60px rgba(17,17,67,.28); z-index: 99999; display: flex; flex-direction: column; overflow: hidden; }
.wcinq-cart-popup-inner { padding: 28px; display: flex; flex-direction: column; overflow-y: auto; }
.wcinq-cart-popup-header { display: flex; align-items: baseline; gap: 10px; margin-bottom: 20px; position: relative; }
.wcinq-cart-popup-header h3 { font-size: 20px; margin: 0; font-weight: 700; color: var(--wcinq-navy); }
#wcinq-popup-count-wrap { margin-left: auto; font-size: 14px; color: var(--wcinq-navy); padding-right: 24px; }
#wcinq-cart-popup-close { position: absolute; right: 0; top: -4px; background: none; border: none; font-size: 22px; cursor: pointer; color: var(--wcinq-navy); line-height: 1; }
#wcinq-cart-popup-body { overflow-y: auto; }
.wcinq-popup-item { padding: 16px 0; border-bottom: 1px solid #eee; }
.wcinq-popup-item-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.wcinq-popup-item-title { font-weight: 700; font-size: 15px; color: var(--wcinq-navy); }
.wcinq-popup-item-subtitle { font-size: 13px; color: var(--wcinq-gray); margin-top: 4px; }
.wcinq-popup-remove { background: none; border: none; cursor: pointer; font-size: 16px; color: var(--wcinq-gray); flex-shrink: 0; }
.wcinq-cart-popup-cta { text-align: center; justify-content: center; margin-top: 20px; width: 100%; box-sizing: border-box; flex-shrink: 0; }
.wcinq-cart-popup-links { display: flex; justify-content: space-between; margin-top: 16px; font-size: 14px; flex-shrink: 0; }
.wcinq-cart-popup-links a:first-child { color: var(--wcinq-navy); font-weight: 700; text-decoration: underline; }
.wcinq-cart-popup-links a:last-child { color: var(--wcinq-gray); text-decoration: none; }
.wcinq-cart-empty { color: var(--wcinq-gray); font-size: 14px; padding: 24px 0; }

/* ---------- Cart popup: empty state (Figma design) ---------- */
.wcinq-popup-empty-state { padding: 8px 0 16px; }
.wcinq-popup-empty-state h3 { font-size: 22px; font-weight: 700; color: var(--wcinq-navy); margin: 0 0 14px; }
.wcinq-popup-empty-state p { font-size: 14px; line-height: 1.6; color: var(--wcinq-gray); margin: 0 0 24px; max-width: 340px; }
.wcinq-popup-empty-state .wcinq-add-more-link { display: inline-block; font-size: 15px; font-weight: 700; color: var(--wcinq-navy); text-decoration: none; border-bottom: 3px solid var(--wcinq-orange); padding-bottom: 6px; }
.wcinq-popup-empty-state .wcinq-add-more-link:hover { color: var(--wcinq-orange); }
.wcinq-popup-empty-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 4px; }
.wcinq-popup-empty-actions .wcinq-add-more-link { margin-top: 0; }
.wcinq-popup-empty-cart-btn { display: inline-flex; align-items: center; background: var(--wcinq-orange); color: #fff; border-radius: 4px; padding: 11px 18px; font-size: 14px; font-weight: 700; text-decoration: none; flex-shrink: 0; }
.wcinq-popup-empty-cart-btn:hover { background: #d97210; color: #fff; }
.wcinq-popup-empty-cart-btn span { margin-left: 6px; }

/* ---------- Responsive: mobile ---------- */
@media (max-width: 860px) {
	.wcinq-grid { grid-template-columns: 1fr; gap: 20px; }
	.wcinq-archive-layout { flex-direction: column; }
	.wcinq-archive-sidebar { display: none; }

	/* Topbar stacks: search full width, then filter + sort side by side */
	.wcinq-archive-topbar { flex-direction: column; align-items: stretch; gap: 12px; }
	.wcinq-search-wrap { flex: 1; width: 100%; }
	.wcinq-filter-toggle-wrap { display: block; flex: 1; }
	.wcinq-sort-wrap { flex: 1; }
	.wcinq-sort-toggle { width: 100%; }
	.wcinq-sort-menu { right: auto; left: 0; min-width: 100%; }

	/* Mobile Product Card Styling */
	.wcinq-card { padding: 24px; border-radius: 10px; }
	.wcinq-card-category { font-size: 11px; }
	.wcinq-card-title { font-size: 17px; }
	.wcinq-card-meta { margin-bottom: 12px; }
	.wcinq-card-productno, .wcinq-card-description { font-size: 13px; color: var(--wcinq-gray); }
	.wcinq-card-rows { display: block; }
	.wcinq-card-row { font-size: 13px; padding: 6px 0; }
	.wcinq-card-footer { justify-content: space-between; gap: 8px; }
	.wcinq-card-readmore { font-size: 14px; }
	.wcinq-card-btn { font-size: 14px; }

	/* System archive stacks */
	.wcinq-system-archive-body { flex-direction: column; }
	.wcinq-system-pdfs { width: 100%; }

	/* Mobile Cart Page: table becomes stacked cards */
	.wcinq-cart-table thead { display: none; }
	.wcinq-cart-table tbody td { display: block; padding: 10px 8px; border: none; }
	.wcinq-cart-table tbody tr { display: block; background: #fff; border: 1px solid var(--wcinq-border); border-radius: 8px; margin-bottom: 16px; padding: 14px; box-shadow: 0 2px 4px rgba(0,0,0,0.05); }
	.wcinq-cart-table tbody td:first-child { padding-top: 0; }
	.wcinq-cart-table tbody td:nth-child(2),
	.wcinq-cart-table tbody td:nth-child(3) { padding: 2px 8px; font-size: 13px; color: var(--wcinq-gray); }
	.wcinq-cart-table tbody td:last-child { text-align: right; padding-bottom: 0; }

	/* Cart popup becomes a centered modal */
	.wcinq-cart-popup { top: 50%; right: auto; left: 50%; transform: translate(-50%, -50%); width: 92vw; max-width: 420px; }
}
