/*!
 * Brick/Block Quantity Estimator — module CSS (e2z-bbq- prefix).
 * Color scheme (spec): Primary #9A3412 (terracotta), Secondary #451A03 (deep brown),
 * Accent #0891B2, BG #FFFBEB.
 * Scope: .e2z-tool-brick-block-quantity-estimator (framework shortcode wrapper).
 */

.e2z-tool-brick-block-quantity-estimator,
.e2z-tool-brick-block-quantity-estimator *,
.e2z-tool-brick-block-quantity-estimator *::before,
.e2z-tool-brick-block-quantity-estimator *::after {
	box-sizing: border-box;
}

.e2z-tool-brick-block-quantity-estimator .e2z-bbq-container {
	font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
	line-height: 1.5;
	color: #451A03;
	width: 100%;
	margin: 0 auto;
	background: #FFFBEB;
	border-radius: 12px;
	box-shadow: 0 4px 20px rgba(69, 26, 3, 0.10);
	overflow: hidden;
}

/* Header */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-header {
	padding: 24px 16px;
	background: linear-gradient(135deg, #9A3412, #451A03);
	color: #fff;
	text-align: center;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-title {
	font-size: 1.8rem;
	font-weight: 700;
	margin: 0 0 4px;
	color: #fff;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-subtitle {
	font-size: 0.9rem;
	opacity: 0.85;
	margin: 0;
}

/* Layout */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-main-grid {
	display: flex;
	flex-direction: column;
	gap: 20px;
	padding: 16px;
}
@media (min-width: 1024px) {
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-main-grid {
		flex-direction: row;
		align-items: flex-start;
	}
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-inputs-panel { flex: 3; }
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-results-panel {
		flex: 3;
		min-width: 360px;
		position: sticky;
		top: 20px;
	}
}

.e2z-tool-brick-block-quantity-estimator .e2z-bbq-inputs-panel,
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-results-panel {
	background: #FFFFFF;
	border-radius: 12px;
	padding: 20px;
	border: 1px solid #FDE68A;
	box-shadow: 0 2px 8px rgba(69, 26, 3, 0.05);
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-section-title {
	font-size: 1.2rem;
	font-weight: 600;
	color: #9A3412;
	margin: 0 0 12px;
	padding-bottom: 8px;
	border-bottom: 2px solid #FED7AA;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-section-title + .e2z-bbq-section-title { margin-top: 18px; }

/* Fields */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-row {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-bottom: 12px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-field {
	flex: 1;
	min-width: 130px;
	display: flex;
	flex-direction: column;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-label {
	font-size: 0.85rem;
	font-weight: 500;
	color: #78350F;
	margin-bottom: 4px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-hint {
	font-size: 0.73rem;
	color: #D6A97A;
	margin-top: 4px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-input {
	width: 100%;
	min-height: 44px;
	padding: 9px 11px;
	border: 1px solid #FCD34D;
	border-radius: 6px;
	font-size: 0.92rem;
	font-family: inherit;
	background: #fff;
	color: #451A03;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-input:focus {
	outline: none;
	border-color: #9A3412;
	box-shadow: 0 0 0 3px rgba(154, 52, 18, 0.14);
}

/* Wall cards */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-wall {
	border: 1px solid #FDE68A;
	border-left: 4px solid #9A3412;
	border-radius: 10px;
	padding: 12px;
	margin-bottom: 12px;
	background: #FFFBEB;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-wall-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 10px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-wall-name {
	font-size: 0.9rem;
	font-weight: 700;
	color: #451A03;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-remove-btn,
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-open-remove {
	min-height: 32px;
	min-width: 32px;
	border: 1px solid #FCA5A5;
	border-radius: 6px;
	background: #FEF2F2;
	color: #DC2626;
	font-size: 0.85rem;
	font-weight: 700;
	cursor: pointer;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-remove-btn:hover,
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-open-remove:hover { background: #DC2626; color: #fff; }

/* Openings */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-openings { margin-top: 8px; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-opening {
	display: flex;
	gap: 8px;
	align-items: flex-end;
	margin-bottom: 8px;
	padding: 8px;
	background: #ECFEFF;
	border: 1px dashed #A5F3FC;
	border-radius: 8px;
	flex-wrap: wrap;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-opening .e2z-bbq-field { min-width: 100px; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-add-open-btn {
	min-height: 36px;
	padding: 7px 14px;
	border: 1px dashed #0891B2;
	border-radius: 8px;
	background: #fff;
	color: #0891B2;
	font-family: inherit;
	font-size: 0.82rem;
	font-weight: 600;
	cursor: pointer;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-add-open-btn:hover { background: #ECFEFF; }

/* Buttons */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-add-wall-btn {
	min-height: 44px;
	padding: 10px 18px;
	border: 1px dashed #9A3412;
	border-radius: 8px;
	background: #fff;
	color: #9A3412;
	font-family: inherit;
	font-size: 0.9rem;
	font-weight: 600;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-add-wall-btn:hover { background: #FFF7ED; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-wall-actions { margin-bottom: 14px; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-calc-btn {
	width: 100%;
	min-height: 48px;
	padding: 13px;
	border: none;
	border-radius: 8px;
	background: #9A3412;
	color: #fff;
	font-family: inherit;
	font-size: 1rem;
	font-weight: 600;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	transition: filter 0.15s ease;
	margin-top: 4px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-calc-btn:hover { filter: brightness(1.15); }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-calc-btn:focus-visible {
	outline: none;
	box-shadow: 0 0 0 3px rgba(8, 145, 178, 0.4);
}

/* Results */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-empty-state {
	padding: 24px;
	text-align: center;
	color: #92400E;
	background: #FFFBEB;
	border-radius: 8px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-hero {
	border-radius: 10px;
	padding: 16px;
	text-align: center;
	margin-bottom: 14px;
	border: 1px solid #FED7AA;
	background: #FFF7ED;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-hero-value {
	font-size: 2rem;
	font-weight: 800;
	margin: 4px 0;
	line-height: 1.1;
	color: #9A3412;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-hero-label {
	font-size: 0.85rem;
	font-weight: 600;
	color: #78350F;
	margin: 0;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-result-block {
	background: #FFFBEB;
	border: 1px solid #FDE68A;
	border-radius: 10px;
	padding: 14px;
	margin-bottom: 12px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-result-block h3 {
	font-size: 1rem;
	color: #451A03;
	margin: 0 0 10px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat-grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(125px, 1fr));
	gap: 10px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat {
	background: #fff;
	border: 1px solid #FDE68A;
	border-radius: 8px;
	padding: 10px;
	text-align: center;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat-label {
	font-size: 0.73rem;
	font-weight: 600;
	color: #92400E;
	margin: 0 0 3px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat-value {
	font-size: 1.02rem;
	font-weight: 700;
	color: #9A3412;
	margin: 0;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat-cyan .e2z-bbq-stat-value { color: #0891B2; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat-dark .e2z-bbq-stat-value { color: #451A03; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-stat-green .e2z-bbq-stat-value { color: #16A34A; }

/* Per-wall table */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-table-wrap { width: 100%; overflow-x: auto; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.83rem;
	background: #fff;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-table th {
	background: #451A03;
	color: #fff;
	padding: 8px;
	text-align: center;
	font-weight: 600;
	white-space: nowrap;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-table td {
	padding: 7px 8px;
	text-align: center;
	border-bottom: 1px solid #FEF3C7;
	white-space: nowrap;
}

.e2z-tool-brick-block-quantity-estimator .e2z-bbq-note {
	font-size: 0.84rem;
	margin: 8px 0 0;
	padding: 9px 11px;
	border-radius: 6px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-note-info { background: #ECFEFF; color: #155E75; border-left: 3px solid #0891B2; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-note-error { background: #FEF2F2; color: #991B1B; border-left: 3px solid #DC2626; }

/* Export */
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-export-row {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
	margin-top: 12px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-print-btn,
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-copy-btn {
	flex: 1;
	min-height: 44px;
	padding: 11px;
	border: none;
	border-radius: 8px;
	color: #fff;
	font-family: inherit;
	font-size: 0.9rem;
	font-weight: 600;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
}
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-print-btn { background: #9A3412; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-copy-btn { background: #451A03; }
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-print-btn:hover,
.e2z-tool-brick-block-quantity-estimator .e2z-bbq-copy-btn:hover { filter: brightness(1.3); }

.e2z-tool-brick-block-quantity-estimator .e2z-bbq-disclaimer {
	font-size: 0.75rem;
	color: #D6A97A;
	margin: 12px 0 0;
	line-height: 1.45;
}

.e2z-tool-brick-block-quantity-estimator .e2z-bbq-hidden { display: none !important; }

/* Responsive */
@media (max-width: 480px) {
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-title { font-size: 1.4rem; }
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-field { min-width: 110px; }
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-inputs-panel,
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-results-panel { padding: 14px; }
}
@media (max-width: 360px) {
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-header { padding: 16px 10px; }
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-title { font-size: 1.25rem; }
	.e2z-tool-brick-block-quantity-estimator .e2z-bbq-field { min-width: 100%; }
}
